forked from qt-creator/qt-creator
Help: Do not try to open folder
We end up using a system editor or the question which tool to use when trying to open a fake help item. Fixes: QTCREATORBUG-31178 Change-Id: I21b7c98a7ea0c2b442ad8b733477c725f96e80e1 Reviewed-by: Eike Ziller <eike.ziller@qt.io>
This commit is contained in:
@@ -136,6 +136,9 @@ bool HelpViewer::launchWithExternalApp(const QUrl &url)
|
|||||||
// QHelpEngineCore::findFile returns a valid url even though the file does not exist
|
// QHelpEngineCore::findFile returns a valid url even though the file does not exist
|
||||||
if (resolvedUrl.scheme() == "about" && resolvedUrl.path() == "blank")
|
if (resolvedUrl.scheme() == "about" && resolvedUrl.path() == "blank")
|
||||||
return false;
|
return false;
|
||||||
|
// fake items have no associated file - they are kind of virtual folders
|
||||||
|
if (resolvedUrl.fileName().isEmpty())
|
||||||
|
return false;
|
||||||
|
|
||||||
const QString& path = resolvedUrl.path();
|
const QString& path = resolvedUrl.path();
|
||||||
if (!canOpenPage(path)) {
|
if (!canOpenPage(path)) {
|
||||||
|
Reference in New Issue
Block a user