comparison libervia.py @ 316:4148f8f4caa0

browser_side: fix import and method signatures relative to changeset e4f586fc6101
author souliane <souliane@mailoo.org>
date Fri, 03 Jan 2014 13:33:44 +0100
parents 5ad70625867a
children bbadd490e63c
comparison
equal deleted inserted replaced
315:09205b410a53 316:4148f8f4caa0
31 from browser_side.contact import ContactPanel 31 from browser_side.contact import ContactPanel
32 from browser_side.base_widget import WidgetsPanel 32 from browser_side.base_widget import WidgetsPanel
33 from browser_side.panels import MicroblogItem 33 from browser_side.panels import MicroblogItem
34 from browser_side import panels, dialog 34 from browser_side import panels, dialog
35 from browser_side.jid import JID 35 from browser_side.jid import JID
36 from browser_side.xmlui import XMLUI
36 from browser_side.tools import html_sanitize 37 from browser_side.tools import html_sanitize
37 from sat_frontends.tools.misc import InputHistory 38 from sat_frontends.tools.misc import InputHistory
38 from sat_frontends.tools.strings import getURLParams 39 from sat_frontends.tools.strings import getURLParams
39 from sat_frontends.constants import Const 40 from sat_frontends.constants import Const
40 41
345 else: 346 else:
346 # this would eventually set the browser saved password 347 # this would eventually set the browser saved password
347 Timer(5, lambda: self._register_box._form.login_pass_box.setFocus(True)) 348 Timer(5, lambda: self._register_box._form.login_pass_box.setFocus(True))
348 349
349 350
350 def _actionCb(data): 351 def _actionCb(self, data):
351 if not data: 352 if not data:
352 # action was a one shot, nothing to do 353 # action was a one shot, nothing to do
353 pass 354 pass
354 elif "xmlui" in data: 355 elif "xmlui" in data:
355 ui = XMLUI(self, xml_data = data['xmlui']) 356 ui = XMLUI(self, xml_data = data['xmlui'])
359 _dialog.show() 360 _dialog.show()
360 else: 361 else:
361 dialog.InfoDialog("Error", 362 dialog.InfoDialog("Error",
362 "Unmanaged action result", Width="400px").center() 363 "Unmanaged action result", Width="400px").center()
363 364
364 def _actionEb(err_data): 365 def _actionEb(self, err_data):
365 err_code, err_obj = err_data 366 err_code, err_obj = err_data
366 dialog.InfoDialog("Error", 367 dialog.InfoDialog("Error",
367 str(err_obj), Width="400px").center() 368 str(err_obj), Width="400px").center()
368 369
369 def launchAction(self, callback_id, data): 370 def launchAction(self, callback_id, data):