Commit 3bfc953c authored by Kai Koehne's avatar Kai Koehne

DebuggingHelpers: Reorder arguments of finished signal

Allow slots that use the error ouput, but aren't interested in the list
of the tools.

Reviewed-by: dt
parent 4150e143
......@@ -133,10 +133,10 @@ void DebuggingHelperBuildTask::run(QFutureInterface<void> &future)
success = buildDebuggingHelper(future, &output);
if (success) {
emit finished(m_qtId, m_tools, output);
emit finished(m_qtId, output, m_tools);
} else {
qWarning("%s", qPrintable(m_errorMessage));
emit finished(m_qtId, m_tools, m_errorMessage);
emit finished(m_qtId, m_errorMessage, m_tools);
}
deleteLater();
......
......@@ -65,7 +65,7 @@ public:
static Tools availableTools(const QtVersion *version);
signals:
void finished(int qtVersionId, DebuggingHelperBuildTask::Tools tools, const QString &output);
void finished(int qtVersionId, const QString &output, DebuggingHelperBuildTask::Tools tools);
private:
bool buildDebuggingHelper(QFutureInterface<void> &future, QString *output);
......
......@@ -544,8 +544,8 @@ void QMakeStepConfigWidget::buildQmlDebuggingHelper()
DebuggingHelperBuildTask *buildTask = new DebuggingHelperBuildTask(version,
DebuggingHelperBuildTask::QmlDebugging);
connect(buildTask, SIGNAL(finished(int,DebuggingHelperBuildTask::Tools,QString)),
this, SLOT(debuggingHelperBuildFinished()),
connect(buildTask, SIGNAL(finished(int,QString,DebuggingHelperBuildTask::Tools)),
this, SLOT(debuggingHelperBuildFinished(int,QString)),
Qt::QueuedConnection);
QFuture<void> task = QtConcurrent::run(&DebuggingHelperBuildTask::run, buildTask);
......@@ -554,7 +554,7 @@ void QMakeStepConfigWidget::buildQmlDebuggingHelper()
QLatin1String("Qt4ProjectManager::BuildHelpers"));
}
void QMakeStepConfigWidget::debuggingHelperBuildFinished()
void QMakeStepConfigWidget::debuggingHelperBuildFinished(int qtVersionId, const QString &output)
{
m_step->qt4BuildConfiguration()->qtVersion()->invalidateCache();
m_ui.qmlDebuggingLibraryCheckBox->setChecked(m_step->linkQmlDebuggingLibrary());
......
......@@ -149,7 +149,7 @@ private slots:
// other
void buildQmlDebuggingHelper();
void debuggingHelperBuildFinished();
void debuggingHelperBuildFinished(int qtVersionId, const QString &output);
private:
void updateSummaryLabel();
......
......@@ -73,8 +73,8 @@ public:
{
qmlDumpBuilds()->insert(version->uniqueId(), this);
connect(m_buildTask, SIGNAL(finished(int,DebuggingHelperBuildTask::Tools,QString)),
this, SLOT(finish(int,DebuggingHelperBuildTask::Tools,QString)),
connect(m_buildTask, SIGNAL(finished(int,QString,DebuggingHelperBuildTask::Tools)),
this, SLOT(finish(int,QString,DebuggingHelperBuildTask::Tools)),
Qt::QueuedConnection);
}
......@@ -102,7 +102,7 @@ public:
}
private slots:
void finish(int qtId, DebuggingHelperBuildTask::Tools tools, const QString &output)
void finish(int qtId, const QString &output, DebuggingHelperBuildTask::Tools tools)
{
QtVersion *version = QtVersionManager::instance()->version(qtId);
......
......@@ -261,7 +261,7 @@ static inline int findVersionById(const QList<QtVersion *> &l, int id)
}
// Update with results of terminated helper build
void QtOptionsPageWidget::debuggingHelperBuildFinished(int qtVersionId, DebuggingHelperBuildTask::Tools tools, const QString &output)
void QtOptionsPageWidget::debuggingHelperBuildFinished(int qtVersionId, const QString &output, DebuggingHelperBuildTask::Tools tools)
{
const int index = findVersionById(m_versions, qtVersionId);
if (index == -1)
......@@ -320,8 +320,8 @@ void QtOptionsPageWidget::buildDebuggingHelper(DebuggingHelperBuildTask::Tools t
// Run a debugging helper build task in the background.
DebuggingHelperBuildTask *buildTask = new DebuggingHelperBuildTask(version, tools);
connect(buildTask, SIGNAL(finished(int,DebuggingHelperBuildTask::Tools,QString)),
this, SLOT(debuggingHelperBuildFinished(int,DebuggingHelperBuildTask::Tools,QString)),
connect(buildTask, SIGNAL(finished(int,QString,DebuggingHelperBuildTask::Tools)),
this, SLOT(debuggingHelperBuildFinished(int,QString,DebuggingHelperBuildTask::Tools)),
Qt::QueuedConnection);
QFuture<void> task = QtConcurrent::run(&DebuggingHelperBuildTask::run, buildTask);
const QString taskName = tr("Building helpers");
......
......@@ -106,7 +106,7 @@ private slots:
void buildQmlDebuggingLibrary();
void buildQmlObserver();
void slotShowDebuggingBuildLog();
void debuggingHelperBuildFinished(int qtVersionId, DebuggingHelperBuildTask::Tools tools, const QString &output);
void debuggingHelperBuildFinished(int qtVersionId, const QString &output, DebuggingHelperBuildTask::Tools tools);
private:
void updateDescriptionLabel();
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment