diff --git a/app/src/main/java/org/jellyfin/mobile/player/interaction/PlayerNotificationHelper.kt b/app/src/main/java/org/jellyfin/mobile/player/interaction/PlayerNotificationHelper.kt index 5b8ca57db..2d146ab9b 100644 --- a/app/src/main/java/org/jellyfin/mobile/player/interaction/PlayerNotificationHelper.kt +++ b/app/src/main/java/org/jellyfin/mobile/player/interaction/PlayerNotificationHelper.kt @@ -8,6 +8,7 @@ import android.content.Context import android.content.Intent import android.content.IntentFilter import android.graphics.Bitmap +import android.media.MediaMetadata import androidx.core.content.ContextCompat import androidx.core.content.getSystemService import androidx.core.graphics.drawable.toBitmap @@ -120,6 +121,18 @@ class PlayerNotificationHelper(private val viewModel: PlayerViewModel) : KoinCom }.build() nm.notify(VIDEO_PLAYER_NOTIFICATION_ID, notification) + + mediaIcon?.let { + viewModel.mediaSession.controller.metadata?.let { + if (!it.containsKey(MediaMetadata.METADATA_KEY_ART)) { + viewModel.mediaSession.setMetadata( + MediaMetadata.Builder(it) + .putBitmap(MediaMetadata.METADATA_KEY_ART, mediaIcon) + .build() + ) + } + } + } } if (receiverRegistered.compareAndSet(false, true)) { diff --git a/app/src/main/res/values-v29/dimens.xml b/app/src/main/res/values-v29/dimens.xml index 3cd9aedb5..6107e4a33 100644 --- a/app/src/main/res/values-v29/dimens.xml +++ b/app/src/main/res/values-v29/dimens.xml @@ -1,4 +1,4 @@ - 140dp + 196dp