selectedIndex property
Selects the shape in the given index.
The map passes the selected index to the onSelectionChanged callback but does not actually change this value until the parent widget rebuilds the maps with the new value.
To unselect a shape, set -1 to the MapShapeSublayer.selectedIndex.
Must not be null. Defaults to -1.
See also:
- MapSelectionSettings, to customize the selected shape's appearance.
- MapShapeSublayer.onSelectionChanged, for getting the current tapped shape index.
Implementation
final int selectedIndex;