selectGroup method
Select all options in a group (defined by groupName
).
Do nothing when mode is SelectionMode.single.
Implementation
void selectGroup(String groupName) {
if (mode == SelectionMode.single) return;
if (mode == SelectionMode.sameGroup) _selected.clear();
_selected.addAll(_groups.keys.where((i) => _groups[i] == groupName));
}