publishes a media control message


Boolean publishMediaControlMessage(Object data, [Array<String> instanceIds])


The Object data parameter is the transport control state payload sent to remote device(s). The data Object has the following properties:

  • state – An integer constant corresponding to the followingKONtx.mediaplayer.constants.states:
    • INIT : -1
    • PLAY : 0
    • PAUSE : 1
    • REWIND : 3
    • STOP : 4
    • BUFFERING : 5
    • INFOLOADED : 7
    • EOF : 8
    • UNKNOWN : 9
    • ERROR : 10
  • timeindex – An integer representing the current time index in seconds.
  • duration – An integer representing the total duration of the current clip in seconds.
  • humanDuration – A String that is the total duration matching the onscreen duration display.
  • isControlOnScreen – A Boolean that is true if the overlay controls are currently onscreen, and false otherwise.

If the optional parameter instanceIds is specified, the message should only be sent to the remote devices identified. No other devices receive the message. This parameter can be a String for a single instanceId, an Array<String> of instanceIds or null. If null, the message is sent to all connected remote devices that are subscribed to media transport control messages.


Returns true if sending the message is successful. Returns false otherwise.


Helper method to publish a media transport control message. Send the media transport control state to subscribed (or identified) devices so they can update their media transport control displays.

Table of Contents