From bd64cda6726e088ebc860c3fc3ee220ed00121bd Mon Sep 17 00:00:00 2001 From: Andrew Date: Mon, 25 Feb 2013 16:36:27 -0600 Subject: Added instance setting overrides. --- plugins/stdinstance/stdinstance.cpp | 3 +++ plugins/stdinstance/stdinstance.h | 4 ++-- 2 files changed, 5 insertions(+), 2 deletions(-) (limited to 'plugins') diff --git a/plugins/stdinstance/stdinstance.cpp b/plugins/stdinstance/stdinstance.cpp index 12d86bbc..217514a3 100644 --- a/plugins/stdinstance/stdinstance.cpp +++ b/plugins/stdinstance/stdinstance.cpp @@ -17,11 +17,14 @@ #include +#include + #include StdInstance::StdInstance(const QString &rootDir, QObject *parent) : Instance(rootDir, parent) { + settings().registerSetting(new Setting("lastVersionUpdate", 0)); } diff --git a/plugins/stdinstance/stdinstance.h b/plugins/stdinstance/stdinstance.h index d812a9b0..d657d9aa 100644 --- a/plugins/stdinstance/stdinstance.h +++ b/plugins/stdinstance/stdinstance.h @@ -29,8 +29,8 @@ public: virtual void updateCurrentVersion(bool keepCurrent); ////// TIMESTAMPS ////// - virtual qint64 lastVersionUpdate() { return getField("lastVersionUpdate", 0).value(); } - virtual void setLastVersionUpdate(qint64 val) { setField("lastVersionUpdate", val); } + virtual qint64 lastVersionUpdate() { return settings().get("lastVersionUpdate").value(); } + virtual void setLastVersionUpdate(qint64 val) { settings().set("lastVersionUpdate", val); } }; #endif // STDINSTANCE_H -- cgit v1.2.3