← Back to team overview

ubuntu-touch-coreapps-reviewers team mailing list archive

[Merge] lp:~vthompson/ubuntu-weather-app/reboot-add-condition-text into lp:ubuntu-weather-app/reboot

 

Victor Thompson has proposed merging lp:~vthompson/ubuntu-weather-app/reboot-add-condition-text into lp:ubuntu-weather-app/reboot with lp:~vthompson/ubuntu-weather-app/reboot-chance-of-rain as a prerequisite.

Commit message:
Add conditions text to day delegate.

Requested reviews:
  Ubuntu Weather Developers (ubuntu-weather-dev)

For more details, see:
https://code.launchpad.net/~vthompson/ubuntu-weather-app/reboot-add-condition-text/+merge/263307

Add conditions text to day delegate.
-- 
Your team Ubuntu Weather Developers is requested to review the proposed merge of lp:~vthompson/ubuntu-weather-app/reboot-add-condition-text into lp:ubuntu-weather-app/reboot.
=== modified file 'app/components/DayDelegate.qml'
--- app/components/DayDelegate.qml	2015-06-30 00:48:43 +0000
+++ app/components/DayDelegate.qml	2015-06-30 00:48:43 +0000
@@ -31,7 +31,7 @@
     property alias high: highLabel.text
     property alias low: lowLabel.text
 
-    property alias description: descriptionForecast.text
+    property alias condition: conditionForecast.text
     property alias chanceOfRain: chanceOfRainForecast.value
     property alias humidity: humidityForecast.value
     property alias pollen: pollenForecast.value
@@ -187,13 +187,11 @@
 
             // Overview text
             Label {
-                id: descriptionForecast
+                id: conditionForecast
                 color: UbuntuColors.coolGrey
                 fontSize: "x-large"
                 horizontalAlignment: Text.AlignHCenter
-                text: i18n.tr("Chance of rain")
                 width: parent.width
-                visible: false  // FIXME: add overview text eg "Chance of flurries"
             }
 
             ForecastDetailsDelegate {

=== modified file 'app/ui/LocationPane.qml'
--- app/ui/LocationPane.qml	2015-06-30 00:48:43 +0000
+++ app/ui/LocationPane.qml	2015-06-30 00:48:43 +0000
@@ -97,6 +97,7 @@
                     low: Math.round(forecasts[x][tempUnits].tempMin).toString() + settings.tempScale,
                     high: (forecasts[x][tempUnits].tempMax !== undefined) ? Math.round(forecasts[x][tempUnits].tempMax).toString() + settings.tempScale : "",
                     image: (forecasts[x].icon !== undefined && iconMap[forecasts[x].icon] !== undefined) ? iconMap[forecasts[x].icon] : "",
+                    condition: emptyIfUndefined(forecasts[x].condition),
                     chanceOfRain: emptyIfUndefined(forecasts[x].propPrecip, "%"),
                     humidity: emptyIfUndefined(forecasts[x].humidity, "%"),
                     uvIndex: emptyIfUndefined(forecasts[x].uv),
@@ -181,6 +182,7 @@
                 image: model.image
                 low: model.low
 
+                condition: model.condition
                 chanceOfRain: model.chanceOfRain
                 humidity: model.humidity
                 // TODO: extra from API


Follow ups