+ if (!cbs->set)
+ return;
+
+ wxRadioButton *item = (wxRadioButton *) clientData;
+ if (item->InSetValue())
+ return;
+
+ //based on mac/radiobut.cpp
+ wxRadioButton* old = item->ClearSelections();
+ item->SetValue(true);
+
+ if ( old )
+ {
+ wxCommandEvent event(wxEVT_RADIOBUTTON,
+ old->GetId() );
+ event.SetEventObject(old);
+ event.SetInt( false );
+ old->ProcessCommand(event);
+ }
+ wxCommandEvent event2(wxEVT_RADIOBUTTON, item->GetId() );
+ event2.SetEventObject(item);
+ event2.SetInt( true );
+ item->ProcessCommand(event2);