Fix loading icon getting stuck on in Firefox. #832
This commit is contained in:
parent
46a065156b
commit
19a57d5737
@ -2,7 +2,11 @@ ThreadUpdater =
|
||||
init: ->
|
||||
return if g.VIEW isnt 'thread' or !Conf['Thread Updater']
|
||||
|
||||
@audio = $.el 'audio', src: ThreadUpdater.beep
|
||||
# Chromium won't play audio created in an inactive tab until the tab has been focused, so set it up now.
|
||||
# XXX Sometimes the loading stalls in Firefox, esp. when opening in private browsing window followed by normal window.
|
||||
# Don't let it keep the loading icon on indefinitely.
|
||||
@audio = $.el 'audio'
|
||||
@audio.src = @beep unless $.engine is 'gecko'
|
||||
|
||||
if Conf['Updater and Stats in Header']
|
||||
@dialog = sc = $.el 'span',
|
||||
@ -90,6 +94,7 @@ ThreadUpdater =
|
||||
|
||||
playBeep: ->
|
||||
{audio} = ThreadUpdater
|
||||
audio.src or= ThreadUpdater.beep
|
||||
if audio.paused
|
||||
audio.play()
|
||||
else
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user