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 class WXDLLEXPORT wxRadioButton
: public wxControl
17 DECLARE_DYNAMIC_CLASS(wxRadioButton
)
20 inline wxRadioButton() {}
21 inline wxRadioButton(wxWindow
*parent
, wxWindowID id
,
22 const wxString
& label
,
23 const wxPoint
& pos
= wxDefaultPosition
,
24 const wxSize
& size
= wxDefaultSize
, long style
= 0,
25 const wxValidator
& validator
= wxDefaultValidator
,
26 const wxString
& name
= wxRadioButtonNameStr
)
28 Create(parent
, id
, label
, pos
, size
, style
, validator
, name
);
31 bool Create(wxWindow
*parent
, wxWindowID id
,
32 const wxString
& label
,
33 const wxPoint
& pos
= wxDefaultPosition
,
34 const wxSize
& size
= wxDefaultSize
, long style
= 0,
35 const wxValidator
& validator
= wxDefaultValidator
,
36 const wxString
& name
= wxRadioButtonNameStr
);
38 virtual void SetValue(bool val
);
39 virtual bool GetValue() const ;
43 virtual void MacHandleControlClick( WXWidget control
, wxInt16 controlpart
, bool mouseStillDown
);
44 void Command(wxCommandEvent
& event
);
45 wxRadioButton
*AddInCycle(wxRadioButton
*cycle
);
46 inline wxRadioButton
*NextInCycle() {return m_cycle
;}
50 wxRadioButton
*m_cycle
;
55 class WXDLLEXPORT wxBitmap
;
57 WXDLLEXPORT_DATA(extern const char*) wxBitmapRadioButtonNameStr
;
59 class WXDLLEXPORT wxBitmapRadioButton
: public wxRadioButton
61 DECLARE_DYNAMIC_CLASS(wxBitmapRadioButton
)
63 wxBitmap
*theButtonBitmap
;
65 inline wxBitmapRadioButton() { theButtonBitmap
= NULL
; }
66 inline wxBitmapRadioButton(wxWindow
*parent
, wxWindowID id
,
67 const wxBitmap
*label
,
68 const wxPoint
& pos
= wxDefaultPosition
,
69 const wxSize
& size
= wxDefaultSize
, long style
= 0,
70 const wxValidator
& validator
= wxDefaultValidator
,
71 const wxString
& name
= wxBitmapRadioButtonNameStr
)
73 Create(parent
, id
, label
, pos
, size
, style
, validator
, name
);
76 bool Create(wxWindow
*parent
, wxWindowID id
,
77 const wxBitmap
*label
,
78 const wxPoint
& pos
= wxDefaultPosition
,
79 const wxSize
& size
= wxDefaultSize
, long style
= 0,
80 const wxValidator
& validator
= wxDefaultValidator
,
81 const wxString
& name
= wxBitmapRadioButtonNameStr
);
83 virtual void SetLabel(const wxBitmap
*label
);
84 virtual void SetValue(bool val
) ;
85 virtual bool GetValue() const ;