From: James Tabor Date: Mon, 15 Aug 2016 01:14:47 +0000 (+0000) Subject: [Win32SS] X-Git-Tag: backups/sndblst@72664~384 X-Git-Url: https://git.reactos.org/?p=reactos.git;a=commitdiff_plain;h=fddaeea6883d0d22d92a89cc107e61e1a64cff5d [Win32SS] - Fix regression from 62529, striped all the MF_POPUP from the code, no way to know if the submenu is a drop menu. See CORE-9269. svn path=/trunk/; revision=72227 --- diff --git a/reactos/win32ss/user/ntuser/menu.c b/reactos/win32ss/user/ntuser/menu.c index 6113bfee9f2..f29e2d06a90 100644 --- a/reactos/win32ss/user/ntuser/menu.c +++ b/reactos/win32ss/user/ntuser/menu.c @@ -4738,7 +4738,7 @@ UINT FASTCALL IntGetMenuState( HMENU hMenu, UINT uId, UINT uFlags) if (pItem->spSubMenu) { - return (pItem->spSubMenu->cItems << 8) | ((pItem->fState|pItem->fType) & 0xff); + return (pItem->spSubMenu->cItems << 8) | ((pItem->fState|pItem->fType|MF_POPUP) & 0xff); } else return (pItem->fType | pItem->fState); diff --git a/reactos/win32ss/user/user32/windows/menu.c b/reactos/win32ss/user/user32/windows/menu.c index 11538e3dc55..d95c30008ae 100644 --- a/reactos/win32ss/user/user32/windows/menu.c +++ b/reactos/win32ss/user/user32/windows/menu.c @@ -1062,6 +1062,7 @@ GetMenuState( { PMENU pSubMenu = DesktopPtrToUser(pItem->spSubMenu); HMENU hsubmenu = UserHMGetHandle(pSubMenu); + Type |= MF_POPUP; // Fix CORE-9269 if (!IsMenu(hsubmenu)) return (UINT)-1; else return (pSubMenu->cItems << 8) | ((pItem->fState|pItem->fType|Type) & 0xff); }