mirror of
https://github.com/antebudimir/tempus.git
synced 2026-04-16 08:47:24 +00:00
feat: implemented additional sorting options for albums in the catalog screen
This commit is contained in:
parent
0f471a7b9f
commit
780f1c3a2e
6 changed files with 28 additions and 2 deletions
|
|
@ -169,6 +169,14 @@ public class AlbumCatalogueAdapter extends RecyclerView.Adapter<AlbumCatalogueAd
|
|||
albums.sort(Comparator.comparing(AlbumID3::getCreated));
|
||||
Collections.reverse(albums);
|
||||
break;
|
||||
case Constants.ALBUM_ORDER_BY_RECENTLY_PLAYED:
|
||||
albums.sort(Comparator.comparing(AlbumID3::getPlayed));
|
||||
Collections.reverse(albums);
|
||||
break;
|
||||
case Constants.ALBUM_ORDER_BY_MOST_PLAYED:
|
||||
albums.sort(Comparator.comparing(AlbumID3::getPlayCount));
|
||||
Collections.reverse(albums);
|
||||
break;
|
||||
}
|
||||
|
||||
notifyDataSetChanged();
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue