]> git.saurik.com Git - wxWidgets.git/blobdiff - src/msw/textctrl.cpp
detect EOF properly in wxFileInputStream
[wxWidgets.git] / src / msw / textctrl.cpp
index f40f6c861b034e9301e1992ba3f2e750b67b83c8..3824a797f4c310e5275900de3a40ba85556efe40 100644 (file)
@@ -678,7 +678,10 @@ void wxTextCtrl::DoWriteText(const wxString& value, bool selectionOnly)
     {
         if ( !selectionOnly )
         {
-            SetSelection(-1, -1);
+            //SetSelection(-1, -1);
+            // This eliminates an annoying flashing effect
+            // when replacing all text.
+            Clear();
         }
 
         ::SendMessage(GetHwnd(), EM_REPLACESEL, 0, (LPARAM)valueDos.c_str());