Chats should jump to the top of the notification queue.
This is to ensure users get notified as soon as chats are received. Notifications with critical urgency still have the highest priority. https://bugzilla.gnome.org/show_bug.cgi?id=630934
This commit is contained in:

committed by
Marina Zhurakhinskaya

parent
ceedc7e32c
commit
f60b995236
@ -343,8 +343,17 @@ NotificationDaemon.prototype = {
|
||||
for (let i = 0; i < actions.length - 1; i += 2)
|
||||
notification.addButton(actions[i], actions[i + 1]);
|
||||
}
|
||||
|
||||
notification.setUrgent(hints.urgency == Urgency.CRITICAL);
|
||||
switch (hints.urgency) {
|
||||
case Urgency.LOW:
|
||||
notification.setUrgency(MessageTray.Urgency.LOW);
|
||||
break;
|
||||
case Urgency.NORMAL:
|
||||
notification.setUrgency(MessageTray.Urgency.NORMAL);
|
||||
break;
|
||||
case Urgency.CRITICAL:
|
||||
notification.setUrgency(MessageTray.Urgency.CRITICAL);
|
||||
break;
|
||||
}
|
||||
notification.setResident(hints.resident == true);
|
||||
// 'transient' is a reserved keyword in JS, so we have to retrieve the value
|
||||
// of the 'transient' hint with hints['transient'] rather than hints.transient
|
||||
|
Reference in New Issue
Block a user