aboutsummaryrefslogtreecommitdiffstats
path: root/src/app/shared
diff options
context:
space:
mode:
authorChristian Kandeler <christian.kandeler@digia.com>2012-11-13 15:17:22 +0100
committerJoerg Bornemann <joerg.bornemann@digia.com>2012-11-13 15:32:35 +0100
commite306aa35bc028c5d1df3635152d04521a10764e6 (patch)
tree83b7d17d522998a66410ce3161abc2a38a809407 /src/app/shared
parent5c2593bb37042ebbde5349959b04d4779b9e68a8 (diff)
Don't use QSharedPointer for Settings objects.
They are not actually shared (and it would be a drag to do so). Change-Id: Ia4a33b37d858ac81af48c96a1fb04ba3d77e7685 Reviewed-by: Joerg Bornemann <joerg.bornemann@digia.com>
Diffstat (limited to 'src/app/shared')
-rw-r--r--src/app/shared/commandlineparser.cpp5
-rw-r--r--src/app/shared/commandlineparser.h2
2 files changed, 3 insertions, 4 deletions
diff --git a/src/app/shared/commandlineparser.cpp b/src/app/shared/commandlineparser.cpp
index 03e6c0dff..6532755c6 100644
--- a/src/app/shared/commandlineparser.cpp
+++ b/src/app/shared/commandlineparser.cpp
@@ -79,7 +79,6 @@ static QStringList allLogLevelStrings()
CommandLineParser::CommandLineParser()
{
- m_settings = Settings::create();
}
// TODO: Symbolic constants for all option and command names.
@@ -152,7 +151,7 @@ void CommandLineParser::doParse()
m_projectFileName.clear();
m_products.clear();
m_buildOptions = BuildOptions();
- m_buildOptions.maxJobCount = m_settings->value("preferences/jobs", 0).toInt();
+ m_buildOptions.maxJobCount = m_settings.value("preferences/jobs", 0).toInt();
if (m_buildOptions.maxJobCount <= 0)
m_buildOptions.maxJobCount = QThread::idealThreadCount();
m_help = false;
@@ -397,7 +396,7 @@ QList<QVariantMap> CommandLineParser::buildConfigurations() const
properties.insert(currentKey, currentProperties);
if (properties.count() == 1) // No build variant specified on command line.
- properties.insert(m_settings->buildVariant(), QVariantMap());
+ properties.insert(m_settings.buildVariant(), QVariantMap());
const PropertyMaps::Iterator globalMapIt = properties.find(QString());
Q_ASSERT(globalMapIt != properties.end());
diff --git a/src/app/shared/commandlineparser.h b/src/app/shared/commandlineparser.h
index 0837bd5f5..a0de3d36d 100644
--- a/src/app/shared/commandlineparser.h
+++ b/src/app/shared/commandlineparser.h
@@ -81,7 +81,7 @@ private:
QString propertyName(const QString &aCommandLineName) const;
void setRealProjectFile();
- Settings::Ptr m_settings;
+ Settings m_settings;
Command m_command;
QString m_runTargetName;
QString m_projectFileName;