forked from qt-creator/qt-creator
RunConfigurationFactory: Centralize much of the restore code
Change-Id: I30c92dd5082eed050c2796a014919788710baafa Reviewed-by: Daniel Teske <daniel.teske@digia.com>
This commit is contained in:
@@ -462,6 +462,18 @@ RunConfiguration *IRunConfigurationFactory::create(Target *parent, const Core::I
|
||||
return rc;
|
||||
}
|
||||
|
||||
RunConfiguration *IRunConfigurationFactory::restore(Target *parent, const QVariantMap &map)
|
||||
{
|
||||
if (!canRestore(parent, map))
|
||||
return 0;
|
||||
RunConfiguration *rc = doRestore(parent, map);
|
||||
if (!rc->fromMap(map)) {
|
||||
delete rc;
|
||||
rc = 0;
|
||||
}
|
||||
return rc;
|
||||
}
|
||||
|
||||
IRunConfigurationFactory *IRunConfigurationFactory::find(Target *parent, const QVariantMap &map)
|
||||
{
|
||||
QList<IRunConfigurationFactory *> factories
|
||||
|
||||
Reference in New Issue
Block a user