Class: shaka.ui.RangeElement

Constructor

new RangeElement(parentnon-null, controlsnon-null, containerClassNamesnon-null, barClassNamesnon-null)

Parameters:
Name Type Description
parent HTMLElement
controls shaka.ui.Controls
containerClassNames Array.<string>
barClassNames Array.<string>
Implements:
Source:

Members

bar :HTMLInputElement

Type:
  • HTMLInputElement
Source:

container :HTMLElement

This container is to support IE 11. See detailed notes in less/range_elements.less for a complete explanation.
Type:
  • HTMLElement
Source:

endFakeChangeTimer_ :shaka.util.Timer

Type:
Source:

isChanging_ :boolean

Type:
  • boolean
Source:

Methods

changeTo(value)

Called to implement keyboard-based changes, where this is no clear "end". This will simulate events like onChangeStart(), onChange(), and onChangeEnd() as appropriate.
Parameters:
Name Type Description
value number
Implements:
Source:

getValue() → {number}

Implements:
Source:
Returns:
Type
number

onChange()

Called when a new value is set by user interaction. To be overridden by subclasses.
Implements:
Source:

onChangeEnd()

Called when user interaction ends. To be overridden by subclasses.
Implements:
Source:

onChangeStart()

Called when user interaction begins. To be overridden by subclasses.
Implements:
Source:

setBarValueForTouch_(event)

Synchronize the touch position with the range value. Comes in handy on iOS, where users have to grab the handle in order to start seeking.
Parameters:
Name Type Description
event Event
Source:

setRange(min, max)

Parameters:
Name Type Description
min number
max number
Implements:
Source:

setValue(value)

Parameters:
Name Type Description
value number
Implements:
Source: