]> git.sesse.net Git - vlc/commitdiff
WinCE: no MonitorFromWindow
authorGeoffroy Couprie <geo.couprie@gmail.com>
Tue, 27 Jan 2009 17:22:04 +0000 (18:22 +0100)
committerGeoffroy Couprie <geo.couprie@gmail.com>
Tue, 27 Jan 2009 17:22:04 +0000 (18:22 +0100)
modules/video_output/msw/events.c

index ae1a26a7f56ddbf58d3465c7a7ae1fc1dc774ea6..9c48875332a710f306a94c541c35cca3bd47504b 100644 (file)
@@ -1202,6 +1202,15 @@ void Win32ToggleFullscreen( vout_thread_t *p_vout )
 
         if( p_vout->p_sys->hparent )
         {
+#ifdef UNDER_CE
+            POINT point = {0,0};
+            RECT rect;
+            ClientToScreen( p_vout->p_sys->hwnd, &point );
+            GetClientRect( p_vout->p_sys->hwnd, &rect );
+            SetWindowPos( hwnd, 0, point.x, point.y,
+                          rect.right, rect.bottom,
+                          SWP_NOZORDER|SWP_FRAMECHANGED );
+#else
             /* Retrieve current window position so fullscreen will happen
             *on the right screen */
             HMONITOR hmon = MonitorFromWindow(p_vout->p_sys->hparent,
@@ -1214,6 +1223,7 @@ void Win32ToggleFullscreen( vout_thread_t *p_vout )
                             mi.rcMonitor.right - mi.rcMonitor.left,
                             mi.rcMonitor.bottom - mi.rcMonitor.top,
                             SWP_NOZORDER|SWP_FRAMECHANGED );
+#endif
         }
 
         /* Maximize window */