[gnome-shell/gnome-3-6] messageTray: Only hide the notification stack on clicking close
- From: Florian MÃllner <fmuellner src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-shell/gnome-3-6] messageTray: Only hide the notification stack on clicking close
- Date: Mon, 12 Nov 2012 16:57:52 +0000 (UTC)
commit c16f9ba7c4028439f4d5599364e765a820f21d95
Author: Jasper St. Pierre <jstpierre mecheye net>
Date: Wed Sep 19 00:37:24 2012 -0300
messageTray: Only hide the notification stack on clicking close
Rather than destroying the entire source, which is unintuitive, simply
close the notification. Removing the entire source is still possible
by right-clicking on the summary item and choosing "Remove".
https://bugzilla.gnome.org/show_bug.cgi?id=682237
js/ui/messageTray.js | 7 +++----
1 files changed, 3 insertions(+), 4 deletions(-)
---
diff --git a/js/ui/messageTray.js b/js/ui/messageTray.js
index 807163d..c8fc9f4 100644
--- a/js/ui/messageTray.js
+++ b/js/ui/messageTray.js
@@ -1244,10 +1244,6 @@ const SummaryItem = new Lang.Class({
this.notificationStackWidget.add_actor(this.notificationStackView);
this.closeButton = makeCloseButton();
- this.closeButton.connect('clicked', Lang.bind(this, function() {
- source.destroy();
- source.emit('done-displaying-content');
- }));
this.notificationStackWidget.add_actor(this.closeButton);
this._stackedNotifications = [];
@@ -2400,6 +2396,7 @@ const MessageTray = new Lang.Class({
let closeButton = this._summaryBoxPointerItem.closeButton;
closeButton.show();
+ this._summaryBoxPointerCloseClickedId = closeButton.connect('clicked', Lang.bind(this, this._hideSummaryBoxPointer));
this._summaryBoxPointerItem.prepareNotificationStackForShowing();
} else if (this._clickedSummaryItemMouseButton == 3) {
this._summaryBoxPointer.bin.child = this._clickedSummaryItem.rightClickMenu;
@@ -2509,6 +2506,8 @@ const MessageTray = new Lang.Class({
this._summaryBoxPointer.bin.child = null;
this._summaryBoxPointerItem.disconnect(this._summaryBoxPointerContentUpdatedId);
this._summaryBoxPointerContentUpdatedId = 0;
+ this._summaryBoxPointerItem.closeButton.disconnect(this._summaryBoxPointerCloseClickedId);
+ this._summaryBoxPointerCloseClickedId = 0;
this._summaryBoxPointerItem.source.disconnect(this._sourceDoneDisplayingId);
this._summaryBoxPointerDoneDisplayingId = 0;
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]