fix for handling (Shift-)Ctrl-Tab when the notebook itself has focus (patch 813507)
[wxWidgets.git] / src / os2 / textctrl.cpp
index 3b2b97719ae88dcd3cc30684b3c86ecc72de1200..9efd84b6e8c1700531e3699a010f5aa4261faf74 100644 (file)
@@ -507,6 +507,15 @@ void wxTextCtrl::SetInsertionPointEnd()
 {
     long                            lPos = GetLastPosition();
 
+    //
+    // We must not do anything if the caret is already there because calling
+    // SetInsertionPoint() thaws the controls if Freeze() had been called even
+    // if it doesn't actually move the caret anywhere and so the simple fact of
+    // doing it results in horrible flicker when appending big amounts of text
+    // to the control in a few chunks (see DoAddText() test in the text sample)
+    //
+    if (GetInsertionPoint() == GetLastPosition())
+        return;
     SetInsertionPoint(lPos);
 } // end of wxTextCtrl::SetInsertionPointEnd
 
@@ -701,6 +710,11 @@ bool wxTextCtrl::IsModified() const
     return bRc;
 } // end of wxTextCtrl::IsModified
 
+void wxTextCtrl::MarkDirty()
+{
+    wxFAIL_MSG( _T("not implemented") );
+}
+
 //
 // Makes 'unmodified'
 //