Class InteractableToggleCollection
A way to control a list of radial type buttons or tabs
Namespace: Microsoft.MixedReality.Toolkit.UI
Assembly: cs.temp.dll.dll
Syntax
public class InteractableToggleCollection : MonoBehaviour
Fields
OnSelectionEvents
Declaration
public UnityEvent OnSelectionEvents
Field Value
Type | Description |
---|---|
Unity |
Properties
CurrentIndex
The current index in the array of interactable toggles
Declaration
public int CurrentIndex { get; set; }
Property Value
Type | Description |
---|---|
Int32 |
ToggleList
Array of Interactables that will be managed by this controller
Declaration
public Interactable[] ToggleList { get; set; }
Property Value
Type | Description |
---|---|
Interactable[] |
Methods
OnSelection(Int32, Boolean)
Declaration
protected virtual void OnSelection(int index, bool force = false)
Parameters
SetSelection(Int32, Boolean, Boolean)
Set the selection of a an element in the toggle collection based on index.
Index of an element in ToggleList Force selection set The manual trigger of the OnClick event. OnClick event is manually triggered when the CurrentIndex is updated via script or inspectorDeclaration
public void SetSelection(int index, bool force = false, bool fireOnClick = false)