[gnome-shell/wip/message-tray: 35/41] 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: 35/41] messageTray: Be able to "switch" notifications
- Date: Sat, 18 Aug 2012 17:21:09 +0000 (UTC)
commit 2856b60a0c53242b6985c9026c907cfaebbb1bf2
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 c03d663..54bc783 100644
--- a/js/ui/messageTray.js
+++ b/js/ui/messageTray.js
@@ -1631,10 +1631,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();
@@ -2271,9 +2269,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]