[gnome-shell/wip/message-tray: 32/32] messageTray: Close the current box pointer when clicking on the same item
- From: Marina Zhurakhinskaya <marinaz src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-shell/wip/message-tray: 32/32] messageTray: Close the current box pointer when clicking on the same item
- Date: Fri, 17 Aug 2012 01:39:37 +0000 (UTC)
commit 303b547f21cffb6e5e5c92cca25672d8d3d13c98
Author: Jasper St. Pierre <jstpierre mecheye net>
Date: Thu Aug 16 13:54:03 2012 -0400
messageTray: Close the current box pointer when clicking on the same item
js/ui/messageTray.js | 7 +++++--
1 files changed, 5 insertions(+), 2 deletions(-)
---
diff --git a/js/ui/messageTray.js b/js/ui/messageTray.js
index 76b6c43..a861c4c 100644
--- a/js/ui/messageTray.js
+++ b/js/ui/messageTray.js
@@ -1628,7 +1628,8 @@ const MessageTray = new Lang.Class({
if (summaryItem.source.handleSummaryClick()) {
this._setClickedSummaryItem(null);
} else {
- this._setClickedSummaryItem(summaryItem, button);
+ if (!this._setClickedSummaryItem(summaryItem, button))
+ this._setClickedSummaryItem(null);
}
this._updateState();
@@ -2227,7 +2228,7 @@ const MessageTray = new Lang.Class({
_setClickedSummaryItem: function(item, button) {
if (item == this._clickedSummaryItem &&
button == this._clickedSummaryItemMouseButton)
- return;
+ return false;
if (this._clickedSummaryItem) {
this._clickedSummaryItem.actor.remove_style_pseudo_class('selected');
@@ -2254,6 +2255,8 @@ const MessageTray = new Lang.Class({
this._trayMotionId = Main.layoutManager.trayBox.connect('notify::anchor-y',
Lang.bind(this, this._adjustSummaryBoxPointerPosition));
}
+
+ return true;
},
_onSummaryBoxPointerUngrabbed: function() {
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]