diff options
author | Noel Grandin <noel@peralex.com> | 2015-10-06 11:42:41 +0200 |
---|---|---|
committer | Noel Grandin <noel@peralex.com> | 2015-10-07 08:27:25 +0200 |
commit | 2b57de8bb0064be828265bf08805b1bc345e62bf (patch) | |
tree | 3d00a7b49de50ba04e60c73d51d9ed46c257270d /chart2/source | |
parent | 6d7353deb891b6cb49e98fec5de2ad0f1bc86c24 (diff) |
remove another custom refcounting base class
Change-Id: Icd8a8d79da0ada68e9ee869c3c2a7b93db5b2733
Diffstat (limited to 'chart2/source')
-rw-r--r-- | chart2/source/controller/inc/ChartController.hxx | 12 | ||||
-rw-r--r-- | chart2/source/controller/main/ChartController.cxx | 18 |
2 files changed, 1 insertions, 29 deletions
diff --git a/chart2/source/controller/inc/ChartController.hxx b/chart2/source/controller/inc/ChartController.hxx index cdb23aa9133c..59a374100fb6 100644 --- a/chart2/source/controller/inc/ChartController.hxx +++ b/chart2/source/controller/inc/ChartController.hxx @@ -447,17 +447,7 @@ private: private: class TheModelRef; friend class ChartController::TheModelRef; - class RefCountable - { - public: - RefCountable(); - virtual ~RefCountable(); - void acquire(); - void release(); - private: - sal_Int32 m_nRefCount; - }; - class TheModel : public RefCountable + class TheModel : public salhelper::SimpleReferenceObject { public: explicit TheModel( const ::com::sun::star::uno::Reference< diff --git a/chart2/source/controller/main/ChartController.cxx b/chart2/source/controller/main/ChartController.cxx index 045837e7ccfd..8b1654393023 100644 --- a/chart2/source/controller/main/ChartController.cxx +++ b/chart2/source/controller/main/ChartController.cxx @@ -131,24 +131,6 @@ ChartController::~ChartController() stopDoubleClickWaiting(); } -ChartController::RefCountable::RefCountable() : m_nRefCount(0) -{ -} - -ChartController::RefCountable::~RefCountable() -{ -} -void ChartController::RefCountable::acquire() -{ - m_nRefCount++; -} -void ChartController::RefCountable::release() -{ - m_nRefCount--; - if(!m_nRefCount) - delete this; -} - ChartController::TheModel::TheModel( const uno::Reference< frame::XModel > & xModel ) : m_xModel( xModel ), m_xCloseable( NULL ), |