user32: Cope with failing SetForegroundWindow().
This commit is contained in:
parent
65c35aad8e
commit
cf6c76b3b4
|
@ -3346,6 +3346,7 @@ static void test_SetParent(void)
|
||||||
HWND desktop = GetDesktopWindow();
|
HWND desktop = GetDesktopWindow();
|
||||||
HMENU hMenu;
|
HMENU hMenu;
|
||||||
HWND ret, parent, child1, child2, child3, child4, sibling, popup;
|
HWND ret, parent, child1, child2, child3, child4, sibling, popup;
|
||||||
|
BOOL bret;
|
||||||
|
|
||||||
parent = CreateWindowExA(0, "static", NULL, WS_OVERLAPPEDWINDOW,
|
parent = CreateWindowExA(0, "static", NULL, WS_OVERLAPPEDWINDOW,
|
||||||
100, 100, 200, 200, 0, 0, 0, NULL);
|
100, 100, 200, 200, 0, 0, 0, NULL);
|
||||||
|
@ -3474,9 +3475,13 @@ todo_wine
|
||||||
SetFocus(parent);
|
SetFocus(parent);
|
||||||
check_active_state(parent, 0, parent);
|
check_active_state(parent, 0, parent);
|
||||||
|
|
||||||
|
bret = SetForegroundWindow(popup);
|
||||||
todo_wine {
|
todo_wine {
|
||||||
ok(SetForegroundWindow(popup), "SetForegroundWindow() failed\n");
|
ok(bret || broken(!bret), "SetForegroundWindow() failed\n");
|
||||||
check_active_state(popup, 0, popup);
|
if (!bret)
|
||||||
|
check_active_state(popup, 0, popup);
|
||||||
|
else
|
||||||
|
check_active_state(popup, popup, popup);
|
||||||
}
|
}
|
||||||
|
|
||||||
ok(DestroyWindow(parent), "DestroyWindow() failed\n");
|
ok(DestroyWindow(parent), "DestroyWindow() failed\n");
|
||||||
|
|
Loading…
Reference in New Issue