[vlc-commits] commit: skin2(Win32): add support for mouse wheel in fullscreen mode ( Erwan Tulou )

git at videolan.org git at videolan.org
Wed Jul 7 16:09:44 CEST 2010


vlc/vlc-1.1 | branch: master | Erwan Tulou <erwan10 at videolan.org> | Wed Jul  7 15:36:27 2010 +0200| [a49e2310b3a7743c66a3fc2adf72767aff992953] | committer: Erwan Tulou 

skin2(Win32): add support for mouse wheel in fullscreen mode

fix #3862
(cherry picked from commit 36fda079eaf46162d0cd67f205766e9c71ee1cc5)

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

 modules/gui/skins2/src/vout_manager.hpp |   13 +++++++++++++
 1 files changed, 13 insertions(+), 0 deletions(-)

diff --git a/modules/gui/skins2/src/vout_manager.hpp b/modules/gui/skins2/src/vout_manager.hpp
index 999990d..095f25c 100644
--- a/modules/gui/skins2/src/vout_manager.hpp
+++ b/modules/gui/skins2/src/vout_manager.hpp
@@ -28,10 +28,12 @@
 
 #include <vlc_vout.h>
 #include <vlc_vout_window.h>
+#include <vlc_keys.h>
 #include "../utils/position.hpp"
 #include "../commands/cmd_generic.hpp"
 #include "../controls/ctrl_video.hpp"
 #include "../events/evt_key.hpp"
+#include "../events/evt_scroll.hpp"
 
 class VarBool;
 class GenericWindow;
@@ -74,6 +76,17 @@ public:
             var_SetInteger( getIntf()->p_libvlc, "key-pressed",
                              rEvtKey.getModKey() );
     }
+
+    virtual void processEvent( EvtScroll &rEvtScroll )
+    {
+        // scroll events sent to core as hotkeys
+        int i_vlck = 0;
+        i_vlck |= rEvtScroll.getMod();
+        i_vlck |= ( rEvtScroll.getDirection() == EvtScroll::kUp ) ?
+                  KEY_MOUSEWHEELUP : KEY_MOUSEWHEELDOWN;
+
+        var_SetInteger( getIntf()->p_libvlc, "key-pressed", i_vlck );
+    }
 };
 
 



More information about the vlc-commits mailing list