X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/3ca6a5f04692678cd2d9f3ea0843fc3f5a0b254f..6c34d0ede9d6f7086896a1e4467091f0360846de:/src/msw/radiobut.cpp diff --git a/src/msw/radiobut.cpp b/src/msw/radiobut.cpp index a9a7705f60..261af8c3d3 100644 --- a/src/msw/radiobut.cpp +++ b/src/msw/radiobut.cpp @@ -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; }