Module: wine Branch: master Commit: accfce21d3e042638a5eac8a8379eda2964fcd0a URL: http://source.winehq.org/git/wine.git/?a=commit;h=accfce21d3e042638a5eac8a83...
Author: Alexandre Julliard julliard@winehq.org Date: Tue Mar 4 20:01:41 2008 +0100
user32: Fix a couple of message test failures.
---
dlls/user32/tests/msg.c | 4 ++-- dlls/user32/winpos.c | 5 +++-- 2 files changed, 5 insertions(+), 4 deletions(-)
diff --git a/dlls/user32/tests/msg.c b/dlls/user32/tests/msg.c index 1ab5a0f..7d5dffa 100644 --- a/dlls/user32/tests/msg.c +++ b/dlls/user32/tests/msg.c @@ -9346,8 +9346,8 @@ static void test_ShowWindow(void) /* 31 */ { SW_RESTORE, TRUE, WS_VISIBLE, WmEmptySeq, FALSE }, /* 32 */ { SW_HIDE, TRUE, 0, WmHide_3, TRUE }, /* 33 */ { SW_HIDE, FALSE, 0, WmEmptySeq, FALSE }, -/* 34 */ { SW_NORMALNA, FALSE, 0, WmEmptySeq, TRUE }, /* what does this mean?! */ -/* 35 */ { SW_NORMALNA, FALSE, 0, WmEmptySeq, TRUE }, +/* 34 */ { SW_NORMALNA, FALSE, 0, WmEmptySeq, FALSE }, /* what does this mean?! */ +/* 35 */ { SW_NORMALNA, FALSE, 0, WmEmptySeq, FALSE }, /* 36 */ { SW_HIDE, FALSE, 0, WmEmptySeq, FALSE }, /* 37 */ { SW_RESTORE, FALSE, WS_VISIBLE, WmRestore_2, FALSE }, /* 38 */ { SW_RESTORE, TRUE, WS_VISIBLE, WmEmptySeq, FALSE }, diff --git a/dlls/user32/winpos.c b/dlls/user32/winpos.c index c60e75d..d61fe01 100644 --- a/dlls/user32/winpos.c +++ b/dlls/user32/winpos.c @@ -1052,8 +1052,7 @@ static BOOL show_window( HWND hwnd, INT cmd ) if (!wasVisible) return FALSE; showFlag = FALSE; swp |= SWP_HIDEWINDOW | SWP_NOSIZE | SWP_NOMOVE; - if (hwnd != GetActiveWindow()) - swp |= SWP_NOACTIVATE | SWP_NOZORDER; + if (style & WS_CHILD) swp |= SWP_NOACTIVATE | SWP_NOZORDER; break;
case SW_SHOWMINNOACTIVE: @@ -1106,6 +1105,8 @@ static BOOL show_window( HWND hwnd, INT cmd ) } if (style & WS_CHILD && !(swp & SWP_STATECHANGED)) swp |= SWP_NOACTIVATE | SWP_NOZORDER; break; + default: + return wasVisible; }
if ((showFlag != wasVisible || cmd == SW_SHOWNA) && cmd != SW_SHOWMAXIMIZED && !(swp & SWP_STATECHANGED))