From b613896e3bb256418b2e31665da5baa6a9cdab56 Mon Sep 17 00:00:00 2001 From: Noel Grandin Date: Mon, 20 Apr 2020 18:14:20 +0200 Subject: CreateDocumentInfoDialog should return shared_ptr which is what it's only call site wants Change-Id: I1c2c2ed3a91a3376af142ac9a5d6993a2186d660 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/92590 Tested-by: Jenkins Reviewed-by: Noel Grandin --- sd/source/ui/docshell/docshel4.cxx | 4 ++-- sd/source/ui/inc/DrawDocShell.hxx | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) (limited to 'sd/source') diff --git a/sd/source/ui/docshell/docshel4.cxx b/sd/source/ui/docshell/docshel4.cxx index 9e90dd020282..1aaa92150cc6 100644 --- a/sd/source/ui/docshell/docshel4.cxx +++ b/sd/source/ui/docshell/docshel4.cxx @@ -954,9 +954,9 @@ void DrawDocShell::OpenBookmark( const OUString& rBookmarkURL ) ( mpViewShell ? mpViewShell->GetViewFrame() : SfxViewFrame::Current() )->GetBindings().Execute( SID_OPENHYPERLINK, ppArgs ); } -std::unique_ptr DrawDocShell::CreateDocumentInfoDialog(weld::Window* pParent, const SfxItemSet &rSet) +std::shared_ptr DrawDocShell::CreateDocumentInfoDialog(weld::Window* pParent, const SfxItemSet &rSet) { - std::unique_ptr xDlg = std::make_unique(pParent, rSet); + std::shared_ptr xDlg = std::make_shared(pParent, rSet); DrawDocShell* pDocSh = dynamic_cast(SfxObjectShell::Current()); if( pDocSh == this ) { diff --git a/sd/source/ui/inc/DrawDocShell.hxx b/sd/source/ui/inc/DrawDocShell.hxx index cb89e22bd446..a8d6dd3084b5 100644 --- a/sd/source/ui/inc/DrawDocShell.hxx +++ b/sd/source/ui/inc/DrawDocShell.hxx @@ -98,7 +98,7 @@ public: virtual SfxStyleSheetBasePool* GetStyleSheetPool() override; virtual void FillClass(SvGlobalName* pClassName, SotClipboardFormatId* pFormat, OUString* pFullTypeName, sal_Int32 nFileFormat, bool bTemplate = false ) const override; virtual void SetModified( bool = true ) override; - virtual std::unique_ptr CreateDocumentInfoDialog(weld::Window* pParent, + virtual std::shared_ptr CreateDocumentInfoDialog(weld::Window* pParent, const SfxItemSet &rSet) override; using SfxObjectShell::GetVisArea; -- cgit