setCurrentSelectingRowsByRange method

  1. @override
void setCurrentSelectingRowsByRange(
  1. int? from,
  2. int? to, {
  3. bool notify = true,
})
inherited

Sets the currentSelectingRows by range. from rowIdx of rows. to rowIdx of rows.

Implementation

@override
void setCurrentSelectingRowsByRange(int? from, int? to,
    {bool notify = true}) {
  if (!selectingMode.isRow) {
    return;
  }

  final maxFrom = min(from!, to!);

  final maxTo = max(from, to) + 1;

  if (maxFrom < 0 || maxTo > refRows.length) {
    return;
  }

  _state._currentSelectingRows = refRows.getRange(maxFrom, maxTo).toList();

  notifyListeners(notify, setCurrentSelectingRowsByRange.hashCode);
}