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: XPopupMenuController.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_XPopupMenuController_idl__
32 #define __com_sun_star_frame_XPopupMenuController_idl__
34 #ifndef __com_sun_star_awt_XPopupMenu_idl__
35 #include
<com
/sun
/star
/awt
/XPopupMenu.idl
>
38 //=============================================================================
40 module com
{ module sun
{ module star
{ module frame
{
42 //=============================================================================
44 /** provides data to a popup menu controller implementation to
45 fill and update a popup menu dynamically.
48 A popup menu controller gets a <type scope="com::sun::star::awt">XPopupMenu</type>
49 from its parent menu implementation. The controller has to fill this popup
50 menu with a set of menu items and/or sub menus. The parent menu implementation
51 briefs the controller whenever the popup menu gets activated by a user.
56 interface XPopupMenuController
: com
::sun
::star
::uno
::XInterface
58 /** provides a <type scope="com::sun::star::awt">XPopupMenu</type> to a
59 popup menu controller implementation. The controller must fill this
60 popup menu with its functions.
63 An empty popup menu that must be filled by the popup menu controller.
65 void setPopupMenu
( [in] com
::sun
::star
::awt
::XPopupMenu PopupMenu
);
67 /** briefs the popup menu controller to update the contents of the provided
68 popup menu to reflect the current state.
70 <p>A controller should <b>never</b> update the popup menu structure on its
71 own to prevent performance problems. A better way would be that a controller
72 registers itself as status listener to for a command URL and immediately
73 deregister after that. Therefor status updates will not be send regularly
74 for a non visible popup menu.
77 void updatePopupMenu
();
82 //=============================================================================