From 582aa81147557ace37b8ad4aea1bd153eb743c66 Mon Sep 17 00:00:00 2001 From: Stephan Bergmann Date: Wed, 22 Aug 2018 10:38:23 +0200 Subject: Adapt Library_vclplug_kde5 to f05f4e042ca6ac8ae7f1d1e8e6bfb4cbba17a044 ..."loplugin:useuniqueptr in SvpSalInstance" Change-Id: I6f3f7c102fcf07f552d3256553dd39e9cd54005f --- vcl/unx/kde5/KDE5SalInstance.cxx | 11 ++++++++--- vcl/unx/kde5/KDE5SalInstance.hxx | 6 +++++- 2 files changed, 13 insertions(+), 4 deletions(-) (limited to 'vcl/unx') diff --git a/vcl/unx/kde5/KDE5SalInstance.cxx b/vcl/unx/kde5/KDE5SalInstance.cxx index fecf22b49037..ec117b2104fc 100644 --- a/vcl/unx/kde5/KDE5SalInstance.cxx +++ b/vcl/unx/kde5/KDE5SalInstance.cxx @@ -17,6 +17,10 @@ * the License at http://www.apache.org/licenses/LICENSE-2.0 . */ +#include + +#include + //#include "KDE4FilePicker.hxx" #include #include @@ -24,6 +28,7 @@ #include #include +#include #include #include @@ -34,8 +39,8 @@ using namespace com::sun::star; -KDE5SalInstance::KDE5SalInstance(SalYieldMutex* pMutex) - : Qt5Instance(pMutex, true) +KDE5SalInstance::KDE5SalInstance(std::unique_ptr pMutex) + : Qt5Instance(std::move(pMutex), true) { ImplSVData* pSVData = ImplGetSVData(); delete pSVData->maAppData.mpToolkitName; @@ -130,7 +135,7 @@ VCLPLUG_KDE5_PUBLIC SalInstance* create_SalInstance() QApplication::setQuitOnLastWindowClosed(false); - KDE5SalInstance* pInstance = new KDE5SalInstance(new SalYieldMutex()); + KDE5SalInstance* pInstance = new KDE5SalInstance(o3tl::make_unique()); // initialize SalData new KDE5SalData(pInstance); diff --git a/vcl/unx/kde5/KDE5SalInstance.hxx b/vcl/unx/kde5/KDE5SalInstance.hxx index 0bf30ab8b235..affd89715f9e 100644 --- a/vcl/unx/kde5/KDE5SalInstance.hxx +++ b/vcl/unx/kde5/KDE5SalInstance.hxx @@ -19,6 +19,10 @@ #pragma once +#include + +#include + #include #include "KDE5SalFrame.hxx" @@ -28,7 +32,7 @@ class SalFrame; class KDE5SalInstance : public Qt5Instance { public: - explicit KDE5SalInstance(SalYieldMutex* pMutex); + explicit KDE5SalInstance(std::unique_ptr pMutex); virtual SalFrame* CreateFrame(SalFrame* pParent, SalFrameStyleFlags nStyle) override; virtual bool hasNativeFileSelection() const override { return true; } -- cgit