diff options
author | Will Thompson <will.thompson@collabora.co.uk> | 2012-11-09 14:15:10 +0000 |
---|---|---|
committer | Will Thompson <will.thompson@collabora.co.uk> | 2012-11-09 14:15:10 +0000 |
commit | 8a3a8ba64195afd03c291282233d3b28abfd85d2 (patch) | |
tree | b2e0300cf3bc1fbc194c5046f72b32cfc9e167a4 | |
parent | 2a81f262441270e8f5b2bd85c5f783dff03d3547 (diff) |
im-manager: use tp_base_channel_is_destroyed()
This is equivalent but neater.
-rw-r--r-- | src/idle-im-manager.c | 11 |
1 files changed, 3 insertions, 8 deletions
diff --git a/src/idle-im-manager.c b/src/idle-im-manager.c index 1d3a73c..71fe7a0 100644 --- a/src/idle-im-manager.c +++ b/src/idle-im-manager.c @@ -387,21 +387,16 @@ _im_channel_closed_cb (IdleIMChannel *chan, { IdleIMManager *self = IDLE_IM_MANAGER (user_data); IdleIMManagerPrivate *priv = IDLE_IM_MANAGER_GET_PRIVATE (self); - TpHandle handle; + TpBaseChannel *base = TP_BASE_CHANNEL (chan); tp_channel_manager_emit_channel_closed_for_object (self, TP_EXPORTABLE_CHANNEL (chan)); if (priv->channels) { - gboolean really_destroyed; - - g_object_get (chan, - "handle", &handle, - "channel-destroyed", &really_destroyed, - NULL); + TpHandle handle = tp_base_channel_get_target_handle (base); - if (really_destroyed) + if (tp_base_channel_is_destroyed (base)) { IDLE_DEBUG ("removing channel with handle %u", handle); g_hash_table_remove (priv->channels, GUINT_TO_POINTER (handle)); |