Merge branch 'vlistbox-current-accessors' of https://github.com/wsu-cb/wxWidgets
wxVListBox: add GetCurrent()/SetCurrent() accessors. See #24204.
This commit is contained in:
commit
1b4dfc292a
9 changed files with 32 additions and 14 deletions
|
|
@ -258,11 +258,6 @@ public:
|
|||
// as a parameter
|
||||
wxGLContextAttrs& GetGLCTXAttrs() { return m_GLCTXAttrs; }
|
||||
|
||||
#ifdef __WXUNIVERSAL__
|
||||
// resolve the conflict with wxWindowUniv::SetCurrent()
|
||||
virtual bool SetCurrent(bool doit) { return wxWindow::SetCurrent(doit); }
|
||||
#endif
|
||||
|
||||
protected:
|
||||
// override this to implement SetColour() in GL_INDEX_MODE
|
||||
// (currently only implemented in wxX11)
|
||||
|
|
|
|||
|
|
@ -50,7 +50,7 @@ public:
|
|||
|
||||
virtual bool Enable(bool enable = true) override;
|
||||
|
||||
virtual bool SetCurrent(bool doit = true) override;
|
||||
virtual bool WXMakeCurrent(bool doit = true) override;
|
||||
|
||||
virtual void Press() override;
|
||||
virtual void Release() override;
|
||||
|
|
|
|||
|
|
@ -126,7 +126,7 @@ public:
|
|||
int GetStateFlags() const;
|
||||
|
||||
// set the "highlighted" flag and return true if it changed
|
||||
virtual bool SetCurrent(bool doit = true);
|
||||
virtual bool WXMakeCurrent(bool doit = true);
|
||||
|
||||
#if wxUSE_SCROLLBAR
|
||||
// get the scrollbar (may be null) for the given orientation
|
||||
|
|
|
|||
|
|
@ -95,6 +95,12 @@ public:
|
|||
bool IsCurrent() const { return wxVScrolledWindow::IsCurrent(); }
|
||||
#endif
|
||||
|
||||
// get current item
|
||||
int GetCurrent() const { return m_current; }
|
||||
|
||||
// set current item
|
||||
void SetCurrent(int current) { DoSetCurrent(current); }
|
||||
|
||||
// is this item selected?
|
||||
bool IsSelected(size_t item) const;
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue