Class Toggle
Inheritance
Toggle
Implements
Inherited Members
Namespace: UnityEngine.Experimental.UIElements
Assembly: UnityEngine.dll
Syntax
public class Toggle : BaseField<bool>, IEventHandler, ITransform, IUIElementDataWatch, IEnumerable<VisualElement>, IEnumerable, IVisualElementScheduler, IStyle, IBindable, INotifyValueChanged<bool>
Constructors
| Improve this Doc View SourceToggle()
Declaration
public Toggle()
Toggle(Action)
Declaration
[Obsolete("Use Toggle() with OnValueChanged() instead.", false)]
public Toggle(Action clickEvent)
Parameters
Type | Name | Description |
---|---|---|
Action | clickEvent |
Properties
| Improve this Doc View Sourcetext
Declaration
public string text { get; set; }
Property Value
Type | Description |
---|---|
String |
Methods
| Improve this Doc View SourceExecuteDefaultActionAtTarget(EventBase)
Declaration
protected override void ExecuteDefaultActionAtTarget(EventBase evt)
Parameters
Type | Name | Description |
---|---|---|
EventBase | evt |
Overrides
| Improve this Doc View SourceOnToggle(Action)
Declaration
[Obsolete("Use OnValueChanged() instead.", false)]
public void OnToggle(Action clickEvent)
Parameters
Type | Name | Description |
---|---|---|
Action | clickEvent |
SetValueWithoutNotify(Boolean)
Declaration
public override void SetValueWithoutNotify(bool newValue)
Parameters
Type | Name | Description |
---|---|---|
Boolean | newValue |
Overrides
UnityEngine.Experimental.UIElements.BaseField<System.Boolean>.SetValueWithoutNotify(System.Boolean)