diff options
author | Marvin Borner | 2020-04-16 14:43:01 +0200 |
---|---|---|
committer | Marvin Borner | 2020-04-16 14:43:01 +0200 |
commit | a3886dac1392304e1259e4a85f1b9fbcd1598894 (patch) | |
tree | 04cc851a7994280a6721a93368c59d2fffa112ff /qml | |
parent | ab3c37cf59b14c517f3cfb374ddd0e8b108ba392 (diff) |
v1.2.0: Added loading animation
Diffstat (limited to 'qml')
-rw-r--r-- | qml/pages/LeaderBoard.qml | 13 |
1 files changed, 12 insertions, 1 deletions
diff --git a/qml/pages/LeaderBoard.qml b/qml/pages/LeaderBoard.qml index 39ca742..80b2943 100644 --- a/qml/pages/LeaderBoard.qml +++ b/qml/pages/LeaderBoard.qml @@ -40,12 +40,15 @@ Page { if (xhr.readyState === 4 && xhr.status === 200) { list.model = JSON.parse(xhr.responseText); internet.visible = false; + loading.running = false; } else if (xhr.readyState === 4) { - list.model = [] internet.visible = true; + loading.running = false; } } xhr.send() + list.model = []; + loading.running = true; } menu: ContextMenu { @@ -86,6 +89,14 @@ Page { visible: false } + BusyIndicator { + id: loading + size: BusyIndicatorSize.Large + anchors.horizontalCenter: parent.horizontalCenter + running: false + visible: running + } + SilicaListView { id: list clip: true |