Fix from Jed Burgess that correctly untoggles radio toolbar items when
another one in the same group is selected. git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@29296 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -385,7 +385,10 @@ void wxToolBarBase::UnToggleRadioGroup(wxToolBarToolBase *tool)
|
||||
if ( !tool->IsButton() || tool->GetKind() != wxITEM_RADIO )
|
||||
break;
|
||||
|
||||
tool->Toggle(false);
|
||||
if ( tool->Toggle(false) )
|
||||
{
|
||||
DoToggleTool(tool, false);
|
||||
}
|
||||
|
||||
nodeNext = nodeNext->GetNext();
|
||||
}
|
||||
@@ -398,7 +401,10 @@ void wxToolBarBase::UnToggleRadioGroup(wxToolBarToolBase *tool)
|
||||
if ( !tool->IsButton() || tool->GetKind() != wxITEM_RADIO )
|
||||
break;
|
||||
|
||||
tool->Toggle(false);
|
||||
if ( tool->Toggle(false) )
|
||||
{
|
||||
DoToggleTool(tool, false);
|
||||
}
|
||||
|
||||
nodePrev = nodePrev->GetPrevious();
|
||||
}
|
||||
|
Reference in New Issue
Block a user