]> git.saurik.com Git - wxWidgets.git/blame - include/wx/mac/carbon/checklst.h
correct access for virtuals
[wxWidgets.git] / include / wx / mac / carbon / checklst.h
CommitLineData
8cf73271 1///////////////////////////////////////////////////////////////////////////////
aa61d352 2// Name: wx/mac/carbon/checklst.h
8cf73271
SC
3// Purpose: wxCheckListBox class - a listbox with checkable items
4// Note: this is an optional class.
5// Author: Stefan Csomor
6// Modified by:
7// Created: 1998-01-01
8// RCS-ID: $Id$
9// Copyright: (c) Stefan Csomor
65571936 10// Licence: wxWindows licence
8cf73271
SC
11///////////////////////////////////////////////////////////////////////////////
12
13#ifndef _WX_CHECKLST_H_
14#define _WX_CHECKLST_H_
15
ca923098
SC
16class wxMacCheckListControl
17{
18public :
19 virtual bool MacIsChecked(unsigned int n) const = 0;
20 virtual void MacCheck(unsigned int n, bool bCheck = true) = 0;
21};
22
8cf73271
SC
23class WXDLLEXPORT wxCheckListBox : public wxCheckListBoxBase
24{
25 DECLARE_DYNAMIC_CLASS(wxCheckListBox)
26public:
27 // ctors
28 wxCheckListBox() { Init(); }
29 wxCheckListBox(wxWindow *parent,
30 wxWindowID id,
31 const wxPoint& pos = wxDefaultPosition,
32 const wxSize& size = wxDefaultSize,
33 int nStrings = 0,
34 const wxString *choices = NULL,
35 long style = 0,
36 const wxValidator& validator = wxDefaultValidator,
37 const wxString& name = wxListBoxNameStr)
38 {
39 Init();
40
41 Create(parent, id, pos, size, nStrings, choices, style, validator, name);
42 }
43 wxCheckListBox(wxWindow *parent,
44 wxWindowID id,
45 const wxPoint& pos,
46 const wxSize& size,
47 const wxArrayString& choices,
48 long style = 0,
49 const wxValidator& validator = wxDefaultValidator,
50 const wxString& name = wxListBoxNameStr)
51 {
52 Init();
53
54 Create(parent, id, pos, size, choices, style, validator, name);
55 }
56
57 bool Create(wxWindow *parent,
58 wxWindowID id,
59 const wxPoint& pos = wxDefaultPosition,
60 const wxSize& size = wxDefaultSize,
61 int nStrings = 0,
62 const wxString *choices = NULL,
63 long style = 0,
64 const wxValidator& validator = wxDefaultValidator,
65 const wxString& name = wxListBoxNameStr);
66 bool Create(wxWindow *parent,
67 wxWindowID id,
68 const wxPoint& pos,
69 const wxSize& size,
70 const wxArrayString& choices,
71 long style = 0,
72 const wxValidator& validator = wxDefaultValidator,
73 const wxString& name = wxListBoxNameStr);
74
19de24fe 75 // items may be checked
aa61d352
VZ
76 bool IsChecked(unsigned int uiIndex) const;
77 void Check(unsigned int uiIndex, bool bCheck = true);
8cf73271 78
ca923098 79 wxMacCheckListControl* GetPeer() const;
19de24fe 80
8cf73271 81protected:
8cf73271
SC
82 void Init();
83private:
19de24fe
SC
84
85 DECLARE_EVENT_TABLE()
8cf73271
SC
86};
87
88#endif
89 // _WX_CHECKLST_H_