[gnome-shell/wip/fmuellner/notification-redux+sass: 136/141] messageTray: Remove overlaid close button



commit 67f312034e6e1db86665e76f6cf68030878aee23
Author: Florian Müllner <fmuellner gnome org>
Date:   Wed Feb 11 20:35:50 2015 +0100

    messageTray: Remove overlaid close button
    
    The new notification banner already includes a close button, so remove
    the one provided by the tray.

 js/ui/messageTray.js |   15 ---------------
 1 files changed, 0 insertions(+), 15 deletions(-)
---
diff --git a/js/ui/messageTray.js b/js/ui/messageTray.js
index dda137a..fbfcf40 100644
--- a/js/ui/messageTray.js
+++ b/js/ui/messageTray.js
@@ -1497,11 +1497,6 @@ const MessageTray = new Lang.Class({
         this._banner = null;
         this._bannerClickedId = 0;
 
-        this._closeButton = Util.makeCloseButton();
-        this._closeButton.hide();
-        this._closeButton.connect('clicked', Lang.bind(this, this._closeNotification));
-        this.actor.add_actor(this._closeButton);
-
         this._userActiveWhileNotificationShown = false;
 
         this.idleMonitor = Meta.IdleMonitor.get_core();
@@ -1527,7 +1522,6 @@ const MessageTray = new Lang.Class({
 
         Main.layoutManager.trayBox.add_actor(this.actor);
         Main.layoutManager.trackChrome(this.actor);
-        Main.layoutManager.trackChrome(this._closeButton);
         Main.layoutManager.trackChrome(this._notificationBin, { affectsInputRegion: true });
 
         global.screen.connect('in-fullscreen-changed', Lang.bind(this, this._updateState));
@@ -1565,14 +1559,6 @@ const MessageTray = new Lang.Class({
         this._updateState();
     },
 
-    _closeNotification: function() {
-        if (this._notificationState == State.SHOWN) {
-            this._closeButton.hide();
-            this._notification.emit('done-displaying');
-            this._notification.destroy();
-        }
-    },
-
     get queueCount() {
         return this._notificationQueue.length;
     },
@@ -2032,7 +2018,6 @@ const MessageTray = new Lang.Class({
         if (notification.isTransient)
             notification.destroy(NotificationDestroyedReason.EXPIRED);
 
-        this._closeButton.hide();
         this._pointerInNotification = false;
         this._notificationRemoved = false;
 


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]