+ bool isRadio = FALSE;
+
+ if ( tool->IsButton() && tool->GetKind() == wxITEM_RADIO )
+ {
+ if ( !lastWasRadio )
+ {
+ if (tool->Toggle(true))
+ {
+ DoToggleTool(tool, true);
+ }
+ }
+ isRadio = TRUE;
+ }
+ else
+ {
+ isRadio = FALSE;
+ }
+ lastWasRadio = isRadio;
+