1d1766043SAndrew Rist/**************************************************************
2cdf0e10cSrcweir *
3d1766043SAndrew Rist * Licensed to the Apache Software Foundation (ASF) under one
4d1766043SAndrew Rist * or more contributor license agreements.  See the NOTICE file
5d1766043SAndrew Rist * distributed with this work for additional information
6d1766043SAndrew Rist * regarding copyright ownership.  The ASF licenses this file
7d1766043SAndrew Rist * to you under the Apache License, Version 2.0 (the
8d1766043SAndrew Rist * "License"); you may not use this file except in compliance
9d1766043SAndrew Rist * with the License.  You may obtain a copy of the License at
10d1766043SAndrew Rist *
11d1766043SAndrew Rist *   http://www.apache.org/licenses/LICENSE-2.0
12d1766043SAndrew Rist *
13d1766043SAndrew Rist * Unless required by applicable law or agreed to in writing,
14d1766043SAndrew Rist * software distributed under the License is distributed on an
15d1766043SAndrew Rist * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
16d1766043SAndrew Rist * KIND, either express or implied.  See the License for the
17d1766043SAndrew Rist * specific language governing permissions and limitations
18d1766043SAndrew Rist * under the License.
19d1766043SAndrew Rist *
20d1766043SAndrew Rist *************************************************************/
21d1766043SAndrew Rist
22d1766043SAndrew Rist
23cdf0e10cSrcweir#ifndef __com_sun_star_presentation_XSlideShowController_idl__
24cdf0e10cSrcweir#define __com_sun_star_presentation_XSlideShowController_idl__
25cdf0e10cSrcweir
26cdf0e10cSrcweir#ifndef __com_sun_star_drawing_XDrawPage_idl__
27cdf0e10cSrcweir#include <com/sun/star/drawing/XDrawPage.idl>
28cdf0e10cSrcweir#endif
29cdf0e10cSrcweir
30cdf0e10cSrcweir#ifndef __com_sun_star_container_XIndexAccess_idl__
31cdf0e10cSrcweir#include <com/sun/star/container/XIndexAccess.idl>
32cdf0e10cSrcweir#endif
33cdf0e10cSrcweir
34cdf0e10cSrcweir#ifndef __com_sun_star_lang_XComponent_idl__
35cdf0e10cSrcweir#include <com/sun/star/lang/XComponent.idl>
36cdf0e10cSrcweir#endif
37cdf0e10cSrcweir
38cdf0e10cSrcweir#ifndef __com_sun_star_presentation_XSlideShow_idl__
39cdf0e10cSrcweir#include <com/sun/star/presentation/XSlideShow.idl>
40cdf0e10cSrcweir#endif
41cdf0e10cSrcweir
42cdf0e10cSrcweir//=============================================================================
43cdf0e10cSrcweir
44cdf0e10cSrcweir module com {  module sun {  module star {  module presentation {
45cdf0e10cSrcweir
46cdf0e10cSrcweir//=============================================================================
47cdf0e10cSrcweir
48cdf0e10cSrcweir/** interface to control a running slideshow.
49cdf0e10cSrcweir
50cdf0e10cSrcweir    @see XPresentation2
51*badb2b8dSJürgen Schmidt	@since OpenOffice 3.0
52cdf0e10cSrcweir*/
53cdf0e10cSrcweirinterface XSlideShowController
54cdf0e10cSrcweir{
55cdf0e10cSrcweir	//-------------------------------------------------------------------------
56cdf0e10cSrcweir
57cdf0e10cSrcweir	/** returns true if the slideshow is still running.
58cdf0e10cSrcweir		If this returns false, this component is already disposed.
59cdf0e10cSrcweir		You can start a new slideshow and get a new instance
60cdf0e10cSrcweir		of <type>XSlideShowController</type> from <type>XPresentation2</type>
61cdf0e10cSrcweir	*/
62cdf0e10cSrcweir	boolean isRunning();
63cdf0e10cSrcweir
64cdf0e10cSrcweir	//-------------------------------------------------------------------------
65cdf0e10cSrcweir
66cdf0e10cSrcweir	/** @returns
67cdf0e10cSrcweir				the number of slides in this slideshow.
68cdf0e10cSrcweir
69cdf0e10cSrcweir		@see getSlideByIndex
70cdf0e10cSrcweir	 */
71cdf0e10cSrcweir	long getSlideCount();
72cdf0e10cSrcweir
73cdf0e10cSrcweir	//-------------------------------------------------------------------------
74cdf0e10cSrcweir
75cdf0e10cSrcweir	/**	gives access to the slides that will be shown in this slideshow.
76cdf0e10cSrcweir
77cdf0e10cSrcweir		<p>Slides are returned in the order they will be displayed in the
78cdf0e10cSrcweir		presentation which can be different than the orders of slides in
79cdf0e10cSrcweir		the document. Not all slides must be present and each slide can
80cdf0e10cSrcweir		be used more than once.
81cdf0e10cSrcweir
82cdf0e10cSrcweir		@returns
83cdf0e10cSrcweir			the slide at the specified index.
84cdf0e10cSrcweir
85cdf0e10cSrcweir		@param Index
86cdf0e10cSrcweir			specifies the position in the list of slides that are displayed
87cdf0e10cSrcweir			in this slideshow. The first index is 0.
88cdf0e10cSrcweir
89cdf0e10cSrcweir		@throws com::sun::star::lang::IndexOutOfBoundException
90cdf0e10cSrcweir			if the index is not valid.
91cdf0e10cSrcweir
92cdf0e10cSrcweir	 */
93cdf0e10cSrcweir	::com::sun::star::drawing::XDrawPage getSlideByIndex( [in] long Index )
94cdf0e10cSrcweir			raises( com::sun::star::lang::IndexOutOfBoundsException );
95cdf0e10cSrcweir
96cdf0e10cSrcweir	//-------------------------------------------------------------------------
97cdf0e10cSrcweir
98cdf0e10cSrcweir	/** addes a listener that recieves events while the slideshow is running. */
99cdf0e10cSrcweir	void addSlideShowListener( [in] XSlideShowListener Listener );
100cdf0e10cSrcweir
101cdf0e10cSrcweir	//-------------------------------------------------------------------------
102cdf0e10cSrcweir
103cdf0e10cSrcweir	/** removes a listener. */
104cdf0e10cSrcweir	void removeSlideShowListener( [in] XSlideShowListener Listener );
105cdf0e10cSrcweir
106cdf0e10cSrcweir	//-------------------------------------------------------------------------
107cdf0e10cSrcweir
108cdf0e10cSrcweir	/** start next effects that wait on a generic trigger.
109cdf0e10cSrcweir		<p>If no generic triggers are waiting the next
110cdf0e10cSrcweir		slide will be displayed.
111cdf0e10cSrcweir	*/
112cdf0e10cSrcweir	void gotoNextEffect();
113cdf0e10cSrcweir
114cdf0e10cSrcweir	//-------------------------------------------------------------------------
115cdf0e10cSrcweir
116cdf0e10cSrcweir	/** undo the last effects that where triggered by a generic trigger.
117cdf0e10cSrcweir		<p>If there is no previous effect that can be undone then the
118cdf0e10cSrcweir		previous slide will be displayed.
119cdf0e10cSrcweir	*/
120cdf0e10cSrcweir	void gotoPreviousEffect();
121cdf0e10cSrcweir
122cdf0e10cSrcweir	//-------------------------------------------------------------------------
123cdf0e10cSrcweir
124cdf0e10cSrcweir	/** goto and display first slide */
125cdf0e10cSrcweir	void gotoFirstSlide();
126cdf0e10cSrcweir
127cdf0e10cSrcweir	//-------------------------------------------------------------------------
128cdf0e10cSrcweir
129cdf0e10cSrcweir	/** goto and display next slide.
130cdf0e10cSrcweir		<p>Remaining effects on the current slide will be skiped.*/
131cdf0e10cSrcweir	void gotoNextSlide();
132cdf0e10cSrcweir
133cdf0e10cSrcweir	//-------------------------------------------------------------------------
134cdf0e10cSrcweir
135cdf0e10cSrcweir	/** goto and display previous slide.
136cdf0e10cSrcweir		<p>Remaining effects on the current slide will be skiped.*/
137cdf0e10cSrcweir	void gotoPreviousSlide();
138cdf0e10cSrcweir
139cdf0e10cSrcweir	//-------------------------------------------------------------------------
140cdf0e10cSrcweir
141cdf0e10cSrcweir	/** goto and display last slide.
142cdf0e10cSrcweir		<p>Remaining effects on the current slide will be skiped.*/
143cdf0e10cSrcweir	void gotoLastSlide();
144cdf0e10cSrcweir
145cdf0e10cSrcweir	//-------------------------------------------------------------------------
146cdf0e10cSrcweir
147cdf0e10cSrcweir	/** goto the given textual bookmark */
148cdf0e10cSrcweir	void gotoBookmark( [in] string Bookmark );
149cdf0e10cSrcweir
150cdf0e10cSrcweir	//-------------------------------------------------------------------------
151cdf0e10cSrcweir
152cdf0e10cSrcweir	/** jumps to the given slide.
153cdf0e10cSrcweir		<p>The slide can also be a slide that would normaly not be shown during
154cdf0e10cSrcweir		the current slideshow.
155cdf0e10cSrcweir
156cdf0e10cSrcweir		@throws com::sun::star::lang::IllegalArgumentException
157cdf0e10cSrcweir			if the given page is not a valid slide of the document for
158cdf0e10cSrcweir			which this slideshow is started. Also not allowed are master,
159cdf0e10cSrcweir			notes and handout pages.
160cdf0e10cSrcweir	*/
161cdf0e10cSrcweir	void gotoSlide( [in] com::sun::star::drawing::XDrawPage Page )
162cdf0e10cSrcweir		raises( com::sun::star::lang::IllegalArgumentException );
163cdf0e10cSrcweir
164cdf0e10cSrcweir	//-------------------------------------------------------------------------
165cdf0e10cSrcweir
166cdf0e10cSrcweir	/** jumps to the slide at the given index.
167cdf0e10cSrcweir	*/
168cdf0e10cSrcweir	void gotoSlideIndex( [in] long Index );
169cdf0e10cSrcweir
170cdf0e10cSrcweir	//-------------------------------------------------------------------------
171cdf0e10cSrcweir
172cdf0e10cSrcweir	/** stop all currently played sounds */
173cdf0e10cSrcweir	void stopSound();
174cdf0e10cSrcweir
175cdf0e10cSrcweir	//-------------------------------------------------------------------------
176cdf0e10cSrcweir
177cdf0e10cSrcweir	/** pauses the slideshow. All effects are paused.
178cdf0e10cSrcweir		<p>The slideshow continues on next user input or if
179cdf0e10cSrcweir		<member>resume</member> is called.
180cdf0e10cSrcweir	*/
181cdf0e10cSrcweir	void pause();
182cdf0e10cSrcweir
183cdf0e10cSrcweir	//-------------------------------------------------------------------------
184cdf0e10cSrcweir
185cdf0e10cSrcweir	/** resumes a paused slideshow.
186cdf0e10cSrcweir	*/
187cdf0e10cSrcweir	void resume();
188cdf0e10cSrcweir
189cdf0e10cSrcweir	//-------------------------------------------------------------------------
190cdf0e10cSrcweir
191cdf0e10cSrcweir	/** returns <TRUE/> if the slideshow is currently paused.
192cdf0e10cSrcweir
193cdf0e10cSrcweir		@see <member>pause</member>
194cdf0e10cSrcweir		@see <member>resume</member>
195cdf0e10cSrcweir	*/
196cdf0e10cSrcweir	boolean isPaused();
197cdf0e10cSrcweir
198cdf0e10cSrcweir	//-------------------------------------------------------------------------
199cdf0e10cSrcweir
200cdf0e10cSrcweir	/** pauses the slideshow and blanks the screen in the given color.
201cdf0e10cSrcweir		<p>Change attribute <member>Pause</member> to false to unpause
202cdf0e10cSrcweir		the slideshow.
203cdf0e10cSrcweir	*/
204cdf0e10cSrcweir	void blankScreen( [in] long Color );
205cdf0e10cSrcweir
206cdf0e10cSrcweir	//-------------------------------------------------------------------------
207cdf0e10cSrcweir
208cdf0e10cSrcweir	/** activates the user interface of this slideshow.
209cdf0e10cSrcweir
210cdf0e10cSrcweir        @see <member>deactivate()</member>
211cdf0e10cSrcweir        @see <member>isActive()</member>
212cdf0e10cSrcweir    */
213cdf0e10cSrcweir	void activate();
214cdf0e10cSrcweir
215cdf0e10cSrcweir	//-------------------------------------------------------------------------
216cdf0e10cSrcweir	/** can be called to deactivate the user interface of this slideshow.
217cdf0e10cSrcweir
218cdf0e10cSrcweir		<p>A deactivated
219cdf0e10cSrcweir        @see <member>activate()</member>
220cdf0e10cSrcweir        @see <member>isActive()</member>
221cdf0e10cSrcweir	 */
222cdf0e10cSrcweir	void deactivate();
223cdf0e10cSrcweir
224cdf0e10cSrcweir	//-------------------------------------------------------------------------
225cdf0e10cSrcweir
226cdf0e10cSrcweir	/** determines if the slideshow is active.
227cdf0e10cSrcweir
228cdf0e10cSrcweir        @return
229cdf0e10cSrcweir            <TRUE/> for UI active slideshow
230cdf0e10cSrcweir            <br>
231cdf0e10cSrcweir            <FALSE/> otherwise
232cdf0e10cSrcweir	 */
233cdf0e10cSrcweir	boolean isActive();
234cdf0e10cSrcweir
235cdf0e10cSrcweir	//-------------------------------------------------------------------------
236cdf0e10cSrcweir
237cdf0e10cSrcweir	/** returns slide that is currently displayed */
238cdf0e10cSrcweir	com::sun::star::drawing::XDrawPage getCurrentSlide();
239cdf0e10cSrcweir
240cdf0e10cSrcweir	//-------------------------------------------------------------------------
241cdf0e10cSrcweir
242cdf0e10cSrcweir	/** returns the index of the current slide. */
243cdf0e10cSrcweir	long getCurrentSlideIndex();
244cdf0e10cSrcweir
245cdf0e10cSrcweir	//-------------------------------------------------------------------------
246cdf0e10cSrcweir
247cdf0e10cSrcweir	/** the index for the slide that is displayed next. */
248cdf0e10cSrcweir	long getNextSlideIndex();
249cdf0e10cSrcweir
250cdf0e10cSrcweir	//-------------------------------------------------------------------------
251cdf0e10cSrcweir
252cdf0e10cSrcweir	/** returns <TRUE/> if the slideshow was started to run endlessly.
253cdf0e10cSrcweir	 */
254cdf0e10cSrcweir	boolean isEndless();
255cdf0e10cSrcweir
256cdf0e10cSrcweir	//-------------------------------------------------------------------------
257cdf0e10cSrcweir
258cdf0e10cSrcweir	/** Returns <TRUE/> if the slideshow was started in full-screen mode.
259cdf0e10cSrcweir	 */
260cdf0e10cSrcweir	boolean isFullScreen();
261cdf0e10cSrcweir
262cdf0e10cSrcweir	//-------------------------------------------------------------------------
263cdf0e10cSrcweir
264cdf0e10cSrcweir	/** If this attribute is set to <TRUE/>, the window of the slideshow is
265cdf0e10cSrcweir		always on top of all other windows.
266cdf0e10cSrcweir	 */
267cdf0e10cSrcweir	[attribute] boolean AlwaysOnTop;
268cdf0e10cSrcweir
269cdf0e10cSrcweir	//-------------------------------------------------------------------------
270cdf0e10cSrcweir
271cdf0e10cSrcweir	/** If this attribute is <TRUE/>, the mouse is visible during the
272cdf0e10cSrcweir		slideshow.
273cdf0e10cSrcweir	 */
274cdf0e10cSrcweir	[attribute] boolean MouseVisible;
275cdf0e10cSrcweir
276cdf0e10cSrcweir	//-------------------------------------------------------------------------
277cdf0e10cSrcweir
278cdf0e10cSrcweir	/** If this is <TRUE/>, a pen is shown during presentation.
279cdf0e10cSrcweir
280cdf0e10cSrcweir		<p>You can draw on the presentation with this pen.</p>
281cdf0e10cSrcweir	 */
282cdf0e10cSrcweir	[attribute] boolean UsePen;
283cdf0e10cSrcweir
284cdf0e10cSrcweir	//-------------------------------------------------------------------------
285cdf0e10cSrcweir
286cdf0e10cSrcweir	/** This attribute changes the color of the pen. */
287cdf0e10cSrcweir	[attribute] long PenColor;
288cdf0e10cSrcweir
289cdf0e10cSrcweir	//-------------------------------------------------------------------------
290cdf0e10cSrcweir
291*badb2b8dSJürgen Schmidt	/** This attribute changes the width of the pen.
292*badb2b8dSJürgen Schmidt
293*badb2b8dSJürgen Schmidt		@since OpenOffice 4.1
294*badb2b8dSJürgen Schmidt	*/
295*badb2b8dSJürgen Schmidt	[attribute] double PenWidth;
296*badb2b8dSJürgen Schmidt
297*badb2b8dSJürgen Schmidt	//-------------------------------------------------------------------------
298*badb2b8dSJürgen Schmidt
299cdf0e10cSrcweir	/** returns the actuall <type>XSlideShow</type> instance that runs the
300cdf0e10cSrcweir		slideshow.
301cdf0e10cSrcweir		<br>Normaly all navigation should be done using this controller and
302cdf0e10cSrcweir		not the <type>XSlideShow</type> itself. */
303cdf0e10cSrcweir	XSlideShow getSlideShow();
304cdf0e10cSrcweir
305cdf0e10cSrcweir	//-------------------------------------------------------------------------
306cdf0e10cSrcweir};
307cdf0e10cSrcweir
308cdf0e10cSrcweir//=============================================================================
309cdf0e10cSrcweir
310cdf0e10cSrcweir}; }; }; };
311cdf0e10cSrcweir
312cdf0e10cSrcweir#endif
313