Merge pull request #688 from glutanimate/fix-js-eval-when-setting-content-via-url

Fix premature JS evaluation in views that set content via URL
This commit is contained in:
Damien Elmes 2020-07-17 14:37:02 +10:00 committed by GitHub
commit f45f9b2d34
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -300,6 +300,11 @@ class AnkiWebView(QWebEngineView):
if oldFocus:
oldFocus.setFocus()
def load(self, url: QUrl):
# allow queuing actions when loading url directly
self._domDone = False
super().load(url)
def zoomFactor(self) -> float:
# overridden scale factor?
webscale = os.environ.get("ANKI_WEBSCALE")