From eec42f0dbcc79a4c9f456ce97fa1066b8031ea28 Mon Sep 17 00:00:00 2001 From: Noel Grandin Date: Sun, 15 Aug 2021 17:35:58 +0200 Subject: pass OutlinerParaObject around by value since it uses o3tl::cow_wrapper, so it is really just a wrapper around a pointer, no point in allocating it on the heap Remove assert in SdrText::SetOutlinerParaObject, which was bogus anyhow, because it was comparing pointers, not deep equality. And since we are now being more efficient and avoiding copying of the internal data in OutlinerParaObject, we hit this assert. Change-Id: I6dbfaab5ee2ca05b2001baf63110041e469df9c5 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/120510 Tested-by: Noel Grandin Reviewed-by: Noel Grandin --- sd/source/ui/view/drviews9.cxx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'sd/source/ui/view/drviews9.cxx') diff --git a/sd/source/ui/view/drviews9.cxx b/sd/source/ui/view/drviews9.cxx index 0909d8536fcd..4ba735f153cd 100644 --- a/sd/source/ui/view/drviews9.cxx +++ b/sd/source/ui/view/drviews9.cxx @@ -150,7 +150,7 @@ void DrawViewShell::ExecGallery(SfxRequest const & rReq) SdrGrafObj* pNewGrafObj(pGrafObj->CloneSdrObject(pGrafObj->getSdrModelFromSdrObject())); pNewGrafObj->SetEmptyPresObj(false); - pNewGrafObj->SetOutlinerParaObject(nullptr); + pNewGrafObj->SetOutlinerParaObject(std::nullopt); pNewGrafObj->SetGraphic(aGraphic); OUString aStr = mpDrawView->GetDescriptionOfMarkedObjects() + -- cgit