Commit 2a78ffea authored by Tim Jenssen's avatar Tim Jenssen
Browse files

refactor if clause



Change-Id: I3ce6e711392f35c89dfcbecc3c8fcb8aca293602
Reviewed-by: default avatarChristian Stenger <christian.stenger@theqtcompany.com>
parent 33ce9f9e
......@@ -342,17 +342,16 @@ static void addProjectInformation(TestConfiguration *config, const QString &file
QList<ProjectExplorer::RunConfiguration *> rcs = target->runConfigurations();
foreach (ProjectExplorer::RunConfiguration *rc, rcs) {
if (ProjectExplorer::LocalApplicationRunConfiguration *localRunConfiguration
= qobject_cast<ProjectExplorer::LocalApplicationRunConfiguration *>(rc)) {
if (localRunConfiguration->executable() == targetFile) {
hasDesktopTarget = true;
workDir = Utils::FileUtils::normalizePathName(
localRunConfiguration->workingDirectory());
ProjectExplorer::EnvironmentAspect *envAsp
= localRunConfiguration->extraAspect<ProjectExplorer::EnvironmentAspect>();
env = envAsp->environment();
break;
}
ProjectExplorer::LocalApplicationRunConfiguration *localRunConfiguration
= qobject_cast<ProjectExplorer::LocalApplicationRunConfiguration *>(rc);
if (localRunConfiguration && localRunConfiguration->executable() == targetFile) {
hasDesktopTarget = true;
workDir = Utils::FileUtils::normalizePathName(
localRunConfiguration->workingDirectory());
ProjectExplorer::EnvironmentAspect *envAsp
= localRunConfiguration->extraAspect<ProjectExplorer::EnvironmentAspect>();
env = envAsp->environment();
break;
}
}
}
......
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