invertSelection method
Inverts the current selection.
Implementation
void invertSelection(List<T> items) {
if (selectionMode != SelectionMode.multiple) {
return;
}
final selected = controller.selectedItems.toSet();
final inverted = items.where((item) => !selected.contains(item)).toList();
controller.setSelection(inverted);
}