Cleaned up a bit (msw).
authorLaurent Aimar <fenrir@videolan.org>
Thu, 1 Oct 2009 19:49:15 +0000 (21:49 +0200)
committerLaurent Aimar <fenrir@videolan.org>
Thu, 1 Oct 2009 20:02:52 +0000 (22:02 +0200)
modules/video_output/msw/common.c
modules/video_output/msw/events.c
modules/video_output/msw/events.h
modules/video_output/msw/vout.h

index 5438d12..262d196 100644 (file)
@@ -701,7 +701,7 @@ void Win32ToggleFullscreen( vout_thread_t *p_vout )
         }
 
         /* Make sure the mouse cursor is displayed */
-        PostMessage( p_vout->p_sys->hwnd, WM_VLC_SHOW_MOUSE, 0, 0 );
+        EventThreadMouseShow( p_vout->p_sys->p_event );
     }
 
     /* Update the object variable and trigger callback */
index 4436dca..44867ab 100644 (file)
 /*****************************************************************************
  * Local prototypes.
  *****************************************************************************/
+#define WM_VLC_HIDE_MOUSE   (WM_APP + 0)
+#define WM_VLC_SHOW_MOUSE   (WM_APP + 1)
+#define WM_VLC_CHANGE_TEXT  (WM_APP + 2)
+
 struct event_thread_t
 {
     vout_thread_t *p_vout;
@@ -933,6 +937,10 @@ void EventThreadMouseAutoHide( event_thread_t *p_event )
         }
     }
 }
+void EventThreadMouseShow( event_thread_t *p_event )
+{
+    PostMessage( p_event->hwnd, WM_VLC_SHOW_MOUSE, 0, 0 );
+}
 void EventThreadUpdateTitle( event_thread_t *p_event, const char *psz_fallback )
 {
     char *psz_title = var_GetNonEmptyString( p_event->p_vout, "video-title" );
index bbd57e3..5e5204d 100644 (file)
@@ -48,6 +48,7 @@ int             EventThreadStart( event_thread_t *, event_hwnd_t *, const event_
 void            EventThreadStop( event_thread_t * );
 
 void            EventThreadMouseAutoHide( event_thread_t * );
+void            EventThreadMouseShow( event_thread_t * );
 void            EventThreadUpdateTitle( event_thread_t *, const char *psz_fallback );
 unsigned        EventThreadRetreiveChanges( event_thread_t * );
 int             EventThreadGetWindowStyle( event_thread_t * );
index 93de50c..9dc3487 100644 (file)
@@ -250,9 +250,6 @@ void RestoreScreensaver ( vout_thread_t *p_vout );
 /*****************************************************************************
  * Constants
  *****************************************************************************/
-#define WM_VLC_HIDE_MOUSE WM_APP
-#define WM_VLC_SHOW_MOUSE WM_APP + 1
-#define WM_VLC_CHANGE_TEXT WM_APP + 2
 #define IDM_TOGGLE_ON_TOP WM_USER + 1
 #define DX_POSITION_CHANGE 0x1000
 #define DX_WALLPAPER_CHANGE 0x2000