diff options
author | Daniel Wilhelm <daniel@wili.li> | 2016-03-16 21:32:47 +0100 |
---|---|---|
committer | Daniel Wilhelm <daniel@wili.li> | 2016-03-16 21:32:47 +0100 |
commit | f7baa4de2ea9e5ce945078b76a3f20244a5d7946 (patch) | |
tree | 744a305661052e368a51b0063e16155dc9f7fe6e /wx+/context_menu.h | |
parent | 7.7 (diff) | |
download | FreeFileSync-f7baa4de2ea9e5ce945078b76a3f20244a5d7946.tar.gz FreeFileSync-f7baa4de2ea9e5ce945078b76a3f20244a5d7946.tar.bz2 FreeFileSync-f7baa4de2ea9e5ce945078b76a3f20244a5d7946.zip |
7.8
Diffstat (limited to 'wx+/context_menu.h')
-rw-r--r-- | wx+/context_menu.h | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/wx+/context_menu.h b/wx+/context_menu.h index 27c00c81..9c30cb98 100644 --- a/wx+/context_menu.h +++ b/wx+/context_menu.h @@ -70,13 +70,13 @@ public: menu->Append(newItem); } - void popup(wxWindow& wnd) //show popup menu + process lambdas + void popup(wxWindow& wnd, const wxPoint& pos = wxDefaultPosition) //show popup menu + process lambdas { //eventually all events from submenu items will be received by this menu for (const auto& item : commandList) menu->Connect(item.first, wxEVT_COMMAND_MENU_SELECTED, wxCommandEventHandler(ContextMenu::onSelection), new GenericCommand(item.second) /*pass ownership*/, this); - wnd.PopupMenu(menu.get()); + wnd.PopupMenu(menu.get(), pos); wxTheApp->ProcessPendingEvents(); //make sure lambdas are evaluated before going out of scope; //although all events seem to be processed within wxWindows::PopupMenu, we shouldn't trust wxWidgets in this regard } |