]> git.saurik.com Git - wxWidgets.git/blame - include/wx/os2/choice.h
Applied patch [ 619705 ] Fixes wxApp::GetComCtl32Version
[wxWidgets.git] / include / wx / os2 / choice.h
CommitLineData
0e320a79
DW
1/////////////////////////////////////////////////////////////////////////////
2// Name: choice.h
3// Purpose: wxChoice class
37f214d5 4// Author: David Webster
0e320a79 5// Modified by:
37f214d5 6// Created: 10/13/99
0e320a79 7// RCS-ID: $Id$
37f214d5
DW
8// Copyright: (c) David Webster
9// Licence: wxWindows licence
0e320a79
DW
10/////////////////////////////////////////////////////////////////////////////
11
12#ifndef _WX_CHOICE_H_
13#define _WX_CHOICE_H_
14
0e320a79 15// Choice item
409c9842 16class WXDLLEXPORT wxChoice: public wxChoiceBase
0e320a79
DW
17{
18 DECLARE_DYNAMIC_CLASS(wxChoice)
19
dcd307ee
DW
20public:
21 // ctors
22 inline wxChoice() { }
0e320a79 23
fb49f3b3
DW
24 inline wxChoice( wxWindow* pParent
25 ,wxWindowID vId
26 ,const wxPoint& rPos = wxDefaultPosition
27 ,const wxSize& rSize = wxDefaultSize
28 ,int n = 0
29 ,const wxString asChoices[] = NULL
30 ,long lStyle = 0
fb49f3b3 31 ,const wxValidator& rValidator = wxDefaultValidator
fb49f3b3
DW
32 ,const wxString& rsName = wxChoiceNameStr
33 )
dcd307ee 34 {
fb49f3b3
DW
35 Create( pParent
36 ,vId
37 ,rPos
38 ,rSize
39 ,n
40 ,asChoices
41 ,lStyle
fb49f3b3 42 ,rValidator
fb49f3b3
DW
43 ,rsName
44 );
dcd307ee 45 }
0e320a79 46
fb49f3b3
DW
47 bool Create( wxWindow* pParent
48 ,wxWindowID vId
49 ,const wxPoint& rPos = wxDefaultPosition
50 ,const wxSize& rSize = wxDefaultSize
51 ,int n = 0
52 ,const wxString asChoices[] = NULL
53 ,long lStyle = 0
fb49f3b3 54 ,const wxValidator& rValidator = wxDefaultValidator
fb49f3b3
DW
55 ,const wxString& rsName = wxChoiceNameStr
56 );
0e320a79 57
fb49f3b3 58 //
dcd307ee 59 // Implement base class virtuals
fb49f3b3
DW
60 //
61 virtual int DoAppend(const wxString& rsItem);
243dbf1a 62 virtual int DoInsert(const wxString& rsItem, int pos);
fb49f3b3
DW
63 virtual void Delete(int n);
64 virtual void Clear(void);
37f214d5 65
fb49f3b3
DW
66 virtual int GetCount(void) const;
67 virtual int GetSelection(void) const ;
68 virtual void SetSelection(int n);
37f214d5 69
fb49f3b3 70 virtual int FindString(const wxString& rsStr) const;
dcd307ee 71 virtual wxString GetString(int n) const ;
fb49f3b3
DW
72 virtual void SetString( int n
73 ,const wxString& rsStr
74 );
0e320a79 75
fb49f3b3 76 //
dcd307ee 77 // OS2 only
fb49f3b3
DW
78 //
79 virtual bool OS2Command( WXUINT uParam
80 ,WXWORD wId
81 );
82 MRESULT OS2WindowProc( WXUINT uMsg
83 ,WXWPARAM wParam
84 ,WXLPARAM lParam
85 );
0e320a79
DW
86
87protected:
fb49f3b3
DW
88 virtual void DoSetItemClientData( int n
89 ,void* pClientData
90 );
91 virtual void* DoGetItemClientData(int n) const;
92 virtual void DoSetItemClientObject( int n
93 ,wxClientData* pClientData
94 );
95 virtual wxClientData* DoGetItemClientObject(int n) const;
96 virtual wxSize DoGetBestSize(void) const;
97 virtual void DoSetSize( int nX
98 ,int nY
99 ,int nWidth
100 ,int nHeight
101 ,int nsizeFlags = wxSIZE_AUTO
102 );
103 void Free(void);
104}; // end of CLASS wxChoice
0e320a79 105
37f214d5 106#endif // _WX_CHOICE_H_