Class: VolumeMenuButton

VolumeMenuButton

Button for volume popup


new VolumeMenuButton(player [, options])

Creates an instance of this class.

Parameters:
Name Type Argument Default Description
player Player

The Player that this class should be attached to.

options Object <optional>
{}

The key/value store of player options.

Source:
control-bar/volume-menu-button.js

Extends

Members


volumeUpdate

Source:
control-bar/volume-menu-button.js

Methods


attachVolumeBarEvents()

Add events listeners to the created VolumeBar.

Source:
control-bar/volume-menu-button.js

buildCSSClass()

Builds the default DOM className.

Overrides:
Source:
control-bar/volume-menu-button.js
Returns:

The DOM className for this object.

Type
string

createEl()

Create the PopupButtons DOM element.

Inherited From:
Source:
popup/popup-button.js
Returns:

The element that gets created.

Type
Element

createPopup()

Create the VolumeMenuButton popup

Overrides:
Source:
control-bar/volume-menu-button.js
Returns:

The popup that was created

Type
Popup

handleClick( [event])

This gets called when an VolumeMenuButton is "clicked". See ClickableComponent for more detailed information on what a click can be.

Parameters:
Name Type Argument Description
event EventTarget~Event <optional>

The keydown, tap, or click event that caused this function to be called.

Source:
control-bar/volume-menu-button.js
Listens to Events:
  • event:tap
  • event:click

handleMouseDown( [event])

Handle the mousedown and touchdown events on the VolumeBar

Parameters:
Name Type Argument Description
event EventTarget~Event <optional>

The mousedown or touchdown event that caused this to run.

Source:
control-bar/volume-menu-button.js
Listens to Events:
  • event:mousedown
  • event:touchdown

handleMouseUp( [event])

Handle the mouseup and touchend events on the VolumeBar

Parameters:
Name Type Argument Description
event EventTarget~Event <optional>

The mouseup or touchend event that caused this to run.

Source:
control-bar/volume-menu-button.js
Listens to Events:
  • event:mouseup
  • event:touchend

update()

Update the Popup that this button is attached to.

Inherited From:
Source:
popup/popup-button.js