From 88ff049184c77fd73b60c01f4f831860d2ec5cef Mon Sep 17 00:00:00 2001 From: Julian Smart Date: Sat, 14 Sep 2013 20:46:43 +0000 Subject: [PATCH] Workaround for #15404: wxRichTextCtrl: caret does not disappear when focus is lost (Mac) (briceandre) git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@74807 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775 --- src/richtext/richtextctrl.cpp | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/src/richtext/richtextctrl.cpp b/src/richtext/richtextctrl.cpp index 6915138..e29da0b 100644 --- a/src/richtext/richtextctrl.cpp +++ b/src/richtext/richtextctrl.cpp @@ -4885,6 +4885,15 @@ void wxRichTextCaret::DoDraw(wxDC *dc) void wxRichTextCaret::Notify() { +#ifdef __WXMAC__ + // Workaround for lack of kill focus event in wxOSX + if (m_richTextCtrl && !m_richTextCtrl->HasFocus()) + { + Hide(); + return; + } +#endif + m_flashOn = !m_flashOn; Refresh(); } -- 2.7.4