1/**************************************************************
2 *
3 * Licensed to the Apache Software Foundation (ASF) under one
4 * or more contributor license agreements.  See the NOTICE file
5 * distributed with this work for additional information
6 * regarding copyright ownership.  The ASF licenses this file
7 * to you under the Apache License, Version 2.0 (the
8 * "License"); you may not use this file except in compliance
9 * with the License.  You may obtain a copy of the License at
10 *
11 *   http://www.apache.org/licenses/LICENSE-2.0
12 *
13 * Unless required by applicable law or agreed to in writing,
14 * software distributed under the License is distributed on an
15 * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
16 * KIND, either express or implied.  See the License for the
17 * specific language governing permissions and limitations
18 * under the License.
19 *
20 *************************************************************/
21
22#ifndef __com_sun_star_ui_dialogs_XWizardPage_idl__
23#define __com_sun_star_ui_dialogs_XWizardPage_idl__
24
25#include <com/sun/star/awt/XWindow.idl>
26
27module com { module sun { module star { module ui { module dialogs {
28
29/** is a single page of a <type>Wizard</type>
30
31    @since OpenOffice 3.3
32 */
33interface XWizardPage : ::com::sun::star::lang::XComponent
34{
35    /** provides read-only access to the window of the page
36    */
37    [attribute, readonly]   ::com::sun::star::awt::XWindow  Window;
38
39    /** denotes the ID of the page.
40
41        <p>Within a wizard, no two pages are allowed to have the same ID.</p>
42    */
43    [attribute, readonly]   short PageId;
44
45    /** called when the page is activated
46    */
47    void    activatePage();
48
49    /** is called when the page is about to be left
50
51        <p>An implementation can veto the leave by returning <FALSE/> here. Usually, the decision about this
52        depends on the current state of the page.</p>
53
54        @param Reason
55            is one of the <type>WizardTravelType</type> contants denoting the reason why the page should be
56            committed.
57    */
58    boolean commitPage( [in] short Reason );
59
60    /** determines whether it is allowed to travel to a later page in the wizard
61
62        <p>You should base this decision on the state of the page only, not on a global state of the wizard. Usually,
63        you return <FALSE/> here if and only if not all necessary input on the page has been provided by the user,
64        or the provided input is not valid.</p>
65
66        <p>If checked for validity is expensive, or if you prefer giving your user more detailed feedback on validity
67        than a disabled <code>Next</code> button in the wizard, then move your checks to the <member>commitPage</member>
68        method.</p>
69    */
70    boolean canAdvance();
71};
72
73}; }; }; }; };
74
75#endif
76