summaryrefslogtreecommitdiffhomepage
path: root/ftnoir_tracker_hatire/ftnoir_tracker_hat_settings.cpp
diff options
context:
space:
mode:
authorStanislaw Halik <sthalik@misaki.pl>2015-03-31 06:23:49 +0200
committerStanislaw Halik <sthalik@misaki.pl>2015-03-31 06:23:49 +0200
commitd7d37e480207bfa48da05172594f8a305345e4d4 (patch)
treea4b7c447a8a6082c2f031659095f495186229b38 /ftnoir_tracker_hatire/ftnoir_tracker_hat_settings.cpp
parentdaae1cf1241b0e2355804a7e5be17eb24af76fe5 (diff)
hatire: update api usage in one more place
Diffstat (limited to 'ftnoir_tracker_hatire/ftnoir_tracker_hat_settings.cpp')
-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" );