X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/9ff9d30c0aab3b281ef9b380eac17435556c5088..8ba80c6f8325e61de2e3fc4bbd7cf3d750f432cd:/src/gtk/button.cpp diff --git a/src/gtk/button.cpp b/src/gtk/button.cpp index 331298c383..fabe9a234f 100644 --- a/src/gtk/button.cpp +++ b/src/gtk/button.cpp @@ -242,9 +242,11 @@ void wxButton::DoApplyWidgetStyle(GtkRcStyle *style) GtkWidget *box = GTK_BIN(child)->child; if ( GTK_IS_BOX(box) ) { - GList *items = gtk_container_get_children(GTK_CONTAINER(box)); - for ( GList *item = items; item; item = item->next ) - gtk_widget_modify_style(GTK_WIDGET(item->data), style); + for (GList* item = GTK_BOX(box)->children; item; item = item->next) + { + GtkBoxChild* boxChild = static_cast(item->data); + gtk_widget_modify_style(boxChild->widget, style); + } } } }