X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/ae53c98c9f71acb0876846b9c5b1e56adfdb6186..1d61ebaca18624cadf455a8859c1d089db5e6a23:/samples/minimal/minimal.cpp diff --git a/samples/minimal/minimal.cpp b/samples/minimal/minimal.cpp index 945e2d8dc8..93536a6b4d 100644 --- a/samples/minimal/minimal.cpp +++ b/samples/minimal/minimal.cpp @@ -70,6 +70,8 @@ public: void OnQuit(wxCommandEvent& event); void OnAbout(wxCommandEvent& event); + void OnPaint(wxPaintEvent& event); + private: // any class wishing to process wxWindows events must use this macro DECLARE_EVENT_TABLE() @@ -85,11 +87,6 @@ enum // menu items Minimal_Quit = 1, Minimal_About, - Minimal_Test1, - Minimal_Test2, - - // controls start here (the numbers are, of course, arbitrary) - Minimal_Text = 1000, }; // ---------------------------------------------------------------------------- @@ -149,7 +146,7 @@ MyFrame::MyFrame(const wxString& title, const wxPoint& pos, const wxSize& size) SetIcon(wxICON(mondrian)); // create a menu bar - wxMenu *menuFile = new wxMenu("File",NULL,wxMENU_TEAROFF); + wxMenu *menuFile = new wxMenu("", wxMENU_TEAROFF); menuFile->Append(Minimal_About, "&About...\tCtrl-A", "Show about dialog"); menuFile->AppendSeparator(); @@ -162,9 +159,11 @@ MyFrame::MyFrame(const wxString& title, const wxPoint& pos, const wxSize& size) // ... and attach this menu bar to the frame SetMenuBar(menuBar); +#if wxUSE_STATUSBAR // create a status bar just for fun (by default with 1 pane only) CreateStatusBar(2); SetStatusText("Welcome to wxWindows!"); +#endif // wxUSE_STATUSBAR } @@ -192,3 +191,4 @@ void MyFrame::OnAbout(wxCommandEvent& WXUNUSED(event)) wxMessageBox(msg, "About Minimal", wxOK | wxICON_INFORMATION, this); } +