forked from qt-creator/qt-creator
Fix that last session could reset to default session
E.g. when opening and closing Qt Creator without opening a session. The last session may only be updated to the "active" session, if it is not the default-virgin session (which is actually a "no session" value). Change-Id: If47da30d94c20df62d45960224e3137bcc6ba1b8 Reviewed-by: hjk <hjk@qt.io> Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
This commit is contained in:
@@ -1556,7 +1556,8 @@ void ProjectExplorerPluginPrivate::savePersistentSettings()
|
||||
}
|
||||
|
||||
QSettings *s = ICore::settings();
|
||||
s->setValue(QLatin1String("ProjectExplorer/StartupSession"), SessionManager::activeSession());
|
||||
if (!SessionManager::isDefaultVirgin())
|
||||
s->setValue(QLatin1String("ProjectExplorer/StartupSession"), SessionManager::activeSession());
|
||||
s->remove(QLatin1String("ProjectExplorer/RecentProjects/Files"));
|
||||
|
||||
QStringList fileNames;
|
||||
|
||||
Reference in New Issue
Block a user