Commit 3c492e92 authored by Sophie Herold's avatar Sophie Herold Committed by Philipp Hörist
Browse files

Show avatar in new message notifications

parent d57bfcbc
Pipeline #2121 passed with stages
in 2 minutes and 9 seconds
......@@ -180,7 +180,6 @@ class Notification:
if text is not None:
notif_id = None
if event_type in (_('Contact Signed In'), _('Contact Signed Out'),
_('New Message'), _('New Single Message'), _('New Private Message'),
......@@ -211,9 +210,14 @@ class Notification:
notif_id = self._id('connection-failed', account)
elif event_type in (_('New Message'), _('New Single Message'),
_('New Private Message')):
avatar = app.contacts.get_avatar(account, jid)
if avatar:
icon_pixbuf = avatar
notif_id = self._id('new-message', account, jid)
notification.set_priority(Gio.NotificationPriority.NORMAL), notification)
def withdraw(self, *args):
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