[MPlayer-cvslog] r32612 - trunk/libvo/w32_common.c
reimar
subversion at mplayerhq.hu
Tue Nov 9 23:13:11 CET 2010
Author: reimar
Date: Tue Nov 9 23:13:11 2010
New Revision: 32612
Log:
Simplify: Use early return instead of large if block.
Modified:
trunk/libvo/w32_common.c
Modified: trunk/libvo/w32_common.c
==============================================================================
--- trunk/libvo/w32_common.c Tue Nov 9 23:11:08 2010 (r32611)
+++ trunk/libvo/w32_common.c Tue Nov 9 23:13:11 2010 (r32612)
@@ -327,10 +327,12 @@ static void resetMode(void) {
static int createRenderingContext(void) {
HWND layer = HWND_NOTOPMOST;
RECT r;
- if (WinID < 0) {
int style = (vo_border && !vo_fs) ?
(WS_OVERLAPPEDWINDOW | WS_SIZEBOX) : WS_POPUP;
+ if (WinID >= 0)
+ return 1;
+
if (vo_fs || vo_ontop) layer = HWND_TOPMOST;
if (vo_fs) {
changeMode();
@@ -371,7 +373,6 @@ static int createRenderingContext(void)
r.bottom = r.top + vo_dheight;
AdjustWindowRect(&r, style, 0);
SetWindowPos(vo_window, layer, r.left, r.top, r.right - r.left, r.bottom - r.top, SWP_SHOWWINDOW);
- }
return 1;
}
More information about the MPlayer-cvslog
mailing list