diff options
author | Noel Grandin <noel.grandin@collabora.co.uk> | 2017-12-13 15:47:02 +0200 |
---|---|---|
committer | Noel Grandin <noel.grandin@collabora.co.uk> | 2017-12-13 20:08:35 +0100 |
commit | 78a6ce17f06fbe13b806fd563e85a4fe60d3bcfc (patch) | |
tree | 25e6d39e9f4d9bc3ffd703f752a35128f70de7b7 /toolkit | |
parent | 3f7fbae1bc38d528080552a715af187285f47028 (diff) |
DELETEZ->std::unique_ptr in toolkit,unotools
Change-Id: I2263e233ae03575e53ab4e7894a7507423afd32e
Reviewed-on: https://gerrit.libreoffice.org/46397
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'toolkit')
-rw-r--r-- | toolkit/source/controls/unocontrol.cxx | 1 | ||||
-rw-r--r-- | toolkit/source/controls/unocontrolcontainer.cxx | 8 |
2 files changed, 3 insertions, 6 deletions
diff --git a/toolkit/source/controls/unocontrol.cxx b/toolkit/source/controls/unocontrol.cxx index f07ff4d64251..6c8435791883 100644 --- a/toolkit/source/controls/unocontrol.cxx +++ b/toolkit/source/controls/unocontrol.cxx @@ -150,7 +150,6 @@ UnoControl::UnoControl() : UnoControl::~UnoControl() { - DELETEZ( mpData ); } OUString UnoControl::GetComponentServiceName() diff --git a/toolkit/source/controls/unocontrolcontainer.cxx b/toolkit/source/controls/unocontrolcontainer.cxx index 0a992812f7d8..5b533dddb22a 100644 --- a/toolkit/source/controls/unocontrolcontainer.cxx +++ b/toolkit/source/controls/unocontrolcontainer.cxx @@ -381,7 +381,7 @@ UnoControlContainer::UnoControlContainer() :UnoControlContainer_Base() ,maCListeners( *this ) { - mpControls = new UnoControlHolderList; + mpControls.reset(new UnoControlHolderList); } UnoControlContainer::UnoControlContainer(const uno::Reference< awt::XWindowPeer >& xP ) @@ -390,12 +390,11 @@ UnoControlContainer::UnoControlContainer(const uno::Reference< awt::XWindowPeer { setPeer( xP ); mbDisposePeer = false; - mpControls = new UnoControlHolderList; + mpControls.reset(new UnoControlHolderList); } UnoControlContainer::~UnoControlContainer() { - DELETEZ( mpControls ); } void UnoControlContainer::ImplActivateTabControllers() @@ -433,8 +432,7 @@ void UnoControlContainer::dispose( ) // Delete all structures - DELETEZ( mpControls ); - mpControls = new UnoControlHolderList; + mpControls.reset(new UnoControlHolderList); UnoControlBase::dispose(); } |