]>
git.saurik.com Git - wxWidgets.git/blob - src/qt/radiobut.cpp
   1 ///////////////////////////////////////////////////////////////////////////// 
   3 // Purpose:     wxRadioButton 
   8 // Copyright:   (c) AUTHOR 
   9 // Licence:     wxWindows licence 
  10 ///////////////////////////////////////////////////////////////////////////// 
  13 #pragma implementation "radiobut.h" 
  16 #include "wx/radiobut.h" 
  18 IMPLEMENT_DYNAMIC_CLASS(wxRadioButton
, wxControl
) 
  20 bool wxRadioButton::Create(wxWindow 
*parent
, wxWindowID id
, 
  21                    const wxString
& label
, 
  23            const wxSize
& size
, long style
, 
  24            const wxValidator
& validator
, 
  28     SetValidator(validator
); 
  30     if (parent
) parent
->AddChild(this); 
  33             m_windowId 
= (int)NewControlId(); 
  37     m_windowStyle 
= style 
; 
  39     // TODO create radiobutton 
  43 void wxRadioButton::SetLabel(const wxString
& label
) 
  48 void wxRadioButton::SetValue(bool value
) 
  53 // Get single selection, for single choice list items 
  54 bool wxRadioButton::GetValue() const 
  60 void wxRadioButton::Command (wxCommandEvent 
& event
) 
  62   SetValue ( (event
.m_commandInt 
!= 0) ); 
  63   ProcessCommand (event
);