+ // Create the main frame window
+ MySecondFrame *frame2 = new MySecondFrame(NULL, _T("Dynamic wxWidgets App"), 150, 150, 450, 340);
+
+ // Show the frame
+ frame2->Show(true);
+
+ SetTopWindow(frame);
+
+ return true;
+}
+
+// -------------------------------------
+// MyFrame
+// -------------------------------------
+
+// Callback from wxShadowObject
+
+int cb_MyFrame_InitStatusbar( void* window, void* WXUNUSED(param) )
+{
+ MyFrame *frame = (MyFrame*) window;
+ frame->SetStatusText( wxT("Hello from MyFrame"), 0 );
+ return 0;
+}
+
+// My frame constructor
+MyFrame::MyFrame(wxFrame *frame, wxChar *title, int x, int y, int w, int h):
+ wxFrame(frame, wxID_ANY, title, wxPoint(x, y), wxSize(w, h))
+{
+ // Give it an icon