selectedIndices
Returns the indices of selected items in the data source. Always returns an enumerable, even if no item is selected, or a single item is selected.
Read time 1 minuteLast updated 12 days ago
Definition
- Type: Property
- Namespace: UnityEngine.UIElements
- Assembly: UnityEngine.UIElementsModule
public IEnumerable<int> selectedIndices { get; }
Remarks
In a tree, if a child item is collapsed, its index is not included in the selection. To get selected items regardless of whether they are collapsed or not, use _selectedIds instead.