Code example for ToggleButton

Methods: getTag, isChecked

0
    // 
    //-------------------------------------------------------------------------- 
 
    protected void onStepChange(ToggleButton button) {
        // trigger on/off for the step in the sequencer 
        StepInfo info = (StepInfo)button.getTag();
        stepSequencerModel.setSelected(info, button.isChecked());
    } 
}