[Libreoffice-commits] core.git: vcl/qt5 vcl/source

Jan-Marek Glogowski (via logerrit) logerrit at kemper.freedesktop.org
Tue Aug 13 15:51:58 UTC 2019


 vcl/qt5/Qt5Widget.cxx         |    2 +-
 vcl/source/window/window2.cxx |    7 ++++---
 2 files changed, 5 insertions(+), 4 deletions(-)

New commits:
commit a0a6a7e60ee499ffd82a57b899ca5f4981f0ab2f
Author:     Jan-Marek Glogowski <jan-marek.glogowski at extern.cib.de>
AuthorDate: Tue Aug 13 11:34:40 2019 +0200
Commit:     Jan-Marek Glogowski <glogow at fbihome.de>
CommitDate: Tue Aug 13 17:51:09 2019 +0200

    tdf#126680 Revert "VCL make horizontal scrolling depend on RTL"
    
    This reverts commit 845743131b733b52eb913048f55f5efdd013b24f.
    
    And fixes the direction in Qt, which I intentionally broke. Didn't
    find time yet to fix all the backends, so just stay with the
    original code.
    
    Change-Id: I9967a0d7e75dcb99f8465e9eecf81afe2d351064
    Reviewed-on: https://gerrit.libreoffice.org/77390
    Tested-by: Jenkins
    Reviewed-by: Jan-Marek Glogowski <glogow at fbihome.de>

diff --git a/vcl/qt5/Qt5Widget.cxx b/vcl/qt5/Qt5Widget.cxx
index 843ce798a989..f3dbfd516716 100644
--- a/vcl/qt5/Qt5Widget.cxx
+++ b/vcl/qt5/Qt5Widget.cxx
@@ -191,7 +191,7 @@ void Qt5Widget::wheelEvent(QWheelEvent* pEvent)
     aEvent.mbHorz = nDelta == 0;
     if (aEvent.mbHorz)
     {
-        nDelta = (QGuiApplication::isLeftToRight() ? -1 : 1) * pEvent->angleDelta().x();
+        nDelta = (QGuiApplication::isLeftToRight() ? 1 : -1) * pEvent->angleDelta().x();
         if (!nDelta)
             return;
 
diff --git a/vcl/source/window/window2.cxx b/vcl/source/window/window2.cxx
index 701a8730ed87..16f202ee09df 100644
--- a/vcl/source/window/window2.cxx
+++ b/vcl/source/window/window2.cxx
@@ -667,9 +667,10 @@ bool Window::HandleScrollCommand( const CommandEvent& rCmd,
                             nLines = pData->GetNotchDelta() * nScrollLines;
                         if ( nLines )
                         {
-                            ImplHandleScroll(nullptr, 0L, pData->IsHorz() ? pHScrl : pVScrl,
-                                pData->IsHorz() && pHScrl && (AllSettings::GetLayoutRTL() == pHScrl->IsRTLEnabled())
-                                    ? -nLines : nLines);
+                            ImplHandleScroll( nullptr,
+                                          0L,
+                                          pData->IsHorz() ? pHScrl : pVScrl,
+                                          nLines );
                             bRet = true;
                         }
                     }


More information about the Libreoffice-commits mailing list