From ad4e3d2c55e75193c41356c23619f80add41db18 Mon Sep 17 00:00:00 2001 From: Daniel Wilhelm Date: Fri, 2 Oct 2015 14:57:46 +0200 Subject: 7.5 --- wx+/context_menu.h | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'wx+/context_menu.h') diff --git a/wx+/context_menu.h b/wx+/context_menu.h index 2ae85162..ec62852d 100644 --- a/wx+/context_menu.h +++ b/wx+/context_menu.h @@ -17,10 +17,10 @@ A context menu supporting C++11 lambda callbacks! Usage: - ContextMenu menu; - menu.addItem(L"Some Label", [&]{ ...do something... }); -> capture by reference is fine, as long as captured variables have at least scope of ContextMenu::popup()! - ... - menu.popup(wnd); + ContextMenu menu; + menu.addItem(L"Some Label", [&]{ ...do something... }); -> capture by reference is fine, as long as captured variables have at least scope of ContextMenu::popup()! + ... + menu.popup(wnd); */ namespace zen @@ -28,7 +28,7 @@ namespace zen class ContextMenu : private wxEvtHandler { public: - ContextMenu() : menu(zen::make_unique()) {} + ContextMenu() : menu(std::make_unique()) {} void addItem(const wxString& label, const std::function& command, const wxBitmap* bmp = nullptr, bool enabled = true) { -- cgit