[MPlayer-cvslog] r35899 - trunk/gui/ui/actions.c

ib subversion at mplayerhq.hu
Sat Jan 26 16:32:37 CET 2013


Author: ib
Date: Sat Jan 26 16:32:37 2013
New Revision: 35899

Log:
Restructure code for video window in uiChangeSkin().

Compact the conditions. It's much clearer now what's happening.

Additionally, change comment to indicate that the video window
will not be reloaded (like all other windows).

Modified:
   trunk/gui/ui/actions.c

Modified: trunk/gui/ui/actions.c
==============================================================================
--- trunk/gui/ui/actions.c	Sat Jan 26 02:07:36 2013	(r35898)
+++ trunk/gui/ui/actions.c	Sat Jan 26 16:32:37 2013	(r35899)
@@ -610,21 +610,21 @@ void uiChangeSkin(char *name)
     wsWindowVisibility(&guiApp.mainWindow, wsShowWindow);
     mainVisible = True;
 
-    /* reload video window (must be second!) */
+    /* adjust video window */
 
-    if (guiApp.video.Bitmap.Image)
+    if (guiApp.video.Bitmap.Image) {
         wsImageResize(&guiApp.videoWindow, guiApp.video.Bitmap.Width, guiApp.video.Bitmap.Height);
+        wsImageRender(&guiApp.videoWindow, guiApp.video.Bitmap.Image);
+    }
 
-    if (!guiApp.videoWindow.isFullScreen && !guiInfo.Playing) {
+    if (!guiInfo.Playing) {
+        if (!guiApp.videoWindow.isFullScreen) {
         wsWindowResize(&guiApp.videoWindow, guiApp.video.width, guiApp.video.height);
         wsWindowMove(&guiApp.videoWindow, False, guiApp.video.x, guiApp.video.y);
     }
 
-    if (guiApp.video.Bitmap.Image)
-        wsImageRender(&guiApp.videoWindow, guiApp.video.Bitmap.Image);
-
-    if (!guiInfo.Playing)
         wsWindowRedraw(&guiApp.videoWindow);
+    }
 
     /* reload playbar */
 


More information about the MPlayer-cvslog mailing list