diff --git a/app/src/main/java/org/thoughtcrime/securesms/media/MediaPage.kt b/app/src/main/java/org/thoughtcrime/securesms/media/MediaPage.kt
index c94b08b68b..49b44b5055 100644
--- a/app/src/main/java/org/thoughtcrime/securesms/media/MediaPage.kt
+++ b/app/src/main/java/org/thoughtcrime/securesms/media/MediaPage.kt
@@ -152,12 +152,30 @@ private fun ThumbnailRow(
) {
it.diskCacheStrategy(DiskCacheStrategy.NONE)
}
- } else if (item.hasPlaceholder) {
+ } else {
+ // The resource given by the placeholder needs tinting according to our theme.
+ // But the missing thumbnail picture does not.
+ var (placeholder, shouldTint) = if (item.hasPlaceholder) {
+ item.placeholder(LocalContext.current) to true
+ } else {
+ R.drawable.ic_missing_thumbnail_picture to false
+ }
+
+ if (placeholder == 0) {
+ placeholder = R.drawable.ic_missing_thumbnail_picture
+ shouldTint = false
+ }
+
Image(
- painter = painterResource(item.placeholder(LocalContext.current)),
+ painter = painterResource(placeholder),
contentDescription = null,
modifier = Modifier.fillMaxSize(),
- contentScale = ContentScale.Inside
+ contentScale = ContentScale.Inside,
+ colorFilter = if (shouldTint) {
+ ColorFilter.tint(LocalColors.current.textSecondary)
+ } else {
+ null
+ }
)
}
diff --git a/app/src/main/res/values/themes.xml b/app/src/main/res/values/themes.xml
index 37f0e517ac..9f81cd153e 100644
--- a/app/src/main/res/values/themes.xml
+++ b/app/src/main/res/values/themes.xml
@@ -58,7 +58,10 @@
- @drawable/ic_document_small_dark
- @drawable/ic_document_large_dark
- ?danger
-
+
+ - @drawable/ic_audio_dark
+ - @drawable/ic_video_dark
+