diff options
author | Noel Grandin <noel.grandin@collabora.co.uk> | 2022-02-10 20:47:03 +0200 |
---|---|---|
committer | Noel Grandin <noel.grandin@collabora.co.uk> | 2022-02-11 05:52:11 +0100 |
commit | a2cee820e5e204058a721c59f2c5df8d8a2a3ca8 (patch) | |
tree | 95b4f6fb0fa166698d3272400dac6e3cee8b7daf /include/svx | |
parent | 01b3187e0713243c8f71d58197da17ee87c4dbb5 (diff) |
merge IPropertyValueProvider into PropertyValueProvider
nothing directly extends IPropertyValueProvider
Change-Id: Ib393bd31bde7f68d8b21dc3bdeeb30b538de1488
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/129797
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'include/svx')
-rw-r--r-- | include/svx/shapepropertynotifier.hxx | 37 |
1 files changed, 12 insertions, 25 deletions
diff --git a/include/svx/shapepropertynotifier.hxx b/include/svx/shapepropertynotifier.hxx index e736545b5ad8..a14fd1e597a3 100644 --- a/include/svx/shapepropertynotifier.hxx +++ b/include/svx/shapepropertynotifier.hxx @@ -54,32 +54,14 @@ namespace svx LAST = TextDocAnchor }; - //= IPropertyValueProvider - - /** a provider for a property value - */ - class SVXCORE_DLLPUBLIC IPropertyValueProvider - { - public: - /** returns the name of the property which this provider is responsible for - */ - virtual const OUString & getPropertyName() const = 0; - - /** returns the current value of the property which the provider is responsible for - */ - virtual void getCurrentValue( css::uno::Any& _out_rValue ) const = 0; - - virtual ~IPropertyValueProvider(); - }; - //= PropertyValueProvider - /** default implementation of an IPropertyValueProvider + /** Default provider for a property value This default implementation queries the object which it is constructed with for the XPropertySet interface, and calls the getPropertyValue method. */ - class SVXCORE_DLLPUBLIC PropertyValueProvider :public IPropertyValueProvider + class SVXCORE_DLLPUBLIC PropertyValueProvider { public: PropertyValueProvider( ::cppu::OWeakObject& _rContext, const char* _pAsciiPropertyName ) @@ -87,9 +69,14 @@ namespace svx ,m_sPropertyName( OUString::createFromAscii( _pAsciiPropertyName ) ) { } + virtual ~PropertyValueProvider(); - virtual const OUString & getPropertyName() const override; - virtual void getCurrentValue( css::uno::Any& _out_rValue ) const override; + /** returns the name of the property which this provider is responsible for + */ + const OUString & getPropertyName() const; + /** returns the current value of the property which the provider is responsible for + */ + virtual void getCurrentValue( css::uno::Any& _out_rValue ) const; protected: ::cppu::OWeakObject& getContext() const { return m_rContext; } @@ -122,9 +109,9 @@ namespace svx void addPropertyChangeListener( const OUString& _rPropertyName, const css::uno::Reference< css::beans::XPropertyChangeListener >& _rxListener ); void removePropertyChangeListener( const OUString& _rPropertyName, const css::uno::Reference< css::beans::XPropertyChangeListener >& _rxListener ); - /** registers an IPropertyValueProvider + /** registers an PropertyValueProvider */ - void registerProvider( const ShapePropertyProviderId _eProperty, std::unique_ptr<IPropertyValueProvider> _rProvider ); + void registerProvider( const ShapePropertyProviderId _eProperty, std::unique_ptr<PropertyValueProvider> _rProvider ); /** notifies changes in the given property to all registered listeners @@ -142,7 +129,7 @@ namespace svx PropertyChangeNotifier& operator=(const PropertyChangeNotifier&) = delete; ::cppu::OWeakObject& m_rContext; - o3tl::enumarray<ShapePropertyProviderId, std::unique_ptr<IPropertyValueProvider>> m_aProviders; + o3tl::enumarray<ShapePropertyProviderId, std::unique_ptr<PropertyValueProvider>> m_aProviders; comphelper::OMultiTypeInterfaceContainerHelperVar3<css::beans::XPropertyChangeListener, OUString> m_aPropertyChangeListeners; }; |