empathy r2347 - in trunk: libempathy-gtk tests



Author: xclaesse
Date: Fri Jan 30 17:35:12 2009
New Revision: 2347
URL: http://svn.gnome.org/viewvc/empathy?rev=2347&view=rev

Log:
Make empathy_contact_selector_new return a GtkWidget* to conform to GTK+.

Signed-off-by: Jonny Lamb <jonny lamb collabora co uk>

Modified:
   trunk/libempathy-gtk/empathy-contact-selector.c
   trunk/libempathy-gtk/empathy-contact-selector.h
   trunk/tests/empetit.c

Modified: trunk/libempathy-gtk/empathy-contact-selector.c
==============================================================================
--- trunk/libempathy-gtk/empathy-contact-selector.c	(original)
+++ trunk/libempathy-gtk/empathy-contact-selector.c	Fri Jan 30 17:35:12 2009
@@ -334,12 +334,12 @@
 
 /* public methods */
 
-EmpathyContactSelector *
+GtkWidget *
 empathy_contact_selector_new (EmpathyContactListStore *store)
 {
   g_return_val_if_fail (EMPATHY_IS_CONTACT_LIST_STORE (store), NULL);
 
-  return g_object_new (EMPATHY_TYPE_CONTACT_SELECTOR, "store", store, NULL);
+  return GTK_WIDGET (g_object_new (EMPATHY_TYPE_CONTACT_SELECTOR, "store", store, NULL));
 }
 
 EmpathyContact *

Modified: trunk/libempathy-gtk/empathy-contact-selector.h
==============================================================================
--- trunk/libempathy-gtk/empathy-contact-selector.h	(original)
+++ trunk/libempathy-gtk/empathy-contact-selector.h	Fri Jan 30 17:35:12 2009
@@ -58,7 +58,7 @@
 };
 
 GType empathy_contact_selector_get_type (void) G_GNUC_CONST;
-EmpathyContactSelector *
+GtkWidget *
 empathy_contact_selector_new (EmpathyContactListStore *store);
 
 EmpathyContact *

Modified: trunk/tests/empetit.c
==============================================================================
--- trunk/tests/empetit.c	(original)
+++ trunk/tests/empetit.c	Fri Jan 30 17:35:12 2009
@@ -53,8 +53,7 @@
 {
   EmpathyContactManager *manager;
   EmpathyContactListStore *store;
-  EmpathyContactSelector *selector;
-  GtkWidget *vbox, *button;
+  GtkWidget *vbox, *button, *selector;
   gchar *icon_path;
 
   gtk_init (&argc, &argv);
@@ -69,7 +68,7 @@
   vbox = gtk_vbox_new (FALSE, 2);
 
   selector = empathy_contact_selector_new (store);
-  gtk_box_pack_start (GTK_BOX (vbox), GTK_WIDGET (selector), FALSE, FALSE, 5);
+  gtk_box_pack_start (GTK_BOX (vbox), selector, FALSE, FALSE, 5);
 
   button = gtk_button_new_with_label ("Chat");
   g_signal_connect (G_OBJECT (button), "clicked",



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]