@page bottom, next thread -> next page
This commit is contained in:
parent
4198365ab4
commit
dfed85d6d1
@ -827,9 +827,11 @@
|
||||
window.scrollTo(0, 0);
|
||||
return;
|
||||
}
|
||||
if (i === nav.threads.length) {
|
||||
window.location = "" + (g.PAGENUM + 1) + "#p0";
|
||||
return;
|
||||
if (delta === +1) {
|
||||
if (i === nav.threads.length || (innerHeight + pageYOffset === d.body.scrollHeight)) {
|
||||
window.location = "" + (g.PAGENUM + 1) + "#p0";
|
||||
return;
|
||||
}
|
||||
}
|
||||
top = nav.threads[i].getBoundingClientRect().top;
|
||||
return window.scrollBy(0, top);
|
||||
|
||||
@ -615,9 +615,12 @@ nav =
|
||||
if i is -1
|
||||
window.scrollTo 0, 0
|
||||
return
|
||||
if i is nav.threads.length
|
||||
window.location = "#{g.PAGENUM + 1}#p0"
|
||||
return
|
||||
if delta is +1
|
||||
# if we're at the last thread, or we're at the bottom of the page.
|
||||
# kind of hackish, what we really need to do is make nav.getThread smarter.
|
||||
if i is nav.threads.length or (innerHeight + pageYOffset == d.body.scrollHeight)
|
||||
window.location = "#{g.PAGENUM + 1}#p0"
|
||||
return
|
||||
|
||||
{top} = nav.threads[i].getBoundingClientRect()
|
||||
window.scrollBy 0, top
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user