added action cb mechanism for buttons. Tested with a temporary new user registration button.

This commit is contained in:
Goffi 2009-12-01 04:56:08 +01:00
commit a103e8b41b

View file

@ -40,12 +40,14 @@ class QuickApp():
self.bridge.register("paramUpdate", self.paramUpdate)
self.bridge.register("contactDeleted", self.contactDeleted)
self.bridge.register("askConfirmation", self.askConfirmation, "request")
self.bridge.register("actionResult", self.actionResult, "request")
###now we get the essential params###
self.whoami=JID(self.bridge.getParamV("JabberID","Connection"))
self.watched=self.bridge.getParamV("Watched", "Misc").split() #TODO: put this in a plugin
self.whoami=JID(self.bridge.getParamA("JabberID","Connection"))
self.watched=self.bridge.getParamA("Watched", "Misc").split() #TODO: put this in a plugin
## misc ##
self.current_action_ids = set()
self.onlineContact = set() #FIXME: temporary
if self.bridge.isConnected():
@ -156,3 +158,6 @@ class QuickApp():
def askConfirmation(self, type, id, data):
raise NotImplementedError
def actionResult(self, type, id, data):
raise NotImplementedError