diff options
author | Caolán McNamara <caolanm@redhat.com> | 2016-10-27 20:55:49 +0100 |
---|---|---|
committer | Caolán McNamara <caolanm@redhat.com> | 2016-10-28 09:08:50 +0000 |
commit | 117fc49c979d65e5479635eab3ce10d74d076679 (patch) | |
tree | 9dbfee8cc04b2bf6f5eab0522ed9270de0d14a5c /chart2/source | |
parent | 8f0f5e0c709d01555a4069f8665889924ed181c7 (diff) |
ScopedVclPtr vs std::unique_ptr for VclAbstractDialog derivatives
Change-Id: I5e43312b6f42ce0c63946f366eaf1e6dcb9629b2
Reviewed-on: https://gerrit.libreoffice.org/30344
Reviewed-by: Caolán McNamara <caolanm@redhat.com>
Tested-by: Caolán McNamara <caolanm@redhat.com>
Diffstat (limited to 'chart2/source')
3 files changed, 9 insertions, 9 deletions
diff --git a/chart2/source/controller/main/ChartController_Position.cxx b/chart2/source/controller/main/ChartController_Position.cxx index 690cedce16e3..b47034867919 100644 --- a/chart2/source/controller/main/ChartController_Position.cxx +++ b/chart2/source/controller/main/ChartController_Position.cxx @@ -140,7 +140,7 @@ void ChartController::executeDispatch_PositionAndSize() SolarMutexGuard aGuard; SvxAbstractDialogFactory * pFact = SvxAbstractDialogFactory::Create(); OSL_ENSURE( pFact, "No dialog factory" ); - std::unique_ptr<SfxAbstractTabDialog> pDlg(pFact->CreateSchTransformTabDialog( + ScopedVclPtr<SfxAbstractTabDialog> pDlg(pFact->CreateSchTransformTabDialog( m_pChartWindow, &aItemSet, pSdrView, bResizePossible )); OSL_ENSURE( pDlg, "Couldn't create SchTransformTabDialog" ); diff --git a/chart2/source/controller/main/ChartController_TextEdit.cxx b/chart2/source/controller/main/ChartController_TextEdit.cxx index 37b57ddeecc9..49dd8a81e3ca 100644 --- a/chart2/source/controller/main/ChartController_TextEdit.cxx +++ b/chart2/source/controller/main/ChartController_TextEdit.cxx @@ -169,7 +169,7 @@ void ChartController::executeDispatch_InsertSpecialCharacter() vcl::Font aCurFont = m_pDrawViewWrapper->getOutliner()->GetRefDevice()->GetFont(); aSet.Put( SvxFontItem( aCurFont.GetFamilyType(), aCurFont.GetFamilyName(), aCurFont.GetStyleName(), aCurFont.GetPitch(), aCurFont.GetCharSet(), SID_ATTR_CHAR_FONT ) ); - std::unique_ptr<SfxAbstractDialog> pDlg(pFact->CreateSfxDialog( m_pChartWindow, aSet, getFrame(), RID_SVXDLG_CHARMAP )); + ScopedVclPtr<SfxAbstractDialog> pDlg(pFact->CreateSfxDialog( m_pChartWindow, aSet, getFrame(), RID_SVXDLG_CHARMAP )); OSL_ENSURE( pDlg, "Couldn't create SvxCharacterMap dialog" ); if( pDlg->Execute() == RET_OK ) { diff --git a/chart2/source/controller/main/ShapeController.cxx b/chart2/source/controller/main/ShapeController.cxx index de1d92bddbe7..8c68892a498e 100644 --- a/chart2/source/controller/main/ShapeController.cxx +++ b/chart2/source/controller/main/ShapeController.cxx @@ -260,7 +260,7 @@ void ShapeController::executeDispatch_FormatLine() SvxAbstractDialogFactory* pFact = SvxAbstractDialogFactory::Create(); if ( pFact ) { - std::unique_ptr< SfxAbstractTabDialog > pDlg( + ScopedVclPtr< SfxAbstractTabDialog > pDlg( pFact->CreateSvxLineTabDialog( pParent, &aAttr, &pDrawModelWrapper->getSdrModel(), pSelectedObj, bHasMarked ) ); if ( pDlg->Execute() == RET_OK ) @@ -299,7 +299,7 @@ void ShapeController::executeDispatch_FormatArea() SvxAbstractDialogFactory* pFact = SvxAbstractDialogFactory::Create(); if ( pFact ) { - std::unique_ptr< AbstractSvxAreaTabDialog > pDlg( + ScopedVclPtr< AbstractSvxAreaTabDialog > pDlg( pFact->CreateSvxAreaTabDialog( pParent, &aAttr, &pDrawModelWrapper->getSdrModel(), true ) ); if ( pDlg.get() ) { @@ -341,7 +341,7 @@ void ShapeController::executeDispatch_TextAttributes() SvxAbstractDialogFactory* pFact = SvxAbstractDialogFactory::Create(); if ( pFact ) { - std::unique_ptr< SfxAbstractTabDialog > pDlg( + ScopedVclPtr< SfxAbstractTabDialog > pDlg( pFact->CreateTextTabDialog( pParent, &aAttr, pDrawViewWrapper ) ); if ( pDlg.get() && ( pDlg->Execute() == RET_OK ) ) { @@ -380,7 +380,7 @@ void ShapeController::executeDispatch_TransformDialog() SvxAbstractDialogFactory* pFact = SvxAbstractDialogFactory::Create(); if ( pFact ) { - std::unique_ptr< SfxAbstractTabDialog > pDlg( + ScopedVclPtr< SfxAbstractTabDialog > pDlg( pFact->CreateCaptionDialog( pParent, pDrawViewWrapper ) ); if ( pDlg.get() ) { @@ -404,7 +404,7 @@ void ShapeController::executeDispatch_TransformDialog() SvxAbstractDialogFactory* pFact = SvxAbstractDialogFactory::Create(); if ( pFact ) { - std::unique_ptr< SfxAbstractTabDialog > pDlg( + ScopedVclPtr< SfxAbstractTabDialog > pDlg( pFact->CreateSvxTransformTabDialog( pParent, &aGeoAttr, pDrawViewWrapper ) ); if ( pDlg.get() && ( pDlg->Execute() == RET_OK ) ) { @@ -433,7 +433,7 @@ void ShapeController::executeDispatch_ObjectTitleDescription() SvxAbstractDialogFactory* pFact = SvxAbstractDialogFactory::Create(); if ( pFact ) { - std::unique_ptr< AbstractSvxObjectTitleDescDialog > pDlg( + ScopedVclPtr< AbstractSvxObjectTitleDescDialog > pDlg( pFact->CreateSvxObjectTitleDescDialog( aTitle, aDescription ) ); if ( pDlg.get() && ( pDlg->Execute() == RET_OK ) ) { @@ -463,7 +463,7 @@ void ShapeController::executeDispatch_RenameObject() SvxAbstractDialogFactory* pFact = SvxAbstractDialogFactory::Create(); if ( pFact ) { - std::unique_ptr< AbstractSvxObjectNameDialog > pDlg( + ScopedVclPtr< AbstractSvxObjectNameDialog > pDlg( pFact->CreateSvxObjectNameDialog( aName ) ); pDlg->SetCheckNameHdl( LINK( this, ShapeController, CheckNameHdl ) ); if ( pDlg.get() && ( pDlg->Execute() == RET_OK ) ) |