getIndexAt method

int getIndexAt (
  1. {int column,
  2. int row}
)

Gets the cell index by column and row.

Implementation

int getIndexAt({int column, int row}) {
  if (!_grid.containsKey(row)) return -1;
  final map = _grid[row];
  if (!map.containsKey(column)) return -1;
  return map[column];
}