2019-09-05 00:26:26 +08:00
|
|
|
#pragma once
|
|
|
|
|
2019-12-06 16:40:23 +08:00
|
|
|
#include <common/json.h>
|
|
|
|
|
2020-02-12 18:03:40 +08:00
|
|
|
struct GeneralSettings
|
|
|
|
{
|
|
|
|
bool isPackaged;
|
|
|
|
bool isStartupEnabled;
|
|
|
|
std::wstring startupDisabledReason;
|
2020-03-26 18:51:05 +08:00
|
|
|
std::map<std::wstring, bool> isModulesEnabledMap;
|
2020-02-12 18:03:40 +08:00
|
|
|
bool isElevated;
|
|
|
|
bool isRunElevated;
|
2020-02-19 03:56:34 +08:00
|
|
|
bool isAdmin;
|
2020-04-21 15:30:12 +08:00
|
|
|
bool downloadUpdatesAutomatically;
|
2020-02-12 18:03:40 +08:00
|
|
|
std::wstring theme;
|
|
|
|
std::wstring systemTheme;
|
|
|
|
std::wstring powerToysVersion;
|
|
|
|
|
|
|
|
json::JsonObject to_json();
|
|
|
|
};
|
|
|
|
|
2019-12-17 01:36:52 +08:00
|
|
|
json::JsonObject load_general_settings();
|
2020-04-21 15:30:12 +08:00
|
|
|
GeneralSettings get_general_settings();
|
2019-12-27 00:26:11 +08:00
|
|
|
void apply_general_settings(const json::JsonObject& general_configs);
|
2019-09-05 00:26:26 +08:00
|
|
|
void start_initial_powertoys();
|