aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorGuillaume Desmottes <guillaume.desmottes@collabora.co.uk>2010-08-18 21:14:44 +0800
committerGuillaume Desmottes <guillaume.desmottes@collabora.co.uk>2010-08-18 21:14:44 +0800
commit12edcf477eaf0bd6a2c9307e2d82a0c1383646d8 (patch)
tree5a929a057f0b09a3d0e4519867954a9b0d626d9c /src
parent2b47047e4493f4ea950d9ecbe4174a0553812d3e (diff)
downloadgsoc2013-empathy-12edcf477eaf0bd6a2c9307e2d82a0c1383646d8.tar
gsoc2013-empathy-12edcf477eaf0bd6a2c9307e2d82a0c1383646d8.tar.gz
gsoc2013-empathy-12edcf477eaf0bd6a2c9307e2d82a0c1383646d8.tar.bz2
gsoc2013-empathy-12edcf477eaf0bd6a2c9307e2d82a0c1383646d8.tar.lz
gsoc2013-empathy-12edcf477eaf0bd6a2c9307e2d82a0c1383646d8.tar.xz
gsoc2013-empathy-12edcf477eaf0bd6a2c9307e2d82a0c1383646d8.tar.zst
gsoc2013-empathy-12edcf477eaf0bd6a2c9307e2d82a0c1383646d8.zip
factor out display_invite_room_dialog
Diffstat (limited to 'src')
-rw-r--r--src/empathy-event-manager.c37
1 files changed, 22 insertions, 15 deletions
diff --git a/src/empathy-event-manager.c b/src/empathy-event-manager.c
index 39d70e6d1..3139c503e 100644
--- a/src/empathy-event-manager.c
+++ b/src/empathy-event-manager.c
@@ -727,27 +727,13 @@ event_room_channel_process_func (EventPriv *event)
}
static void
-event_manager_muc_invite_got_contact_cb (TpConnection *connection,
- EmpathyContact *contact,
- const GError *error,
- gpointer user_data,
- GObject *object)
+display_invite_room_dialog (EventManagerApproval *approval)
{
- EventManagerApproval *approval = (EventManagerApproval *) user_data;
GtkWidget *window = empathy_main_window_dup ();
const gchar *invite_msg;
gchar *msg;
TpHandle self_handle;
- if (error != NULL)
- {
- /* FIXME: We should probably still display the event */
- DEBUG ("Error: %s", error->message);
- return;
- }
-
- approval->contact = g_object_ref (contact);
-
self_handle = tp_channel_group_get_self_handle (approval->main_channel);
tp_channel_group_get_local_pending_info (approval->main_channel, self_handle,
NULL, NULL, &invite_msg);
@@ -767,6 +753,27 @@ event_manager_muc_invite_got_contact_cb (TpConnection *connection,
}
static void
+event_manager_muc_invite_got_contact_cb (TpConnection *connection,
+ EmpathyContact *contact,
+ const GError *error,
+ gpointer user_data,
+ GObject *object)
+{
+ EventManagerApproval *approval = (EventManagerApproval *) user_data;
+
+ if (error != NULL)
+ {
+ /* FIXME: We should probably still display the event */
+ DEBUG ("Error: %s", error->message);
+ return;
+ }
+
+ approval->contact = g_object_ref (contact);
+
+ display_invite_room_dialog (approval);
+}
+
+static void
event_manager_ft_got_contact_cb (TpConnection *connection,
EmpathyContact *contact,
const GError *error,