const wxString& name)
{
// common initialisation
- if ( !CreateControl(parent, id, pos, size, style, name) )
+ if ( !CreateControl(parent, id, pos, size, style, wxDefaultValidator, name) )
return FALSE;
// prepare flags
if ( tool->CanBeToggled() )
{
LRESULT state = ::SendMessage(GetHwnd(), TB_GETSTATE, id, 0);
- tool->SetToggle((state & TBSTATE_CHECKED) != 0);
+ tool->Toggle((state & TBSTATE_CHECKED) != 0);
}
bool toggled = tool->IsToggled();