Android SDK - Player events



Player events (Android)

onPlayerPlaybackPermission

Sent each time any playback request has failed or if the initial playback attempt has succeeded.

onPlayerStart

Sent the first time the Player attempts to start the playback, either because of user interaction, an autoplay parameter or an API call (e.g play(), loadContent(), etc.)

onPlayerVideoChange

Sent when a new video has been loaded in the Player. (e.g. after calling loadContent({ video: 'xID' }), or at player start-up).

onPlayerEnd

Sent when the playback of the content video, and eventual post-roll ad video is completed.

onFullscreenRequested

Sent when the fullscreen mode is requested.

onPlayerVolumeChange

Sent when the volume level or mute state changes.

onPlayerPlaybackSpeedChange

Sent when the playback speed changes.

onPlayerScaleModeChange

Sent when the scale mode of the player changes after using setScaleMode().

onPlayerError

Sent when the player triggers an error.

Video events (Android)

onVideoProgress

Sent when the browser is fetching the media data.

onVideoQualitiesReady

Sent when video qualities are available.

onVideoSubtitlesReady

Sent when subtitles are available.

onVideoDurationChange

Sent when the duration property of the video becomes available or changes after a new video load.

onVideoPlay

Sent when the playback state of the content video is no longer paused, as a result of the play method or the autoplay attribute.

onVideoPlaying

Sent when the content video starts playing, after the play or waiting event

onVideoPause

Sent when the video playback has paused.

onVideoSeekStart

Sent when the player starts to seek to another position in the video timeline.

onVideoSeekEnd

Sent when the player has completed a seeking operation.

onVideoStart

Sent when the player begins playback of the content video.

onVideoTimeChange

Sent when the playback position changes.

onVideoEnd

Sent when the Player completes playback of the content video.

onVideoQualityChange

Sent when the video quality changes.

onVideoSubtitlesChange

Sent when the current subtitles change.

onVideoBuffering

Sent when the player has to temporarily stop video playback for further buffering of content.

Ad events (Android)

onAdReadyToFetch

Sent a few seconds before an request is made:
– First preroll: 2 sec – Consecutive preroll: 4 sec – Midroll & postroll: 6 sec

Important: Only sent when Player setting enable_wait_for_custom_config
is true.

onAdCompanionsReady

Sent when a companion ad is received. Companion ads should be played in sync with the main ad (linear/non-linear) by listening to events AD_START and AD_END.

onAdLoaded

Sent when the Player has loaded and buffered the creative’s media and assets either fully or to the extent that it is ready to play the media.

onAdstart

Sent when the player begins playback of an ad video.

onAdPlay

Sent when the ad playback starts or continues after being in a paused state.

onAdPause

Sent when the player pauses an ad.

onAdEnd

Sent when the player completes playback of an ad.

onAdTimeChange

Sent when the playback position of an ad changes.

onAdImpression

Sent when the first ad frame is displayed.

onAdClick

Sent when a user clicks on a video ad.

onAdDurationChange

Sent when the duration property of the video advertisement becomes available or changes after a new video load.