From 1a5db5d420a5550f6e42cb39cc93eecb9c848788 Mon Sep 17 00:00:00 2001 From: codereader Date: Sat, 22 May 2021 17:59:42 +0200 Subject: [PATCH] #5622: Rename map::algorithm::mergeMap to map::algorithm::importMap to not collide with the upcoming changes --- radiantcore/map/Map.cpp | 3 +-- radiantcore/map/algorithm/Import.cpp | 4 ++-- radiantcore/map/algorithm/Import.h | 4 ++-- 3 files changed, 5 insertions(+), 6 deletions(-) diff --git a/radiantcore/map/Map.cpp b/radiantcore/map/Map.cpp index 9ecac315c7..69ef3be9e5 100644 --- a/radiantcore/map/Map.cpp +++ b/radiantcore/map/Map.cpp @@ -426,7 +426,7 @@ bool Map::import(const std::string& filename) // Adjust all new names to fit into the existing map namespace algorithm::prepareNamesForImport(getRoot(), otherRoot); - algorithm::mergeMap(otherRoot); + algorithm::importMap(otherRoot); success = true; } @@ -944,7 +944,6 @@ void Map::mergeMap(const cmd::ArgumentList& args) throw cmd::ExecutionFailure(fmt::format(_("File doesn't exist: {0}"), candidate)); } - } void Map::emitMapEvent(MapEvent ev) diff --git a/radiantcore/map/algorithm/Import.cpp b/radiantcore/map/algorithm/Import.cpp index 99ae8bb860..990fbc214b 100644 --- a/radiantcore/map/algorithm/Import.cpp +++ b/radiantcore/map/algorithm/Import.cpp @@ -227,7 +227,7 @@ class EntityMerger : } }; -void mergeMap(const scene::INodePtr& node) +void importMap(const scene::INodePtr& node) { if (!GlobalSceneGraph().root()) { @@ -360,7 +360,7 @@ void importFromStream(std::istream& stream) // Adjust all new names to fit into the existing map namespace prepareNamesForImport(GlobalMap().getRoot(), importFilter.getRootNode()); - mergeMap(importFilter.getRootNode()); + importMap(importFilter.getRootNode()); } catch (IMapReader::FailureException& ex) { diff --git a/radiantcore/map/algorithm/Import.h b/radiantcore/map/algorithm/Import.h index 1223622a7f..d9846d6a57 100644 --- a/radiantcore/map/algorithm/Import.h +++ b/radiantcore/map/algorithm/Import.h @@ -21,8 +21,8 @@ typedef std::shared_ptr MapFormatPtr; namespace algorithm { -// Merges the map graph rooted at \p node into the global scene-graph. -void mergeMap(const scene::INodePtr& node); +// Integrates the map graph rooted at \p node into the global scene-graph. +void importMap(const scene::INodePtr& node); /** * Ensures that all names in the foreign root node are adjusted such that