LibreOffice Module reportdesign (master) 1
ReportComponentHandler.hxx
Go to the documentation of this file.
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_REPORTDESIGN_SOURCE_UI_INC_REPORTCOMPONENTHANDLER_HXX
21#define INCLUDED_REPORTDESIGN_SOURCE_UI_INC_REPORTCOMPONENTHANDLER_HXX
22
23#include <sal/config.h>
24#include <com/sun/star/uno/XComponentContext.hpp>
27#include <com/sun/star/inspection/XPropertyHandler.hpp>
28#include <com/sun/star/lang/XServiceInfo.hpp>
29
30
31namespace rptui
32{
33
34
35 class OPropertyInfoService;
36
37 typedef ::cppu::WeakComponentImplHelper< css::inspection::XPropertyHandler
38 , css::lang::XServiceInfo> ReportComponentHandler_Base;
39
41 private ::cppu::BaseMutex,
43 {
44 public:
45 explicit ReportComponentHandler(css::uno::Reference< css::uno::XComponentContext > context);
46
47 // XServiceInfo
48 virtual OUString SAL_CALL getImplementationName( ) override;
49 virtual sal_Bool SAL_CALL supportsService( const OUString& ServiceName ) override;
50 virtual css::uno::Sequence< OUString > SAL_CALL getSupportedServiceNames( ) override;
51
52 // css::lang::XComponent:
53 virtual void SAL_CALL addEventListener(const css::uno::Reference< css::lang::XEventListener > & xListener) override;
54 virtual void SAL_CALL removeEventListener(const css::uno::Reference< css::lang::XEventListener > & aListener) override;
55
56 // css::inspection::XPropertyHandler:
57 virtual void SAL_CALL inspect(const css::uno::Reference< css::uno::XInterface > & Component) override;
58 virtual css::uno::Any SAL_CALL getPropertyValue(const OUString & PropertyName) override;
59 virtual void SAL_CALL setPropertyValue(const OUString & PropertyName, const css::uno::Any & Value) override;
60 virtual css::beans::PropertyState SAL_CALL getPropertyState(const OUString & PropertyName) override;
61 virtual css::inspection::LineDescriptor SAL_CALL describePropertyLine(const OUString& PropertyName, const css::uno::Reference< css::inspection::XPropertyControlFactory >& ControlFactory ) override;
62 virtual css::uno::Any SAL_CALL convertToPropertyValue(const OUString & PropertyName, const css::uno::Any & ControlValue) override;
63 virtual css::uno::Any SAL_CALL convertToControlValue(const OUString & PropertyName, const css::uno::Any & PropertyValue, const css::uno::Type & ControlValueType) override;
64 virtual void SAL_CALL addPropertyChangeListener(const css::uno::Reference< css::beans::XPropertyChangeListener > & Listener) override;
65 virtual void SAL_CALL removePropertyChangeListener(const css::uno::Reference< css::beans::XPropertyChangeListener > & _rxListener) override;
66 virtual css::uno::Sequence< css::beans::Property > SAL_CALL getSupportedProperties() override;
67 virtual css::uno::Sequence< OUString > SAL_CALL getSupersededProperties() override;
68 virtual css::uno::Sequence< OUString > SAL_CALL getActuatingProperties() override;
69 virtual sal_Bool SAL_CALL isComposable(const OUString & PropertyName) override;
70 virtual css::inspection::InteractiveSelectionResult SAL_CALL onInteractivePropertySelection(const OUString & PropertyName, sal_Bool Primary, css::uno::Any & out_Data, const css::uno::Reference< css::inspection::XObjectInspectorUI > & InspectorUI) override;
71 virtual void SAL_CALL actuatingPropertyChanged(const OUString & ActuatingPropertyName, const css::uno::Any & NewValue, const css::uno::Any & OldValue, const css::uno::Reference< css::inspection::XObjectInspectorUI > & InspectorUI, sal_Bool FirstTimeInit) override;
72 virtual sal_Bool SAL_CALL suspend(sal_Bool Suspend) override;
73
74 protected:
75 virtual ~ReportComponentHandler() override {}
76 private:
78 void operator =(ReportComponentHandler const &) = delete;
79
80
81 // override WeakComponentImplHelperBase::disposing()
82 // This function is called upon disposing the component,
83 // if your component needs special work when it becomes
84 // disposed, do it here.
85 virtual void SAL_CALL disposing() override;
86
87 css::uno::Reference< css::uno::XComponentContext > m_xContext;
88 css::uno::Reference< css::inspection::XPropertyHandler > m_xFormComponentHandler;
89 css::uno::Reference< css::uno::XInterface > m_xFormComponent;
90 };
91
92} // namespace rptui
93
94
95#endif // INCLUDED_REPORTDESIGN_SOURCE_UI_INC_REPORTCOMPONENTHANDLER_HXX
96
97/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
css::uno::Reference< css::uno::XInterface > m_xFormComponent
delegatee
virtual void SAL_CALL addEventListener(const css::uno::Reference< css::lang::XEventListener > &xListener) override
virtual css::uno::Sequence< OUString > SAL_CALL getSupportedServiceNames() override
virtual OUString SAL_CALL getImplementationName() override
virtual void SAL_CALL removePropertyChangeListener(const css::uno::Reference< css::beans::XPropertyChangeListener > &_rxListener) override
virtual css::inspection::InteractiveSelectionResult SAL_CALL onInteractivePropertySelection(const OUString &PropertyName, sal_Bool Primary, css::uno::Any &out_Data, const css::uno::Reference< css::inspection::XObjectInspectorUI > &InspectorUI) override
virtual css::inspection::LineDescriptor SAL_CALL describePropertyLine(const OUString &PropertyName, const css::uno::Reference< css::inspection::XPropertyControlFactory > &ControlFactory) override
virtual void SAL_CALL addPropertyChangeListener(const css::uno::Reference< css::beans::XPropertyChangeListener > &Listener) override
ReportComponentHandler(ReportComponentHandler const &)=delete
css::uno::Reference< css::inspection::XPropertyHandler > m_xFormComponentHandler
virtual css::uno::Any SAL_CALL convertToControlValue(const OUString &PropertyName, const css::uno::Any &PropertyValue, const css::uno::Type &ControlValueType) override
virtual css::uno::Sequence< OUString > SAL_CALL getActuatingProperties() override
ReportComponentHandler(css::uno::Reference< css::uno::XComponentContext > context)
virtual void SAL_CALL setPropertyValue(const OUString &PropertyName, const css::uno::Any &Value) override
virtual css::uno::Sequence< OUString > SAL_CALL getSupersededProperties() override
virtual sal_Bool SAL_CALL isComposable(const OUString &PropertyName) override
void operator=(ReportComponentHandler const &)=delete
virtual void SAL_CALL disposing() override
virtual css::uno::Any SAL_CALL convertToPropertyValue(const OUString &PropertyName, const css::uno::Any &ControlValue) override
virtual css::beans::PropertyState SAL_CALL getPropertyState(const OUString &PropertyName) override
virtual void SAL_CALL actuatingPropertyChanged(const OUString &ActuatingPropertyName, const css::uno::Any &NewValue, const css::uno::Any &OldValue, const css::uno::Reference< css::inspection::XObjectInspectorUI > &InspectorUI, sal_Bool FirstTimeInit) override
virtual css::uno::Any SAL_CALL getPropertyValue(const OUString &PropertyName) override
virtual css::uno::Sequence< css::beans::Property > SAL_CALL getSupportedProperties() override
virtual sal_Bool SAL_CALL suspend(sal_Bool Suspend) override
virtual sal_Bool SAL_CALL supportsService(const OUString &ServiceName) override
css::uno::Reference< css::uno::XComponentContext > m_xContext
virtual void SAL_CALL removeEventListener(const css::uno::Reference< css::lang::XEventListener > &aListener) override
virtual void SAL_CALL inspect(const css::uno::Reference< css::uno::XInterface > &Component) override
::cppu::WeakComponentImplHelper< css::inspection::XPropertyHandler, css::lang::XServiceInfo > ReportComponentHandler_Base
::std::pair< MetaAction *, int > Component
unsigned char sal_Bool