Fix proFileUpdated signal, set correct parse in progress state

Change-Id: I1f7ca269115491323373fe5c4230bd38860c08ce
Reviewed-on: http://codereview.qt.nokia.com/596
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Christian Kandeler <christian.kandeler@nokia.com>
This commit is contained in:
dt_
2011-06-22 12:53:49 +02:00
committed by Daniel Teske
parent 893c4022c6
commit 1c1521c3c4
3 changed files with 14 additions and 1 deletions

View File

@@ -1462,6 +1462,16 @@ bool Qt4ProFileNode::validParse() const
return m_validParse;
}
void Qt4ProFileNode::setParseInProgressRecursive()
{
m_parseInProgress = true;
foreach (ProjectNode *subNode, subProjectNodes()) {
if (Qt4ProFileNode *node = qobject_cast<Qt4ProFileNode *>(subNode)) {
node->setParseInProgressRecursive();
}
}
}
bool Qt4ProFileNode::parseInProgress() const
{
return m_parseInProgress;
@@ -1469,7 +1479,7 @@ bool Qt4ProFileNode::parseInProgress() const
void Qt4ProFileNode::scheduleUpdate()
{
m_parseInProgress = true;
setParseInProgressRecursive();
emitProFileUpdated();
m_project->scheduleAsyncUpdate(this);
}

View File

@@ -353,6 +353,7 @@ public:
bool hasBuildTargets(Qt4ProjectType projectType) const;
void setParseInProgressRecursive();
public slots:
void asyncUpdate();

View File

@@ -673,6 +673,7 @@ void Qt4Project::scheduleAsyncUpdate()
m_cancelEvaluate = true;
m_asyncUpdateState = AsyncFullUpdatePending;
activeTarget()->activeBuildConfiguration()->setEnabled(false);
m_rootProjectNode->setParseInProgressRecursive();
m_rootProjectNode->emitProFileUpdated();
return;
}
@@ -681,6 +682,7 @@ void Qt4Project::scheduleAsyncUpdate()
qDebug()<<" starting timer for full update, setting state to full update pending";
m_partialEvaluate.clear();
activeTarget()->activeBuildConfiguration()->setEnabled(false);
m_rootProjectNode->setParseInProgressRecursive();
m_rootProjectNode->emitProFileUpdated();
m_asyncUpdateState = AsyncFullUpdatePending;
m_asyncUpdateTimer.start();