Skip to end of metadata
Go to start of metadata

You are viewing an old version of this content. View the current version.

Compare with Current View Version History

« Previous Version 2 Next »

Methods

MethodDescription
TouchCastPlayerAPI.embed()This method will allow you to embed players into any webpage.
TouchCastPlayerAPI.doAction()This method will allow you to control the player.
TouchCastPlayerAPI.Event.subscribe()This method will allow you to subscribe to a Player Api event, which will fire on different types of actions.
TouchCastPlayerAPI.Event.unsubscribe()This method will allow you to unsubscribe from any Player Api event you have previously subscribed.

Event Types

Click here to get more info about each event.

Event TypeDescription
TouchCastPlayerAPI.events.EMBED_PLAYER_ADDED_TO_DOMThis event is dispatched when an embed player was added to the DOM, but not yet fully initialized.
TouchCastPlayerAPI.events.EMBED_PLAYER_FULLY_READYThis event is dispatched when an embed player is fully initialized and ready to be used. At this stage is safe to use the TouchCastPlayerAPI.doAction() method.
TouchCastPlayerAPI.events.TIME_UPDATEThis event is dispatched during playback of an embed player. Use this to track playback time.
TouchCastPlayerAPI.events.VIDEO_ENDEDThis event is dispatched when an embed player has finised playback and reached video end.
TouchCastPlayerAPI.events.VIDEO_PLAYEDThis event is dispatched when an embed player has started playback, even if it's for the very first time or just a simple resume.
TouchCastPlayerAPI.events.VIDEO_PAUSEDThis event is dispatched when an embed player has finished playback and reached video end.
  • No labels