Line data Source code
1 : /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
2 : /*
3 : * This file is part of the LibreOffice project.
4 : *
5 : * This Source Code Form is subject to the terms of the Mozilla Public
6 : * License, v. 2.0. If a copy of the MPL was not distributed with this
7 : * file, You can obtain one at http://mozilla.org/MPL/2.0/.
8 : *
9 : * This file incorporates work covered by the following license notice:
10 : *
11 : * Licensed to the Apache Software Foundation (ASF) under one or more
12 : * contributor license agreements. See the NOTICE file distributed
13 : * with this work for additional information regarding copyright
14 : * ownership. The ASF licenses this file to you under the Apache
15 : * License, Version 2.0 (the "License"); you may not use this file
16 : * except in compliance with the License. You may obtain a copy of
17 : * the License at http://www.apache.org/licenses/LICENSE-2.0 .
18 : */
19 :
20 : #ifndef INCLUDED_TOOLKIT_CONTROLS_UNOCONTROLS_HXX
21 : #define INCLUDED_TOOLKIT_CONTROLS_UNOCONTROLS_HXX
22 :
23 : #include <toolkit/dllapi.h>
24 : #include <com/sun/star/awt/XTextComponent.hpp>
25 : #include <com/sun/star/awt/XTextListener.hpp>
26 : #include <com/sun/star/awt/XLayoutConstrains.hpp>
27 : #include <com/sun/star/awt/XTextLayoutConstrains.hpp>
28 : #include <com/sun/star/awt/XButton.hpp>
29 : #include <com/sun/star/awt/XToggleButton.hpp>
30 : #include <com/sun/star/awt/XRadioButton.hpp>
31 : #include <com/sun/star/awt/XItemListener.hpp>
32 : #include <com/sun/star/awt/XCheckBox.hpp>
33 : #include <com/sun/star/awt/XFixedHyperlink.hpp>
34 : #include <com/sun/star/awt/XFixedText.hpp>
35 : #include <com/sun/star/awt/XListBox.hpp>
36 : #include <com/sun/star/awt/XComboBox.hpp>
37 : #include <com/sun/star/awt/XDateField.hpp>
38 : #include <com/sun/star/awt/XSpinField.hpp>
39 : #include <com/sun/star/awt/XTimeField.hpp>
40 : #include <com/sun/star/awt/XNumericField.hpp>
41 : #include <com/sun/star/awt/XCurrencyField.hpp>
42 : #include <com/sun/star/awt/XPatternField.hpp>
43 : #include <com/sun/star/awt/XProgressBar.hpp>
44 : #include <com/sun/star/awt/XItemList.hpp>
45 : #include <com/sun/star/graphic/XGraphicObject.hpp>
46 : #include <toolkit/controls/unocontrolmodel.hxx>
47 : #include <toolkit/controls/unocontrolbase.hxx>
48 : #include <toolkit/helper/macros.hxx>
49 : #include <toolkit/helper/servicenames.hxx>
50 : #include <vcl/bitmapex.hxx>
51 : #include <cppuhelper/implbase5.hxx>
52 : #include <cppuhelper/implbase4.hxx>
53 : #include <cppuhelper/implbase2.hxx>
54 : #include <cppuhelper/implbase1.hxx>
55 : #include <comphelper/uno3.hxx>
56 :
57 : #include <list>
58 : #include <vector>
59 :
60 : #include <boost/scoped_ptr.hpp>
61 : #include <boost/optional.hpp>
62 :
63 : #define UNO_NAME_GRAPHOBJ_URLPREFIX "vnd.sun.star.GraphicObject:"
64 :
65 : class ImageHelper
66 : {
67 : public:
68 : // The routine will always attempt to return a valid XGraphic for the
69 : // passed _rURL, additionallly xOutGraphicObject will contain the
70 : // associated XGraphicObject ( if url is valid for that ) and is set
71 : // appropriately ( e.g. NULL if non GraphicObject scheme ) or a valid
72 : // object if the rURL points to a valid object
73 : static ::com::sun::star::uno::Reference< ::com::sun::star::graphic::XGraphic > getGraphicAndGraphicObjectFromURL_nothrow( ::com::sun::star::uno::Reference< ::com::sun::star::graphic::XGraphicObject >& xOutGraphicObject, const OUString& _rURL );
74 : static ::com::sun::star::uno::Reference< ::com::sun::star::graphic::XGraphic > getGraphicFromURL_nothrow( const OUString& _rURL );
75 :
76 : };
77 :
78 :
79 : // class UnoControlEditModel
80 :
81 36 : class UnoControlEditModel : public UnoControlModel
82 : {
83 : protected:
84 : ::com::sun::star::uno::Any ImplGetDefaultValue( sal_uInt16 nPropId ) const SAL_OVERRIDE;
85 : ::cppu::IPropertyArrayHelper& SAL_CALL getInfoHelper() SAL_OVERRIDE;
86 :
87 : public:
88 : UnoControlEditModel( const ::com::sun::star::uno::Reference< ::com::sun::star::uno::XComponentContext >& rxContext );
89 2 : UnoControlEditModel( const UnoControlEditModel& rModel ) : UnoControlModel( rModel ) {;}
90 :
91 2 : UnoControlModel* Clone() const SAL_OVERRIDE { return new UnoControlEditModel( *this ); }
92 :
93 : // ::com::sun::star::io::XPersistObject
94 : OUString SAL_CALL getServiceName() throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
95 :
96 : // ::com::sun::star::beans::XMultiPropertySet
97 : ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertySetInfo > SAL_CALL getPropertySetInfo( ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
98 :
99 :
100 : // XServiceInfo
101 208 : DECLIMPL_SERVICEINFO_DERIVED( UnoControlEditModel, UnoControlModel, szServiceName2_UnoControlEditModel )
102 : };
103 :
104 :
105 : // class UnoEditControl
106 :
107 : typedef ::cppu::ImplHelper4 < ::com::sun::star::awt::XTextComponent
108 : , ::com::sun::star::awt::XTextListener
109 : , ::com::sun::star::awt::XLayoutConstrains
110 : , ::com::sun::star::awt::XTextLayoutConstrains
111 : > UnoEditControl_Base;
112 200 : class TOOLKIT_DLLPUBLIC UnoEditControl :public UnoControlBase
113 : ,public UnoEditControl_Base
114 : {
115 : private:
116 : TextListenerMultiplexer maTextListeners;
117 :
118 : // Not all fields derived from UnoEditCOntrol have the property "Text"
119 : // They only support XTextComponent, so keep the text
120 : // here, maybe there is no Peer when calling setText()...
121 : OUString maText;
122 : sal_uInt16 mnMaxTextLen;
123 :
124 : bool mbSetTextInPeer;
125 : bool mbSetMaxTextLenInPeer;
126 : bool mbHasTextProperty;
127 :
128 : public:
129 :
130 : UnoEditControl();
131 : OUString GetComponentServiceName() SAL_OVERRIDE;
132 992 : TextListenerMultiplexer& GetTextListeners() { return maTextListeners; }
133 :
134 : void ImplSetPeerProperty( const OUString& rPropName, const ::com::sun::star::uno::Any& rVal ) SAL_OVERRIDE;
135 :
136 : void SAL_CALL createPeer( const ::com::sun::star::uno::Reference< ::com::sun::star::awt::XToolkit >& Toolkit, const ::com::sun::star::uno::Reference< ::com::sun::star::awt::XWindowPeer >& Parent ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
137 380 : void SAL_CALL disposing( const ::com::sun::star::lang::EventObject& Source ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE { UnoControlBase::disposing( Source ); }
138 : void SAL_CALL dispose( ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
139 :
140 : // disambiguate XInterface
141 : DECLARE_XINTERFACE()
142 :
143 : // XAggregation
144 : ::com::sun::star::uno::Any SAL_CALL queryAggregation( const ::com::sun::star::uno::Type & rType ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
145 :
146 : // XTypeProvider
147 : DECLARE_XTYPEPROVIDER()
148 :
149 : // XTextListener
150 : void SAL_CALL textChanged( const ::com::sun::star::awt::TextEvent& rEvent ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
151 :
152 : // XTextComponent
153 : void SAL_CALL addTextListener( const ::com::sun::star::uno::Reference< ::com::sun::star::awt::XTextListener >& l ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
154 : void SAL_CALL removeTextListener( const ::com::sun::star::uno::Reference< ::com::sun::star::awt::XTextListener >& l ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
155 : void SAL_CALL setText( const OUString& aText ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
156 : void SAL_CALL insertText( const ::com::sun::star::awt::Selection& Sel, const OUString& Text ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
157 : OUString SAL_CALL getText( ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
158 : OUString SAL_CALL getSelectedText( ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
159 : void SAL_CALL setSelection( const ::com::sun::star::awt::Selection& aSelection ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
160 : ::com::sun::star::awt::Selection SAL_CALL getSelection( ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
161 : sal_Bool SAL_CALL isEditable( ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
162 : void SAL_CALL setEditable( sal_Bool bEditable ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
163 : void SAL_CALL setMaxTextLen( sal_Int16 nLen ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
164 : sal_Int16 SAL_CALL getMaxTextLen( ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
165 :
166 : // XLayoutConstrains
167 : ::com::sun::star::awt::Size SAL_CALL getMinimumSize( ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
168 : ::com::sun::star::awt::Size SAL_CALL getPreferredSize( ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
169 : ::com::sun::star::awt::Size SAL_CALL calcAdjustedSize( const ::com::sun::star::awt::Size& aNewSize ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
170 :
171 : // XTextLayoutConstrains
172 : ::com::sun::star::awt::Size SAL_CALL getMinimumSize( sal_Int16 nCols, sal_Int16 nLines ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
173 : void SAL_CALL getColumnsAndLines( sal_Int16& nCols, sal_Int16& nLines ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
174 :
175 : // XServiceInfo
176 : OUString SAL_CALL getImplementationName( ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
177 : ::com::sun::star::uno::Sequence< OUString > SAL_CALL getSupportedServiceNames() throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
178 :
179 : sal_Bool SAL_CALL setModel(const ::com::sun::star::uno::Reference< ::com::sun::star::awt::XControlModel >& Model) throw ( ::com::sun::star::uno::RuntimeException, std::exception ) SAL_OVERRIDE;
180 : };
181 :
182 :
183 : // class UnoControlFileControlModel
184 :
185 32 : class UnoControlFileControlModel : public UnoControlModel
186 : {
187 : protected:
188 : ::com::sun::star::uno::Any ImplGetDefaultValue( sal_uInt16 nPropId ) const SAL_OVERRIDE;
189 : ::cppu::IPropertyArrayHelper& SAL_CALL getInfoHelper() SAL_OVERRIDE;
190 :
191 : public:
192 : UnoControlFileControlModel( const ::com::sun::star::uno::Reference< ::com::sun::star::uno::XComponentContext >& rxContext );
193 2 : UnoControlFileControlModel( const UnoControlFileControlModel& rModel ) : UnoControlModel( rModel ) {;}
194 :
195 2 : UnoControlModel* Clone() const SAL_OVERRIDE { return new UnoControlFileControlModel( *this ); }
196 :
197 : // ::com::sun::star::io::XPersistObject
198 : OUString SAL_CALL getServiceName() throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
199 :
200 : // ::com::sun::star::beans::XMultiPropertySet
201 : ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertySetInfo > SAL_CALL getPropertySetInfo( ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
202 :
203 : // ::com::sun::star::lang::XServiceInfo
204 16 : DECLIMPL_SERVICEINFO_DERIVED( UnoControlFileControlModel, UnoControlModel, szServiceName2_UnoControlFileControlModel )
205 : };
206 :
207 :
208 : // class UnoFileControl
209 :
210 0 : class UnoFileControl : public UnoEditControl
211 : {
212 : public:
213 : UnoFileControl();
214 : OUString GetComponentServiceName() SAL_OVERRIDE;
215 :
216 : // ::com::sun::star::lang::XServiceInfo
217 0 : DECLIMPL_SERVICEINFO_DERIVED( UnoFileControl, UnoEditControl, szServiceName2_UnoControlFileControl )
218 : };
219 :
220 :
221 : // class GraphicControlModel
222 :
223 240 : class GraphicControlModel : public UnoControlModel
224 : {
225 : private:
226 : bool mbAdjustingImagePosition;
227 : bool mbAdjustingGraphic;
228 :
229 : ::com::sun::star::uno::Reference< ::com::sun::star::graphic::XGraphicObject > mxGrfObj;
230 :
231 : protected:
232 272 : GraphicControlModel( const ::com::sun::star::uno::Reference< ::com::sun::star::uno::XComponentContext >& rxContext )
233 : :UnoControlModel( rxContext )
234 : ,mbAdjustingImagePosition( false )
235 272 : ,mbAdjustingGraphic( false )
236 : {
237 272 : }
238 18 : GraphicControlModel( const GraphicControlModel& _rSource ) : UnoControlModel( _rSource ), mbAdjustingImagePosition( false ), mbAdjustingGraphic( false ) { }
239 :
240 : // ::cppu::OPropertySetHelper
241 : void SAL_CALL setFastPropertyValue_NoBroadcast( sal_Int32 nHandle, const ::com::sun::star::uno::Any& rValue ) throw (::com::sun::star::uno::Exception, std::exception) SAL_OVERRIDE;
242 :
243 : // UnoControlModel
244 : ::com::sun::star::uno::Any ImplGetDefaultValue( sal_uInt16 nPropId ) const SAL_OVERRIDE;
245 :
246 : private:
247 : GraphicControlModel& operator=( const GraphicControlModel& ); // never implemented
248 : };
249 :
250 :
251 : // class UnoControlButtonModel
252 :
253 212 : class UnoControlButtonModel : public GraphicControlModel
254 : {
255 : protected:
256 : ::com::sun::star::uno::Any ImplGetDefaultValue( sal_uInt16 nPropId ) const SAL_OVERRIDE;
257 : ::cppu::IPropertyArrayHelper& SAL_CALL getInfoHelper() SAL_OVERRIDE;
258 :
259 : public:
260 : UnoControlButtonModel( const ::com::sun::star::uno::Reference< ::com::sun::star::uno::XComponentContext >& rxContext );
261 4 : UnoControlButtonModel( const UnoControlButtonModel& rModel ) : GraphicControlModel( rModel ) {;}
262 :
263 4 : UnoControlModel* Clone() const SAL_OVERRIDE { return new UnoControlButtonModel( *this ); }
264 :
265 : // ::com::sun::star::beans::XMultiPropertySet
266 : ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertySetInfo > SAL_CALL getPropertySetInfo( ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
267 :
268 : // ::com::sun::star::io::XPersistObject
269 : OUString SAL_CALL getServiceName() throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
270 :
271 : // ::com::sun::star::lang::XServiceInfo
272 84 : DECLIMPL_SERVICEINFO_DERIVED( UnoControlButtonModel, GraphicControlModel, szServiceName2_UnoControlButtonModel )
273 : };
274 :
275 :
276 : // class UnoButtonControl
277 :
278 : typedef ::cppu::AggImplInheritanceHelper4 < UnoControlBase
279 : , ::com::sun::star::awt::XButton
280 : , ::com::sun::star::awt::XToggleButton
281 : , ::com::sun::star::awt::XLayoutConstrains
282 : , ::com::sun::star::awt::XItemListener
283 : > UnoButtonControl_Base;
284 456 : class UnoButtonControl : public UnoButtonControl_Base
285 : {
286 : private:
287 : ActionListenerMultiplexer maActionListeners;
288 : ItemListenerMultiplexer maItemListeners;
289 : OUString maActionCommand;
290 :
291 : public:
292 :
293 : UnoButtonControl();
294 : OUString GetComponentServiceName() SAL_OVERRIDE;
295 :
296 : void SAL_CALL createPeer( const ::com::sun::star::uno::Reference< ::com::sun::star::awt::XToolkit >& Toolkit, const ::com::sun::star::uno::Reference< ::com::sun::star::awt::XWindowPeer >& Parent ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
297 : void SAL_CALL dispose( ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
298 :
299 : // ::com::sun::star::awt::XButton
300 : void SAL_CALL addActionListener( const ::com::sun::star::uno::Reference< ::com::sun::star::awt::XActionListener >& l ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
301 : void SAL_CALL removeActionListener( const ::com::sun::star::uno::Reference< ::com::sun::star::awt::XActionListener >& l ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
302 : void SAL_CALL setLabel( const OUString& Label ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
303 : void SAL_CALL setActionCommand( const OUString& Command ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
304 :
305 : // ::com::sun::star::awt::XToggleButton
306 : // ::com::sun::star::awt::XItemEventBroadcaster
307 : void SAL_CALL addItemListener( const ::com::sun::star::uno::Reference< ::com::sun::star::awt::XItemListener >& l ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
308 : void SAL_CALL removeItemListener( const ::com::sun::star::uno::Reference< ::com::sun::star::awt::XItemListener >& l ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
309 :
310 : // ::com::sun::star::lang::XEventListener
311 : virtual void SAL_CALL disposing( const ::com::sun::star::lang::EventObject& Source ) throw (::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
312 :
313 : // XItemListener
314 : virtual void SAL_CALL itemStateChanged( const ::com::sun::star::awt::ItemEvent& rEvent ) throw (::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
315 :
316 : // ::com::sun::star::awt::XLayoutConstrains
317 : ::com::sun::star::awt::Size SAL_CALL getMinimumSize( ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
318 : ::com::sun::star::awt::Size SAL_CALL getPreferredSize( ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
319 : ::com::sun::star::awt::Size SAL_CALL calcAdjustedSize( const ::com::sun::star::awt::Size& aNewSize ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
320 :
321 : // ::com::sun::star::lang::XServiceInfo
322 2 : DECLIMPL_SERVICEINFO_DERIVED( UnoButtonControl, UnoControlBase, szServiceName2_UnoControlButton )
323 : };
324 :
325 :
326 : // class UnoControlImageControlModel
327 :
328 60 : class UnoControlImageControlModel : public GraphicControlModel
329 : {
330 : private:
331 : bool mbAdjustingImageScaleMode;
332 :
333 : protected:
334 : ::com::sun::star::uno::Any ImplGetDefaultValue( sal_uInt16 nPropId ) const SAL_OVERRIDE;
335 : ::cppu::IPropertyArrayHelper& SAL_CALL getInfoHelper() SAL_OVERRIDE;
336 :
337 : public:
338 : UnoControlImageControlModel( const ::com::sun::star::uno::Reference< ::com::sun::star::uno::XComponentContext >& rxContext );
339 6 : UnoControlImageControlModel( const UnoControlImageControlModel& rModel ) : GraphicControlModel( rModel ), mbAdjustingImageScaleMode( false ) { }
340 :
341 6 : UnoControlModel* Clone() const SAL_OVERRIDE { return new UnoControlImageControlModel( *this ); }
342 :
343 : // ::com::sun::star::beans::XMultiPropertySet
344 : ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertySetInfo > SAL_CALL getPropertySetInfo( ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
345 :
346 : // ::com::sun::star::io::XPersistObject
347 : OUString SAL_CALL getServiceName() throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
348 :
349 : // ::com::sun::star::lang::XServiceInfo
350 34 : DECLIMPL_SERVICEINFO_DERIVED( UnoControlImageControlModel, GraphicControlModel, szServiceName2_UnoControlImageControlModel )
351 :
352 : // ::cppu::OPropertySetHelper
353 : void SAL_CALL setFastPropertyValue_NoBroadcast( sal_Int32 nHandle, const ::com::sun::star::uno::Any& rValue ) throw (::com::sun::star::uno::Exception, std::exception) SAL_OVERRIDE;
354 : };
355 :
356 :
357 : // class UnoImageControlControl
358 :
359 : typedef ::cppu::AggImplInheritanceHelper1 < UnoControlBase
360 : , ::com::sun::star::awt::XLayoutConstrains
361 : > UnoImageControlControl_Base;
362 44 : class UnoImageControlControl : public UnoImageControlControl_Base
363 : {
364 : private:
365 : ActionListenerMultiplexer maActionListeners;
366 :
367 : public:
368 :
369 : UnoImageControlControl();
370 : OUString GetComponentServiceName() SAL_OVERRIDE;
371 :
372 : void SAL_CALL dispose( ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
373 :
374 : // ::com::sun::star::awt::XControl
375 : sal_Bool SAL_CALL isTransparent( ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
376 :
377 : // ::com::sun::star::awt::XLayoutConstrains
378 : ::com::sun::star::awt::Size SAL_CALL getMinimumSize( ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
379 : ::com::sun::star::awt::Size SAL_CALL getPreferredSize( ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
380 : ::com::sun::star::awt::Size SAL_CALL calcAdjustedSize( const ::com::sun::star::awt::Size& aNewSize ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
381 :
382 : // ::com::sun::star::lang::XServiceInfo
383 2 : DECLIMPL_SERVICEINFO_DERIVED( UnoImageControlControl, UnoControlBase, szServiceName2_UnoControlImageControl )
384 : };
385 :
386 :
387 : // class UnoControlRadioButtonModel
388 :
389 104 : class UnoControlRadioButtonModel : public GraphicControlModel
390 :
391 : {
392 : protected:
393 : ::com::sun::star::uno::Any ImplGetDefaultValue( sal_uInt16 nPropId ) const SAL_OVERRIDE;
394 : ::cppu::IPropertyArrayHelper& SAL_CALL getInfoHelper() SAL_OVERRIDE;
395 :
396 : public:
397 : UnoControlRadioButtonModel( const ::com::sun::star::uno::Reference< ::com::sun::star::uno::XComponentContext >& rxContext );
398 4 : UnoControlRadioButtonModel( const UnoControlRadioButtonModel& rModel ) : GraphicControlModel( rModel ) {;}
399 :
400 4 : UnoControlModel* Clone() const SAL_OVERRIDE { return new UnoControlRadioButtonModel( *this ); }
401 :
402 : // ::com::sun::star::io::XPersistObject
403 : OUString SAL_CALL getServiceName() throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
404 :
405 : // ::com::sun::star::beans::XMultiPropertySet
406 : ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertySetInfo > SAL_CALL getPropertySetInfo( ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
407 :
408 : // ::com::sun::star::lang::XServiceInfo
409 68 : DECLIMPL_SERVICEINFO_DERIVED( UnoControlRadioButtonModel, GraphicControlModel, szServiceName2_UnoControlRadioButtonModel )
410 :
411 : };
412 :
413 :
414 : // class UnoRadioButtonControl
415 :
416 : typedef ::cppu::AggImplInheritanceHelper4 < UnoControlBase
417 : , ::com::sun::star::awt::XButton
418 : , ::com::sun::star::awt::XRadioButton
419 : , ::com::sun::star::awt::XItemListener
420 : , ::com::sun::star::awt::XLayoutConstrains
421 : > UnoRadioButtonControl_Base;
422 72 : class UnoRadioButtonControl : public UnoRadioButtonControl_Base
423 : {
424 : private:
425 : ItemListenerMultiplexer maItemListeners;
426 : ActionListenerMultiplexer maActionListeners;
427 : OUString maActionCommand;
428 :
429 : public:
430 :
431 : UnoRadioButtonControl();
432 : OUString GetComponentServiceName() SAL_OVERRIDE;
433 :
434 : void SAL_CALL createPeer( const ::com::sun::star::uno::Reference< ::com::sun::star::awt::XToolkit >& Toolkit, const ::com::sun::star::uno::Reference< ::com::sun::star::awt::XWindowPeer >& Parent ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
435 : void SAL_CALL dispose( ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
436 48 : void SAL_CALL disposing( const ::com::sun::star::lang::EventObject& Source ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE { UnoControlBase::disposing( Source ); }
437 :
438 : // ::com::sun::star::awt::XControl
439 : sal_Bool SAL_CALL isTransparent( ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
440 :
441 : // ::com::sun::star::awt::XButton
442 : void SAL_CALL addActionListener( const ::com::sun::star::uno::Reference< ::com::sun::star::awt::XActionListener >& l ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
443 : void SAL_CALL removeActionListener( const ::com::sun::star::uno::Reference< ::com::sun::star::awt::XActionListener >& l ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
444 : void SAL_CALL setActionCommand( const OUString& Command ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
445 :
446 : // ::com::sun::star::awt::XRadioButton
447 : void SAL_CALL addItemListener( const ::com::sun::star::uno::Reference< ::com::sun::star::awt::XItemListener >& l ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
448 : void SAL_CALL removeItemListener( const ::com::sun::star::uno::Reference< ::com::sun::star::awt::XItemListener >& l ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
449 : sal_Bool SAL_CALL getState( ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
450 : void SAL_CALL setState( sal_Bool b ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
451 : void SAL_CALL setLabel( const OUString& Label ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
452 :
453 : // ::com::sun::star::awt::XItemListener
454 : void SAL_CALL itemStateChanged( const ::com::sun::star::awt::ItemEvent& rEvent ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
455 :
456 : // ::com::sun::star::awt::XLayoutConstrains
457 : ::com::sun::star::awt::Size SAL_CALL getMinimumSize( ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
458 : ::com::sun::star::awt::Size SAL_CALL getPreferredSize( ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
459 : ::com::sun::star::awt::Size SAL_CALL calcAdjustedSize( const ::com::sun::star::awt::Size& aNewSize ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
460 :
461 : // ::com::sun::star::lang::XServiceInfo
462 2 : DECLIMPL_SERVICEINFO_DERIVED( UnoRadioButtonControl, UnoControlBase, szServiceName2_UnoControlRadioButton )
463 :
464 : };
465 :
466 :
467 : // class UnoControlCheckBoxModel
468 :
469 100 : class UnoControlCheckBoxModel : public GraphicControlModel
470 : {
471 : protected:
472 : ::com::sun::star::uno::Any ImplGetDefaultValue( sal_uInt16 nPropId ) const SAL_OVERRIDE;
473 : ::cppu::IPropertyArrayHelper& SAL_CALL getInfoHelper() SAL_OVERRIDE;
474 :
475 : public:
476 : UnoControlCheckBoxModel( const ::com::sun::star::uno::Reference< ::com::sun::star::uno::XComponentContext >& rxContext );
477 4 : UnoControlCheckBoxModel( const UnoControlCheckBoxModel& rModel ) : GraphicControlModel( rModel ) {;}
478 :
479 4 : UnoControlModel* Clone() const SAL_OVERRIDE { return new UnoControlCheckBoxModel( *this ); }
480 :
481 : // ::com::sun::star::io::XPersistObject
482 : OUString SAL_CALL getServiceName() throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
483 :
484 : // ::com::sun::star::beans::XMultiPropertySet
485 : ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertySetInfo > SAL_CALL getPropertySetInfo( ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
486 :
487 : // ::com::sun::star::lang::XServiceInfo
488 50 : DECLIMPL_SERVICEINFO_DERIVED( UnoControlCheckBoxModel, GraphicControlModel, szServiceName2_UnoControlCheckBoxModel )
489 : };
490 :
491 :
492 : // class UnoCheckBoxControl
493 :
494 : typedef ::cppu::AggImplInheritanceHelper4 < UnoControlBase
495 : , ::com::sun::star::awt::XButton
496 : , ::com::sun::star::awt::XCheckBox
497 : , ::com::sun::star::awt::XItemListener
498 : , ::com::sun::star::awt::XLayoutConstrains
499 : > UnoCheckBoxControl_Base;
500 : class UnoCheckBoxControl : public UnoCheckBoxControl_Base
501 : {
502 : private:
503 : ItemListenerMultiplexer maItemListeners;
504 : ActionListenerMultiplexer maActionListeners;
505 : OUString maActionCommand;
506 :
507 : public:
508 :
509 : UnoCheckBoxControl();
510 76 : virtual ~UnoCheckBoxControl(){;}
511 : OUString GetComponentServiceName() SAL_OVERRIDE;
512 :
513 : void SAL_CALL createPeer( const ::com::sun::star::uno::Reference< ::com::sun::star::awt::XToolkit >& Toolkit, const ::com::sun::star::uno::Reference< ::com::sun::star::awt::XWindowPeer >& Parent ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
514 : void SAL_CALL dispose( ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
515 48 : void SAL_CALL disposing( const ::com::sun::star::lang::EventObject& Source ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE { UnoControlBase::disposing( Source ); }
516 :
517 : // ::com::sun::star::awt::XControl
518 : sal_Bool SAL_CALL isTransparent( ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
519 :
520 : // ::com::sun::star::awt::XButton
521 : void SAL_CALL addActionListener( const ::com::sun::star::uno::Reference< ::com::sun::star::awt::XActionListener >& l ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
522 : void SAL_CALL removeActionListener( const ::com::sun::star::uno::Reference< ::com::sun::star::awt::XActionListener >& l ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
523 : void SAL_CALL setActionCommand( const OUString& Command ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
524 :
525 : virtual void SAL_CALL addItemListener( const ::com::sun::star::uno::Reference< ::com::sun::star::awt::XItemListener >& l ) throw (::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
526 : virtual void SAL_CALL removeItemListener( const ::com::sun::star::uno::Reference< ::com::sun::star::awt::XItemListener >& l ) throw (::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
527 :
528 :
529 : sal_Int16 SAL_CALL getState( ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
530 : void SAL_CALL setState( sal_Int16 n ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
531 : void SAL_CALL setLabel( const OUString& Label ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
532 : void SAL_CALL enableTriState( sal_Bool b ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
533 :
534 : // ::com::sun::star::awt::XItemListener
535 : void SAL_CALL itemStateChanged( const ::com::sun::star::awt::ItemEvent& rEvent ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
536 :
537 : // ::com::sun::star::awt::XLayoutConstrains
538 : ::com::sun::star::awt::Size SAL_CALL getMinimumSize( ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
539 : ::com::sun::star::awt::Size SAL_CALL getPreferredSize( ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
540 : ::com::sun::star::awt::Size SAL_CALL calcAdjustedSize( const ::com::sun::star::awt::Size& aNewSize ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
541 :
542 : // ::com::sun::star::lang::XServiceInfo
543 2 : DECLIMPL_SERVICEINFO_DERIVED( UnoCheckBoxControl, UnoControlBase, szServiceName2_UnoControlCheckBox )
544 :
545 : };
546 :
547 :
548 : // class UnoControlFixedTextModel
549 :
550 0 : class UnoControlFixedHyperlinkModel : public UnoControlModel
551 : {
552 : protected:
553 : ::com::sun::star::uno::Any ImplGetDefaultValue( sal_uInt16 nPropId ) const SAL_OVERRIDE;
554 : ::cppu::IPropertyArrayHelper& SAL_CALL getInfoHelper() SAL_OVERRIDE;
555 :
556 : public:
557 : UnoControlFixedHyperlinkModel( const ::com::sun::star::uno::Reference< ::com::sun::star::uno::XComponentContext >& rxContext );
558 0 : UnoControlFixedHyperlinkModel( const UnoControlFixedHyperlinkModel& rModel ) : UnoControlModel( rModel ) {;}
559 :
560 0 : UnoControlModel* Clone() const SAL_OVERRIDE { return new UnoControlFixedHyperlinkModel( *this ); }
561 :
562 : // ::com::sun::star::io::XPersistObject
563 : OUString SAL_CALL getServiceName() throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
564 :
565 : // ::com::sun::star::beans::XMultiPropertySet
566 : ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertySetInfo > SAL_CALL getPropertySetInfo( ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
567 :
568 : // ::com::sun::star::lang::XServiceInfo
569 0 : DECLIMPL_SERVICEINFO_DERIVED( UnoControlFixedHyperlinkModel, UnoControlModel, szServiceName_UnoControlFixedHyperlinkModel )
570 : };
571 :
572 :
573 : // class UnoFixedHyperlinkControl
574 :
575 0 : class UnoFixedHyperlinkControl : public UnoControlBase,
576 : public ::com::sun::star::awt::XFixedHyperlink,
577 : public ::com::sun::star::awt::XLayoutConstrains
578 : {
579 : private:
580 : ActionListenerMultiplexer maActionListeners;
581 :
582 : public:
583 : UnoFixedHyperlinkControl();
584 :
585 : OUString GetComponentServiceName() SAL_OVERRIDE;
586 :
587 0 : ::com::sun::star::uno::Any SAL_CALL queryInterface( const ::com::sun::star::uno::Type & rType ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE { return UnoControlBase::queryInterface(rType); }
588 : ::com::sun::star::uno::Any SAL_CALL queryAggregation( const ::com::sun::star::uno::Type & rType ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
589 0 : void SAL_CALL acquire() throw() SAL_OVERRIDE { OWeakAggObject::acquire(); }
590 0 : void SAL_CALL release() throw() SAL_OVERRIDE { OWeakAggObject::release(); }
591 :
592 : void SAL_CALL createPeer( const ::com::sun::star::uno::Reference< ::com::sun::star::awt::XToolkit >& Toolkit, const ::com::sun::star::uno::Reference< ::com::sun::star::awt::XWindowPeer >& Parent ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
593 : void SAL_CALL dispose( ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
594 :
595 : // ::com::sun::star::lang::XTypeProvider
596 : ::com::sun::star::uno::Sequence< ::com::sun::star::uno::Type > SAL_CALL getTypes() throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
597 : ::com::sun::star::uno::Sequence< sal_Int8 > SAL_CALL getImplementationId() throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
598 :
599 : // ::com::sun::star::awt::XControl
600 : sal_Bool SAL_CALL isTransparent( ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
601 :
602 : // ::com::sun::star::awt::XFixedHyperlink
603 : void SAL_CALL setText( const OUString& Text ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
604 : OUString SAL_CALL getText( ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
605 : void SAL_CALL setURL( const OUString& URL ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
606 : OUString SAL_CALL getURL( ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
607 : void SAL_CALL setAlignment( sal_Int16 nAlign ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
608 : sal_Int16 SAL_CALL getAlignment( ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
609 : void SAL_CALL addActionListener( const ::com::sun::star::uno::Reference< ::com::sun::star::awt::XActionListener >& l ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
610 : void SAL_CALL removeActionListener( const ::com::sun::star::uno::Reference< ::com::sun::star::awt::XActionListener >& l ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
611 :
612 : // ::com::sun::star::awt::XLayoutConstrains
613 : ::com::sun::star::awt::Size SAL_CALL getMinimumSize( ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
614 : ::com::sun::star::awt::Size SAL_CALL getPreferredSize( ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
615 : ::com::sun::star::awt::Size SAL_CALL calcAdjustedSize( const ::com::sun::star::awt::Size& aNewSize ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
616 :
617 : // ::com::sun::star::lang::XServiceInfo
618 0 : DECLIMPL_SERVICEINFO_DERIVED( UnoFixedHyperlinkControl, UnoControlBase, szServiceName_UnoControlFixedHyperlink )
619 : };
620 :
621 :
622 : // class UnoControlFixedTextModel
623 :
624 304 : class UnoControlFixedTextModel : public UnoControlModel
625 : {
626 : protected:
627 : ::com::sun::star::uno::Any ImplGetDefaultValue( sal_uInt16 nPropId ) const SAL_OVERRIDE;
628 : ::cppu::IPropertyArrayHelper& SAL_CALL getInfoHelper() SAL_OVERRIDE;
629 :
630 : public:
631 : UnoControlFixedTextModel( const ::com::sun::star::uno::Reference< ::com::sun::star::uno::XComponentContext >& rxContext );
632 6 : UnoControlFixedTextModel( const UnoControlFixedTextModel& rModel ) : UnoControlModel( rModel ) {;}
633 :
634 6 : UnoControlModel* Clone() const SAL_OVERRIDE { return new UnoControlFixedTextModel( *this ); }
635 :
636 : // ::com::sun::star::io::XPersistObject
637 : OUString SAL_CALL getServiceName() throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
638 :
639 : // ::com::sun::star::beans::XMultiPropertySet
640 : ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertySetInfo > SAL_CALL getPropertySetInfo( ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
641 :
642 : // ::com::sun::star::lang::XServiceInfo
643 40 : DECLIMPL_SERVICEINFO_DERIVED( UnoControlFixedTextModel, UnoControlModel, szServiceName2_UnoControlFixedTextModel )
644 :
645 : };
646 :
647 :
648 : // class UnoFixedTextControl
649 :
650 36 : class UnoFixedTextControl : public UnoControlBase,
651 : public ::com::sun::star::awt::XFixedText,
652 : public ::com::sun::star::awt::XLayoutConstrains
653 : {
654 : public:
655 : UnoFixedTextControl();
656 : OUString GetComponentServiceName() SAL_OVERRIDE;
657 :
658 156 : ::com::sun::star::uno::Any SAL_CALL queryInterface( const ::com::sun::star::uno::Type & rType ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE { return UnoControlBase::queryInterface(rType); }
659 : ::com::sun::star::uno::Any SAL_CALL queryAggregation( const ::com::sun::star::uno::Type & rType ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
660 592 : void SAL_CALL acquire() throw() SAL_OVERRIDE { OWeakAggObject::acquire(); }
661 580 : void SAL_CALL release() throw() SAL_OVERRIDE { OWeakAggObject::release(); }
662 :
663 : // ::com::sun::star::lang::XTypeProvider
664 : ::com::sun::star::uno::Sequence< ::com::sun::star::uno::Type > SAL_CALL getTypes() throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
665 : ::com::sun::star::uno::Sequence< sal_Int8 > SAL_CALL getImplementationId() throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
666 :
667 : // ::com::sun::star::awt::XControl
668 : sal_Bool SAL_CALL isTransparent( ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
669 :
670 : // ::com::sun::star::awt::XFixedText
671 : void SAL_CALL setText( const OUString& Text ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
672 : OUString SAL_CALL getText( ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
673 : void SAL_CALL setAlignment( sal_Int16 nAlign ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
674 : sal_Int16 SAL_CALL getAlignment( ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
675 :
676 : // ::com::sun::star::awt::XLayoutConstrains
677 : ::com::sun::star::awt::Size SAL_CALL getMinimumSize( ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
678 : ::com::sun::star::awt::Size SAL_CALL getPreferredSize( ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
679 : ::com::sun::star::awt::Size SAL_CALL calcAdjustedSize( const ::com::sun::star::awt::Size& aNewSize ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
680 :
681 : // ::com::sun::star::lang::XServiceInfo
682 2 : DECLIMPL_SERVICEINFO_DERIVED( UnoFixedTextControl, UnoControlBase, szServiceName2_UnoControlFixedText )
683 :
684 : };
685 :
686 :
687 : // class UnoControlGroupBoxModel
688 :
689 84 : class UnoControlGroupBoxModel : public UnoControlModel
690 : {
691 : protected:
692 : ::com::sun::star::uno::Any ImplGetDefaultValue( sal_uInt16 nPropId ) const SAL_OVERRIDE;
693 : ::cppu::IPropertyArrayHelper& SAL_CALL getInfoHelper() SAL_OVERRIDE;
694 :
695 : public:
696 : UnoControlGroupBoxModel( const ::com::sun::star::uno::Reference< ::com::sun::star::uno::XComponentContext >& rxContext );
697 4 : UnoControlGroupBoxModel( const UnoControlGroupBoxModel& rModel ) : UnoControlModel( rModel ) {;}
698 :
699 4 : UnoControlModel* Clone() const SAL_OVERRIDE { return new UnoControlGroupBoxModel( *this ); }
700 :
701 : // ::com::sun::star::io::XPersistObject
702 : OUString SAL_CALL getServiceName() throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
703 :
704 : // ::com::sun::star::beans::XMultiPropertySet
705 : ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertySetInfo > SAL_CALL getPropertySetInfo( ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
706 :
707 : // ::com::sun::star::lang::XServiceInfo
708 24 : DECLIMPL_SERVICEINFO_DERIVED( UnoControlGroupBoxModel, UnoControlModel, szServiceName2_UnoControlGroupBoxModel )
709 :
710 : };
711 :
712 :
713 : // class UnoGroupBoxControl
714 :
715 52 : class UnoGroupBoxControl : public UnoControlBase
716 : {
717 : public:
718 : UnoGroupBoxControl();
719 : OUString GetComponentServiceName() SAL_OVERRIDE;
720 :
721 : sal_Bool SAL_CALL isTransparent( ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
722 :
723 : // ::com::sun::star::lang::XServiceInfo
724 2 : DECLIMPL_SERVICEINFO_DERIVED( UnoGroupBoxControl, UnoControlBase, szServiceName2_UnoControlGroupBox )
725 :
726 : };
727 :
728 :
729 : // class UnoControlListBoxModel
730 :
731 : struct UnoControlListBoxModel_Data;
732 : typedef ::cppu::AggImplInheritanceHelper1 < UnoControlModel
733 : , ::com::sun::star::awt::XItemList
734 : > UnoControlListBoxModel_Base;
735 : class TOOLKIT_DLLPUBLIC UnoControlListBoxModel : public UnoControlListBoxModel_Base
736 : {
737 : protected:
738 : enum ConstructorMode
739 : {
740 : ConstructDefault,
741 : ConstructWithoutProperties
742 : };
743 :
744 : public:
745 : UnoControlListBoxModel(
746 : const ::com::sun::star::uno::Reference< ::com::sun::star::uno::XComponentContext >& rxContext,
747 : ConstructorMode const i_mode = ConstructDefault
748 : );
749 : UnoControlListBoxModel( const UnoControlListBoxModel& i_rSource );
750 : virtual ~UnoControlListBoxModel();
751 :
752 4 : UnoControlModel* Clone() const SAL_OVERRIDE { return new UnoControlListBoxModel( *this ); }
753 :
754 : virtual void ImplNormalizePropertySequence(
755 : const sal_Int32 _nCount, /// the number of entries in the arrays
756 : sal_Int32* _pHandles, /// the handles of the properties to set
757 : ::com::sun::star::uno::Any* _pValues, /// the values of the properties to set
758 : sal_Int32* _pValidHandles /// pointer to the valid handles, allowed to be adjusted
759 : ) const SAL_OVERRIDE;
760 :
761 : // ::com::sun::star::beans::XMultiPropertySet
762 : ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertySetInfo > SAL_CALL getPropertySetInfo( ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
763 :
764 : // ::com::sun::star::io::XPersistObject
765 : OUString SAL_CALL getServiceName() throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
766 :
767 : // ::com::sun::star::lang::XServiceInfo
768 : OUString SAL_CALL getImplementationName( ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
769 : ::com::sun::star::uno::Sequence< OUString > SAL_CALL getSupportedServiceNames() throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
770 :
771 : // ::com::sun::star::awt::XItemList
772 : virtual ::sal_Int32 SAL_CALL getItemCount() throw (::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
773 : virtual void SAL_CALL insertItem( ::sal_Int32 Position, const OUString& ItemText, const OUString& ItemImageURL ) throw (::com::sun::star::lang::IndexOutOfBoundsException, ::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
774 : virtual void SAL_CALL insertItemText( ::sal_Int32 Position, const OUString& ItemText ) throw (::com::sun::star::lang::IndexOutOfBoundsException, ::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
775 : virtual void SAL_CALL insertItemImage( ::sal_Int32 Position, const OUString& ItemImageURL ) throw (::com::sun::star::lang::IndexOutOfBoundsException, ::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
776 : virtual void SAL_CALL removeItem( ::sal_Int32 Position ) throw (::com::sun::star::lang::IndexOutOfBoundsException, ::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
777 : virtual void SAL_CALL removeAllItems( ) throw (::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
778 : virtual void SAL_CALL setItemText( ::sal_Int32 Position, const OUString& ItemText ) throw (::com::sun::star::lang::IndexOutOfBoundsException, ::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
779 : virtual void SAL_CALL setItemImage( ::sal_Int32 Position, const OUString& ItemImageURL ) throw (::com::sun::star::lang::IndexOutOfBoundsException, ::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
780 : virtual void SAL_CALL setItemTextAndImage( ::sal_Int32 Position, const OUString& ItemText, const OUString& ItemImageURL ) throw (::com::sun::star::lang::IndexOutOfBoundsException, ::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
781 : virtual void SAL_CALL setItemData( ::sal_Int32 Position, const ::com::sun::star::uno::Any& DataValue ) throw (::com::sun::star::lang::IndexOutOfBoundsException, ::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
782 : virtual OUString SAL_CALL getItemText( ::sal_Int32 Position ) throw (::com::sun::star::lang::IndexOutOfBoundsException, ::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
783 : virtual OUString SAL_CALL getItemImage( ::sal_Int32 Position ) throw (::com::sun::star::lang::IndexOutOfBoundsException, ::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
784 : virtual ::com::sun::star::beans::Pair< OUString, OUString > SAL_CALL getItemTextAndImage( ::sal_Int32 Position ) throw (::com::sun::star::lang::IndexOutOfBoundsException, ::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
785 : virtual ::com::sun::star::uno::Any SAL_CALL getItemData( ::sal_Int32 Position ) throw (::com::sun::star::lang::IndexOutOfBoundsException, ::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
786 : virtual ::com::sun::star::uno::Sequence< ::com::sun::star::beans::Pair< OUString, OUString > > SAL_CALL getAllItems( ) throw (::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
787 : virtual void SAL_CALL addItemListListener( const ::com::sun::star::uno::Reference< ::com::sun::star::awt::XItemListListener >& Listener ) throw (::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
788 : virtual void SAL_CALL removeItemListListener( const ::com::sun::star::uno::Reference< ::com::sun::star::awt::XItemListListener >& Listener ) throw (::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
789 :
790 : // OPropertySetHelper
791 : void SAL_CALL setFastPropertyValue_NoBroadcast( sal_Int32 nHandle, const ::com::sun::star::uno::Any& rValue ) throw (::com::sun::star::uno::Exception, std::exception) SAL_OVERRIDE;
792 :
793 : protected:
794 : ::com::sun::star::uno::Any ImplGetDefaultValue( sal_uInt16 nPropId ) const SAL_OVERRIDE;
795 : ::cppu::IPropertyArrayHelper& SAL_CALL getInfoHelper() SAL_OVERRIDE;
796 :
797 : private:
798 : void impl_notifyItemListEvent_nolck(
799 : const sal_Int32 i_nItemPosition,
800 : const ::boost::optional< OUString >& i_rItemText,
801 : const ::boost::optional< OUString >& i_rItemImageURL,
802 : void ( SAL_CALL ::com::sun::star::awt::XItemListListener::*NotificationMethod )( const ::com::sun::star::awt::ItemListEvent& )
803 : );
804 :
805 : void impl_handleInsert(
806 : const sal_Int32 i_nItemPosition,
807 : const ::boost::optional< OUString >& i_rItemText,
808 : const ::boost::optional< OUString >& i_rItemImageURL,
809 : ::osl::ClearableMutexGuard& i_rClearBeforeNotify
810 : );
811 :
812 : void impl_handleRemove(
813 : const sal_Int32 i_nItemPosition,
814 : ::osl::ClearableMutexGuard& i_rClearBeforeNotify
815 : );
816 :
817 : void impl_handleModify(
818 : const sal_Int32 i_nItemPosition,
819 : const ::boost::optional< OUString >& i_rItemText,
820 : const ::boost::optional< OUString >& i_rItemImageURL,
821 : ::osl::ClearableMutexGuard& i_rClearBeforeNotify
822 : );
823 :
824 : void impl_getStringItemList( ::std::vector< OUString >& o_rStringItems ) const;
825 : void impl_setStringItemList_nolck( const ::std::vector< OUString >& i_rStringItems );
826 :
827 : protected:
828 : ::boost::scoped_ptr< UnoControlListBoxModel_Data > m_pData;
829 : ::cppu::OInterfaceContainerHelper m_aItemListListeners;
830 : };
831 :
832 :
833 : // class UnoListBoxControl
834 :
835 : typedef ::cppu::AggImplInheritanceHelper5 < UnoControlBase
836 : , ::com::sun::star::awt::XListBox
837 : , ::com::sun::star::awt::XItemListener
838 : , ::com::sun::star::awt::XLayoutConstrains
839 : , ::com::sun::star::awt::XTextLayoutConstrains
840 : , ::com::sun::star::awt::XItemListListener
841 : > UnoListBoxControl_Base;
842 24 : class TOOLKIT_DLLPUBLIC UnoListBoxControl : public UnoListBoxControl_Base
843 : {
844 : public:
845 : UnoListBoxControl();
846 : OUString GetComponentServiceName() SAL_OVERRIDE;
847 :
848 : void SAL_CALL createPeer( const ::com::sun::star::uno::Reference< ::com::sun::star::awt::XToolkit >& Toolkit, const ::com::sun::star::uno::Reference< ::com::sun::star::awt::XWindowPeer >& Parent ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
849 : void SAL_CALL dispose( ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
850 42 : void SAL_CALL disposing( const ::com::sun::star::lang::EventObject& Source ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE { UnoControlBase::disposing( Source ); }
851 :
852 : // ::com::sun::star::awt::XListBox
853 : void SAL_CALL addItemListener( const ::com::sun::star::uno::Reference< ::com::sun::star::awt::XItemListener >& l ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
854 : void SAL_CALL removeItemListener( const ::com::sun::star::uno::Reference< ::com::sun::star::awt::XItemListener >& l ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
855 : void SAL_CALL addActionListener( const ::com::sun::star::uno::Reference< ::com::sun::star::awt::XActionListener >& l ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
856 : void SAL_CALL removeActionListener( const ::com::sun::star::uno::Reference< ::com::sun::star::awt::XActionListener >& l ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
857 : void SAL_CALL addItem( const OUString& aItem, sal_Int16 nPos ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
858 : void SAL_CALL addItems( const ::com::sun::star::uno::Sequence< OUString >& aItems, sal_Int16 nPos ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
859 : void SAL_CALL removeItems( sal_Int16 nPos, sal_Int16 nCount ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
860 : sal_Int16 SAL_CALL getItemCount( ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
861 : OUString SAL_CALL getItem( sal_Int16 nPos ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
862 : ::com::sun::star::uno::Sequence< OUString > SAL_CALL getItems( ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
863 : sal_Int16 SAL_CALL getSelectedItemPos( ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
864 : ::com::sun::star::uno::Sequence< sal_Int16 > SAL_CALL getSelectedItemsPos( ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
865 : OUString SAL_CALL getSelectedItem( ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
866 : ::com::sun::star::uno::Sequence< OUString > SAL_CALL getSelectedItems( ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
867 : void SAL_CALL selectItemPos( sal_Int16 nPos, sal_Bool bSelect ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
868 : void SAL_CALL selectItemsPos( const ::com::sun::star::uno::Sequence< sal_Int16 >& aPositions, sal_Bool bSelect ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
869 : void SAL_CALL selectItem( const OUString& aItem, sal_Bool bSelect ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
870 : sal_Bool SAL_CALL isMutipleMode( ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
871 : void SAL_CALL setMultipleMode( sal_Bool bMulti ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
872 : sal_Int16 SAL_CALL getDropDownLineCount( ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
873 : void SAL_CALL setDropDownLineCount( sal_Int16 nLines ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
874 : void SAL_CALL makeVisible( sal_Int16 nEntry ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
875 :
876 : // ::com::sun::star::awt::XItemListener
877 : void SAL_CALL itemStateChanged( const ::com::sun::star::awt::ItemEvent& rEvent ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
878 :
879 : // ::com::sun::star::awt::XLayoutConstrains
880 : ::com::sun::star::awt::Size SAL_CALL getMinimumSize( ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
881 : ::com::sun::star::awt::Size SAL_CALL getPreferredSize( ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
882 : ::com::sun::star::awt::Size SAL_CALL calcAdjustedSize( const ::com::sun::star::awt::Size& aNewSize ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
883 :
884 : // ::com::sun::star::awt::XTextLayoutConstrains
885 : ::com::sun::star::awt::Size SAL_CALL getMinimumSize( sal_Int16 nCols, sal_Int16 nLines ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
886 : void SAL_CALL getColumnsAndLines( sal_Int16& nCols, sal_Int16& nLines ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
887 :
888 : // XUnoControl
889 : sal_Bool SAL_CALL setModel(const ::com::sun::star::uno::Reference< ::com::sun::star::awt::XControlModel >& Model) throw ( ::com::sun::star::uno::RuntimeException, std::exception ) SAL_OVERRIDE;
890 :
891 : // XItemListListener
892 : virtual void SAL_CALL listItemInserted( const ::com::sun::star::awt::ItemListEvent& Event ) throw (::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
893 : virtual void SAL_CALL listItemRemoved( const ::com::sun::star::awt::ItemListEvent& Event ) throw (::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
894 : virtual void SAL_CALL listItemModified( const ::com::sun::star::awt::ItemListEvent& Event ) throw (::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
895 : virtual void SAL_CALL allItemsRemoved( const ::com::sun::star::lang::EventObject& Event ) throw (::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
896 : virtual void SAL_CALL itemListChanged( const ::com::sun::star::lang::EventObject& Event ) throw (::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
897 :
898 : // ::com::sun::star::lang::XServiceInfo
899 : OUString SAL_CALL getImplementationName( ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
900 : ::com::sun::star::uno::Sequence< OUString > SAL_CALL getSupportedServiceNames() throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
901 :
902 : protected:
903 : void ImplUpdateSelectedItemsProperty();
904 : virtual void ImplSetPeerProperty( const OUString& rPropName, const ::com::sun::star::uno::Any& rVal ) SAL_OVERRIDE;
905 : virtual void updateFromModel() SAL_OVERRIDE;
906 :
907 : private:
908 : ActionListenerMultiplexer maActionListeners;
909 : ItemListenerMultiplexer maItemListeners;
910 : };
911 :
912 :
913 : // class UnoControlComboBoxModel
914 :
915 132 : class UnoControlComboBoxModel : public UnoControlListBoxModel
916 : {
917 : protected:
918 : ::com::sun::star::uno::Any ImplGetDefaultValue( sal_uInt16 nPropId ) const SAL_OVERRIDE;
919 : ::cppu::IPropertyArrayHelper& SAL_CALL getInfoHelper() SAL_OVERRIDE;
920 :
921 : public:
922 : UnoControlComboBoxModel( const ::com::sun::star::uno::Reference< ::com::sun::star::uno::XComponentContext >& rxContext );
923 4 : UnoControlComboBoxModel( const UnoControlComboBoxModel& rModel ) : UnoControlListBoxModel( rModel ) {;}
924 :
925 4 : UnoControlModel* Clone() const SAL_OVERRIDE { return new UnoControlComboBoxModel( *this ); }
926 :
927 : // ::com::sun::star::io::XPersistObject
928 : OUString SAL_CALL getServiceName() throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
929 :
930 : // ::com::sun::star::beans::XMultiPropertySet
931 : ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertySetInfo > SAL_CALL getPropertySetInfo( ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
932 : // OPropertySetHelper
933 : void SAL_CALL setFastPropertyValue_NoBroadcast( sal_Int32 nHandle, const ::com::sun::star::uno::Any& rValue ) throw (::com::sun::star::uno::Exception, std::exception) SAL_OVERRIDE;
934 :
935 : // ::com::sun::star::lang::XServiceInfo
936 : OUString SAL_CALL getImplementationName( ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
937 : ::com::sun::star::uno::Sequence< OUString > SAL_CALL getSupportedServiceNames() throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
938 :
939 : };
940 :
941 :
942 : // class UnoComboBoxControl
943 :
944 64 : class UnoComboBoxControl : public UnoEditControl
945 : , public ::com::sun::star::awt::XComboBox
946 : , public ::com::sun::star::awt::XItemListener
947 : , public ::com::sun::star::awt::XItemListListener
948 : {
949 : private:
950 : ActionListenerMultiplexer maActionListeners;
951 : ItemListenerMultiplexer maItemListeners;
952 :
953 : public:
954 :
955 : UnoComboBoxControl();
956 : OUString GetComponentServiceName() SAL_OVERRIDE;
957 :
958 : void SAL_CALL createPeer( const ::com::sun::star::uno::Reference< ::com::sun::star::awt::XToolkit >& Toolkit, const ::com::sun::star::uno::Reference< ::com::sun::star::awt::XWindowPeer >& Parent ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
959 52 : void SAL_CALL disposing( const ::com::sun::star::lang::EventObject& Source ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE { UnoEditControl::disposing( Source ); }
960 : void SAL_CALL dispose( ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
961 :
962 1379 : ::com::sun::star::uno::Any SAL_CALL queryInterface( const ::com::sun::star::uno::Type & rType ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE { return UnoEditControl::queryInterface(rType); }
963 : ::com::sun::star::uno::Any SAL_CALL queryAggregation( const ::com::sun::star::uno::Type & rType ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
964 5259 : void SAL_CALL acquire() throw() SAL_OVERRIDE { OWeakAggObject::acquire(); }
965 5253 : void SAL_CALL release() throw() SAL_OVERRIDE { OWeakAggObject::release(); }
966 :
967 :
968 : // ::com::sun::star::lang::XTypeProvider
969 : ::com::sun::star::uno::Sequence< ::com::sun::star::uno::Type > SAL_CALL getTypes() throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
970 : ::com::sun::star::uno::Sequence< sal_Int8 > SAL_CALL getImplementationId() throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
971 :
972 : // ::com::sun::star::awt::XComboBox
973 : void SAL_CALL addItemListener( const ::com::sun::star::uno::Reference< ::com::sun::star::awt::XItemListener >& l ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
974 : void SAL_CALL removeItemListener( const ::com::sun::star::uno::Reference< ::com::sun::star::awt::XItemListener >& l ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
975 : void SAL_CALL addActionListener( const ::com::sun::star::uno::Reference< ::com::sun::star::awt::XActionListener >& l ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
976 : void SAL_CALL removeActionListener( const ::com::sun::star::uno::Reference< ::com::sun::star::awt::XActionListener >& l ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
977 : void SAL_CALL addItem( const OUString& aItem, sal_Int16 nPos ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
978 : void SAL_CALL addItems( const ::com::sun::star::uno::Sequence< OUString >& aItems, sal_Int16 nPos ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
979 : void SAL_CALL removeItems( sal_Int16 nPos, sal_Int16 nCount ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
980 : sal_Int16 SAL_CALL getItemCount( ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
981 : OUString SAL_CALL getItem( sal_Int16 nPos ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
982 : ::com::sun::star::uno::Sequence< OUString > SAL_CALL getItems( ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
983 : sal_Int16 SAL_CALL getDropDownLineCount( ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
984 : void SAL_CALL setDropDownLineCount( sal_Int16 nLines ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
985 :
986 : // XUnoControl
987 : virtual sal_Bool SAL_CALL setModel(const ::com::sun::star::uno::Reference< ::com::sun::star::awt::XControlModel >& Model) throw ( ::com::sun::star::uno::RuntimeException, std::exception ) SAL_OVERRIDE;
988 :
989 : // XItemListListener
990 : virtual void SAL_CALL listItemInserted( const ::com::sun::star::awt::ItemListEvent& Event ) throw (::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
991 : virtual void SAL_CALL listItemRemoved( const ::com::sun::star::awt::ItemListEvent& Event ) throw (::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
992 : virtual void SAL_CALL listItemModified( const ::com::sun::star::awt::ItemListEvent& Event ) throw (::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
993 : virtual void SAL_CALL allItemsRemoved( const ::com::sun::star::lang::EventObject& Event ) throw (::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
994 : virtual void SAL_CALL itemListChanged( const ::com::sun::star::lang::EventObject& Event ) throw (::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
995 :
996 : // XItemListener
997 : virtual void SAL_CALL itemStateChanged( const ::com::sun::star::awt::ItemEvent& rEvent ) throw (::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
998 :
999 : // ::com::sun::star::lang::XServiceInfo
1000 : OUString SAL_CALL getImplementationName( ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
1001 : ::com::sun::star::uno::Sequence< OUString > SAL_CALL getSupportedServiceNames() throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
1002 : protected:
1003 : virtual void ImplSetPeerProperty( const OUString& rPropName, const ::com::sun::star::uno::Any& rVal ) SAL_OVERRIDE;
1004 : virtual void updateFromModel() SAL_OVERRIDE;
1005 : ActionListenerMultiplexer& getActionListeners();
1006 : ItemListenerMultiplexer& getItemListeners();
1007 :
1008 : };
1009 :
1010 :
1011 : // class UnoSpinFieldControl
1012 :
1013 78 : class UnoSpinFieldControl : public UnoEditControl,
1014 : public ::com::sun::star::awt::XSpinField
1015 : {
1016 : private:
1017 : SpinListenerMultiplexer maSpinListeners;
1018 : bool mbRepeat;
1019 :
1020 : public:
1021 : UnoSpinFieldControl();
1022 :
1023 6182 : ::com::sun::star::uno::Any SAL_CALL queryInterface( const ::com::sun::star::uno::Type & rType ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE { return UnoEditControl::queryInterface(rType); }
1024 : ::com::sun::star::uno::Any SAL_CALL queryAggregation( const ::com::sun::star::uno::Type & rType ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
1025 544 : void SAL_CALL acquire() throw() SAL_OVERRIDE { OWeakAggObject::acquire(); }
1026 544 : void SAL_CALL release() throw() SAL_OVERRIDE { OWeakAggObject::release(); }
1027 :
1028 : // ::com::sun::star::lang::XTypeProvider
1029 : ::com::sun::star::uno::Sequence< ::com::sun::star::uno::Type > SAL_CALL getTypes() throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
1030 : ::com::sun::star::uno::Sequence< sal_Int8 > SAL_CALL getImplementationId() throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
1031 :
1032 : void SAL_CALL createPeer( const ::com::sun::star::uno::Reference< ::com::sun::star::awt::XToolkit >& Toolkit, const ::com::sun::star::uno::Reference< ::com::sun::star::awt::XWindowPeer >& Parent ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
1033 :
1034 : // ::com::sun::star::awt::XSpinField
1035 : void SAL_CALL addSpinListener( const ::com::sun::star::uno::Reference< ::com::sun::star::awt::XSpinListener >& l ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
1036 : void SAL_CALL removeSpinListener( const ::com::sun::star::uno::Reference< ::com::sun::star::awt::XSpinListener >& l ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
1037 : void SAL_CALL up() throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
1038 : void SAL_CALL down() throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
1039 : void SAL_CALL first() throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
1040 : void SAL_CALL last() throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
1041 : void SAL_CALL enableRepeat( sal_Bool bRepeat ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
1042 :
1043 :
1044 : // ::com::sun::star::lang::XServiceInfo
1045 : // No service info, only base class for other fields.
1046 : };
1047 :
1048 :
1049 :
1050 : // class UnoControlDateFieldModel
1051 :
1052 156 : class UnoControlDateFieldModel : public UnoControlModel
1053 : {
1054 : protected:
1055 : ::com::sun::star::uno::Any ImplGetDefaultValue( sal_uInt16 nPropId ) const SAL_OVERRIDE;
1056 : ::cppu::IPropertyArrayHelper& SAL_CALL getInfoHelper() SAL_OVERRIDE;
1057 :
1058 : public:
1059 : UnoControlDateFieldModel( const ::com::sun::star::uno::Reference< ::com::sun::star::uno::XComponentContext >& rxContext );
1060 6 : UnoControlDateFieldModel( const UnoControlDateFieldModel& rModel ) : UnoControlModel( rModel ) {;}
1061 :
1062 6 : UnoControlModel* Clone() const SAL_OVERRIDE { return new UnoControlDateFieldModel( *this ); }
1063 :
1064 : // ::com::sun::star::io::XPersistObject
1065 : OUString SAL_CALL getServiceName() throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
1066 :
1067 : // ::com::sun::star::beans::XMultiPropertySet
1068 : ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertySetInfo > SAL_CALL getPropertySetInfo( ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
1069 :
1070 : // ::com::sun::star::lang::XServiceInfo
1071 40 : DECLIMPL_SERVICEINFO_DERIVED( UnoControlDateFieldModel, UnoControlModel, szServiceName2_UnoControlDateFieldModel )
1072 :
1073 : };
1074 :
1075 :
1076 : // class UnoDateFieldControl
1077 :
1078 40 : class UnoDateFieldControl : public UnoSpinFieldControl,
1079 : public ::com::sun::star::awt::XDateField
1080 : {
1081 : private:
1082 : ::com::sun::star::util::Date mnFirst;
1083 : ::com::sun::star::util::Date mnLast;
1084 : TriState mbLongFormat;
1085 : public:
1086 : UnoDateFieldControl();
1087 : OUString GetComponentServiceName() SAL_OVERRIDE;
1088 :
1089 1317 : ::com::sun::star::uno::Any SAL_CALL queryInterface( const ::com::sun::star::uno::Type & rType ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE { return UnoSpinFieldControl::queryInterface(rType); }
1090 : ::com::sun::star::uno::Any SAL_CALL queryAggregation( const ::com::sun::star::uno::Type & rType ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
1091 5075 : void SAL_CALL acquire() throw() SAL_OVERRIDE { OWeakAggObject::acquire(); }
1092 5075 : void SAL_CALL release() throw() SAL_OVERRIDE { OWeakAggObject::release(); }
1093 :
1094 : // ::com::sun::star::lang::XTypeProvider
1095 : ::com::sun::star::uno::Sequence< ::com::sun::star::uno::Type > SAL_CALL getTypes() throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
1096 : ::com::sun::star::uno::Sequence< sal_Int8 > SAL_CALL getImplementationId() throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
1097 :
1098 : void SAL_CALL createPeer( const ::com::sun::star::uno::Reference< ::com::sun::star::awt::XToolkit >& Toolkit, const ::com::sun::star::uno::Reference< ::com::sun::star::awt::XWindowPeer >& Parent ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
1099 :
1100 : // ::com::sun::star::awt::XTextListener
1101 : void SAL_CALL textChanged( const ::com::sun::star::awt::TextEvent& rEvent ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
1102 :
1103 : //XDateField
1104 : void SAL_CALL setDate( const ::com::sun::star::util::Date& Date ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
1105 : ::com::sun::star::util::Date SAL_CALL getDate( ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
1106 : void SAL_CALL setMin( const ::com::sun::star::util::Date& Date ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
1107 : ::com::sun::star::util::Date SAL_CALL getMin( ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
1108 : void SAL_CALL setMax( const ::com::sun::star::util::Date& Date ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
1109 : ::com::sun::star::util::Date SAL_CALL getMax( ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
1110 : void SAL_CALL setFirst( const ::com::sun::star::util::Date& Date ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
1111 : ::com::sun::star::util::Date SAL_CALL getFirst( ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
1112 : void SAL_CALL setLast( const ::com::sun::star::util::Date& Date ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
1113 : ::com::sun::star::util::Date SAL_CALL getLast( ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
1114 : void SAL_CALL setLongFormat( sal_Bool bLong ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
1115 : sal_Bool SAL_CALL isLongFormat( ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
1116 : void SAL_CALL setEmpty( ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
1117 : sal_Bool SAL_CALL isEmpty( ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
1118 : void SAL_CALL setStrictFormat( sal_Bool bStrict ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
1119 : sal_Bool SAL_CALL isStrictFormat( ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
1120 :
1121 : // ::com::sun::star::lang::XServiceInfo
1122 2 : DECLIMPL_SERVICEINFO_DERIVED( UnoDateFieldControl, UnoSpinFieldControl, szServiceName2_UnoControlDateField )
1123 : };
1124 :
1125 :
1126 : // class UnoControlTimeFieldModel
1127 :
1128 64 : class UnoControlTimeFieldModel : public UnoControlModel
1129 : {
1130 : protected:
1131 : ::com::sun::star::uno::Any ImplGetDefaultValue( sal_uInt16 nPropId ) const SAL_OVERRIDE;
1132 : ::cppu::IPropertyArrayHelper& SAL_CALL getInfoHelper() SAL_OVERRIDE;
1133 :
1134 : public:
1135 : UnoControlTimeFieldModel( const ::com::sun::star::uno::Reference< ::com::sun::star::uno::XComponentContext >& rxContext );
1136 4 : UnoControlTimeFieldModel( const UnoControlTimeFieldModel& rModel ) : UnoControlModel( rModel ) {;}
1137 :
1138 4 : UnoControlModel* Clone() const SAL_OVERRIDE { return new UnoControlTimeFieldModel( *this ); }
1139 :
1140 : // ::com::sun::star::io::XPersistObject
1141 : OUString SAL_CALL getServiceName() throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
1142 :
1143 : // ::com::sun::star::beans::XMultiPropertySet
1144 : ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertySetInfo > SAL_CALL getPropertySetInfo( ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
1145 :
1146 : // ::com::sun::star::lang::XServiceInfo
1147 30 : DECLIMPL_SERVICEINFO_DERIVED( UnoControlTimeFieldModel, UnoControlModel, szServiceName2_UnoControlTimeFieldModel )
1148 :
1149 : };
1150 :
1151 :
1152 : // class UnoTimeFieldControl
1153 :
1154 28 : class UnoTimeFieldControl : public UnoSpinFieldControl,
1155 : public ::com::sun::star::awt::XTimeField
1156 : {
1157 : private:
1158 : ::com::sun::star::util::Time mnFirst;
1159 : ::com::sun::star::util::Time mnLast;
1160 :
1161 : public:
1162 : UnoTimeFieldControl();
1163 : OUString GetComponentServiceName() SAL_OVERRIDE;
1164 :
1165 1067 : ::com::sun::star::uno::Any SAL_CALL queryInterface( const ::com::sun::star::uno::Type & rType ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE { return UnoSpinFieldControl::queryInterface(rType); }
1166 : ::com::sun::star::uno::Any SAL_CALL queryAggregation( const ::com::sun::star::uno::Type & rType ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
1167 4259 : void SAL_CALL acquire() throw() SAL_OVERRIDE { OWeakAggObject::acquire(); }
1168 4259 : void SAL_CALL release() throw() SAL_OVERRIDE { OWeakAggObject::release(); }
1169 :
1170 : // ::com::sun::star::lang::XTypeProvider
1171 : ::com::sun::star::uno::Sequence< ::com::sun::star::uno::Type > SAL_CALL getTypes() throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
1172 : ::com::sun::star::uno::Sequence< sal_Int8 > SAL_CALL getImplementationId() throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
1173 :
1174 : void SAL_CALL createPeer( const ::com::sun::star::uno::Reference< ::com::sun::star::awt::XToolkit >& Toolkit, const ::com::sun::star::uno::Reference< ::com::sun::star::awt::XWindowPeer >& Parent ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
1175 :
1176 : // ::com::sun::star::awt::XTextListener
1177 : void SAL_CALL textChanged( const ::com::sun::star::awt::TextEvent& rEvent ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
1178 :
1179 : //XTimeField
1180 : void SAL_CALL setTime( const ::com::sun::star::util::Time& Time ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
1181 : ::com::sun::star::util::Time SAL_CALL getTime( ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
1182 : void SAL_CALL setMin( const ::com::sun::star::util::Time& Time ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
1183 : ::com::sun::star::util::Time SAL_CALL getMin( ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
1184 : void SAL_CALL setMax( const ::com::sun::star::util::Time& Time ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
1185 : ::com::sun::star::util::Time SAL_CALL getMax( ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
1186 : void SAL_CALL setFirst( const ::com::sun::star::util::Time& Time ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
1187 : ::com::sun::star::util::Time SAL_CALL getFirst( ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
1188 : void SAL_CALL setLast( const ::com::sun::star::util::Time& Time ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
1189 : ::com::sun::star::util::Time SAL_CALL getLast( ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
1190 : void SAL_CALL setEmpty( ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
1191 : sal_Bool SAL_CALL isEmpty( ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
1192 : void SAL_CALL setStrictFormat( sal_Bool bStrict ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
1193 : sal_Bool SAL_CALL isStrictFormat( ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
1194 :
1195 : // ::com::sun::star::lang::XServiceInfo
1196 2 : DECLIMPL_SERVICEINFO_DERIVED( UnoTimeFieldControl, UnoSpinFieldControl, szServiceName2_UnoControlTimeField )
1197 :
1198 : };
1199 :
1200 :
1201 : // class UnoControlNumericFieldModel
1202 :
1203 64 : class UnoControlNumericFieldModel : public UnoControlModel
1204 : {
1205 : protected:
1206 : ::com::sun::star::uno::Any ImplGetDefaultValue( sal_uInt16 nPropId ) const SAL_OVERRIDE;
1207 : ::cppu::IPropertyArrayHelper& SAL_CALL getInfoHelper() SAL_OVERRIDE;
1208 :
1209 : public:
1210 : UnoControlNumericFieldModel( const ::com::sun::star::uno::Reference< ::com::sun::star::uno::XComponentContext >& rxContext );
1211 4 : UnoControlNumericFieldModel( const UnoControlNumericFieldModel& rModel ) : UnoControlModel( rModel ) {;}
1212 :
1213 4 : UnoControlModel* Clone() const SAL_OVERRIDE { return new UnoControlNumericFieldModel( *this ); }
1214 :
1215 : // ::com::sun::star::io::XPersistObject
1216 : OUString SAL_CALL getServiceName() throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
1217 :
1218 : // ::com::sun::star::beans::XMultiPropertySet
1219 : ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertySetInfo > SAL_CALL getPropertySetInfo( ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
1220 :
1221 : // ::com::sun::star::lang::XServiceInfo
1222 30 : DECLIMPL_SERVICEINFO_DERIVED( UnoControlNumericFieldModel, UnoControlModel, szServiceName2_UnoControlNumericFieldModel )
1223 :
1224 : };
1225 :
1226 :
1227 : // class UnoNumericFieldControl
1228 :
1229 28 : class UnoNumericFieldControl : public UnoSpinFieldControl,
1230 : public ::com::sun::star::awt::XNumericField
1231 : {
1232 : private:
1233 : double mnFirst;
1234 : double mnLast;
1235 :
1236 : public:
1237 : UnoNumericFieldControl();
1238 : OUString GetComponentServiceName() SAL_OVERRIDE;
1239 :
1240 1250 : ::com::sun::star::uno::Any SAL_CALL queryInterface( const ::com::sun::star::uno::Type & rType ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE { return UnoSpinFieldControl::queryInterface(rType); }
1241 : ::com::sun::star::uno::Any SAL_CALL queryAggregation( const ::com::sun::star::uno::Type & rType ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
1242 4772 : void SAL_CALL acquire() throw() SAL_OVERRIDE { OWeakAggObject::acquire(); }
1243 4772 : void SAL_CALL release() throw() SAL_OVERRIDE { OWeakAggObject::release(); }
1244 :
1245 : void SAL_CALL createPeer( const ::com::sun::star::uno::Reference< ::com::sun::star::awt::XToolkit >& Toolkit, const ::com::sun::star::uno::Reference< ::com::sun::star::awt::XWindowPeer >& Parent ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
1246 :
1247 : // ::com::sun::star::lang::XTypeProvider
1248 : ::com::sun::star::uno::Sequence< ::com::sun::star::uno::Type > SAL_CALL getTypes() throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
1249 : ::com::sun::star::uno::Sequence< sal_Int8 > SAL_CALL getImplementationId() throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
1250 :
1251 : // ::com::sun::star::awt::XTextListener
1252 : void SAL_CALL textChanged( const ::com::sun::star::awt::TextEvent& rEvent ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
1253 :
1254 : // ::com::sun::star::awt::XNumericField
1255 : void SAL_CALL setValue( double Value ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
1256 : double SAL_CALL getValue( ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
1257 : void SAL_CALL setMin( double Value ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
1258 : double SAL_CALL getMin( ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
1259 : void SAL_CALL setMax( double Value ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
1260 : double SAL_CALL getMax( ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
1261 : void SAL_CALL setFirst( double Value ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
1262 : double SAL_CALL getFirst( ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
1263 : void SAL_CALL setLast( double Value ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
1264 : double SAL_CALL getLast( ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
1265 : void SAL_CALL setSpinSize( double Value ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
1266 : double SAL_CALL getSpinSize( ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
1267 : void SAL_CALL setDecimalDigits( sal_Int16 nDigits ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
1268 : sal_Int16 SAL_CALL getDecimalDigits( ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
1269 : void SAL_CALL setStrictFormat( sal_Bool bStrict ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
1270 : sal_Bool SAL_CALL isStrictFormat( ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
1271 :
1272 : // ::com::sun::star::lang::XServiceInfo
1273 2 : DECLIMPL_SERVICEINFO_DERIVED( UnoNumericFieldControl, UnoSpinFieldControl, szServiceName2_UnoControlNumericField )
1274 :
1275 : };
1276 :
1277 :
1278 : // class UnoControlCurrencyFieldModel
1279 :
1280 60 : class UnoControlCurrencyFieldModel : public UnoControlModel
1281 : {
1282 : protected:
1283 : ::com::sun::star::uno::Any ImplGetDefaultValue( sal_uInt16 nPropId ) const SAL_OVERRIDE;
1284 : ::cppu::IPropertyArrayHelper& SAL_CALL getInfoHelper() SAL_OVERRIDE;
1285 :
1286 : public:
1287 : UnoControlCurrencyFieldModel( const ::com::sun::star::uno::Reference< ::com::sun::star::uno::XComponentContext >& rxContext );
1288 4 : UnoControlCurrencyFieldModel( const UnoControlCurrencyFieldModel& rModel ) : UnoControlModel( rModel ) {;}
1289 :
1290 4 : UnoControlModel* Clone() const SAL_OVERRIDE { return new UnoControlCurrencyFieldModel( *this ); }
1291 :
1292 : // ::com::sun::star::io::XPersistObject
1293 : OUString SAL_CALL getServiceName() throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
1294 :
1295 : // ::com::sun::star::beans::XMultiPropertySet
1296 : ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertySetInfo > SAL_CALL getPropertySetInfo( ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
1297 :
1298 : // ::com::sun::star::lang::XServiceInfo
1299 28 : DECLIMPL_SERVICEINFO_DERIVED( UnoControlCurrencyFieldModel, UnoControlModel, szServiceName2_UnoControlCurrencyFieldModel )
1300 :
1301 : };
1302 :
1303 :
1304 : // class UnoCurrencyFieldControl
1305 :
1306 28 : class UnoCurrencyFieldControl : public UnoSpinFieldControl,
1307 : public ::com::sun::star::awt::XCurrencyField
1308 : {
1309 : private:
1310 : double mnFirst;
1311 : double mnLast;
1312 :
1313 : public:
1314 : UnoCurrencyFieldControl();
1315 : OUString GetComponentServiceName() SAL_OVERRIDE;
1316 :
1317 1356 : ::com::sun::star::uno::Any SAL_CALL queryInterface( const ::com::sun::star::uno::Type & rType ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE { return UnoSpinFieldControl::queryInterface(rType); }
1318 : ::com::sun::star::uno::Any SAL_CALL queryAggregation( const ::com::sun::star::uno::Type & rType ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
1319 4822 : void SAL_CALL acquire() throw() SAL_OVERRIDE { OWeakAggObject::acquire(); }
1320 4822 : void SAL_CALL release() throw() SAL_OVERRIDE { OWeakAggObject::release(); }
1321 :
1322 : void SAL_CALL createPeer( const ::com::sun::star::uno::Reference< ::com::sun::star::awt::XToolkit >& Toolkit, const ::com::sun::star::uno::Reference< ::com::sun::star::awt::XWindowPeer >& Parent ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
1323 :
1324 : // ::com::sun::star::lang::XTypeProvider
1325 : ::com::sun::star::uno::Sequence< ::com::sun::star::uno::Type > SAL_CALL getTypes() throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
1326 : ::com::sun::star::uno::Sequence< sal_Int8 > SAL_CALL getImplementationId() throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
1327 :
1328 : // ::com::sun::star::awt::XTextListener
1329 : void SAL_CALL textChanged( const ::com::sun::star::awt::TextEvent& rEvent ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
1330 :
1331 : // ::com::sun::star::awt::XCurrencyField
1332 : void SAL_CALL setValue( double Value ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
1333 : double SAL_CALL getValue( ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
1334 : void SAL_CALL setMin( double Value ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
1335 : double SAL_CALL getMin( ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
1336 : void SAL_CALL setMax( double Value ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
1337 : double SAL_CALL getMax( ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
1338 : void SAL_CALL setFirst( double Value ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
1339 : double SAL_CALL getFirst( ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
1340 : void SAL_CALL setLast( double Value ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
1341 : double SAL_CALL getLast( ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
1342 : void SAL_CALL setSpinSize( double Value ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
1343 : double SAL_CALL getSpinSize( ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
1344 : void SAL_CALL setDecimalDigits( sal_Int16 nDigits ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
1345 : sal_Int16 SAL_CALL getDecimalDigits( ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
1346 : void SAL_CALL setStrictFormat( sal_Bool bStrict ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
1347 : sal_Bool SAL_CALL isStrictFormat( ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
1348 :
1349 : // ::com::sun::star::lang::XServiceInfo
1350 2 : DECLIMPL_SERVICEINFO_DERIVED( UnoCurrencyFieldControl, UnoSpinFieldControl, szServiceName2_UnoControlCurrencyField )
1351 : };
1352 :
1353 :
1354 : // class UnoControlPatternFieldModel
1355 :
1356 20 : class UnoControlPatternFieldModel : public UnoControlModel
1357 : {
1358 : protected:
1359 : ::com::sun::star::uno::Any ImplGetDefaultValue( sal_uInt16 nPropId ) const SAL_OVERRIDE;
1360 : ::cppu::IPropertyArrayHelper& SAL_CALL getInfoHelper() SAL_OVERRIDE;
1361 :
1362 : public:
1363 : UnoControlPatternFieldModel( const ::com::sun::star::uno::Reference< ::com::sun::star::uno::XComponentContext >& rxContext );
1364 4 : UnoControlPatternFieldModel( const UnoControlPatternFieldModel& rModel ) : UnoControlModel( rModel ) {;}
1365 :
1366 4 : UnoControlModel* Clone() const SAL_OVERRIDE { return new UnoControlPatternFieldModel( *this ); }
1367 :
1368 : // ::com::sun::star::io::XPersistObject
1369 : OUString SAL_CALL getServiceName() throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
1370 :
1371 : // ::com::sun::star::beans::XMultiPropertySet
1372 : ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertySetInfo > SAL_CALL getPropertySetInfo( ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
1373 :
1374 : // ::com::sun::star::lang::XServiceInfo
1375 30 : DECLIMPL_SERVICEINFO_DERIVED( UnoControlPatternFieldModel, UnoControlModel, szServiceName2_UnoControlPatternFieldModel )
1376 :
1377 : };
1378 :
1379 :
1380 : // class UnoPatternFieldControl
1381 :
1382 28 : class UnoPatternFieldControl : public UnoSpinFieldControl,
1383 : public ::com::sun::star::awt::XPatternField
1384 : {
1385 : protected:
1386 : void ImplSetPeerProperty( const OUString& rPropName, const ::com::sun::star::uno::Any& rVal ) SAL_OVERRIDE;
1387 :
1388 : public:
1389 : UnoPatternFieldControl();
1390 : OUString GetComponentServiceName() SAL_OVERRIDE;
1391 :
1392 1082 : ::com::sun::star::uno::Any SAL_CALL queryInterface( const ::com::sun::star::uno::Type & rType ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE { return UnoSpinFieldControl::queryInterface(rType); }
1393 : ::com::sun::star::uno::Any SAL_CALL queryAggregation( const ::com::sun::star::uno::Type & rType ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
1394 3606 : void SAL_CALL acquire() throw() SAL_OVERRIDE { OWeakAggObject::acquire(); }
1395 3606 : void SAL_CALL release() throw() SAL_OVERRIDE { OWeakAggObject::release(); }
1396 :
1397 : // ::com::sun::star::lang::XTypeProvider
1398 : ::com::sun::star::uno::Sequence< ::com::sun::star::uno::Type > SAL_CALL getTypes() throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
1399 : ::com::sun::star::uno::Sequence< sal_Int8 > SAL_CALL getImplementationId() throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
1400 :
1401 : // ::com::sun::star::awt::XPatternField
1402 : void SAL_CALL setMasks( const OUString& EditMask, const OUString& LiteralMask ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
1403 : void SAL_CALL getMasks( OUString& EditMask, OUString& LiteralMask ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
1404 : void SAL_CALL setString( const OUString& Str ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
1405 : OUString SAL_CALL getString( ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
1406 : void SAL_CALL setStrictFormat( sal_Bool bStrict ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
1407 : sal_Bool SAL_CALL isStrictFormat( ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
1408 :
1409 : // ::com::sun::star::lang::XServiceInfo
1410 2 : DECLIMPL_SERVICEINFO_DERIVED( UnoPatternFieldControl, UnoSpinFieldControl, szServiceName2_UnoControlPatternField )
1411 :
1412 : };
1413 :
1414 :
1415 : // class UnoControlProgressBarModel
1416 :
1417 20 : class UnoControlProgressBarModel : public UnoControlModel
1418 : {
1419 : protected:
1420 : ::com::sun::star::uno::Any ImplGetDefaultValue( sal_uInt16 nPropId ) const SAL_OVERRIDE;
1421 : ::cppu::IPropertyArrayHelper& SAL_CALL getInfoHelper() SAL_OVERRIDE;
1422 :
1423 : public:
1424 : UnoControlProgressBarModel( const ::com::sun::star::uno::Reference< ::com::sun::star::uno::XComponentContext >& rxContext );
1425 2 : UnoControlProgressBarModel( const UnoControlProgressBarModel& rModel ) : UnoControlModel( rModel ) {;}
1426 :
1427 2 : UnoControlModel* Clone() const SAL_OVERRIDE { return new UnoControlProgressBarModel( *this ); }
1428 :
1429 : // ::com::sun::star::beans::XMultiPropertySet
1430 : ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertySetInfo > SAL_CALL getPropertySetInfo( ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
1431 :
1432 : // ::com::sun::star::io::XPersistObject
1433 : OUString SAL_CALL getServiceName() throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
1434 :
1435 : // XServiceInfo
1436 8 : DECLIMPL_SERVICEINFO_DERIVED( UnoControlProgressBarModel, UnoControlModel, szServiceName2_UnoControlProgressBarModel )
1437 : };
1438 :
1439 :
1440 : // class UnoProgressBarControl
1441 :
1442 0 : class UnoProgressBarControl : public UnoControlBase,
1443 : public ::com::sun::star::awt::XProgressBar
1444 : {
1445 : public:
1446 : UnoProgressBarControl();
1447 : OUString GetComponentServiceName() SAL_OVERRIDE;
1448 :
1449 0 : ::com::sun::star::uno::Any SAL_CALL queryInterface( const ::com::sun::star::uno::Type & rType ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE { return UnoControlBase::queryInterface(rType); }
1450 : ::com::sun::star::uno::Any SAL_CALL queryAggregation( const ::com::sun::star::uno::Type & rType ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
1451 0 : void SAL_CALL acquire() throw() SAL_OVERRIDE { OWeakAggObject::acquire(); }
1452 0 : void SAL_CALL release() throw() SAL_OVERRIDE { OWeakAggObject::release(); }
1453 :
1454 : // ::com::sun::star::lang::XTypeProvider
1455 : ::com::sun::star::uno::Sequence< ::com::sun::star::uno::Type > SAL_CALL getTypes() throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
1456 : ::com::sun::star::uno::Sequence< sal_Int8 > SAL_CALL getImplementationId() throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
1457 :
1458 : // ::com::sun::star::awt::XProgressBar
1459 : void SAL_CALL setForegroundColor( sal_Int32 nColor ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
1460 : void SAL_CALL setBackgroundColor( sal_Int32 nColor ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
1461 : void SAL_CALL setValue( sal_Int32 nValue ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
1462 : void SAL_CALL setRange( sal_Int32 nMin, sal_Int32 nMax ) throw(::com::sun::star::uno::RuntimeException, std::exception ) SAL_OVERRIDE;
1463 : sal_Int32 SAL_CALL getValue() throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
1464 :
1465 : // ::com::sun::star::lang::XServiceInfo
1466 0 : DECLIMPL_SERVICEINFO_DERIVED( UnoProgressBarControl, UnoControlBase, szServiceName2_UnoControlProgressBar )
1467 : };
1468 :
1469 :
1470 :
1471 : // class UnoControlFixedLineModel
1472 :
1473 20 : class UnoControlFixedLineModel : public UnoControlModel
1474 : {
1475 : protected:
1476 : ::com::sun::star::uno::Any ImplGetDefaultValue( sal_uInt16 nPropId ) const SAL_OVERRIDE;
1477 : ::cppu::IPropertyArrayHelper& SAL_CALL getInfoHelper() SAL_OVERRIDE;
1478 :
1479 : public:
1480 : UnoControlFixedLineModel( const ::com::sun::star::uno::Reference< ::com::sun::star::uno::XComponentContext >& rxContext );
1481 2 : UnoControlFixedLineModel( const UnoControlFixedLineModel& rModel ) : UnoControlModel( rModel ) {;}
1482 :
1483 2 : UnoControlModel* Clone() const SAL_OVERRIDE { return new UnoControlFixedLineModel( *this ); }
1484 :
1485 : // ::com::sun::star::beans::XMultiPropertySet
1486 : ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertySetInfo > SAL_CALL getPropertySetInfo( ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
1487 :
1488 : // ::com::sun::star::io::XPersistObject
1489 : OUString SAL_CALL getServiceName() throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
1490 :
1491 : // ::com::sun::star::lang::XServiceInfo
1492 14 : DECLIMPL_SERVICEINFO_DERIVED( UnoControlFixedLineModel, UnoControlModel, szServiceName2_UnoControlFixedLineModel )
1493 :
1494 : };
1495 :
1496 :
1497 : // class UnoFixedLineControl
1498 :
1499 0 : class UnoFixedLineControl : public UnoControlBase
1500 : {
1501 : public:
1502 : UnoFixedLineControl();
1503 : OUString GetComponentServiceName() SAL_OVERRIDE;
1504 :
1505 : sal_Bool SAL_CALL isTransparent( ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
1506 :
1507 : // ::com::sun::star::lang::XServiceInfo
1508 0 : DECLIMPL_SERVICEINFO_DERIVED( UnoFixedLineControl, UnoControlBase, szServiceName2_UnoControlFixedLine )
1509 :
1510 : };
1511 :
1512 :
1513 :
1514 : #endif // INCLUDED_TOOLKIT_CONTROLS_UNOCONTROLS_HXX
1515 :
1516 : /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
|