[vlc-devel] [PATCH] Use middle mouse button to toggle fullscreen on Windows systems.

VlcVelope 1034-135 at online.de
Sun Apr 29 13:14:48 CEST 2012


This change make use of the middle mouse button to toggle fullscreen. I found
this feature quite useful.

Regards,
VlcVelope
---
 modules/video_output/msw/events.c |    7 +++++++
 1 files changed, 7 insertions(+), 0 deletions(-)

diff --git a/modules/video_output/msw/events.c b/modules/video_output/msw/events.c
index 51de721..dd428fd 100644
--- a/modules/video_output/msw/events.c
+++ b/modules/video_output/msw/events.c
@@ -203,6 +203,12 @@ static void MousePressed( event_thread_t *p_event, HWND hwnd, unsigned button )
         SetCapture( hwnd );
     p_event->button_pressed |= 1 << button;
     vout_display_SendEventMousePressed( p_event->vd, button );
+    /* if middle button is clicked toggle fullscreen */
+    if( button == MOUSE_BUTTON_CENTER )
+    {
+        if( hwnd == p_event->hvideownd )
+            vout_display_SendEventMouseDoubleClick( p_event->vd );
+    }
 }
 
 static void MouseReleased( event_thread_t *p_event, unsigned button )
@@ -1161,3 +1167,4 @@ void EventThreadStop( event_thread_t *p_event )
     p_event->b_ready = false;
 }
 
+
-- 
1.7.5.4




More information about the vlc-devel mailing list