]>
Commit | Line | Data |
---|---|---|
c801d85f | 1 | ///////////////////////////////////////////////////////////////////////////// |
6b0d8a01 | 2 | // Name: wx/gtk/radiobut.h |
c801d85f KB |
3 | // Purpose: |
4 | // Author: Robert Roebling | |
f96aa4d9 RR |
5 | // Id: $Id$ |
6 | // Copyright: (c) 1998 Robert Roebling | |
6b0d8a01 | 7 | // Licence: wxWindows licence |
c801d85f KB |
8 | ///////////////////////////////////////////////////////////////////////////// |
9 | ||
10 | ||
11 | #ifndef __GTKRADIOBUTTONH__ | |
12 | #define __GTKRADIOBUTTONH__ | |
13 | ||
12028905 | 14 | #if defined(__GNUG__) && !defined(NO_GCC_PRAGMA) |
c801d85f KB |
15 | #pragma interface |
16 | #endif | |
17 | ||
6de97a3b RR |
18 | //----------------------------------------------------------------------------- |
19 | // wxRadioButton | |
20 | //----------------------------------------------------------------------------- | |
21 | ||
22 | class wxRadioButton: public wxControl | |
23 | { | |
953704c1 | 24 | public: |
2b4f3c9f VZ |
25 | wxRadioButton() { } |
26 | wxRadioButton( wxWindow *parent, | |
27 | wxWindowID id, | |
28 | const wxString& label, | |
29 | const wxPoint& pos = wxDefaultPosition, | |
30 | const wxSize& size = wxDefaultSize, | |
31 | long style = 0, | |
32 | const wxValidator& validator = wxDefaultValidator, | |
33 | const wxString& name = wxRadioButtonNameStr ) | |
2f073eb2 RR |
34 | { |
35 | Create( parent, id, label, pos, size, style, validator, name ); | |
36 | } | |
2b4f3c9f VZ |
37 | |
38 | bool Create( wxWindow *parent, | |
39 | wxWindowID id, | |
40 | const wxString& label, | |
41 | const wxPoint& pos = wxDefaultPosition, | |
42 | const wxSize& size = wxDefaultSize, | |
43 | long style = 0, | |
44 | const wxValidator& validator = wxDefaultValidator, | |
45 | const wxString& name = wxRadioButtonNameStr ); | |
46 | ||
2f073eb2 RR |
47 | virtual void SetLabel(const wxString& label); |
48 | virtual void SetValue(bool val); | |
49 | virtual bool GetValue() const; | |
6b0d8a01 | 50 | virtual bool Enable( bool enable = TRUE ); |
2b4f3c9f VZ |
51 | |
52 | // implementation | |
53 | ||
54 | virtual bool IsRadioButton() const { return TRUE; } | |
55 | ||
2f073eb2 RR |
56 | GSList *m_radioButtonGroup; |
57 | void ApplyWidgetStyle(); | |
58 | bool IsOwnGtkWindow( GdkWindow *window ); | |
59 | void OnInternalIdle(); | |
2b4f3c9f | 60 | |
9864c56d | 61 | bool m_blockEvent; |
2b4f3c9f | 62 | |
db434467 RR |
63 | protected: |
64 | virtual wxSize DoGetBestSize() const; | |
65 | ||
2f073eb2 RR |
66 | private: |
67 | DECLARE_DYNAMIC_CLASS(wxRadioButton) | |
6de97a3b | 68 | }; |
c801d85f KB |
69 | |
70 | #endif // __GTKRADIOBUTTONH__ |