1 /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
3 * This file is part of the LibreOffice project.
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/.
9 * This file incorporates work covered by the following license notice:
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 .
19 #ifndef INCLUDED_EXTENSIONS_SOURCE_PROPCTRLR_FORMCONTROLLER_HXX
20 #define INCLUDED_EXTENSIONS_SOURCE_PROPCTRLR_FORMCONTROLLER_HXX
22 #include "propcontroller.hxx"
24 #include <cppuhelper/propshlp.hxx>
25 #include <comphelper/proparrhlp.hxx>
26 #include <comphelper/uno3.hxx>
35 struct ServiceDescriptor
38 ( *GetImplementationName
)( void );
39 css::uno::Sequence
< OUString
>
40 ( *GetSupportedServiceNames
)( void );
47 typedef ::cppu::OPropertySetHelper FormController_PropertyBase1
;
48 typedef ::comphelper::OPropertyArrayUsageHelper
< FormController
> FormController_PropertyBase2
;
50 /** Legacy implementation of com.sun.star.form.PropertyBrowserController
52 Nowadays only a wrapper around an ObjectInspector using a
53 DefaultFormComponentInspectorModel.
55 class FormController
:public OPropertyBrowserController
56 ,public FormController_PropertyBase1
57 ,public FormController_PropertyBase2
60 ServiceDescriptor m_aServiceDescriptor
;
61 css::uno::Reference
< css::beans::XPropertySet
>
65 const css::uno::Reference
< css::uno::XComponentContext
>& _rxContext
,
66 ServiceDescriptor _aServiceDescriptor
,
67 bool _bUseFormFormComponentHandlers
70 // XServiceInfo - static versions
71 /// @throws css::uno::RuntimeException
72 static OUString
getImplementationName_static( );
73 /// @throws css::uno::RuntimeException
74 static css::uno::Sequence
< OUString
> getSupportedServiceNames_static( );
75 static css::uno::Reference
< css::uno::XInterface
>
76 Create(const css::uno::Reference
< css::uno::XComponentContext
>&);
79 virtual ~FormController() override
;
82 DECLARE_XTYPEPROVIDER()
85 virtual OUString SAL_CALL
getImplementationName( ) override
;
86 virtual css::uno::Sequence
< OUString
> SAL_CALL
getSupportedServiceNames( ) override
;
88 // XPropertySet and friends
89 virtual css::uno::Reference
< css::beans::XPropertySetInfo
> SAL_CALL
getPropertySetInfo( ) override
;
90 virtual ::cppu::IPropertyArrayHelper
& SAL_CALL
getInfoHelper() override
;
91 virtual ::cppu::IPropertyArrayHelper
* createArrayHelper( ) const override
;
93 virtual sal_Bool SAL_CALL
convertFastPropertyValue(
94 css::uno::Any
& rConvertedValue
, css::uno::Any
& rOldValue
, sal_Int32 nHandle
, const css::uno::Any
& rValue
96 virtual void SAL_CALL
setFastPropertyValue_NoBroadcast(
97 sal_Int32 nHandle
, const css::uno::Any
& rValue
99 virtual void SAL_CALL
getFastPropertyValue(
100 css::uno::Any
& rValue
, sal_Int32 nHandle
103 using FormController_PropertyBase1::getFastPropertyValue
;
109 /** Legacy implementation of com.sun.star.awt.PropertyBrowserController
111 class DialogController
114 // XServiceInfo - static versions
115 /// @throws css::uno::RuntimeException
116 static OUString
getImplementationName_static( );
117 /// @throws css::uno::RuntimeException
118 static css::uno::Sequence
< OUString
> getSupportedServiceNames_static( );
119 static css::uno::Reference
< css::uno::XInterface
>
120 Create(const css::uno::Reference
< css::uno::XComponentContext
>&);
123 DialogController( const DialogController
& ) = delete;
124 DialogController
& operator=( const DialogController
& ) = delete;
130 #endif // INCLUDED_EXTENSIONS_SOURCE_PROPCTRLR_FORMCONTROLLER_HXX
132 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */