Primitivus: fixed redraw on profile change in profile manager

This commit is contained in:
Goffi 2011-12-04 00:05:41 +01:00
commit 9410e81551

View file

@ -108,14 +108,15 @@ class ProfileManager(urwid.WidgetWrap):
def onProfileChange(self, list_wid):
def setJID(jabberID):
self.login_wid.set_edit_text(jabberID)
self.host.redraw()
def setPassword(password):
self.pass_wid.set_edit_text(password)
self.host.redraw()
profile_name = list_wid.getSelectedValue()
if profile_name:
self.host.bridge.asyncGetParamA("JabberID", "Connection", profile_key=profile_name, callback=setJID, errback=self.getParamError)
self.host.bridge.asyncGetParamA("Password", "Connection", profile_key=profile_name, callback=setPassword, errback=self.getParamError)
self.host.redraw()
def onConnectProfile(self, button):
profile_name = self.list_profile.getSelectedValue()