diff options
author | Guillaume Desmottes <guillaume.desmottes@collabora.co.uk> | 2008-02-13 15:55:01 (GMT) |
---|---|---|
committer | Morgan Collett <morgan.collett@gmail.com> | 2008-02-15 12:06:18 (GMT) |
commit | 8b67ad6cf441aed167d9edd41f80c2d66bc247e5 (patch) | |
tree | 79b9da7cdecede5d44b2c772b5ae98be6d659c95 | |
parent | 0b007af8959c162ab6254a0c0ab9d0b7c0c4fd58 (diff) |
remove duplicated start method and be sure we are connected to the address-changed signal when starting the plugin
-rw-r--r-- | src/telepathy_plugin.py | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/src/telepathy_plugin.py b/src/telepathy_plugin.py index 5131c9c..0fb4b05 100644 --- a/src/telepathy_plugin.py +++ b/src/telepathy_plugin.py @@ -163,9 +163,6 @@ class TelepathyPlugin(gobject.GObject): """ raise NotImplementedError - def start(self): - raise NotImplementedError - def suggest_room_for_activity(self, activity_id): """Suggest a room to use to share the given activity. """ @@ -340,6 +337,7 @@ class TelepathyPlugin(gobject.GObject): self._backoff_id = 0 self._ip4am.disconnect(self._ip4am_sigid) + self._ip4am_sigid = 0 def _contacts_offline(self, handles): """Handle contacts going offline (send message, update set)""" @@ -544,6 +542,11 @@ class TelepathyPlugin(gobject.GObject): otherwise initiate a connection and transfer control to _connect_reply_cb or _connect_error_cb """ + + if self._ip4am_sigid == 0: + self._ip4am_sigid = self._ip4am.connect('address-changed', + self._ip4_address_changed_cb) + if self._conn is not None: return |