[gnome-shell/wip/gdm-shell: 12/16] dateMenu: Force min-width of events area, not whole menu



commit 32aa9be1c8088124a2d713ca3471520fa90ea51f
Author: Ray Strode <rstrode redhat com>
Date:   Tue Jun 28 08:57:19 2011 -0400

    dateMenu: Force min-width of events area, not whole menu
    
    The theme currently hard codes the minimum size of the calendar
    menu to make sure there's a designated area for events
    (even if their isn't anything currently scheduled).
    
    A side-effect of the hard coded minimum width is that
    if the events area is hidden, the menu ends up much
    bigger than the calendar.  We don't currently ever hide
    the events area, but we will in the future.
    
    This commit moves the min-width restriction from the menu
    specifically to the events area.

 data/theme/gnome-shell.css |    6 +++---
 js/ui/dateMenu.js          |    6 +++---
 2 files changed, 6 insertions(+), 6 deletions(-)
---
diff --git a/data/theme/gnome-shell.css b/data/theme/gnome-shell.css
index ab03867..e8030b9 100644
--- a/data/theme/gnome-shell.css
+++ b/data/theme/gnome-shell.css
@@ -804,9 +804,9 @@ StTooltip StLabel {
 
 /* Calendar popup */
 
-#calendarArea {
-    /* this is the width of the entire popup */
-    min-width: 600px;
+#calendarEventsArea {
+    /* this is the width of the second column of the popup */
+    min-width: 400px;
 }
 
 .calendar-vertical-separator {
diff --git a/js/ui/dateMenu.js b/js/ui/dateMenu.js
index 7926861..cb41ec2 100644
--- a/js/ui/dateMenu.js
+++ b/js/ui/dateMenu.js
@@ -61,7 +61,7 @@ DateMenuButton.prototype = {
         this._clock = new St.Label();
         this.actor.set_child(this._clock);
 
-        hbox = new St.BoxLayout({name: 'calendarArea'});
+        hbox = new St.BoxLayout();
         this.menu.addActor(hbox);
 
         // Fill up the first column
@@ -103,8 +103,8 @@ DateMenuButton.prototype = {
         hbox.add(item);
 
         // Fill up the second column
-
-        vbox = new St.BoxLayout({vertical: true});
+        vbox = new St.BoxLayout({ name:     'calendarEventsArea',
+                                  vertical: true});
         hbox.add(vbox, { expand: true });
 
         // Event list



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