Managementness of borderless windows

Stefan Dösinger stefandoesinger at gmx.at
Sun Jul 10 13:52:29 CDT 2005


Hello List,
Wine has problems with Windows which don't have the WS_CAPTION flag set. These 
Windows are usually not managed, which leads to focus problems(no keyboard) 
and the window constantly stays on top.

I had a look on this and tried to find a solution:
(Applications tested: Steam, Quicktime, Realoneplayer)

*All windows seem to have the WS_POPUP and WS_SYSMENU flag set

*GetParent(hwnd) returns NULL on the windows hwnd.

*GetAncestor(hwnd, GA_PARENT) returns the same as GetDesktopWindow()

I added a line which checks for GetAncestor() in is_window_managed(). This 
made the problematic windows managed nicely on my KDE Desktop, but it broke 
the menus which are also children of the desktop window.

Checking GetParent(hwnd) == NULL seems to work too, and it doesn't break the 
menus. I've sent a patch in March 2005
(http://www.winehq.org/hypermail/wine-patches/2005/03/0504.html), but it 
wasn't accepted, and according to my information using GetParent in this 
situation is wrong, and it affects other windows too, like some parts of the 
main window of Half Life 1.

The last thing that came into my mind is to make windows with WS_SYSMENU 
managed. This works without any side effects for me, but it doesn't appear 
right to me.

Can anyone suggest a solution? Are there any other apps which I can 
test(Freely downloadable, small download preferable)?

Thanks,
Stefan Dösinger




More information about the wine-devel mailing list