]> git.saurik.com Git - wxWidgets.git/blobdiff - contrib/samples/deprecated/resource/resource.cpp
Bumping the version number also requires that version.h be modified,
[wxWidgets.git] / contrib / samples / deprecated / resource / resource.cpp
index 4aaf51eca0f18b6828a5e355e3e4f92d5345ba01..7d0bb7b9c8cb3bd4b0ded3a1b5728b13b3e2f810 100644 (file)
@@ -9,10 +9,6 @@
 // Licence:     wxWindows license
 /////////////////////////////////////////////////////////////////////////////
 
-#ifdef __GNUG__
-// #pragma implementation
-#endif
-
 // For compilers that support precompilation, includes "wx/wx.h".
 #include "wx/wxprec.h"
 
@@ -103,12 +99,14 @@ bool MyApp::OnInit(void)
 #endif
 
     // Create the main frame window
-    frame = new MyFrame( (wxFrame *) NULL, -1,
+    frame = new MyFrame( (wxFrame *) NULL, wxID_ANY,
                          wxT("wxWidgets Resource Sample"),
-                         wxPoint(-1, -1), wxSize(300, 250) );
+                         wxDefaultPosition, wxSize(300, 250) );
 
+#if wxUSE_STATUSBAR
     // Give it a status line
     frame->CreateStatusBar(2);
+#endif // wxUSE_STATUSBAR
 
     wxMenuBar *menu_bar = wxResourceCreateMenuBar(wxT("menu1"));
 
@@ -116,13 +114,13 @@ bool MyApp::OnInit(void)
     frame->SetMenuBar(menu_bar);
 
     // Make a panel
-    frame->panel = new MyPanel( frame, -1, wxPoint(0, 0), wxSize(400, 400),
+    frame->panel = new MyPanel( frame, wxID_ANY, wxPoint(0, 0), wxSize(400, 400),
                                 0, wxT("MyMainFrame") );
-    frame->Show(TRUE);
+    frame->Show(true);
 
     SetTopWindow(frame);
 
-    return TRUE;
+    return true;
 }
 
 MyApp::~MyApp()
@@ -179,7 +177,7 @@ void MyFrame::OnAbout( wxCommandEvent& WXUNUSED(event) )
 
 void MyFrame::OnQuit( wxCommandEvent& WXUNUSED(event) )
 {
-    Close(TRUE);
+    Close(true);
 }
 
 void MyFrame::OnTestDialog(wxCommandEvent& WXUNUSED(event) )
@@ -197,7 +195,7 @@ void MyFrame::OnTestDialog(wxCommandEvent& WXUNUSED(event) )
         dialog->ShowModal();
     }
 
-    dialog->Close(TRUE);
+    dialog->Close(true);
 }
 
 BEGIN_EVENT_TABLE(MyDialog, wxDialog)