[vlc-commits] qt: input_slider: Convert wheel events to KEY_MOUSEWHEEL*

Hugo Beauzée-Luyssen git at videolan.org
Fri Apr 6 11:43:47 CEST 2018


vlc/vlc-3.0 | branch: master | Hugo Beauzée-Luyssen <hugo at beauzee.fr> | Thu Apr  5 10:59:58 2018 +0200| [907a01db65ed657565fcbaa21dc627be4077a63d] | committer: Hugo Beauzée-Luyssen

qt: input_slider: Convert wheel events to KEY_MOUSEWHEEL*

This way we can honor the user's settings regarding inverting the scroll
direction, and they can chose the size of the jump

refs #19790

(cherry picked from commit 11bd3483a06de831a9127fd813db5728a178632a)
Signed-off-by: Hugo Beauzée-Luyssen <hugo at beauzee.fr>

> http://git.videolan.org/gitweb.cgi/vlc/vlc-3.0.git/?a=commit;h=907a01db65ed657565fcbaa21dc627be4077a63d
---

 modules/gui/qt/util/input_slider.cpp | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/modules/gui/qt/util/input_slider.cpp b/modules/gui/qt/util/input_slider.cpp
index b612354832..d5dcff61ea 100644
--- a/modules/gui/qt/util/input_slider.cpp
+++ b/modules/gui/qt/util/input_slider.cpp
@@ -404,9 +404,9 @@ void SeekSlider::wheelEvent( QWheelEvent *event )
     if( !isSliding && isEnabled() )
     {
         if ( event->delta() > 0 )
-            var_SetInteger( p_intf->obj.libvlc, "key-action", ACTIONID_JUMP_BACKWARD_SHORT );
+            var_SetInteger( p_intf->obj.libvlc, "key-pressed", KEY_MOUSEWHEELRIGHT );
         else
-            var_SetInteger( p_intf->obj.libvlc, "key-action", ACTIONID_JUMP_FORWARD_SHORT );
+            var_SetInteger( p_intf->obj.libvlc, "key-pressed", KEY_MOUSEWHEELLEFT );
     }
     event->accept();
 }



More information about the vlc-commits mailing list