1 ///////////////////////////////////////////////////////////////////////////// 
   3 // Purpose:     wxRadioButton class 
   4 // Author:      Stefan Csomor 
   8 // Copyright:   (c) Stefan Csomor 
   9 // Licence:     wxWindows licence 
  10 ///////////////////////////////////////////////////////////////////////////// 
  12 #ifndef _WX_RADIOBUT_H_ 
  13 #define _WX_RADIOBUT_H_ 
  15 #if defined(__GNUG__) && !defined(NO_GCC_PRAGMA) 
  16 #pragma interface "radiobut.h" 
  19 class WXDLLEXPORT wxRadioButton
: public wxControl
 
  21   DECLARE_DYNAMIC_CLASS(wxRadioButton
) 
  24     inline wxRadioButton() {} 
  25     inline wxRadioButton(wxWindow 
*parent
, wxWindowID id
, 
  26            const wxString
& label
, 
  27            const wxPoint
& pos 
= wxDefaultPosition
, 
  28            const wxSize
& size 
= wxDefaultSize
, long style 
= 0, 
  29            const wxValidator
& validator 
= wxDefaultValidator
, 
  30            const wxString
& name 
= wxRadioButtonNameStr
) 
  32         Create(parent
, id
, label
, pos
, size
, style
, validator
, name
); 
  35     bool Create(wxWindow 
*parent
, wxWindowID id
, 
  36            const wxString
& label
, 
  37            const wxPoint
& pos 
= wxDefaultPosition
, 
  38            const wxSize
& size 
= wxDefaultSize
, long style 
= 0, 
  39            const wxValidator
& validator 
= wxDefaultValidator
, 
  40            const wxString
& name 
= wxRadioButtonNameStr
); 
  42     virtual void SetValue(bool val
); 
  43     virtual bool GetValue() const ; 
  47       virtual void MacHandleControlClick( WXWidget control 
, wxInt16 controlpart 
, bool mouseStillDown 
);  
  48     void Command(wxCommandEvent
& event
); 
  49     wxRadioButton 
*AddInCycle(wxRadioButton 
*cycle
); 
  50     inline wxRadioButton 
*NextInCycle() {return m_cycle
;} 
  54     wxRadioButton 
*m_cycle
; 
  59 class WXDLLEXPORT wxBitmap 
; 
  61 WXDLLEXPORT_DATA(extern const char*) wxBitmapRadioButtonNameStr
; 
  63 class WXDLLEXPORT wxBitmapRadioButton
: public wxRadioButton
 
  65   DECLARE_DYNAMIC_CLASS(wxBitmapRadioButton
) 
  67   wxBitmap 
*theButtonBitmap
; 
  69   inline wxBitmapRadioButton() { theButtonBitmap 
= NULL
; } 
  70   inline wxBitmapRadioButton(wxWindow 
*parent
, wxWindowID id
, 
  71            const wxBitmap 
*label
, 
  72            const wxPoint
& pos 
= wxDefaultPosition
, 
  73            const wxSize
& size 
= wxDefaultSize
, long style 
= 0, 
  74            const wxValidator
& validator 
= wxDefaultValidator
, 
  75            const wxString
& name 
= wxBitmapRadioButtonNameStr
) 
  77       Create(parent
, id
, label
, pos
, size
, style
, validator
, name
); 
  80   bool Create(wxWindow 
*parent
, wxWindowID id
, 
  81            const wxBitmap 
*label
, 
  82            const wxPoint
& pos 
= wxDefaultPosition
, 
  83            const wxSize
& size 
= wxDefaultSize
, long style 
= 0, 
  84            const wxValidator
& validator 
= wxDefaultValidator
, 
  85            const wxString
& name 
= wxBitmapRadioButtonNameStr
); 
  87   virtual void SetLabel(const wxBitmap 
*label
); 
  88   virtual void SetValue(bool val
) ; 
  89   virtual bool GetValue() const ;