diff options
| author | Felix Morgner <felix.morgner@gmail.com> | 2025-05-24 11:58:39 +0200 |
|---|---|---|
| committer | Felix Morgner <felix.morgner@gmail.com> | 2025-05-24 11:58:39 +0200 |
| commit | 72ab1fb4c1bf363f46470816d8b914a78ac493c4 (patch) | |
| tree | 27349a1bacbab4ea698be35d2d3d9b5184b15ca1 /gui/settings.cpp | |
| parent | b7f2ff4d991ae068f7834bf8e565f6261bf7fff1 (diff) | |
| download | turns-72ab1fb4c1bf363f46470816d8b914a78ac493c4.tar.xz turns-72ab1fb4c1bf363f46470816d8b914a78ac493c4.zip | |
gui: restructure file layout and apply licenses
Diffstat (limited to 'gui/settings.cpp')
| -rw-r--r-- | gui/settings.cpp | 28 |
1 files changed, 0 insertions, 28 deletions
diff --git a/gui/settings.cpp b/gui/settings.cpp deleted file mode 100644 index 13cf665..0000000 --- a/gui/settings.cpp +++ /dev/null @@ -1,28 +0,0 @@ -#include "turns/core/settings.hpp" - -#include <glibmm/refptr.h> -#include <glibmm/wrap.h> - -#include <giomm/settings.h> -#include <giomm/settingsschemasource.h> - -#include <gio/gsettings.h> - -namespace turns::core -{ - - auto get_settings() -> Glib::RefPtr<Gio::Settings> - { - auto constexpr schema_id = "ch.arknet.Turns"; - -#ifdef TURNS_SETTINGS_SCHEMA_DIR - auto source = Gio::SettingsSchemaSource::create(TURNS_SETTINGS_SCHEMA_DIR "/glib-2.0/schemas", true); - auto schema = source->lookup(schema_id, true); - auto settings = g_settings_new_full(Glib::unwrap(schema), nullptr, nullptr); - return Glib::wrap(settings); -#else - return Gio::Settings::create(schema_id); -#endif - } - -} // namespace turns::core |
