check the first radio button in a group

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@8931 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Vadim Zeitlin
2000-12-16 23:12:09 +00:00
parent 47c93b637e
commit a9c317d27c

View File

@@ -138,6 +138,13 @@ bool wxRadioButton::Create(wxWindow *parent, wxWindowID id,
SetSize(x, y, width, height);
// for compatibility with wxGTK, the first radio button in a group is
// always checked (this makes sense anyhow as you need to ensure that at
// least one button in the group is checked and this is the simlpest way to
// do it)
if ( m_windowStyle & wxRB_GROUP )
SetValue(TRUE);
return TRUE;
}