Search in sources :

Example 1 with SuggestedHeaderView

use of com.simplecity.amp_library.ui.modelviews.SuggestedHeaderView in project Shuttle by timusus.

the class SuggestedFragment method getRecentlyAddedViewModels.

Observable<List<ViewModel>> getRecentlyAddedViewModels() {
    return Playlist.recentlyAddedPlaylist.getSongsObservable().flatMap(songs -> Observable.just(Operators.songsToAlbums(songs))).flatMapSingle(source -> Observable.fromIterable(source).sorted((a, b) -> ComparisonUtils.compareLong(b.songPlayCount, a.songPlayCount)).take(20).toList()).map(albums -> {
        if (!albums.isEmpty()) {
            List<ViewModel> viewModels = new ArrayList<>();
            SuggestedHeader recentlyAddedHeader = new SuggestedHeader(getString(R.string.recentlyadded), getString(R.string.suggested_recently_added_subtitle), Playlist.recentlyAddedPlaylist);
            SuggestedHeaderView recentlyAddedHeaderView = new SuggestedHeaderView(recentlyAddedHeader);
            recentlyAddedHeaderView.setClickListener(this);
            viewModels.add(recentlyAddedHeaderView);
            viewModels.addAll(Stream.of(albums).map(album -> {
                AlbumView albumView = new AlbumView(album, ViewType.ALBUM_CARD, requestManager);
                albumView.setClickListener(this);
                return albumView;
            }).toList());
            return viewModels;
        } else {
            return Collections.emptyList();
        }
    });
}
Also used : R(com.simplecity.amp_library.R) GridLayoutManager(android.support.v7.widget.GridLayoutManager) Bundle(android.os.Bundle) ViewModel(com.simplecityapps.recycler_adapter.model.ViewModel) SuggestedDividerDecoration(com.simplecity.amp_library.ui.views.SuggestedDividerDecoration) AndroidSchedulers(io.reactivex.android.schedulers.AndroidSchedulers) Song(com.simplecity.amp_library.model.Song) Optional(com.annimon.stream.Optional) RequestManager(com.bumptech.glide.RequestManager) MenuUtils(com.simplecity.amp_library.utils.MenuUtils) View(android.view.View) LogUtils(com.simplecity.amp_library.utils.LogUtils) Playlist(com.simplecity.amp_library.model.Playlist) PopupMenu(android.support.v7.widget.PopupMenu) ViewGroup(android.view.ViewGroup) SuggestedHeaderView(com.simplecity.amp_library.ui.modelviews.SuggestedHeaderView) MusicUtils(com.simplecity.amp_library.utils.MusicUtils) List(java.util.List) CompositeDisposable(io.reactivex.disposables.CompositeDisposable) Disposable(io.reactivex.disposables.Disposable) FragmentModule(com.simplecity.amp_library.dagger.module.FragmentModule) PermissionUtils(com.simplecity.amp_library.utils.PermissionUtils) Nullable(android.support.annotation.Nullable) Context(android.content.Context) SuggestedSongView(com.simplecity.amp_library.ui.modelviews.SuggestedSongView) Album(com.simplecity.amp_library.model.Album) Stream(com.annimon.stream.Stream) RecyclerListener(com.simplecityapps.recycler_adapter.recyclerview.RecyclerListener) EmptyView(com.simplecity.amp_library.ui.modelviews.EmptyView) ViewModelAdapter(com.simplecityapps.recycler_adapter.adapter.ViewModelAdapter) ViewType(com.simplecity.amp_library.ui.adapters.ViewType) ArrayList(java.util.ArrayList) Inject(javax.inject.Inject) SuppressLint(android.annotation.SuppressLint) SuggestedHeader(com.simplecity.amp_library.model.SuggestedHeader) Toast(android.widget.Toast) Observable(io.reactivex.Observable) UpgradeDialog(com.simplecity.amp_library.ui.dialog.UpgradeDialog) ShuttleUtils(com.simplecity.amp_library.utils.ShuttleUtils) LayoutInflater(android.view.LayoutInflater) AlbumView(com.simplecity.amp_library.ui.modelviews.AlbumView) TimeUnit(java.util.concurrent.TimeUnit) RecyclerView(android.support.v7.widget.RecyclerView) ShuttleApplication(com.simplecity.amp_library.ShuttleApplication) HorizontalRecyclerView(com.simplecity.amp_library.ui.modelviews.HorizontalRecyclerView) PlaylistDetailFragment(com.simplecity.amp_library.ui.detail.PlaylistDetailFragment) ComparisonUtils(com.simplecity.amp_library.utils.ComparisonUtils) DataManager(com.simplecity.amp_library.utils.DataManager) AlbumArtist(com.simplecity.amp_library.model.AlbumArtist) Operators(com.simplecity.amp_library.utils.Operators) Collections(java.util.Collections) SuggestedHeaderView(com.simplecity.amp_library.ui.modelviews.SuggestedHeaderView) AlbumView(com.simplecity.amp_library.ui.modelviews.AlbumView) ArrayList(java.util.ArrayList) ViewModel(com.simplecityapps.recycler_adapter.model.ViewModel) SuggestedHeader(com.simplecity.amp_library.model.SuggestedHeader)

Example 2 with SuggestedHeaderView

use of com.simplecity.amp_library.ui.modelviews.SuggestedHeaderView in project Shuttle by timusus.

the class SuggestedFragment method getFavoriteSongViewModels.

@SuppressLint("CheckResult")
Observable<List<ViewModel>> getFavoriteSongViewModels() {
    Observable<List<Song>> favoritesSongs = DataManager.getInstance().getFavoriteSongsRelay().take(20);
    return Observable.combineLatest(favoritesSongs, Playlist.favoritesPlaylist().filter(Optional::isPresent).map(Optional::get).toObservable(), (songs, playlist) -> {
        if (!songs.isEmpty()) {
            List<ViewModel> viewModels = new ArrayList<>();
            SuggestedHeader favoriteHeader = new SuggestedHeader(getString(R.string.fav_title), getString(R.string.suggested_favorite_subtitle), playlist);
            SuggestedHeaderView favoriteHeaderView = new SuggestedHeaderView(favoriteHeader);
            favoriteHeaderView.setClickListener(SuggestedFragment.this);
            viewModels.add(favoriteHeaderView);
            viewModels.add(favoriteRecyclerView);
            SongClickListener songClickListener = new SongClickListener(songs);
            favoriteRecyclerView.viewModelAdapter.setItems(Stream.of(songs).map(song -> {
                SuggestedSongView suggestedSongView = new SuggestedSongView(song, requestManager);
                suggestedSongView.setClickListener(songClickListener);
                return (ViewModel) suggestedSongView;
            }).toList());
            return viewModels;
        } else {
            return Collections.emptyList();
        }
    });
}
Also used : Optional(com.annimon.stream.Optional) SuggestedHeaderView(com.simplecity.amp_library.ui.modelviews.SuggestedHeaderView) ArrayList(java.util.ArrayList) SuggestedSongView(com.simplecity.amp_library.ui.modelviews.SuggestedSongView) List(java.util.List) ArrayList(java.util.ArrayList) ViewModel(com.simplecityapps.recycler_adapter.model.ViewModel) SuggestedHeader(com.simplecity.amp_library.model.SuggestedHeader) SuppressLint(android.annotation.SuppressLint)

Example 3 with SuggestedHeaderView

use of com.simplecity.amp_library.ui.modelviews.SuggestedHeaderView in project Shuttle by timusus.

the class SuggestedFragment method onCreateView.

@Override
public View onCreateView(LayoutInflater inflater, ViewGroup container, Bundle savedInstanceState) {
    if (recyclerView == null) {
        recyclerView = (RecyclerView) inflater.inflate(R.layout.fragment_suggested, container, false);
        recyclerView.addItemDecoration(new SuggestedDividerDecoration(getResources()));
        recyclerView.setRecyclerListener(new RecyclerListener());
        int spanCount = ShuttleUtils.isTablet() ? 12 : 6;
        GridLayoutManager gridLayoutManager = new GridLayoutManager(getContext(), spanCount);
        gridLayoutManager.setSpanSizeLookup(new GridLayoutManager.SpanSizeLookup() {

            @Override
            public int getSpanSize(int position) {
                if (!adapter.items.isEmpty() && position >= 0) {
                    ViewModel item = adapter.items.get(position);
                    if (item instanceof HorizontalRecyclerView || item instanceof SuggestedHeaderView || (item instanceof AlbumView && item.getViewType() == ViewType.ALBUM_LIST) || (item instanceof AlbumView && item.getViewType() == ViewType.ALBUM_LIST_SMALL) || item instanceof EmptyView) {
                        return spanCount;
                    }
                    if (item instanceof AlbumView && item.getViewType() == ViewType.ALBUM_CARD_LARGE) {
                        return 3;
                    }
                }
                return 2;
            }
        });
        recyclerView.setLayoutManager(gridLayoutManager);
    }
    if (recyclerView.getAdapter() != adapter) {
        recyclerView.setAdapter(adapter);
    }
    return recyclerView;
}
Also used : GridLayoutManager(android.support.v7.widget.GridLayoutManager) SuggestedHeaderView(com.simplecity.amp_library.ui.modelviews.SuggestedHeaderView) AlbumView(com.simplecity.amp_library.ui.modelviews.AlbumView) RecyclerListener(com.simplecityapps.recycler_adapter.recyclerview.RecyclerListener) ViewModel(com.simplecityapps.recycler_adapter.model.ViewModel) SuggestedDividerDecoration(com.simplecity.amp_library.ui.views.SuggestedDividerDecoration) EmptyView(com.simplecity.amp_library.ui.modelviews.EmptyView) SuppressLint(android.annotation.SuppressLint) HorizontalRecyclerView(com.simplecity.amp_library.ui.modelviews.HorizontalRecyclerView)

Example 4 with SuggestedHeaderView

use of com.simplecity.amp_library.ui.modelviews.SuggestedHeaderView in project Shuttle by timusus.

the class SuggestedFragment method refreshAdapterItems.

void refreshAdapterItems() {
    PermissionUtils.RequestStoragePermissions(() -> {
        if (getActivity() != null && isAdded()) {
            subscription = new CompositeSubscription();
            Observable<Playlist> mostPlayedPlaylistObservable = Observable.fromCallable(Playlist::mostPlayedPlaylist).subscribeOn(Schedulers.io()).cache();
            Observable<List<Song>> mostPlayedSongsObservable = mostPlayedPlaylistObservable.filter(playlist -> playlist != null).flatMap(playlist -> playlist.getSongsObservable(getContext())).cache();
            Observable<List<AdaptableItem>> mostPlayedItemsObservable = mostPlayedPlaylistObservable.flatMap(playlist -> {
                SuggestedHeader mostPlayedHeader = new SuggestedHeader(getString(R.string.mostplayed), getString(R.string.suggested_most_played_songs_subtitle), playlist);
                SuggestedHeaderView mostPlayedHeaderView = new SuggestedHeaderView(mostPlayedHeader);
                return mostPlayedSongsObservable.map(songs -> {
                    List<AdaptableItem> items = new ArrayList<>();
                    if (!songs.isEmpty()) {
                        items.add(mostPlayedHeaderView);
                        items.add(mostPlayedRecyclerView);
                    }
                    return items;
                });
            }).switchIfEmpty(Observable.just(Collections.emptyList()));
            Observable<List<AdaptableItem>> recentlyPlayedAlbums = Observable.fromCallable(Playlist::recentlyPlayedPlaylist).subscribeOn(Schedulers.io()).filter(playlist -> playlist != null).flatMap(playlist -> {
                SuggestedHeader recentlyPlayedHeader = new SuggestedHeader(getString(R.string.suggested_recent_title), getString(R.string.suggested_recent_subtitle), playlist);
                SuggestedHeaderView recentlyPlayedHeaderView = new SuggestedHeaderView(recentlyPlayedHeader);
                return playlist.getSongsObservable(getContext()).flatMap(songs -> Observable.just(Operators.songsToAlbums(songs))).flatMap(Observable::from).sorted((a, b) -> ComparisonUtils.compareLong(b.lastPlayed, a.lastPlayed)).limit(6).flatMap(album -> album.getSongsObservable().map(songs -> {
                    album.numSongs = songs.size();
                    return album;
                })).sorted((a, b) -> ComparisonUtils.compareLong(b.lastPlayed, a.lastPlayed)).filter(album -> album.numSongs > 0).map(album -> (AdaptableItem) new AlbumView(album, ViewType.ALBUM_LIST_SMALL, requestManager)).toList().map(adaptableItems -> {
                    if (!adaptableItems.isEmpty()) {
                        adaptableItems.add(0, recentlyPlayedHeaderView);
                    }
                    return adaptableItems;
                });
            }).switchIfEmpty(Observable.just(Collections.emptyList()));
            Observable<Playlist> favouritesPlaylistObservable = Observable.fromCallable(Playlist::favoritesPlaylist).subscribeOn(Schedulers.io()).cache();
            Observable<List<Song>> favouritesSongsObservable = favouritesPlaylistObservable.filter(playlist -> playlist != null).flatMap(playlist -> playlist.getSongsObservable(getContext())).cache();
            Observable<List<AdaptableItem>> favoriteSongsItemsObservable = favouritesPlaylistObservable.flatMap(playlist -> {
                SuggestedHeader favoriteHeader = new SuggestedHeader(getString(R.string.fav_title), getString(R.string.suggested_favorite_subtitle), playlist);
                SuggestedHeaderView favoriteHeaderView = new SuggestedHeaderView(favoriteHeader);
                return favouritesSongsObservable.map(songs -> {
                    List<AdaptableItem> items = new ArrayList<>();
                    if (!songs.isEmpty()) {
                        items.add(favoriteHeaderView);
                        items.add(favoriteRecyclerView);
                    }
                    return items;
                });
            }).switchIfEmpty(Observable.just(Collections.emptyList()));
            Observable<List<AdaptableItem>> recentlyAddedAlbums = Observable.fromCallable(Playlist::recentlyAddedPlaylist).subscribeOn(Schedulers.io()).filter(playlist -> playlist != null).flatMap(playlist -> {
                SuggestedHeader recentlyAddedHeader = new SuggestedHeader(getString(R.string.recentlyadded), getString(R.string.suggested_recently_added_subtitle), playlist);
                SuggestedHeaderView recentlyAddedHeaderView = new SuggestedHeaderView(recentlyAddedHeader);
                return playlist.getSongsObservable(getContext()).flatMap(songs -> Observable.just(Operators.songsToAlbums(songs))).flatMap(Observable::from).sorted((a, b) -> ComparisonUtils.compareLong(b.dateAdded, a.dateAdded)).limit(4).flatMap(album -> album.getSongsObservable().map(songs -> {
                    album.numSongs = songs.size();
                    return album;
                })).sorted((a, b) -> ComparisonUtils.compareLong(b.dateAdded, a.dateAdded)).filter(album -> album.numSongs > 0).map(album -> (AdaptableItem) new AlbumView(album, ViewType.ALBUM_LIST_SMALL, requestManager)).toList().map(adaptableItems -> {
                    if (!adaptableItems.isEmpty()) {
                        adaptableItems.add(0, recentlyAddedHeaderView);
                    }
                    return adaptableItems;
                });
            }).switchIfEmpty(Observable.just(Collections.emptyList()));
            Observable.merge(mostPlayedItemsObservable, recentlyPlayedAlbums, favoriteSongsItemsObservable, recentlyAddedAlbums);
            subscription.add(Observable.combineLatest(mostPlayedItemsObservable, recentlyPlayedAlbums, favoriteSongsItemsObservable, recentlyAddedAlbums, (mostPlayedSongs1, recentlyPlayedAlbums1, favoriteSongs1, recentlyAddedAlbums1) -> {
                List<AdaptableItem> items = new ArrayList<>();
                items.addAll(mostPlayedSongs1);
                items.addAll(recentlyPlayedAlbums1);
                items.addAll(favoriteSongs1);
                items.addAll(recentlyAddedAlbums1);
                return items;
            }).debounce(250, TimeUnit.MILLISECONDS).switchIfEmpty(Observable.just(new ArrayList<>())).observeOn(AndroidSchedulers.mainThread()).subscribe(adaptableItems -> {
                if (adaptableItems.isEmpty()) {
                    suggestedAdapter.setEmpty(new EmptyView(R.string.empty_suggested));
                } else {
                    suggestedAdapter.setItems(adaptableItems);
                }
            }));
            subscription.add(mostPlayedSongsObservable.map(songs -> {
                Collections.sort(songs, (a, b) -> ComparisonUtils.compareInt(b.playCount, a.playCount));
                return Stream.of(songs).map(song -> (AdaptableItem) new SuggestedSongView(song, requestManager)).limit(20).collect(Collectors.toList());
            }).observeOn(AndroidSchedulers.mainThread()).subscribe(adaptableItems -> {
                mostPlayedRecyclerView.itemAdapter.setItems(adaptableItems);
            }));
            subscription.add(favouritesSongsObservable.map(songs -> Stream.of(songs).map(song -> (AdaptableItem) new SuggestedSongView(song, requestManager)).limit(20).collect(Collectors.toList())).observeOn(AndroidSchedulers.mainThread()).subscribe(adaptableItems -> {
                favoriteRecyclerView.itemAdapter.setItems(adaptableItems);
            }));
        }
    });
}
Also used : R(com.simplecity.amp_library.R) GridLayoutManager(android.support.v7.widget.GridLayoutManager) Bundle(android.os.Bundle) AndroidSchedulers(rx.android.schedulers.AndroidSchedulers) SuggestedDividerDecoration(com.simplecity.amp_library.ui.views.SuggestedDividerDecoration) ItemAdapter(com.simplecity.amp_library.ui.adapters.ItemAdapter) Song(com.simplecity.amp_library.model.Song) RequestManager(com.bumptech.glide.RequestManager) MenuUtils(com.simplecity.amp_library.utils.MenuUtils) Schedulers(rx.schedulers.Schedulers) View(android.view.View) PreferenceManager(android.preference.PreferenceManager) Playlist(com.simplecity.amp_library.model.Playlist) IntentFilter(android.content.IntentFilter) PopupMenu(android.support.v7.widget.PopupMenu) BroadcastReceiver(android.content.BroadcastReceiver) AppCompatActivity(android.support.v7.app.AppCompatActivity) ViewGroup(android.view.ViewGroup) SuggestedHeaderView(com.simplecity.amp_library.ui.modelviews.SuggestedHeaderView) Serializable(java.io.Serializable) MusicUtils(com.simplecity.amp_library.utils.MusicUtils) List(java.util.List) PermissionUtils(com.simplecity.amp_library.utils.PermissionUtils) AdaptableItem(com.simplecity.amp_library.model.AdaptableItem) Context(android.content.Context) SuggestedSongView(com.simplecity.amp_library.ui.modelviews.SuggestedSongView) Album(com.simplecity.amp_library.model.Album) Stream(com.annimon.stream.Stream) EmptyView(com.simplecity.amp_library.ui.modelviews.EmptyView) Intent(android.content.Intent) ArrayList(java.util.ArrayList) Observable(rx.Observable) SuggestedHeader(com.simplecity.amp_library.model.SuggestedHeader) ThemeUtils(com.simplecity.amp_library.utils.ThemeUtils) SuggestedAdapter(com.simplecity.amp_library.ui.adapters.SuggestedAdapter) Toast(android.widget.Toast) ViewType(com.simplecity.amp_library.ui.modelviews.ViewType) Collectors(com.annimon.stream.Collectors) LayoutInflater(android.view.LayoutInflater) AlbumView(com.simplecity.amp_library.ui.modelviews.AlbumView) TimeUnit(java.util.concurrent.TimeUnit) CompositeSubscription(rx.subscriptions.CompositeSubscription) RecyclerView(android.support.v7.widget.RecyclerView) BlacklistHelper(com.simplecity.amp_library.sql.databases.BlacklistHelper) Glide(com.bumptech.glide.Glide) SharedPreferences(android.content.SharedPreferences) HorizontalRecyclerView(com.simplecity.amp_library.ui.modelviews.HorizontalRecyclerView) ComparisonUtils(com.simplecity.amp_library.utils.ComparisonUtils) AlbumArtist(com.simplecity.amp_library.model.AlbumArtist) Operators(com.simplecity.amp_library.utils.Operators) Collections(java.util.Collections) AlbumView(com.simplecity.amp_library.ui.modelviews.AlbumView) AdaptableItem(com.simplecity.amp_library.model.AdaptableItem) SuggestedSongView(com.simplecity.amp_library.ui.modelviews.SuggestedSongView) Playlist(com.simplecity.amp_library.model.Playlist) SuggestedHeaderView(com.simplecity.amp_library.ui.modelviews.SuggestedHeaderView) CompositeSubscription(rx.subscriptions.CompositeSubscription) List(java.util.List) ArrayList(java.util.ArrayList) SuggestedHeader(com.simplecity.amp_library.model.SuggestedHeader) EmptyView(com.simplecity.amp_library.ui.modelviews.EmptyView)

Example 5 with SuggestedHeaderView

use of com.simplecity.amp_library.ui.modelviews.SuggestedHeaderView in project Shuttle by timusus.

the class SuggestedFragment method getMostPlayedViewModels.

Observable<List<ViewModel>> getMostPlayedViewModels() {
    return Playlist.mostPlayedPlaylist.getSongsObservable().map(songs -> {
        if (!songs.isEmpty()) {
            List<ViewModel> viewModels = new ArrayList<>();
            SuggestedHeader mostPlayedHeader = new SuggestedHeader(getString(R.string.mostplayed), getString(R.string.suggested_most_played_songs_subtitle), Playlist.mostPlayedPlaylist);
            SuggestedHeaderView mostPlayedHeaderView = new SuggestedHeaderView(mostPlayedHeader);
            mostPlayedHeaderView.setClickListener(this);
            viewModels.add(mostPlayedHeaderView);
            viewModels.add(mostPlayedRecyclerView);
            Collections.sort(songs, (a, b) -> ComparisonUtils.compareInt(b.playCount, a.playCount));
            SongClickListener songClickListener = new SongClickListener(songs);
            mostPlayedRecyclerView.viewModelAdapter.setItems(Stream.of(songs).map(song -> {
                SuggestedSongView suggestedSongView = new SuggestedSongView(song, requestManager);
                suggestedSongView.setClickListener(songClickListener);
                return (ViewModel) suggestedSongView;
            }).limit(20).toList());
            return viewModels;
        } else {
            return Collections.emptyList();
        }
    });
}
Also used : R(com.simplecity.amp_library.R) GridLayoutManager(android.support.v7.widget.GridLayoutManager) Bundle(android.os.Bundle) ViewModel(com.simplecityapps.recycler_adapter.model.ViewModel) SuggestedDividerDecoration(com.simplecity.amp_library.ui.views.SuggestedDividerDecoration) AndroidSchedulers(io.reactivex.android.schedulers.AndroidSchedulers) Song(com.simplecity.amp_library.model.Song) Optional(com.annimon.stream.Optional) RequestManager(com.bumptech.glide.RequestManager) MenuUtils(com.simplecity.amp_library.utils.MenuUtils) View(android.view.View) LogUtils(com.simplecity.amp_library.utils.LogUtils) Playlist(com.simplecity.amp_library.model.Playlist) PopupMenu(android.support.v7.widget.PopupMenu) ViewGroup(android.view.ViewGroup) SuggestedHeaderView(com.simplecity.amp_library.ui.modelviews.SuggestedHeaderView) MusicUtils(com.simplecity.amp_library.utils.MusicUtils) List(java.util.List) CompositeDisposable(io.reactivex.disposables.CompositeDisposable) Disposable(io.reactivex.disposables.Disposable) FragmentModule(com.simplecity.amp_library.dagger.module.FragmentModule) PermissionUtils(com.simplecity.amp_library.utils.PermissionUtils) Nullable(android.support.annotation.Nullable) Context(android.content.Context) SuggestedSongView(com.simplecity.amp_library.ui.modelviews.SuggestedSongView) Album(com.simplecity.amp_library.model.Album) Stream(com.annimon.stream.Stream) RecyclerListener(com.simplecityapps.recycler_adapter.recyclerview.RecyclerListener) EmptyView(com.simplecity.amp_library.ui.modelviews.EmptyView) ViewModelAdapter(com.simplecityapps.recycler_adapter.adapter.ViewModelAdapter) ViewType(com.simplecity.amp_library.ui.adapters.ViewType) ArrayList(java.util.ArrayList) Inject(javax.inject.Inject) SuppressLint(android.annotation.SuppressLint) SuggestedHeader(com.simplecity.amp_library.model.SuggestedHeader) Toast(android.widget.Toast) Observable(io.reactivex.Observable) UpgradeDialog(com.simplecity.amp_library.ui.dialog.UpgradeDialog) ShuttleUtils(com.simplecity.amp_library.utils.ShuttleUtils) LayoutInflater(android.view.LayoutInflater) AlbumView(com.simplecity.amp_library.ui.modelviews.AlbumView) TimeUnit(java.util.concurrent.TimeUnit) RecyclerView(android.support.v7.widget.RecyclerView) ShuttleApplication(com.simplecity.amp_library.ShuttleApplication) HorizontalRecyclerView(com.simplecity.amp_library.ui.modelviews.HorizontalRecyclerView) PlaylistDetailFragment(com.simplecity.amp_library.ui.detail.PlaylistDetailFragment) ComparisonUtils(com.simplecity.amp_library.utils.ComparisonUtils) DataManager(com.simplecity.amp_library.utils.DataManager) AlbumArtist(com.simplecity.amp_library.model.AlbumArtist) Operators(com.simplecity.amp_library.utils.Operators) Collections(java.util.Collections) SuggestedHeaderView(com.simplecity.amp_library.ui.modelviews.SuggestedHeaderView) ArrayList(java.util.ArrayList) SuggestedSongView(com.simplecity.amp_library.ui.modelviews.SuggestedSongView) ViewModel(com.simplecityapps.recycler_adapter.model.ViewModel) SuggestedHeader(com.simplecity.amp_library.model.SuggestedHeader)

Aggregations

SuggestedHeaderView (com.simplecity.amp_library.ui.modelviews.SuggestedHeaderView)6 SuppressLint (android.annotation.SuppressLint)5 GridLayoutManager (android.support.v7.widget.GridLayoutManager)5 SuggestedHeader (com.simplecity.amp_library.model.SuggestedHeader)5 AlbumView (com.simplecity.amp_library.ui.modelviews.AlbumView)5 EmptyView (com.simplecity.amp_library.ui.modelviews.EmptyView)5 HorizontalRecyclerView (com.simplecity.amp_library.ui.modelviews.HorizontalRecyclerView)5 SuggestedSongView (com.simplecity.amp_library.ui.modelviews.SuggestedSongView)5 SuggestedDividerDecoration (com.simplecity.amp_library.ui.views.SuggestedDividerDecoration)5 ArrayList (java.util.ArrayList)5 List (java.util.List)5 Context (android.content.Context)4 Bundle (android.os.Bundle)4 PopupMenu (android.support.v7.widget.PopupMenu)4 RecyclerView (android.support.v7.widget.RecyclerView)4 LayoutInflater (android.view.LayoutInflater)4 View (android.view.View)4 ViewGroup (android.view.ViewGroup)4 Toast (android.widget.Toast)4 Optional (com.annimon.stream.Optional)4