[MERGE] Add get_username() call to the UIFactory.
Gary van der Merwe
garyvdm at gmail.com
Wed Apr 1 20:36:10 BST 2009
bb:coment
+ def get_username(self, prompt, **kwargs):
+ """Prompt the user for a password.
Should that not be :
+ def get_username(self, prompt, **kwargs):
+ """Prompt the user for a user name.
Typical, GUI's will ask for a user name and password with one dialog
box. I'm not sure how one would implement that with this api. I guess
that you could show a dialog that asks for a user name and password
when get_username is called, store the password, and return that
password when get_password is called. But how would you safely match
get_username and get_password calls. It would be much easier if you
had a method for both user name and password. E.g.:
+ def get_username_password(self, prompt, **kwargs):
+ """Prompt the user for a username and password.
...
+ :return:(username, password), return None if the user
+ canceled the request.
Gary
More information about the bazaar
mailing list