diff options
author | Kohei Yoshida <kohei.yoshida@collabora.com> | 2014-05-12 19:54:18 -0400 |
---|---|---|
committer | Kohei Yoshida <kohei.yoshida@collabora.com> | 2014-05-12 19:59:57 -0400 |
commit | 36122c27539ae22c3a67fab89ecf1a262074c3b4 (patch) | |
tree | 7817448f174284adb262293b394efae0c9320145 /chart2 | |
parent | 1b7aee193f8e99ec3984a93b47c6f506c1e5db2f (diff) |
Replace auto_ptr with boost::scoped_ptr.
Change-Id: Ibc6d532eff59146d8fbe7dcc7f9155ce6119f474
Diffstat (limited to 'chart2')
-rw-r--r-- | chart2/source/controller/dialogs/dlg_CreationWizard.cxx | 11 | ||||
-rw-r--r-- | chart2/source/controller/inc/dlg_CreationWizard.hxx | 11 |
2 files changed, 9 insertions, 13 deletions
diff --git a/chart2/source/controller/dialogs/dlg_CreationWizard.cxx b/chart2/source/controller/dialogs/dlg_CreationWizard.cxx index 6b018be7f68e..2a3e219bac3d 100644 --- a/chart2/source/controller/dialogs/dlg_CreationWizard.cxx +++ b/chart2/source/controller/dialogs/dlg_CreationWizard.cxx @@ -66,7 +66,7 @@ CreationWizard::CreationWizard( Window* pParent, const uno::Reference< frame::XM , m_aTimerTriggeredControllerLock( xChartModel ) , m_bCanTravel( true ) { - m_apDialogModel.reset( new DialogModel( m_xChartModel, m_xCC )); + m_pDialogModel.reset( new DialogModel( m_xChartModel, m_xCC )); // Do not call FreeResource(), because there are no sub-elements defined in // the dialog resource ShowButtonFixedLine( true ); @@ -124,21 +124,20 @@ svt::OWizardPage* CreationWizard::createPage(WizardState nState) ChartTypeTabPage* pChartTypeTabPage = new ChartTypeTabPage(this,m_xChartModel,m_xCC,bDoLiveUpdate); pRet = pChartTypeTabPage; m_pTemplateProvider = pChartTypeTabPage; - if( m_pTemplateProvider && - m_apDialogModel.get() ) - m_apDialogModel->setTemplate( m_pTemplateProvider->getCurrentTemplate()); + if (m_pTemplateProvider && m_pDialogModel) + m_pDialogModel->setTemplate( m_pTemplateProvider->getCurrentTemplate()); } break; case STATE_SIMPLE_RANGE: { m_aTimerTriggeredControllerLock.startTimer(); - pRet = new RangeChooserTabPage(this,*(m_apDialogModel.get()),m_pTemplateProvider,this); + pRet = new RangeChooserTabPage(this, *m_pDialogModel, m_pTemplateProvider, this); } break; case STATE_DATA_SERIES: { m_aTimerTriggeredControllerLock.startTimer(); - pRet = new DataSourceTabPage(this,*(m_apDialogModel.get()),m_pTemplateProvider,this); + pRet = new DataSourceTabPage(this, *m_pDialogModel, m_pTemplateProvider, this); } break; case STATE_OBJECTS: diff --git a/chart2/source/controller/inc/dlg_CreationWizard.hxx b/chart2/source/controller/inc/dlg_CreationWizard.hxx index 0b9739b4940d..84e74acfe1a0 100644 --- a/chart2/source/controller/inc/dlg_CreationWizard.hxx +++ b/chart2/source/controller/inc/dlg_CreationWizard.hxx @@ -28,7 +28,8 @@ #include <svtools/roadmapwizard.hxx> #include <com/sun/star/uno/XComponentContext.hpp> -#include <memory> +#include <boost/noncopyable.hpp> +#include <boost/scoped_ptr.hpp> namespace chart { @@ -38,9 +39,7 @@ class DataSourceTabPage; class ChartTypeTemplateProvider; class DialogModel; -class CreationWizard : public - svt::RoadmapWizard - , public TabPageNotifiable +class CreationWizard : public svt::RoadmapWizard, public TabPageNotifiable, private boost::noncopyable { public: CreationWizard( Window* pParent, @@ -77,9 +76,7 @@ private: bool m_bIsClosable; sal_Int32 m_nOnePageOnlyIndex;//if nOnePageOnlyIndex is an index of an exsisting page starting with 0, then only this page is displayed without next/previous and roadmap ChartTypeTemplateProvider* m_pTemplateProvider; - SAL_WNODEPRECATED_DECLARATIONS_PUSH - ::std::auto_ptr< DialogModel > m_apDialogModel; - SAL_WNODEPRECATED_DECLARATIONS_POP + boost::scoped_ptr<DialogModel> m_pDialogModel; WizardState m_nFirstState; WizardState m_nLastState; |