[empathy] dispatch-operation: factor out channel_wrapper_ready
- From: Guillaume Desmottes <gdesmott src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [empathy] dispatch-operation: factor out channel_wrapper_ready
- Date: Mon, 7 Jun 2010 11:03:07 +0000 (UTC)
commit 63b5db096a4a8e706bf9d2b7043aa6c9fe5d5697
Author: Guillaume Desmottes <guillaume desmottes collabora co uk>
Date: Mon Jun 7 12:24:06 2010 +0200
dispatch-operation: factor out channel_wrapper_ready
libempathy/empathy-dispatch-operation.c | 18 +++++++++++++-----
1 files changed, 13 insertions(+), 5 deletions(-)
---
diff --git a/libempathy/empathy-dispatch-operation.c b/libempathy/empathy-dispatch-operation.c
index f6cc0d6..68143c5 100644
--- a/libempathy/empathy-dispatch-operation.c
+++ b/libempathy/empathy-dispatch-operation.c
@@ -433,6 +433,18 @@ empathy_dispatch_operation_set_status (EmpathyDispatchOperation *self,
}
static void
+channel_wrapper_ready (EmpathyDispatchOperation *self)
+{
+ EmpathyDispatchOperationPriv *priv = GET_PRIV (self);
+
+ g_signal_handler_disconnect (priv->channel_wrapper, priv->ready_handler);
+ priv->ready_handler = 0;
+
+ empathy_dispatch_operation_set_status (self,
+ EMPATHY_DISPATCHER_OPERATION_STATE_PENDING);
+}
+
+static void
empathy_dispatcher_operation_tp_chat_ready_cb (GObject *object,
GParamSpec *spec, gpointer user_data)
{
@@ -442,11 +454,7 @@ empathy_dispatcher_operation_tp_chat_ready_cb (GObject *object,
if (!empathy_tp_chat_is_ready (EMPATHY_TP_CHAT (priv->channel_wrapper)))
return;
- g_signal_handler_disconnect (priv->channel_wrapper, priv->ready_handler);
- priv->ready_handler = 0;
-
- empathy_dispatch_operation_set_status (self,
- EMPATHY_DISPATCHER_OPERATION_STATE_PENDING);
+ channel_wrapper_ready (self);
}
static void
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]