aboutsummaryrefslogtreecommitdiffstats
path: root/mobile-widgets
diff options
context:
space:
mode:
Diffstat (limited to 'mobile-widgets')
-rw-r--r--mobile-widgets/qmlmanager.cpp7
-rw-r--r--mobile-widgets/qmlmanager.h1
2 files changed, 7 insertions, 1 deletions
diff --git a/mobile-widgets/qmlmanager.cpp b/mobile-widgets/qmlmanager.cpp
index 9aae67f33..7780a3ff6 100644
--- a/mobile-widgets/qmlmanager.cpp
+++ b/mobile-widgets/qmlmanager.cpp
@@ -412,6 +412,12 @@ void QMLManager::loadDivesWithValidCredentials()
alreadySaving = false;
return;
}
+ consumeFinishedLoad(currentDiveTimestamp);
+ setLoadFromCloud(true);
+}
+
+void QMLManager::consumeFinishedLoad(timestamp_t currentDiveTimestamp)
+{
prefs.unit_system = informational_prefs.unit_system;
if (informational_prefs.unit_system == IMPERIAL)
informational_prefs.units = IMPERIAL_units;
@@ -426,7 +432,6 @@ void QMLManager::loadDivesWithValidCredentials()
appendTextToLog(QStringLiteral("%1 dives loaded").arg(dive_table.nr));
if (dive_table.nr == 0)
setStartPageText(tr("Cloud storage open successfully. No dives in dive list."));
- setLoadFromCloud(true);
alreadySaving = false;
}
diff --git a/mobile-widgets/qmlmanager.h b/mobile-widgets/qmlmanager.h
index 860e3c3ad..2bd2ee240 100644
--- a/mobile-widgets/qmlmanager.h
+++ b/mobile-widgets/qmlmanager.h
@@ -133,6 +133,7 @@ public slots:
QString getCurrentPosition();
QString getVersion() const;
void deleteGpsFix(quint64 when);
+ void consumeFinishedLoad(timestamp_t currentDiveTimestamp);
void refreshDiveList();
void screenChanged(QScreen *screen);
qreal lastDevicePixelRatio();