MCPcopy Create free account
hub / github.com/comaps/comaps / SetChildCategoriesVisibility

Method SetChildCategoriesVisibility

libs/map/bookmark_manager.cpp:3265–3288  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

3263}
3264
3265void BookmarkManager::SetChildCategoriesVisibility(kml::MarkGroupId categoryId, kml::CompilationType compilationType,
3266 bool visible)
3267{
3268 CHECK_THREAD_CHECKER(m_threadChecker, ());
3269 auto session = GetEditSession();
3270 auto const categoryIt = m_categories.find(categoryId);
3271 CHECK(categoryIt != m_categories.end(), ());
3272 auto & category = *categoryIt->second;
3273 for (kml::MarkGroupId const compilationId : category.GetCategoryData().m_compilationIds)
3274 {
3275 auto const compilationIt = m_compilations.find(compilationId);
3276 CHECK(compilationIt != m_compilations.cend(), ());
3277 auto & compilation = *compilationIt->second;
3278 if (compilation.GetCategoryData().m_type != compilationType)
3279 continue;
3280 if (visible != compilation.IsVisible())
3281 {
3282 compilation.SetIsVisible(visible);
3283 category.SetDirty(false /* updateModificationTime */);
3284 if (visible)
3285 category.SetIsVisible(true);
3286 }
3287 }
3288}
3289
3290void BookmarkManager::SetNotificationsEnabled(bool enabled)
3291{

Callers

nothing calls this directly

Calls 6

findMethod · 0.45
endMethod · 0.45
cendMethod · 0.45
IsVisibleMethod · 0.45
SetIsVisibleMethod · 0.45
SetDirtyMethod · 0.45

Tested by

no test coverage detected