diff options
author | Eike Ziller <eike.ziller@qt.io> | 2019-01-28 12:46:30 +0100 |
---|---|---|
committer | Eike Ziller <eike.ziller@qt.io> | 2019-01-31 10:32:36 +0000 |
commit | d386b3c2412c4e0fb2dd32a51ebcf83ca2a32442 (patch) | |
tree | a3eada8f38760995a126bab80a169aa2064ac9ea /src/plugins/help/localhelpmanager.cpp | |
parent | 1dee275f58e9f9df2e2719325157cfdec42fe1cf (diff) | |
download | qt-creator-d386b3c2412c4e0fb2dd32a51ebcf83ca2a32442.tar.gz |
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>
Diffstat (limited to 'src/plugins/help/localhelpmanager.cpp')
-rw-r--r-- | src/plugins/help/localhelpmanager.cpp | 18 |
1 files changed, 0 insertions, 18 deletions
diff --git a/src/plugins/help/localhelpmanager.cpp b/src/plugins/help/localhelpmanager.cpp index 731d938873..3f698f2f28 100644 --- a/src/plugins/help/localhelpmanager.cpp +++ b/src/plugins/help/localhelpmanager.cpp @@ -302,24 +302,6 @@ BookmarkManager& LocalHelpManager::bookmarkManager() return *m_bookmarkManager; } -/*! - * Checks if the string does contain a scheme, and if that scheme is a "sensible" scheme for - * opening in a internal or external browser (qthelp, about, file, http, https). - * This is necessary to avoid trying to open e.g. "Foo::bar" in a external browser. - */ -bool LocalHelpManager::isValidUrl(const QString &link) -{ - QUrl url(link); - if (!url.isValid()) - return false; - const QString scheme = url.scheme(); - return (scheme == "qthelp" - || scheme == "about" - || scheme == "file" - || scheme == "http" - || scheme == "https"); -} - QByteArray LocalHelpManager::loadErrorMessage(const QUrl &url, const QString &errorString) { const char g_htmlPage[] = |