summaryrefslogtreecommitdiff
path: root/svx
diff options
context:
space:
mode:
authorNoel Grandin <noel.grandin@collabora.co.uk>2018-04-30 19:17:27 +0200
committerNoel Grandin <noel.grandin@collabora.co.uk>2018-05-02 08:26:54 +0200
commit18b5b3ae444209b2e4476411194896ae917a2beb (patch)
treecf04b4a9dce9a81a9ab227f9539cf8a47fb4df0d /svx
parent1c944356f817013353819c6eb4bc5ed86356658d (diff)
loplugin:useuniqueptr in E3dScene
Change-Id: Ia2de7248406b47539ff40d81491ec1541c0c7bcd Reviewed-on: https://gerrit.libreoffice.org/53709 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'svx')
-rw-r--r--svx/source/engine3d/scene3d.cxx8
1 files changed, 2 insertions, 6 deletions
diff --git a/svx/source/engine3d/scene3d.cxx b/svx/source/engine3d/scene3d.cxx
index 5992fbae38b6..b3c9a401e3c4 100644
--- a/svx/source/engine3d/scene3d.cxx
+++ b/svx/source/engine3d/scene3d.cxx
@@ -233,11 +233,7 @@ basegfx::B2DPolyPolygon E3dScene::TakeXorPoly() const
void E3dScene::ImpCleanup3DDepthMapper()
{
- if(mp3DDepthRemapper)
- {
- delete mp3DDepthRemapper;
- mp3DDepthRemapper = nullptr;
- }
+ mp3DDepthRemapper.reset();
}
sal_uInt32 E3dScene::RemapOrdNum(sal_uInt32 nNewOrdNum) const
@@ -248,7 +244,7 @@ sal_uInt32 E3dScene::RemapOrdNum(sal_uInt32 nNewOrdNum) const
if(nObjCount > 1)
{
- const_cast<E3dScene*>(this)->mp3DDepthRemapper = new Imp3DDepthRemapper(*this);
+ mp3DDepthRemapper.reset(new Imp3DDepthRemapper(*this));
}
}