summaryrefslogtreecommitdiffstats
path: root/examples/help/contextsensitivehelp
diff options
context:
space:
mode:
Diffstat (limited to 'examples/help/contextsensitivehelp')
-rw-r--r--examples/help/contextsensitivehelp/helpbrowser.cpp7
1 files changed, 4 insertions, 3 deletions
diff --git a/examples/help/contextsensitivehelp/helpbrowser.cpp b/examples/help/contextsensitivehelp/helpbrowser.cpp
index 0eb983c05..f0cc4a1d7 100644
--- a/examples/help/contextsensitivehelp/helpbrowser.cpp
+++ b/examples/help/contextsensitivehelp/helpbrowser.cpp
@@ -53,6 +53,7 @@
#include <QtHelp/QHelpEngineCore>
#include "helpbrowser.h"
+#include "qhelplink.h"
HelpBrowser::HelpBrowser(QWidget *parent)
: QTextBrowser(parent)
@@ -70,9 +71,9 @@ HelpBrowser::HelpBrowser(QWidget *parent)
void HelpBrowser::showHelpForKeyword(const QString &id)
{
if (m_helpEngine) {
- QMultiMap<QString, QUrl> links = m_helpEngine->linksForIdentifier(id);
- if (links.count())
- setSource(links.constBegin().value());
+ QList<QHelpLink> documents = m_helpEngine->documentsForIdentifier(id);
+ if (documents.count())
+ setSource(documents.first().url);
}
}