MainToolbarSlider
Specify the content and function of a main toolbar slider.
Read time 1 minuteLast updated 12 days ago
Definition
- Type: Constructor
- Namespace: UnityEditor.Toolbars
- Assembly: UnityEditor
MainToolbarSlider(MainToolbarContent, float, float, float, Action<float>)
Specify the content and function of a main toolbar slider.
public MainToolbarSlider(MainToolbarContent content, float value, float minValue, float maxValue, Action<float> valueChanged)
Parameters
The visual content of the slider.
The default value of the slider.
The start value of the slider, it must be lower than the end value.
The end value of the slider, it must to be higher than the end value.
The callback that receives the new value of the slider when the user changes it.
MainToolbarSlider(MainToolbarContent, float, float, float, Action<float>, bool)
Specify the content and function of a main toolbar slider.
public MainToolbarSlider(MainToolbarContent content, float value, float minValue, float maxValue, Action<float> valueChanged, bool rounded)
Parameters
The visual content of the slider.
The default value of the slider.
The start value of the slider, it must be lower than the end value.
The end value of the slider, it must to be higher than the end value.
The callback that receives the new value of the slider when the user changes it.
Set to true if the slider should only have values rounded to the closest int value.