forked from qt-creator/qt-creator
Project: Fix crashes
Task-number: QTCREATORBUG-7563 Change-Id: Ib7630e9ca82a0b09703ff948af95af53ced05730 Reviewed-by: Tobias Hunger <tobias.hunger@nokia.com>
This commit is contained in:
committed by
Tobias Hunger
parent
f930db7e0a
commit
dc251deccf
@@ -226,6 +226,8 @@ void BuildSettingsWidget::updateAddButtonMenu()
|
||||
this, SLOT(cloneConfiguration()));
|
||||
}
|
||||
IBuildConfigurationFactory * factory = IBuildConfigurationFactory::find(m_target);
|
||||
if (!factory)
|
||||
return;
|
||||
foreach (Core::Id id, factory->availableCreationIds(m_target)) {
|
||||
QAction *action = m_addButtonMenu->addAction(factory->displayNameForId(id), this, SLOT(createConfiguration()));
|
||||
action->setData(QVariant::fromValue(id));
|
||||
|
@@ -924,17 +924,16 @@ QtSupport::ProFileReader *Qt4Project::createProFileReader(Qt4ProFileNode *qt4Pro
|
||||
|
||||
Profile *p;
|
||||
Utils::Environment env = Utils::Environment::systemEnvironment();
|
||||
Qt4BuildConfiguration *currentBc = bc;
|
||||
QStringList qmakeArgs;
|
||||
if (!currentBc)
|
||||
currentBc = activeTarget() ? qobject_cast<Qt4BuildConfiguration *>(activeTarget()->activeBuildConfiguration()) : 0;
|
||||
if (!bc)
|
||||
bc = activeTarget() ? qobject_cast<Qt4BuildConfiguration *>(activeTarget()->activeBuildConfiguration()) : 0;
|
||||
|
||||
if (currentBc) {
|
||||
p = currentBc->target()->profile();
|
||||
env = currentBc->environment();
|
||||
if (currentBc->qmakeStep()) {
|
||||
qmakeArgs = currentBc->qmakeStep()->parserArguments();
|
||||
m_proFileOption->qmakespec = currentBc->qmakeStep()->mkspec().toString();
|
||||
if (bc) {
|
||||
p = bc->target()->profile();
|
||||
env = bc->environment();
|
||||
if (bc->qmakeStep()) {
|
||||
qmakeArgs = bc->qmakeStep()->parserArguments();
|
||||
m_proFileOption->qmakespec = bc->qmakeStep()->mkspec().toString();
|
||||
} else {
|
||||
qmakeArgs = bc->configCommandLineArguments();
|
||||
}
|
||||
|
Reference in New Issue
Block a user