summaryrefslogtreecommitdiff
path: root/dbaccess
diff options
context:
space:
mode:
authorNoel Grandin <noel.grandin@collabora.co.uk>2018-05-08 12:58:00 +0200
committerNoel Grandin <noel.grandin@collabora.co.uk>2018-05-14 11:10:22 +0200
commit0f53efefe14285101ee95a2f8a202b30f7089ea9 (patch)
treee2c75203c2647246a97d8f4414756586838ee030 /dbaccess
parenta245e5c60fac58889738a9705225c6378b35eef4 (diff)
loplugin:useuniqueptr in SaveDBDocPage
Change-Id: I750e6de1cce5355281336343b1ec03596113e311 Reviewed-on: https://gerrit.libreoffice.org/54170 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'dbaccess')
-rw-r--r--dbaccess/source/ext/macromigration/macromigrationpages.cxx6
-rw-r--r--dbaccess/source/ext/macromigration/macromigrationpages.hxx2
2 files changed, 4 insertions, 4 deletions
diff --git a/dbaccess/source/ext/macromigration/macromigrationpages.cxx b/dbaccess/source/ext/macromigration/macromigrationpages.cxx
index 09fd1f69b495..d4b84e5982e6 100644
--- a/dbaccess/source/ext/macromigration/macromigrationpages.cxx
+++ b/dbaccess/source/ext/macromigration/macromigrationpages.cxx
@@ -79,8 +79,8 @@ namespace dbmm
get(m_pStartMigration, "startmigrate");
get(m_pBrowseSaveAsLocation, "browse");
get(m_pSaveAsLocation, "location");
- m_pLocationController = new svx::DatabaseLocationInputController(
- _rParentDialog.getComponentContext(), *m_pSaveAsLocation, *m_pBrowseSaveAsLocation);
+ m_pLocationController.reset( new svx::DatabaseLocationInputController(
+ _rParentDialog.getComponentContext(), *m_pSaveAsLocation, *m_pBrowseSaveAsLocation) );
m_pSaveAsLocation->SetModifyHdl( LINK( this, SaveDBDocPage, OnLocationModified ) );
m_pSaveAsLocation->SetDropDownLineCount( 20 );
@@ -95,7 +95,7 @@ namespace dbmm
void SaveDBDocPage::dispose()
{
- delete m_pLocationController;
+ m_pLocationController.reset();
m_pSaveAsLocation.clear();
m_pBrowseSaveAsLocation.clear();
m_pStartMigration.clear();
diff --git a/dbaccess/source/ext/macromigration/macromigrationpages.hxx b/dbaccess/source/ext/macromigration/macromigrationpages.hxx
index 6bba4ef64a27..8c28cfd3076d 100644
--- a/dbaccess/source/ext/macromigration/macromigrationpages.hxx
+++ b/dbaccess/source/ext/macromigration/macromigrationpages.hxx
@@ -83,7 +83,7 @@ namespace dbmm
VclPtr< ::svt::OFileURLControl> m_pSaveAsLocation;
VclPtr<PushButton> m_pBrowseSaveAsLocation;
VclPtr<FixedText> m_pStartMigration;
- svx::DatabaseLocationInputController* m_pLocationController;
+ std::unique_ptr<svx::DatabaseLocationInputController> m_pLocationController;
// IWizardPageController overridables
virtual void initializePage() override;