[PATCH] comctl32/tests: Fix propsheet and listview tests which depend on being in foreground.
-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 Hello, the comctl32:propsheet and comctl32:listview are regularly failing on the Windows testbots. This is visible in these test runs with an "empty" patch to these tests: https://testbot.winehq.org/JobDetails.pl?Key=6828 https://testbot.winehq.org/JobDetails.pl?Key=6829 This is because windows forbids them to get into foreground. This patch is working around this by simulating an ALT key press and then calling SetForegroundWindow. These are the results with an earlier revision of this patch: https://testbot.winehq.org/JobDetails.pl?Key=6832 https://testbot.winehq.org/JobDetails.pl?Key=6833 Kind regards, Bernhard -----BEGIN PGP SIGNATURE----- Version: GnuPG v1 Comment: Using GnuPG with Thunderbird - http://www.enigmail.net/ iQEcBAEBAgAGBQJTaVcbAAoJEOlvol+DpkHmDb8IAKD/G0FWgDP8v44SpfqhHY2W 0g8fCzJY6/GhjweV6Mybwqx/YmeBwmc8qvRuHshDUm8WWZbI6yH14LEGz5GwbccI XH/kJgiqqaJH8AiCQM6chF+JBAz3URf9SsAsuDKBjNmpHSMkPAhC/JXecI43GMyX E2AoggKh6DXtEq3yOnGJIRSMAhGPJGYP1Vny5+rq6+rvg2DpNdGI11Xk4oCVgJvc cYCk3yVNKquv4JW8vg80ZJboglDff7omTBLJdF5Nkk5xSGY4iV7amp9CChEJN33N lsohSyvIXeDWegeCWaXGNGhTPXwuTb56tQG22uR7IxJscT8/cXsDQ4jYvuTHoXM= =hTJp -----END PGP SIGNATURE-----
@@ -587,6 +587,7 @@ static HWND create_parent_window(BOOL Unicode) WS_MAXIMIZEBOX | WS_VISIBLE, 0, 0, 100, 100, GetDesktopWindow(), NULL, GetModuleHandleA(NULL), NULL); + force_set_foreground_window(hwnd); SetWindowPos( hwnd, HWND_TOPMOST, 0, 0, 0, 0, SWP_NOSIZE|SWP_NOMOVE ); return hwnd; } I don't know about propsheet part, but for a listview you're setting parent to foreground, does it mean that lately created child listview will be foreground as well? Cause failing test is about mouse movements over listview, not its parent.
-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 Hello Nikolay,
I don't know about propsheet part, but for a listview you're setting parent to foreground, does it mean that lately created child listview will be foreground as well? Cause failing test is about mouse movements over listview, not its parent. If I understand you correct yes, most of the listviews in the tests are created with the parent window being that one I try to get to foreground. Therefore the failing listview is then also in foreground.
If you execute this test in windows from a cmd window which has focus then the test is not failing. But when you immediately after starting the test click to another opened window or minimize the cmd window this failure can be reproduced. So one could say this patch is not fixing the test - it only changes the environment to the state it currently expects. Kind regards, Bernhard -----BEGIN PGP SIGNATURE----- Version: GnuPG v1 Comment: Using GnuPG with Thunderbird - http://www.enigmail.net/ iQEcBAEBAgAGBQJTarcHAAoJEOlvol+DpkHmBzYH/2osoORR6zfcN0ZbKzp3jT2s CfhFvpONTDkyQTMFht8m1qZAwl2xRqjnCoA/JxYLNJqpzIatQ6RuDIOrPuL4SL8F Zz9QkZ13eF5ww9DHaFpc+w0coi2RdUamtNK6SzU3L55m8drwsJpLv0cyCnLhDuLK uvhj8ZSppatnsLxcIdjon1seaLUhHBwICaGtoUjKPb3NaL3LGIt410dddFFgXFir Mv+A+pewmnkvhyJQmzdoUDz90cwK/YZFFUX8pGNdLDjA3TCHzn7/gWIzX081vxj8 B+dSmarM3CTLZ63cFn3aMDAunuLGc9GSWDFacQfM3ndSxMXTXZl/YDJWyn6T82U= =5kGN -----END PGP SIGNATURE-----
participants (2)
-
Bernhard Übelacker -
Nikolay Sivov