[vlc-commits] skins2: transmit scroll events to the vout display

Erwan Tulou git at videolan.org
Thu Feb 8 00:39:36 CET 2018


vlc | branch: master | Erwan Tulou <erwan10 at videolan.org> | Wed Feb  7 20:13:30 2018 +0100| [d362b2df71a0aad0f77a7fce4c812aceb0f645db] | committer: Erwan Tulou

skins2: transmit scroll events to the vout display

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

 modules/gui/skins2/src/vout_window.cpp | 9 +++++++++
 modules/gui/skins2/src/vout_window.hpp | 1 +
 2 files changed, 10 insertions(+)

diff --git a/modules/gui/skins2/src/vout_window.cpp b/modules/gui/skins2/src/vout_window.cpp
index d683e6a974..d8c2e2f2e4 100644
--- a/modules/gui/skins2/src/vout_window.cpp
+++ b/modules/gui/skins2/src/vout_window.cpp
@@ -118,6 +118,15 @@ void VoutWindow::processEvent( EvtKey &rEvtKey )
 }
 
 
+void VoutWindow::processEvent( EvtScroll &rEvtScroll )
+{
+    int i = (rEvtScroll.getDirection() == EvtScroll::kUp ?
+            KEY_MOUSEWHEELUP : KEY_MOUSEWHEELDOWN) | rEvtScroll.getMod();
+
+    getIntf()->p_sys->p_dialogs->sendKey( i );
+}
+
+
 void VoutWindow::processEvent( EvtMotion &rEvtMotion )
 {
     int x = rEvtMotion.getXPos() - m_pParentWindow->getLeft() - getLeft();
diff --git a/modules/gui/skins2/src/vout_window.hpp b/modules/gui/skins2/src/vout_window.hpp
index ef971ae7d5..0a927c80cd 100644
--- a/modules/gui/skins2/src/vout_window.hpp
+++ b/modules/gui/skins2/src/vout_window.hpp
@@ -56,6 +56,7 @@ public:
 
     /// hotkeys processing
     virtual void processEvent( EvtKey &rEvtKey );
+    virtual void processEvent( EvtScroll &rEvtScroll );
     virtual void processEvent( EvtMotion &rEvtMotion );
     virtual void processEvent( EvtMouse &rEvtMouse );
 



More information about the vlc-commits mailing list