forked from organicmaps/organicmaps
[editor] Correctly process created features in the Index.
This commit is contained in:
parent
36b83eb5c9
commit
7847d189c7
2 changed files with 3 additions and 3 deletions
|
@ -109,7 +109,7 @@ void Index::FeaturesLoaderGuard::GetFeatureByIndex(uint32_t index, FeatureType &
|
|||
{
|
||||
MwmId const & id = m_handle.GetId();
|
||||
ASSERT_NOT_EQUAL(osm::Editor::FeatureStatus::Deleted, m_editor.GetFeatureStatus(id, index),
|
||||
("Deleted feature was cached. Please review your code."));
|
||||
("Deleted feature was cached. It should not be here. Please review your code."));
|
||||
if (!m_editor.Instance().GetEditedFeature(id, index, ft))
|
||||
GetOriginalFeatureByIndex(index, ft);
|
||||
}
|
||||
|
|
|
@ -229,9 +229,9 @@ public:
|
|||
{
|
||||
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."));
|
||||
("Deleted feature was cached. It should not be here. Please review your code."));
|
||||
FeatureType featureType;
|
||||
if (fts == osm::Editor::FeatureStatus::Modified)
|
||||
if (fts == osm::Editor::FeatureStatus::Modified || fts == osm::Editor::FeatureStatus::Created)
|
||||
{
|
||||
VERIFY(editor.GetEditedFeature(id, fidIter->m_index, featureType), ());
|
||||
}
|
||||
|
|
Loading…
Add table
Reference in a new issue