mirror of
https://github.com/morgan9e/dash-to-panel
synced 2026-04-15 00:34:05 +09:00
Use new showNotification method
This commit is contained in:
3
utils.js
3
utils.js
@@ -472,6 +472,7 @@ var getPanelGhost = function() {
|
||||
var notify = function(text, iconName, action, isTransient) {
|
||||
let source = new MessageTray.SystemNotificationSource();
|
||||
let notification = new MessageTray.Notification(source, 'Dash to Panel', text);
|
||||
let notifyFunc = source.showNotification || source.notify;
|
||||
|
||||
if (iconName) {
|
||||
source.createIcon = function() {
|
||||
@@ -490,7 +491,7 @@ var notify = function(text, iconName, action, isTransient) {
|
||||
Main.messageTray.add(source);
|
||||
|
||||
notification.setTransient(isTransient);
|
||||
source.notify(notification);
|
||||
notifyFunc.call(source, notification);
|
||||
};
|
||||
|
||||
/*
|
||||
|
||||
Reference in New Issue
Block a user