vcl/source/window/layout.cxx |    5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)

New commits:
commit 411c870ed16c6a27bbd9c762e187783b3b39849e
Author:     Caolán McNamara <caol...@redhat.com>
AuthorDate: Mon Mar 1 11:56:17 2021 +0000
Commit:     Adolfo Jayme Barrientos <fit...@ubuntu.com>
CommitDate: Wed Mar 3 09:12:20 2021 +0100

    tdf#140537 scroll-wheeling shouldn't affect disabled scrollbars
    
    Change-Id: I5d8659c7d431d35d628b12cebfe6a4b4f9cab9ef
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/111703
    Tested-by: Jenkins
    Reviewed-by: Adolfo Jayme Barrientos <fit...@ubuntu.com>

diff --git a/vcl/source/window/layout.cxx b/vcl/source/window/layout.cxx
index 9b562c340b6b..2cf77e81a688 100644
--- a/vcl/source/window/layout.cxx
+++ b/vcl/source/window/layout.cxx
@@ -2059,7 +2059,10 @@ bool VclScrolledWindow::EventNotify(NotifyEvent& rNEvt)
             const CommandWheelData* pData = rCEvt.GetWheelData();
             if( !pData->GetModifier() && ( pData->GetMode() == 
CommandWheelMode::SCROLL ) )
             {
-                bDone = HandleScrollCommand(rCEvt, m_pHScroll, m_pVScroll);
+                // tdf#140537 only handle scroll commands in the valid shown 
scrollbars
+                bDone = HandleScrollCommand(rCEvt,
+                                            m_pHScroll->IsVisible() ? 
m_pHScroll : nullptr,
+                                            m_pVScroll->IsVisible() ? 
m_pVScroll : nullptr);
             }
         }
     }
_______________________________________________
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits

Reply via email to