x11drv, user: support for window state change SWP flag

Juris Smotrovs juris.smotrovs at sets.lv
Tue May 23 06:53:56 CDT 2006


Changelog:
Implements support for undocumented Windows SWP
flag signalling window state change, thus
making 10 todo tests succeed.

===
In more detail:

Recent modifications of dlls/x11drv/winpos.c introduced
some support for the undocumented SWP flag 0x8000.
The tests (dlls/user/tests/msg.c) show that
this flag is set whenever a window changes its state
between restored/maximized/minimized.

This patch:

* Introduces a constant for the SWP flag 0x8000,
so that it can be used in several places in Wine.

* Extends the support of this flag not only for
windows with style WS_CHILD, but for all windows
(certified by testcases
CreateWindow(WS_MAXIMIZED):popup (2 tests),
ShowWindow(SW_SHOWMAXIMIZED):popup with WS_POPUP style,
ShowWindow(SW_SHOWMAXIMIZED):overlapped with WS_OVERLAPPEDWINDOW style).
After applying patch, the flag 0x8000 appears
during msg.c tests exactly in the places where it appears in Windows.

* Implements corrections enabled by the usage of this flag
to make many of the testcases related with state change succeed.
Particularly, 10 todo testcases now succeed:
ShowWindow(SW_MAXIMIZE):invisible MDI child
ShowWindow(SW_RESTORE):invisible MDI child
ShowWindow(SW_MAXIMIZE):MDI child
ShowWindow(SW_RESTORE):MDI child
Create maximized visible 1st MDI child window
Create maximized visible 2nd MDI child 2 window
Create maximized visible 2nd MDI child 2 window
Maximize MDI child window with invisible parent
ShowWindow(SW_SHOWMAXIMIZED):popup
CreateWindow:maximized child

Additionally, 2 testcases which were marked as succeeding
had their SWP flag parts commented out, because they actually failed.
Now the SWP flags are set correctly in these testcases:
CreateWindow(WS_MAXIMIZED):popup (2 testcases with this description)

There are improvements in some more testcases, e.g.:
ShowWindow(SW_SHOWMAXIMIZED):overlapped (an earlier SWP flag failure now missing),
WM_MDICREATE for maximized visible MDI child window
(earlier failures with SWP flags now missing).

* Adds one more testcase to document behaviour of a child window
with invisible parent at ShowWindow(SW_RESTORE)
(current Wine version was failing on that,
though handled OK other cases in the invisible parent test):
ShowWindow(SW_RESTORE) child with invisible parent.

-------------- next part --------------
A non-text attachment was scrubbed...
Name: patch.diff
Type: text/x-patch
Size: 27082 bytes
Desc: not available
Url : http://www.winehq.org/pipermail/wine-patches/attachments/20060523/04cfe05f/patch-0001.diff


More information about the wine-patches mailing list