No need to prevent scrolling when using noscript captcha.

This commit is contained in:
ccd0 2015-06-20 18:45:28 -07:00
parent 690005c40e
commit d34944e1c4

View File

@ -133,6 +133,7 @@ QR =
QR.hasFocus = d.activeElement and QR.nodes.el.contains(d.activeElement) QR.hasFocus = d.activeElement and QR.nodes.el.contains(d.activeElement)
QR.nodes.el.classList.toggle 'focus', QR.hasFocus QR.nodes.el.classList.toggle 'focus', QR.hasFocus
# XXX Stop unwanted scrolling due to captcha. # XXX Stop unwanted scrolling due to captcha.
if QR.captcha.isEnabled and !QR.captcha.noscript
if QR.inCaptcha() if QR.inCaptcha()
QR.scrollY = window.scrollY QR.scrollY = window.scrollY
$.on d, 'scroll', QR.scrollLock $.on d, 'scroll', QR.scrollLock