From 1fc570acb79fbe18958a7d5732b330bcd4601a97 Mon Sep 17 00:00:00 2001 From: Tobias Hunger Date: Wed, 11 Nov 2015 11:02:42 +0100 Subject: [PATCH] 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 --- src/plugins/projectexplorer/kitmanager.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/plugins/projectexplorer/kitmanager.cpp b/src/plugins/projectexplorer/kitmanager.cpp index 0125b0e8a94..05f75c3df5e 100644 --- a/src/plugins/projectexplorer/kitmanager.cpp +++ b/src/plugins/projectexplorer/kitmanager.cpp @@ -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; }