part of wxComboBox to wxEntry refactoring (should have been part of rev48952)
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@48953 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -13,6 +13,7 @@
|
|||||||
#define _WX_COMBOBOX_H_
|
#define _WX_COMBOBOX_H_
|
||||||
|
|
||||||
#include "wx/choice.h"
|
#include "wx/choice.h"
|
||||||
|
#include "wx/textentry.h"
|
||||||
|
|
||||||
#if wxUSE_COMBOBOX
|
#if wxUSE_COMBOBOX
|
||||||
|
|
||||||
@@ -20,7 +21,8 @@
|
|||||||
// Combobox control
|
// Combobox control
|
||||||
// ----------------------------------------------------------------------------
|
// ----------------------------------------------------------------------------
|
||||||
|
|
||||||
class WXDLLEXPORT wxComboBox: public wxChoice
|
class WXDLLEXPORT wxComboBox : public wxChoice,
|
||||||
|
public wxTextEntry
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
wxComboBox() { }
|
wxComboBox() { }
|
||||||
@@ -68,46 +70,26 @@ public:
|
|||||||
const wxValidator& validator = wxDefaultValidator,
|
const wxValidator& validator = wxDefaultValidator,
|
||||||
const wxString& name = wxComboBoxNameStr);
|
const wxString& name = wxComboBoxNameStr);
|
||||||
|
|
||||||
// List functions: see wxChoice
|
// resolve ambiguities among virtual functions inherited from both base
|
||||||
|
// classes
|
||||||
// Text field functions
|
|
||||||
virtual wxString GetValue() const;
|
|
||||||
virtual void SetValue(const wxString& value);
|
virtual void SetValue(const wxString& value);
|
||||||
|
virtual wxString GetStringSelection() const
|
||||||
|
{ return wxChoice::GetStringSelection(); }
|
||||||
|
|
||||||
// Clipboard operations
|
|
||||||
virtual void Copy();
|
|
||||||
virtual void Cut();
|
|
||||||
virtual void Paste();
|
|
||||||
virtual bool CanCopy() const;
|
|
||||||
virtual bool CanCut() const;
|
|
||||||
virtual bool CanPaste() const;
|
|
||||||
virtual void SetInsertionPoint(long pos);
|
|
||||||
virtual void SetInsertionPointEnd();
|
|
||||||
virtual long GetInsertionPoint() const;
|
|
||||||
virtual wxTextPos GetLastPosition() const;
|
|
||||||
virtual void Replace(long from, long to, const wxString& value);
|
|
||||||
virtual void Remove(long from, long to);
|
|
||||||
virtual void SetSelection(int n) { wxChoice::SetSelection(n); }
|
virtual void SetSelection(int n) { wxChoice::SetSelection(n); }
|
||||||
virtual void SetSelection(long from, long to);
|
virtual void SetSelection(long from, long to)
|
||||||
|
{ wxTextEntry::SetSelection(from, to); }
|
||||||
virtual int GetSelection() const { return wxChoice::GetSelection(); }
|
virtual int GetSelection() const { return wxChoice::GetSelection(); }
|
||||||
virtual void GetSelection(long* from, long* to) const;
|
virtual void GetSelection(long *from, long *to) const
|
||||||
virtual void SetEditable(bool editable);
|
{ wxTextEntry::GetSelection(from, to); }
|
||||||
|
|
||||||
virtual void Undo();
|
|
||||||
virtual void Redo();
|
|
||||||
virtual bool CanUndo() const;
|
|
||||||
virtual bool CanRedo() const;
|
|
||||||
virtual void SelectAll();
|
|
||||||
virtual bool IsEditable() const;
|
virtual bool IsEditable() const;
|
||||||
virtual bool HasSelection() const;
|
|
||||||
|
|
||||||
// implementation only from now on
|
// implementation only from now on
|
||||||
virtual bool MSWCommand(WXUINT param, WXWORD id);
|
virtual bool MSWCommand(WXUINT param, WXWORD id);
|
||||||
bool MSWProcessEditMsg(WXUINT msg, WXWPARAM wParam, WXLPARAM lParam);
|
bool MSWProcessEditMsg(WXUINT msg, WXWPARAM wParam, WXLPARAM lParam);
|
||||||
virtual WXLRESULT MSWWindowProc(WXUINT nMsg, WXWPARAM wParam, WXLPARAM lParam);
|
virtual WXLRESULT MSWWindowProc(WXUINT nMsg, WXWPARAM wParam, WXLPARAM lParam);
|
||||||
bool MSWShouldPreProcessMessage(WXMSG *pMsg);
|
bool MSWShouldPreProcessMessage(WXMSG *pMsg);
|
||||||
|
|
||||||
WXHWND GetEditHWND() const;
|
|
||||||
|
|
||||||
// Standard event handling
|
// Standard event handling
|
||||||
void OnCut(wxCommandEvent& event);
|
void OnCut(wxCommandEvent& event);
|
||||||
@@ -133,11 +115,13 @@ protected:
|
|||||||
virtual void DoSetToolTip(wxToolTip *tip);
|
virtual void DoSetToolTip(wxToolTip *tip);
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
virtual WXHWND GetEditHWND() const;
|
||||||
|
|
||||||
private:
|
private:
|
||||||
DECLARE_DYNAMIC_CLASS_NO_COPY(wxComboBox)
|
DECLARE_DYNAMIC_CLASS_NO_COPY(wxComboBox)
|
||||||
DECLARE_EVENT_TABLE()
|
DECLARE_EVENT_TABLE()
|
||||||
};
|
};
|
||||||
|
|
||||||
#endif // wxUSE_COMBOBOX
|
#endif // wxUSE_COMBOBOX
|
||||||
#endif
|
|
||||||
// _WX_COMBOBOX_H_
|
#endif // _WX_COMBOBOX_H_
|
||||||
|
Reference in New Issue
Block a user