[PATCH 3/5] user32: A button-up in the menu-bar, but not on an item, should stop the tracking.

Huw Davies huw at codeweavers.com
Mon Jun 5 07:05:13 CDT 2017


Signed-off-by: Huw Davies <huw at codeweavers.com>
---
 dlls/user32/menu.c | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/dlls/user32/menu.c b/dlls/user32/menu.c
index 95e4ef6..00abcc9 100644
--- a/dlls/user32/menu.c
+++ b/dlls/user32/menu.c
@@ -2647,7 +2647,10 @@ static INT MENU_ButtonUp( MTRACKER* pmt, HMENU hPtMenu, UINT wFlags)
 		return 0;
 	}
         if( GetMenu(ptmenu->hWnd) == hPtMenu || IS_SYSTEM_MENU(ptmenu) )
+        {
+            if (pos == NO_SELECTED_ITEM) return 0;
             pmt->trackFlags |= TF_RCVD_BTN_UP;
+        }
     }
     return -1;
 }
-- 
2.7.4




More information about the wine-patches mailing list