summaryrefslogtreecommitdiffstats
path: root/src/preferences/settingsmanager.cpp
diff options
context:
space:
mode:
authorRJ Ryan <rryan@mixxx.org>2016-01-24 22:57:41 -0800
committerRJ Ryan <rryan@mixxx.org>2016-01-24 22:57:41 -0800
commit83e58a40a109acda194078ad8e53d07de68799bd (patch)
tree1a42d622c056aee939aa618abfbcdd0969ed5a23 /src/preferences/settingsmanager.cpp
parent479c9e15159299667f2f7d16d65a8565f656a376 (diff)
Use UserSettings (typedef) instead of ConfigObject.
This will allow us to experiment with different implementations for structured user preferences. It will also reduce repeated typing of template arguments and better represent the purpose of the object.
Diffstat (limited to 'src/preferences/settingsmanager.cpp')
-rw-r--r--src/preferences/settingsmanager.cpp7
1 files changed, 3 insertions, 4 deletions
diff --git a/src/preferences/settingsmanager.cpp b/src/preferences/settingsmanager.cpp
index cd4cb2516d..54b1481457 100644
--- a/src/preferences/settingsmanager.cpp
+++ b/src/preferences/settingsmanager.cpp
@@ -19,11 +19,10 @@ SettingsManager::SettingsManager(QObject* pParent,
// Check to see if this is the first time this version of Mixxx is run
// after an upgrade and make any needed changes.
Upgrade upgrader;
- UserSettings* pSettings = upgrader.versionUpgrade(settingsPath);
- DEBUG_ASSERT_AND_HANDLE(pSettings != nullptr) {
- pSettings = new UserSettings("");
+ m_pSettings = upgrader.versionUpgrade(settingsPath);
+ DEBUG_ASSERT_AND_HANDLE(!m_pSettings.isNull()) {
+ m_pSettings = UserSettingsPointer(new UserSettings(""));
}
- m_pSettings = UserSettingsPointer(pSettings);
m_bShouldRescanLibrary = upgrader.rescanLibrary();
ControlDoublePrivate::setUserConfig(m_pSettings);
}