[Android] Add 'storages' header in file browser root

Geoffrey Métais git at videolan.org
Fri Nov 3 16:25:50 CET 2017


vlc-android | branch: 2.5.x | Geoffrey Métais <geoffrey.metais at gmail.com> | Fri Nov  3 15:30:18 2017 +0100| [cb46813b52a56bc4ab7a7c27088d1f5760cac0b8] | committer: Geoffrey Métais

Add 'storages' header in file browser root

(cherry picked from commit 2906e1e9cb45cb35258b71a9e4dc9da02b6f3fa8)

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

 vlc-android/res/values/strings.xml                                    | 1 +
 vlc-android/src/org/videolan/vlc/gui/browser/FileBrowserFragment.java | 1 +
 2 files changed, 2 insertions(+)

diff --git a/vlc-android/res/values/strings.xml b/vlc-android/res/values/strings.xml
index 36f6fabfd..5a5c55b4a 100644
--- a/vlc-android/res/values/strings.xml
+++ b/vlc-android/res/values/strings.xml
@@ -568,4 +568,5 @@
     <string name="recommendations">Recommendations</string>
     <string name="recommendations_desc">Recommendations cards on launcher</string>
     <string name="browser_quick_access">Quick Access</string>
+    <string name="browser_storages">Storages</string>
 </resources>
diff --git a/vlc-android/src/org/videolan/vlc/gui/browser/FileBrowserFragment.java b/vlc-android/src/org/videolan/vlc/gui/browser/FileBrowserFragment.java
index 5fac90758..04790e5f8 100644
--- a/vlc-android/src/org/videolan/vlc/gui/browser/FileBrowserFragment.java
+++ b/vlc-android/src/org/videolan/vlc/gui/browser/FileBrowserFragment.java
@@ -91,6 +91,7 @@ public class FileBrowserFragment extends BaseBrowserFragment {
                 final String storages[] = AndroidDevices.getMediaDirectories();
                 MediaWrapper directory;
                 final ArrayList<MediaLibraryItem> devices = new ArrayList<>(storages.length);
+                devices.add(new DummyItem(getString(R.string.browser_storages)));
                 for (String mediaDirLocation : storages) {
                     if (!(new File(mediaDirLocation).exists()))
                         continue;



More information about the Android mailing list