Merge lp:~vthompson/ubuntu-weather-app/reboot-current-location-ui-changes into lp:ubuntu-weather-app

Proposed by Victor Thompson
Status: Merged
Approved by: Andrew Hayzen
Approved revision: 51
Merged at revision: 49
Proposed branch: lp:~vthompson/ubuntu-weather-app/reboot-current-location-ui-changes
Merge into: lp:ubuntu-weather-app
Prerequisite: lp:~vthompson/ubuntu-weather-app/reboot-manage-current-location
Diff against target: 81 lines (+30/-6)
2 files modified
app/ui/LocationsPage.qml (+25/-5)
po/com.ubuntu.weather.pot (+5/-1)
To merge this branch: bzr merge lp:~vthompson/ubuntu-weather-app/reboot-current-location-ui-changes
Reviewer Review Type Date Requested Status
Andrew Hayzen Approve
Ubuntu Phone Apps Jenkins Bot continuous-integration Approve
Review via email: mp+261299@code.launchpad.net

Commit message

Update LocationsPage layout to better match the design spec.

Description of the change

Update LocationsPage layout to better match the design spec.

To post a comment you must log in.
50. By Victor Thompson

Merge of prereq branch and resolve conflict.

51. By Victor Thompson

Make secondary label lighter in color

Revision history for this message
Ubuntu Phone Apps Jenkins Bot (ubuntu-phone-apps-jenkins-bot) wrote :
review: Approve (continuous-integration)
Revision history for this message
Andrew Hayzen (ahayzen) wrote :

LGTM, as discussed we'll attempt to make the 'current' location non-removable/reorderable/multiselectable either by moving into another view/component or within the view itself. This will be investigated after moving to the new listitems.

review: Approve

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'app/ui/LocationsPage.qml'
2--- app/ui/LocationsPage.qml 2015-06-05 23:16:06 +0000
3+++ app/ui/LocationsPage.qml 2015-06-05 23:16:07 +0000
4@@ -87,21 +87,38 @@
5 rightMargin: units.gu(2)
6 }
7
8- Label {
9- id: locationName
10+ Column {
11 anchors {
12 left: parent.left
13 right: weatherImage.visible ? weatherImage.left : parent.right
14 rightMargin: units.gu(1)
15 verticalCenter: parent.verticalCenter
16 }
17- elide: Text.ElideRight
18- text: name
19+
20+ Label {
21+ id: locationName
22+ elide: Text.ElideRight
23+ fontSize: "medium"
24+ text: index != 0 ? name : i18n.tr("Current Location")
25+ }
26+ Label {
27+ id: locationName2
28+ color: UbuntuColors.lightGrey
29+ elide: Text.ElideRight
30+ fontSize: "small"
31+ font.weight: Font.Light
32+ text: index != 0 ? (adminName1 == name ? countryName : adminName1)
33+ : name + ", " + (adminName1 == name ? countryName : adminName1)
34+ }
35 }
36
37 Icon {
38 id: weatherImage
39- anchors.centerIn: parent
40+ anchors {
41+ right: parent.right
42+ rightMargin: units.gu(12)
43+ verticalCenter: parent.verticalCenter
44+ }
45 name: icon
46 height: units.gu(3)
47 width: units.gu(3)
48@@ -143,6 +160,9 @@
49 data = weatherApp.locationsList[i];
50 loc = {
51 "name": data.location.name,
52+ "adminName1": data.location.adminName1,
53+ "areaLabel": data.location.areaLabel,
54+ "countryName": data.location.countryName,
55 "temp": Math.round(data.data[0].current[tempUnits].temp).toString(),
56 "icon": iconMap[data.data[0].current.icon]
57 }
58
59=== modified file 'po/com.ubuntu.weather.pot'
60--- po/com.ubuntu.weather.pot 2015-06-03 17:49:50 +0000
61+++ po/com.ubuntu.weather.pot 2015-06-05 23:16:07 +0000
62@@ -8,7 +8,7 @@
63 msgstr ""
64 "Project-Id-Version: ubuntu-weather-app\n"
65 "Report-Msgid-Bugs-To: \n"
66-"POT-Creation-Date: 2015-05-29 05:21+0100\n"
67+"POT-Creation-Date: 2015-06-05 18:04-0500\n"
68 "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
69 "Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
70 "Language-Team: LANGUAGE <LL@li.org>\n"
71@@ -102,6 +102,10 @@
72 msgid "Locations"
73 msgstr ""
74
75+#: ../app/ui/LocationsPage.qml:102
76+msgid "Current Location"
77+msgstr ""
78+
79 #: ../app/ui/SettingsPage.qml:24
80 msgid "Settings"
81 msgstr ""

Subscribers

People subscribed via source and target branches

to all changes: