[Android] UI : Use network menu icon

Alexandre Perraud git at videolan.org
Wed Feb 11 19:34:20 CET 2015


vlc-ports/android | branch: master | Alexandre Perraud <4leyx4ndre at gmail.com> | Wed Feb 11 15:57:42 2015 +0100| [22cdd18b8cbff6ae10784e965a71bf37d2afee6b] | committer: Alexandre Perraud

UI : Use network menu icon

> http://git.videolan.org/gitweb.cgi/vlc-ports/android.git/?a=commit;h=22cdd18b8cbff6ae10784e965a71bf37d2afee6b
---

 vlc-android/res/values/attrs.xml                                 |    1 +
 vlc-android/res/values/styles.xml                                |    2 ++
 vlc-android/src/org/videolan/vlc/gui/SidebarAdapter.java         |    4 ++--
 vlc-android/src/org/videolan/vlc/gui/network/NetworkAdapter.java |    2 +-
 4 files changed, 6 insertions(+), 3 deletions(-)

diff --git a/vlc-android/res/values/attrs.xml b/vlc-android/res/values/attrs.xml
index 00ca621..33acdfa 100644
--- a/vlc-android/res/values/attrs.xml
+++ b/vlc-android/res/values/attrs.xml
@@ -49,6 +49,7 @@
     <attr name="ic_menu_folder" format="reference" />
     <attr name="ic_menu_history" format="reference" />
     <attr name="ic_menu_openmrl" format="reference" />
+    <attr name="ic_menu_network" format="reference" />
     <attr name="ic_menu_preferences" format="reference" />
     <attr name="ic_menu_cone" format="reference" />
     <attr name="ic_move_media" format="reference" />
diff --git a/vlc-android/res/values/styles.xml b/vlc-android/res/values/styles.xml
index 38b93ca..ff7c78b 100644
--- a/vlc-android/res/values/styles.xml
+++ b/vlc-android/res/values/styles.xml
@@ -68,6 +68,7 @@
         <item name="ic_menu_folder">@drawable/ic_menu_folder</item>
         <item name="ic_menu_history">@drawable/ic_menu_history</item>
         <item name="ic_menu_openmrl">@drawable/ic_menu_goto</item>
+        <item name="ic_menu_network">@drawable/ic_menu_network</item>
         <item name="ic_menu_preferences">@drawable/ic_menu_preferences</item>
         <item name="ic_menu_cone">@drawable/ic_menu_cone</item>
         <item name="ic_move_media">@drawable/ic_move_media</item>
@@ -136,6 +137,7 @@
         <item name="ic_menu_folder">@drawable/ic_menu_folder_w</item>
         <item name="ic_menu_history">@drawable/ic_menu_history_w</item>
         <item name="ic_menu_openmrl">@drawable/ic_menu_goto_w</item>
+        <item name="ic_menu_network">@drawable/ic_menu_network_w</item>
         <item name="ic_menu_preferences">@drawable/ic_menu_preferences_w</item>
         <item name="ic_menu_cone">@drawable/ic_menu_cone_w</item>
         <item name="ic_move_media">@drawable/ic_move_media_w</item>
diff --git a/vlc-android/src/org/videolan/vlc/gui/SidebarAdapter.java b/vlc-android/src/org/videolan/vlc/gui/SidebarAdapter.java
index 913fa31..0b4d223 100644
--- a/vlc-android/src/org/videolan/vlc/gui/SidebarAdapter.java
+++ b/vlc-android/src/org/videolan/vlc/gui/SidebarAdapter.java
@@ -82,9 +82,9 @@ public class SidebarAdapter extends BaseAdapter {
         entries = new ArrayList<SidebarEntry>();
         entries.add(new SidebarEntry(SidebarEntry.ID_VIDEO, R.string.video, R.attr.ic_menu_video, SidebarEntry.TYPE_FRAGMENT));
         entries.add(new SidebarEntry(SidebarEntry.ID_AUDIO, R.string.audio, R.attr.ic_menu_audio, SidebarEntry.TYPE_FRAGMENT));
-        entries.add(new SidebarEntry(SidebarEntry.ID_NETWORK, R.string.network_browsing, R.attr.ic_menu_openmrl, SidebarEntry.TYPE_FRAGMENT));
-        entries.add(new SidebarEntry(SidebarEntry.ID_MRL, R.string.open_mrl, R.attr.ic_menu_openmrl, SidebarEntry.TYPE_FRAGMENT));
         entries.add(new SidebarEntry(SidebarEntry.ID_DIRECTORIES, R.string.directories, R.attr.ic_menu_folder, SidebarEntry.TYPE_FRAGMENT));
+        entries.add(new SidebarEntry(SidebarEntry.ID_NETWORK, R.string.network_browsing, R.attr.ic_menu_network, SidebarEntry.TYPE_FRAGMENT));
+        entries.add(new SidebarEntry(SidebarEntry.ID_MRL, R.string.open_mrl, R.attr.ic_menu_openmrl, SidebarEntry.TYPE_FRAGMENT));
 //        entries.add(new SidebarEntry(SidebarEntry.ID_HISTORY, R.string.history, R.attr.ic_menu_history, SidebarEntry.TYPE_FRAGMENT));
         sidebarFragments = new ArrayList<String>();
         for(SidebarEntry e : entries) {
diff --git a/vlc-android/src/org/videolan/vlc/gui/network/NetworkAdapter.java b/vlc-android/src/org/videolan/vlc/gui/network/NetworkAdapter.java
index 6da169d..e22d50c 100644
--- a/vlc-android/src/org/videolan/vlc/gui/network/NetworkAdapter.java
+++ b/vlc-android/src/org/videolan/vlc/gui/network/NetworkAdapter.java
@@ -186,7 +186,7 @@ public class NetworkAdapter extends  RecyclerView.Adapter<RecyclerView.ViewHolde
             case MediaWrapper.TYPE_AUDIO:
                 return R.drawable.ic_menu_audio;
             case MediaWrapper.TYPE_DIR:
-                return R.drawable.ic_menu_folder;
+                return R.drawable.ic_menu_network;
             case MediaWrapper.TYPE_VIDEO:
                 return R.drawable.ic_menu_video;
             case MediaWrapper.TYPE_SUBTITLE:



More information about the Android mailing list