aboutsummaryrefslogtreecommitdiffstats
path: root/src/empathy-chat-window.c
diff options
context:
space:
mode:
authorXavier Claessens <xclaesse@src.gnome.org>2008-05-06 04:34:41 +0800
committerXavier Claessens <xclaesse@src.gnome.org>2008-05-06 04:34:41 +0800
commit1557095113a3c0f5baadcfb1e953d73762e5263e (patch)
tree6af706fb1f4f673120981e033768a09169544c11 /src/empathy-chat-window.c
parent62828fac680bd53e0047d9ae2a281c864075c809 (diff)
downloadgsoc2013-empathy-1557095113a3c0f5baadcfb1e953d73762e5263e.tar
gsoc2013-empathy-1557095113a3c0f5baadcfb1e953d73762e5263e.tar.gz
gsoc2013-empathy-1557095113a3c0f5baadcfb1e953d73762e5263e.tar.bz2
gsoc2013-empathy-1557095113a3c0f5baadcfb1e953d73762e5263e.tar.lz
gsoc2013-empathy-1557095113a3c0f5baadcfb1e953d73762e5263e.tar.xz
gsoc2013-empathy-1557095113a3c0f5baadcfb1e953d73762e5263e.tar.zst
gsoc2013-empathy-1557095113a3c0f5baadcfb1e953d73762e5263e.zip
Keep a priv pointer in the object struct instead of using G_TYPE_INSTANCE_GET_PRIVATE all the time.
svn path=/trunk/; revision=1082
Diffstat (limited to 'src/empathy-chat-window.c')
-rw-r--r--src/empathy-chat-window.c31
1 files changed, 15 insertions, 16 deletions
diff --git a/src/empathy-chat-window.c b/src/empathy-chat-window.c
index bb8960479..a43e524cd 100644
--- a/src/empathy-chat-window.c
+++ b/src/empathy-chat-window.c
@@ -55,9 +55,8 @@
#define DEBUG_FLAG EMPATHY_DEBUG_CHAT
#include <libempathy/empathy-debug.h>
-#define GET_PRIV(obj) (G_TYPE_INSTANCE_GET_PRIVATE ((obj), EMPATHY_TYPE_CHAT_WINDOW, EmpathyChatWindowPriv))
-
-struct _EmpathyChatWindowPriv {
+#define GET_PRIV(obj) EMPATHY_GET_PRIV (obj, EmpathyChatWindow)
+typedef struct {
EmpathyChat *current_chat;
GList *chats;
GList *chats_new_msg;
@@ -86,7 +85,7 @@ struct _EmpathyChatWindowPriv {
GtkWidget *menu_help_contents;
GtkWidget *menu_help_about;
-};
+} EmpathyChatWindowPriv;
static GList *chat_windows = NULL;
@@ -1090,18 +1089,18 @@ empathy_chat_window_class_init (EmpathyChatWindowClass *klass)
static void
empathy_chat_window_init (EmpathyChatWindow *window)
{
- EmpathyChatWindowPriv *priv;
- GladeXML *glade;
- GtkAccelGroup *accel_group;
- GClosure *closure;
- GtkWidget *menu_conv;
- GtkWidget *menu;
- gint i;
- GtkWidget *chat_vbox;
- gchar *filename;
-
- priv = GET_PRIV (window);
-
+ GladeXML *glade;
+ GtkAccelGroup *accel_group;
+ GClosure *closure;
+ GtkWidget *menu_conv;
+ GtkWidget *menu;
+ gint i;
+ GtkWidget *chat_vbox;
+ gchar *filename;
+ EmpathyChatWindowPriv *priv = G_TYPE_INSTANCE_GET_PRIVATE (window,
+ EMPATHY_TYPE_CHAT_WINDOW, EmpathyChatWindowPriv);
+
+ window->priv = priv;
filename = empathy_file_lookup ("empathy-chat-window.glade", "src");
glade = empathy_glade_get_file (filename,
"chat_window",