]> git.saurik.com Git - wxWidgets.git/blobdiff - src/gtk/control.cpp
floating pane size now restores after perspective restore
[wxWidgets.git] / src / gtk / control.cpp
index 613ed139fa1c74732b1d4eac2d6cf122cf6dcc15..f940e07bdb355389915ca4ca2f7f9650669c9e8f 100644 (file)
@@ -82,7 +82,7 @@ void wxControl::PostCreation(const wxSize& size)
     gtk_widget_ensure_style(m_widget);
 
     ApplyWidgetStyle();
-    SetInitialBestSize(size);
+    SetInitialSize(size);
 }
 
 // ----------------------------------------------------------------------------
@@ -366,4 +366,24 @@ wxControl::GetDefaultAttributesFromGTKWidget(wxGtkWidgetNewFromAdj_t widget_new,
     return attr;
 }
 
+// ----------------------------------------------------------------------------
+// idle handling
+// ----------------------------------------------------------------------------
+
+void wxControl::OnInternalIdle()
+{
+    if ( GtkShowFromOnIdle() )
+        return;
+
+    if ( GTK_WIDGET_REALIZED(m_widget) )
+    {
+        GTKUpdateCursor();
+
+        GTKSetDelayedFocusIfNeeded();
+    }
+
+    if ( wxUpdateUIEvent::CanUpdate(this) )
+        UpdateWindowUI(wxUPDATE_UI_FROMIDLE);
+}
+
 #endif // wxUSE_CONTROLS