From e777f2a253ee9eece60ef1579ad92c2fe8aadc63 Mon Sep 17 00:00:00 2001 From: Vadim Zeitlin Date: Tue, 6 Mar 2018 19:51:31 +0100 Subject: [PATCH] Document that wxEVT_TREE_ITEM_MENU item is always valid Mention that wxEVT_CONTEXT_MENU can be used to show popup menus that should be shown even when clicking outside of the client area. --- interface/wx/treectrl.h | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/interface/wx/treectrl.h b/interface/wx/treectrl.h index 0a73785bde..c7738861d4 100644 --- a/interface/wx/treectrl.h +++ b/interface/wx/treectrl.h @@ -132,7 +132,10 @@ Processes a @c wxEVT_TREE_ITEM_GETTOOLTIP event type. @event{EVT_TREE_ITEM_MENU(id, func)} The context menu for the selected item has been requested, either by a - right click or by using the menu key. + right click or by using the menu key. Notice that these events always + carry a valid tree item and so are not generated when (right) + clicking outside of the items area. If you need to handle such + events, consider using @c wxEVT_CONTEXT_MENU instead. Processes a @c wxEVT_TREE_ITEM_MENU event type. @event{EVT_TREE_STATE_IMAGE_CLICK(id, func)} The state image has been clicked.