| 86 | } |
| 87 | |
| 88 | void Processor::EnableIndexingOfBookmarkGroup(GroupId const & groupId, bool enable) |
| 89 | { |
| 90 | bool const wasIndexable = m_indexableGroups.count(groupId) > 0; |
| 91 | if (enable) |
| 92 | m_indexableGroups.insert(groupId); |
| 93 | else |
| 94 | m_indexableGroups.erase(groupId); |
| 95 | bool const nowIndexable = m_indexableGroups.count(groupId) > 0; |
| 96 | |
| 97 | if (wasIndexable == nowIndexable) |
| 98 | return; |
| 99 | |
| 100 | for (auto const & id : m_bookmarksInGroup[groupId]) |
| 101 | if (nowIndexable) |
| 102 | AddToIndex(id); |
| 103 | else |
| 104 | EraseFromIndex(id); |
| 105 | } |
| 106 | |
| 107 | void Processor::Add(Id const & id, Doc const & doc) |
| 108 | { |