diff options
author | Noel Grandin <noelgrandin@gmail.com> | 2021-12-28 17:08:51 +0200 |
---|---|---|
committer | Noel Grandin <noel.grandin@collabora.co.uk> | 2021-12-29 08:35:07 +0100 |
commit | f5f97c7949d08c706ffb1f7a17b8bab32d2e2109 (patch) | |
tree | 210d87498145ecfcd25a6a53b71d4ab97037b3bd /sd | |
parent | ee6d4e2c79bd7d9b007518592f1a3ecc884660f1 (diff) |
use comphelper::WeakComponentImplHelper in PresentationFactory
Change-Id: Iff8c17951e3d17c280f47211432ee619ff188ea0
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/127647
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'sd')
-rw-r--r-- | sd/source/ui/framework/factories/PresentationFactory.cxx | 9 | ||||
-rw-r--r-- | sd/source/ui/inc/framework/PresentationFactory.hxx | 13 |
2 files changed, 7 insertions, 15 deletions
diff --git a/sd/source/ui/framework/factories/PresentationFactory.cxx b/sd/source/ui/framework/factories/PresentationFactory.cxx index 4fb0ac40e2ad..57304923f142 100644 --- a/sd/source/ui/framework/factories/PresentationFactory.cxx +++ b/sd/source/ui/framework/factories/PresentationFactory.cxx @@ -91,8 +91,7 @@ constexpr OUStringLiteral gsPresentationViewURL = u"private:resource/view/Presen PresentationFactory::PresentationFactory ( const Reference<frame::XController>& rxController) - : PresentationFactoryInterfaceBase(m_aMutex), - mxController(rxController) + : mxController(rxController) { } @@ -100,10 +99,6 @@ PresentationFactory::~PresentationFactory() { } -void SAL_CALL PresentationFactory::disposing() -{ -} - //----- XViewFactory ---------------------------------------------------------- Reference<XResource> SAL_CALL PresentationFactory::createResource ( @@ -146,7 +141,7 @@ void SAL_CALL PresentationFactory::disposing ( void PresentationFactory::ThrowIfDisposed() const { - if (rBHelper.bDisposed || rBHelper.bInDispose) + if (m_bDisposed) { throw lang::DisposedException ("PresentationFactory object has already been disposed", const_cast<uno::XWeak*>(static_cast<const uno::XWeak*>(this))); diff --git a/sd/source/ui/inc/framework/PresentationFactory.hxx b/sd/source/ui/inc/framework/PresentationFactory.hxx index 058086081c2b..897825c8acfb 100644 --- a/sd/source/ui/inc/framework/PresentationFactory.hxx +++ b/sd/source/ui/inc/framework/PresentationFactory.hxx @@ -21,14 +21,13 @@ #include <com/sun/star/drawing/framework/XResourceFactory.hpp> #include <com/sun/star/drawing/framework/XConfigurationChangeListener.hpp> -#include <cppuhelper/basemutex.hxx> -#include <cppuhelper/compbase.hxx> +#include <comphelper/compbase.hxx> namespace com::sun::star::frame { class XController; } namespace sd::framework { -typedef ::cppu::WeakComponentImplHelper < +typedef comphelper::WeakComponentImplHelper < css::drawing::framework::XResourceFactory, css::drawing::framework::XConfigurationChangeListener > PresentationFactoryInterfaceBase; @@ -37,17 +36,14 @@ typedef ::cppu::WeakComponentImplHelper < indicates that a slideshow is running (in another but associated application window). */ -class PresentationFactory - : private cppu::BaseMutex, - public PresentationFactoryInterfaceBase +class PresentationFactory final + : public PresentationFactoryInterfaceBase { public: PresentationFactory ( const css::uno::Reference<css::frame::XController>& rxController); virtual ~PresentationFactory() override; - virtual void SAL_CALL disposing() override; - // XResourceFactory virtual css::uno::Reference<css::drawing::framework::XResource> @@ -65,6 +61,7 @@ public: // lang::XEventListener + using WeakComponentImplHelperBase::disposing; virtual void SAL_CALL disposing ( const css::lang::EventObject& rEventObject) override; |