QML UI: with a local default file setup, open that at start

And set no cloud mode.

Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
This commit is contained in:
Dirk Hohndel 2016-04-22 07:13:14 -07:00
parent ec136defa8
commit bdf8bc676b

View file

@ -179,9 +179,15 @@ void QMLManager::finishSetup()
// but we need to make sure we stay the only ones accessing git storage
alreadySaving = true;
openLocalThenRemote(url);
} else if (!same_string(existing_filename, "")) {
setCredentialStatus(NOCLOUD);
appendTextToLog(tr("working in no-cloud mode"));
parse_file(existing_filename);
consumeFinishedLoad(0);
qDebug() << "working in no-cloud mode, finished loading" << dive_table.nr << "dives";
} else {
setCredentialStatus(INCOMPLETE);
appendTextToLog(QStringLiteral("no cloud credentials"));
appendTextToLog(tr("no cloud credentials"));
setStartPageText(RED_FONT + tr("Please enter valid cloud credentials.") + END_FONT);
}
setDistanceThreshold(prefs.distance_threshold);