don't translate js console msgs
This commit is contained in:
parent
072489f436
commit
718b4b35d1
@ -50,9 +50,10 @@ class AnkiWebPage(QWebEnginePage):
|
|||||||
self.profile().scripts().insert(script)
|
self.profile().scripts().insert(script)
|
||||||
|
|
||||||
def javaScriptConsoleMessage(self, lvl, msg, line, srcID):
|
def javaScriptConsoleMessage(self, lvl, msg, line, srcID):
|
||||||
sys.stdout.write(
|
# not translated because console usually not visible,
|
||||||
(_("JS error on line %(a)d: %(b)s") %
|
# and may only accept ascii text
|
||||||
dict(a=line, b=msg+"\n")))
|
sys.stdout.write("JS error on line %(a)d: %(b)s" %
|
||||||
|
dict(a=line, b=msg+"\n"))
|
||||||
|
|
||||||
def acceptNavigationRequest(self, url, navType, isMainFrame):
|
def acceptNavigationRequest(self, url, navType, isMainFrame):
|
||||||
if not isMainFrame:
|
if not isMainFrame:
|
||||||
|
Loading…
Reference in New Issue
Block a user