[Telepathy-commits] [telepathy-mission-control/master] Let the Dispatcher set a channel's dispatching status
Alberto Mardegan
alberto.mardegan at nokia.com
Mon Nov 17 00:05:17 PST 2008
Remove unnecessary duplication of code.
---
src/mcd-connection.c | 7 -------
src/mcd-dispatcher.c | 3 ++-
2 files changed, 2 insertions(+), 8 deletions(-)
diff --git a/src/mcd-connection.c b/src/mcd-connection.c
index 0149a6d..e32934e 100644
--- a/src/mcd-connection.c
+++ b/src/mcd-connection.c
@@ -585,9 +585,6 @@ on_new_channel (TpConnection *proxy, const gchar *chan_obj_path,
if (priv->can_dispatch)
{
- /* Channel about to be dispatched */
- mcd_channel_set_status (channel, MCD_CHANNEL_DISPATCHING);
-
/* Dispatch the incoming channel */
mcd_dispatcher_send (priv->dispatcher, channel);
}
@@ -1270,7 +1267,6 @@ dispatch_undispatched_channels (McdConnection *connection)
{
g_debug ("Dispatching channel %p", channel);
/* dispatch the channel */
- mcd_channel_set_status (channel, MCD_CHANNEL_DISPATCHING);
mcd_dispatcher_send (priv->dispatcher, channel);
}
channels = channels->next;
@@ -1956,9 +1952,6 @@ request_channel_cb (TpConnection *proxy, const gchar *channel_path,
return;
}
- /* Channel about to be dispatched */
- mcd_channel_set_status (channel, MCD_CHANNEL_DISPATCHING);
-
/* Dispatch the incoming channel */
mcd_dispatcher_send (priv->dispatcher, channel);
}
diff --git a/src/mcd-dispatcher.c b/src/mcd-dispatcher.c
index 279dfc3..46955f6 100644
--- a/src/mcd-dispatcher.c
+++ b/src/mcd-dispatcher.c
@@ -817,7 +817,8 @@ _mcd_dispatcher_send (McdDispatcher * dispatcher, McdChannel * channel)
McdDispatcherPrivate *priv;
g_return_if_fail (MCD_IS_DISPATCHER (dispatcher));
g_return_if_fail (MCD_IS_CHANNEL (channel));
-
+
+ mcd_channel_set_status (channel, MCD_CHANNEL_DISPATCHING);
priv = MCD_DISPATCHER_PRIV (dispatcher);
/* it can happen that this function gets called when the same channel has
--
1.5.6.5
More information about the Telepathy-commits
mailing list