forked from qt-creator/qt-creator
ProjectExplorer: Emit activeBuildConfigurationChanged on project restore
Change-Id: Id5f2d8b36d99df1ffc6e4e0d8a680b55e57c336e Reviewed-by: hjk <hjk@qt.io>
This commit is contained in:
@@ -557,12 +557,20 @@ void Project::saveSettings()
|
||||
|
||||
Project::RestoreResult Project::restoreSettings(QString *errorMessage)
|
||||
{
|
||||
BuildConfiguration *oldBc = activeTarget() ? activeTarget()->activeBuildConfiguration()
|
||||
: nullptr;
|
||||
|
||||
if (!d->m_accessor)
|
||||
d->m_accessor = std::make_unique<Internal::UserFileAccessor>(this);
|
||||
QVariantMap map(d->m_accessor->restoreSettings(Core::ICore::mainWindow()));
|
||||
RestoreResult result = fromMap(map, errorMessage);
|
||||
if (result == RestoreResult::Ok)
|
||||
emit settingsLoaded();
|
||||
|
||||
BuildConfiguration *bc = activeTarget() ? activeTarget()->activeBuildConfiguration() : nullptr;
|
||||
if (bc != oldBc)
|
||||
emit activeBuildConfigurationChanged(bc);
|
||||
|
||||
return result;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user