[Android] Handle FS types in onNewIntent
Geoffrey Métais
git at videolan.org
Thu Apr 7 15:09:40 CEST 2016
vlc-android | branch: master | Geoffrey Métais <geoffrey.metais at gmail.com> | Thu Apr 7 14:36:47 2016 +0200| [69c1b89a6e8513b846b34ce25c1c290cd8e4a999] | committer: Geoffrey Métais
Handle FS types in onNewIntent
> https://code.videolan.org/videolan/vlc-android/commit/69c1b89a6e8513b846b34ce25c1c290cd8e4a999
---
.../src/org/videolan/vlc/gui/video/VideoPlayerActivity.java | 7 +++++++
1 file changed, 7 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 a9ec6cc..03d2eb0 100644
--- a/vlc-android/src/org/videolan/vlc/gui/video/VideoPlayerActivity.java
+++ b/vlc-android/src/org/videolan/vlc/gui/video/VideoPlayerActivity.java
@@ -545,6 +545,13 @@ public class VideoPlayerActivity extends AppCompatActivity implements IVLCVout.C
(Uri) intent.getExtras().getParcelable(PLAY_EXTRA_ITEM_LOCATION) : intent.getData();
if (uri == null || uri.equals(mUri))
return;
+ if (TextUtils.equals("file", uri.getScheme()) && uri.getPath().startsWith("/sdcard")) {
+ Uri convertedUri = FileUtils.convertLocalUri(uri);
+ if (convertedUri == null || convertedUri.equals(mUri))
+ return;
+ else
+ uri = convertedUri;
+ }
mUri = uri;
initUI();
setOverlayProgress();
More information about the Android
mailing list