mirror of
https://github.com/antebudimir/tempus.git
synced 2025-12-31 17:43:32 +00:00
Removed rating system for album and artist as it seems it's not supported
This commit is contained in:
parent
e2ddbdf6c9
commit
75d6f3afd3
3 changed files with 0 additions and 34 deletions
|
|
@ -94,17 +94,6 @@ public class AlbumBottomSheetDialog extends BottomSheetDialogFragment implements
|
|||
albumBottomSheetViewModel.setFavorite();
|
||||
dismissBottomSheet();
|
||||
});
|
||||
favoriteToggle.setOnLongClickListener(v -> {
|
||||
Bundle bundle = new Bundle();
|
||||
bundle.putParcelable("album_object", album);
|
||||
|
||||
RatingDialog dialog = new RatingDialog();
|
||||
dialog.setArguments(bundle);
|
||||
dialog.show(requireActivity().getSupportFragmentManager(), null);
|
||||
|
||||
dismissBottomSheet();
|
||||
return true;
|
||||
});
|
||||
|
||||
playRadio = view.findViewById(R.id.play_radio_text_view);
|
||||
playRadio.setOnClickListener(v -> {
|
||||
|
|
|
|||
|
|
@ -83,17 +83,6 @@ public class ArtistBottomSheetDialog extends BottomSheetDialogFragment implement
|
|||
artistBottomSheetViewModel.setFavorite();
|
||||
dismissBottomSheet();
|
||||
});
|
||||
favoriteToggle.setOnLongClickListener(v -> {
|
||||
Bundle bundle = new Bundle();
|
||||
bundle.putParcelable("artist_object", artist);
|
||||
|
||||
RatingDialog dialog = new RatingDialog();
|
||||
dialog.setArguments(bundle);
|
||||
dialog.show(requireActivity().getSupportFragmentManager(), null);
|
||||
|
||||
dismissBottomSheet();
|
||||
return true;
|
||||
});
|
||||
|
||||
playRadio = view.findViewById(R.id.play_radio_text_view);
|
||||
playRadio.setOnClickListener(v -> {
|
||||
|
|
|
|||
|
|
@ -72,18 +72,6 @@ public class RatingViewModel extends AndroidViewModel {
|
|||
this.artist = artist;
|
||||
}
|
||||
|
||||
public int getItemRating() {
|
||||
if (song != null) {
|
||||
return song.getRating();
|
||||
} else if (album != null) {
|
||||
return 0;
|
||||
} else if (artist != null) {
|
||||
return 0;
|
||||
} else {
|
||||
return 0;
|
||||
}
|
||||
}
|
||||
|
||||
public void rate(int star) {
|
||||
if (song != null) {
|
||||
songRepository.setRating(song.getId(), star);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue