summaryrefslogtreecommitdiff
path: root/sc/source/ui/undo/undodat.cxx
diff options
context:
space:
mode:
Diffstat (limited to 'sc/source/ui/undo/undodat.cxx')
-rw-r--r--sc/source/ui/undo/undodat.cxx18
1 files changed, 2 insertions, 16 deletions
diff --git a/sc/source/ui/undo/undodat.cxx b/sc/source/ui/undo/undodat.cxx
index b6bc5d614a33..d0a7c809faa8 100644
--- a/sc/source/ui/undo/undodat.cxx
+++ b/sc/source/ui/undo/undodat.cxx
@@ -739,21 +739,14 @@ bool ScUndoSubTotals::CanRepeat(SfxRepeatTarget& /* rTarget */) const
ScUndoSort::ScUndoSort( ScDocShell* pNewDocShell,
SCTAB nNewTab, const ScSortParam& rParam,
- ScDocument* pNewUndoDoc, ScDBCollection* pNewUndoDB,
- const ScRange* pDest ) :
+ ScDocument* pNewUndoDoc, ScDBCollection* pNewUndoDB ) :
ScDBFuncUndo( pNewDocShell, ScRange( rParam.nCol1, rParam.nRow1, nNewTab,
rParam.nCol2, rParam.nRow2, nNewTab ) ),
nTab( nNewTab ),
aSortParam( rParam ),
pUndoDoc( pNewUndoDoc ),
- pUndoDB( pNewUndoDB ),
- bDestArea( false )
+ pUndoDB( pNewUndoDB )
{
- if ( pDest )
- {
- bDestArea = true;
- aDestRange = *pDest;
- }
}
ScUndoSort::~ScUndoSort()
@@ -796,13 +789,6 @@ void ScUndoSort::Undo()
pUndoDoc->CopyToDocument( nStartCol, nStartRow, nSortTab, nEndCol, nEndRow, nSortTab,
IDF_ALL|IDF_NOCAPTIONS, false, &rDoc );
- if (bDestArea)
- {
- // do not delete/copy note captions, they are handled in drawing undo (ScDBFuncUndo::mpDrawUndo)
- rDoc.DeleteAreaTab( aDestRange, IDF_ALL|IDF_NOCAPTIONS );
- pUndoDoc->CopyToDocument( aDestRange, IDF_ALL|IDF_NOCAPTIONS, false, &rDoc );
- }
-
// Row heights always (due to automatic adjustment)
// TODO change to use ScBlockUndo
pUndoDoc->CopyToDocument( 0, nStartRow, nSortTab, MAXCOL, nEndRow, nSortTab,