]> git.saurik.com Git - wxWidgets.git/blobdiff - src/gtk/radiobut.cpp
Print everything by default in non-interactive mode.
[wxWidgets.git] / src / gtk / radiobut.cpp
index 93e92becbb64528184d047804b52f659618ed1bc..9cb0c7fe1694788b43f0d220eeb09e1e2cbbd8c1 100644 (file)
@@ -47,8 +47,6 @@ void gtk_radiobutton_clicked_callback( GtkToggleButton *button, wxRadioButton *r
 // wxRadioButton
 //-----------------------------------------------------------------------------
 
 // wxRadioButton
 //-----------------------------------------------------------------------------
 
-IMPLEMENT_DYNAMIC_CLASS(wxRadioButton,wxControl)
-
 bool wxRadioButton::Create( wxWindow *parent,
                             wxWindowID id,
                             const wxString& label,
 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") );
 
 {
     wxCHECK_RET( m_widget != NULL, wxT("invalid radiobutton") );
 
+    // save the original label
+    wxControlBase::SetLabel(label);
+
     GTKSetLabelForLabel(GTK_LABEL(GTK_BIN(m_widget)->child), label);
 }
 
     GTKSetLabelForLabel(GTK_LABEL(GTK_BIN(m_widget)->child), label);
 }
 
@@ -138,11 +139,14 @@ bool wxRadioButton::GetValue() const
 
 bool wxRadioButton::Enable( bool enable )
 {
 
 bool wxRadioButton::Enable( bool enable )
 {
-    if ( !wxControl::Enable( enable ) )
+    if (!base_type::Enable(enable))
         return false;
 
     gtk_widget_set_sensitive(GTK_BIN(m_widget)->child, enable);
 
         return false;
 
     gtk_widget_set_sensitive(GTK_BIN(m_widget)->child, enable);
 
+    if (enable)
+        GTKFixSensitivity();
+
     return true;
 }
 
     return true;
 }