From 19edcfe36b32b15f86cba1eead7932b610e70ce7 Mon Sep 17 00:00:00 2001 From: Caolán McNamara Date: Mon, 11 May 2020 17:17:26 +0100 Subject: always use the LinkManager's persist as the known referer MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Change-Id: Ibb1bd9138993adbd8391b524c0cd654ba523cad2 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/94006 Tested-by: Jenkins Reviewed-by: Caolán McNamara --- svx/source/svdraw/svdograf.cxx | 9 +-------- 1 file changed, 1 insertion(+), 8 deletions(-) (limited to 'svx') diff --git a/svx/source/svdraw/svdograf.cxx b/svx/source/svdraw/svdograf.cxx index b0a13593845c..3f836d4123cd 100644 --- a/svx/source/svdraw/svdograf.cxx +++ b/svx/source/svdraw/svdograf.cxx @@ -19,9 +19,7 @@ #include -#include #include -#include #include #include #include @@ -92,13 +90,8 @@ SdrGraphicLink::SdrGraphicLink(SdrGrafObj& rObj) { sfx2::LinkManager::GetDisplayNames( this, nullptr, &rGrafObj.aFileName, nullptr, &rGrafObj.aFilterName ); - OUString sReferer(rGrafObj.aReferer); - SfxObjectShell * sh = pLinkManager->GetPersist(); - if (sh != nullptr && sh->HasName()) - sReferer = sh->GetMedium()->GetName(); - Graphic aGraphic; - if (sfx2::LinkManager::GetGraphicFromAny(rMimeType, rValue, sReferer, aGraphic, nullptr)) + if (pLinkManager->GetGraphicFromAny(rMimeType, rValue, aGraphic, nullptr)) { rGrafObj.ImpSetLinkedGraphic(aGraphic); } -- cgit