summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMarkus Mohrhard <markus.mohrhard@googlemail.com>2013-09-29 18:44:32 +0200
committerMarkus Mohrhard <markus.mohrhard@googlemail.com>2013-09-29 20:26:06 +0200
commit140e5eabbfa6f91dc34d2d8181e0ee0508a5a271 (patch)
tree7889fcbce637a773c04c65ed6fc9950d9d30bee5
parentd3affcac9a74065d8cf566a5288447856b84d59b (diff)
replace more auto_ptr with scoped_ptr
Change-Id: Ia96fcc857e028c7c14186b9560153e7580e6b4fb
-rw-r--r--chart2/source/controller/main/ElementSelector.cxx2
-rw-r--r--chart2/source/controller/main/ElementSelector.hxx4
-rw-r--r--chart2/source/model/main/ChartModel.hxx5
-rw-r--r--chart2/source/model/main/ChartModel_Persistence.cxx2
-rw-r--r--chart2/source/model/main/DataPoint.hxx3
-rw-r--r--chart2/source/view/axes/VPolarRadiusAxis.cxx2
-rw-r--r--chart2/source/view/axes/VPolarRadiusAxis.hxx5
-rw-r--r--chart2/source/view/inc/VSeriesPlotter.hxx2
8 files changed, 10 insertions, 15 deletions
diff --git a/chart2/source/controller/main/ElementSelector.cxx b/chart2/source/controller/main/ElementSelector.cxx
index f892f0b497b0..55d3904dc8a8 100644
--- a/chart2/source/controller/main/ElementSelector.cxx
+++ b/chart2/source/controller/main/ElementSelector.cxx
@@ -304,7 +304,7 @@ uno::Reference< awt::XWindow > SAL_CALL ElementSelectorToolbarController::create
Window* pParent = VCLUnoHelper::GetWindow( xParent );
if( pParent )
{
- m_apSelectorListBox = ::std::auto_ptr< SelectorListBox >( new SelectorListBox( pParent, WB_DROPDOWN|WB_AUTOHSCROLL|WB_BORDER ) );
+ m_apSelectorListBox.reset( new SelectorListBox( pParent, WB_DROPDOWN|WB_AUTOHSCROLL|WB_BORDER ) );
::Size aLogicalSize( 95, 160 );
::Size aPixelSize = m_apSelectorListBox->LogicToPixel( aLogicalSize, MAP_APPFONT );
m_apSelectorListBox->SetSizePixel( aPixelSize );
diff --git a/chart2/source/controller/main/ElementSelector.hxx b/chart2/source/controller/main/ElementSelector.hxx
index e5db87e4d3d5..ed4714da39dc 100644
--- a/chart2/source/controller/main/ElementSelector.hxx
+++ b/chart2/source/controller/main/ElementSelector.hxx
@@ -28,7 +28,7 @@
#include <vcl/lstbox.hxx>
#include <cppuhelper/weakref.hxx>
-#include <memory>
+#include <boost/scoped_ptr.hpp>
namespace chart
{
@@ -100,7 +100,7 @@ private:
private:
::com::sun::star::uno::Reference< ::com::sun::star::uno::XComponentContext> m_xCC;
- ::std::auto_ptr< SelectorListBox > m_apSelectorListBox;
+ boost::scoped_ptr< SelectorListBox > m_apSelectorListBox;
};
} //namespace chart
diff --git a/chart2/source/model/main/ChartModel.hxx b/chart2/source/model/main/ChartModel.hxx
index ee36ddde856d..9752c3bbf276 100644
--- a/chart2/source/model/main/ChartModel.hxx
+++ b/chart2/source/model/main/ChartModel.hxx
@@ -66,8 +66,7 @@
#include <cppuhelper/interfacecontainer.hxx>
#include <svtools/grfmgr.hxx>
-// for auto_ptr
-#include <memory>
+#include <boost/scoped_ptr.hpp>
class SvNumberFormatter;
@@ -149,7 +148,7 @@ private:
m_xOwnNumberFormatsSupplier;
::com::sun::star::uno::Reference< com::sun::star::util::XNumberFormatsSupplier >
m_xNumberFormatsSupplier;
- std::auto_ptr< SvNumberFormatter > m_apSvNumberFormatter; // #i113784# avoid memory leak
+ boost::scoped_ptr< SvNumberFormatter > m_apSvNumberFormatter; // #i113784# avoid memory leak
::com::sun::star::uno::Reference< ::com::sun::star::chart2::XChartTypeManager >
m_xChartTypeManager;
diff --git a/chart2/source/model/main/ChartModel_Persistence.cxx b/chart2/source/model/main/ChartModel_Persistence.cxx
index b8e37ef1c34e..eebf278eeb2e 100644
--- a/chart2/source/model/main/ChartModel_Persistence.cxx
+++ b/chart2/source/model/main/ChartModel_Persistence.cxx
@@ -623,7 +623,7 @@ void ChartModel::impl_loadGraphics(
if( xElementStream.is() )
{
- std::auto_ptr< SvStream > apIStm(
+ boost::scoped_ptr< SvStream > apIStm(
::utl::UcbStreamHelper::CreateStream(
xElementStream, true ) );
diff --git a/chart2/source/model/main/DataPoint.hxx b/chart2/source/model/main/DataPoint.hxx
index cbe7a9876588..b95a9fafac60 100644
--- a/chart2/source/model/main/DataPoint.hxx
+++ b/chart2/source/model/main/DataPoint.hxx
@@ -32,9 +32,6 @@
#include "ModifyListenerHelper.hxx"
#include "ServiceMacros.hxx"
-//for auto_ptr
-#include <memory>
-
namespace chart
{
diff --git a/chart2/source/view/axes/VPolarRadiusAxis.cxx b/chart2/source/view/axes/VPolarRadiusAxis.cxx
index 0a2133ce52cf..4b6d8e2ca832 100644
--- a/chart2/source/view/axes/VPolarRadiusAxis.cxx
+++ b/chart2/source/view/axes/VPolarRadiusAxis.cxx
@@ -41,7 +41,7 @@ VPolarRadiusAxis::VPolarRadiusAxis( const AxisProperties& rAxisProperties
m_aAxisProperties.m_aLabelAlignment=LABEL_ALIGN_RIGHT;
m_aAxisProperties.init();
- m_apAxisWithLabels = std::auto_ptr<VCartesianAxis>( new VCartesianAxis(
+ m_apAxisWithLabels.reset( new VCartesianAxis(
m_aAxisProperties,xNumberFormatsSupplier,1/*nDimensionIndex*/,nDimensionCount
,new PolarPlottingPositionHelper() ) );
}
diff --git a/chart2/source/view/axes/VPolarRadiusAxis.hxx b/chart2/source/view/axes/VPolarRadiusAxis.hxx
index 7d16ffba9f2a..126817b37790 100644
--- a/chart2/source/view/axes/VPolarRadiusAxis.hxx
+++ b/chart2/source/view/axes/VPolarRadiusAxis.hxx
@@ -20,8 +20,7 @@
#define _CHART2_VPOLARRADIUSAXIS_HXX
#include "VPolarAxis.hxx"
-
-#include <memory>
+#include <boost/scoped_ptr.hpp>
namespace chart
{
@@ -74,7 +73,7 @@ protected: //methods
virtual bool prepareShapeCreation();
private: //member
- std::auto_ptr<VCartesianAxis> m_apAxisWithLabels;
+ boost::scoped_ptr<VCartesianAxis> m_apAxisWithLabels;
};
} //namespace chart
diff --git a/chart2/source/view/inc/VSeriesPlotter.hxx b/chart2/source/view/inc/VSeriesPlotter.hxx
index 970bc1b9823e..33dc8e9bb545 100644
--- a/chart2/source/view/inc/VSeriesPlotter.hxx
+++ b/chart2/source/view/inc/VSeriesPlotter.hxx
@@ -398,7 +398,7 @@ protected:
long m_nTimeResolution;
Date m_aNullDate;
- ::std::auto_ptr< NumberFormatterWrapper > m_apNumberFormatterWrapper;
+ boost::scoped_ptr< NumberFormatterWrapper > m_apNumberFormatterWrapper;
AxesNumberFormats m_aAxesNumberFormats;//direct numberformats on axes, if empty ask the data series instead
::com::sun::star::uno::Reference<