Commit 1f014821 authored by Stefano Crocco's avatar Stefano Crocco
Browse files

Revert "Fix focus when opening page in a new tab"

This reverts commit a69162a9.

It seems that this causes issues with links to non-html files. For
- open a web page
- from that page, middle click on a link to another web page to open it
  in another tab
- from the second page, middle click on a link to a PDF file

What should happen is that the PDF file is displayed in a third tab
while the first two tabs remain unchanged. Instead, with original commit
the PDF file is displayed not only in the third tab but also in the
first one.
parent a69162a9
......@@ -866,7 +866,7 @@ bool NewWindowPage::acceptNavigationRequest(const QUrl &url, NavigationType type
KParts::WindowArgs wargs (m_windowArgs);
KParts::ReadOnlyPart* newWindowPart =nullptr;
emit part()->browserExtension()->createNewWindow(url, uargs, bargs, wargs, &newWindowPart);
emit part()->browserExtension()->createNewWindow(QUrl(), uargs, bargs, wargs, &newWindowPart);
qCDebug(WEBENGINEPART_LOG) << "Created new window" << newWindowPart;
if (!newWindowPart) {
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