Commit 1d75ebec authored by dt's avatar dt
Browse files

Fix Qt4Project::toolchain() returning a wrong thing.

Hmm even if the cached toolchain is correct, we do a few things, maybe
I should optimize it.
parent fd5ee479
......@@ -268,7 +268,6 @@ void Qt4Project::qtVersionsChanged()
m_rootProjectNode->update();
}
}
updateToolChain(activeBuildConfiguration());
}
void Qt4Project::updateFileList()
......@@ -386,14 +385,6 @@ void Qt4Project::scheduleUpdateCodeModel(Qt4ProjectManager::Internal::Qt4ProFile
}
ProjectExplorer::ToolChain *Qt4Project::toolChain(const QString &buildConfiguration) const
{
if (!m_toolChain) {
updateToolChain(buildConfiguration);
}
return m_toolChain;
}
void Qt4Project::updateToolChain(const QString &buildConfiguration) const
{
ProjectExplorer::ToolChain *tempToolChain;
tempToolChain = qtVersion(buildConfiguration)->createToolChain(toolChainType(buildConfiguration));
......@@ -404,6 +395,8 @@ void Qt4Project::updateToolChain(const QString &buildConfiguration) const
} else {
delete tempToolChain;
}
return m_toolChain;
}
QString Qt4Project::makeCommand(const QString &buildConfiguration) const
......@@ -891,7 +884,6 @@ void Qt4Project::setQtVersion(const QString &buildConfiguration, int id)
void Qt4Project::setToolChainType(const QString &buildConfiguration, ProjectExplorer::ToolChain::ToolChainType type)
{
setValue(buildConfiguration, "ToolChain", (int)type);
updateToolChain(buildConfiguration);
updateActiveRunConfiguration();
}
......
......@@ -238,7 +238,6 @@ private:
static QString qmakeVarName(ProjectExplorer::FileType type);
void updateActiveRunConfiguration();
void updateToolChain(const QString &buildConfiguration) const;
Qt4Manager *m_manager;
Internal::Qt4ProFileNode *m_rootProjectNode;
......
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