ProjectExplorer: Replace ToolChainFactory::canRestore

... by a member-based check.

Change-Id: Id7d19e488695e76ea17cf2d02c7b6eb2cd0246cc
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
This commit is contained in:
hjk
2019-05-08 14:56:26 +02:00
parent e919a9f545
commit 78fd99f5d3
21 changed files with 36 additions and 99 deletions

View File

@@ -43,6 +43,7 @@ namespace Nim {
NimToolChainFactory::NimToolChainFactory()
{
setDisplayName(tr("Nim"));
setSupportedToolChainType(Constants::C_NIMTOOLCHAIN_TYPEID);
}
bool NimToolChainFactory::canCreate()
@@ -59,11 +60,6 @@ ToolChain *NimToolChainFactory::create(Core::Id l)
return result;
}
bool NimToolChainFactory::canRestore(const QVariantMap &data)
{
return typeIdFromMap(data) == Constants::C_NIMTOOLCHAIN_TYPEID;
}
ToolChain *NimToolChainFactory::restore(const QVariantMap &data)
{
auto tc = new NimToolChain(ToolChain::AutoDetection);