toggle method
Mutator to mark a T
value as either active or inactive.
Implementation
void toggle(WidgetEvent event, [bool? active]) {
active = active ?? !value.contains(event);
return active ? add(event) : remove(event);
}
Mutator to mark a T
value as either active or inactive.
void toggle(WidgetEvent event, [bool? active]) {
active = active ?? !value.contains(event);
return active ? add(event) : remove(event);
}