]> git.saurik.com Git - wxWidgets.git/blobdiff - src/gtk/radiobut.cpp
In wxComboCtrlBase::DrawButton(), let the button background rendering changes also...
[wxWidgets.git] / src / gtk / radiobut.cpp
index 49590debfb527425757019879626b05b7fa147a6..d5c28e4574801bcc9e39f0a0ac35db15f9ca7afc 100644 (file)
@@ -1,5 +1,5 @@
 /////////////////////////////////////////////////////////////////////////////
-// Name:        radiobut.cpp
+// Name:        src/gtk/radiobut.cpp
 // Purpose:
 // Author:      Robert Roebling
 // Id:          $Id$
@@ -47,8 +47,6 @@ void gtk_radiobutton_clicked_callback( GtkToggleButton *button, wxRadioButton *r
 // wxRadioButton
 //-----------------------------------------------------------------------------
 
-IMPLEMENT_DYNAMIC_CLASS(wxRadioButton,wxControl)
-
 bool wxRadioButton::Create( wxWindow *parent,
                             wxWindowID id,
                             const wxString& label,
@@ -101,6 +99,9 @@ void wxRadioButton::SetLabel( const wxString& label )
 {
     wxCHECK_RET( m_widget != NULL, wxT("invalid radiobutton") );
 
+    // save the original label
+    wxControlBase::SetLabel(label);
+
     GTKSetLabelForLabel(GTK_LABEL(GTK_BIN(m_widget)->child), label);
 }
 
@@ -123,8 +124,6 @@ void wxRadioButton::SetValue( bool val )
         // should give an assert
         // RL - No it shouldn't.  A wxGenericValidator might try to set it
         //      as FALSE.  Failing silently is probably TRTTD here.
-        // RR - MSW actually unchecks the radio button so do this here, too
-        gtk_toggle_button_set_active( GTK_TOGGLE_BUTTON(m_widget), FALSE );
     }
 
     g_signal_handlers_unblock_by_func(