Route startup preference load through adapter

This commit is contained in:
2026-06-12 17:41:00 +02:00
parent d049d586ed
commit baee4b2a08
4 changed files with 11 additions and 3 deletions

View File

@@ -29,7 +29,6 @@
#include <Foundation/Foundation.h>
#include "objc_utils.h"
#endif
#include "settings.h"
App* App::I = nullptr; // singleton
@@ -223,7 +222,7 @@ void App::initLog()
LOG("%s", g_version);
LOG("load preferences");
if (!Settings::load())
if (!pp::panopainter::load_legacy_preferences())
LOG("load preferences failed");
}

View File

@@ -7,6 +7,11 @@
namespace pp::panopainter {
bool load_legacy_preferences()
{
return Settings::load();
}
bool has_legacy_preference(const char* key)
{
return Settings::has(key);

View File

@@ -4,6 +4,7 @@
namespace pp::panopainter {
bool load_legacy_preferences();
bool has_legacy_preference(const char* key);
int legacy_integer_preference(const char* key);
int legacy_integer_preference_or(const char* key, int default_value);