[3/6]comctl32: treeview should send WM_CONTEXTMENU everywhere, not just over items
Daniel Jelinski
djelinski1 at gmail.com
Fri Jul 13 14:58:08 CDT 2012
-------------- next part --------------
From c55e0d391b37d0e1808f08d50f76e68ff787635c Mon Sep 17 00:00:00 2001
From: Daniel Jelinski <djelinski1 at gmail.com>
Date: Fri, 13 Jul 2012 20:42:33 +0200
Subject: [PATCH 3/6] comctl32: treeview should send WM_CONTEXTMENU
everywhere, not just over items
Tested on linux+native comctl32 and several testbot's machines
---
dlls/comctl32/treeview.c | 15 +++++----------
1 files changed, 5 insertions(+), 10 deletions(-)
diff --git a/dlls/comctl32/treeview.c b/dlls/comctl32/treeview.c
index e55c941..88c1ff4 100644
--- a/dlls/comctl32/treeview.c
+++ b/dlls/comctl32/treeview.c
@@ -4274,17 +4274,12 @@ TREEVIEW_RButtonUp(const TREEVIEW_INFO *infoPtr, const POINT *pPt)
ht.pt = *pPt;
- TREEVIEW_HitTest(infoPtr, &ht);
-
- if (ht.hItem)
- {
- /* Change to screen coordinate for WM_CONTEXTMENU */
- ClientToScreen(infoPtr->hwnd, &ht.pt);
+ /* Change to screen coordinate for WM_CONTEXTMENU */
+ ClientToScreen(infoPtr->hwnd, &ht.pt);
- /* Send a WM_CONTEXTMENU message in response to the RBUTTONUP */
- SendMessageW(infoPtr->hwnd, WM_CONTEXTMENU,
- (WPARAM)infoPtr->hwnd, MAKELPARAM(ht.pt.x, ht.pt.y));
- }
+ /* Send a WM_CONTEXTMENU message in response to the RBUTTONUP */
+ SendMessageW(infoPtr->hwnd, WM_CONTEXTMENU,
+ (WPARAM)infoPtr->hwnd, MAKELPARAM(ht.pt.x, ht.pt.y));
return 0;
}
--
1.7.5.4
More information about the wine-patches
mailing list