[Libreoffice-commits] core.git: vcl/source
Szymon KÅos (via logerrit)
logerrit at kemper.freedesktop.org
Thu Feb 4 14:13:35 UTC 2021
vcl/source/treelist/svimpbox.cxx | 4 ++++
1 file changed, 4 insertions(+)
New commits:
commit 50e345d50b72aad07776d4af343f41028640d83e
Author: Szymon Kłos <szymon.klos at collabora.com>
AuthorDate: Wed Feb 3 16:44:35 2021 +0100
Commit: Szymon Kłos <szymon.klos at collabora.com>
CommitDate: Thu Feb 4 15:12:36 2021 +0100
Don't skip lines if only one row in the list
Mouse wheel emits delta > 1 so if we see only one row
but delta is 3 we skip then 2 rows.
Change-Id: I136788d38a189c061a55cba12eef05c7a4733820
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/110379
Tested-by: Jenkins
Reviewed-by: Szymon Kłos <szymon.klos at collabora.com>
diff --git a/vcl/source/treelist/svimpbox.cxx b/vcl/source/treelist/svimpbox.cxx
index 186810ff84c9..7397305e0aba 100644
--- a/vcl/source/treelist/svimpbox.cxx
+++ b/vcl/source/treelist/svimpbox.cxx
@@ -293,6 +293,10 @@ IMPL_LINK( SvImpLBox, ScrollUpDownHdl, ScrollBar *, pScrollBar, void )
if( !nDelta )
return;
+ // when only one row don't skip lines
+ if (pScrollBar->GetPageSize() == 1)
+ nDelta = nDelta > 0 ? 1 : -1;
+
m_nFlags &= ~LBoxFlags::Filling;
m_bInVScrollHdl = true;
More information about the Libreoffice-commits
mailing list