mirror of
https://github.com/Screenly/Anthias.git
synced 2026-05-06 14:25:33 -04:00
some fixes
This commit is contained in:
@@ -1,5 +1,4 @@
|
||||
set show_status = 0
|
||||
set ssl_verify = 1
|
||||
set on_event = request ON_EVENT
|
||||
|
||||
@on_event LOAD_START js alert=function(e){return true};confirm=function(e){return true};prompt=function(e){return true};
|
||||
|
||||
@@ -250,13 +250,13 @@ def browser_send(command, cb=lambda _: True):
|
||||
browser.process.stdin.put(command + '\n')
|
||||
while True: # loop until cb returns True
|
||||
try:
|
||||
event = browser.next()
|
||||
browser_event = browser.next()
|
||||
except StopIteration:
|
||||
break
|
||||
if 'FOCUS_LOST' in event:
|
||||
if 'FOCUS_LOST' in str(browser_event):
|
||||
browser_focus_lost = True
|
||||
break
|
||||
if cb(event):
|
||||
if cb(browser_event):
|
||||
break
|
||||
else:
|
||||
logging.info('browser found dead, restarting')
|
||||
|
||||
Reference in New Issue
Block a user