[Libreoffice-commits] core.git: chart2/source

Kohei Yoshida kohei.yoshida at collabora.com
Mon May 12 16:59:39 PDT 2014


 chart2/source/controller/dialogs/dlg_CreationWizard.cxx |   11 +++++------
 chart2/source/controller/inc/dlg_CreationWizard.hxx     |   11 ++++-------
 2 files changed, 9 insertions(+), 13 deletions(-)

New commits:
commit 36122c27539ae22c3a67fab89ecf1a262074c3b4
Author: Kohei Yoshida <kohei.yoshida at collabora.com>
Date:   Mon May 12 19:54:18 2014 -0400

    Replace auto_ptr with boost::scoped_ptr.
    
    Change-Id: Ibc6d532eff59146d8fbe7dcc7f9155ce6119f474

diff --git a/chart2/source/controller/dialogs/dlg_CreationWizard.cxx b/chart2/source/controller/dialogs/dlg_CreationWizard.cxx
index 6b018be..2a3e219 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 0b9739b..84e74ac 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;


More information about the Libreoffice-commits mailing list