]> git.saurik.com Git - wxWidgets.git/blame - include/wx/combobox.h
Replaces size_t with unsigned int in wxDataViewCtrl API.
[wxWidgets.git] / include / wx / combobox.h
CommitLineData
1e6feb95
VZ
1///////////////////////////////////////////////////////////////////////////////
2// Name: wx/combobox.h
3// Purpose: wxComboBox declaration
4// Author: Vadim Zeitlin
5// Modified by:
6// Created: 24.12.00
7// RCS-ID: $Id$
77ffb593 8// Copyright: (c) 1996-2000 wxWidgets team
65571936 9// Licence: wxWindows licence
1e6feb95
VZ
10///////////////////////////////////////////////////////////////////////////////
11
34138703
JS
12#ifndef _WX_COMBOBOX_H_BASE_
13#define _WX_COMBOBOX_H_BASE_
c801d85f 14
1e6feb95
VZ
15#include "wx/defs.h"
16
83beee57
RR
17#if wxUSE_COMBOBOX
18
63ec432b 19extern WXDLLEXPORT_DATA(const wxChar) wxComboBoxNameStr[];
1e6feb95
VZ
20
21// ----------------------------------------------------------------------------
22// wxComboBoxBase: this interface defines the methods wxComboBox must implement
23// ----------------------------------------------------------------------------
24
7d8268a1 25#include "wx/textctrl.h"
1e6feb95
VZ
26#include "wx/ctrlsub.h"
27
28class WXDLLEXPORT wxComboBoxBase : public wxItemContainer
29{
30public:
31 // wxTextCtrl-like methods wxComboBox must implement
32 virtual wxString GetValue() const = 0;
33 virtual void SetValue(const wxString& value) = 0;
34
35 virtual void Copy() = 0;
36 virtual void Cut() = 0;
37 virtual void Paste() = 0;
38 virtual void SetInsertionPoint(long pos) = 0;
39 virtual long GetInsertionPoint() const = 0;
7d8268a1 40 virtual wxTextPos GetLastPosition() const = 0;
1e6feb95
VZ
41 virtual void Replace(long from, long to, const wxString& value) = 0;
42 virtual void SetSelection(long from, long to) = 0;
43 virtual void SetEditable(bool editable) = 0;
44
45 virtual void SetInsertionPointEnd()
46 { SetInsertionPoint(GetLastPosition()); }
47 virtual void Remove(long from, long to)
48 { Replace(from, to, wxEmptyString); }
150e31d2
JS
49
50 virtual bool IsEditable() const = 0;
51
52 virtual void Undo() = 0;
53 virtual void Redo() = 0;
54 virtual void SelectAll() = 0;
55
56 virtual bool CanCopy() const = 0;
57 virtual bool CanCut() const = 0;
58 virtual bool CanPaste() const = 0;
59 virtual bool CanUndo() const = 0;
60 virtual bool CanRedo() const = 0;
61
d2fde247
VZ
62
63 // redeclare inherited SetSelection() overload here as well to avoid
64 // virtual function hiding
65 virtual void SetSelection(int n) = 0;
1e6feb95
VZ
66};
67
68// ----------------------------------------------------------------------------
69// include the platform-dependent header defining the real class
70// ----------------------------------------------------------------------------
71
72#if defined(__WXUNIVERSAL__)
73 #include "wx/univ/combobox.h"
74#elif defined(__WXMSW__)
75 #include "wx/msw/combobox.h"
2049ba38 76#elif defined(__WXMOTIF__)
1e6feb95 77 #include "wx/motif/combobox.h"
1be7a35c 78#elif defined(__WXGTK20__)
1e6feb95 79 #include "wx/gtk/combobox.h"
1be7a35c
MR
80#elif defined(__WXGTK__)
81 #include "wx/gtk1/combobox.h"
34138703 82#elif defined(__WXMAC__)
1e6feb95 83 #include "wx/mac/combobox.h"
421a8431
DE
84#elif defined(__WXCOCOA__)
85 #include "wx/cocoa/combobox.h"
1777b9bb 86#elif defined(__WXPM__)
1e6feb95 87 #include "wx/os2/combobox.h"
c801d85f
KB
88#endif
89
1e6feb95
VZ
90#endif // wxUSE_COMBOBOX
91
c801d85f 92#endif
34138703 93 // _WX_COMBOBOX_H_BASE_