Class: shaka.ui.MediaSession

Constructor

new MediaSession(controlsnon-null)

Parameters:
Name Type Description
controls shaka.ui.Controls
Implements:
Source:

Members

actionsHandled_ :Set<string>

Type:
  • Set<string>
Source:

enabled_ :boolean

Type:
  • boolean
Source:

supported_ :boolean

Type:
  • boolean
Source:

supportsChapterInfo_ :boolean

Type:
  • boolean
Source:

video_ :HTMLVideoElement

Type:
  • HTMLVideoElement
Source:

Methods

addMediaSessionHandler(type, callbackopt, nullable)

Parameters:
Name Type Attributes Default Description
type string
callback ?function()= <optional>
<nullable>
null
Source:

clearPositionState_()

Source:

commonActionHandler(detailsnon-null)

Parameters:
Name Type Description
details !{action: string, seekOffset: ?number, seekTime: ?number}
Source:

configure(confignon-null)

Parameters:
Name Type Description
config shaka.extern.UIConfiguration
Source:

getMediaMetadata() → {!{title: string, artist: string, album: string, artwork: Object, chapterInfo: ?Object}}

Source:
Returns:
Type
!{title: string, artist: string, album: string, artwork: Object, chapterInfo: ?Object}

init_()

Source:

release()

Request that this object release all internal references.
Implements:
Source:

setupChapters(chaptersnon-null)

Parameters:
Name Type Description
chapters Array<!shaka.extern.Chapter>
Source:

setupMediaSessionActions_()

Source:

setupMediaSessionMetadata_()

Source:

setupMediaSessionPosition_()

Source:

setupPoster(imageUrl)

Parameters:
Name Type Description
imageUrl string
Source:

setupTitle(title)

Parameters:
Name Type Description
title string
Source:

stop_()

Source: