sd/source/ui/inc/ViewTabBar.hxx | 10 ++++------ sd/source/ui/view/ViewTabBar.cxx | 5 ++--- 2 files changed, 6 insertions(+), 9 deletions(-)
New commits: commit f030d899d8f52684b0d34bcc1f4d9864f243ce73 Author: Noel Grandin <noelgran...@gmail.com> AuthorDate: Tue Dec 28 17:24:55 2021 +0200 Commit: Noel Grandin <noel.gran...@collabora.co.uk> CommitDate: Wed Dec 29 07:14:12 2021 +0100 use comphelper::WeakComponentImplHelper in ViewTabBar Change-Id: If64cb90586532ee20321cfbf3dd634781a9d9a9a Reviewed-on: https://gerrit.libreoffice.org/c/core/+/127651 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.gran...@collabora.co.uk> diff --git a/sd/source/ui/inc/ViewTabBar.hxx b/sd/source/ui/inc/ViewTabBar.hxx index fed069cbb45f..ca9db932e0c6 100644 --- a/sd/source/ui/inc/ViewTabBar.hxx +++ b/sd/source/ui/inc/ViewTabBar.hxx @@ -24,8 +24,7 @@ #include <com/sun/star/drawing/framework/XToolBar.hpp> #include <com/sun/star/drawing/framework/XConfigurationChangeListener.hpp> #include <com/sun/star/lang/XUnoTunnel.hpp> -#include <cppuhelper/basemutex.hxx> -#include <cppuhelper/compbase.hxx> +#include <comphelper/compbase.hxx> #include <vcl/InterimItemWindow.hxx> #include <vector> @@ -60,7 +59,7 @@ private: DECL_LINK(NotebookSizeAllocHdl, const Size&, void); }; -typedef ::cppu::WeakComponentImplHelper < +typedef comphelper::WeakComponentImplHelper < css::drawing::framework::XToolBar, css::drawing::framework::XTabBar, css::drawing::framework::XConfigurationChangeListener, @@ -70,8 +69,7 @@ typedef ::cppu::WeakComponentImplHelper < /** Tab control for switching between views in the center pane. */ class ViewTabBar final - : private cppu::BaseMutex, - public ViewTabBarInterfaceBase + : public ViewTabBarInterfaceBase { public: ViewTabBar ( @@ -79,7 +77,7 @@ public: const css::uno::Reference< css::frame::XController>& rxController); virtual ~ViewTabBar() override; - virtual void SAL_CALL disposing() override; + virtual void disposing(std::unique_lock<std::mutex>&) override; const VclPtr<TabBarControl>& GetTabControl() const { return mpTabControl; } diff --git a/sd/source/ui/view/ViewTabBar.cxx b/sd/source/ui/view/ViewTabBar.cxx index 4e205b04276e..18a408e83956 100644 --- a/sd/source/ui/view/ViewTabBar.cxx +++ b/sd/source/ui/view/ViewTabBar.cxx @@ -59,8 +59,7 @@ bool IsEqual (const TabBarButton& rButton1, const TabBarButton& rButton2) ViewTabBar::ViewTabBar ( const Reference<XResourceId>& rxViewTabBarId, const Reference<frame::XController>& rxController) - : ViewTabBarInterfaceBase(m_aMutex), - mpTabControl(VclPtr<TabBarControl>::Create(GetAnchorWindow(rxViewTabBarId,rxController), this)), + : mpTabControl(VclPtr<TabBarControl>::Create(GetAnchorWindow(rxViewTabBarId,rxController), this)), mxController(rxController), mxViewTabBarId(rxViewTabBarId), mpViewShellBase(nullptr), @@ -106,7 +105,7 @@ ViewTabBar::~ViewTabBar() { } -void ViewTabBar::disposing() +void ViewTabBar::disposing(std::unique_lock<std::mutex>&) { if (mpViewShellBase != nullptr && mxViewTabBarId->isBoundToURL(