]> git.saurik.com Git - wxWidgets.git/blobdiff - src/gtk/tbargtk.cpp
switching to preemptive implementation (from mpthread.cpp)
[wxWidgets.git] / src / gtk / tbargtk.cpp
index 4755e17a0e16c75c2aca7d42daf8d82f878bd9ff..3360929f68c4371d596ec600209d5fc77c4b856e 100644 (file)
@@ -373,9 +373,7 @@ bool wxToolBar::Create( wxWindow *parent,
 
     m_parent->DoAddChild( this );
 
-    PostCreation();
-
-    Show( TRUE );
+    PostCreation(size);
 
     return TRUE;
 }
@@ -705,4 +703,22 @@ void wxToolBar::OnInternalIdle()
         UpdateWindowUI(wxUPDATE_UI_FROMIDLE);
 }
 
+
+// ----------------------------------------------------------------------------
+
+// static
+wxVisualAttributes
+wxToolBar::GetClassDefaultAttributes(wxWindowVariant WXUNUSED(variant))
+{
+#ifdef __WXGTK20__
+    return GetDefaultAttributesFromGTKWidget(gtk_toolbar_new);
+#else
+    wxVisualAttributes attr;
+    GtkWidget* widget = gtk_toolbar_new(GTK_ORIENTATION_HORIZONTAL, GTK_TOOLBAR_BOTH);
+    attr = GetDefaultAttributesFromGTKWidget(widget);
+    gtk_widget_destroy(widget);
+    return attr;
+#endif
+}
+
 #endif // wxUSE_TOOLBAR_NATIVE