mirror of
https://github.com/CappielloAntonio/tempo.git
synced 2026-02-02 23:43:37 +00:00
Use getBindingAdapterPosition() instead of getAdapterPosition()
This commit is contained in:
@@ -71,14 +71,14 @@ public class ArtistAdapter extends RecyclerView.Adapter<ArtistAdapter.ViewHolder
|
||||
@Override
|
||||
public void onClick(View view) {
|
||||
Bundle bundle = new Bundle();
|
||||
bundle.putParcelable("artist_object", artists.get(getAdapterPosition()));
|
||||
bundle.putParcelable("artist_object", artists.get(getBindingAdapterPosition()));
|
||||
Navigation.findNavController(view).navigate(R.id.action_libraryFragment_to_artistPageFragment, bundle);
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean onLongClick(View v) {
|
||||
Bundle bundle = new Bundle();
|
||||
bundle.putParcelable("artist_object", artists.get(getAdapterPosition()));
|
||||
bundle.putParcelable("artist_object", artists.get(getBindingAdapterPosition()));
|
||||
Navigation.findNavController(v).navigate(R.id.artistBottomSheetDialog, bundle);
|
||||
return true;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user