From 356c47e89e12154737dc71ecc7a30676ec96cdb9 Mon Sep 17 00:00:00 2001 From: Igor Tarasov Date: Fri, 23 May 2008 18:35:33 +0900 Subject: [PATCH] user32: Further implementation of MNS_NOTIFYBYPOS. --- dlls/user32/menu.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/dlls/user32/menu.c b/dlls/user32/menu.c index 49de5e1b7a4..dd859b170ec 100644 --- a/dlls/user32/menu.c +++ b/dlls/user32/menu.c @@ -2472,7 +2472,10 @@ static INT MENU_ExecFocusedItem( MTRACKER* pmt, HMENU hMenu, UINT wFlags ) MAKELPARAM((INT16)pmt->pt.x, (INT16)pmt->pt.y) ); else { - if (menu->dwStyle & MNS_NOTIFYBYPOS) + POPUPMENU *topmenu = MENU_GetMenu( pmt->hTopMenu ); + DWORD dwStyle = menu->dwStyle | (topmenu ? topmenu->dwStyle : 0); + + if (dwStyle & MNS_NOTIFYBYPOS) PostMessageW( pmt->hOwnerWnd, WM_MENUCOMMAND, menu->FocusedItem, (LPARAM)hMenu); else