X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/9dc44eff0235c5f30940f32ccc6d9d82a236e7d2..88932ec82d048d006cdc81bd309f5e59aee799ac:/src/gtk/toolbar.cpp diff --git a/src/gtk/toolbar.cpp b/src/gtk/toolbar.cpp index 6897592dd9..ee5749277c 100644 --- a/src/gtk/toolbar.cpp +++ b/src/gtk/toolbar.cpp @@ -271,18 +271,15 @@ void wxToolBarTool::SetImage() void wxToolBarTool::CreateDropDown() { gtk_tool_item_set_homogeneous(m_item, false); - GtkWidget* box; - GtkWidget* arrow; + GtkOrientation orient = GTK_ORIENTATION_HORIZONTAL; + GtkArrowType arrowType = GTK_ARROW_DOWN; if (GetToolBar()->HasFlag(wxTB_LEFT | wxTB_RIGHT)) { - box = gtk_vbox_new(false, 0); - arrow = gtk_arrow_new(GTK_ARROW_RIGHT, GTK_SHADOW_NONE); - } - else - { - box = gtk_hbox_new(false, 0); - arrow = gtk_arrow_new(GTK_ARROW_DOWN, GTK_SHADOW_NONE); + orient = GTK_ORIENTATION_VERTICAL; + arrowType = GTK_ARROW_RIGHT; } + GtkWidget* box = gtk_box_new(orient, 0); + GtkWidget* arrow = gtk_arrow_new(arrowType, GTK_SHADOW_NONE); GtkWidget* tool_button = gtk_bin_get_child(GTK_BIN(m_item)); gtk_widget_reparent(tool_button, box); GtkWidget* arrow_button = gtk_toggle_button_new(); @@ -763,7 +760,7 @@ void wxToolBar::SetToolDisabledBitmap( int id, const wxBitmap& bitmap ) wxVisualAttributes wxToolBar::GetClassDefaultAttributes(wxWindowVariant WXUNUSED(variant)) { - return GetDefaultAttributesFromGTKWidget(gtk_toolbar_new); + return GetDefaultAttributesFromGTKWidget(gtk_toolbar_new()); } #endif // wxUSE_TOOLBAR_NATIVE