kill multi repo support: BuildDirs and gbuild.mk, GNUmakefile.mk
[LibreOffice.git] / embedserv / source / inc / xwin.hxx
blobe7cdbac531170c2884ec4b436eee6fecdb77a6aa
1 /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
2 /*************************************************************************
4 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
6 * Copyright 2000, 2010 Oracle and/or its affiliates.
8 * OpenOffice.org - a multi-platform office productivity suite
10 * This file is part of OpenOffice.org.
12 * OpenOffice.org is free software: you can redistribute it and/or modify
13 * it under the terms of the GNU Lesser General Public License version 3
14 * only, as published by the Free Software Foundation.
16 * OpenOffice.org is distributed in the hope that it will be useful,
17 * but WITHOUT ANY WARRANTY; without even the implied warranty of
18 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
19 * GNU Lesser General Public License version 3 for more details
20 * (a copy is included in the LICENSE file that accompanied this code).
22 * You should have received a copy of the GNU Lesser General Public License
23 * version 3 along with OpenOffice.org. If not, see
24 * <http://www.openoffice.org/license.html>
25 * for a copy of the LGPLv3 License.
27 ************************************************************************/
29 #ifndef _XWIN_HXX_
30 #define _XWIN_HXX_
33 #include "common.h"
34 #include <osl/mutex.hxx>
35 #include <cppuhelper/interfacecontainer.h>
36 #include <cppuhelper/implbase2.hxx>
37 #include <com/sun/star/awt/XWindow.hpp>
38 #include <com/sun/star/awt/XSystemDependentWindowPeer.hpp>
41 class ContainerWindowWrapper:
42 public ::cppu::WeakImplHelper2<
43 ::com::sun::star::awt::XWindow,
44 ::com::sun::star::awt::XSystemDependentWindowPeer>
46 public:
48 ContainerWindowWrapper(HWND aHwnd);
50 ~ ContainerWindowWrapper();
53 // XComponent
55 virtual void SAL_CALL
56 dispose(
58 throw (
59 ::com::sun::star::uno::RuntimeException
62 virtual void SAL_CALL
63 addEventListener(
64 const ::com::sun::star::uno::Reference<
65 ::com::sun::star::lang::XEventListener >& xListener
67 throw (
68 ::com::sun::star::uno::RuntimeException
71 virtual void SAL_CALL
72 removeEventListener(
73 const ::com::sun::star::uno::Reference<
74 ::com::sun::star::lang::XEventListener >& aListener
76 throw (
77 ::com::sun::star::uno::RuntimeException
81 // XSystemDependentWindowPeer
83 virtual ::com::sun::star::uno::Any SAL_CALL
84 getWindowHandle(
85 const ::com::sun::star::uno::Sequence< sal_Int8 >& ProcessId,
86 sal_Int16 SystemType
88 throw (
89 ::com::sun::star::uno::RuntimeException
92 // XWindow
94 virtual void SAL_CALL
95 setPosSize(
96 sal_Int32 X,
97 sal_Int32 Y,
98 sal_Int32 Width,
99 sal_Int32 Height,
100 sal_Int16 Flags
102 throw (
103 ::com::sun::star::uno::RuntimeException);
105 virtual ::com::sun::star::awt::Rectangle SAL_CALL
106 getPosSize(
108 throw (
109 ::com::sun::star::uno::RuntimeException
112 virtual void SAL_CALL
113 setVisible(
114 sal_Bool Visible
116 throw (
117 ::com::sun::star::uno::RuntimeException
120 virtual void SAL_CALL
121 setEnable(
122 sal_Bool Enable
124 throw (
125 ::com::sun::star::uno::RuntimeException
128 virtual void SAL_CALL
129 setFocus(
131 throw (
132 ::com::sun::star::uno::RuntimeException
135 virtual void SAL_CALL
136 addWindowListener(
137 const ::com::sun::star::uno::Reference<
138 ::com::sun::star::awt::XWindowListener >& xListener
140 throw (
141 ::com::sun::star::uno::RuntimeException
144 virtual void SAL_CALL
145 removeWindowListener(
146 const ::com::sun::star::uno::Reference<
147 ::com::sun::star::awt::XWindowListener >& xListener
149 throw (
150 ::com::sun::star::uno::RuntimeException
153 virtual void SAL_CALL
154 addFocusListener(
155 const ::com::sun::star::uno::Reference<
156 ::com::sun::star::awt::XFocusListener >& xListener
158 throw (
159 ::com::sun::star::uno::RuntimeException
162 virtual void SAL_CALL
163 removeFocusListener(
164 const ::com::sun::star::uno::Reference<
165 ::com::sun::star::awt::XFocusListener >& xListener
167 throw (
168 ::com::sun::star::uno::RuntimeException
171 virtual void SAL_CALL
172 addKeyListener(
173 const ::com::sun::star::uno::Reference<
174 ::com::sun::star::awt::XKeyListener >& xListener
176 throw (
177 ::com::sun::star::uno::RuntimeException
180 virtual void SAL_CALL
181 removeKeyListener(
182 const ::com::sun::star::uno::Reference<
183 ::com::sun::star::awt::XKeyListener >& xListener
185 throw (
186 ::com::sun::star::uno::RuntimeException
189 virtual void SAL_CALL
190 addMouseListener(
191 const ::com::sun::star::uno::Reference<
192 ::com::sun::star::awt::XMouseListener >& xListener
194 throw (
195 ::com::sun::star::uno::RuntimeException
198 virtual void SAL_CALL
199 removeMouseListener(
200 const ::com::sun::star::uno::Reference<
201 ::com::sun::star::awt::XMouseListener >& xListener
203 throw (
204 ::com::sun::star::uno::RuntimeException
207 virtual void SAL_CALL
208 addMouseMotionListener(
209 const ::com::sun::star::uno::Reference<
210 ::com::sun::star::awt::XMouseMotionListener >& xListener
212 throw (
213 ::com::sun::star::uno::RuntimeException
216 virtual void SAL_CALL
217 removeMouseMotionListener(
218 const ::com::sun::star::uno::Reference<
219 ::com::sun::star::awt::XMouseMotionListener >& xListener
221 throw (
222 ::com::sun::star::uno::RuntimeException
225 virtual void SAL_CALL
226 addPaintListener(
227 const ::com::sun::star::uno::Reference<
228 ::com::sun::star::awt::XPaintListener >& xListener
230 throw (
231 ::com::sun::star::uno::RuntimeException
234 virtual void SAL_CALL
235 removePaintListener(
236 const ::com::sun::star::uno::Reference<
237 ::com::sun::star::awt::XPaintListener >& xListener
239 throw (
240 ::com::sun::star::uno::RuntimeException
244 private:
246 osl::Mutex m_aMutex;
247 cppu::OInterfaceContainerHelper *m_pDisposeEventListeners;
249 HWND m_aHwnd;
253 #endif
255 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */