- MGR: Finish implementing the use of Usernames in the account manager part

of the wizard.  I must have been asleep at the wheel on that one.
        
    clientgui/
        AccountInfoPage.h
        AccountManagerProcessingPage.cpp
        ProjectProcessingPage.cpp

svn path=/trunk/boinc/; revision=22271
This commit is contained in:
Rom Walton 2010-08-19 00:22:25 +00:00
parent fb7d10a686
commit 10573af830
4 changed files with 23 additions and 2 deletions

View File

@ -6167,3 +6167,12 @@ Rom 18 Aug 2010
BOINCHtmlLBox.cpp, .h
BOINCVListBox.cpp, .h
stdwx.h
Rom 18 Aug 2010
- MGR: Finish implementing the use of Usernames in the account manager part
of the wizard. I must have been asleep at the wheel on that one.
clientgui/
AccountInfoPage.h
AccountManagerProcessingPage.cpp
ProjectProcessingPage.cpp

View File

@ -80,6 +80,9 @@ public:
wxString GetAccountConfirmPassword() const { return m_strAccountConfirmPassword ; }
void SetAccountConfirmPassword(wxString value) { m_strAccountConfirmPassword = value ; }
wxString GetAccountUsername() const { return m_strAccountUsername ; }
void SetAccountUsername(wxString value) { m_strAccountUsername = value ; }
/// Retrieves bitmap resources
wxBitmap GetBitmapResource( const wxString& name );

View File

@ -264,7 +264,11 @@ void CAccountManagerProcessingPage::OnStateChange( CAccountManagerProcessingPage
url = (const char*)pWA->m_AccountManagerInfoPage->GetProjectURL().mb_str();
}
username = (const char*)pWA->m_AccountInfoPage->GetAccountEmailAddress().mb_str();
if (pWA->project_config.uses_username) {
username = (const char*)pWA->m_AccountInfoPage->GetAccountUsername().mb_str();
} else {
username = (const char*)pWA->m_AccountInfoPage->GetAccountEmailAddress().mb_str();
}
password = (const char*)pWA->m_AccountInfoPage->GetAccountPassword().mb_str();
// Wait until we are done processing the request.

View File

@ -398,7 +398,12 @@ void CProjectProcessingPage::OnStateChange( CProjectProcessingPageEvent& WXUNUSE
SetProjectCommunitcationsSucceeded(true);
} else {
// Setup initial values for both the create and lookup API
ai->email_addr = (const char*)pWA->m_AccountInfoPage->GetAccountEmailAddress().mb_str();
if (pWA->project_config.uses_username) {
ai->email_addr = (const char*)pWA->m_AccountInfoPage->GetAccountUsername().mb_str();
} else {
ai->email_addr = (const char*)pWA->m_AccountInfoPage->GetAccountEmailAddress().mb_str();
}
ai->passwd = (const char*)pWA->m_AccountInfoPage->GetAccountPassword().mb_str();
ai->user_name = (const char*)::wxGetUserName().mb_str();
if (ai->user_name.empty()) {