From c7d9d98acf3a02b6f094a952105e858d2bd425ad Mon Sep 17 00:00:00 2001 From: Ed Page Date: Sat, 3 Oct 2009 18:16:42 -0500 Subject: [PATCH] Forcing an initial announcing of existing contacts --- src/channel/contact_list.py | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/src/channel/contact_list.py b/src/channel/contact_list.py index b51a050..301e95b 100644 --- a/src/channel/contact_list.py +++ b/src/channel/contact_list.py @@ -35,6 +35,10 @@ class AllContactsListChannel(AbstractListChannel): ) self.GroupFlagsChanged(0, 0) + addressbook = connection.session.addressbook + contacts = addressbook.get_contacts() + self._process_refresh(addressbook, contacts, []) + @coroutines.func_sink @coroutines.expand_positional @gobject_utils.async @@ -45,6 +49,9 @@ class AllContactsListChannel(AbstractListChannel): @todo This currently does not handle people with multiple phone numbers, yay that'll be annoying to resolve """ + self._process_refresh(addressbook, added, removed) + + def _process_refresh(self, addressbook, added, removed): connection = self._conn handlesAdded = [ handle.create_handle(connection, "contact", contactId) -- 1.7.9.5