Commit 854e8066 authored by Sébastien Toque's avatar Sébastien Toque

notification: keep default cover if there is none

parent 828353f1
......@@ -519,7 +519,8 @@ public class AudioService extends Service {
PendingIntent piStop = PendingIntent.getBroadcast(this, 0, iStop, PendingIntent.FLAG_UPDATE_CURRENT);
RemoteViews view = new RemoteViews(getPackageName(), R.layout.notification);
view.setImageViewBitmap(, cover);
if (cover != null)
view.setImageViewBitmap(, cover);
view.setTextViewText(, title);
view.setTextViewText(, artist);
view.setImageViewResource(, mLibVLC.isPlaying() ? R.drawable.ic_pause : R.drawable.ic_play);
......@@ -529,7 +530,8 @@ public class AudioService extends Service {
view.setOnClickPendingIntent(, pendingIntent);
RemoteViews view_expanded = new RemoteViews(getPackageName(), R.layout.notification_expanded);
view_expanded.setImageViewBitmap(, cover);
if (cover != null)
view_expanded.setImageViewBitmap(, cover);
view_expanded.setTextViewText(, title);
view_expanded.setTextViewText(, artist);
view_expanded.setTextViewText(, album);
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment