Merge git://github.com/simon04/gnome-shell-extension-weather

yahoo_weather
Simon Claessens 14 years ago
commit 7f0673f6f7
  1. 31
      README
  2. 32
      README.md
  3. 4
      TODO
  4. BIN
      screenshot.png
  5. 7
      weather@venemo.net/extension.js
  6. 2
      weather@venemo.net/metadata.json

@ -1,31 +0,0 @@
gnome-shell-extension-weather is a simple extension for displaying weather notifications in Gnome Shell.
Installation:
Change YAHOO_ID to your location in extension.js (cf. WOEID)
Put directory weather@venemo.com in ~/.local/share/gnome-shell/extensions/
Restart Gnome Shell ([Alt]+[F2], `r`)
Enjoy, contribute, ...
Licence:
Copyright (C) 2011
Timur Kristóf <venemo@msn.com>,
Elad Alfassa <elad@fedoraproject.org>,
Simon Legner <Simon.Legner@gmail.com>
This file is part of gnome-shell-extension-weather.
gnome-shell-extension-weather is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.
gnome-shell-extension-weather is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with gnome-shell-extension-weather. If not, see <http://www.gnu.org/licenses/>.

@ -0,0 +1,32 @@
## gnome-shell-extension-weather
gnome-shell-extension-weather is a simple extension for displaying weather notifications in Gnome Shell.
Currently, the weather report including forecast for today and tomorrow is fetched from [Yahoo](http://weather.yahoo.com/).
### Screenshot
![Screenshot](https://github.com/simon04/gnome-shell-extension-weather/raw/master/screenshot.png)
### Installation
1. Change `YAHOO_ID` to your location in extension.js (cf. [WOEID](http://developer.yahoo.com/geo/geoplanet/guide/concepts.html))
2. Put directory `weather@venemo.com/` in `~/.local/share/gnome-shell/extensions/`
3. Restart Gnome Shell (`[Alt]+[F2]`, `r`)
4. Enjoy, contribute, ...
### Licence
Copyright (C) 2011
Timur Kristóf <venemo@msn.com>,
Elad Alfassa <elad@fedoraproject.org>,
Simon Legner <Simon.Legner@gmail.com>
This file is part of gnome-shell-extension-weather.
gnome-shell-extension-weather is free software: you can redistribute it and/or modify it under the terms of the **GNU General Public License as published by the Free Software Foundation, either version 3** of the License, or (at your option) any later version.
gnome-shell-extension-weather is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
You should have received a copy of the GNU General Public License along with gnome-shell-extension-weather. If not, see <http://www.gnu.org/licenses/>.

@ -1,4 +0,0 @@
TODO List:
* Write the deamon that talks with libgweather (or make sure libgweather is fixed upstream)
** Implement talking to the deamon with DBus
* Find how to deal with translations (autotools?)

Binary file not shown.

After

Width:  |  Height:  |  Size: 71 KiB

@ -84,6 +84,7 @@ WeatherMenuButton.prototype = {
topBox.add_actor(this._weatherInfo);
this.actor.set_child(topBox);
Main.panel._centerBox.add(this.actor, { y_fill: true });
Main.panel._menus.addMenu(this.menu);
// Current weather
this._currentWeather = new St.Bin({style_class: 'current'});
@ -251,7 +252,7 @@ WeatherMenuButton.prototype = {
let location = weather.get_object_member('location').get_string_member('city');
let comment = weather.get_object_member('condition').get_string_member('text');
let temperature = weather.get_object_member('condition').get_double_member('temperature');
let temperature_unit = weather.get_object_member('units').get_string_member('temperature');
let temperature_unit = '\u00b0' + weather.get_object_member('units').get_string_member('temperature');
let humidity = weather.get_object_member('atmosphere').get_string_member('humidity') + ' %';
let pressure = weather.get_object_member('atmosphere').get_double_member('pressure');
pressure_unit = weather.get_object_member('units').get_string_member('pressure');
@ -321,7 +322,7 @@ WeatherMenuButton.prototype = {
// This will hold the icon for the current weather
this._currentWeatherIcon = new St.Icon({
icon_type: St.IconType.FULLCOLOR,
icon_type: St.IconType.FULLCOLOR, //TODO SYMBOLIC not available in 64x64!?
icon_size: 64,
icon_name: 'view-refresh-symbolic',
style_class: 'weather-current-icon'
@ -381,7 +382,7 @@ WeatherMenuButton.prototype = {
let forecastWeather = {};
forecastWeather.Icon = new St.Icon({
icon_type: St.IconType.FULLCOLOR,
icon_type: St.IconType.SYMBOLIC,
icon_size: 48,
icon_name: 'view-refresh-symbolic',
style_class: 'weather-forecast-icon'

@ -1 +1 @@
{"shell-version": ["3.0.1"], "uuid": "weather@venemo.net", "name": "Weather", "description": "Adds weather information next to the clock."}
{"shell-version": ["3.0"], "uuid": "weather@venemo.net", "name": "Weather", "description": "Adds weather information next to the clock."}

Loading…
Cancel
Save