mirror of
https://github.com/swift-project/pilotclient.git
synced 2026-04-02 23:25:53 +08:00
refs #198, enabled settings context to read / write JSON settings from/to file
This commit is contained in:
@@ -8,7 +8,7 @@
|
||||
|
||||
#include "context_settings.h"
|
||||
#include "dbus_server.h"
|
||||
#include "coreruntime.h"
|
||||
#include "context_runtime.h"
|
||||
|
||||
#include "blackmisc/setnetwork.h"
|
||||
#include "blackmisc/statusmessagelist.h"
|
||||
@@ -61,11 +61,23 @@ namespace BlackCore
|
||||
*/
|
||||
virtual BlackMisc::CStatusMessageList value(const QString &path, const QString &command, QDBusVariant value, int unifiedBlackMetaType);
|
||||
|
||||
//! \brief read settings
|
||||
virtual BlackMisc::CStatusMessage read() override;
|
||||
|
||||
//! \copydoc IContextSettings::write
|
||||
virtual BlackMisc::CStatusMessage write() const override;
|
||||
|
||||
//! Settings file name
|
||||
virtual QString getSettingsFileName() const override { return BlackMisc::Settings::CSettingUtilities::getSettingsFile(); }
|
||||
|
||||
//! JSON represenation
|
||||
virtual QString getSettingsAsJsonString() const override;
|
||||
|
||||
private:
|
||||
friend class CRuntime;
|
||||
BlackMisc::Settings::CSettingsNetwork m_settingsNetwork;
|
||||
BlackMisc::Hardware::CKeyboardKeyList m_hotkeys;
|
||||
QJsonDocument toJsonDocument() const;
|
||||
};
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user