X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/345c78ca5fa57ea6c7dc7e6a05496a8e82aa2b50..40aa05e0b8931793f2be33bbf0177048dcd80c1a:/src/richtext/richtextctrl.cpp diff --git a/src/richtext/richtextctrl.cpp b/src/richtext/richtextctrl.cpp index 9f90f65488..e0e80081a1 100644 --- a/src/richtext/richtextctrl.cpp +++ b/src/richtext/richtextctrl.cpp @@ -2663,6 +2663,8 @@ bool wxRichTextCtrl::RecreateBuffer(const wxSize& size) bool wxRichTextCtrl::DoLoadFile(const wxString& filename, int fileType) { + SetFocusObject(& GetBuffer(), true); + bool success = GetBuffer().LoadFile(filename, (wxRichTextFileType)fileType); if (success) m_filename = filename;