Merge lp:~nik90/ubuntu-weather-app/fix-ota10-sdk-issues into lp:ubuntu-weather-app

Proposed by Nekhelesh Ramananthan on 2016-02-28
Status: Merged
Approved by: Victor Thompson on 2016-03-26
Approved revision: 227
Merged at revision: 230
Proposed branch: lp:~nik90/ubuntu-weather-app/fix-ota10-sdk-issues
Merge into: lp:ubuntu-weather-app
Diff against target: 830 lines (+218/-199)
13 files modified
app/components/ExpandableListItem.qml (+17/-24)
app/components/NoAPIKeyErrorStateComponent.qml (+2/-3)
app/components/StandardListItem.qml (+11/-17)
app/ui/AddLocationPage.qml (+52/-70)
app/ui/HomePage.qml (+2/-3)
app/ui/SettingsPage.qml (+33/-11)
app/ui/settings/DataProviderPage.qml (+12/-7)
app/ui/settings/LocationPage.qml (+20/-11)
app/ui/settings/RefreshIntervalPage.qml (+12/-7)
app/ui/settings/UnitsPage.qml (+18/-13)
debian/changelog (+7/-1)
manifest.json.in (+1/-1)
po/com.ubuntu.weather.pot (+31/-31)
To merge this branch: bzr merge lp:~nik90/ubuntu-weather-app/fix-ota10-sdk-issues
Reviewer Review Type Date Requested Status
Jenkins Bot continuous-integration Approve on 2016-03-26
Victor Thompson 2016-02-28 Approve on 2016-03-26
Review via email: mp+287421@code.launchpad.net

Commit message

- Migrated Settings Page (and its child settings pages) to ListItemLayouts and PageHeader which fixes lot of the colouring issues. Also, in UC 1.3, the page.head, page.title and page.flickable is deprecated.

- Updated framework to ubuntu-sdk-15.04.3-qml
- Fixed label color issue in AddLocationsPage

Description of the change

- Migrated Settings Page (and its child settings pages) to ListItemLayouts and PageHeader which fixes lot of the colouring issues. Also, in UC 1.3, the page.head, page.title and page.flickable is deprecated.

- Updated framework to ubuntu-sdk-15.04.3-qml

To post a comment you must log in.
227. By Nekhelesh Ramananthan on 2016-02-28

Replace clock with weather in header

review: Needs Fixing (continuous-integration)
Victor Thompson (vthompson) wrote :

Functionally, issues #2 and #4 (recently added) are still occurring. I suspect Issues #4 is possibly an SDK issue--it affects Music as well. Although the code is probably similar, as I'm sure we borrowed the header state logic from Music.

Other comments on functionality:

1. Could we make the Settings and AddCityPage pages white to match the header? It is slightly off-white now and the header is white.
2. FastScroll is currently the light blue color--while it looks OK it doesn't fit the theme very well.

Code looks good at first glance--will need to actually review it.

review: Needs Fixing
Victor Thompson (vthompson) wrote :

In the above review, I meant issues #1 and #4 are still occurring. For #4, the music app made changes to set the visible property rather than the enabled property.

Victor Thompson (vthompson) wrote :

I support merging this and fixing the remaining issues shortly.

review: Approve
review: Approve (continuous-integration)

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
=== modified file 'app/components/ExpandableListItem.qml'
--- app/components/ExpandableListItem.qml 2015-11-02 21:28:34 +0000
+++ app/components/ExpandableListItem.qml 2016-02-28 22:59:00 +0000
@@ -1,5 +1,5 @@
1/*1/*
2 * Copyright (C) 2015 Canonical Ltd2 * Copyright (C) 2015-2016 Canonical Ltd
3 *3 *
4 * This file is part of Ubuntu Weather App4 * This file is part of Ubuntu Weather App
5 *5 *
@@ -18,31 +18,27 @@
1818
19import QtQuick 2.419import QtQuick 2.4
20import Ubuntu.Components 1.320import Ubuntu.Components 1.3
21import Ubuntu.Components.ListItems 1.0 as ListItem
2221
23/*22/*
24 Component which extends the SDK Expandable list item and provides a easy23 Component which extends the SDK Expandable list item and provides a easy
25 to use component where the title, subtitle and listview can be displayed. It24 to use component where the title, subtitle and a listview can be displayed. It
26 matches the design specification provided for clock.25 matches the design specification provided for clock.
27*/26*/
2827
29ListItem.Expandable {28ListItem {
30 id: expandableListItem29 id: expandableListItem
3130
31 // Public APIs
32 property ListModel model32 property ListModel model
33 property Component delegate33 property Component delegate
34 property alias text: expandableHeader.text34 property alias title: expandableHeader.title
35 property alias subText: expandableHeader.subText35 property alias subText: expandableHeader.subtitle
36 property alias listViewHeight: expandableList.height36 property alias listViewHeight: expandableList.height
3737
38 anchors {38 highlightColor: "Transparent"
39 left: parent.left39 height: expandableHeader.height + divider.height
40 right: parent.right40 expansion.height: contentColumn.height
41 margins: units.gu(-2)41 onClicked: expansion.expanded = !expansion.expanded
42 }
43
44 collapseOnClick: true
45 expandedHeight: contentColumn.height + units.gu(1)
4642
47 Column {43 Column {
48 id: contentColumn44 id: contentColumn
@@ -52,25 +48,21 @@
52 right: parent.right48 right: parent.right
53 }49 }
5450
55 Item {51 ListItem {
56 width: parent.width52 height: expandableHeader.height + divider.height
57 height: expandableListItem.collapsedHeight53 ListItemLayout {
58
59 ListItem.Subtitled {
60 id: expandableHeader54 id: expandableHeader
61 onClicked: expandableListItem.expanded = true
6255
63 Icon {56 Icon {
64 id: arrow57 id: arrow
6558
66 width: units.gu(2)59 width: units.gu(2)
67 height: width60 height: width
68 anchors.right: parent.right61 SlotsLayout.position: SlotsLayout.Trailing
62 SlotsLayout.overrideVerticalPositioning: true
69 anchors.verticalCenter: parent.verticalCenter63 anchors.verticalCenter: parent.verticalCenter
70
71 name: "go-down"64 name: "go-down"
72 color: "Grey"65 rotation: expandableListItem.expansion.expanded ? 180 : 0
73 rotation: expandableListItem.expanded ? 180 : 0
7466
75 Behavior on rotation {67 Behavior on rotation {
76 UbuntuNumberAnimation {}68 UbuntuNumberAnimation {}
@@ -88,3 +80,4 @@
88 }80 }
89 }81 }
90}82}
83
9184
=== modified file 'app/components/NoAPIKeyErrorStateComponent.qml'
--- app/components/NoAPIKeyErrorStateComponent.qml 2015-11-12 01:45:36 +0000
+++ app/components/NoAPIKeyErrorStateComponent.qml 2016-02-28 22:59:00 +0000
@@ -1,5 +1,5 @@
1/*1/*
2 * Copyright (C) 2015 Canonical Ltd2 * Copyright (C) 2015-2016 Canonical Ltd
3 *3 *
4 * This file is part of Ubuntu Weather App4 * This file is part of Ubuntu Weather App
5 *5 *
@@ -17,10 +17,9 @@
17 */17 */
1818
19import QtQuick 2.419import QtQuick 2.4
20import Ubuntu.Components 1.520import Ubuntu.Components 1.3
21import "../components"21import "../components"
2222
23
24Rectangle {23Rectangle {
25 color: "white"24 color: "white"
26 anchors.fill: parent25 anchors.fill: parent
2726
=== modified file 'app/components/StandardListItem.qml'
--- app/components/StandardListItem.qml 2015-11-02 21:28:34 +0000
+++ app/components/StandardListItem.qml 2016-02-28 22:59:00 +0000
@@ -17,32 +17,26 @@
17 */17 */
1818
19import QtQuick 2.419import QtQuick 2.4
20import QtQuick.Layouts 1.1
21import Ubuntu.Components 1.320import Ubuntu.Components 1.3
2221
23ListItem {22ListItem {
24 id: listItem23 id: listItem
2524
26 property alias title: _title.text25 property alias title: listitemlayout.title
27 property alias icon: _icon.name26 property alias icon: _icon
28 property alias showIcon: _icon.visible27
2928 height: listitemlayout.height + divider.height
30 RowLayout {29
31 anchors { left: parent.left; right: parent.right; verticalCenter: parent.verticalCenter; margins: units.gu(2) }30 ListItemLayout {
32 height: _icon.height31 id: listitemlayout
33 spacing: units.gu(2)32
34 33 title.text: ""
35 Label {34
36 id: _title
37 anchors.verticalCenter: _icon.verticalCenter
38 elide: Text.ElideRight
39 Layout.fillWidth: true
40 }
41
42 Icon {35 Icon {
43 id: _icon36 id: _icon
44 height: units.gu(2); width: height37 height: units.gu(2); width: height
45 name: "go-next"38 name: "go-next"
39 SlotsLayout.position: SlotsLayout.Last
46 }40 }
47 }41 }
48}42}
4943
=== modified file 'app/ui/AddLocationPage.qml'
--- app/ui/AddLocationPage.qml 2015-11-02 21:28:34 +0000
+++ app/ui/AddLocationPage.qml 2016-02-28 22:59:00 +0000
@@ -1,5 +1,5 @@
1/*1/*
2 * Copyright (C) 2015 Canonical Ltd2 * Copyright (C) 2015-2016 Canonical Ltd
3 *3 *
4 * This file is part of Ubuntu Weather App4 * This file is part of Ubuntu Weather App
5 *5 *
@@ -26,65 +26,60 @@
26Page {26Page {
27 id: addLocationPage27 id: addLocationPage
28 objectName: "addLocationPage"28 objectName: "addLocationPage"
29 title: i18n.tr("Select a city")29
30 visible: false30 visible: false
3131
32 /*
33 Flickable is set to null to stop page header from hiding since the fast
34 scroll component hides top anchor margin is incorrect.
35 */
36 flickable: null
37
38 property bool searching: citiesModel.loading || searchTimer.running32 property bool searching: citiesModel.loading || searchTimer.running
3933
40 state: "default"34 header: standardHeader
41 states: [35
42 PageHeadState {36 PageHeader {
43 name: "default"37 id: standardHeader
44 head: addLocationPage.head38 title: i18n.tr("Select a city")
45 backAction: Action {39 /*
46 iconName: "back"40 Flickable is set to null to stop page header from hiding since the fast
47 text: i18n.tr("Back")41 scroll component hides top anchor margin is incorrect.
48 onTriggered: mainPageStack.pop()42 */
43 flickable: null
44 visible: addLocationPage.header === standardHeader
45 trailingActionBar.actions: [
46 Action {
47 iconName: "search"
48 objectName: "search"
49 text: i18n.tr("City")
50 onTriggered: {
51 addLocationPage.header = searchHeader
52 searchComponentLoader.sourceComponent = searchComponent
53 searchComponentLoader.item.forceActiveFocus()
54 }
49 }55 }
50 actions: [56 ]
51 Action {57 }
52 iconName: "search"
53 objectName: "search"
54 text: i18n.tr("City")
55 onTriggered: {
56 addLocationPage.state = "search"
57 searchComponentLoader.sourceComponent = searchComponent
58 searchComponentLoader.item.forceActiveFocus()
59 }
60 }
61 ]
62 },
6358
64 PageHeadState {59 PageHeader {
65 name: "search"60 id: searchHeader
66 head: addLocationPage.head61 visible: addLocationPage.header === searchHeader
67 backAction: Action {62 leadingActionBar.actions: [
63 Action {
68 iconName: "back"64 iconName: "back"
69 text: i18n.tr("Back")65 text: i18n.tr("Back")
70 onTriggered: {66 onTriggered: {
71 locationList.forceActiveFocus()67 locationList.forceActiveFocus()
72 searchComponentLoader.item.text = ""68 searchComponentLoader.item.text = ""
73 addLocationPage.state = "default"69 addLocationPage.header = standardHeader
74 searchComponentLoader.sourceComponent = undefined70 searchComponentLoader.sourceComponent = undefined
75 }71 }
76 }72 }
7773 ]
78 contents: Loader {74 contents: Loader {
79 id: searchComponentLoader75 id: searchComponentLoader
80 anchors {76 anchors {
81 left: parent ? parent.left : undefined77 left: parent ? parent.left : undefined
82 right: parent ? parent.right : undefined78 right: parent ? parent.right : undefined
83 rightMargin: units.gu(2)79 verticalCenter: parent ? parent.verticalCenter : undefined
84 }
85 }80 }
86 }81 }
87 ]82 }
8883
89 // Outside component so property can bind to for autopilot84 // Outside component so property can bind to for autopilot
90 Timer {85 Timer {
@@ -181,9 +176,12 @@
181 ListView {176 ListView {
182 id: locationList177 id: locationList
183 anchors {178 anchors {
184 fill: parent179 top: addLocationPage.header.bottom
180 topMargin: units.gu(2)
181 left: parent.left
182 right: parent.right
185 rightMargin: fastScroll.showing ? fastScroll.width - units.gu(1) : 0183 rightMargin: fastScroll.showing ? fastScroll.width - units.gu(1) : 0
186 topMargin: units.gu(2)184 bottom: parent.bottom
187 }185 }
188186
189 objectName: "locationList"187 objectName: "locationList"
@@ -224,30 +222,14 @@
224 delegate: ListItem {222 delegate: ListItem {
225 divider.visible: false223 divider.visible: false
226 objectName: "addLocation" + index224 objectName: "addLocation" + index
227 Column {225
228 anchors {226 height: listDelegateLayout.height
229 left: parent.left227
230 leftMargin: units.gu(2)228 ListItemLayout {
231 right: parent.right229 id: listDelegateLayout
232 rightMargin: units.gu(2)230 title.text: name
233 verticalCenter: parent.verticalCenter231 subtitle.text: areaLabel
234 }232 subtitle.textSize: Label.Small
235
236 Label {
237 color: UbuntuColors.darkGrey
238 elide: Text.ElideRight
239 fontSize: "medium"
240 text: name
241 width: parent.width
242 }
243
244 Label {
245 color: UbuntuColors.lightGrey
246 elide: Text.ElideRight
247 fontSize: "xx-small"
248 text: areaLabel
249 width: parent.width
250 }
251 }233 }
252234
253 onClicked: {235 onClicked: {
254236
=== modified file 'app/ui/HomePage.qml'
--- app/ui/HomePage.qml 2015-11-26 02:05:13 +0000
+++ app/ui/HomePage.qml 2016-02-28 22:59:00 +0000
@@ -1,5 +1,5 @@
1/*1/*
2 * Copyright (C) 2015 Canonical Ltd2 * Copyright (C) 2015-2016 Canonical Ltd
3 *3 *
4 * This file is part of Ubuntu Weather App4 * This file is part of Ubuntu Weather App
5 *5 *
@@ -85,8 +85,7 @@
85 }85 }
8686
87 // Do not show the Page Header87 // Do not show the Page Header
88 head {88 header: PageHeader {
89 locked: true
90 visible: false89 visible: false
91 }90 }
9291
9392
=== modified file 'app/ui/SettingsPage.qml'
--- app/ui/SettingsPage.qml 2015-11-02 21:28:34 +0000
+++ app/ui/SettingsPage.qml 2016-02-28 22:59:00 +0000
@@ -1,5 +1,5 @@
1/*1/*
2 * Copyright (C) 2015 Canonical Ltd2 * Copyright (C) 2015-2016 Canonical Ltd
3 *3 *
4 * This file is part of Ubuntu Weather App4 * This file is part of Ubuntu Weather App
5 *5 *
@@ -21,31 +21,53 @@
21import "../components"21import "../components"
2222
23Page {23Page {
24 title: i18n.tr("Settings")24 id: settingsPage
25
26 header: PageHeader {
27 title: i18n.tr("Settings")
28 }
29
25 property bool bug1341671workaround: true30 property bool bug1341671workaround: true
2631
27 Column {32 Column {
28 id: settingsColumn33 id: settingsColumn
2934
30 anchors.fill: parent35 anchors {
36 top: settingsPage.header.bottom
37 left: parent.left
38 right: parent.right
39 bottom: parent.bottom
40 }
3141
32 StandardListItem {42 ListItem {
33 title: i18n.tr("Units")43 ListItemLayout {
44 title.text: i18n.tr("Units")
45 ProgressionSlot{}
46 }
34 onClicked: mainPageStack.push(Qt.resolvedUrl("settings/UnitsPage.qml"))47 onClicked: mainPageStack.push(Qt.resolvedUrl("settings/UnitsPage.qml"))
35 }48 }
3649
37 StandardListItem {50 ListItem {
38 title: i18n.tr("Data Provider")51 ListItemLayout {
52 title.text: i18n.tr("Data Provider")
53 ProgressionSlot{}
54 }
39 onClicked: mainPageStack.push(Qt.resolvedUrl("settings/DataProviderPage.qml"))55 onClicked: mainPageStack.push(Qt.resolvedUrl("settings/DataProviderPage.qml"))
40 }56 }
4157
42 StandardListItem {58 ListItem {
43 title: i18n.tr("Refresh Interval")59 ListItemLayout {
60 title.text: i18n.tr("Refresh Interval")
61 ProgressionSlot{}
62 }
44 onClicked: mainPageStack.push(Qt.resolvedUrl("settings/RefreshIntervalPage.qml"))63 onClicked: mainPageStack.push(Qt.resolvedUrl("settings/RefreshIntervalPage.qml"))
45 }64 }
4665
47 StandardListItem {66 ListItem {
48 title: i18n.tr("Location")67 ListItemLayout {
68 title.text: i18n.tr("Location")
69 ProgressionSlot{}
70 }
49 onClicked: mainPageStack.push(Qt.resolvedUrl("settings/LocationPage.qml"))71 onClicked: mainPageStack.push(Qt.resolvedUrl("settings/LocationPage.qml"))
50 }72 }
51 }73 }
5274
=== modified file 'app/ui/settings/DataProviderPage.qml'
--- app/ui/settings/DataProviderPage.qml 2015-11-02 21:28:34 +0000
+++ app/ui/settings/DataProviderPage.qml 2016-02-28 22:59:00 +0000
@@ -1,5 +1,5 @@
1/*1/*
2 * Copyright (C) 2015 Canonical Ltd2 * Copyright (C) 2015-2016 Canonical Ltd
3 *3 *
4 * This file is part of Ubuntu Weather App4 * This file is part of Ubuntu Weather App
5 *5 *
@@ -22,7 +22,11 @@
22import "../../data/keys.js" as Keys22import "../../data/keys.js" as Keys
2323
24Page {24Page {
25 title: i18n.tr("Data Provider")25 id: dataProviderPage
26
27 header: PageHeader {
28 title: i18n.tr("Data Provider")
29 }
2630
27 ListModel {31 ListModel {
28 id: dataProviderModel32 id: dataProviderModel
@@ -32,15 +36,16 @@
32 ExpandableListItem {36 ExpandableListItem {
33 id: dataProviderSetting37 id: dataProviderSetting
3438
39 anchors.top: dataProviderPage.header.bottom
35 listViewHeight: dataProviderModel.count*units.gu(7) - units.gu(1)40 listViewHeight: dataProviderModel.count*units.gu(7) - units.gu(1)
36 model: dataProviderModel41 model: dataProviderModel
37 text: i18n.tr("Provider")42 title.text: i18n.tr("Provider")
38 subText: settings.service === "weatherchannel" ? "The Weather Channel" : "OpenWeatherMap"43 subText.text: settings.service === "weatherchannel" ? "The Weather Channel" : "OpenWeatherMap"
3944
40 delegate: StandardListItem {45 delegate: StandardListItem {
41 title: model.text46 title.text: model.text
42 icon: "ok"47 icon.name: "ok"
43 showIcon: dataProviderSetting.subText === model.text48 icon.visible: dataProviderSetting.subText === model.text
44 onClicked: {49 onClicked: {
45 if (model.text === "The Weather Channel") {50 if (model.text === "The Weather Channel") {
46 settings.service = "weatherchannel"51 settings.service = "weatherchannel"
4752
=== modified file 'app/ui/settings/LocationPage.qml'
--- app/ui/settings/LocationPage.qml 2015-11-02 21:28:34 +0000
+++ app/ui/settings/LocationPage.qml 2016-02-28 22:59:00 +0000
@@ -1,5 +1,5 @@
1/*1/*
2 * Copyright (C) 2015 Canonical Ltd2 * Copyright (C) 2015-2016 Canonical Ltd
3 *3 *
4 * This file is part of Ubuntu Weather App4 * This file is part of Ubuntu Weather App
5 *5 *
@@ -18,19 +18,28 @@
1818
19import QtQuick 2.419import QtQuick 2.4
20import Ubuntu.Components 1.320import Ubuntu.Components 1.3
21import Ubuntu.Components.ListItems 1.0 as ListItem
2221
23Page {22Page {
24 title: i18n.tr("Location")23 id: locationPage
2524
26 ListItem.Standard {25 header: PageHeader {
27 control: CheckBox {26 title: i18n.tr("Location")
28 checked: settings.detectCurrentLocation27 }
2928
30 onCheckedChanged: settings.detectCurrentLocation = checked;29 ListItem {
30 anchors.top: locationPage.header.bottom
31 height: locationLayout.height + divider.height
32 ListItemLayout {
33 id: locationLayout
34 title.text: i18n.tr("Detect current location")
35 Switch {
36 id: locationSwitch
37 SlotsLayout.position: SlotsLayout.Last
38 checked: settings.detectCurrentLocation
39 onCheckedChanged: settings.detectCurrentLocation = checked;
40 }
31 }41 }
32 text: i18n.tr("Detect current location")
3342
34 onClicked: control.checked = !control.checked43 onClicked: locationSwitch.checked = !locationSwitch.checked
35 }44 }
36}45}
3746
=== modified file 'app/ui/settings/RefreshIntervalPage.qml'
--- app/ui/settings/RefreshIntervalPage.qml 2015-11-02 21:28:34 +0000
+++ app/ui/settings/RefreshIntervalPage.qml 2016-02-28 22:59:00 +0000
@@ -1,5 +1,5 @@
1/*1/*
2 * Copyright (C) 2015 Canonical Ltd2 * Copyright (C) 2015-2016 Canonical Ltd
3 *3 *
4 * This file is part of Ubuntu Weather App4 * This file is part of Ubuntu Weather App
5 *5 *
@@ -21,7 +21,11 @@
21import "../../components"21import "../../components"
2222
23Page {23Page {
24 title: i18n.tr("Refresh Interval")24 id: refreshIntervalPage
25
26 header: PageHeader {
27 title: i18n.tr("Refresh Interval")
28 }
2529
26 ListModel {30 ListModel {
27 id: refreshModel31 id: refreshModel
@@ -37,15 +41,16 @@
37 ExpandableListItem {41 ExpandableListItem {
38 id: dataProviderSetting42 id: dataProviderSetting
3943
44 anchors.top: refreshIntervalPage.header.bottom
40 listViewHeight: refreshModel.count*units.gu(7) - units.gu(1)45 listViewHeight: refreshModel.count*units.gu(7) - units.gu(1)
41 model: refreshModel46 model: refreshModel
42 text: i18n.tr("Interval")47 title.text: i18n.tr("Interval")
43 subText: i18n.tr("%1 minute", "%1 minutes", Math.floor(settings.refreshInterval / 60).toString()).arg(Math.floor(settings.refreshInterval / 60).toString())48 subText.text: i18n.tr("%1 minute", "%1 minutes", Math.floor(settings.refreshInterval / 60).toString()).arg(Math.floor(settings.refreshInterval / 60).toString())
4449
45 delegate: StandardListItem {50 delegate: StandardListItem {
46 title: model.text51 title.text: model.text
47 icon: "ok"52 icon.name: "ok"
48 showIcon: settings.refreshInterval === model.interval53 icon.visible: settings.refreshInterval === model.interval
49 onClicked: {54 onClicked: {
50 settings.refreshInterval = model.interval55 settings.refreshInterval = model.interval
51 refreshData(false, true)56 refreshData(false, true)
5257
=== modified file 'app/ui/settings/UnitsPage.qml'
--- app/ui/settings/UnitsPage.qml 2015-11-02 21:28:34 +0000
+++ app/ui/settings/UnitsPage.qml 2016-02-28 22:59:00 +0000
@@ -1,5 +1,5 @@
1/*1/*
2 * Copyright (C) 2015 Canonical Ltd2 * Copyright (C) 2015-2016 Canonical Ltd
3 *3 *
4 * This file is part of Ubuntu Weather App4 * This file is part of Ubuntu Weather App
5 *5 *
@@ -21,12 +21,17 @@
21import "../../components"21import "../../components"
2222
23Page {23Page {
24 title: i18n.tr("Units")24 id: unitsPage
25
25 property bool bug1341671workaround: true26 property bool bug1341671workaround: true
2627
27 flickable: null28 header: PageHeader {
29 title: i18n.tr("Units")
30 flickable: unitsFlickable
31 }
2832
29 Flickable {33 Flickable {
34 id: unitsFlickable
30 clip: true35 clip: true
31 anchors.fill: parent36 anchors.fill: parent
32 height: parent.height37 height: parent.height
@@ -74,14 +79,14 @@
7479
75 listViewHeight: temperatureModel.count*units.gu(7) - units.gu(1)80 listViewHeight: temperatureModel.count*units.gu(7) - units.gu(1)
76 model: temperatureModel81 model: temperatureModel
77 text: i18n.tr("Temperature")82 title.text: i18n.tr("Temperature")
78 subText: settings.tempScale === "°C" ? i18n.tr("°C")83 subText.text: settings.tempScale === "°C" ? i18n.tr("°C")
79 : i18n.tr("°F")84 : i18n.tr("°F")
8085
81 delegate: StandardListItem {86 delegate: StandardListItem {
82 title: model.text87 title.text: model.text
83 icon: "ok"88 icon.name: "ok"
84 showIcon: settings.tempScale === model.value89 icon.visible: settings.tempScale === model.value
85 onClicked: {90 onClicked: {
86 settings.tempScale = model.value91 settings.tempScale = model.value
87 refreshData(true)92 refreshData(true)
@@ -95,14 +100,14 @@
95100
96 listViewHeight: windSpeedModel.count*units.gu(7) - units.gu(1)101 listViewHeight: windSpeedModel.count*units.gu(7) - units.gu(1)
97 model: windSpeedModel102 model: windSpeedModel
98 text: i18n.tr("Wind Speed")103 title.text: i18n.tr("Wind Speed")
99 subText: settings.windUnits === "kph" ? i18n.tr("kph")104 subText.text: settings.windUnits === "kph" ? i18n.tr("kph")
100 : i18n.tr("mph")105 : i18n.tr("mph")
101106
102 delegate: StandardListItem {107 delegate: StandardListItem {
103 title: model.text108 title.text: model.text
104 icon: "ok"109 icon.name: "ok"
105 showIcon: settings.windUnits === model.value110 icon.visible: settings.windUnits === model.value
106 onClicked: {111 onClicked: {
107 settings.windUnits = model.value112 settings.windUnits = model.value
108 refreshData(true)113 refreshData(true)
109114
=== modified file 'debian/changelog'
--- debian/changelog 2016-01-29 23:07:11 +0000
+++ debian/changelog 2016-02-28 22:59:00 +0000
@@ -8,7 +8,13 @@
8 * Added new READMEs8 * Added new READMEs
99
10 [ Victor Thompson ]10 [ Victor Thompson ]
11 * Change translatable string from "rain" to "precipitation" (LP:1521701)11 * Change translatable string from "rain" to "precipitation" (LP: #1521701)
12
13 [ Nekhelesh Ramananthan ]
14 * Update frameworks to ubuntu-sdk-15.04.3-qml
15 * Migrate Settings Page (and child settings pages) to ListItemLayout
16 and PageLayout.
17 * Fix label color issues due to SDK Palette changed in OTA10 (LP: #1550507)
1218
13 -- Andrew Hayzen <ahayzen@gmail.com> Thu, 03 Dec 2015 15:20:49 +000019 -- Andrew Hayzen <ahayzen@gmail.com> Thu, 03 Dec 2015 15:20:49 +0000
1420
1521
=== modified file 'manifest.json.in'
--- manifest.json.in 2015-12-03 15:22:45 +0000
+++ manifest.json.in 2016-02-28 22:59:00 +0000
@@ -1,7 +1,7 @@
1{1{
2 "architecture": "all",2 "architecture": "all",
3 "description": "A weather forecast application for Ubuntu with support for multiple online weather data sources",3 "description": "A weather forecast application for Ubuntu with support for multiple online weather data sources",
4 "framework": "ubuntu-sdk-15.04.1-qml",4 "framework": "ubuntu-sdk-15.04.3-qml",
5 "hooks": {5 "hooks": {
6 "weather": {6 "weather": {
7 "apparmor": "ubuntu-weather-app.apparmor",7 "apparmor": "ubuntu-weather-app.apparmor",
88
=== modified file 'po/com.ubuntu.weather.pot'
--- po/com.ubuntu.weather.pot 2015-12-12 03:41:27 +0000
+++ po/com.ubuntu.weather.pot 2016-02-28 22:59:00 +0000
@@ -8,7 +8,7 @@
8msgstr ""8msgstr ""
9"Project-Id-Version: ubuntu-weather-app\n"9"Project-Id-Version: ubuntu-weather-app\n"
10"Report-Msgid-Bugs-To: \n"10"Report-Msgid-Bugs-To: \n"
11"POT-Creation-Date: 2015-12-11 21:39-0600\n"11"POT-Creation-Date: 2016-02-29 04:21+0530\n"
12"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"12"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
13"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"13"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
14"Language-Team: LANGUAGE <LL@li.org>\n"14"Language-Team: LANGUAGE <LL@li.org>\n"
@@ -104,35 +104,35 @@
104"to obtain your own Open Weather Map API key."104"to obtain your own Open Weather Map API key."
105msgstr ""105msgstr ""
106106
107#: ../app/ui/AddLocationPage.qml:29107#: ../app/ui/AddLocationPage.qml:38
108msgid "Select a city"108msgid "Select a city"
109msgstr ""109msgstr ""
110110
111#: ../app/ui/AddLocationPage.qml:47 ../app/ui/AddLocationPage.qml:69111#: ../app/ui/AddLocationPage.qml:49
112msgid "City"
113msgstr ""
114
115#: ../app/ui/AddLocationPage.qml:65
112msgid "Back"116msgid "Back"
113msgstr ""117msgstr ""
114118
115#: ../app/ui/AddLocationPage.qml:54119#: ../app/ui/AddLocationPage.qml:108
116msgid "City"
117msgstr ""
118
119#: ../app/ui/AddLocationPage.qml:113
120msgid "Search city"120msgid "Search city"
121msgstr ""121msgstr ""
122122
123#: ../app/ui/AddLocationPage.qml:299123#: ../app/ui/AddLocationPage.qml:281
124msgid "No city found"124msgid "No city found"
125msgstr ""125msgstr ""
126126
127#: ../app/ui/AddLocationPage.qml:312127#: ../app/ui/AddLocationPage.qml:294
128msgid "Couldn't load weather data, please try later again!"128msgid "Couldn't load weather data, please try later again!"
129msgstr ""129msgstr ""
130130
131#: ../app/ui/AddLocationPage.qml:322131#: ../app/ui/AddLocationPage.qml:304
132msgid "Location already added."132msgid "Location already added."
133msgstr ""133msgstr ""
134134
135#: ../app/ui/AddLocationPage.qml:325135#: ../app/ui/AddLocationPage.qml:307
136msgid "OK"136msgid "OK"
137msgstr ""137msgstr ""
138138
@@ -144,82 +144,82 @@
144msgid "Current Location"144msgid "Current Location"
145msgstr ""145msgstr ""
146146
147#: ../app/ui/SettingsPage.qml:24147#: ../app/ui/SettingsPage.qml:27
148msgid "Settings"148msgid "Settings"
149msgstr ""149msgstr ""
150150
151#: ../app/ui/SettingsPage.qml:33 ../app/ui/settings/UnitsPage.qml:24151#: ../app/ui/SettingsPage.qml:44 ../app/ui/settings/UnitsPage.qml:29
152msgid "Units"152msgid "Units"
153msgstr ""153msgstr ""
154154
155#: ../app/ui/SettingsPage.qml:38 ../app/ui/settings/DataProviderPage.qml:25155#: ../app/ui/SettingsPage.qml:52 ../app/ui/settings/DataProviderPage.qml:28
156msgid "Data Provider"156msgid "Data Provider"
157msgstr ""157msgstr ""
158158
159#: ../app/ui/SettingsPage.qml:43 ../app/ui/settings/RefreshIntervalPage.qml:24159#: ../app/ui/SettingsPage.qml:60 ../app/ui/settings/RefreshIntervalPage.qml:27
160msgid "Refresh Interval"160msgid "Refresh Interval"
161msgstr ""161msgstr ""
162162
163#: ../app/ui/SettingsPage.qml:48 ../app/ui/settings/LocationPage.qml:24163#: ../app/ui/SettingsPage.qml:68 ../app/ui/settings/LocationPage.qml:26
164msgid "Location"164msgid "Location"
165msgstr ""165msgstr ""
166166
167#: ../app/ui/settings/DataProviderPage.qml:37167#: ../app/ui/settings/DataProviderPage.qml:42
168msgid "Provider"168msgid "Provider"
169msgstr ""169msgstr ""
170170
171#: ../app/ui/settings/LocationPage.qml:32171#: ../app/ui/settings/LocationPage.qml:34
172msgid "Detect current location"172msgid "Detect current location"
173msgstr ""173msgstr ""
174174
175#: ../app/ui/settings/RefreshIntervalPage.qml:30175#: ../app/ui/settings/RefreshIntervalPage.qml:34
176#: ../app/ui/settings/RefreshIntervalPage.qml:31176#: ../app/ui/settings/RefreshIntervalPage.qml:35
177#: ../app/ui/settings/RefreshIntervalPage.qml:32177#: ../app/ui/settings/RefreshIntervalPage.qml:36
178#: ../app/ui/settings/RefreshIntervalPage.qml:33178#: ../app/ui/settings/RefreshIntervalPage.qml:37
179#: ../app/ui/settings/RefreshIntervalPage.qml:43179#: ../app/ui/settings/RefreshIntervalPage.qml:48
180#, qt-format180#, qt-format
181msgid "%1 minute"181msgid "%1 minute"
182msgid_plural "%1 minutes"182msgid_plural "%1 minutes"
183msgstr[0] ""183msgstr[0] ""
184msgstr[1] ""184msgstr[1] ""
185185
186#: ../app/ui/settings/RefreshIntervalPage.qml:42186#: ../app/ui/settings/RefreshIntervalPage.qml:47
187msgid "Interval"187msgid "Interval"
188msgstr ""188msgstr ""
189189
190#. TRANSLATORS: The strings are standard measurement units190#. TRANSLATORS: The strings are standard measurement units
191#. of temperature in Celcius and are shown in the settings page.191#. of temperature in Celcius and are shown in the settings page.
192#. Only the abbreviated form of Celcius should be used.192#. Only the abbreviated form of Celcius should be used.
193#: ../app/ui/settings/UnitsPage.qml:42 ../app/ui/settings/UnitsPage.qml:78193#: ../app/ui/settings/UnitsPage.qml:47 ../app/ui/settings/UnitsPage.qml:83
194msgid "°C"194msgid "°C"
195msgstr ""195msgstr ""
196196
197#. TRANSLATORS: The strings are standard measurement units197#. TRANSLATORS: The strings are standard measurement units
198#. of temperature in Fahrenheit and are shown in the settings page.198#. of temperature in Fahrenheit and are shown in the settings page.
199#. Only the abbreviated form of Fahrenheit should be used.199#. Only the abbreviated form of Fahrenheit should be used.
200#: ../app/ui/settings/UnitsPage.qml:47 ../app/ui/settings/UnitsPage.qml:79200#: ../app/ui/settings/UnitsPage.qml:52 ../app/ui/settings/UnitsPage.qml:84
201msgid "°F"201msgid "°F"
202msgstr ""202msgstr ""
203203
204#. TRANSLATORS: The strings are standard measurement units204#. TRANSLATORS: The strings are standard measurement units
205#. of wind speed in kilometers per hour and are shown in the settings page.205#. of wind speed in kilometers per hour and are shown in the settings page.
206#. Only the abbreviated form of kilometers per hour should be used.206#. Only the abbreviated form of kilometers per hour should be used.
207#: ../app/ui/settings/UnitsPage.qml:58 ../app/ui/settings/UnitsPage.qml:99207#: ../app/ui/settings/UnitsPage.qml:63 ../app/ui/settings/UnitsPage.qml:104
208msgid "kph"208msgid "kph"
209msgstr ""209msgstr ""
210210
211#. TRANSLATORS: The strings are standard measurement units211#. TRANSLATORS: The strings are standard measurement units
212#. of wind speed in miles per hour and are shown in the settings page.212#. of wind speed in miles per hour and are shown in the settings page.
213#. Only the abbreviated form of miles per hour should be used.213#. Only the abbreviated form of miles per hour should be used.
214#: ../app/ui/settings/UnitsPage.qml:63 ../app/ui/settings/UnitsPage.qml:100214#: ../app/ui/settings/UnitsPage.qml:68 ../app/ui/settings/UnitsPage.qml:105
215msgid "mph"215msgid "mph"
216msgstr ""216msgstr ""
217217
218#: ../app/ui/settings/UnitsPage.qml:77218#: ../app/ui/settings/UnitsPage.qml:82
219msgid "Temperature"219msgid "Temperature"
220msgstr ""220msgstr ""
221221
222#: ../app/ui/settings/UnitsPage.qml:98222#: ../app/ui/settings/UnitsPage.qml:103
223msgid "Wind Speed"223msgid "Wind Speed"
224msgstr ""224msgstr ""
225225

Subscribers

People subscribed via source and target branches