Ad playback events

TVSDK dispatches ad-playback events in response to ad-related operations such as when an ad starts playing.

To be notified about all ad-playback related events, register an implementation of MediaPlayer.AdPlaybackEventListener including the following callbacks.

TIP

When ads are inserted into or removed from the media, TVSDK dispatches the playback event onTimelineUpdated.

Event Meaning
onAdBreakComplete (AdBreak adBreak) An ad break has played completely.
onAdBreakSkipped An ad break was skipped during playback.
onAdBreakStart (AdBreak adBreak) An ad break has started.
onAdClick (AdBreak adBreak, Ad ad, AdClick adClick) The user has clicked the ad. Provides information to your application about the ad that the user clicked, in response to your application calling notifyClick on the MediaPlayerView.
onAdComplete (AdBreak adBreak, Ad ad) An ad has played completely.
onAdProgress (AdBreak adBreak, Ad ad, int percentage) Ad playback has progressed. Dispatched multiple times while an ad plays.
onAdStart (AdBreak adBreak, Ad ad) An ad has started.

On this page

Adobe Summit Banner

A virtual event April 27-28.

Expand your skills and get inspired.

Register for free
Adobe Summit Banner

A virtual event April 27-28.

Expand your skills and get inspired.

Register for free
Adobe Maker Awards Banner

Time to shine!

Apply now for the 2021 Adobe Experience Maker Awards.

Apply now
Adobe Maker Awards Banner

Time to shine!

Apply now for the 2021 Adobe Experience Maker Awards.

Apply now