merge the formfield patch from ooo-build
[ooovba.git] / offapi / com / sun / star / awt / XContainerWindowEventHandler.idl
blob8b02bdd2b2a1a4ccb5f0db1e1a6e1dba22edb9f2
1 /*************************************************************************
3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
4 *
5 * Copyright 2008 by Sun Microsystems, Inc.
7 * OpenOffice.org - a multi-platform office productivity suite
9 * $RCSfile: XContainerWindowEventHandler.idl,v $
10 * $Revision: 1.3 $
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_awt_XContainerWindowEventHandler_idl__
32 #define __com_sun_star_awt_XContainerWindowEventHandler_idl__
34 #ifndef __com_sun_star_uno_XInterface_idl__
35 #include <com/sun/star/uno/XInterface.idl>
36 #endif
37 #ifndef __com_sun_star_awt_XWindow_idl__
38 #include <com/sun/star/awt/XWindow.idl>
39 #endif
40 #ifndef __com_sun_star_lang_WrappedTargetException_idl__
41 #include <com/sun/star/lang/WrappedTargetException.idl>
42 #endif
45 //=============================================================================
47 module com { module sun { module star { module awt {
49 //=============================================================================
51 /** Handles events fired by windows represented by a
52 <type scope="com::sun::star::awt">XWindow</type> interface.
54 interface XContainerWindowEventHandler : ::com::sun::star::uno::XInterface {
56 //-------------------------------------------------------------------------
58 /** Handles an event generated by a window.
60 The implementation must be aware that the EventObject argument contains types
61 which it is not prepared to handle. Similarly this applies for the MethodName
62 argument. In this case the method should simply return false.
64 @param xWindow
65 the window instance that generated the event. If used in the scope of
66 <type scope="com::sun::star::awt">XContainerWindowProvider</type> this
67 is the same window instance that was returned by the createContainerWindow
68 method when passing the XContainerWindowEventHandler instance receiving the
69 event as handler parameter.
71 @param EventObject
72 an object describing the event which occurred in the window or anything else that
73 provides additional information for the event.
74 If the event was caused by the window or any of the controls which it contains
75 then the any should contain an object derived from
76 <type scope="com::sun::star::lang">EventObject</type>. Typically this would be one
77 of the several com::sun::star::awt::*Event types.
79 @param MethodName
80 the name of the function which is to be called.
82 @returns
83 true if the event was handled, otherwise false.
85 @throws com::sun::star::lang::WrappedTargetException
86 if the implementation of the method, which is determined by the argument MethodName,
87 throws an exception. This exception is then wrapped into a
88 <type scope="com::sun::star::lang">WrappedTargetException</type>.
91 boolean callHandlerMethod(
92 [in] com::sun::star::awt::XWindow xWindow,
93 [in] any EventObject,
94 [in] string MethodName)
95 raises(com::sun::star::lang::WrappedTargetException);
98 /** returns a sequence of supported method names
100 @returns
101 all method names that will be accepted in calls to callHandlerMethod.
103 sequence<string> getSupportedMethodNames();
106 //=============================================================================
108 }; }; }; };
110 #endif