From afa292ff314e4d032cf267dd16741589b7689193 Mon Sep 17 00:00:00 2001 From: David Elliott Date: Wed, 8 Aug 2007 03:17:36 +0000 Subject: [PATCH] Select the first choice in the radiobox upon creation for parity with other ports. git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@47951 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775 --- src/cocoa/radiobox.mm | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/cocoa/radiobox.mm b/src/cocoa/radiobox.mm index 5ee7d00586..6ce3aa2dd3 100644 --- a/src/cocoa/radiobox.mm +++ b/src/cocoa/radiobox.mm @@ -167,6 +167,11 @@ bool wxRadioBox::Create(wxWindow *parent, wxWindowID winid, SetMajorDim(majorDim, style); + // Set the selection to the first item if we have any items. + // This is for parity with other wx ports which do the same thing. + if(n > 0) + SetSelection(0); + if(m_parent) m_parent->CocoaAddChild(this); -- 2.50.0