[gnome-shell] messageTray: Don't use gravity for notificationBin



commit 752c25bb7d66b07798c8b5dfe1d63712a871123f
Author: Adel Gadllah <adel gadllah gmail com>
Date:   Thu Apr 8 20:36:20 2010 +0200

    messageTray: Don't use gravity for notificationBin
    
    When the notificaionBin has an odd width this could result into
    loosing pixel aligment (and ugly looking font).
    
    As the notification is already reactive make it non reactive and
    remove the use of garvity.
    
    https://bugzilla.gnome.org/show_bug.cgi?id=614702

 js/ui/messageTray.js |    6 +++---
 1 files changed, 3 insertions(+), 3 deletions(-)
---
diff --git a/js/ui/messageTray.js b/js/ui/messageTray.js
index 921210b..7822737 100644
--- a/js/ui/messageTray.js
+++ b/js/ui/messageTray.js
@@ -394,8 +394,7 @@ MessageTray.prototype = {
                                         track_hover: true });
         this.actor.connect('notify::hover', Lang.bind(this, this._onTrayHoverChanged));
 
-        this._notificationBin = new St.Bin({ reactive: true,
-                                             anchor_gravity: Clutter.Gravity.NORTH });
+        this._notificationBin = new St.Bin();
         this.actor.add(this._notificationBin);
         this._notificationBin.hide();
         this._notificationQueue = [];
@@ -463,9 +462,10 @@ MessageTray.prototype = {
         this.actor.x = primary.x;
         this.actor.y = primary.y + primary.height - 1;
         this.actor.width = primary.width;
+        this._notificationBin.x = 0;
+        this._notificationBin.width = primary.width;
 
         // These work because of their anchor_gravity
-        this._notificationBin.x = primary.width / 2;
         this._summaryBin.x = primary.width;
         this._summaryNotificationBin.x = primary.width;
     },



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