|
@@ -1136,9 +1136,7 @@ export default {
|
|
this.video.player.getCurrentTime() <
|
|
this.video.player.getCurrentTime() <
|
|
this.song.skipDuration
|
|
this.song.skipDuration
|
|
) {
|
|
) {
|
|
- return this.video.player.seekTo(
|
|
|
|
- this.song.skipDuration
|
|
|
|
- );
|
|
|
|
|
|
+ return this.seekTo(this.song.skipDuration);
|
|
}
|
|
}
|
|
} else if (event.data === 2) {
|
|
} else if (event.data === 2) {
|
|
this.video.paused = true;
|
|
this.video.paused = true;
|
|
@@ -1522,8 +1520,7 @@ export default {
|
|
break;
|
|
break;
|
|
case "skipToLast10Secs":
|
|
case "skipToLast10Secs":
|
|
this.skipToLast10SecsPressed = true;
|
|
this.skipToLast10SecsPressed = true;
|
|
- if (this.video.paused) this.pauseVideo(false);
|
|
|
|
- this.video.player.seekTo(
|
|
|
|
|
|
+ this.seekTo(
|
|
this.song.duration - 10 + this.song.skipDuration
|
|
this.song.duration - 10 + this.song.skipDuration
|
|
);
|
|
);
|
|
break;
|
|
break;
|
|
@@ -1541,6 +1538,10 @@ export default {
|
|
}
|
|
}
|
|
this.settings("play");
|
|
this.settings("play");
|
|
},
|
|
},
|
|
|
|
+ seekTo(position) {
|
|
|
|
+ if (!this.video.paused) this.settings("play");
|
|
|
|
+ this.video.player.seekTo(position);
|
|
|
|
+ },
|
|
changeVolume() {
|
|
changeVolume() {
|
|
const volume = this.volumeSliderValue;
|
|
const volume = this.volumeSliderValue;
|
|
localStorage.setItem("volume", volume / 100);
|
|
localStorage.setItem("volume", volume / 100);
|