[Android] Prevent saving AB repeat when history is off

Nicolas Pomepuy git at videolan.org
Wed Mar 20 14:10:02 UTC 2024


vlc-android | branch: master | Nicolas Pomepuy <nicolas at videolabs.io> | Tue Mar 12 07:48:57 2024 +0100| [a856c56cd8f45eba2756c320fa2f59f1a91dbac3] | committer: Duncan McNamara

Prevent saving AB repeat when history is off

> https://code.videolan.org/videolan/vlc-android/commit/a856c56cd8f45eba2756c320fa2f59f1a91dbac3
---

 application/vlc-android/src/org/videolan/vlc/media/PlaylistManager.kt | 1 +
 1 file changed, 1 insertion(+)

diff --git a/application/vlc-android/src/org/videolan/vlc/media/PlaylistManager.kt b/application/vlc-android/src/org/videolan/vlc/media/PlaylistManager.kt
index 9a5e56d7a2..696c450b0f 100644
--- a/application/vlc-android/src/org/videolan/vlc/media/PlaylistManager.kt
+++ b/application/vlc-android/src/org/videolan/vlc/media/PlaylistManager.kt
@@ -1009,6 +1009,7 @@ class PlaylistManager(val service: PlaybackService) : MediaWrapperList.EventList
     fun getMediaList(): List<MediaWrapper> = mediaList.copy
 
     fun setABRepeatValue(media: MediaWrapper?, time: Long) {
+        if (settings.getBoolean(PLAYBACK_HISTORY, true)) return
         val value = abRepeat.value ?: ABRepeat()
         when {
             value.start == -1L -> {



More information about the Android mailing list