[gnome-shell/wip/message-tray: 17/23] messageTray: Be able to "switch" notifications
- From: Marina Zhurakhinskaya <marinaz src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-shell/wip/message-tray: 17/23] messageTray: Be able to "switch" notifications
- Date: Sun, 19 Aug 2012 21:18:30 +0000 (UTC)
commit d49cf61117cf149a25db3a237a975a2d1e210a5d
Author: Jasper St. Pierre <jstpierre mecheye net>
Date: Thu Aug 16 13:39:34 2012 -0400
messageTray: Be able to "switch" notifications
If you click on a summary item while another is up, we should
swap without an extra click.
js/ui/messageTray.js | 8 ++++----
1 files changed, 4 insertions(+), 4 deletions(-)
---
diff --git a/js/ui/messageTray.js b/js/ui/messageTray.js
index f7f5176..e53b604 100644
--- a/js/ui/messageTray.js
+++ b/js/ui/messageTray.js
@@ -1633,10 +1633,8 @@ const MessageTray = new Lang.Class({
_onSummaryItemClicked: function(summaryItem, button) {
if (summaryItem.source.handleSummaryClick()) {
this._setClickedSummaryItem(null);
- } else if (!this._clickedSummaryItem) {
- this._setClickedSummaryItem(summaryItem, button);
} else {
- this._setClickedSummaryItem(null);
+ this._setClickedSummaryItem(summaryItem, button);
}
this._updateState();
@@ -2285,9 +2283,11 @@ const MessageTray = new Lang.Class({
}
this._summaryBoxPointerState = State.HIDING;
- this._setClickedSummaryItem(null);
this._unlock();
+ if (this._summaryBoxPointerItem == this._clickedSummaryItem)
+ this._setClickedSummaryItem(null);
+
if (this._summaryBoxPointerItem.source.notifications.length == 0) {
this._summaryBoxPointer.actor.hide();
this._hideSummaryBoxPointerCompleted();
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]