From 1376850dbe9e25c7330dffc5ac7cfc2505ba4f1f Mon Sep 17 00:00:00 2001 From: nieve Date: Wed, 28 Aug 2024 01:13:53 -0400 Subject: [PATCH] option to autoplay playlist only --- src/components/WatchVideo.vue | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/src/components/WatchVideo.vue b/src/components/WatchVideo.vue index 4a09161f..00afd9c0 100644 --- a/src/components/WatchVideo.vue +++ b/src/components/WatchVideo.vue @@ -212,7 +212,11 @@
- +
@@ -424,7 +428,7 @@ export default { }, activated() { this.active = true; - this.selectedAutoPlay = this.getPreferenceBoolean("autoplay", false); + this.selectedAutoPlay = this.getPreferenceNumber("autoplay", 1); this.showComments = !this.getPreferenceBoolean("minimizeComments", false); this.showDesc = !this.getPreferenceBoolean("minimizeDescription", true); this.showRecs = !this.getPreferenceBoolean("minimizeRecommendations", false); @@ -623,8 +627,8 @@ export default { onVideoEnded() { if ( !this.selectedAutoLoop && - this.selectedAutoPlay && - (this.playlist?.relatedStreams?.length > 0 || this.video.relatedStreams.length > 0) + ((this.selectedAutoPlay >= 1 && this.playlist?.relatedStreams?.length > this.index) || + (this.selectedAutoPlay >= 2 && this.video.relatedStreams.length > 0)) ) { this.showToast(); }