diff options
author | Danielle Madeley <danielle.madeley@collabora.co.uk> | 2009-12-21 07:21:11 +0800 |
---|---|---|
committer | Danielle Madeley <danielle.madeley@collabora.co.uk> | 2009-12-21 17:55:03 +0800 |
commit | 79074c4ba575f4b01782f6f498a3e9f91cd7ba21 (patch) | |
tree | 42964f5d089cf89aa254b58dec6c84106c78605b /src | |
parent | 845c851672bb392dd265cd63afde325ed1dfad49 (diff) | |
download | gsoc2013-empathy-79074c4ba575f4b01782f6f498a3e9f91cd7ba21.tar gsoc2013-empathy-79074c4ba575f4b01782f6f498a3e9f91cd7ba21.tar.gz gsoc2013-empathy-79074c4ba575f4b01782f6f498a3e9f91cd7ba21.tar.bz2 gsoc2013-empathy-79074c4ba575f4b01782f6f498a3e9f91cd7ba21.tar.lz gsoc2013-empathy-79074c4ba575f4b01782f6f498a3e9f91cd7ba21.tar.xz gsoc2013-empathy-79074c4ba575f4b01782f6f498a3e9f91cd7ba21.tar.zst gsoc2013-empathy-79074c4ba575f4b01782f6f498a3e9f91cd7ba21.zip |
Replace raw Tp call with existing abstraction in EmpathyTpChat
Diffstat (limited to 'src')
-rw-r--r-- | src/empathy-chat-window.c | 14 |
1 files changed, 5 insertions, 9 deletions
diff --git a/src/empathy-chat-window.c b/src/empathy-chat-window.c index 240dc4b68..5e0ad049c 100644 --- a/src/empathy-chat-window.c +++ b/src/empathy-chat-window.c @@ -43,6 +43,7 @@ #include <libempathy/empathy-chatroom-manager.h> #include <libempathy/empathy-utils.h> #include <libempathy/empathy-tp-contact-factory.h> +#include <libempathy/empathy-contact-list.h> #include <libempathy-gtk/empathy-images.h> #include <libempathy-gtk/empathy-conf.h> @@ -873,7 +874,7 @@ got_contact_cb (EmpathyTpContactFactory *factory, gpointer user_data, GObject *object) { - TpChannel *channel = TP_CHANNEL (user_data); + EmpathyTpChat *tp_chat = EMPATHY_TP_CHAT (user_data); if (error != NULL) { @@ -882,13 +883,8 @@ got_contact_cb (EmpathyTpContactFactory *factory, } else { - TpHandle handle = empathy_contact_get_handle (contact); - GArray handles = {(gchar *) &handle, 1}; - - tp_cli_channel_interface_group_call_add_members ( - channel, -1, &handles, - _("Inviting to this room"), - NULL, NULL, NULL, NULL); + empathy_contact_list_add (EMPATHY_CONTACT_LIST (tp_chat), + contact, _("Inviting you to this room")); } } @@ -941,7 +937,7 @@ chat_window_invite_participant_activate_cb (GtkAction *action, factory = empathy_tp_contact_factory_dup_singleton (connection); empathy_tp_contact_factory_get_from_id (factory, id, - got_contact_cb, channel, NULL, NULL); + got_contact_cb, tp_chat, NULL, NULL); g_object_unref (factory); |