mobile/dive-list: add indicator that dive list is being processed

This should deal with the rather confusing 'No dive in dive list' shown
while loading and processing the dive list.

Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
This commit is contained in:
Dirk Hohndel 2020-03-29 12:53:01 -07:00
parent 4cd7767bec
commit 2e07e9345f
3 changed files with 24 additions and 2 deletions

View file

@ -346,11 +346,15 @@ Kirigami.ScrollablePage {
}
Controls.Label {
property bool showProcessingText: manager.diveListProcessing
anchors.fill: parent
horizontalAlignment: Text.AlignHCenter
verticalAlignment: Text.AlignVCenter
text: diveListModel ? qsTr("No dives in dive list") : qsTr("Please wait, updating the dive list")
text: diveListModel && !showProcessingText ? qsTr("No dives in dive list") : qsTr("Please wait, updating the dive list")
visible: diveListView.visible && diveListView.count === 0
onShowProcessingTextChanged: {
manager.appendTextToLog("============diveListProcessing is " + showProcessingText)
}
}
Rectangle {