moveSelectingCellToEdgeOfRows method
void
moveSelectingCellToEdgeOfRows(
- PlutoMoveDirection direction, {
- bool force = false,
- bool notify = true,
inherited
Implementation
@override
void moveSelectingCellToEdgeOfRows(
PlutoMoveDirection direction, {
bool force = false,
bool notify = true,
}) {
if (!direction.vertical) {
return;
}
if (!force && isEditing == true) {
return;
}
if (currentCell == null) {
return;
}
final columnIdx = hasCurrentSelectingPosition
? currentSelectingPosition!.columnIdx
: currentCellPosition!.columnIdx;
final int rowIdx = direction.isUp ? 0 : refRows.length - 1;
setCurrentSelectingPosition(
cellPosition: PlutoGridCellPosition(
columnIdx: columnIdx,
rowIdx: rowIdx,
),
notify: notify,
);
direction.isUp
? scroll.vertical!.jumpTo(0)
: scroll.vertical!.jumpTo(scroll.maxScrollVertical);
}