getState method

SeatState getState(
  1. int row,
  2. int col
)

Returns the SeatState for a cell — selection overrides the stored state.

Implementation

SeatState getState(int row, int col) {
  if (_selectedSeats.contains(SeatPoint(row, col))) return SeatState.selected;
  return _grid[row][col].state;
}