mirror of
https://github.com/subsurface/subsurface.git
synced 2025-02-19 22:16:15 +00:00
Remember in settings if we ever synced with the cloud
Otherwise, if the device is offline we would not be able to store changes in the local cache, completely defeating the purpose. Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
This commit is contained in:
parent
a3af5331ea
commit
60d5463311
1 changed files with 5 additions and 0 deletions
|
@ -54,6 +54,9 @@ QMLManager::QMLManager() :
|
||||||
// create location manager service
|
// create location manager service
|
||||||
locationProvider = new GpsLocation(&appendTextToLogStandalone, this);
|
locationProvider = new GpsLocation(&appendTextToLogStandalone, this);
|
||||||
set_git_update_cb(&gitProgressCB);
|
set_git_update_cb(&gitProgressCB);
|
||||||
|
QSettings s;
|
||||||
|
if (s.contains("setLoadFromCloud") && s.value("setLoadFromCloud").toInt() == 1)
|
||||||
|
setLoadFromCloud(true);
|
||||||
}
|
}
|
||||||
|
|
||||||
void QMLManager::finishSetup()
|
void QMLManager::finishSetup()
|
||||||
|
@ -646,6 +649,8 @@ bool QMLManager::loadFromCloud() const
|
||||||
|
|
||||||
void QMLManager::setLoadFromCloud(bool done)
|
void QMLManager::setLoadFromCloud(bool done)
|
||||||
{
|
{
|
||||||
|
QSettings s;
|
||||||
|
s.setValue("loadFromCloud", 1);
|
||||||
m_loadFromCloud = done;
|
m_loadFromCloud = done;
|
||||||
emit loadFromCloudChanged();
|
emit loadFromCloudChanged();
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Reference in a new issue