forked from qt-creator/qt-creator
Kits: Do not lose toolchains when using SDK-provided kits
The observed behavior is: The first time you open Qt Creator from the Qt 5.6 package you get the kit for the installed Qt version with a toolchain. The next time you start the toolchain vanishes from the Kit. Surprisingly nobody reported a bug about this:-/ Change-Id: I49545e11f02eadb73f583b134d9eadfc2adf3bec Reviewed-by: Niels Weber <niels.weber@theqtcompany.com>
This commit is contained in:
@@ -171,6 +171,8 @@ void KitManager::restoreKits()
|
||||
Kit *toStore = 0;
|
||||
foreach (Kit *current, kitsToValidate) {
|
||||
toStore = current;
|
||||
toStore->setup(); // Make sure all kitinformation are properly set up before merging them
|
||||
// with the information from the user settings file
|
||||
|
||||
// Check whether we had this kit stored and prefer the stored one:
|
||||
for (int i = 0; i < kitsToCheck.count(); ++i) {
|
||||
@@ -191,8 +193,6 @@ void KitManager::restoreKits()
|
||||
break;
|
||||
}
|
||||
}
|
||||
if (toStore == current)
|
||||
toStore->setup();
|
||||
addKit(toStore);
|
||||
sdkKits << toStore;
|
||||
}
|
||||
|
Reference in New Issue
Block a user