[Android] Show 'Sort by' option as an action

Geoffrey Métais git at videolan.org
Mon Mar 16 15:58:30 CET 2015


vlc-ports/android | branch: master | Geoffrey Métais <geoffrey.metais at gmail.com> | Mon Mar 16 15:51:04 2015 +0100| [01554881552ff3f770f6addd2186d7a2e16edae2] | committer: Geoffrey Métais

Show 'Sort by' option as an action

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

 vlc-android/res/menu/media_library.xml                          |    3 ++-
 vlc-android/src/org/videolan/vlc/gui/DirectoryViewFragment.java |    3 +--
 2 files changed, 3 insertions(+), 3 deletions(-)

diff --git a/vlc-android/res/menu/media_library.xml b/vlc-android/res/menu/media_library.xml
index d8d7d9f..6532e32 100644
--- a/vlc-android/res/menu/media_library.xml
+++ b/vlc-android/res/menu/media_library.xml
@@ -27,7 +27,8 @@
     <item
         android:title="@string/sortby"
         android:icon="@drawable/ic_menu_sortby"
-        android:id="@+id/ml_menu_sortby">
+        android:id="@+id/ml_menu_sortby"
+        vlc:showAsAction="ifRoom">
         <menu>
             <item
                 android:id="@+id/ml_menu_sortby_name"
diff --git a/vlc-android/src/org/videolan/vlc/gui/DirectoryViewFragment.java b/vlc-android/src/org/videolan/vlc/gui/DirectoryViewFragment.java
index 757a6cf..1748432 100644
--- a/vlc-android/src/org/videolan/vlc/gui/DirectoryViewFragment.java
+++ b/vlc-android/src/org/videolan/vlc/gui/DirectoryViewFragment.java
@@ -58,7 +58,7 @@ import android.widget.AdapterView.AdapterContextMenuInfo;
 import android.widget.AdapterView.OnItemLongClickListener;
 import android.widget.ListView;
 
-public class DirectoryViewFragment extends BrowserFragment implements IRefreshable, ISortable, SwipeRefreshLayout.OnRefreshListener, AdapterView.OnItemClickListener {
+public class DirectoryViewFragment extends BrowserFragment implements IRefreshable, SwipeRefreshLayout.OnRefreshListener, AdapterView.OnItemClickListener {
     public final static String TAG = "VLC/DirectoryViewFragment";
 
     private DirectoryAdapter mDirectoryAdapter;
@@ -234,7 +234,6 @@ public class DirectoryViewFragment extends BrowserFragment implements IRefreshab
         }
     }
 
-    @Override
     public void sortBy(int sortby) {
         // TODO
         Util.toaster(getActivity(), R.string.notavailable);



More information about the Android mailing list