X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/abdeb9e7006488bf917d90048fcd0cbe22f44a71..f5f3247dcc3a65b5018f5b8843f139ae6b6e6bd2:/src/gtk1/radiobut.cpp?ds=sidebyside diff --git a/src/gtk1/radiobut.cpp b/src/gtk1/radiobut.cpp index 1fd39b77fb..2c3e1c0d10 100644 --- a/src/gtk1/radiobut.cpp +++ b/src/gtk1/radiobut.cpp @@ -187,11 +187,10 @@ bool wxRadioButton::Enable( bool enable ) return TRUE; } -void wxRadioButton::ApplyWidgetStyle() +void wxRadioButton::DoApplyWidgetStyle(GtkRcStyle *style) { - SetWidgetStyle(); - gtk_widget_set_style( m_widget, m_widgetStyle ); - gtk_widget_set_style( BUTTON_CHILD(m_widget), m_widgetStyle ); + gtk_widget_modify_style(m_widget, style); + gtk_widget_modify_style(BUTTON_CHILD(m_widget), style); } bool wxRadioButton::IsOwnGtkWindow( GdkWindow *window ) @@ -233,4 +232,16 @@ wxSize wxRadioButton::DoGetBestSize() const return wxControl::DoGetBestSize(); } +// static +wxVisualAttributes +wxRadioButton::GetClassDefaultAttributes(wxWindowVariant WXUNUSED(variant)) +{ + wxVisualAttributes attr; + GtkWidget* widget = gtk_radio_button_new_with_label(NULL, ""); + attr = GetDefaultAttributesFromGTKWidget(widget); + gtk_widget_destroy(widget); + return attr; +} + + #endif