AudioPlayerDisplayDelegate
public protocol AudioPlayerDisplayDelegate : AnyObject
The DisplayPlayerAgent delegate is used to notify observers when a player template directive is received.
-
Tells the delegate that the specified template should be displayed.
Declaration
Swift
func audioPlayerDisplayShouldRender(template: AudioPlayerDisplayTemplate, completion: @escaping (AnyObject?) -> Void)
Parameters
template
The player template to display.
-
Tells the delegate that the specified template should be removed from the screen.
Declaration
Swift
func audioPlayerDisplayDidClear(template: AudioPlayerDisplayTemplate)
Parameters
template
The template to remove from the screen.
-
Tells the delegate that the specified template should be updated from the screen.
Declaration
Swift
func audioPlayerDisplayShouldUpdateMetadata(payload: Data, header: Downstream.Header)
Parameters
template
The template to update the screen.
header
The header of the originally handled directive.
-
Tells the delegate that the displayed template should show lyrics
Declaration
Swift
func audioPlayerDisplayShouldShowLyrics(header: Downstream.Header, completion: @escaping (Bool) -> Void)
Parameters
header
The header of the originally handled directive.
completion
Whether succeeded or not
-
Tells the delegate that the displayed template should hide lyrics
Declaration
Swift
func audioPlayerDisplayShouldHideLyrics(header: Downstream.Header, completion: @escaping (Bool) -> Void)
Parameters
header
The header of the originally handled directive.
completion
Whether succeeded or not
-
Tells the delegate that the displayed template should scroll with given direction.
Declaration
Swift
func audioPlayerDisplayShouldControlLyricsPage(direction: AudioPlayerDisplayControlPayload.Direction, header: Downstream.Header, completion: @escaping (Bool) -> Void)
Parameters
direction
Direction to scroll.
header
The header of the originally handled directive.
completion
Whether succeeded or not
-
<#Description#>
Declaration
Swift
func audioPlayerIsLyricsVisible(completion: @escaping (Bool) -> Void)
Parameters
completion
<#completion description#>