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_SD_SOURCE_UI_UNOIDL_UNOPBACK_HXX
20 #define INCLUDED_SD_SOURCE_UI_UNOIDL_UNOPBACK_HXX
22 #include <sal/config.h>
26 #include <com/sun/star/beans/XPropertySet.hpp>
27 #include <com/sun/star/beans/XPropertyState.hpp>
28 #include <com/sun/star/lang/XServiceInfo.hpp>
29 #include <com/sun/star/lang/XUnoTunnel.hpp>
31 #include <svl/lstner.hxx>
32 #include <comphelper/servicehelper.hxx>
34 #include <cppuhelper/implbase.hxx>
39 class SvxItemPropertySet
;
40 struct SfxItemPropertySimpleEntry
;
42 const SvxItemPropertySet
* ImplGetPageBackgroundPropertySet();
44 class SdUnoPageBackground final
: public ::cppu::WeakImplHelper
<
45 css::beans::XPropertySet
,
46 css::lang::XServiceInfo
,
47 css::beans::XPropertyState
,
48 css::lang::XUnoTunnel
>,
51 const SvxItemPropertySet
* mpPropSet
;
52 std::unique_ptr
<SfxItemSet
> mpSet
;
55 const SfxItemPropertySimpleEntry
* getPropertyMapEntry( const OUString
& rPropertyName
) const throw();
57 SdUnoPageBackground( SdDrawDocument
* pDoc
= nullptr, const SfxItemSet
* pSet
= nullptr);
58 virtual ~SdUnoPageBackground() throw() override
;
61 void fillItemSet( SdDrawDocument
* pDoc
, SfxItemSet
& rSet
) throw();
62 virtual void Notify( SfxBroadcaster
& rBC
, const SfxHint
& rHint
) override
;
65 UNO3_GETIMPLEMENTATION_DECL( SdUnoPageBackground
)
68 virtual OUString SAL_CALL
getImplementationName() override
;
69 virtual sal_Bool SAL_CALL
supportsService( const OUString
& ServiceName
) override
;
70 virtual css::uno::Sequence
< OUString
> SAL_CALL
getSupportedServiceNames() override
;
73 virtual css::uno::Reference
< css::beans::XPropertySetInfo
> SAL_CALL
getPropertySetInfo() override
;
74 virtual void SAL_CALL
setPropertyValue( const OUString
& aPropertyName
, const css::uno::Any
& aValue
) override
;
75 virtual css::uno::Any SAL_CALL
getPropertyValue( const OUString
& PropertyName
) override
;
76 virtual void SAL_CALL
addPropertyChangeListener( const OUString
& aPropertyName
, const css::uno::Reference
< css::beans::XPropertyChangeListener
>& xListener
) override
;
77 virtual void SAL_CALL
removePropertyChangeListener( const OUString
& aPropertyName
, const css::uno::Reference
< css::beans::XPropertyChangeListener
>& aListener
) override
;
78 virtual void SAL_CALL
addVetoableChangeListener( const OUString
& PropertyName
, const css::uno::Reference
< css::beans::XVetoableChangeListener
>& aListener
) override
;
79 virtual void SAL_CALL
removeVetoableChangeListener( const OUString
& PropertyName
, const css::uno::Reference
< css::beans::XVetoableChangeListener
>& aListener
) override
;
82 virtual css::beans::PropertyState SAL_CALL
getPropertyState( const OUString
& PropertyName
) override
;
83 virtual css::uno::Sequence
< css::beans::PropertyState
> SAL_CALL
getPropertyStates( const css::uno::Sequence
< OUString
>& aPropertyName
) override
;
84 virtual void SAL_CALL
setPropertyToDefault( const OUString
& PropertyName
) override
;
85 virtual css::uno::Any SAL_CALL
getPropertyDefault( const OUString
& aPropertyName
) override
;
90 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */