mirror of
https://github.com/CappielloAntonio/tempo.git
synced 2026-02-01 23:13:36 +00:00
Add album page
This commit is contained in:
@@ -10,6 +10,7 @@ import androidx.recyclerview.widget.RecyclerView;
|
||||
|
||||
import com.cappielloantonio.play.R;
|
||||
import com.cappielloantonio.play.model.Album;
|
||||
import com.cappielloantonio.play.model.Artist;
|
||||
import com.cappielloantonio.play.util.Util;
|
||||
|
||||
import java.util.List;
|
||||
@@ -65,6 +66,10 @@ public class AlbumAdapter extends RecyclerView.Adapter<AlbumAdapter.ViewHolder>
|
||||
}
|
||||
}
|
||||
|
||||
public Album getItem(int position) {
|
||||
return albums.get(position);
|
||||
}
|
||||
|
||||
public void setItems(List<Album> albums) {
|
||||
this.albums = albums;
|
||||
notifyDataSetChanged();
|
||||
|
||||
@@ -61,6 +61,10 @@ public class AlbumArtistPageAdapter extends RecyclerView.Adapter<AlbumArtistPage
|
||||
}
|
||||
}
|
||||
|
||||
public Album getItem(int position) {
|
||||
return albums.get(position);
|
||||
}
|
||||
|
||||
public void setItems(List<Album> albums) {
|
||||
this.albums = albums;
|
||||
notifyDataSetChanged();
|
||||
|
||||
@@ -10,6 +10,7 @@ import androidx.recyclerview.widget.RecyclerView;
|
||||
|
||||
import com.cappielloantonio.play.R;
|
||||
import com.cappielloantonio.play.model.Album;
|
||||
import com.cappielloantonio.play.model.Artist;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
@@ -64,6 +65,10 @@ public class AlbumCatalogueAdapter extends RecyclerView.Adapter<AlbumCatalogueAd
|
||||
}
|
||||
}
|
||||
|
||||
public Album getItem(int position) {
|
||||
return albums.get(position);
|
||||
}
|
||||
|
||||
public void setItems(List<Album> albums) {
|
||||
this.albums = albums;
|
||||
notifyDataSetChanged();
|
||||
|
||||
@@ -62,6 +62,10 @@ public class ArtistAdapter extends RecyclerView.Adapter<ArtistAdapter.ViewHolder
|
||||
}
|
||||
}
|
||||
|
||||
public Artist getItem(int position) {
|
||||
return artists.get(position);
|
||||
}
|
||||
|
||||
public void setItems(List<Artist> artists) {
|
||||
this.artists = artists;
|
||||
notifyDataSetChanged();
|
||||
|
||||
Reference in New Issue
Block a user