diff --git a/Yattee/Views/Playlist/UnifiedPlaylistDetailView.swift b/Yattee/Views/Playlist/UnifiedPlaylistDetailView.swift index aa9af67a..e720b0ce 100644 --- a/Yattee/Views/Playlist/UnifiedPlaylistDetailView.swift +++ b/Yattee/Views/Playlist/UnifiedPlaylistDetailView.swift @@ -1221,8 +1221,17 @@ struct UnifiedPlaylistDetailView: View { private func playAll() { guard !videos.isEmpty, let appEnvironment else { return } + // In shuffle mode start from a random video (#988). Rotate rather than + // pick an index so every other video stays in the queue instead of + // being pushed to history as "already played". + var orderedVideos = videos + if appEnvironment.playerService.state.queueMode == .shuffle { + let start = Int.random(in: 0..