1 /*************************************************************************
2  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
3  *
4  * Copyright 2000, 2010 Oracle and/or its affiliates.
5  *
6  * OpenOffice.org - a multi-platform office productivity suite
7  *
8  * This file is part of OpenOffice.org.
9  *
10  * OpenOffice.org is free software: you can redistribute it and/or modify
11  * it under the terms of the GNU Lesser General Public License version 3
12  * only, as published by the Free Software Foundation.
13  *
14  * OpenOffice.org is distributed in the hope that it will be useful,
15  * but WITHOUT ANY WARRANTY; without even the implied warranty of
16  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
17  * GNU Lesser General Public License version 3 for more details
18  * (a copy is included in the LICENSE file that accompanied this code).
19  *
20  * You should have received a copy of the GNU Lesser General Public License
21  * version 3 along with OpenOffice.org.  If not, see
22  * <http://www.openoffice.org/license.html>
23  * for a copy of the LGPLv3 License.
24  *
25  ************************************************************************/
26 
27 #ifndef SVT_UNOWIZ_WIZARDPAGECONTROLLER_HXX
28 #define SVT_UNOWIZ_WIZARDPAGECONTROLLER_HXX
29 
30 #include "svtools/wizardmachine.hxx"
31 
32 /** === begin UNO includes === **/
33 #include <com/sun/star/ui/dialogs/XWizardController.hpp>
34 /** === end UNO includes === **/
35 
36 //......................................................................................................................
37 namespace svt { namespace uno
38 {
39 //......................................................................................................................
40 
41     class WizardShell;
42 
43 	//==================================================================================================================
44 	//= WizardPageController
45 	//==================================================================================================================
46     class WizardPageController : public IWizardPageController
47 	{
48     public:
49         WizardPageController(
50             WizardShell& i_rParent,
51             const ::com::sun::star::uno::Reference< ::com::sun::star::ui::dialogs::XWizardController >& i_rController,
52             const sal_Int16 i_nPageId
53         );
54         ~WizardPageController();
55 
56         // IWizardPageController overridables
57 		virtual void		initializePage();
58         virtual sal_Bool	commitPage( WizardTypes::CommitPageReason _eReason );
59 		virtual bool        canAdvance() const;
60 
61         const ::com::sun::star::uno::Reference< ::com::sun::star::ui::dialogs::XWizardPage >&
62                             getWizardPage() const { return m_xWizardPage; }
63         TabPage*            getTabPage() const;
64 
65     private:
66         const ::com::sun::star::uno::Reference< ::com::sun::star::ui::dialogs::XWizardController >  m_xController;
67         ::com::sun::star::uno::Reference< ::com::sun::star::ui::dialogs::XWizardPage >              m_xWizardPage;
68         const sal_Int16                                                                             m_nPageId;
69 	};
70 
71 //......................................................................................................................
72 } } // namespace svt::uno
73 //......................................................................................................................
74 
75 #endif // SVT_UNOWIZ_WIZARDPAGECONTROLLER_HXX
76