Version: Unity 6.3 Beta (6000.3)
LanguageEnglish
  • C#

MainToolbarSlider Constructor

Suggest a change

Success!

Thank you for helping us improve the quality of Unity Documentation. Although we cannot accept all submissions, we do read each suggested change from our users and will make updates where applicable.

Close

Submission failed

For some reason your suggested change could not be submitted. Please <a>try again</a> in a few minutes. And thank you for taking the time to help us improve the quality of Unity Documentation.

Close

Cancel

Declaration

public MainToolbarSlider(Toolbars.MainToolbarContent content, float value, float minValue, float maxValue, Action<float> valueChanged);

Declaration

public MainToolbarSlider(Toolbars.MainToolbarContent content, float value, float minValue, float maxValue, Action<float> valueChanged, bool rounded);

Parameters

Parameter Description
content The visual content of the slider.
value The default value of the slider.
minValue The start value of the slider, it must be lower than the end value.
maxValue The end value of the slider, it must to be higher than the end value.
rounded Set to true if the slider should only have values rounded to the closest int value.
valueChanged The callback that receives the new value of the slider when the user changes it.

Description

Specify the content and function of a main toolbar slider.