forked from qt-creator/qt-creator
Have qmakestep trigger the import label
* Do not use the BuildManager but have the qmakestep trigger the update via the target and project. Reviewed-by: dt
This commit is contained in:
@@ -225,6 +225,7 @@ bool QMakeStep::processFinished(int exitCode, QProcess::ExitStatus status)
|
|||||||
bool result = AbstractProcessStep::processFinished(exitCode, status);
|
bool result = AbstractProcessStep::processFinished(exitCode, status);
|
||||||
if (!result)
|
if (!result)
|
||||||
m_forced = true;
|
m_forced = true;
|
||||||
|
qt4BuildConfiguration()->emitBuildDirectoryInitialized();
|
||||||
return result;
|
return result;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -372,6 +372,11 @@ void Qt4BuildConfiguration::emitQMakeBuildConfigurationChanged()
|
|||||||
emit qmakeBuildConfigurationChanged();
|
emit qmakeBuildConfigurationChanged();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void Qt4BuildConfiguration::emitBuildDirectoryInitialized()
|
||||||
|
{
|
||||||
|
emit buildDirectoryInitialized();
|
||||||
|
}
|
||||||
|
|
||||||
void Qt4BuildConfiguration::getConfigCommandLineArguments(QStringList *addedUserConfigs, QStringList *removedUserConfigs) const
|
void Qt4BuildConfiguration::getConfigCommandLineArguments(QStringList *addedUserConfigs, QStringList *removedUserConfigs) const
|
||||||
{
|
{
|
||||||
QtVersion::QmakeBuildConfigs defaultBuildConfiguration = qtVersion()->defaultBuildConfig();
|
QtVersion::QmakeBuildConfigs defaultBuildConfiguration = qtVersion()->defaultBuildConfig();
|
||||||
|
|||||||
@@ -86,6 +86,9 @@ public:
|
|||||||
// used by qmake step to notify that the qmake args have changed
|
// used by qmake step to notify that the qmake args have changed
|
||||||
// not really nice
|
// not really nice
|
||||||
void emitQMakeBuildConfigurationChanged();
|
void emitQMakeBuildConfigurationChanged();
|
||||||
|
// used by qmake step to notify that the build directory was initialized
|
||||||
|
// not really nice
|
||||||
|
void emitBuildDirectoryInitialized();
|
||||||
void getConfigCommandLineArguments(QStringList *addedUserConfigs, QStringList *removedUserConfigs) const;
|
void getConfigCommandLineArguments(QStringList *addedUserConfigs, QStringList *removedUserConfigs) const;
|
||||||
|
|
||||||
// Those functions are used in a few places.
|
// Those functions are used in a few places.
|
||||||
@@ -120,6 +123,8 @@ signals:
|
|||||||
/// configuration changed
|
/// configuration changed
|
||||||
void targetInformationChanged();
|
void targetInformationChanged();
|
||||||
|
|
||||||
|
void buildDirectoryInitialized();
|
||||||
|
|
||||||
private slots:
|
private slots:
|
||||||
void qtVersionsChanged(const QList<int> &changedVersions);
|
void qtVersionsChanged(const QList<int> &changedVersions);
|
||||||
|
|
||||||
|
|||||||
@@ -390,6 +390,10 @@ void Qt4Project::onAddedTarget(ProjectExplorer::Target *t)
|
|||||||
Q_ASSERT(t);
|
Q_ASSERT(t);
|
||||||
connect(t, SIGNAL(targetInformationChanged()),
|
connect(t, SIGNAL(targetInformationChanged()),
|
||||||
this, SLOT(changeTargetInformation()));
|
this, SLOT(changeTargetInformation()));
|
||||||
|
Qt4Target *qt4target = qobject_cast<Qt4Target *>(t);
|
||||||
|
Q_ASSERT(qt4target);
|
||||||
|
connect(qt4target, SIGNAL(buildDirectoryInitialized()),
|
||||||
|
this, SIGNAL(buildDirectoryInitialized()));
|
||||||
}
|
}
|
||||||
|
|
||||||
void Qt4Project::updateCodeModel()
|
void Qt4Project::updateCodeModel()
|
||||||
|
|||||||
@@ -172,6 +172,7 @@ signals:
|
|||||||
/// (which can happen by the active target changing, too).
|
/// (which can happen by the active target changing, too).
|
||||||
void targetInformationChanged();
|
void targetInformationChanged();
|
||||||
void proFileUpdated(Qt4ProjectManager::Internal::Qt4ProFileNode *node);
|
void proFileUpdated(Qt4ProjectManager::Internal::Qt4ProFileNode *node);
|
||||||
|
void buildDirectoryInitialized();
|
||||||
|
|
||||||
public slots:
|
public slots:
|
||||||
void proFileParseError(const QString &errorMessage);
|
void proFileParseError(const QString &errorMessage);
|
||||||
|
|||||||
@@ -41,7 +41,6 @@
|
|||||||
#include <coreplugin/mainwindow.h>
|
#include <coreplugin/mainwindow.h>
|
||||||
#include <projectexplorer/projectexplorerconstants.h>
|
#include <projectexplorer/projectexplorerconstants.h>
|
||||||
#include <projectexplorer/buildconfiguration.h>
|
#include <projectexplorer/buildconfiguration.h>
|
||||||
#include <projectexplorer/buildmanager.h>
|
|
||||||
#include <utils/qtcassert.h>
|
#include <utils/qtcassert.h>
|
||||||
#include <extensionsystem/pluginmanager.h>
|
#include <extensionsystem/pluginmanager.h>
|
||||||
|
|
||||||
@@ -103,8 +102,7 @@ Qt4ProjectConfigWidget::Qt4ProjectConfigWidget(Qt4Project *project)
|
|||||||
connect(m_ui->manageQtVersionPushButtons, SIGNAL(clicked()),
|
connect(m_ui->manageQtVersionPushButtons, SIGNAL(clicked()),
|
||||||
this, SLOT(manageQtVersions()));
|
this, SLOT(manageQtVersions()));
|
||||||
|
|
||||||
connect(ProjectExplorer::ProjectExplorerPlugin::instance()->buildManager(),
|
connect(project, SIGNAL(buildDirectoryInitialized()),
|
||||||
SIGNAL(buildQueueFinished(bool)),
|
|
||||||
this, SLOT(updateImportLabel()));
|
this, SLOT(updateImportLabel()));
|
||||||
|
|
||||||
QtVersionManager *vm = QtVersionManager::instance();
|
QtVersionManager *vm = QtVersionManager::instance();
|
||||||
|
|||||||
@@ -190,6 +190,8 @@ Qt4Target::Qt4Target(Qt4Project *parent, const QString &id) :
|
|||||||
this, SIGNAL(environmentChanged()));
|
this, SIGNAL(environmentChanged()));
|
||||||
connect(this, SIGNAL(addedRunConfiguration(ProjectExplorer::RunConfiguration*)),
|
connect(this, SIGNAL(addedRunConfiguration(ProjectExplorer::RunConfiguration*)),
|
||||||
this, SLOT(onAddedRunConfiguration(ProjectExplorer::RunConfiguration*)));
|
this, SLOT(onAddedRunConfiguration(ProjectExplorer::RunConfiguration*)));
|
||||||
|
connect(this, SIGNAL(addedBuildConfiguration(ProjectExplorer::BuildConfiguration*)),
|
||||||
|
this, SLOT(onAddedBuildConfiguration(ProjectExplorer::BuildConfiguration*)));
|
||||||
connect(this, SIGNAL(activeRunConfigurationChanged(ProjectExplorer::RunConfiguration*)),
|
connect(this, SIGNAL(activeRunConfigurationChanged(ProjectExplorer::RunConfiguration*)),
|
||||||
this, SLOT(updateToolTipAndIcon()));
|
this, SLOT(updateToolTipAndIcon()));
|
||||||
|
|
||||||
@@ -403,6 +405,15 @@ void Qt4Target::onAddedRunConfiguration(ProjectExplorer::RunConfiguration *rc)
|
|||||||
this, SLOT(slotUpdateDeviceInformation()));
|
this, SLOT(slotUpdateDeviceInformation()));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void Qt4Target::onAddedBuildConfiguration(ProjectExplorer::BuildConfiguration *bc)
|
||||||
|
{
|
||||||
|
Q_ASSERT(bc);
|
||||||
|
Qt4BuildConfiguration *qt4bc = qobject_cast<Qt4BuildConfiguration *>(bc);
|
||||||
|
Q_ASSERT(qt4bc);
|
||||||
|
connect(qt4bc, SIGNAL(buildDirectoryInitialized()),
|
||||||
|
this, SIGNAL(buildDirectoryInitialized()));
|
||||||
|
}
|
||||||
|
|
||||||
void Qt4Target::slotUpdateDeviceInformation()
|
void Qt4Target::slotUpdateDeviceInformation()
|
||||||
{
|
{
|
||||||
S60DeviceRunConfiguration *deviceRc(qobject_cast<S60DeviceRunConfiguration *>(sender()));
|
S60DeviceRunConfiguration *deviceRc(qobject_cast<S60DeviceRunConfiguration *>(sender()));
|
||||||
|
|||||||
@@ -99,12 +99,15 @@ signals:
|
|||||||
/// targetInformationChanged() or if the active build configuration changes
|
/// targetInformationChanged() or if the active build configuration changes
|
||||||
void targetInformationChanged();
|
void targetInformationChanged();
|
||||||
|
|
||||||
|
void buildDirectoryInitialized();
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
bool fromMap(const QVariantMap &map);
|
bool fromMap(const QVariantMap &map);
|
||||||
|
|
||||||
private slots:
|
private slots:
|
||||||
void updateQtVersion();
|
void updateQtVersion();
|
||||||
void onAddedRunConfiguration(ProjectExplorer::RunConfiguration *rc);
|
void onAddedRunConfiguration(ProjectExplorer::RunConfiguration *rc);
|
||||||
|
void onAddedBuildConfiguration(ProjectExplorer::BuildConfiguration *bc);
|
||||||
void slotUpdateDeviceInformation();
|
void slotUpdateDeviceInformation();
|
||||||
void updateToolTipAndIcon();
|
void updateToolTipAndIcon();
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user