[Telepathy-commits] [telepathy-gabble/master] GabbleRoomlistChannel: simplify priv access

Simon McVittie simon.mcvittie at collabora.co.uk
Tue Aug 19 10:53:41 PDT 2008


20080722182244-53eee-b0b6ceede6b53291829d16481017cc7156eb36de.gz
---
 src/roomlist-channel.c |    4 +---
 src/roomlist-channel.h |    3 ++-
 2 files changed, 3 insertions(+), 4 deletions(-)

diff --git a/src/roomlist-channel.c b/src/roomlist-channel.c
index 7b3eb55..6bf8abc 100644
--- a/src/roomlist-channel.c
+++ b/src/roomlist-channel.c
@@ -71,7 +71,6 @@ enum
 };
 
 /* private structure */
-typedef struct _GabbleRoomlistChannelPrivate GabbleRoomlistChannelPrivate;
 
 struct _GabbleRoomlistChannelPrivate
 {
@@ -91,8 +90,7 @@ struct _GabbleRoomlistChannelPrivate
   gboolean dispose_has_run;
 };
 
-#define GABBLE_ROOMLIST_CHANNEL_GET_PRIVATE(obj) \
-    ((GabbleRoomlistChannelPrivate *) obj->priv)
+#define GABBLE_ROOMLIST_CHANNEL_GET_PRIVATE(obj) ((obj)->priv)
 
 #define ROOM_SIGNAL_INTERVAL 300
 
diff --git a/src/roomlist-channel.h b/src/roomlist-channel.h
index 1bf44c2..1ce6e98 100644
--- a/src/roomlist-channel.h
+++ b/src/roomlist-channel.h
@@ -28,6 +28,7 @@
 G_BEGIN_DECLS
 
 typedef struct _GabbleRoomlistChannel GabbleRoomlistChannel;
+typedef struct _GabbleRoomlistChannelPrivate GabbleRoomlistChannelPrivate;
 typedef struct _GabbleRoomlistChannelClass GabbleRoomlistChannelClass;
 
 struct _GabbleRoomlistChannelClass {
@@ -39,7 +40,7 @@ struct _GabbleRoomlistChannelClass {
 struct _GabbleRoomlistChannel {
     GObject parent;
 
-    gpointer priv;
+    GabbleRoomlistChannelPrivate *priv;
 };
 
 GType gabble_roomlist_channel_get_type (void);
-- 
1.5.6.3




More information about the Telepathy-commits mailing list