summaryrefslogtreecommitdiff
path: root/svl/source/undo
diff options
context:
space:
mode:
authorNoel Grandin <noel.grandin@collabora.co.uk>2018-07-12 09:42:07 +0200
committerNoel Grandin <noel.grandin@collabora.co.uk>2018-07-13 08:39:15 +0200
commit2d71dd52b6d91660cda6cb8f9457463439f56e20 (patch)
treef894d34e604eee2db24978c85ba67b9da0a4d573 /svl/source/undo
parentddef60b9c26b1d2990c6c49dbbda73e7831f21fb (diff)
merge IUndoManager into SfxUndoManager
SfxUndoManager is the only implementation of the IUnderManager "interface", and it lives in the same header. Plus this way we can get rid of some covariant parameters, which will make using std::unique_ptr easier. Change-Id: I6661b9876b18da830bead78794d237886cd3c5c9 Reviewed-on: https://gerrit.libreoffice.org/57317 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'svl/source/undo')
-rw-r--r--svl/source/undo/undo.cxx10
1 files changed, 5 insertions, 5 deletions
diff --git a/svl/source/undo/undo.cxx b/svl/source/undo/undo.cxx
index 81ac12bca7c3..09b088f27339 100644
--- a/svl/source/undo/undo.cxx
+++ b/svl/source/undo/undo.cxx
@@ -586,7 +586,7 @@ void SfxUndoManager::ImplClearUndo( UndoManagerGuard& i_guard )
void SfxUndoManager::ImplClearRedo( UndoManagerGuard& i_guard, bool const i_currentLevel )
{
- SfxUndoArray* pUndoArray = ( i_currentLevel == IUndoManager::CurrentLevel ) ? m_xData->pActUndoArray : m_xData->pUndoArray.get();
+ SfxUndoArray* pUndoArray = ( i_currentLevel == SfxUndoManager::CurrentLevel ) ? m_xData->pActUndoArray : m_xData->pUndoArray.get();
// clearance
while ( pUndoArray->aUndoActions.size() > pUndoArray->nCurUndoAction )
@@ -599,7 +599,7 @@ void SfxUndoManager::ImplClearRedo( UndoManagerGuard& i_guard, bool const i_curr
ImplCheckEmptyActions();
// notification - only if the top level's stack was cleared
- if ( i_currentLevel == IUndoManager::TopLevel )
+ if ( i_currentLevel == SfxUndoManager::TopLevel )
i_guard.scheduleNotification( &SfxUndoListener::clearedRedo );
}
@@ -627,7 +627,7 @@ bool SfxUndoManager::ImplAddUndoAction_NoNotify( SfxUndoAction *pAction, bool bT
// clear redo stack, if requested
if ( bClearRedo && ( ImplGetRedoActionCount_Lock() > 0 ) )
- ImplClearRedo( i_guard, IUndoManager::CurrentLevel );
+ ImplClearRedo( i_guard, SfxUndoManager::CurrentLevel );
// respect max number
if( m_xData->pActUndoArray == m_xData->pUndoArray.get() )
@@ -900,7 +900,7 @@ bool SfxUndoManager::ImplRedo( SfxUndoContext* i_contextOrNull )
{
// the Undo action is still there ...
// assume the error is a permanent failure, and clear the Undo stack
- ImplClearRedo( aGuard, IUndoManager::CurrentLevel );
+ ImplClearRedo( aGuard, SfxUndoManager::CurrentLevel );
throw;
}
++nCurAction;
@@ -1098,7 +1098,7 @@ size_t SfxUndoManager::ImplLeaveListAction( const bool i_merge, UndoManagerGuard
// now that it is finally clear the list action is non-trivial, and does participate in the Undo stack, clear
// the redo stack
- ImplClearRedo( i_guard, IUndoManager::CurrentLevel );
+ ImplClearRedo( i_guard, SfxUndoManager::CurrentLevel );
SfxUndoAction* pCurrentAction= m_xData->pActUndoArray->aUndoActions[ m_xData->pActUndoArray->nCurUndoAction-1 ].pAction;
SfxListUndoAction* pListAction = dynamic_cast< SfxListUndoAction * >( pCurrentAction );