C# Класс Nez.UI.Slider

Наследование: ProgressBar, IInputListener, IGamepadFocusable
Показать файл Открыть проект Примеры использования класса

Открытые свойства

Свойство Тип Описание
sliderBoundaryThreshold float

Открытые методы

Метод Описание
IGamepadFocusable ( ) : void
IGamepadFocusable ( Direction direction ) : void
IInputListener ( ) : void
IInputListener ( Vector2 mousePos ) : void
Slider ( Skin skin, string styleName = null, float min, float max = 1, float step = 0.1f ) : System
Slider ( float min, float max, float stepSize, bool vertical, SliderStyle style ) : System

Creates a new slider. It's width is determined by the given prefWidth parameter, its height is determined by the maximum of the height of either the slider {@link NinePatch} or slider handle {@link TextureRegion}. The min and max values determine the range the values of this slider can take on, the stepSize parameter specifies the distance between individual values. E.g. min could be 4, max could be 10 and stepSize could be 0.2, giving you a total of 30 values, 4.0 4.2, 4.4 and so on.

calculatePositionAndValue ( Vector2 mousePos ) : void
enableExplicitFocusableControl ( IGamepadFocusable upEle, IGamepadFocusable downEle, IGamepadFocusable leftEle, IGamepadFocusable rightEle ) : void
getStyle ( ) : SliderStyle

Returns the slider's style. Modifying the returned style may not have an effect until {@link #setStyle(SliderStyle)} is called

isDragging ( ) : bool
setStyle ( SliderStyle style ) : void

Защищенные методы

Метод Описание
getKnobDrawable ( ) : IDrawable
onActionButtonPressed ( ) : void
onActionButtonReleased ( ) : void
onFocused ( ) : void
onUnfocused ( ) : void
onUnhandledDirectionPressed ( Direction direction ) : void

Приватные методы

Метод Описание
IInputListener ( Vector2 mousePos ) : bool
IInputListener ( int mouseWheelDelta ) : bool

Описание методов

IGamepadFocusable() публичный Метод

public IGamepadFocusable ( ) : void
Результат void

IGamepadFocusable() публичный Метод

public IGamepadFocusable ( Direction direction ) : void
direction Direction
Результат void

IInputListener() публичный Метод

public IInputListener ( ) : void
Результат void

IInputListener() публичный Метод

public IInputListener ( Vector2 mousePos ) : void
mousePos Vector2
Результат void

Slider() публичный Метод

public Slider ( Skin skin, string styleName = null, float min, float max = 1, float step = 0.1f ) : System
skin Skin
styleName string
min float
max float
step float
Результат System

Slider() публичный Метод

Creates a new slider. It's width is determined by the given prefWidth parameter, its height is determined by the maximum of the height of either the slider {@link NinePatch} or slider handle {@link TextureRegion}. The min and max values determine the range the values of this slider can take on, the stepSize parameter specifies the distance between individual values. E.g. min could be 4, max could be 10 and stepSize could be 0.2, giving you a total of 30 values, 4.0 4.2, 4.4 and so on.
public Slider ( float min, float max, float stepSize, bool vertical, SliderStyle style ) : System
min float Minimum.
max float Max.
stepSize float Step size.
vertical bool If set to true vertical.
style SliderStyle
Результат System

calculatePositionAndValue() публичный Метод

public calculatePositionAndValue ( Vector2 mousePos ) : void
mousePos Vector2
Результат void

enableExplicitFocusableControl() публичный Метод

public enableExplicitFocusableControl ( IGamepadFocusable upEle, IGamepadFocusable downEle, IGamepadFocusable leftEle, IGamepadFocusable rightEle ) : void
upEle IGamepadFocusable
downEle IGamepadFocusable
leftEle IGamepadFocusable
rightEle IGamepadFocusable
Результат void

getKnobDrawable() защищенный Метод

protected getKnobDrawable ( ) : IDrawable
Результат IDrawable

getStyle() публичный Метод

Returns the slider's style. Modifying the returned style may not have an effect until {@link #setStyle(SliderStyle)} is called
public getStyle ( ) : SliderStyle
Результат SliderStyle

isDragging() публичный Метод

public isDragging ( ) : bool
Результат bool

onActionButtonPressed() защищенный Метод

protected onActionButtonPressed ( ) : void
Результат void

onActionButtonReleased() защищенный Метод

protected onActionButtonReleased ( ) : void
Результат void

onFocused() защищенный Метод

protected onFocused ( ) : void
Результат void

onUnfocused() защищенный Метод

protected onUnfocused ( ) : void
Результат void

onUnhandledDirectionPressed() защищенный Метод

protected onUnhandledDirectionPressed ( Direction direction ) : void
direction Direction
Результат void

setStyle() публичный Метод

public setStyle ( SliderStyle style ) : void
style SliderStyle
Результат void

Описание свойств

sliderBoundaryThreshold публичное свойство

the maximum distance outside the slider the mouse can move when pressing it to cause it to be unfocused
public float sliderBoundaryThreshold
Результат float