diff options
author | Tobias Hunger <tobias.hunger@qt.io> | 2018-04-26 15:07:56 +0200 |
---|---|---|
committer | Tobias Hunger <tobias.hunger@qt.io> | 2018-05-02 14:55:15 +0000 |
commit | d3329545674ba6ee0233477f0821741e496c6b77 (patch) | |
tree | 954c1f17402d3d3c6097c6886300ae5809a36066 /src/plugins/autotoolsprojectmanager | |
parent | f9585d939f6a140ecbf6526d30c294048060b246 (diff) |
ProjectExplorer: Add and use addNestedNode(...) that takes unique_ptr
Change-Id: Ieb26721d053111fb350494e31d1f6da3fe642420
Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
Diffstat (limited to 'src/plugins/autotoolsprojectmanager')
-rw-r--r-- | src/plugins/autotoolsprojectmanager/autotoolsproject.cpp | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/plugins/autotoolsprojectmanager/autotoolsproject.cpp b/src/plugins/autotoolsprojectmanager/autotoolsproject.cpp index d368acd4567..c211fcc471b 100644 --- a/src/plugins/autotoolsprojectmanager/autotoolsproject.cpp +++ b/src/plugins/autotoolsprojectmanager/autotoolsproject.cpp @@ -209,7 +209,8 @@ void AutotoolsProject::makefileParsingFinished() auto newRoot = std::make_unique<AutotoolsProjectNode>(projectDirectory()); for (const QString &f : m_files) { const Utils::FileName path = Utils::FileName::fromString(f); - newRoot->addNestedNode(new FileNode(path, FileNode::fileTypeForFileName(path), false)); + newRoot->addNestedNode(std::make_unique<FileNode>(path, FileNode::fileTypeForFileName(path), + false)); } setRootProjectNode(std::move(newRoot)); |