diff --git a/lib/player/player.js b/lib/player/player.js index a7e2a1a8e..3b56423f5 100644 --- a/lib/player/player.js +++ b/lib/player/player.js @@ -427,6 +427,13 @@ shaka.player.Player.prototype.onPlaying_ = function(event) { shaka.log.debug('onPlaying_', event); shaka.timer.begin('playing'); + // Start rewind timer if playback rate should be negative and a rewind timer + // is not already set. + if (!this.rewindTimer_ && this.playbackRate_ < 0) { + this.video_.playbackRate = 0; + this.onRewindTimer_( + this.video_.currentTime, Date.now(), this.playbackRate_); + } if (this.buffering_) { this.endBufferingState_(); } @@ -673,7 +680,8 @@ shaka.player.Player.prototype.setPlaybackRate = function(rate) { if (rate >= 0) { // Slow-mo or fast-forward are handled natively by the UA. this.video_.playbackRate = rate; - } else { + // Only rewind when not paused. + } else if (!this.video_.paused) { // Rewind is not supported by any UA to date (2015), so we fake it. // http://crbug.com/33099 this.video_.playbackRate = 0;