| 3263 | } |
| 3264 | |
| 3265 | void 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 | |
| 3290 | void BookmarkManager::SetNotificationsEnabled(bool enabled) |
| 3291 | { |