From 34cc018629e49bb98536b278a4dc05eae22bbf92 Mon Sep 17 00:00:00 2001 From: map-per Date: Sat, 28 Sep 2024 19:10:55 +0200 Subject: [PATCH] update place page after edit Signed-off-by: map-per --- map/framework.cpp | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/map/framework.cpp b/map/framework.cpp index 2976f18b2f..6c98e8e030 100644 --- a/map/framework.cpp +++ b/map/framework.cpp @@ -3070,15 +3070,15 @@ osm::Editor::SaveResult Framework::SaveEditedMapObject(osm::EditableMapObject em auto const result = osm::Editor::Instance().SaveEditedFeature(emo); - // Automatically select newly created objects. - if (!m_currentPlacePageInfo) - { - place_page::BuildInfo info; - info.m_mercator = emo.GetMercator(); - info.m_featureId = emo.GetID(); - m_currentPlacePageInfo = BuildPlacePageInfo(info); - ActivateMapSelection(); - } + // Automatically select newly created and edited objects. + if (m_currentPlacePageInfo) + DeactivateMapSelection(); + + place_page::BuildInfo info; + info.m_mercator = emo.GetMercator(); + info.m_featureId = emo.GetID(); + m_currentPlacePageInfo = BuildPlacePageInfo(info); + ActivateMapSelection(); return result; }