From 1ff4b9088d0b86a020142df1f624ea8a5b9dec27 Mon Sep 17 00:00:00 2001 From: Rom Walton Date: Tue, 31 Jan 2006 07:31:16 +0000 Subject: [PATCH] *** empty log message *** svn path=/trunk/boinc/; revision=9360 --- checkin_notes | 7 +++++++ clientgui/AccountInfoPage.cpp | 5 ++++- 2 files changed, 11 insertions(+), 1 deletion(-) diff --git a/checkin_notes b/checkin_notes index c51aa7bbae..31809a1f90 100755 --- a/checkin_notes +++ b/checkin_notes @@ -1193,4 +1193,11 @@ Charlie 30 Jan 2006 mac_build/ Info.plist + + Rom 31 Jan 2006 + - Bug Fix: If the wizard is configured for usernames, do not use the email + address validator on the account info page. + + clientgui/ + AccountInfoPage.cpp \ No newline at end of file diff --git a/clientgui/AccountInfoPage.cpp b/clientgui/AccountInfoPage.cpp index e13cec5fbf..a52fe1671c 100644 --- a/clientgui/AccountInfoPage.cpp +++ b/clientgui/AccountInfoPage.cpp @@ -183,7 +183,8 @@ void CAccountInfoPage::CreateControls() itemFlexGridSizer64->Add(m_pAccountPasswordRequirmentsStaticCtrl, 0, wxGROW|wxALIGN_CENTER_VERTICAL|wxALL, 5); // Set validators - m_pAccountEmailAddressCtrl->SetValidator( CValidateEmailAddress(& m_strAccountEmailAddress) ); + // m_pAccountEmailAddressCtrl is setup when the OnPageChange event is fired since + // it can be a username or an email address. m_pAccountPasswordCtrl->SetValidator( wxTextValidator(wxFILTER_ASCII, &m_strAccountPassword) ); m_pAccountConfirmPasswordCtrl->SetValidator( wxTextValidator(wxFILTER_ASCII, &m_strAccountConfirmPassword) ); ////@end CAccountInfoPage content construction @@ -354,6 +355,7 @@ void CAccountInfoPage::OnPageChanged( wxWizardExEvent& event ) { m_pAccountEmailAddressStaticCtrl->SetLabel( _("Username:") ); + m_pAccountEmailAddressCtrl->SetValidator( wxTextValidator(wxFILTER_ASCII, &m_strAccountEmailAddress) ); } else { if (m_pAccountManagerInformationStaticCtrl) { m_pAccountManagerInformationStaticCtrl->SetLabel( @@ -364,6 +366,7 @@ void CAccountInfoPage::OnPageChanged( wxWizardExEvent& event ) { m_pAccountEmailAddressStaticCtrl->SetLabel( _("Email address:") ); + m_pAccountEmailAddressCtrl->SetValidator( CValidateEmailAddress(& m_strAccountEmailAddress) ); } if (((CBOINCBaseWizard*)GetParent())->project_config.min_passwd_length) {