mirror of
https://github.com/subsurface/subsurface.git
synced 2025-01-31 22:03:23 +00:00
0825f644e0
Prepare qPref.* to run load/sync Make variables and methods static to give easy access Make getter inline to give faster access Signed-off-by: Jan Iversen <jani@apache.org>:wq
34 lines
1,000 B
C++
34 lines
1,000 B
C++
// SPDX-License-Identifier: GPL-2.0
|
|
#include "qPref.h"
|
|
#include "qPrefPrivate.h"
|
|
|
|
qPref::qPref(QObject *parent) : QObject(parent)
|
|
{
|
|
}
|
|
qPref *qPref::instance()
|
|
{
|
|
static qPref *self = new qPref;
|
|
return self;
|
|
}
|
|
|
|
void qPref::loadSync(bool doSync)
|
|
{
|
|
if (!doSync)
|
|
uiLanguage(NULL);
|
|
|
|
qPrefAnimations::instance()->loadSync(doSync);
|
|
qPrefCloudStorage::instance()->loadSync(doSync);
|
|
qPrefDisplay::instance()->loadSync(doSync);
|
|
qPrefDiveComputer::instance()->loadSync(doSync);
|
|
qPrefDivePlanner::instance()->loadSync(doSync);
|
|
// qPrefFaceook does not use disk.
|
|
qPrefGeneral::instance()->loadSync(doSync);
|
|
qPrefGeocoding::instance()->loadSync(doSync);
|
|
qPrefLanguage::instance()->loadSync(doSync);
|
|
qPrefLocationService::instance()->loadSync(doSync);
|
|
qPrefPartialPressureGas::instance()->loadSync(doSync);
|
|
qPrefProxy::instance()->loadSync(doSync);
|
|
qPrefTechnicalDetails::instance()->loadSync(doSync);
|
|
qPrefUnits::instance()->loadSync(doSync);
|
|
qPrefUpdateManager::instance()->loadSync(doSync);
|
|
}
|