summaryrefslogtreecommitdiffstats
path: root/sw/source/core/edit/eddel.cxx
diff options
context:
space:
mode:
Diffstat (limited to 'sw/source/core/edit/eddel.cxx')
-rw-r--r--sw/source/core/edit/eddel.cxx8
1 files changed, 5 insertions, 3 deletions
diff --git a/sw/source/core/edit/eddel.cxx b/sw/source/core/edit/eddel.cxx
index 9eb51da617..b8d6b0e395 100644
--- a/sw/source/core/edit/eddel.cxx
+++ b/sw/source/core/edit/eddel.cxx
@@ -33,7 +33,8 @@
#include <strings.hrc>
#include <vector>
-void SwEditShell::DeleteSel(SwPaM& rPam, bool const isArtificialSelection, bool *const pUndo)
+void SwEditShell::DeleteSel(SwPaM& rPam, bool const isArtificialSelection, bool goLeft,
+ bool* const pUndo)
{
auto const oSelectAll(StartsWith_() != SwCursorShell::StartsWith::None
? ExtendedSelectedAll()
@@ -127,11 +128,12 @@ void SwEditShell::DeleteSel(SwPaM& rPam, bool const isArtificialSelection, bool
}
}
+ rPam.Normalize(goLeft); // change tracking case: will make sure to end up in the correct point
// Selection is not needed anymore
rPam.DeleteMark();
}
-bool SwEditShell::Delete(bool const isArtificialSelection)
+bool SwEditShell::Delete(bool const isArtificialSelection, bool goLeft)
{
CurrShell aCurr( this );
bool bRet = false;
@@ -159,7 +161,7 @@ bool SwEditShell::Delete(bool const isArtificialSelection)
for(SwPaM& rPaM : GetCursor()->GetRingContainer())
{
- DeleteSel(rPaM, isArtificialSelection, &bUndo);
+ DeleteSel(rPaM, isArtificialSelection, goLeft, &bUndo);
}
// If undo container then close here