mirror of
https://github.com/signalapp/Signal-Android.git
synced 2026-04-22 01:40:07 +01:00
Add avatar picker and defaults.
This commit is contained in:
committed by
Greyson Parrelli
parent
0093e1d3eb
commit
ed23c3fe7c
@@ -52,7 +52,7 @@ data class NotificationConversation(
|
||||
return if (SignalStore.settings().messageNotificationsPrivacy.isDisplayContact) {
|
||||
recipient.getContactDrawable(context)
|
||||
} else {
|
||||
GeneratedContactPhoto("Unknown", R.drawable.ic_profile_outline_40).asDrawable(context, AvatarColor.UNKNOWN.colorInt())
|
||||
GeneratedContactPhoto("Unknown", R.drawable.ic_profile_outline_40).asDrawable(context, AvatarColor.UNKNOWN)
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -56,12 +56,12 @@ fun Recipient.getContactDrawable(context: Context): Drawable? {
|
||||
)
|
||||
.get()
|
||||
} catch (e: InterruptedException) {
|
||||
fallbackContactPhoto.asDrawable(context, avatarColor.colorInt())
|
||||
fallbackContactPhoto.asDrawable(context, avatarColor)
|
||||
} catch (e: ExecutionException) {
|
||||
fallbackContactPhoto.asDrawable(context, avatarColor.colorInt())
|
||||
fallbackContactPhoto.asDrawable(context, avatarColor)
|
||||
}
|
||||
} else {
|
||||
fallbackContactPhoto.asDrawable(context, avatarColor.colorInt())
|
||||
fallbackContactPhoto.asDrawable(context, avatarColor)
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user