diff options
author | Sergey Magidovich <mgsergio@mapswithme.com> | 2016-01-06 11:30:41 +0300 |
---|---|---|
committer | Sergey Yershov <yershov@corp.mail.ru> | 2016-03-23 16:04:20 +0300 |
commit | cf2302d03418bef2ed6399df84b55ef41bf0b6da (patch) | |
tree | 0dd1aec52643de78fd4786e1ab46a015dc6f6e0a /indexer/index.hpp | |
parent | ef1e40d052042e91f5d5ed836cb3f1d656caee5d (diff) |
Do not create node features from xml for now. Patch everything.
Diffstat (limited to 'indexer/index.hpp')
-rw-r--r-- | indexer/index.hpp | 34 |
1 files changed, 19 insertions, 15 deletions
diff --git a/indexer/index.hpp b/indexer/index.hpp index f22681382d..08b1c9474f 100644 --- a/indexer/index.hpp +++ b/indexer/index.hpp @@ -137,14 +137,14 @@ private: FeatureType feature; switch (m_editor.GetFeatureStatus(mwmID, index)) { - case osm::Editor::FeatureStatus::Deleted: return; - case osm::Editor::FeatureStatus::Modified: - VERIFY(m_editor.GetEditedFeature(mwmID, index, feature), ()); - m_f(feature); - return; - case osm::Editor::FeatureStatus::Created: - CHECK(false, ("Created features index should be generated.")); - case osm::Editor::FeatureStatus::Untouched: break; + case osm::Editor::FeatureStatus::Deleted: return; + case osm::Editor::FeatureStatus::Modified: + VERIFY(m_editor.GetEditedFeature(mwmID, index, feature), ()); + m_f(feature); + return; + case osm::Editor::FeatureStatus::Created: + CHECK(false, ("Created features index should be generated.")); + case osm::Editor::FeatureStatus::Untouched: break; } if (checkUnique(index)) { @@ -196,12 +196,15 @@ private: for (auto const & i : interval) { - index.ForEachInIntervalAndScale([&] (uint32_t index) - { - if (osm::Editor::FeatureStatus::Deleted != m_editor.GetFeatureStatus(mwmID, index) && - checkUnique(index)) - m_f(FeatureID(mwmID, index)); - }, i.first, i.second, scale); + index.ForEachInIntervalAndScale( + [&](uint32_t index) + { + if (osm::Editor::FeatureStatus::Deleted != + m_editor.GetFeatureStatus(mwmID, index) && + checkUnique(index)) + m_f(FeatureID(mwmID, index)); + }, + i.first, i.second, scale); } } } @@ -248,7 +251,8 @@ public: do { osm::Editor::FeatureStatus const fts = editor.GetFeatureStatus(id, fidIter->m_index); - ASSERT_NOT_EQUAL(osm::Editor::FeatureStatus::Deleted, fts, ("Deleted feature was cached. Please review your code.")); + ASSERT_NOT_EQUAL(osm::Editor::FeatureStatus::Deleted, fts, + ("Deleted feature was cached. Please review your code.")); FeatureType featureType; if (fts == osm::Editor::FeatureStatus::Modified) { |