forked from qt-creator/qt-creator
Help: Avoid ambiguity of help ID being interpreted as URL
Users know if they have a URL or not, we should not guess (and then even guess differently at different places) Change-Id: Iaaf69a94baadbee0ff427a2bc9065b714dcf8478 Reviewed-by: David Schulz <david.schulz@qt.io>
This commit is contained in:
@@ -190,9 +190,11 @@ bool QmlJSHoverHandler::setQmlTypeHelp(const ScopeChain &scopeChain, const Docum
|
||||
filteredUrlMap.insert(x.key(), x.value());
|
||||
}
|
||||
if (!filteredUrlMap.isEmpty()) {
|
||||
// Use the url as helpId, to disambiguate different versions
|
||||
helpId = filteredUrlMap.first().toString();
|
||||
const HelpItem helpItem(helpId, qName.join(QLatin1Char('.')), HelpItem::QmlComponent, filteredUrlMap);
|
||||
// Use the URL, to disambiguate different versions
|
||||
const HelpItem helpItem(filteredUrlMap.first(),
|
||||
qName.join(QLatin1Char('.')),
|
||||
HelpItem::QmlComponent,
|
||||
filteredUrlMap);
|
||||
setLastHelpItemIdentified(helpItem);
|
||||
return true;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user