]> git.saurik.com Git - wxWidgets.git/blobdiff - src/gtk/textctrl.cpp
Fixed the drawing of the HRules so they don't try to iterate over all
[wxWidgets.git] / src / gtk / textctrl.cpp
index ba3c070bb9b9b529a734bfdccd8d52210d65bd92..f16643b0c74218275e3ac7100832e24fa35324e6 100644 (file)
@@ -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;
     }
 }