mirror of
https://github.com/subsurface/subsurface.git
synced 2025-02-19 22:16:15 +00:00
qPref: reduce recompiles with every commit
Including ssrf-version.h in an include file that a lot of files depend on caused a ton of unnecessary recompiles with every commit. This should reduce that problem. Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
This commit is contained in:
parent
d9588ec5df
commit
4461b47965
2 changed files with 13 additions and 3 deletions
|
@ -15,6 +15,7 @@
|
|||
#include "qPrefTechnicalDetails.h"
|
||||
#include "qPrefUnit.h"
|
||||
#include "qPrefUpdateManager.h"
|
||||
#include "ssrf-version.h"
|
||||
|
||||
#include <QtQml>
|
||||
#include <QQmlContext>
|
||||
|
@ -29,6 +30,16 @@ qPref *qPref::instance()
|
|||
return self;
|
||||
}
|
||||
|
||||
const QString qPref::canonical_version()
|
||||
{
|
||||
return QString(CANONICAL_VERSION_STRING);
|
||||
}
|
||||
|
||||
const QString qPref::mobile_version()
|
||||
{
|
||||
return QString(MOBILE_VERSION_STRING);
|
||||
}
|
||||
|
||||
void qPref::loadSync(bool doSync)
|
||||
{
|
||||
if (!doSync)
|
||||
|
|
|
@ -2,7 +2,6 @@
|
|||
#ifndef QPREF_H
|
||||
#define QPREF_H
|
||||
#include "core/pref.h"
|
||||
#include "ssrf-version.h"
|
||||
|
||||
#include <QObject>
|
||||
#include <QQmlEngine>
|
||||
|
@ -24,8 +23,8 @@ public:
|
|||
void registerQML(QQmlEngine *engine);
|
||||
|
||||
public:
|
||||
static const QString canonical_version() { return QString(CANONICAL_VERSION_STRING); }
|
||||
static const QString mobile_version() { return QString(MOBILE_VERSION_STRING); }
|
||||
static const QString canonical_version();
|
||||
static const QString mobile_version();
|
||||
|
||||
private:
|
||||
static void loadSync(bool doSync);
|
||||
|
|
Loading…
Add table
Reference in a new issue