diff options
author | Noel Grandin <noel.grandin@collabora.co.uk> | 2023-02-23 15:31:34 +0200 |
---|---|---|
committer | Noel Grandin <noel.grandin@collabora.co.uk> | 2023-02-24 08:10:25 +0000 |
commit | e0f05df76177174fce1d662b211b3047237debae (patch) | |
tree | 7f0ec50e1bf6b0657406fa9bfd09d313507eed02 | |
parent | b4b3f281443fc64b420156eed11af773f80a4e2a (diff) |
BaseMutex->std::mutex in sd::tools::PropertySet
Change-Id: Iab6d9f3cb1c198f9f3ffd8ac556985cafb821787
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/147587
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
-rw-r--r-- | sd/source/ui/inc/tools/PropertySet.hxx | 11 | ||||
-rw-r--r-- | sd/source/ui/tools/PropertySet.cxx | 11 |
2 files changed, 6 insertions, 16 deletions
diff --git a/sd/source/ui/inc/tools/PropertySet.hxx b/sd/source/ui/inc/tools/PropertySet.hxx index c432783da394..04727be0dbe4 100644 --- a/sd/source/ui/inc/tools/PropertySet.hxx +++ b/sd/source/ui/inc/tools/PropertySet.hxx @@ -19,15 +19,14 @@ #pragma once -#include <cppuhelper/basemutex.hxx> -#include <cppuhelper/compbase.hxx> +#include <comphelper/compbase.hxx> #include <com/sun/star/beans/XPropertySet.hpp> #include <map> #include <memory> namespace sd::tools { -typedef ::cppu::WeakComponentImplHelper < +typedef ::comphelper::WeakComponentImplHelper < css::beans::XPropertySet > PropertySetInterfaceBase; @@ -38,16 +37,12 @@ typedef ::cppu::WeakComponentImplHelper < In order to use it you have to derive from this class and implement the GetPropertyValue() and SetPropertyValue() methods. */ -class PropertySet - : protected ::cppu::BaseMutex, - public PropertySetInterfaceBase +class PropertySet : public PropertySetInterfaceBase { public: explicit PropertySet(); virtual ~PropertySet() override; - virtual void SAL_CALL disposing() override; - // XPropertySet virtual css::uno::Reference<css::beans::XPropertySetInfo> diff --git a/sd/source/ui/tools/PropertySet.cxx b/sd/source/ui/tools/PropertySet.cxx index 057b7dd96ce3..c50a617de1b0 100644 --- a/sd/source/ui/tools/PropertySet.cxx +++ b/sd/source/ui/tools/PropertySet.cxx @@ -26,8 +26,7 @@ using namespace ::com::sun::star::uno; namespace sd::tools { PropertySet::PropertySet() - : PropertySetInterfaceBase(m_aMutex), - mpChangeListeners(new ChangeListenerContainer) + : mpChangeListeners(new ChangeListenerContainer) { } @@ -35,10 +34,6 @@ PropertySet::~PropertySet() { } -void SAL_CALL PropertySet::disposing() -{ -} - //----- XPropertySet ---------------------------------------------------------- Reference<beans::XPropertySetInfo> SAL_CALL PropertySet::getPropertySetInfo() @@ -83,7 +78,7 @@ void SAL_CALL PropertySet::addPropertyChangeListener ( if ( ! rxListener.is()) throw lang::IllegalArgumentException(); - if (rBHelper.bDisposed || rBHelper.bInDispose) + if (m_bDisposed) return; mpChangeListeners->emplace(rsPropertyName, rxListener); @@ -145,7 +140,7 @@ void PropertySet::CallListeners ( void PropertySet::ThrowIfDisposed() { - if (rBHelper.bDisposed || rBHelper.bInDispose) + if (m_bDisposed) { throw lang::DisposedException ( "PropertySet object has already been disposed", |