Set artist and album
This commit is contained in:
parent
9de67792c7
commit
e4855e51eb
@ -88,11 +88,8 @@ public class RemoteControl {
|
||||
remote.setPlaybackState(isPlaying ? RemoteControlClient.PLAYSTATE_PLAYING : RemoteControlClient.PLAYSTATE_PAUSED);
|
||||
RemoteControlClient.MetadataEditor editor = remote.editMetadata(true);
|
||||
if (song != null && song.id != -1) {
|
||||
String artist_album = song.artist + " - " + song.album;
|
||||
artist_album = (song.artist.length() == 0 ? song.album : artist_album); // no artist ? -> only display album
|
||||
artist_album = (song.album.length() == 0 ? song.artist : artist_album); // no album ? -> only display artist
|
||||
|
||||
editor.putString(MediaMetadataRetriever.METADATA_KEY_ALBUM, artist_album);
|
||||
editor.putString(MediaMetadataRetriever.METADATA_KEY_ARTIST, song.artist);
|
||||
editor.putString(MediaMetadataRetriever.METADATA_KEY_ALBUM, song.album);
|
||||
editor.putString(MediaMetadataRetriever.METADATA_KEY_TITLE, song.title);
|
||||
Bitmap bitmap = song.getCover(context);
|
||||
if (bitmap != null && (isPlaying || keepPaused)) {
|
||||
|
Loading…
x
Reference in New Issue
Block a user