ubuntu-touch-coreapps-reviewers team mailing list archive
-
ubuntu-touch-coreapps-reviewers team
-
Mailing list archive
-
Message #02644
[Merge] lp:~vthompson/ubuntu-weather-app/reboot-anchor-location-pages into lp:ubuntu-weather-app/reboot
Victor Thompson has proposed merging lp:~vthompson/ubuntu-weather-app/reboot-anchor-location-pages into lp:ubuntu-weather-app/reboot.
Commit message:
* Set contentHeight declaratively.
Requested reviews:
Ubuntu Weather Developers (ubuntu-weather-dev)
For more details, see:
https://code.launchpad.net/~vthompson/ubuntu-weather-app/reboot-anchor-location-pages/+merge/261316
* Set contentHeight declaratively.
Currently, if you have multiple locations and one is on the other side of the world, you will likely get a different number of days in the forecast--this causes the contentHeight to be incorrect. If the first location has 4 days of forecast, but the second only has 3, then in some cases the user will experience the first location being "clipped" to only see the first 3 days. Additionally, the 2nd location would see excessive whitespace at the end of the view.
--
Your team Ubuntu Weather Developers is requested to review the proposed merge of lp:~vthompson/ubuntu-weather-app/reboot-anchor-location-pages into lp:ubuntu-weather-app/reboot.
=== modified file 'app/ui/HomePage.qml'
--- app/ui/HomePage.qml 2015-05-29 02:38:23 +0000
+++ app/ui/HomePage.qml 2015-06-06 17:39:13 +0000
@@ -95,6 +95,7 @@
id: locationFlickable
width: parent.width
height: parent.height
+ contentHeight: locationPages.currentItem.childrenRect.height + units.gu(3)
contentWidth: parent.width
Behavior on contentHeight {
=== modified file 'app/ui/LocationPane.qml'
--- app/ui/LocationPane.qml 2015-05-09 03:23:34 +0000
+++ app/ui/LocationPane.qml 2015-06-06 17:39:13 +0000
@@ -40,9 +40,6 @@
height: childrenRect.height
anchors.fill: parent.fill
- // FIXME: not sure where the 3GU comes from, PullToRefresh or something in HomePage?
- onHeightChanged: locationFlickable.contentHeight = locationItem.height + units.gu(3)
-
function emptyIfUndefined(variable, append) {
if (append === undefined) {
append = ""
Follow ups