Merge lp:~neokore/ubuntu-weather-app/ActivityIndicatorLoading into lp:ubuntu-weather-app/obsolete.trunk

Proposed by Raúl Yeguas
Status: Merged
Approved by: Martin Borho
Approved revision: 20
Merged at revision: 19
Proposed branch: lp:~neokore/ubuntu-weather-app/ActivityIndicatorLoading
Merge into: lp:ubuntu-weather-app/obsolete.trunk
Diff against target: 51 lines (+11/-5)
1 file modified
ubuntu-weather-app.qml (+11/-5)
To merge this branch: bzr merge lp:~neokore/ubuntu-weather-app/ActivityIndicatorLoading
Reviewer Review Type Date Requested Status
Martin Borho Approve
Ubuntu Phone Apps Jenkins Bot continuous-integration Approve
Review via email: mp+161897@code.launchpad.net

Commit message

Added an ActivityIndicator to appear while loading data or adding a new location

Description of the change

Added an ActivityIndicator to appear while loading data or adding a new location

To post a comment you must log in.
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
Martin Borho (martin-borho) wrote :

Fine!

review: Approve

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
=== modified file 'ubuntu-weather-app.qml'
--- ubuntu-weather-app.qml 2013-05-01 17:10:19 +0000
+++ ubuntu-weather-app.qml 2013-05-01 17:43:30 +0000
@@ -55,8 +55,9 @@
55 tabsString += "Components.LocationTabEmpty { }"55 tabsString += "Components.LocationTabEmpty { }"
56 }56 }
57 tabsString += "}"; // END Tabs componen57 tabsString += "}"; // END Tabs componen
58 if(loading != null)58 if(bigLoading !== null)
59 loading.destroy();59 bigLoading.destroy();
60 loading.running = false;
60 tabsObject = Qt.createQmlObject(tabsString, tabPage, "tabs")61 tabsObject = Qt.createQmlObject(tabsString, tabPage, "tabs")
61 if(focusToLast)62 if(focusToLast)
62 tabsObject.selectedTabIndex = locLength -1;63 tabsObject.selectedTabIndex = locLength -1;
@@ -71,7 +72,8 @@
71 locationDataWorker.sendMessage({72 locationDataWorker.sendMessage({
72 action: "newLocationData",73 action: "newLocationData",
73 params: {location:locationObj, units:"metric"}74 params: {location:locationObj, units:"metric"}
74 })75 });
76 loading.running = true;
75 }77 }
7678
77 function onNewLocationDataSuccess(resp) {79 function onNewLocationDataSuccess(resp) {
@@ -80,6 +82,8 @@
80 }82 }
8183
82 function refreshData() {84 function refreshData() {
85 if(bigLoading === null)
86 loading.running = true;
83 storage.getLocations(function(locations) {87 storage.getLocations(function(locations) {
84 locationDataWorker.sendMessage({88 locationDataWorker.sendMessage({
85 action: "updateData",89 action: "updateData",
@@ -104,12 +108,14 @@
104 Page {108 Page {
105 id: tabPage109 id: tabPage
106 title: "Simple page"110 title: "Simple page"
107111 ActivityIndicator{id:loading; running: false; z: 1; anchors{top: parent.top; topMargin: units.gu(0.5); right: parent.right; rightMargin: units.gu(1)}}
108 Tabs {112 Tabs {
109 id: tabs113 id: tabs
110 objectName: "Tabs"114 objectName: "Tabs"
111 anchors.fill: parent115 anchors.fill: parent
112 Tab {Components.LoadingComponent{id:loading; anchors.fill: tabs}}116 Tab {
117 Components.LoadingComponent{id:bigLoading; anchors.fill: parent; z: 2;}
118 }
113 }119 }
114 }120 }
115}121}

Subscribers

People subscribed via source and target branches