[gnome-weather] city: add a style class for setting the background under the content view
- From: William Jon McCann <mccann src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-weather] city: add a style class for setting the background under the content view
- Date: Wed, 6 Mar 2013 22:26:25 +0000 (UTC)
commit ad553f59b08160ada32da31340a0cf9b65fbb0e6
Author: William Jon McCann <william jon mccann gmail com>
Date: Wed Mar 6 12:24:58 2013 -0500
city: add a style class for setting the background under the content view
https://bugzilla.gnome.org/show_bug.cgi?id=695313
data/application.css | 4 ++++
src/city.js | 9 +++++++--
2 files changed, 11 insertions(+), 2 deletions(-)
---
diff --git a/data/application.css b/data/application.css
index b8d63fa..71c74bb 100644
--- a/data/application.css
+++ b/data/application.css
@@ -3,6 +3,10 @@
icon-shadow: inset 1px 1px 3px black;
}
+#weather-page-content-view {
+ background-color: black;
+}
+
#loading-label {
padding-top: 24px;
font-size: 1.5em;
diff --git a/src/city.js b/src/city.js
index 2419f6e..0984760 100644
--- a/src/city.js
+++ b/src/city.js
@@ -30,7 +30,12 @@ const WeatherWidget = new Lang.Class({
name: 'weather-page' });
this.parent(params);
+ let outerBox = new Gtk.Box({ orientation: Gtk.Orientation.HORIZONTAL });
+ let contentFrame = new Gtk.Frame({ name: 'weather-page-content-view' });
+ outerBox.add(contentFrame);
+
let outerGrid = new Gtk.Grid();
+ contentFrame.add(outerGrid);
let alignment = new Gtk.Grid({ hexpand: true, vexpand: true,
halign: Gtk.Align.CENTER,
@@ -74,7 +79,7 @@ const WeatherWidget = new Lang.Class({
this._revealer = new Gd.Revealer({ child: this._today,
reveal_child: false,
orientation: Gtk.Orientation.VERTICAL });
- outerGrid.attach(this._revealer, 2, 0, 1, 2);
+ outerBox.add(this._revealer);
this._revealButton.connect('clicked', Lang.bind(this, function() {
if (this._revealer.reveal_child) {
@@ -86,7 +91,7 @@ const WeatherWidget = new Lang.Class({
}
}));
- this.add(outerGrid);
+ this.add(outerBox);
},
clear: function() {
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]