From 8e85c4e4adfa0546c39ae2b9ddb3a1a0887e8148 Mon Sep 17 00:00:00 2001 From: Vadim Zeitlin Date: Fri, 31 May 2013 23:21:40 +0000 Subject: [PATCH] Document that wxRadioBox::SetSelection() doesn't accept wxNOT_FOUND. A radio box always has selection and it can't be unset (at least not under all platforms), so document that the item passed to its SetSelection() must be valid, unlike with SetSelection() methods in some other classes. Closes #15233. git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@74073 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775 --- interface/wx/radiobox.h | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/interface/wx/radiobox.h b/interface/wx/radiobox.h index fe5f106f6d..be54439d7f 100644 --- a/interface/wx/radiobox.h +++ b/interface/wx/radiobox.h @@ -287,6 +287,14 @@ public: */ void SetItemToolTip(unsigned int item, const wxString& text); + /** + Sets the selection to the given item. + + Notice that a radio box always has selection, so @a n must be valid + here and passing @c wxNOT_FOUND is not allowed. + */ + virtual void SetSelection(int n); + /** Shows or hides individual buttons. @@ -310,7 +318,6 @@ public: virtual unsigned int GetCount() const; virtual wxString GetString(unsigned int n) const; virtual void SetString(unsigned int n, const wxString& string); - virtual void SetSelection(int n); virtual int GetSelection() const; }; -- 2.45.2