forked from qt-creator/qt-creator
ProjectExplorer: Compactify runconfiguration aspect creation
Change-Id: I12394d3df8deb7666be6ac3f112082f915454e82 Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
This commit is contained in:
@@ -231,7 +231,7 @@ RunConfiguration::RunConfiguration(Target *target, Core::Id id)
|
||||
[this] { return displayName(); }, false);
|
||||
|
||||
for (const AspectFactory &factory : theAspectFactories)
|
||||
addExtraAspect(factory(this));
|
||||
m_aspects.append(factory(this));
|
||||
}
|
||||
|
||||
RunConfiguration::~RunConfiguration()
|
||||
@@ -280,12 +280,6 @@ void RunConfiguration::addAspectFactory(const AspectFactory &aspectFactory)
|
||||
theAspectFactories.push_back(aspectFactory);
|
||||
}
|
||||
|
||||
void RunConfiguration::addExtraAspect(IRunConfigurationAspect *aspect)
|
||||
{
|
||||
if (aspect)
|
||||
m_aspects += aspect;
|
||||
}
|
||||
|
||||
/*!
|
||||
* Returns the RunConfiguration of the currently active target
|
||||
* of the startup project, if such exists, or \c nullptr otherwise.
|
||||
|
||||
Reference in New Issue
Block a user