summaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
-rw-r--r--ftnoir_tracker_hatire/ftnoir_tracker_hat_settings.cpp10
1 files changed, 9 insertions, 1 deletions
diff --git a/ftnoir_tracker_hatire/ftnoir_tracker_hat_settings.cpp b/ftnoir_tracker_hatire/ftnoir_tracker_hat_settings.cpp
index 79f93538..a327c0c1 100644
--- a/ftnoir_tracker_hatire/ftnoir_tracker_hat_settings.cpp
+++ b/ftnoir_tracker_hatire/ftnoir_tracker_hat_settings.cpp
@@ -105,8 +105,16 @@ void TrackerSettings::load_ini()
void TrackerSettings::save_ini() const
{
+#ifdef OPENTRACK_API
+ QSettings settings(options::group::org); // Registry settings (in HK_USER)
+#else
QSettings settings("opentrack"); // Registry settings (in HK_USER)
- QString currentFile = settings.value( "SettingsFile", QCoreApplication::applicationDirPath() + "/settings/default.ini" ).toString();
+#endif
+#ifdef OPENTRACK_API
+ QString currentFile = settings.value( options::group::filename_key, QCoreApplication::applicationDirPath() + options::group::default_path ).toString();
+#else
+ QString currentFile = settings.value( "SettingsFile", QCoreApplication::applicationDirPath() + "/Settings/default.ini" ).toString();
+#endif
QSettings iniFile( currentFile, QSettings::IniFormat ); // Application settings (in INI-file)
iniFile.beginGroup ( "HAT" );