Skip to content

Show avatar on message notification #7089

@Goooler

Description

@Goooler

Checklist

  • I have used the search function to see if someone else has already submitted the same feature request.
  • I will describe the problem with as much detail as possible.
  • This issue only contains a request for one single feature, not multiple (related) features.

App version

v6.602

Problem you are trying to solve

There are no avatars showing on message notifications as Gmail app did, can we add this support feature?

Suggested solution

Add setLargeIcon on notification builder:

val notification = notificationHelper.createNotificationBuilder(account, ChannelType.MESSAGES)
.setCategory(NotificationCompat.CATEGORY_EMAIL)
.setGroup(baseNotificationData.groupKey)
.setGroupSummary(isGroupSummary)
.setSmallIcon(resourceProvider.iconNewMail)
.setColor(baseNotificationData.color)
.setWhen(singleNotificationData.timestamp)
.setTicker(content.summary)
.setContentTitle(content.sender)
.setContentText(content.subject)
.setSubText(baseNotificationData.accountName)
.setBigText(content.preview)
.setContentIntent(actionCreator.createViewMessagePendingIntent(content.messageReference))
.setDeleteIntent(actionCreator.createDismissMessagePendingIntent(content.messageReference))
.setDeviceActions(singleNotificationData)
.setWearActions(singleNotificationData)
.setAppearance(singleNotificationData.isSilent, baseNotificationData.appearance)
.setLockScreenNotification(baseNotificationData, singleNotificationData.addLockScreenNotification)
.build()

Ref: https://developer.android.com/develop/ui/views/notifications/expanded#large-style

Screenshots / Drawings / Technical details

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    type: enhancementNew features or improvements to existing features.

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions