comparison sat_bridge/DBus.py @ 101:783e9d6980ec

Couchsurfing plugin: first draft SàT core: adding additionnal menu method bridge: new methods getMenus, getMenuHelp and callMenu wix: new menu are added on startup CS plugin: login on CS
author Goffi <goffi@goffi.org>
date Sat, 19 Jun 2010 17:15:30 +0800
parents 23caf1051099
children d2630fba8dfd
comparison
equal deleted inserted replaced
100:50f1591c8fc6 101:783e9d6980ec
246 in_signature='s', out_signature='a{ss}') 246 in_signature='s', out_signature='a{ss}')
247 def getProgress(self, id): 247 def getProgress(self, id):
248 #debug("Progress asked for %s", id) 248 #debug("Progress asked for %s", id)
249 return self.cb["getProgress"](id) 249 return self.cb["getProgress"](id)
250 250
251 @dbus.service.method(const_INT_PREFIX+const_REQ_SUFFIX,
252 in_signature='', out_signature='a(sss)')
253 def getMenus(self):
254 return self.cb["getMenus"]()
255
256 @dbus.service.method(const_INT_PREFIX+const_REQ_SUFFIX,
257 in_signature='sss', out_signature='s')
258 def getMenuHelp(self, category, name, type="NORMAL"):
259 return self.cb["getMenuHelp"](category, name, type)
260
261 @dbus.service.method(const_INT_PREFIX+const_REQ_SUFFIX,
262 in_signature='ssss', out_signature='s')
263 def callMenu(self, category, name, type, profile_key):
264 return self.cb["callMenu"](category, name, type, profile_key)
265
251 def __attribute_string(self, in_sign): 266 def __attribute_string(self, in_sign):
252 i=0 267 i=0
253 idx=0 268 idx=0
254 attr_string="" 269 attr_string=""
255 while i<len(in_sign): 270 while i<len(in_sign):