[gnome-shell] messageTray: Add Source.pushNotification method
- From: Jasper St. Pierre <jstpierre src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-shell] messageTray: Add Source.pushNotification method
- Date: Mon, 14 Mar 2011 22:52:46 +0000 (UTC)
commit 4029202635fdea3ad8ef2a5caac3bdbebff6d147
Author: Jasper St. Pierre <jstpierre mecheye net>
Date: Mon Feb 28 13:13:32 2011 -0500
messageTray: Add Source.pushNotification method
This allows clients to make minor adjustments to their notification
content without triggering a new popup.
https://bugzilla.gnome.org/show_bug.cgi?id=642793
js/ui/messageTray.js | 6 +++++-
1 files changed, 5 insertions(+), 1 deletions(-)
---
diff --git a/js/ui/messageTray.js b/js/ui/messageTray.js
index 4f25122..8a29597 100644
--- a/js/ui/messageTray.js
+++ b/js/ui/messageTray.js
@@ -844,12 +844,13 @@ Source.prototype = {
return this._iconBin;
},
- notify: function(notification) {
+ pushNotification: function(notification) {
if (this.notification) {
this.notification.disconnect(this._notificationClickedId);
this.notification.disconnect(this._notificationDestroyedId);
}
+ // FIXME: Right now, we don't save multiple notifications.
this.notification = notification;
this._notificationClickedId = notification.connect('clicked', Lang.bind(this, this.open));
@@ -862,7 +863,10 @@ Source.prototype = {
this._notificationRemoved();
}
}));
+ },
+ notify: function(notification) {
+ this.pushNotification(notification);
this.emit('notify', notification);
},
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]