summaryrefslogtreecommitdiff
path: root/chart2/source/model/main/ChartModel.cxx
diff options
context:
space:
mode:
authorFrank Schoenheit [fs] <frank.schoenheit@oracle.com>2010-11-16 08:49:38 +0100
committerFrank Schoenheit [fs] <frank.schoenheit@oracle.com>2010-11-16 08:49:38 +0100
commit4d0ae2eac2ac03475b7496f81e803b9b71b7481f (patch)
treea3dec753cf2a69951829ca75e200648c1b647f88 /chart2/source/model/main/ChartModel.cxx
parent3909360c32b8e018bab468db7aece015c6d1a2b4 (diff)
undoapi: step 2.3 of the migration of css.chart2.XUndoManager to css.document.XUndoManager:
migrate the clients of XDocumentActions to using the new XUndoManager, and completely remove the (X)DocumentActions still some more cleanup needed
Diffstat (limited to 'chart2/source/model/main/ChartModel.cxx')
-rwxr-xr-xchart2/source/model/main/ChartModel.cxx109
1 files changed, 0 insertions, 109 deletions
diff --git a/chart2/source/model/main/ChartModel.cxx b/chart2/source/model/main/ChartModel.cxx
index 6ba450d76f5f..481f968f9488 100755
--- a/chart2/source/model/main/ChartModel.cxx
+++ b/chart2/source/model/main/ChartModel.cxx
@@ -155,7 +155,6 @@ ChartModel::ChartModel( const ChartModel & rOther )
, m_aGraphicObjectVector( rOther.m_aGraphicObjectVector )
, m_xDataProvider( rOther.m_xDataProvider )
, m_xInternalDataProvider( rOther.m_xInternalDataProvider )
- , m_xDocumentActions( NULL )
{
OSL_TRACE( "ChartModel: Copy-CTOR called" );
@@ -557,8 +556,6 @@ void SAL_CALL ChartModel::dispose() throw(uno::RuntimeException)
m_pUndoManager.clear();
// that's important, since the UndoManager implementation delegates its ref counting to ourself.
- m_xDocumentActions.clear();
-
m_aControllers.disposeAndClear( lang::EventObject( static_cast< cppu::OWeakObject * >( this )));
m_xCurrentController.clear();
@@ -1366,112 +1363,6 @@ void SAL_CALL ChartModel::setParent( const Reference< uno::XInterface >& Parent
m_xParent.set( Parent, uno::UNO_QUERY );
}
-bool ChartModel::impl_getDocumentActions_lck()
-{
- if ( !m_xDocumentActions.is() )
- m_xDocumentActions.set( createInstance( CHART_DOCUMENT_ACTIONS_SERVICE_NAME ), uno::UNO_QUERY );
- OSL_POSTCOND( m_xDocumentActions.is(), "ChartModel::impl_getDocumentActions_lck: could not create the legacy DocumentActions service!" );
- return m_xDocumentActions.is();
-}
-
-// ____ XDocumentActions ____
-void SAL_CALL ChartModel::preAction( ) throw (RuntimeException)
-{
- ::osl::MutexGuard aGuard( m_aModelMutex );
- if ( impl_getDocumentActions_lck() )
- m_xDocumentActions->preAction();
-}
-
-void SAL_CALL ChartModel::preActionWithArguments( const Sequence< beans::PropertyValue >& aArguments ) throw (RuntimeException)
-{
- ::osl::MutexGuard aGuard( m_aModelMutex );
- if ( impl_getDocumentActions_lck() )
- m_xDocumentActions->preActionWithArguments( aArguments );
-}
-
-void SAL_CALL ChartModel::postAction( const ::rtl::OUString& aUndoText ) throw (RuntimeException)
-{
- ::osl::MutexGuard aGuard( m_aModelMutex );
- if ( impl_getDocumentActions_lck() )
- m_xDocumentActions->postAction( aUndoText );
-}
-
-void SAL_CALL ChartModel::cancelAction( ) throw (RuntimeException)
-{
- ::osl::MutexGuard aGuard( m_aModelMutex );
- if ( impl_getDocumentActions_lck() )
- m_xDocumentActions->cancelAction();
-}
-
-void SAL_CALL ChartModel::cancelActionWithUndo( ) throw (RuntimeException)
-{
- ::osl::MutexGuard aGuard( m_aModelMutex );
- if ( impl_getDocumentActions_lck() )
- m_xDocumentActions->cancelActionWithUndo();
-}
-
-void SAL_CALL ChartModel::undo( ) throw (RuntimeException)
-{
- ::osl::MutexGuard aGuard( m_aModelMutex );
- if ( impl_getDocumentActions_lck() )
- m_xDocumentActions->undo();
-}
-
-void SAL_CALL ChartModel::redo( ) throw (RuntimeException)
-{
- ::osl::MutexGuard aGuard( m_aModelMutex );
- if ( impl_getDocumentActions_lck() )
- m_xDocumentActions->redo();
-}
-
-::sal_Bool SAL_CALL ChartModel::undoPossible( ) throw (RuntimeException)
-{
- ::osl::MutexGuard aGuard( m_aModelMutex );
- if ( impl_getDocumentActions_lck() )
- return m_xDocumentActions->undoPossible();
- return sal_False;
-}
-
-::sal_Bool SAL_CALL ChartModel::redoPossible( ) throw (RuntimeException)
-{
- ::osl::MutexGuard aGuard( m_aModelMutex );
- if ( impl_getDocumentActions_lck() )
- return m_xDocumentActions->redoPossible();
- return sal_False;
-}
-
-::rtl::OUString SAL_CALL ChartModel::getCurrentUndoString( ) throw (RuntimeException)
-{
- ::osl::MutexGuard aGuard( m_aModelMutex );
- if ( impl_getDocumentActions_lck() )
- return m_xDocumentActions->getCurrentUndoString();
- return ::rtl::OUString();
-}
-
-::rtl::OUString SAL_CALL ChartModel::getCurrentRedoString( ) throw (RuntimeException)
-{
- ::osl::MutexGuard aGuard( m_aModelMutex );
- if ( impl_getDocumentActions_lck() )
- return m_xDocumentActions->getCurrentRedoString();
- return ::rtl::OUString();
-}
-
-Sequence< ::rtl::OUString > SAL_CALL ChartModel::getAllUndoStrings( ) throw (RuntimeException)
-{
- ::osl::MutexGuard aGuard( m_aModelMutex );
- if ( impl_getDocumentActions_lck() )
- return m_xDocumentActions->getAllUndoStrings();
- return Sequence< ::rtl::OUString >();
-}
-
-Sequence< ::rtl::OUString > SAL_CALL ChartModel::getAllRedoStrings( ) throw (RuntimeException)
-{
- ::osl::MutexGuard aGuard( m_aModelMutex );
- if ( impl_getDocumentActions_lck() )
- return m_xDocumentActions->getAllRedoStrings();
- return Sequence< ::rtl::OUString >();
-}
-
// ____ XDataSource ____
uno::Sequence< Reference< chart2::data::XLabeledDataSequence > > SAL_CALL ChartModel::getDataSequences()
throw (uno::RuntimeException)