Setup app (#541)

- Implement Setup app for device's first boot
- Implement device simple name and vendor name variables
- Remove region setting (locale setting is already available)
This commit is contained in:
Ken Van Hoeylandt
2026-07-02 00:29:03 +02:00
committed by GitHub
parent d3439f6f45
commit 2f5e183f18
16 changed files with 283 additions and 71 deletions
@@ -14,7 +14,6 @@ static const auto LOGGER = Logger("SystemSettings");
constexpr auto* FILE_PATH_FORMAT = "{}/settings/system.properties";
static Mutex mutex;
static bool cached = false;
static SystemSettings cachedSettings;
@@ -51,15 +50,6 @@ static bool loadSystemSettingsFromFile(SystemSettings& properties) {
properties.dateFormat = "MM/DD/YYYY";
}
// Load region
auto region_entry = map.find("region");
if (region_entry != map.end() && !region_entry->second.empty()) {
properties.region = region_entry->second;
} else {
LOGGER.info("Region missing or empty, using default EU");
properties.region = "EU";
}
LOGGER.info("System settings loaded");
return true;
}
@@ -82,7 +72,6 @@ bool saveSystemSettings(const SystemSettings& properties) {
map["language"] = toString(properties.language);
map["timeFormat24h"] = properties.timeFormat24h ? "true" : "false";
map["dateFormat"] = properties.dateFormat;
map["region"] = properties.region;
if (!file::savePropertiesFile(file_path, map)) {
LOGGER.error("Failed to save {}", file_path);