From: Jacek Caban jacek@codeweavers.com
Signed-off-by: Jacek Caban jacek@codeweavers.com --- dlls/user32/menu.c | 19 ++++++------------- 1 file changed, 6 insertions(+), 13 deletions(-)
diff --git a/dlls/user32/menu.c b/dlls/user32/menu.c index f5b74a24c25..73aee6b849d 100644 --- a/dlls/user32/menu.c +++ b/dlls/user32/menu.c @@ -4309,20 +4309,13 @@ BOOL WINAPI GetMenuInfo( HMENU menu, MENUINFO *info ) /********************************************************************** * GetMenuContextHelpId (USER32.@) */ -DWORD WINAPI GetMenuContextHelpId( HMENU hMenu ) +DWORD WINAPI GetMenuContextHelpId( HMENU menu ) { - DWORD help_id = 0; - POPUPMENU *menu; - - TRACE("(%p)\n", hMenu); - - if ((menu = grab_menu_ptr(hMenu))) - { - help_id = menu->dwContextHelpID; - release_menu_ptr(menu); - } - - return help_id; + MENUINFO info; + TRACE( "(%p)\n", menu ); + info.cbSize = sizeof(info); + info.fMask = MIM_HELPID; + return GetMenuInfo( menu, &info ) ? info.dwContextHelpID : 0; }
/**********************************************************************