summaryrefslogtreecommitdiff
path: root/chart2
diff options
context:
space:
mode:
authorNoel Grandin <noelgrandin@gmail.com>2023-12-15 21:39:10 +0200
committerNoel Grandin <noel.grandin@collabora.co.uk>2023-12-16 10:44:10 +0100
commit3ca3fd6eafee8ead7578acfbc7d9a0f319ca7a4a (patch)
treed550d78f821d26efcb4ffbc762d8c134837fd94d /chart2
parentc498e2acd64688df9aa32bbcc820d8513a5373ea (diff)
no need to allocate this on the heap
Change-Id: I99a41076db39b76f6dbbd5974039ee271c29eee5 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/160840 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'chart2')
-rw-r--r--chart2/source/controller/main/ChartTransferable.cxx12
1 files changed, 6 insertions, 6 deletions
diff --git a/chart2/source/controller/main/ChartTransferable.cxx b/chart2/source/controller/main/ChartTransferable.cxx
index 2f27902ba1e3..9a94d45ff9ff 100644
--- a/chart2/source/controller/main/ChartTransferable.cxx
+++ b/chart2/source/controller/main/ChartTransferable.cxx
@@ -51,17 +51,17 @@ ChartTransferable::ChartTransferable(
bool bDrawing)
: m_bDrawing(bDrawing)
{
- std::unique_ptr<SdrExchangeView> pExchgView(std::make_unique<SdrView>( rSdrModel ));
- SdrPageView* pPv = pExchgView->ShowSdrPage( rSdrModel.GetPage( 0 ));
+ SdrView aExchgView( rSdrModel );
+ SdrPageView* pPv = aExchgView.ShowSdrPage( rSdrModel.GetPage( 0 ));
if( pSelectedObj )
- pExchgView->MarkObj( pSelectedObj, pPv );
+ aExchgView.MarkObj( pSelectedObj, pPv );
else
- pExchgView->MarkAllObj( pPv );
- Graphic aGraphic( pExchgView->GetMarkedObjMetaFile(true));
+ aExchgView.MarkAllObj( pPv );
+ Graphic aGraphic( aExchgView.GetMarkedObjMetaFile(true));
m_xMetaFileGraphic.set( aGraphic.GetXGraphic());
if ( m_bDrawing )
{
- m_xMarkedObjModel = pExchgView->CreateMarkedObjModel();
+ m_xMarkedObjModel = aExchgView.CreateMarkedObjModel();
}
}