summaryrefslogtreecommitdiff
path: root/sw/source/core/edit/eddel.cxx
diff options
context:
space:
mode:
authorMiklos Vajna <vmiklos@collabora.co.uk>2014-03-12 17:28:10 +0100
committerMiklos Vajna <vmiklos@collabora.co.uk>2014-03-12 18:11:40 +0100
commitf9b62506b22c3eb885ffd5a4ec8025c33df7b2d4 (patch)
tree421f580b0f5667bf1c071602cf7303ac78bc4b43 /sw/source/core/edit/eddel.cxx
parent9cfa665706cbced0fa71c43bb9425f28a0145f67 (diff)
fdo#75110 SwEditShell::DeleteSel fix start of selection when bSelAll == true
Change-Id: I3e8ce585b29619061b18ab1ab8f0cf6c7d421074
Diffstat (limited to 'sw/source/core/edit/eddel.cxx')
-rw-r--r--sw/source/core/edit/eddel.cxx9
1 files changed, 7 insertions, 2 deletions
diff --git a/sw/source/core/edit/eddel.cxx b/sw/source/core/edit/eddel.cxx
index 3f5fe7cf7a13..c751a36c6fbc 100644
--- a/sw/source/core/edit/eddel.cxx
+++ b/sw/source/core/edit/eddel.cxx
@@ -89,9 +89,14 @@ void SwEditShell::DeleteSel( SwPaM& rPam, sal_Bool* pUndo )
}
else
{
+ SwPaM aPam(rPam);
+ if (bSelectAll)
+ // Selection starts at the first para of the first cell, but we
+ // want to delete the table node before the first cell as well.
+ aPam.Start()->nNode = aPam.Start()->nNode.GetNode().FindTableNode()->GetIndex();
// delete everything
- GetDoc()->DeleteAndJoin( rPam );
- SaveTblBoxCntnt( rPam.GetPoint() );
+ GetDoc()->DeleteAndJoin( aPam );
+ SaveTblBoxCntnt( aPam.GetPoint() );
}
// Selection is not needed anymore