]> git.saurik.com Git - wxWidgets.git/commitdiff
adding edit menu in order to be able to support native edit menu commands (osx)
authorStefan Csomor <csomor@advancedconcepts.ch>
Wed, 16 Feb 2011 18:51:15 +0000 (18:51 +0000)
committerStefan Csomor <csomor@advancedconcepts.ch>
Wed, 16 Feb 2011 18:51:15 +0000 (18:51 +0000)
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@66908 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775

samples/dialogs/dialogs.cpp

index 761144bc8af01ae2eced2c34e4e375c79c4279f0..1c70584b914e446a6fdc5c5a45b08038e60530f6 100644 (file)
@@ -539,8 +539,23 @@ bool MyApp::OnInit()
     menuHelp->Append(DIALOGS_ABOUTDLG_CUSTOM, wxT("About (&custom)...\tCtrl-Shift-F1"));
 #endif // wxUSE_ABOUTDLG
 
+    wxMenu* editMenu = new wxMenu;
+    editMenu->Append(wxID_UNDO, _("&Undo\tCtrl+Z"));
+    editMenu->Append(wxID_REDO, _("&Redo\tCtrl+Y"));
+    editMenu->AppendSeparator();
+    editMenu->Append(wxID_CUT, _("Cu&t\tCtrl+X"));
+    editMenu->Append(wxID_COPY, _("&Copy\tCtrl+C"));
+    editMenu->Append(wxID_PASTE, _("&Paste\tCtrl+V"));
+    editMenu->Append(wxID_CLEAR, _("&Delete"));
+    
+    editMenu->AppendSeparator();
+    editMenu->Append(wxID_SELECTALL, _("Select All\tCtrl+A"));
+
     wxMenuBar *menubar = new wxMenuBar;
     menubar->Append(menuDlg, wxT("&Dialogs"));
+    
+    menubar->Append(editMenu, wxT("&Edit"));
+    
 #if wxUSE_ABOUTDLG
     menubar->Append(menuHelp, wxT("&Help"));
 #endif // wxUSE_ABOUTDLG