Fixed a bug where the last song in the song view was not showing up.
This commit is contained in:
parent
7aee6f2bb0
commit
92159797f5
2 changed files with 13 additions and 0 deletions
|
|
@ -45,6 +45,12 @@ public class ShuffleButtonSongAdapter extends SongAdapter {
|
|||
return super.getIdentifier(position);
|
||||
}
|
||||
|
||||
@Override
|
||||
public int getItemCount() {
|
||||
int superItemCount = super.getItemCount();
|
||||
return superItemCount == 0 ? 0 : superItemCount + 1;
|
||||
}
|
||||
|
||||
@Override
|
||||
public int getItemViewType(int position) {
|
||||
return position == 0 ? SHUFFLE_BUTTON : SONG;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue