Commit ada14482 authored by Stefano Crocco's avatar Stefano Crocco
Browse files

Force using WebEnginePart to open konq: URLS

Without this, if the default HTML engine isn't WebEnginePart, when
opening a konq: URL, the user would get an error. Forcing the use of
WebEnginePart provides a workaround for this issue.

BUG: 424848
parent bdb464bc
......@@ -810,6 +810,14 @@ bool KonqMainWindow::openView(QString mimeType, const QUrl &_url, KonqView *chil
QString serviceName = req.serviceName; // default: none provided
//Force use of WebEnginePart when opening a konq: URL. If the user chose a different
//default HTML engine, they would get an error because they don't know how to handle
//such scheme. As a workaround, in this case we force the use of WebEnginePart
if (KonqUrl::hasKonqScheme(url)) {
serviceName = "webenginepart";
const QString urlStr = url.url();
if (KonqUrl::isValidNotBlank(urlStr)) {
mimeType = QStringLiteral("text/html");
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment