]> git.saurik.com Git - wxWidgets.git/commitdiff
Make stc sample startup faster.
authorVadim Zeitlin <vadim@wxwidgets.org>
Sun, 30 Sep 2012 22:26:36 +0000 (22:26 +0000)
committerVadim Zeitlin <vadim@wxwidgets.org>
Sun, 30 Sep 2012 22:26:36 +0000 (22:26 +0000)
Don't show "About" dialog on startup, this has nothing to do with the purpose
of this sample and is just annoying.

Also, don't select the entire file after opening it.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72592 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775

samples/stc/stctest.cpp

index ff590d1b12ae66547eaed135a50454540ffc6481..599722d1519e5af2483084d984c4e95e04ae356b 100644 (file)
@@ -318,9 +318,6 @@ AppFrame::AppFrame (const wxString &title)
     SetTitle (*g_appname);
     SetBackgroundColour (wxT("WHITE"));
 
-    // about box shown for 1 seconds
-    AppAbout dlg(this, 1000);
-
     // create menu
     m_menuBar = new wxMenuBar;
     CreateMenu ();
@@ -330,7 +327,6 @@ AppFrame::AppFrame (const wxString &title)
     m_edit->SetFocus();
 
     FileOpen (wxT("stctest.cpp"));
-    m_edit->SetSelection(0,0);
 }
 
 AppFrame::~AppFrame () {
@@ -588,6 +584,7 @@ void AppFrame::FileOpen (wxString fname)
 {
     wxFileName w(fname); w.Normalize(); fname = w.GetFullPath();
     m_edit->LoadFile (fname);
+    m_edit->SelectNone();
 }
 
 wxRect AppFrame::DeterminePrintSize () {