[Libreoffice-commits] core.git: sw/source
Justin Luth (via logerrit)
logerrit at kemper.freedesktop.org
Wed Jun 17 07:00:45 UTC 2020
sw/source/uibase/docvw/edtwin.cxx | 8 +++++---
1 file changed, 5 insertions(+), 3 deletions(-)
New commits:
commit c3cf3e908add6b6617eb0ee12385fbd8a70a9887
Author: Justin Luth <jluth at mail.com>
AuthorDate: Wed Jun 17 09:00:33 2020 +0300
Commit: Justin Luth <justin_luth at sil.org>
CommitDate: Wed Jun 17 09:00:11 2020 +0200
tdf#134023 sw ui: stay at footer ONLY when showing control
This adds a missing piece to LO 6.4's
commit 342a5890dbcddccb4013e201e3ff3d9e6967e733
That tdf#84929 commit message suggested:
One additional limitation could be added to only apply this
if it is dealing with the footer, since in the case of a
header there would be no screen-jump.
and this bug report shows why that is necessary.
I'm not sure why I didn't apply that immediately.
Perhaps to help identify situations where the entire
concept might be bad?
Change-Id: Icea861bec45262eed88c38bb7eea910289c06870
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/96487
Tested-by: Justin Luth <justin_luth at sil.org>
Reviewed-by: Justin Luth <justin_luth at sil.org>
diff --git a/sw/source/uibase/docvw/edtwin.cxx b/sw/source/uibase/docvw/edtwin.cxx
index 132930631cf5..2a2d6634a0ea 100644
--- a/sw/source/uibase/docvw/edtwin.cxx
+++ b/sw/source/uibase/docvw/edtwin.cxx
@@ -2821,10 +2821,12 @@ void SwEditWin::MouseButtonDown(const MouseEvent& _rMEvt)
// Repaint everything
Invalidate();
- // If the control had not been showing, do not return to the cursor position,
+ // tdf#84929. If the footer control had not been showing, do not change the cursor position,
// because the user may have scrolled to turn on the separator control and
- // if the cursor is now off-screen, then the user would need to scroll back again to use the control.
- if ( !bSeparatorWasVisible && rSh.GetViewOptions()->IsUseHeaderFooterMenu() && !Application::IsHeadlessModeEnabled() )
+ // if the cursor cannot be positioned on-screen, then the user would need to scroll back again to use the control.
+ // This should only be done for the footer. The cursor can always be re-positioned near the header. tdf#134023.
+ if ( eControl == FrameControlType::Footer && !bSeparatorWasVisible
+ && rSh.GetViewOptions()->IsUseHeaderFooterMenu() && !Application::IsHeadlessModeEnabled() )
return;
}
}
More information about the Libreoffice-commits
mailing list