Constructor
new VolumeMenuButton(player, optionsopt)
Creates an instance of this class.
Parameters:
| Name | Type | Attributes | Default | Description |
|---|---|---|---|---|
player |
Player | The |
||
options |
Object |
<optional> |
{} | The key/value store of player options. |
Extends
Members
-
volumeUpdate
-
Methods
-
attachVolumeBarEvents()
-
Add events listeners to the created
VolumeBar. -
buildCSSClass() → {string}
-
Builds the default DOM
className.Returns:
string -The DOM
classNamefor this object.- Overrides:
-
createEl() → {Element}
-
Create the
PopupButtons DOM element.Returns:
Element -The element that gets created.
- Inherited From:
-
createPopup() → {Popup}
-
Create the VolumeMenuButton popup
- Overrides:
-
handleClick(eventopt)
-
This gets called when an
VolumeMenuButtonis "clicked". See ClickableComponent for more detailed information on what a click can be.Parameters:
Name Type Attributes Description eventEventTarget~Event <optional>
The
keydown,tap, orclickevent that caused this function to be called.Listens to Events:
- event:tap
- event:click
-
handleMouseDown(eventopt)
-
Handle the
mousedownandtouchdownevents on theVolumeBarParameters:
Name Type Attributes Description eventEventTarget~Event <optional>
The
mousedownortouchdownevent that caused this to run.Listens to Events:
- event:mousedown
- event:touchdown
-
handleMouseUp(eventopt)
-
Handle the
mouseupandtouchendevents on theVolumeBarParameters:
Name Type Attributes Description eventEventTarget~Event <optional>
The
mouseuportouchendevent that caused this to run.Listens to Events:
- event:mouseup
- event:touchend
-
update()
-
Update the
Popupthat this button is attached to.- Inherited From: