Esempio n. 1
0
bool wxToolBarToolBase::Toggle(bool toggle)
{
    wxASSERT_MSG( CanBeToggled(), wxT("can't toggle this tool") );

    if ( m_toggled == toggle )
        return false;

    m_toggled = toggle;

    return true;
}
Esempio n. 2
0
 // is this tool pressed, even temporarily? (this is different from being
 // permanently toggled which is what IsToggled() returns)
 bool IsPressed() const
     { return CanBeToggled() ? IsToggled() != m_isInverted : m_isInverted; }