dclark at akamail.com
Tue Jan 7 21:01:12 CST 2003
Dmitry Timoshkov wrote:
> "Duane Clark" <dclark at akamail.com> wrote:
>>A window with a WS_EX_APPWINDOW extended style can also
>>get a menu.
>> /* Set the window menu */
>>- if ((wndPtr->dwStyle & (WS_CAPTION | WS_CHILD)) == WS_CAPTION )
>>+ if ((wndPtr->dwStyle & WS_CAPTION || wndPtr->dwExStyle & WS_EX_APPWINDOW)
>>+ && !( wndPtr->dwStyle & WS_CHILD) )
> Sorry for the late response, but this doesn't look right to me.
> First of all check for WS_CAPTION should be if ((dwStyle & WS_CAPTION) == WS_CAPTION)
> because WS_CAPTION is a two bit style. Next, apparently menu can be assigned
> only for a window that has a caption and not is a child. If for some reason
> in your case a window has no WS_CAPTION style set (even after all style
> corrections) then it's a bug in Wine and it should be found and fixed.
> I would suggest to write a conformance test for this, which will create windows
> with various styles, check whether they have a caption (by comparing client and
> window rectangles), then try to set a menu for a window.
Well, just as a bit of info, the window does not appear to have a
caption; either in Windows or Wine. The menu pops down when the mouse is
slid to the very top of the window, and no other border decoration shows
ever. Here is the call that does it, which is a call directly from the app.
trace:win:WIN_CreateWindowEx "" "menuWndProc" ex=00040000 style=80000000
0,0 640x19 parent=0x10023 menu=0xc8 inst=0x400000 params=(nil)
More information about the wine-devel