[gnome-shell] message-tray: Fix dismissing notifications
- From: Florian Müllner <fmuellner src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-shell] message-tray: Fix dismissing notifications
- Date: Mon, 28 Mar 2011 17:46:39 +0000 (UTC)
commit 25b743b03cefc9c2d879016f7dcb98673964d7a9
Author: Florian Müllner <fmuellner gnome org>
Date: Sun Mar 27 17:58:23 2011 +0200
message-tray: Fix dismissing notifications
Commit 31b12635d1 fixed links in notifications again, but blocked
clicks on normal labels getting through to the notification. Fix
this, so that both links and dismissing notifications work again.
https://bugzilla.gnome.org/show_bug.cgi?id=645839
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 f592f48..f1244a5 100644
--- a/js/ui/messageTray.js
+++ b/js/ui/messageTray.js
@@ -108,12 +108,12 @@ URLHighlighter.prototype = {
}
this.setMarkup(text, allowMarkup);
- this.actor.connect('button-press-event', function() {
+ this.actor.connect('button-press-event', Lang.bind(this, function(actor, event) {
// Keep Notification.actor from seeing this and taking
// a pointer grab, which would block our button-release-event
- // handler
- return true;
- });
+ // handler, if an URL is clicked
+ return this._findUrlAtPos(event) != -1;
+ }));
this.actor.connect('button-release-event', Lang.bind(this, function (actor, event) {
let urlId = this._findUrlAtPos(event);
if (urlId != -1) {
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]