Details
Description
This issue is an followup to QTBUG-87235(duplicate of QTBUG-85494)
While the patch solves the segfault (as mentioned in QTBUG-85494), now it is causing another unexpected behaviour.
Problem : When a new view request is received, if there are no `request.openIn` call made, it forcefully loads the new view in the existing webengineview instead of ignoring the request. Right now there is no way to block a new view request.
Expected : If there are no `request.openIn` calls, it should block the new view request or maybe there should be `request.accepted` flag to control the behaviour.
Simple Example :
test.html
<html> <body> <a href="https://google.com">Google</a> </body> </html>
WebEngineView { id: webengine anchors.fill: parent url: "/path/to/test.html" onNewViewRequested: { console.log("New View Requested but cannot ignore request"); } }
Load the test.html page in the WebEngineView and Ctrl+Click the link to reproduce the error