summaryrefslogtreecommitdiff
path: root/src/plugins/cppeditor/cpphoverhandler.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/plugins/cppeditor/cpphoverhandler.cpp')
-rw-r--r--src/plugins/cppeditor/cpphoverhandler.cpp15
1 files changed, 8 insertions, 7 deletions
diff --git a/src/plugins/cppeditor/cpphoverhandler.cpp b/src/plugins/cppeditor/cpphoverhandler.cpp
index bd4754c2aa..4135d0b6cc 100644
--- a/src/plugins/cppeditor/cpphoverhandler.cpp
+++ b/src/plugins/cppeditor/cpphoverhandler.cpp
@@ -221,23 +221,24 @@ void CppHoverHandler::updateHelpIdAndTooltip(TextEditor::ITextEditor *editor, in
}
}
+ if (m_helpEngineNeedsSetup
+ && m_helpEngine->registeredDocumentations().count() > 0) {
+ m_helpEngine->setupData();
+ m_helpEngineNeedsSetup = false;
+ }
+ QMap<QString, QUrl> helpLinks;
+
if (m_toolTip.isEmpty()) {
foreach (const Document::Include &incl, doc->includes()) {
if (incl.line() == lineNumber) {
m_toolTip = QDir::toNativeSeparators(incl.fileName());
m_helpId = QFileInfo(incl.fileName()).fileName();
+ helpLinks = m_helpEngine->linksForIdentifier(m_helpId);
break;
}
}
}
- if (m_helpEngineNeedsSetup
- && m_helpEngine->registeredDocumentations().count() > 0) {
- m_helpEngine->setupData();
- m_helpEngineNeedsSetup = false;
- }
-
- QMap<QString, QUrl> helpLinks;
if (m_helpId.isEmpty()) {
// Move to the end of a qualified name
bool stop = false;