]> git.saurik.com Git - wxWidgets.git/blobdiff - samples/display/display.cpp
Give spin button the same height as the associated text control
[wxWidgets.git] / samples / display / display.cpp
index 7ee089971d09884481c85f981437e7910e74bcc0..456f75f97ef74f969b8610577f5f4615f22a3547 100644 (file)
@@ -167,6 +167,9 @@ IMPLEMENT_APP(MyApp)
 // 'Main program' equivalent: the program execution "starts" here
 bool MyApp::OnInit()
 {
+    if ( !wxApp::OnInit() )
+        return false;
+
 #ifdef __WXMSW__
     if ( argc == 2 && !wxStricmp(argv[1],  _T("/dx")) )
     {
@@ -310,7 +313,6 @@ MyFrame::MyFrame(const wxString& title, const wxPoint& pos, const wxSize& size,
     wxBoxSizer *sizer = new wxBoxSizer(wxHORIZONTAL);
     sizer->Add(m_book, 1, wxEXPAND);
     panel->SetSizer(sizer);
-    sizer->Fit(this);
     sizer->SetSizeHints(this);
 }