1
// Berkeley Open Infrastructure for Network Computing
2
// http://boinc.berkeley.edu
3
// Copyright (C) 2005 University of California
5
// This is free software; you can redistribute it and/or
6
// modify it under the terms of the GNU Lesser General Public
7
// License as published by the Free Software Foundation;
8
// either version 2.1 of the License, or (at your option) any later version.
10
// This software is distributed in the hope that it will be useful,
11
// but WITHOUT ANY WARRANTY; without even the implied warranty of
12
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
13
// See the GNU Lesser General Public License for more details.
15
// To view the GNU Lesser General Public License visit
16
// http://www.gnu.org/copyleft/lesser.html
17
// or write to the Free Software Foundation, Inc.,
18
// 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
21
#ifndef _WIZ_ATTACHPROJECT_H_
22
#define _WIZ_ATTACHPROJECT_H_
24
#if defined(__GNUG__) && !defined(__APPLE__)
25
#pragma interface "WizardAttachProject.cpp"
29
* Forward declarations
32
////@begin forward declarations
33
class CProjectInfoPage;
34
class CProjectPropertiesPage;
35
class CProjectProcessingPage;
36
////@end forward declarations
40
* CWizardAttachProject class declaration
43
class CWizardAttachProject: public CBOINCBaseWizard
45
DECLARE_DYNAMIC_CLASS( CWizardAttachProject )
50
CWizardAttachProject( );
51
CWizardAttachProject( wxWindow* parent, wxWindowID id = SYMBOL_CWIZARDATTACHPROJECT_IDNAME, const wxPoint& pos = wxDefaultPosition );
54
bool Create( wxWindow* parent, wxWindowID id = SYMBOL_CWIZARDATTACHPROJECT_IDNAME, const wxPoint& pos = wxDefaultPosition );
56
/// Creates the controls and sizers
57
void CreateControls();
59
////@begin CWizardAttachProject event handler declarations
61
/// wxEVT_WIZARD_FINISHED event handler for ID_ATTACHPROJECTWIZARD
62
void OnFinished( wxWizardExEvent& event );
64
////@end CWizardAttachProject event handler declarations
66
/// wxEVT_COMMAND_BUTTON_CLICKED event handler for wxID_BACKWARD
67
void OnWizardBack( wxCommandEvent& event );
68
/// wxEVT_COMMAND_BUTTON_CLICKED event handler for wxID_FORWARD
69
void OnWizardNext( wxCommandEvent& event );
71
////@begin CWizardAttachProject member function declarations
74
bool Run( wxString& strName, wxString& strURL, bool bCredentialsCached = true );
76
/// Retrieves bitmap resources
77
wxBitmap GetBitmapResource( const wxString& name );
79
/// Retrieves icon resources
80
wxIcon GetIconResource( const wxString& name );
81
////@end CWizardAttachProject member function declarations
84
virtual bool HasNextPage( wxWizardPageEx* page );
85
virtual bool HasPrevPage( wxWizardPageEx* page );
87
/// Track page transitions
88
wxWizardPageEx* _PopPageTransition();
89
wxWizardPageEx* _PushPageTransition( wxWizardPageEx* pCurrentPage, unsigned long ulPageID );
91
/// Cancel Event Infrastructure
92
void _ProcessCancelEvent( wxWizardExEvent& event );
94
/// Finish Button Environment
95
bool GetAccountCreatedSuccessfully() const { return account_created_successfully ; }
96
void SetAccountCreatedSuccessfully(bool value) { account_created_successfully = value ; }
98
bool GetAttachedToProjectSuccessfully() const { return attached_to_project_successfully ; }
99
void SetAttachedToProjectSuccessfully(bool value) { attached_to_project_successfully = value ; }
101
wxString GetProjectURL() const { return project_url ; }
102
void SetProjectURL(wxString value) { project_url = value ; }
104
wxString GetProjectAuthenticator() const { return project_authenticator ; }
105
void SetProjectAuthenticator(wxString value) { project_authenticator = value ; }
107
/// Should we show tooltips?
108
static bool ShowToolTips();
110
////@begin CWizardAttachProject member variables
111
CWelcomePage* m_WelcomePage;
112
CProjectInfoPage* m_ProjectInfoPage;
113
CProjectPropertiesPage* m_ProjectPropertiesPage;
114
CProjectProcessingPage* m_ProjectProcessingPage;
115
CTermsOfUsePage* m_TermsOfUsePage;
116
CAccountInfoPage* m_AccountInfoPage;
117
CCompletionPage* m_CompletionPage;
118
CCompletionErrorPage* m_CompletionErrorPage;
119
CErrNotDetectedPage* m_ErrNotDetectedPage;
120
CErrUnavailablePage* m_ErrUnavailablePage;
121
CErrAlreadyAttachedPage* m_ErrAlreadyAttachedPage;
122
CErrNoInternetConnectionPage* m_ErrNoInternetConnectionPage;
123
CErrNotFoundPage* m_ErrNotFoundPage;
124
CErrAlreadyExistsPage* m_ErrAlreadyExistsPage;
125
CErrProxyInfoPage* m_ErrProxyInfoPage;
126
CErrProxyPage* m_ErrProxyPage;
127
////@end CWizardAttachProject member variables
128
bool m_bCredentialsCached;
129
bool m_bCredentialsDetected;
130
wxString m_strProjectName;
133
#endif // _WIZ_ATTACHPROJECT_H_