[Android] Improve DVD/BD menus support
Geoffrey Métais
git at videolan.org
Thu Apr 30 11:02:34 CEST 2020
vlc-android | branch: 3.2.x | Geoffrey Métais <geoffrey.metais at gmail.com> | Thu Apr 30 11:01:10 2020 +0200| [c92d30ce19d974835572995e7c171d845da88121] | committer: Geoffrey Métais
Improve DVD/BD menus support
> https://code.videolan.org/videolan/vlc-android/commit/c92d30ce19d974835572995e7c171d845da88121
---
vlc-android/src/org/videolan/vlc/gui/video/VideoPlayerActivity.kt | 8 ++++++--
1 file changed, 6 insertions(+), 2 deletions(-)
diff --git a/vlc-android/src/org/videolan/vlc/gui/video/VideoPlayerActivity.kt b/vlc-android/src/org/videolan/vlc/gui/video/VideoPlayerActivity.kt
index 4ae185826..a5db54262 100644
--- a/vlc-android/src/org/videolan/vlc/gui/video/VideoPlayerActivity.kt
+++ b/vlc-android/src/org/videolan/vlc/gui/video/VideoPlayerActivity.kt
@@ -2686,13 +2686,13 @@ open class VideoPlayerActivity : AppCompatActivity(), IPlaybackSettingsControlle
private fun updateNavStatus() {
if (service == null) return
- isNavMenu = false
menuIdx = -1
runIO(Runnable {
val titles = service?.titles
runOnMainThread(Runnable {
if (isFinishing || !lifecycle.currentState.isAtLeast(Lifecycle.State.STARTED)) return at Runnable
+ isNavMenu = false
if (titles != null) {
val currentIdx = service?.titleIdx ?: return at Runnable
for (i in titles.indices) {
@@ -2702,7 +2702,11 @@ open class VideoPlayerActivity : AppCompatActivity(), IPlaybackSettingsControlle
break
}
}
- isNavMenu = menuIdx == currentIdx
+ val interactive = service?.mediaplayer?.let {
+ it.titles[it.title].isInteractive
+ } ?: false
+ isNavMenu = menuIdx == currentIdx || interactive
+
}
if (isNavMenu) {
More information about the Android
mailing list