forked from qt-creator/qt-creator
Refactor deployment
* Add a DeployConfiguration class to hold settings related to deployment. * Add BuildStepsList to hold a list of buildsteps * Update BuildConfiguration to use BuildStepLists instead of manageing lists of buildsteps itself. * Update BuildManager to use BuildStepLists in its interfaces * Fix fallout introduced by API changes * Update .user file to new way of storing settings Task-number: QTCREATORBUG-1427 Task-number: QTCREATORBUG-1428 Task-number: QTCREATORBUG-1811 Task-number: QTCREATORBUG-1930
This commit is contained in:
@@ -37,6 +37,8 @@
|
||||
#include "makestep.h"
|
||||
|
||||
#include <utils/qtcassert.h>
|
||||
#include <projectexplorer/buildsteplist.h>
|
||||
#include <projectexplorer/projectexplorerconstants.h>
|
||||
|
||||
#include <QtCore/QDebug>
|
||||
|
||||
@@ -398,18 +400,22 @@ void Qt4BuildConfiguration::getConfigCommandLineArguments(QStringList *addedUser
|
||||
QMakeStep *Qt4BuildConfiguration::qmakeStep() const
|
||||
{
|
||||
QMakeStep *qs = 0;
|
||||
foreach(BuildStep *bs, steps(ProjectExplorer::BuildStep::Build))
|
||||
if ((qs = qobject_cast<QMakeStep *>(bs)) != 0)
|
||||
BuildStepList *bsl = stepList(ProjectExplorer::Constants::BUILDSTEPS_BUILD);
|
||||
Q_ASSERT(bsl);
|
||||
for (int i = 0; i < bsl->count(); ++i)
|
||||
if ((qs = qobject_cast<QMakeStep *>(bsl->at(i))) != 0)
|
||||
return qs;
|
||||
return 0;
|
||||
}
|
||||
|
||||
MakeStep *Qt4BuildConfiguration::makeStep() const
|
||||
{
|
||||
MakeStep *qs = 0;
|
||||
foreach(BuildStep *bs, steps(ProjectExplorer::BuildStep::Build))
|
||||
if ((qs = qobject_cast<MakeStep *>(bs)) != 0)
|
||||
return qs;
|
||||
MakeStep *ms = 0;
|
||||
BuildStepList *bsl = stepList(ProjectExplorer::Constants::BUILDSTEPS_BUILD);
|
||||
Q_ASSERT(bsl);
|
||||
for (int i = 0; i < bsl->count(); ++i)
|
||||
if ((ms = qobject_cast<MakeStep *>(bsl->at(i))) != 0)
|
||||
return ms;
|
||||
return 0;
|
||||
}
|
||||
|
||||
@@ -648,7 +654,7 @@ BuildConfiguration *Qt4BuildConfigurationFactory::create(ProjectExplorer::Target
|
||||
version->displayName(),
|
||||
&ok);
|
||||
if (!ok || buildConfigurationName.isEmpty())
|
||||
return false;
|
||||
return 0;
|
||||
|
||||
qt4Target->addQt4BuildConfiguration(tr("%1 Debug").arg(buildConfigurationName),
|
||||
version,
|
||||
|
||||
Reference in New Issue
Block a user