diff options
author | Michael Stahl <Michael.Stahl@cib.de> | 2020-06-15 13:11:29 +0200 |
---|---|---|
committer | Michael Meeks <michael.meeks@collabora.com> | 2020-06-19 10:26:49 +0100 |
commit | 51703be4e72eaaeaa3765f125df127a111895cc5 (patch) | |
tree | f88319a9ddb5b54a7690e3e5fc688b694eb8ec9e /sw/inc/undobj.hxx | |
parent | 943e072fdfd0f54e6408662caab5837a28e2568d (diff) |
tdf#133957 sw: SelectAll should select fly in empty section
Ctrl+A should select everything in the section; if the section is empty,
there's no text to select, and then the shell will cancel the selection
because SwCursorShell::HasSelection() returns false - so check if
there are flys anchored there, which fixes the Copy.
To fix Delete, a few more checks for empty selection need to be changed.
Change-Id: If54160bdca976ad5f153b89cf8492f4da1e774b7
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/96324
Tested-by: Jenkins
Reviewed-by: Michael Stahl <michael.stahl@cib.de>
(cherry picked from commit 2d89b9929e85bede4c72684a12e7508751875f0e)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/96368
Reviewed-by: Thorsten Behrens <Thorsten.Behrens@CIB.de>
Diffstat (limited to 'sw/inc/undobj.hxx')
-rw-r--r-- | sw/inc/undobj.hxx | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/sw/inc/undobj.hxx b/sw/inc/undobj.hxx index d449de1f8c9f..c76a1dfbec0e 100644 --- a/sw/inc/undobj.hxx +++ b/sw/inc/undobj.hxx @@ -152,6 +152,9 @@ bool IsDestroyFrameAnchoredAtChar(SwPosition const & rAnchorPos, bool IsSelectFrameAnchoredAtPara(SwPosition const & rAnchorPos, SwPosition const & rStart, SwPosition const & rEnd, DelContentType const nDelContentType = DelContentType::AllMask); +/// check at-char and at-para flys in rDoc +bool IsFlySelectedByCursor(SwDoc const & rDoc, + SwPosition const & rStart, SwPosition const & rEnd); // This class has to be inherited into an Undo-object if it saves content // for Redo/Undo... |