summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMarc-André Lureau <marcandre.lureau@gmail.com>2015-12-16 15:29:40 +0100
committerMarc-André Lureau <marcandre.lureau@gmail.com>2016-03-14 12:02:47 +0100
commit8d1da627fb8c08cd1d784262a6b50965f4078472 (patch)
tree46ab2e0e444d180733e6c57551af23d0a05b598b
parent0e70894bff28765e3becba031e19e6ae5d0097b8 (diff)
downloadspice-gtk-8d1da627fb8c08cd1d784262a6b50965f4078472.tar.gz
spice-gtk-8d1da627fb8c08cd1d784262a6b50965f4078472.tar.xz
spice-gtk-8d1da627fb8c08cd1d784262a6b50965f4078472.zip
gtk: make SpiceGtkSession private
Do not leak internals of SpiceGtkSession in our headers. This makes also the class final, which let us extend more easily without fear of breaking ABI. Signed-off-by: Marc-André Lureau <marcandre.lureau@gmail.com> Acked-by: Fabiano Fidêncio <fidencio@redhat.com>
-rw-r--r--src/spice-gtk-session-priv.h13
-rw-r--r--src/spice-gtk-session.h33
2 files changed, 13 insertions, 33 deletions
diff --git a/src/spice-gtk-session-priv.h b/src/spice-gtk-session-priv.h
index b2b6206..d7fe313 100644
--- a/src/spice-gtk-session-priv.h
+++ b/src/spice-gtk-session-priv.h
@@ -22,6 +22,19 @@
G_BEGIN_DECLS
+typedef struct _SpiceGtkSessionPrivate SpiceGtkSessionPrivate;
+
+struct _SpiceGtkSession
+{
+ GObject parent;
+ SpiceGtkSessionPrivate *priv;
+};
+
+struct _SpiceGtkSessionClass
+{
+ GObjectClass parent_class;
+};
+
void spice_gtk_session_request_auto_usbredir(SpiceGtkSession *self,
gboolean state);
gboolean spice_gtk_session_get_read_only(SpiceGtkSession *self);
diff --git a/src/spice-gtk-session.h b/src/spice-gtk-session.h
index 9a45d85..b04f4fc 100644
--- a/src/spice-gtk-session.h
+++ b/src/spice-gtk-session.h
@@ -35,39 +35,6 @@ G_BEGIN_DECLS
typedef struct _SpiceGtkSession SpiceGtkSession;
typedef struct _SpiceGtkSessionClass SpiceGtkSessionClass;
-typedef struct _SpiceGtkSessionPrivate SpiceGtkSessionPrivate;
-
-/**
- * SpiceGtkSession:
- *
- * The #SpiceGtkSession struct is opaque and should not be accessed directly.
- */
-struct _SpiceGtkSession
-{
- GObject parent;
- SpiceGtkSessionPrivate *priv;
- /* Do not add fields to this struct */
-};
-
-/**
- * SpiceGtkSessionClass:
- * @parent_class: Parent class.
- *
- * Class structure for #SpiceGtkSession.
- */
-struct _SpiceGtkSessionClass
-{
- GObjectClass parent_class;
-
- /* signals */
-
- /*< private >*/
- /*
- * If adding fields to this struct, remove corresponding
- * amount of padding to avoid changing overall struct size
- */
- gchar _spice_reserved[SPICE_RESERVED_PADDING];
-};
GType spice_gtk_session_get_type(void);