| 87 | } |
| 88 | |
| 89 | void DocumentationQuickOpenProvider::setFilterText(const QString& text) |
| 90 | { |
| 91 | if (text.size() < 2) { |
| 92 | return; |
| 93 | } |
| 94 | m_results.clear(); |
| 95 | int split = 0; |
| 96 | const QList<IDocumentationProvider*> providers = ICore::self()->documentationController()->documentationProviders(); |
| 97 | for (IDocumentationProvider* p : providers) { |
| 98 | QList<QModelIndex> idxs; |
| 99 | int internalSplit = 0; |
| 100 | int i = 0; |
| 101 | matchingIndexes(p->indexModel(), text, QModelIndex(), idxs, internalSplit); |
| 102 | for (const QModelIndex& idx : std::as_const(idxs)) { |
| 103 | m_results.insert(split + i, QuickOpenDataPointer(new DocumentationQuickOpenItem(idx, p))); |
| 104 | i++; |
| 105 | } |
| 106 | |
| 107 | split += internalSplit; |
| 108 | } |
| 109 | } |
| 110 | |
| 111 | uint DocumentationQuickOpenProvider::unfilteredItemCount() const |
| 112 | { |
nothing calls this directly
no test coverage detected