Fix Auto Scroll.
This commit is contained in:
parent
eb64392145
commit
39e33ddccf
@ -325,9 +325,10 @@ ThreadUpdater =
|
|||||||
scroll = Conf['Auto Scroll'] and ThreadUpdater.scrollBG() and
|
scroll = Conf['Auto Scroll'] and ThreadUpdater.scrollBG() and
|
||||||
ThreadUpdater.root.getBoundingClientRect().bottom - doc.clientHeight < 25
|
ThreadUpdater.root.getBoundingClientRect().bottom - doc.clientHeight < 25
|
||||||
|
|
||||||
|
firstPost = null
|
||||||
for post in posts
|
for post in posts
|
||||||
root = post.nodes.root
|
|
||||||
unless QuoteThreading.insert post
|
unless QuoteThreading.insert post
|
||||||
|
firstPost or= post.nodes.root
|
||||||
$.add ThreadUpdater.root, post.nodes.root
|
$.add ThreadUpdater.root, post.nodes.root
|
||||||
$.event 'PostsInserted'
|
$.event 'PostsInserted'
|
||||||
|
|
||||||
@ -335,7 +336,7 @@ ThreadUpdater =
|
|||||||
if Conf['Bottom Scroll']
|
if Conf['Bottom Scroll']
|
||||||
window.scrollTo 0, d.body.clientHeight
|
window.scrollTo 0, d.body.clientHeight
|
||||||
else
|
else
|
||||||
Header.scrollTo root if root
|
Header.scrollTo firstPost if firstPost
|
||||||
|
|
||||||
# Update IP count in original post form.
|
# Update IP count in original post form.
|
||||||
if OP.unique_ips? and ipCountEl = $.id('unique-ips')
|
if OP.unique_ips? and ipCountEl = $.id('unique-ips')
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user