From d99dcaafdccedc946a11285b80d017d16b98c320 Mon Sep 17 00:00:00 2001 From: Damien Elmes Date: Mon, 17 Jul 2017 12:40:38 +1000 Subject: [PATCH] don't open separate browser window on iframe load https://anki.tenderapp.com/discussions/beta-testing/627-anki-210-beta-1#comment_43008395 --- aqt/webview.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/aqt/webview.py b/aqt/webview.py index 221d39678..e89e20c4a 100644 --- a/aqt/webview.py +++ b/aqt/webview.py @@ -56,6 +56,8 @@ class AnkiWebPage(QWebEnginePage): dict(a=line, b=msg+"\n"))) def acceptNavigationRequest(self, url, navType, isMainFrame): + if not isMainFrame: + return True # load all other links in browser openLink(url) return False