onAdaptation_(from, to) {
    // Delay the 'adaptation' event so that StreamingEngine has time to absorb
    // the changes before the user tries to query it.
    const data = new Map()
        .set('oldTrack', from)
        .set('newTrack', to);
    const event = shaka.Player.makeEvent_(
        shaka.util.FakeEvent.EventName.Adaptation, data);
    this.delayDispatchEvent_(event);
  }
Dispatches an 'adaptation' event.
@param {?shaka.extern.Track} from
@param {shaka.extern.Track} to
@private