aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJonny Lamb <jonny.lamb@collabora.co.uk>2009-01-31 01:35:12 +0800
committerXavier Claessens <xclaesse@src.gnome.org>2009-01-31 01:35:12 +0800
commit1c17073f1f3156c8746ca9ef149435e1328193fa (patch)
tree3cf73df64f72fbbdf35888caca388dcba065c3f8
parentbb1f7649fc6cbba1722ff57fc2017810b2cf6578 (diff)
downloadgsoc2013-empathy-1c17073f1f3156c8746ca9ef149435e1328193fa.tar
gsoc2013-empathy-1c17073f1f3156c8746ca9ef149435e1328193fa.tar.gz
gsoc2013-empathy-1c17073f1f3156c8746ca9ef149435e1328193fa.tar.bz2
gsoc2013-empathy-1c17073f1f3156c8746ca9ef149435e1328193fa.tar.lz
gsoc2013-empathy-1c17073f1f3156c8746ca9ef149435e1328193fa.tar.xz
gsoc2013-empathy-1c17073f1f3156c8746ca9ef149435e1328193fa.tar.zst
gsoc2013-empathy-1c17073f1f3156c8746ca9ef149435e1328193fa.zip
Make empathy_contact_selector_new return a GtkWidget* to conform to GTK+.
Signed-off-by: Jonny Lamb <jonny.lamb@collabora.co.uk> svn path=/trunk/; revision=2347
-rw-r--r--libempathy-gtk/empathy-contact-selector.c4
-rw-r--r--libempathy-gtk/empathy-contact-selector.h2
-rw-r--r--tests/empetit.c5
3 files changed, 5 insertions, 6 deletions
diff --git a/libempathy-gtk/empathy-contact-selector.c b/libempathy-gtk/empathy-contact-selector.c
index aafffdc84..eb1e67689 100644
--- a/libempathy-gtk/empathy-contact-selector.c
+++ b/libempathy-gtk/empathy-contact-selector.c
@@ -334,12 +334,12 @@ empathy_contact_selector_class_init (EmpathyContactSelectorClass *klass)
/* 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 *
diff --git a/libempathy-gtk/empathy-contact-selector.h b/libempathy-gtk/empathy-contact-selector.h
index 1418f7cd3..238cbbbb9 100644
--- a/libempathy-gtk/empathy-contact-selector.h
+++ b/libempathy-gtk/empathy-contact-selector.h
@@ -58,7 +58,7 @@ struct _EmpathyContactSelectorClass
};
GType empathy_contact_selector_get_type (void) G_GNUC_CONST;
-EmpathyContactSelector *
+GtkWidget *
empathy_contact_selector_new (EmpathyContactListStore *store);
EmpathyContact *
diff --git a/tests/empetit.c b/tests/empetit.c
index 5a091a75d..14a813034 100644
--- a/tests/empetit.c
+++ b/tests/empetit.c
@@ -53,8 +53,7 @@ int main (int argc,
{
EmpathyContactManager *manager;
EmpathyContactListStore *store;
- EmpathyContactSelector *selector;
- GtkWidget *vbox, *button;
+ GtkWidget *vbox, *button, *selector;
gchar *icon_path;
gtk_init (&argc, &argv);
@@ -69,7 +68,7 @@ int main (int argc,
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",