summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--tools/assistant/tools/assistant/helpviewer.cpp4
-rw-r--r--tools/assistant/tools/assistant/helpviewer_qwv.cpp7
2 files changed, 5 insertions, 6 deletions
diff --git a/tools/assistant/tools/assistant/helpviewer.cpp b/tools/assistant/tools/assistant/helpviewer.cpp
index 22b3f30..25214e2 100644
--- a/tools/assistant/tools/assistant/helpviewer.cpp
+++ b/tools/assistant/tools/assistant/helpviewer.cpp
@@ -52,9 +52,7 @@
QT_BEGIN_NAMESPACE
-QString AbstractHelpViewer::DocPath = QString::fromLatin1("qthelp://com."
- "trolltech.qt.%1/").arg(QString(QLatin1String(QT_VERSION_STR))
- .replace(QLatin1String("."), QLatin1String("")));
+QString AbstractHelpViewer::DocPath = QString::fromLatin1("qthelp://com.trolltech.");
QString AbstractHelpViewer::AboutBlank =
QCoreApplication::translate("HelpViewer", "<title>about:blank</title>");
diff --git a/tools/assistant/tools/assistant/helpviewer_qwv.cpp b/tools/assistant/tools/assistant/helpviewer_qwv.cpp
index a19b29a..585c69d 100644
--- a/tools/assistant/tools/assistant/helpviewer_qwv.cpp
+++ b/tools/assistant/tools/assistant/helpviewer_qwv.cpp
@@ -139,9 +139,10 @@ QNetworkReply *HelpNetworkAccessManager::createRequest(Operation /*op*/,
// the virtual folder
if (!helpEngine.findFile(url).isValid()) {
if (url.startsWith(AbstractHelpViewer::DocPath)) {
- if (!url.startsWith(AbstractHelpViewer::DocPath + QLatin1String("qdoc/"))) {
- url = url.replace(AbstractHelpViewer::DocPath,
- AbstractHelpViewer::DocPath + QLatin1String("qdoc/"));
+ QUrl newUrl = request.url();
+ if (!newUrl.path().startsWith(QLatin1String("/qdoc/"))) {
+ newUrl.setPath(QLatin1String("/qdoc/")+newUrl.path());
+ url = newUrl.toString();
}
}
}