[Android] Fix playback speed rate set to 1 when resuming
Nicolas Pomepuy
git at videolan.org
Tue Mar 26 15:44:31 CET 2019
vlc-android | branch: master | Nicolas Pomepuy <nicolas.pomepuy at gmail.com> | Wed Mar 20 09:42:33 2019 +0100| [c64c8fb033d6bcdee8b25de9d342bc59cb8e9827] | committer: Geoffrey Métais
Fix playback speed rate set to 1 when resuming
> https://code.videolan.org/videolan/vlc-android/commit/c64c8fb033d6bcdee8b25de9d342bc59cb8e9827
---
vlc-android/src/org/videolan/vlc/media/PlaylistManager.kt | 10 +++++-----
1 file changed, 5 insertions(+), 5 deletions(-)
diff --git a/vlc-android/src/org/videolan/vlc/media/PlaylistManager.kt b/vlc-android/src/org/videolan/vlc/media/PlaylistManager.kt
index e9ed30069..52811a88f 100644
--- a/vlc-android/src/org/videolan/vlc/media/PlaylistManager.kt
+++ b/vlc-android/src/org/videolan/vlc/media/PlaylistManager.kt
@@ -162,15 +162,15 @@ class PlaylistManager(val service: PlaybackService) : MediaWrapperList.EventList
repeating = settings.getInt(if (audio) "audio_repeating" else "media_repeating", REPEAT_NONE)
val position = settings.getInt(if (audio) "position_in_audio_list" else "position_in_media_list", 0)
savedTime = settings.getLong(if (audio) "position_in_song" else "position_in_media", -1)
+ if (!audio && position < playList.size && settings.getBoolean(PreferencesActivity.VIDEO_PAUSED, false)) {
+ playList[position].addFlags(MediaWrapper.MEDIA_PAUSED)
+ }
+ load(playList, position, true)
+ loadingLastPlaylist = false
if (!audio) {
- if (position < playList.size && settings.getBoolean(PreferencesActivity.VIDEO_PAUSED, false)) {
- playList[position].addFlags(MediaWrapper.MEDIA_PAUSED)
- }
val rate = settings.getFloat(PreferencesActivity.VIDEO_SPEED, player.getRate())
if (rate != 1.0f) player.setRate(rate, false)
}
- load(playList, position, true)
- loadingLastPlaylist = false
}
return true
}
More information about the Android
mailing list