]> git.saurik.com Git - wxWidgets.git/blob - include/wx/cocoa/radiobox.h
added wxMAKE_UNIQUE_NAME to wx/defs.h, use it in wx/debug.h
[wxWidgets.git] / include / wx / cocoa / radiobox.h
1 /////////////////////////////////////////////////////////////////////////////
2 // Name: wx/cocoa/radiobox.h
3 // Purpose: wxRadioBox class
4 // Author: David Elliott
5 // Modified by:
6 // Created: 2003/03/18
7 // RCS-ID: $Id:
8 // Copyright: (c) 2003 David Elliott
9 // Licence: wxWindows license
10 /////////////////////////////////////////////////////////////////////////////
11
12 #ifndef __WX_COCOA_RADIOBOX_H__
13 #define __WX_COCOA_RADIOBOX_H__
14
15 // #include "wx/cocoa/NSButton.h"
16
17 // ========================================================================
18 // wxRadioBox
19 // ========================================================================
20 class WXDLLEXPORT wxRadioBox: public wxControl, public wxRadioBoxBase// , protected wxCocoaNSButton
21 {
22 DECLARE_DYNAMIC_CLASS(wxRadioBox)
23 DECLARE_EVENT_TABLE()
24 // WX_DECLARE_COCOA_OWNER(NSButton,NSControl,NSView)
25 // ------------------------------------------------------------------------
26 // initialization
27 // ------------------------------------------------------------------------
28 public:
29 wxRadioBox() { }
30 wxRadioBox(wxWindow *parent, wxWindowID winid,
31 const wxString& title,
32 const wxPoint& pos = wxDefaultPosition,
33 const wxSize& size = wxDefaultSize,
34 int n = 0, const wxString choices[] = NULL,
35 int majorDim = 0,
36 long style = 0, const wxValidator& validator = wxDefaultValidator,
37 const wxString& name = wxRadioBoxNameStr)
38 {
39 Create(parent, winid, title, pos, size, n, choices, majorDim, style, validator, name);
40 }
41
42 bool Create(wxWindow *parent, wxWindowID winid,
43 const wxString& title,
44 const wxPoint& pos = wxDefaultPosition,
45 const wxSize& size = wxDefaultSize,
46 int n = 0, const wxString choices[] = NULL,
47 int majorDim = 0,
48 long style = 0,
49 const wxValidator& validator = wxDefaultValidator,
50 const wxString& name = wxRadioBoxNameStr);
51 virtual ~wxRadioBox();
52
53 // ------------------------------------------------------------------------
54 // Cocoa callbacks
55 // ------------------------------------------------------------------------
56 protected:
57 // ------------------------------------------------------------------------
58 // Implementation
59 // ------------------------------------------------------------------------
60 public:
61 // Pure virtuals
62 // selection
63 virtual void SetSelection(int n);
64 virtual int GetSelection() const;
65 // string access
66 virtual int GetCount() const;
67 virtual wxString GetString(int n) const;
68 virtual void SetString(int n, const wxString& label);
69 // change the individual radio button state
70 virtual void Enable(int n, bool enable = TRUE);
71 virtual void Show(int n, bool show = TRUE);
72 // layout parameters
73 virtual int GetColumnCount() const;
74 virtual int GetRowCount() const;
75 };
76
77 #endif // __WX_COCOA_RADIOBOX_H__