QtSupport: Store Qt versions after autodetection on startup

Restores old behavior. When QC is started with a Qt in PATH but
without existing settings it ran the autodetection and stored
the Qt versions to disk. This made it possible to restart QC later
with the same settingspath, but without having Qt in PATH.
Without this patch the Qt versions of QC only got persisted if
the settings dialog had been opened at least once and closed with
Ok (or an explicit Apply).

Change-Id: I74bd9bc0b96d5ff66e5a81200d6a269a5411a5ea
Reviewed-by: hjk <hjk@qt.io>
This commit is contained in:
Christian Stenger
2023-10-17 08:53:25 +02:00
parent 3363d71888
commit 54b841f789

View File

@@ -155,6 +155,8 @@ void QtVersionManagerImpl::triggerQtVersionRestore()
// in that case figure out if there's a qt in path // in that case figure out if there's a qt in path
// and add it to the Qt versions // and add it to the Qt versions
findSystemQt(); findSystemQt();
if (m_versions.size())
saveQtVersions();
} }
{ {