setup method

void setup(
  1. TextTracks trackListToWrap
)

Method to setup the TextTrack event listeners on a TextTrack list (TextTracks)

Implementation

void setup(TextTracks trackListToWrap) {
  _wrappedTrackList = trackListToWrap;
  innerList = trackListToWrap;

  _wrappedTrackList?.addEventListener(TextTracksEventTypes.ADDTRACK, forwardingkEventListener);
  _wrappedTrackList?.addEventListener(TextTracksEventTypes.REMOVETRACK, forwardingkEventListener);
  _wrappedTrackList?.addEventListener(TextTracksEventTypes.CHANGE, forwardingkEventListener);
}