summaryrefslogtreecommitdiff
path: root/svx
diff options
context:
space:
mode:
authorNoel Grandin <noel.grandin@collabora.co.uk>2018-06-04 14:30:16 +0200
committerNoel Grandin <noel.grandin@collabora.co.uk>2018-06-11 08:25:50 +0200
commitee28d75d495c9e115397e0825b14bd3cbf67d5f3 (patch)
tree8e306c6c8087771850c9a23e3876bc2bf398e68e /svx
parentb2c9f0045b62829d09607bb69cd6480ea18b6c25 (diff)
loplugin:useuniqueptr in Svx3DWin
Change-Id: I529a486b7b60306293089b776202810f84ab0126 Reviewed-on: https://gerrit.libreoffice.org/55516 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/float3d.cxx18
1 files changed, 9 insertions, 9 deletions
diff --git a/svx/source/engine3d/float3d.cxx b/svx/source/engine3d/float3d.cxx
index 615957ada6a4..4d840574eeee 100644
--- a/svx/source/engine3d/float3d.cxx
+++ b/svx/source/engine3d/float3d.cxx
@@ -212,9 +212,9 @@ Svx3DWin::Svx3DWin(SfxBindings* pInBindings, SfxChildWindow *pCW, vcl::Window* p
m_pMtrDistance->SetUnit( eFUnit );
m_pMtrFocalLength->SetUnit( eFUnit );
- pControllerItem = new Svx3DCtrlItem(SID_3D_STATE, pBindings);
- pConvertTo3DItem = new SvxConvertTo3DItem(SID_CONVERT_TO_3D, pBindings);
- pConvertTo3DLatheItem = new SvxConvertTo3DItem(SID_CONVERT_TO_3D_LATHE_FAST, pBindings);
+ pControllerItem.reset( new Svx3DCtrlItem(SID_3D_STATE, pBindings) );
+ pConvertTo3DItem.reset( new SvxConvertTo3DItem(SID_CONVERT_TO_3D, pBindings) );
+ pConvertTo3DLatheItem.reset( new SvxConvertTo3DItem(SID_CONVERT_TO_3D_LATHE_FAST, pBindings) );
m_pBtnAssign->SetClickHdl( LINK( this, Svx3DWin, ClickAssignHdl ) );
m_pBtnUpdate->SetClickHdl( LINK( this, Svx3DWin, ClickUpdateHdl ) );
@@ -330,11 +330,11 @@ Svx3DWin::~Svx3DWin()
void Svx3DWin::dispose()
{
pVDev.disposeAndClear();
- delete pModel;
+ pModel.reset();
- DELETEZ( pControllerItem );
- DELETEZ( pConvertTo3DItem );
- DELETEZ( pConvertTo3DLatheItem );
+ pControllerItem.reset();
+ pConvertTo3DItem.reset();
+ pConvertTo3DLatheItem.reset();
mpImpl.reset();
@@ -2786,9 +2786,9 @@ void Svx3DWin::LBSelectColor( SvxColorListBox* pLb, const Color& rColor )
void Svx3DWin::UpdatePreview()
{
- if(nullptr == pModel)
+ if(!pModel)
{
- pModel = new FmFormModel();
+ pModel.reset(new FmFormModel());
}
// Get Itemset