aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGravatar Dirk Hohndel <dirk@hohndel.org>2016-02-10 17:31:52 -0800
committerGravatar Dirk Hohndel <dirk@hohndel.org>2016-02-10 21:00:21 -0800
commitb7e353b7f66f3a9eba923cd07a26dced2e512053 (patch)
tree21a72a4147a9a4992c68dfe1f18718f92505067e
parent6829d1008666926d935f62236fce7f680c41a90f (diff)
downloadsubsurface-b7e353b7f66f3a9eba923cd07a26dced2e512053.tar.gz
QML UI: more accurate messages on the start page
Now the text shown better reflects what's going on, especially when the credentials are invalid. Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
-rw-r--r--qt-mobile/qmlmanager.cpp10
1 files changed, 5 insertions, 5 deletions
diff --git a/qt-mobile/qmlmanager.cpp b/qt-mobile/qmlmanager.cpp
index ff1c748a1..5aa10edfe 100644
--- a/qt-mobile/qmlmanager.cpp
+++ b/qt-mobile/qmlmanager.cpp
@@ -49,7 +49,7 @@ QMLManager::QMLManager() : m_locationServiceEnabled(false),
appendTextToLog(QStringLiteral("build with Qt Version %1, runtime from Qt Version %2").arg(QT_VERSION_STR).arg(qVersion()));
qDebug() << "Starting" << getUserAgent();
qDebug() << QStringLiteral("build with Qt Version %1, runtime from Qt Version %2").arg(QT_VERSION_STR).arg(qVersion());
- m_startPageText = tr("Searching for dive data");
+ setStartPageText(tr("Starting..."));
// create location manager service
locationProvider = new GpsLocation(&appendTextToLogStandalone, this);
set_git_update_cb(&gitProgressCB);
@@ -93,13 +93,13 @@ void QMLManager::finishSetup()
setSaveCloudPassword(prefs.save_password_local);
// if the cloud credentials are valid, we should get the GPS Webservice ID as well
QString url;
- if (!same_string(prefs.cloud_storage_email, "") &&
- !same_string(prefs.cloud_storage_password, "") &&
+ if (!cloudUserName().isEmpty() &&
+ !cloudPassword().isEmpty() &&
getCloudURL(url) == 0) {
openLocalThenRemote(url);
} else {
- appendTextToLog(QStringLiteral("no cloud credentials, tell user no dives found"));
- setStartPageText(tr("No recorded dives found. You can download your dives to this device from the Subsurface cloud storage service, from your dive computer, or add them manually."));
+ appendTextToLog(QStringLiteral("no cloud credentials"));
+ setStartPageText(tr("Please enter valid cloud credentials."));
}
setDistanceThreshold(prefs.distance_threshold);
setTimeThreshold(prefs.time_threshold / 60);