setSelectedFloorByFloorIndex method

  1. @override
void setSelectedFloorByFloorIndex(
  1. int floorIndex
)
override

Invoked when a floor has been selected programmatically by index

Implementation

@override
void setSelectedFloorByFloorIndex(int floorIndex) {
  if (_floors.isEmpty) {
    return;
  }

  for (final floor in _floors) {
    if (floor.floorIndex == floorIndex) {
      setSelectedFloor(floor);
      return;
    }
  }
}