toggle method
void
toggle(
- dynamic o
Change the option status (depending on isSelected result).
Which option to be toggled can be defined by the index (String) or by the option (T
) object itself.
On SelectionMode.single, this will just call select.
Implementation
void toggle(dynamic o) {
if (mode == SelectionMode.single) {
select(o);
} else if (isSelected(o)) {
unselect(o);
} else {
select(o);
}
}