1 'encoding UTF-8 Do not remove or change this line!
2 '**************************************************************************
3 '* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
5 '* Copyright 2008 by Sun Microsystems, Inc.
7 '* OpenOffice.org - a multi-platform office productivity suite
9 '* $RCSfile: ch2_view.inc,v $
13 '* last change: $Author: jsi $ $Date: 2008-06-13 14:27:01 $
15 '* This file is part of OpenOffice.org.
17 '* OpenOffice.org is free software: you can redistribute it and/or modify
18 '* it under the terms of the GNU Lesser General Public License version 3
19 '* only, as published by the Free Software Foundation.
21 '* OpenOffice.org is distributed in the hope that it will be useful,
22 '* but WITHOUT ANY WARRANTY; without even the implied warranty of
23 '* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
24 '* GNU Lesser General Public License version 3 for more details
25 '* (a copy is included in the LICENSE file that accompanied this code).
27 '* You should have received a copy of the GNU Lesser General Public License
28 '* version 3 along with OpenOffice.org. If not, see
29 '* <http://www.openoffice.org/license.html>
30 '* for a copy of the LGPLv3 License.
32 '/************************************************************************
34 '* owner : oliver.craemer@sun.com
36 '* short description : Chart resource test - Menu VIEW
38 '************************************************************************
41 ' #1 tViewToolbarsCustomize
44 '\************************************************************************
46 testcase tViewToolbars
47 '///<u><b>Check invocation of View::Toolbars::*</b></u>
48 '/// Load simple chart document and save it in user's work dorectory
49 if fLoadVerySimpleChartAndSaveLocal() > 0 then
50 warnlog "Loading test document seems to have failed -> Check this out!"
53 '/// Select chart using the navigator
55 '/// Edit / Object / Edit
57 '/// Convert chart to 3D
58 if NOT fConvertChartTo3D() then
59 warnlog "Conversion of chart to 3D failed -> Quit testcase"
63 printlog "Converting chart into 3D was successful."
66 if Standardbar.Exists then
67 '/// View / Toolbars / Standard
70 '/// Verifying that the toolbar 'Standard' is disabled
71 if Standardbar.Exists then
72 QAErrorLog "#i72537 - Disabling 'Standard' toolbar does not work."
76 '/// Enabling the toolbar again
80 warnlog "'Standard' toolbar was not visible by default as expected!"
83 if Toolbar.Exists then
84 '/// View / Toolbars / Formatting
87 '/// Verifying that the toolbar 'Formatting' is disabled
88 if Toolbar.Exists then
89 QAErrorLog "#i72537 - Disabling 'Formatting' toolbar does not work."
93 '/// Enabling the toolbar again
97 warnlog "'Standard' toolbar was not visible by default as expected!"
103 '-------------------------------------------------------------
105 testcase tViewToolbarsCustomize
106 '///<u><b>Check Dialog after invocation of View::Toolbars::Customize</b></u>
109 '///+<li>Load simple chart document</li>
110 if fLoadVerySimpleChartAndSaveLocal() > 0 then
111 warnlog "Loading test document seems to have failed -> Check this out!"
114 '///+<li>Select chart using navigator</li>
116 '///+<li>Invoke Edit::Object::Edit to enter Inplace Mode</li>
118 '///+<li>Invoke View::Toolbars::Customize</li>
119 ViewToolbarsCustomize
120 '///+<li>Change to Menus tab-page</li>
122 Active.SetPage TabCustomizeMenu
123 '///+<li>Check existence of dialog</li>
124 Call DialogTest ( TabCustomizeMenu )
125 '///+<li>Change to Keyboard tab-page</li>
127 Active.SetPage TabTastatur
128 '///+<li>Check existence of dialog</li>
129 Call DialogTest ( TabTastatur )
130 '///+<li>Change to Toolbars tab-page</li>
132 Active.SetPage TabCustomizeToolbars
133 '///+<li>Check existence of dialog</li>
134 Call DialogTest ( TabCustomizeToolbars )
135 '///+<li>Change to Events tab-page</li>
137 Active.SetPage TabCustomizeEvents
138 '///+<li>Check existence of dialog</li>
139 Call DialogTest ( TabCustomizeEvents )
140 '///+<li>Quit dialog</li>
141 TabCustomizeEvents.cancel
142 '///+<li>Close document</li>
143 Kontext "DocumentCalc"
144 DocumentCalc.TypeKeys "<Escape>"
149 '-------------------------------------------------------------
150 testcase tViewFullScreen
151 '///<u><b>Check invocation of View::Fullscren</b></u>
154 '///+<li>Load simple chart document</li>
155 if fLoadVerySimpleChartAndSaveLocal() > 0 then
156 warnlog "Loading test document seems to have failed -> Check this out!"
159 '///+<li>Select chart using navigator</li>
161 '///+<li>Invoke Edit::Object::Edit to enter Inplace Mode</li>
163 '///+<li>Convert chart to 3D (this probably makes the test more risky)</li>
164 if NOT fConvertChartTo3D() then
165 warnlog "Conversion of chart to 3D failed -> Quit testcase"
169 '///+<li>Invoke View::Fullscren</li>
171 '///+<li>Quit fullscreen using CTRL+SHIFT+J</li>
172 Kontext "DocumentCalc"
173 DocumentCalc.TypeKeys "<Mod1 Shift J>"
175 '///+<li>Enter fullscreen using CTRL+SHIFT+J</li>
176 DocumentCalc.TypeKeys "<Mod1 Shift J>"
177 '///+<li>Quit fullscreen using View::Fullscren</li>
179 '///<li>Close document</li>
180 Kontext "DocumentCalc"
181 DocumentCalc.TypeKeys "<Escape>"
187 '-----------------------------------------------------------