1 /////////////////////////////////////////////////////////////////////////////
2 // Name: wx/os2/choice.h
3 // Purpose: wxChoice class
4 // Author: David Webster
8 // Copyright: (c) David Webster
9 // Licence: wxWindows licence
10 /////////////////////////////////////////////////////////////////////////////
15 // ----------------------------------------------------------------------------
17 // ----------------------------------------------------------------------------
19 class WXDLLIMPEXP_CORE wxChoice
: public wxChoiceBase
21 DECLARE_DYNAMIC_CLASS(wxChoice
)
28 inline wxChoice( wxWindow
* pParent
30 ,const wxPoint
& rPos
= wxDefaultPosition
31 ,const wxSize
& rSize
= wxDefaultSize
33 ,const wxString asChoices
[] = NULL
35 ,const wxValidator
& rValidator
= wxDefaultValidator
36 ,const wxString
& rsName
= wxChoiceNameStr
51 inline wxChoice( wxWindow
* pParent
55 ,const wxArrayString
& asChoices
57 ,const wxValidator
& rValidator
= wxDefaultValidator
58 ,const wxString
& rsName
= wxChoiceNameStr
72 bool Create( wxWindow
* pParent
74 ,const wxPoint
& rPos
= wxDefaultPosition
75 ,const wxSize
& rSize
= wxDefaultSize
77 ,const wxString asChoices
[] = NULL
79 ,const wxValidator
& rValidator
= wxDefaultValidator
80 ,const wxString
& rsName
= wxChoiceNameStr
83 bool Create( wxWindow
* pParent
87 ,const wxArrayString
& asChoices
89 ,const wxValidator
& rValidator
= wxDefaultValidator
90 ,const wxString
& rsName
= wxChoiceNameStr
94 // Implement base class virtuals
96 virtual void DoDeleteOneItem(unsigned int n
);
97 virtual void DoClear(void);
99 virtual unsigned int GetCount() const;
100 virtual int GetSelection(void) const;
101 virtual void SetSelection(int n
);
103 virtual wxString
GetString(unsigned int n
) const;
104 virtual void SetString(unsigned int n
, const wxString
& rsStr
);
109 virtual bool OS2Command( WXUINT uParam
112 MRESULT
OS2WindowProc( WXUINT uMsg
118 virtual int DoInsertItems(const wxArrayStringsAdapter
& items
,
121 wxClientDataType type
);
123 virtual void DoSetItemClientData(unsigned int n
, void* pClientData
);
124 virtual void* DoGetItemClientData(unsigned int n
) const;
125 virtual wxSize
DoGetBestSize(void) const;
126 virtual void DoSetSize( int nX
130 ,int nsizeFlags
= wxSIZE_AUTO
133 }; // end of CLASS wxChoice
135 #endif // _WX_CHOICE_H_