diff options
-rw-r--r-- | sc/source/ui/view/cellsh1.cxx | 12 | ||||
-rw-r--r-- | sw/source/uibase/fldui/fldwrap.cxx | 2 | ||||
-rw-r--r-- | sw/source/uibase/uiview/view2.cxx | 4 | ||||
-rw-r--r-- | vcl/source/window/layout.cxx | 2 |
4 files changed, 10 insertions, 10 deletions
diff --git a/sc/source/ui/view/cellsh1.cxx b/sc/source/ui/view/cellsh1.cxx index 12f1f3184ea3..f661f347a54f 100644 --- a/sc/source/ui/view/cellsh1.cxx +++ b/sc/source/ui/view/cellsh1.cxx @@ -1079,8 +1079,8 @@ void ScCellShell::ExecuteEdit( SfxRequest& rReq ) ScAbstractDialogFactory* pFact = ScAbstractDialogFactory::Create(); OSL_ENSURE(pFact, "ScAbstractFactory create fail!"); - AbstractScDPShowDetailDlg* pDlg = pFact->CreateScDPShowDetailDlg( - pTabViewShell->GetDialogParent(), *pDPObj, nOrientation ); + ScopedVclPtr<AbstractScDPShowDetailDlg> pDlg( pFact->CreateScDPShowDetailDlg( + pTabViewShell->GetDialogParent(), *pDPObj, nOrientation ) ); OSL_ENSURE(pDlg, "Dialog create fail!"); if ( pDlg->Execute() == RET_OK ) { @@ -1120,9 +1120,9 @@ void ScCellShell::ExecuteEdit( SfxRequest& rReq ) ScAbstractDialogFactory* pFact = ScAbstractDialogFactory::Create(); OSL_ENSURE( pFact, "ScAbstractFactory create fail!" ); Date aNullDate( *GetViewData()->GetDocument()->GetFormatTable()->GetNullDate() ); - AbstractScDPDateGroupDlg* pDlg = pFact->CreateScDPDateGroupDlg( + ScopedVclPtr<AbstractScDPDateGroupDlg> pDlg( pFact->CreateScDPDateGroupDlg( pTabViewShell->GetDialogParent(), - aNumInfo, nParts, aNullDate ); + aNumInfo, nParts, aNullDate ) ); OSL_ENSURE( pDlg, "Dialog create fail!" ); if( pDlg->Execute() == RET_OK ) { @@ -1134,8 +1134,8 @@ void ScCellShell::ExecuteEdit( SfxRequest& rReq ) { ScAbstractDialogFactory* pFact = ScAbstractDialogFactory::Create(); OSL_ENSURE( pFact, "ScAbstractFactory create fail!" ); - AbstractScDPNumGroupDlg* pDlg = pFact->CreateScDPNumGroupDlg( - pTabViewShell->GetDialogParent(), aNumInfo ); + ScopedVclPtr<AbstractScDPNumGroupDlg> pDlg( pFact->CreateScDPNumGroupDlg( + pTabViewShell->GetDialogParent(), aNumInfo ) ); OSL_ENSURE( pDlg, "Dialog create fail!" ); if( pDlg->Execute() == RET_OK ) pTabViewShell->NumGroupDataPilot( pDlg->GetGroupInfo() ); diff --git a/sw/source/uibase/fldui/fldwrap.cxx b/sw/source/uibase/fldui/fldwrap.cxx index 153f15add5ac..38b45e577fa5 100644 --- a/sw/source/uibase/fldui/fldwrap.cxx +++ b/sw/source/uibase/fldui/fldwrap.cxx @@ -125,7 +125,7 @@ SwFieldDataOnlyDlgWrapper::SwFieldDataOnlyDlgWrapper( vcl::Window* _pParent, sal SwAbstractDialogFactory* pFact = SwAbstractDialogFactory::Create(); OSL_ENSURE(pFact, "SwAbstractDialogFactory fail!"); - AbstractSwFieldDlg* pDlg = pFact->CreateSwFieldDlg(pB, this, _pParent); + VclPtr<AbstractSwFieldDlg> pDlg = pFact->CreateSwFieldDlg(pB, this, _pParent); OSL_ENSURE(pDlg, "Dialog creation failed!"); pDlgInterface = pDlg; diff --git a/sw/source/uibase/uiview/view2.cxx b/sw/source/uibase/uiview/view2.cxx index 9cd0adc773e5..8865d294597a 100644 --- a/sw/source/uibase/uiview/view2.cxx +++ b/sw/source/uibase/uiview/view2.cxx @@ -1138,7 +1138,7 @@ void SwView::Execute(SfxRequest &rReq) SfxViewFrame* pTmpFrame = GetViewFrame(); SwAbstractDialogFactory* pFact = SwAbstractDialogFactory::Create(); OSL_ENSURE(pFact, "Dialog creation failed!"); - AbstractMailMergeCreateFromDlg* pDlg = pFact->CreateMailMergeCreateFromDlg(&pTmpFrame->GetWindow()); + ScopedVclPtr<AbstractMailMergeCreateFromDlg> pDlg( pFact->CreateMailMergeCreateFromDlg(&pTmpFrame->GetWindow()) ); OSL_ENSURE(pDlg, "Dialog creation failed!"); if(RET_OK == pDlg->Execute()) bUseCurrentDocument = pDlg->IsThisDocument(); @@ -2340,7 +2340,7 @@ void SwView::GenerateFormLetter(bool bUseCurrentDocument) //take an existing data source or create a new one? SwAbstractDialogFactory* pFact = SwAbstractDialogFactory::Create(); OSL_ENSURE(pFact, "Dialog creation failed!"); - AbstractMailMergeFieldConnectionsDlg* pConnectionsDlg = pFact->CreateMailMergeFieldConnectionsDlg(&GetViewFrame()->GetWindow()); + ScopedVclPtr<AbstractMailMergeFieldConnectionsDlg> pConnectionsDlg( pFact->CreateMailMergeFieldConnectionsDlg(&GetViewFrame()->GetWindow()) ); OSL_ENSURE(pConnectionsDlg, "Dialog creation failed!"); if(RET_OK == pConnectionsDlg->Execute()) bCallAddressPilot = !pConnectionsDlg->IsUseExistingConnections(); diff --git a/vcl/source/window/layout.cxx b/vcl/source/window/layout.cxx index 8bed6514a066..872c2357d504 100644 --- a/vcl/source/window/layout.cxx +++ b/vcl/source/window/layout.cxx @@ -308,7 +308,7 @@ void VclContainer::Command(const CommandEvent& rCEvt) { // open screenshot annotation dialog VclAbstractDialogFactory* pFact = VclAbstractDialogFactory::Create(); - AbstractScreenshotAnnotationDlg* pTmp = pFact->CreateScreenshotAnnotationDlg( + VclPtr<AbstractScreenshotAnnotationDlg> pTmp = pFact->CreateScreenshotAnnotationDlg( Application::GetDefDialogParent(), *pParentDialog); ScopedVclPtr<AbstractScreenshotAnnotationDlg> pDialog(pTmp); |