moveSelectingCellByRowIdx method
void
moveSelectingCellByRowIdx(
- int rowIdx,
- PlutoMoveDirection direction, {
- bool notify = true,
inherited
Implementation
@override
void moveSelectingCellByRowIdx(
int rowIdx,
PlutoMoveDirection direction, {
bool notify = true,
}) {
if (rowIdx < 0) {
rowIdx = 0;
}
if (rowIdx > refRows.length - 1) {
rowIdx = refRows.length - 1;
}
if (currentCell == null) {
return;
}
int? columnIdx = hasCurrentSelectingPosition
? currentSelectingPosition!.columnIdx
: currentCellPosition!.columnIdx;
setCurrentSelectingPosition(
cellPosition: PlutoGridCellPosition(
columnIdx: columnIdx,
rowIdx: rowIdx,
),
);
moveScrollByRow(direction, rowIdx - direction.offset);
}