diff options
author | Simon Rettberg | 2019-05-30 01:14:31 +0200 |
---|---|---|
committer | Simon Rettberg | 2019-05-30 01:14:31 +0200 |
commit | df168536ca1aaf0b147e67ef214bf35dfd34e441 (patch) | |
tree | 7ffcd8e12318c57440e733728de71cf556705c12 /src/config.h | |
parent | Add 'disable screensaver' checkbox (diff) | |
download | vmchooser2-df168536ca1aaf0b147e67ef214bf35dfd34e441.tar.gz vmchooser2-df168536ca1aaf0b147e67ef214bf35dfd34e441.tar.xz vmchooser2-df168536ca1aaf0b147e67ef214bf35dfd34e441.zip |
Cleanup, and rewrite cmdline + settings handling
Command line parsing now uses QCommandLineXXX classes
Old unused options have been removed, like the "pools" feature
Closes #3599
Diffstat (limited to 'src/config.h')
-rw-r--r-- | src/config.h | 46 |
1 files changed, 46 insertions, 0 deletions
diff --git a/src/config.h b/src/config.h new file mode 100644 index 0000000..872836d --- /dev/null +++ b/src/config.h @@ -0,0 +1,46 @@ +#ifndef CONFIG_H +#define CONFIG_H + +#include <QCoreApplication> +#include <QList> + +struct ConfigOption; + +class Config +{ +public: + static const ConfigOption* const ALLOW_VM_EDIT; + static const ConfigOption* const AUTOQUIT; + static const ConfigOption* const BASEDIR; + static const ConfigOption* const CONFIG; + static const ConfigOption* const DEBUG; + static const ConfigOption* const DEFAULT_SESSION; + static const ConfigOption* const EXAM_MODE; + static const ConfigOption* const FULLSCREEN; + static const ConfigOption* const INSECURE; + static const ConfigOption* const LOCATIONS; + static const ConfigOption* const PVS; + static const ConfigOption* const PVS_CHECKED; + static const ConfigOption* const RUNSCRIPT; + static const ConfigOption* const WINDOW_SIZE; + static const ConfigOption* const DEFAULT_TAB; + static const ConfigOption* const THEME; + static const ConfigOption* const URL_BASE; + static const ConfigOption* const URL_LIST; + static const ConfigOption* const URL_NEWS; + static const ConfigOption* const URL_HELP; + static const ConfigOption* const XSESSION_PATH; + static const ConfigOption* const LOCATION_MODE; + static const ConfigOption* const TEMPLATE_MODE; + static const ConfigOption* const AUTOSTART_UUID; + static const ConfigOption* const NO_VTX; + + static bool init(const QCoreApplication& app, const ConfigOption* const configFile); + static QString get(const ConfigOption* const option); + static bool isSet(const ConfigOption* const option); + +private: + Config() {} +}; + +#endif // CONFIG_H |