- MGR: Fix an endless loop during wizard creation, any automatic

true conditions in the GetNext() GetPrev() logic causes
        the wizard to traverse the page and then look for the next
        page.
        
    clientgui/
        AccountManagerPropertiesPage.cpp
        ProjectPropertiesPage.cpp

svn path=/trunk/boinc/; revision=18749
This commit is contained in:
Rom Walton 2009-07-28 05:53:51 +00:00
parent 5f2339a1e6
commit 31e9916f7d
5 changed files with 24 additions and 14 deletions

View File

@ -6590,3 +6590,13 @@ Rom 27 July 2009
clientgui/
AccountManagerPropertiesPage.cpp
ProjectPropertiesPage.cpp
Rom 28 July 2008
- MGR: Fix an endless loop during wizard creation, any automatic
true conditions in the GetNext() GetPrev() logic causes
the wizard to traverse the page and then look for the next
page.
clientgui/
AccountManagerPropertiesPage.cpp
ProjectPropertiesPage.cpp

View File

@ -117,7 +117,7 @@ bool CAccountManagerPropertiesPage::Create( CBOINCBaseWizard* parent )
m_bProjectPropertiesCommunicationFailure = false;
m_bProjectAccountCreationDisabled = false;
m_bProjectClientAccountCreationDisabled = false;
m_bNetworkConnectionDetected = false;
m_bNetworkConnectionNotDetected = false;
m_bServerReportedError = false;
m_bTermsOfUseRequired = true;
m_bCredentialsAlreadyAvailable = false;
@ -215,7 +215,7 @@ void CAccountManagerPropertiesPage::OnPageChanged( wxWizardExEvent& event )
SetProjectPropertiesCommunicationFailure(false);
SetProjectAccountCreationDisabled(false);
SetProjectClientAccountCreationDisabled(false);
SetNetworkConnectionDetected(false);
SetNetworkConnectionNotDetected(false);
SetTermsOfUseRequired(true);
SetCredentialsAlreadyAvailable(false);
SetNextState(ACCTMGRPROP_INIT);
@ -387,7 +387,7 @@ void CAccountManagerPropertiesPage::OnStateChange( CAccountManagerPropertiesPage
::wxSafeYield(GetParent());
}
SetNetworkConnectionDetected(NETWORK_STATUS_WANT_CONNECTION != status.network_status);
SetNetworkConnectionNotDetected(NETWORK_STATUS_WANT_CONNECTION == status.network_status);
SetNextState(ACCTMGRPROP_DETERMINEACCOUNTINFOSTATUS_BEGIN);
break;
@ -450,7 +450,7 @@ wxWizardPageEx* CAccountManagerPropertiesPage::GetNext() const
} else if (GetProjectPropertiesSucceeded()) {
// We were successful in retrieving the project properties
return PAGE_TRANSITION_NEXT(ID_ACCOUNTINFOPAGE);
} else if (GetProjectPropertiesDNSFailure() || !GetNetworkConnectionDetected()) {
} else if (GetProjectPropertiesDNSFailure() || GetNetworkConnectionNotDetected()) {
// No Internet Connection
return PAGE_TRANSITION_NEXT(ID_ERRPROXYINFOPAGE);
} else if (GetProjectPropertiesURLFailure()) {

View File

@ -126,8 +126,8 @@ public:
bool GetProjectClientAccountCreationDisabled() const { return m_bProjectClientAccountCreationDisabled ; }
void SetProjectClientAccountCreationDisabled(bool value) { m_bProjectClientAccountCreationDisabled = value ; }
bool GetNetworkConnectionDetected() const { return m_bNetworkConnectionDetected ; }
void SetNetworkConnectionDetected(bool value) { m_bNetworkConnectionDetected = value ; }
bool GetNetworkConnectionNotDetected() const { return m_bNetworkConnectionNotDetected ; }
void SetNetworkConnectionNotDetected(bool value) { m_bNetworkConnectionNotDetected = value ; }
bool GetServerReportedError() const { return m_bServerReportedError ; }
void SetServerReportedError(bool value) { m_bServerReportedError = value ; }
@ -160,7 +160,7 @@ public:
bool m_bProjectPropertiesCommunicationFailure;
bool m_bProjectAccountCreationDisabled;
bool m_bProjectClientAccountCreationDisabled;
bool m_bNetworkConnectionDetected;
bool m_bNetworkConnectionNotDetected;
bool m_bServerReportedError;
bool m_bTermsOfUseRequired;
bool m_bCredentialsAlreadyAvailable;

View File

@ -114,7 +114,7 @@ bool CProjectPropertiesPage::Create( CBOINCBaseWizard* parent )
m_bProjectPropertiesCommunicationFailure = false;
m_bProjectAccountCreationDisabled = false;
m_bProjectClientAccountCreationDisabled = false;
m_bNetworkConnectionDetected = false;
m_bNetworkConnectionNotDetected = false;
m_bServerReportedError = false;
m_bTermsOfUseRequired = true;
m_iBitmapIndex = 0;
@ -195,7 +195,7 @@ wxWizardPageEx* CProjectPropertiesPage::GetNext() const
} else if (GetProjectPropertiesSucceeded()) {
// We were successful in retrieving the project properties
return PAGE_TRANSITION_NEXT(ID_ACCOUNTINFOPAGE);
} else if (GetProjectPropertiesDNSFailure() || !GetNetworkConnectionDetected()) {
} else if (GetProjectPropertiesDNSFailure() || GetNetworkConnectionNotDetected()) {
// No Internet Connection
return PAGE_TRANSITION_NEXT(ID_ERRPROXYINFOPAGE);
} else if (GetProjectPropertiesURLFailure()) {
@ -343,7 +343,7 @@ void CProjectPropertiesPage::OnPageChanged( wxWizardExEvent& event ) {
SetProjectPropertiesCommunicationFailure(false);
SetProjectAccountCreationDisabled(false);
SetProjectClientAccountCreationDisabled(false);
SetNetworkConnectionDetected(false);
SetNetworkConnectionNotDetected(false);
SetNextState(PROJPROP_INIT);
CProjectPropertiesPageEvent TransitionEvent(wxEVT_PROJECTPROPERTIES_STATECHANGE, this);
@ -505,7 +505,7 @@ void CProjectPropertiesPage::OnStateChange( CProjectPropertiesPageEvent& WXUNUSE
::wxSafeYield(GetParent());
}
SetNetworkConnectionDetected(NETWORK_STATUS_WANT_CONNECTION != status.network_status);
SetNetworkConnectionNotDetected(NETWORK_STATUS_WANT_CONNECTION == status.network_status);
SetNextState(PROJPROP_DETERMINEACCOUNTINFOSTATUS_BEGIN);
break;

View File

@ -126,8 +126,8 @@ public:
bool GetProjectClientAccountCreationDisabled() const { return m_bProjectClientAccountCreationDisabled ; }
void SetProjectClientAccountCreationDisabled(bool value) { m_bProjectClientAccountCreationDisabled = value ; }
bool GetNetworkConnectionDetected() const { return m_bNetworkConnectionDetected ; }
void SetNetworkConnectionDetected(bool value) { m_bNetworkConnectionDetected = value ; }
bool GetNetworkConnectionNotDetected() const { return m_bNetworkConnectionNotDetected ; }
void SetNetworkConnectionNotDetected(bool value) { m_bNetworkConnectionNotDetected = value ; }
bool GetServerReportedError() const { return m_bServerReportedError ; }
void SetServerReportedError(bool value) { m_bServerReportedError = value ; }
@ -159,7 +159,7 @@ public:
bool m_bProjectPropertiesCommunicationFailure;
bool m_bProjectAccountCreationDisabled;
bool m_bProjectClientAccountCreationDisabled;
bool m_bNetworkConnectionDetected;
bool m_bNetworkConnectionNotDetected;
bool m_bServerReportedError;
bool m_bTermsOfUseRequired;
bool m_bCredentialsAlreadyAvailable;