2008-08-06 18:36:30 +00:00
|
|
|
// This file is part of BOINC.
|
2005-09-26 11:29:28 +00:00
|
|
|
// http://boinc.berkeley.edu
|
2008-08-06 18:36:30 +00:00
|
|
|
// Copyright (C) 2008 University of California
|
2005-09-26 11:29:28 +00:00
|
|
|
//
|
2008-08-06 18:36:30 +00:00
|
|
|
// BOINC is free software; you can redistribute it and/or modify it
|
|
|
|
// under the terms of the GNU Lesser General Public License
|
|
|
|
// as published by the Free Software Foundation,
|
|
|
|
// either version 3 of the License, or (at your option) any later version.
|
2005-09-26 11:29:28 +00:00
|
|
|
//
|
2008-08-06 18:36:30 +00:00
|
|
|
// BOINC is distributed in the hope that it will be useful,
|
2005-09-26 11:29:28 +00:00
|
|
|
// but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
|
|
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
|
|
|
|
// See the GNU Lesser General Public License for more details.
|
|
|
|
//
|
2008-08-06 18:36:30 +00:00
|
|
|
// You should have received a copy of the GNU Lesser General Public License
|
|
|
|
// along with BOINC. If not, see <http://www.gnu.org/licenses/>.
|
|
|
|
|
2005-09-26 11:29:28 +00:00
|
|
|
#ifndef _WIZ_BOINCBASEWIZARD_H_
|
|
|
|
#define _WIZ_BOINCBASEWIZARD_H_
|
|
|
|
|
|
|
|
#if defined(__GNUG__) && !defined(__APPLE__)
|
|
|
|
#pragma interface "BOINCBaseWizard.cpp"
|
|
|
|
#endif
|
|
|
|
|
|
|
|
/*!
|
|
|
|
* CBOINCBaseWizard class declaration
|
|
|
|
*/
|
|
|
|
|
|
|
|
class CBOINCBaseWizard: public wxWizardEx
|
|
|
|
{
|
|
|
|
DECLARE_DYNAMIC_CLASS( CBOINCBaseWizard )
|
|
|
|
|
|
|
|
public:
|
|
|
|
/// Constructors
|
|
|
|
CBOINCBaseWizard();
|
|
|
|
CBOINCBaseWizard(wxWindow *parent,
|
|
|
|
int id = wxID_ANY,
|
|
|
|
const wxString& title = wxEmptyString,
|
|
|
|
const wxBitmap& bitmap = wxNullBitmap,
|
|
|
|
const wxPoint& pos = wxDefaultPosition,
|
|
|
|
long style = wxDEFAULT_DIALOG_STYLE);
|
|
|
|
|
|
|
|
/// Track page transitions
|
|
|
|
wxWizardPageEx* PopPageTransition();
|
|
|
|
virtual wxWizardPageEx* _PopPageTransition();
|
|
|
|
wxWizardPageEx* PushPageTransition( wxWizardPageEx* pCurrentPage, unsigned long ulPageID );
|
|
|
|
virtual wxWizardPageEx* _PushPageTransition( wxWizardPageEx* pCurrentPage, unsigned long ulPageID );
|
|
|
|
std::stack<wxWizardPageEx*> m_PageTransition;
|
|
|
|
|
|
|
|
/// Cancel Event Infrastructure
|
2005-09-27 03:17:49 +00:00
|
|
|
bool IsCancelInProgress() const;
|
2005-09-26 11:29:28 +00:00
|
|
|
void ProcessCancelEvent( wxWizardExEvent& event );
|
|
|
|
virtual void _ProcessCancelEvent( wxWizardExEvent& event );
|
|
|
|
bool m_bCancelInProgress;
|
|
|
|
|
|
|
|
/// Button State Infrastructure
|
2005-09-27 03:17:49 +00:00
|
|
|
wxButton* GetNextButton() const;
|
2005-09-26 11:29:28 +00:00
|
|
|
void SimulateNextButton();
|
|
|
|
void EnableNextButton();
|
|
|
|
void DisableNextButton();
|
2005-09-27 03:17:49 +00:00
|
|
|
wxButton* GetBackButton() const;
|
2005-09-26 11:29:28 +00:00
|
|
|
void SimulateBackButton();
|
|
|
|
void EnableBackButton();
|
|
|
|
void DisableBackButton();
|
2008-09-19 20:19:52 +00:00
|
|
|
wxButton* GetCancelButton() const;
|
|
|
|
void SimulateCancelButton();
|
|
|
|
void EnableCancelButton();
|
|
|
|
void DisableCancelButton();
|
2005-09-26 11:29:28 +00:00
|
|
|
|
|
|
|
/// Wizard Detection
|
|
|
|
bool IsAttachToProjectWizard;
|
2006-01-27 00:34:53 +00:00
|
|
|
bool IsAccountManagerWizard;
|
2006-01-25 11:58:02 +00:00
|
|
|
bool IsAccountManagerUpdateWizard;
|
2005-09-26 11:29:28 +00:00
|
|
|
|
|
|
|
/// Global Wizard Status
|
|
|
|
PROJECT_CONFIG project_config;
|
|
|
|
ACCOUNT_IN account_in;
|
|
|
|
ACCOUNT_OUT account_out;
|
|
|
|
bool account_created_successfully;
|
|
|
|
bool attached_to_project_successfully;
|
2006-10-13 17:02:28 +00:00
|
|
|
bool close_when_completed;
|
2006-01-15 12:10:42 +00:00
|
|
|
wxString project_name;
|
2005-09-26 11:29:28 +00:00
|
|
|
wxString project_url;
|
|
|
|
wxString project_authenticator;
|
|
|
|
};
|
|
|
|
|
|
|
|
#endif // _WIZ_BOINCBASEWIZARD_H_
|