From f171143fe0237fe649b8498203e67d06e1cd0146 Mon Sep 17 00:00:00 2001 From: Boris billiob Faure Date: Tue, 21 Apr 2009 23:54:17 +0200 Subject: [PATCH] Strip text from efl entry --- amsn2/core/amsn.py | 2 +- amsn2/gui/front_ends/efl/login.py | 6 ++++-- 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/amsn2/core/amsn.py b/amsn2/core/amsn.py index 2971e184..69250283 100644 --- a/amsn2/core/amsn.py +++ b/amsn2/core/amsn.py @@ -125,7 +125,7 @@ def addProfile(self, account): return self._profile_manager.addProfile(account) def signinToAccount(self, login_window, profile): - print "Signing in to account %s" % (profile.email) + print "Signing in to account '%s'" % (profile.email) profile.login = login_window profile.client = protocol.Client(self, profile) self._profile = profile diff --git a/amsn2/gui/front_ends/efl/login.py b/amsn2/gui/front_ends/efl/login.py index b94bc604..82763746 100644 --- a/amsn2/gui/front_ends/efl/login.py +++ b/amsn2/gui/front_ends/efl/login.py @@ -83,9 +83,11 @@ def switch_to_profile(self, profile): def signin(self): - self.current_profile.username = elementary.Entry.markup_to_utf8(self.username.entry_get()) + self.current_profile.username = \ + elementary.Entry.markup_to_utf8(self.username.entry_get()).strip() self.current_profile.email = self.current_profile.username - self.current_profile.password = elementary.Entry.markup_to_utf8(self.password.entry_get()) + self.current_profile.password = \ + elementary.Entry.markup_to_utf8(self.password.entry_get()).strip() self._amsn_core.signinToAccount(self, self.current_profile) def onConnecting(self, progress, message):