Mercurial > libervia-backend
diff frontends/src/bridge/DBus.py @ 337:4402ac630712
bridge: async callback managed in bridge_constructor + misc
- the new flag async make the method asynchronous
- new method asyncConnect (connect which return when the user is connected)
- setMicroblogAccess added to DBus frontend
author | Goffi <goffi@goffi.org> |
---|---|
date | Thu, 26 May 2011 16:47:09 +0200 |
parents | 953536246d9d |
children | e6047415868d |
line wrap: on
line diff
--- a/frontends/src/bridge/DBus.py Wed May 25 17:18:05 2011 +0200 +++ b/frontends/src/bridge/DBus.py Thu May 26 16:47:09 2011 +0200 @@ -52,6 +52,9 @@ def addContact(self, entity, profile_key="@DEFAULT@"): return self.db_comm_iface.addContact(entity, profile_key) + def asyncConnect(self, profile_key="@DEFAULT@", callback=None, errback=None): + return self.db_comm_iface.asyncConnect(profile_key, reply_handler=callback, error_handler=errback) + def callMenu(self, category, name, menu_type, profile_key): return unicode(self.db_req_iface.callMenu(category, name, menu_type, profile_key)) @@ -199,3 +202,6 @@ def sendPersonalEvent(self, event_type, data, profile_key='@DEFAULT@'): return self.db_comm_iface.sendPersonalEvent(event_type, data, profile_key) + + def setMicroblogAccess(self, access="presence", profile_key='@DEFAULT@', callback=None, errback=None): + return self.db_comm_iface.setMicroblogAccess(access, profile_key, reply_handler=callback, error_handler=errback)