1 /*************************************************************************
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: ToolbarController.idl,v $
12 * This file is part of OpenOffice.org.
14 * OpenOffice.org is free software: you can redistribute it and/or modify
15 * it under the terms of the GNU Lesser General Public License version 3
16 * only, as published by the Free Software Foundation.
18 * OpenOffice.org is distributed in the hope that it will be useful,
19 * but WITHOUT ANY WARRANTY; without even the implied warranty of
20 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
21 * GNU Lesser General Public License version 3 for more details
22 * (a copy is included in the LICENSE file that accompanied this code).
24 * You should have received a copy of the GNU Lesser General Public License
25 * version 3 along with OpenOffice.org. If not, see
26 * <http://www.openoffice.org/license.html>
27 * for a copy of the LGPLv3 License.
29 ************************************************************************/
31 #ifndef __com_sun_star_frame_ToolbarController_idl__
32 #define __com_sun_star_frame_ToolbarController_idl__
34 #ifndef __com_sun_star_lang_XInitialization_idl__
35 #include
<com
/sun
/star
/lang
/XInitialization.idl
>
38 #ifndef __com_sun_star_util_XUpdatable_idl__
39 #include
<com
/sun
/star
/util
/XUpdatable.idl
>
42 #ifndef __com_sun_star_frame_XStatusListener_idl__
43 #include
<com
/sun
/star
/frame
/XStatusListener.idl
>
46 #ifndef __com_sun_star_frame_XToolbarController_idl__
47 #include
<com
/sun
/star
/frame
/XToolbarController.idl
>
50 #ifndef __com_sun_star_frame_XSubToolbarController_idl__
51 #include
<com
/sun
/star
/frame
/XSubToolbarController.idl
>
54 //=============================================================================
56 module com
{ module sun
{ module star
{ module frame
{
58 //=============================================================================
59 /** is an abstract service for a component which offers a more complex user
60 interface to users within a toolbar.
63 A generic toolbar function is represented as a button which has a state
64 (enabled,disabled and selected, not selected). A toolbar controller can
65 be added to a toolbar and provide information or functions within a more
66 sophisticated user interface.<br/> A typical example for toolbar controller
67 is the font chooser within the toolbar. It provides all available fonts in
68 a dropdown box and shows the current chosen font.
71 @see com::sun::star::frame::XDispatchProvider
76 service ToolbarController
78 //-------------------------------------------------------------------------
79 /** with this interface a component can receive events if a feature has
83 The toolbar controller implementation should register itself as a
84 listener when its <member scope="com::sun::star::util">XUpdatable</member>
85 interface has been called.
88 interface com
::sun
::star
::frame
::XStatusListener
;
90 /** used to initialize a component with required arguments.
92 A toolbar controller needs at least three additional arguments
93 provided as <type scope="com::sun::star::beans">PropertyValue</type>:
95 <li><b>Frame</b><br>a <type scope="com::sun::star::frame">XFrame</type>
96 instance to which the toolbar controller belongs.</li>
97 <li><b>CommandURL</b><br>a string which specifies the command a
98 toolbar controller is bound.</li>
99 <li><b>ServiceManager</b><br>a
100 <type scope="com::sun::star::lang">XMultiServiceFactory</type>
101 instance which can be used to create additional UNO services.</li>
104 interface com
::sun
::star
::lang
::XInitialization
;
106 /** used to notify an implementation that it needs to add its listener or remove
110 A toolbar controller instance is ready for use after this call has been made
111 the first time. The toolbar implementation guarentees that the controller's
112 item window has been added to the toolbar and its reference is held by it.
115 interface com
::sun
::star
::util
::XUpdatable
;
117 //-------------------------------------------------------------------------
118 /** used to notify changed features and requests for additional user interface
122 Mostly used by a toolbar implementation to forward information to and request
123 services from a toolbar controller component. This interface must be useable
124 after <member scope="com::sun::star::lang">XInitialitation::initialize</member>
125 has been called. The behavior of the interface is undefined if the controller
126 component hasn't been initialized.
129 interface com
::sun
::star
::frame
::XToolbarController
;
131 //-------------------------------------------------------------------------
132 /** used to notify and retrieve information that are specific for sub-toolbar
136 Used by implementations that want to provide the toolbar button/sub-
137 toolbar function feature. A controller supporting this interface exchanges
138 the function of its own toolbar button, that opened the sub-toolbar, with
139 the one that has been selected on the sub-toolbar.
142 [optional] interface ::com
::sun
::star
::frame
::XSubToolbarController
;
145 //=============================================================================