summaryrefslogtreecommitdiffstats
path: root/src/assistant/help/qhelpenginecore.cpp
diff options
context:
space:
mode:
authorJarek Kobus <jaroslaw.kobus@qt.io>2020-08-31 10:33:58 +0200
committerJarek Kobus <jaroslaw.kobus@qt.io>2020-09-11 15:35:06 +0200
commitdbe178044b591490cb98c071da8b91342129e030 (patch)
tree26acb80b35eb473ed8f2047b020c3a90729fe6b5 /src/assistant/help/qhelpenginecore.cpp
parent14024df36e7a26b79aa2b0edf82c9b29d9eb0185 (diff)
QtHelp: Fix documentsFor() when not using filter engine
Fixes: QTBUG-84727 Pick-to: 5.15 Change-Id: Id66cc071a24cc761dc63d044b7f74d0e1959cd22 Reviewed-by: Edward Welbourne <edward.welbourne@qt.io> Reviewed-by: Kai Koehne <kai.koehne@qt.io>
Diffstat (limited to 'src/assistant/help/qhelpenginecore.cpp')
-rw-r--r--src/assistant/help/qhelpenginecore.cpp14
1 files changed, 10 insertions, 4 deletions
diff --git a/src/assistant/help/qhelpenginecore.cpp b/src/assistant/help/qhelpenginecore.cpp
index 81e224b37..56137d124 100644
--- a/src/assistant/help/qhelpenginecore.cpp
+++ b/src/assistant/help/qhelpenginecore.cpp
@@ -635,10 +635,13 @@ QList<QHelpLink> QHelpEngineCore::documentsForIdentifier(const QString &id) cons
*/
QList<QHelpLink> QHelpEngineCore::documentsForIdentifier(const QString &id, const QString &filterName) const
{
- if (!d->setup() || !d->usesFilterEngine)
+ if (!d->setup())
return QList<QHelpLink>();
- return d->collectionHandler->documentsForIdentifier(id, filterName);
+ if (d->usesFilterEngine)
+ return d->collectionHandler->documentsForIdentifier(id, filterName);
+
+ return d->collectionHandler->documentsForIdentifier(id, filterAttributes(filterName));
}
/*!
@@ -665,10 +668,13 @@ QList<QHelpLink> QHelpEngineCore::documentsForKeyword(const QString &keyword) co
*/
QList<QHelpLink> QHelpEngineCore::documentsForKeyword(const QString &keyword, const QString &filterName) const
{
- if (!d->setup() || !d->usesFilterEngine)
+ if (!d->setup())
return QList<QHelpLink>();
- return d->collectionHandler->documentsForKeyword(keyword, filterName);
+ if (d->usesFilterEngine)
+ return d->collectionHandler->documentsForKeyword(keyword, filterName);
+
+ return d->collectionHandler->documentsForKeyword(keyword, filterAttributes(filterName));
}
/*!