From 4461b479655a40d46b5f900ca227d30310812891 Mon Sep 17 00:00:00 2001 From: Dirk Hohndel Date: Wed, 24 Oct 2018 22:28:26 +0100 Subject: 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 --- core/settings/qPref.cpp | 11 +++++++++++ core/settings/qPref.h | 5 ++--- 2 files changed, 13 insertions(+), 3 deletions(-) diff --git a/core/settings/qPref.cpp b/core/settings/qPref.cpp index 2d3c53a40..b1c7217b2 100644 --- a/core/settings/qPref.cpp +++ b/core/settings/qPref.cpp @@ -15,6 +15,7 @@ #include "qPrefTechnicalDetails.h" #include "qPrefUnit.h" #include "qPrefUpdateManager.h" +#include "ssrf-version.h" #include #include @@ -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) diff --git a/core/settings/qPref.h b/core/settings/qPref.h index e59a778e5..2c95a1500 100644 --- a/core/settings/qPref.h +++ b/core/settings/qPref.h @@ -2,7 +2,6 @@ #ifndef QPREF_H #define QPREF_H #include "core/pref.h" -#include "ssrf-version.h" #include #include @@ -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); -- cgit v1.2.3-70-g09d2