ignore requested height for non-menubar ownerdraw popups
Felix Nawothnig
felix.nawothnig at t-online.de
Sun May 8 06:30:30 CDT 2005
On 05/08/2005 12:25:18 PM, Rein Klazes wrote:
> That does not seem correct on the Win2k system that I am using for
> testing.
Right. Windows sets itemHeight before and not after WM_MEASUREITEM.
Sorry for that.
And it also seems not to be GetSystemMetrics(SM_CYMENU)-1 but a rather
strange magic value of 16. (with my test it looked 100% the same ...
sigh. I'll go to bed soon. ;)
How about this patch?
-flx
-------------- next part --------------
Index: menu.c
===================================================================
RCS file: /home/wine/wine/dlls/user/menu.c,v
retrieving revision 1.26
diff -u -r1.26 menu.c
--- menu.c 19 Apr 2005 09:47:02 -0000 1.26
+++ menu.c 8 May 2005 11:23:59 -0000
@@ -882,7 +882,8 @@
mis.CtlID = 0;
mis.itemID = lpitem->wID;
mis.itemData = (DWORD)lpitem->dwItemData;
- mis.itemHeight = 0;
+ mis.itemHeight = 16; /* XXX: WinXP sets this - but where does
+ this come from? */
mis.itemWidth = 0;
SendMessageW( hwndOwner, WM_MEASUREITEM, 0, (LPARAM)&mis );
lpitem->rect.right += mis.itemWidth;
More information about the wine-devel
mailing list