comparison sat.tac @ 36:6491b7956c80

wix: Form submitting, first draft
author Goffi <goffi@goffi.org>
date Mon, 14 Dec 2009 02:11:05 +1100
parents b9bb5d8e0cc7
children a61beb21d16d
comparison
equal deleted inserted replaced
35:c45deebb40a5 36:6491b7956c80
276 self.bridge.register("addContact", self.addContact) 276 self.bridge.register("addContact", self.addContact)
277 self.bridge.register("delContact", self.delContact) 277 self.bridge.register("delContact", self.delContact)
278 self.bridge.register("isConnected", self.isConnected) 278 self.bridge.register("isConnected", self.isConnected)
279 self.bridge.register("launchAction", self.launchAction) 279 self.bridge.register("launchAction", self.launchAction)
280 self.bridge.register("confirmationAnswer", self.confirmationAnswer) 280 self.bridge.register("confirmationAnswer", self.confirmationAnswer)
281 self.bridge.register("submitForm", self.submitForm)
281 self.bridge.register("getProgress", self.getProgress) 282 self.bridge.register("getProgress", self.getProgress)
282 283
283 self._import_plugins() 284 self._import_plugins()
284 285
285 286
415 server = self.memory.getParamA("Server", "Connection") 416 server = self.memory.getParamA("Server", "Connection")
416 if accepted: 417 if accepted:
417 self.registerNewAccount(user, password, server, id=action_id) 418 self.registerNewAccount(user, password, server, id=action_id)
418 else: 419 else:
419 self.actionResult(action_id, "SUPPRESS", {}) 420 self.actionResult(action_id, "SUPPRESS", {})
421
422 def submitForm(self, target, fields):
423 """Called when a form is submited"""
424 to_jid = jid.JID(target)
425 print "Form submitted !", fields
426 return self.get_next_id()
420 427
421 ## Client management ## 428 ## Client management ##
422 429
423 def setParam(self, name, value, category): 430 def setParam(self, name, value, category):
424 """set wanted paramater and notice observers""" 431 """set wanted paramater and notice observers"""