forked from qt-creator/qt-creator
Android: Mark toolchains from not the current ndk as invalid
And ensure that they are removed on changing the ndk directory. Change-Id: Ifd3de4d2ac53e93c70b683e11c1368755969ccee Reviewed-by: Tobias Hunger <tobias.hunger@digia.com>
This commit is contained in:
@@ -83,7 +83,14 @@ void AndroidSettingsPage::apply()
|
||||
ProjectExplorer::ToolChainManager::instance()->registerToolChain(tc);
|
||||
}
|
||||
|
||||
// TODO deregister old automatic toolchains?
|
||||
for (int i = 0; i < existingToolChains.count(); ++i) {
|
||||
ProjectExplorer::ToolChain *tc = existingToolChains.at(i);
|
||||
if (tc->type() == QLatin1String(Constants::ANDROID_TOOLCHAIN_TYPE)) {
|
||||
if (!tc->isValid()) {
|
||||
ProjectExplorer::ToolChainManager::instance()->deregisterToolChain(tc);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
AndroidConfigurations::instance().updateAutomaticKitList();
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user