diff options
-rw-r--r-- | chart2/source/controller/main/ChartController.cxx | 6 | ||||
-rw-r--r-- | chart2/source/inc/LifeTime.hxx | 5 | ||||
-rw-r--r-- | chart2/source/tools/LifeTime.cxx | 8 |
3 files changed, 4 insertions, 15 deletions
diff --git a/chart2/source/controller/main/ChartController.cxx b/chart2/source/controller/main/ChartController.cxx index 79029e6bae09..caf03db40f45 100644 --- a/chart2/source/controller/main/ChartController.cxx +++ b/chart2/source/controller/main/ChartController.cxx @@ -139,8 +139,7 @@ void ChartController::RefCountable::release() ChartController::TheModel::TheModel( const uno::Reference< frame::XModel > & xModel ) : m_xModel( xModel ), m_xCloseable( NULL ), - m_bOwnership( true ), - m_bOwnershipIsWellKnown( false ) + m_bOwnership( true ) { m_xCloseable = uno::Reference< util::XCloseable >( xModel, uno::UNO_QUERY ); @@ -153,7 +152,6 @@ ChartController::TheModel::~TheModel() void ChartController::TheModel::SetOwnership( bool bGetsOwnership ) { m_bOwnership = bGetsOwnership; - m_bOwnershipIsWellKnown = true; } void ChartController::TheModel::addListener( ChartController* pController ) @@ -206,7 +204,6 @@ void ChartController::TheModel::tryTermination() m_xCloseable->close(sal_True); m_bOwnership = false; - m_bOwnershipIsWellKnown = true; } catch( const util::CloseVetoException& ) { @@ -219,7 +216,6 @@ void ChartController::TheModel::tryTermination() #endif m_bOwnership = false; - m_bOwnershipIsWellKnown = true; return; } diff --git a/chart2/source/inc/LifeTime.hxx b/chart2/source/inc/LifeTime.hxx index 4b208585fefd..2465875fbeea 100644 --- a/chart2/source/inc/LifeTime.hxx +++ b/chart2/source/inc/LifeTime.hxx @@ -83,10 +83,6 @@ protected: //each controller might consider him as owner of the model first //at start the model is not considered as owner of itself bool volatile m_bOwnership; - //with a XCloseable::close call and during XCloseListener::queryClosing - //the ownership can be regulated more explicit, - //if so the ownership is considered to be well known - bool volatile m_bOwnershipIsWellKnown; public: OOO_DLLPUBLIC_CHARTTOOLS CloseableLifeTimeManager( ::com::sun::star::util::XCloseable* pCloseable @@ -118,7 +114,6 @@ protected: m_bClosed = false; m_bInTryClose = false; m_bOwnership = false; - m_bOwnershipIsWellKnown = false; m_aEndTryClosingCondition.set(); } }; diff --git a/chart2/source/tools/LifeTime.cxx b/chart2/source/tools/LifeTime.cxx index a0631928f957..63b5acccae9d 100644 --- a/chart2/source/tools/LifeTime.cxx +++ b/chart2/source/tools/LifeTime.cxx @@ -311,14 +311,12 @@ bool CloseableLifeTimeManager::impl_isDisposedOrClosed( bool bAssert ) impl_doClose(); } - void CloseableLifeTimeManager -::impl_setOwnership( bool bDeliverOwnership, bool bMyVeto ) +void CloseableLifeTimeManager::impl_setOwnership( bool bDeliverOwnership, bool bMyVeto ) { m_bOwnership = bDeliverOwnership && bMyVeto; - m_bOwnershipIsWellKnown = true; } - bool CloseableLifeTimeManager -::impl_shouldCloseAtNextChance() + +bool CloseableLifeTimeManager::impl_shouldCloseAtNextChance() { return m_bOwnership; } |