Skip to content

Commit

Permalink
fix(UI): Fix playback restarts in safari when click on seekbar end (#…
Browse files Browse the repository at this point in the history
…5527)

Fixes #5080
  • Loading branch information
avelad authored Aug 24, 2023
1 parent cdf60aa commit 4235658
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion ui/seek_bar.js
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,13 @@ shaka.ui.SeekBar = class extends shaka.ui.RangeElement {
* @private {shaka.util.Timer}
*/
this.seekTimer_ = new shaka.util.Timer(() => {
this.video.currentTime = this.getValue();
let newCurrentTime = this.getValue();
if (!this.player.isLive()) {
if (newCurrentTime == this.video.duration) {
newCurrentTime -= 0.001;
}
}
this.video.currentTime = newCurrentTime;
});


Expand Down

0 comments on commit 4235658

Please sign in to comment.