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
className
for this object.- Overrides:
-
createEl() → {Element}
-
Create the
PopupButton
s 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
VolumeMenuButton
is "clicked". See ClickableComponent for more detailed information on what a click can be.Parameters:
Name Type Attributes Description event
EventTarget~Event <optional>
The
keydown
,tap
, orclick
event that caused this function to be called.Listens to Events:
- event:tap
- event:click
-
handleMouseDown(eventopt)
-
Handle the
mousedown
andtouchdown
events on theVolumeBar
Parameters:
Name Type Attributes Description event
EventTarget~Event <optional>
The
mousedown
ortouchdown
event that caused this to run.Listens to Events:
- event:mousedown
- event:touchdown
-
handleMouseUp(eventopt)
-
Handle the
mouseup
andtouchend
events on theVolumeBar
Parameters:
Name Type Attributes Description event
EventTarget~Event <optional>
The
mouseup
ortouchend
event that caused this to run.Listens to Events:
- event:mouseup
- event:touchend
-
update()
-
Update the
Popup
that this button is attached to.- Inherited From: