[Android] Set Uri variable when switching from audio

Geoffrey Métais git at videolan.org
Mon Mar 7 15:46:37 CET 2016


vlc-android | branch: master | Geoffrey Métais <geoffrey.metais at gmail.com> | Mon Mar  7 14:41:15 2016 +0100| [a0d2d87bd2932f6ea9feb400d8952cdba0590993] | committer: Geoffrey Métais

Set Uri variable when switching from audio

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

 vlc-android/src/org/videolan/vlc/gui/video/VideoPlayerActivity.java | 6 ++++++
 1 file changed, 6 insertions(+)

diff --git a/vlc-android/src/org/videolan/vlc/gui/video/VideoPlayerActivity.java b/vlc-android/src/org/videolan/vlc/gui/video/VideoPlayerActivity.java
index 7900d15..9c94b9d 100644
--- a/vlc-android/src/org/videolan/vlc/gui/video/VideoPlayerActivity.java
+++ b/vlc-android/src/org/videolan/vlc/gui/video/VideoPlayerActivity.java
@@ -2819,6 +2819,12 @@ public class VideoPlayerActivity extends AppCompatActivity implements IVLCVout.C
         } else {
             mService.addCallback(this);
             mService.loadLastPlaylist(PlaybackService.TYPE_VIDEO);
+            MediaWrapper mw = mService.getCurrentMediaWrapper();
+            if (mw == null) {
+                finish();
+                return;
+            }
+            mUri = mService.getCurrentMediaWrapper().getUri();
         }
         if (itemTitle != null)
             title = itemTitle;



More information about the Android mailing list