X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/f8387e15ee87ab9c37d79308199612a5604c0c8b..27c78e4552aaefac9a4db0d4453eff09cdfef2ad:/src/msw/textctrl.cpp diff --git a/src/msw/textctrl.cpp b/src/msw/textctrl.cpp index 8e6a49e05f..a04437dc77 100644 --- a/src/msw/textctrl.cpp +++ b/src/msw/textctrl.cpp @@ -13,10 +13,6 @@ // declarations // ============================================================================ -#if defined(__GNUG__) && !defined(NO_GCC_PRAGMA) - #pragma implementation "textctrl.h" -#endif - // ---------------------------------------------------------------------------- // headers // ---------------------------------------------------------------------------- @@ -965,7 +961,8 @@ void wxTextCtrl::DoWriteText(const wxString& value, bool selectionOnly) UpdatesCountFilter ucf(m_updatesCount); ::SendMessage(GetHwnd(), selectionOnly ? EM_REPLACESEL : WM_SETTEXT, - 0, (LPARAM)valueDos.c_str()); + // EM_REPLACESEL takes 1 to indicate the operation should be redoable + selectionOnly ? 1 : 0, (LPARAM)valueDos.c_str()); if ( !ucf.GotUpdate() ) { @@ -1776,6 +1773,7 @@ void wxTextCtrl::OnChar(wxKeyEvent& event) // Insert tab since calling the default Windows handler // doesn't seem to do it WriteText(wxT("\t")); + return; } break; }