[Bug 34181] New: Reinstate per-status callbacks in TpChannelManager
bugzilla-daemon at freedesktop.org
bugzilla-daemon at freedesktop.org
Fri Feb 11 17:02:26 CET 2011
https://bugs.freedesktop.org/show_bug.cgi?id=34181
Summary: Reinstate per-status callbacks in TpChannelManager
Product: Telepathy
Version: unspecified
Platform: Other
OS/Version: All
Status: NEW
Severity: normal
Priority: medium
Component: tp-glib
AssignedTo: telepathy-bugs at lists.freedesktop.org
ReportedBy: will.thompson at collabora.co.uk
QAContact: telepathy-bugs at lists.freedesktop.org
TpChannelFactoryIface had callbacks for the different states a connection can
move into (as discussed briefly on bug 17631). TpChannelManager doesn't, on the
basis that you can use :status-changed. While that's true, it means that pretty
much every single channel manager has code like this:
static void
connection_status_changed_cb (GabbleConnection *conn,
guint status,
guint reason,
GabbleFtManager *self)
{
switch (status)
{
case TP_CONNECTION_STATUS_CONNECTING:
g_signal_connect (self->priv->connection->jingle_factory,
"new-session",
G_CALLBACK (new_jingle_session_cb), self);
break;
case TP_CONNECTION_STATUS_DISCONNECTED:
ft_manager_close_all (self);
if (self->priv->status_changed_id != 0)
{
g_signal_handler_disconnect (self->priv->connection,
self->priv->status_changed_id);
self->priv->status_changed_id = 0;
}
break;
}
}
It would be nice if we could use a signal detail to connect different callbacks
to the different statuses. The signal's generated by dbus-glib, so I don't know
how much this is going to fly.
--
Configure bugmail: https://bugs.freedesktop.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the QA contact for the bug.
You are the assignee for the bug.
More information about the telepathy-bugs
mailing list