X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/7ba5a665ac37b67ac1b87a18b2d93dff91fa395e..2d2c394b59407ca3780a92a28ab12f63489c9cb1:/src/gtk1/textctrl.cpp?ds=sidebyside diff --git a/src/gtk1/textctrl.cpp b/src/gtk1/textctrl.cpp index ba3c070bb9..f16643b0c7 100644 --- a/src/gtk1/textctrl.cpp +++ b/src/gtk1/textctrl.cpp @@ -97,11 +97,9 @@ static gint gtk_text_focus_in_callback( GtkWidget *widget, GdkEvent *WXUNUSED(ev g_focusWindow = win; - wxPanel *panel = wxDynamicCast(win->GetParent(), wxPanel); - if (panel) - { - panel->SetLastFocus(win); - } + // notify the parent that we got the focus + wxChildFocusEvent eventFocus(win); + (void)win->GetEventHandler()->ProcessEvent(eventFocus); #ifdef HAVE_XIM if (win->m_ic) @@ -1077,10 +1075,10 @@ void wxTextCtrl::ChangeFontGlobally() wxString value = GetValue(); if ( !value.IsEmpty() ) { + m_updateFont = FALSE; + Clear(); AppendText(value); - - m_updateFont = FALSE; } }