Merge branch 'v3' of git://github.com/zixaphir/appchan-x
This commit is contained in:
commit
b922110a59
@ -3267,8 +3267,11 @@
|
||||
if (!(rect.top <= 0 || rect.left <= 0)) {
|
||||
return;
|
||||
}
|
||||
headRect = Header.bar.getBoundingClientRect();
|
||||
top = rect.top - headRect.top - headRect.height;
|
||||
top = rect.top;
|
||||
if (Conf['Fixed Header'] && !Conf['Bottom Header']) {
|
||||
headRect = Header.bar.getBoundingClientRect();
|
||||
top += -headRect.top - headRect.height;
|
||||
}
|
||||
root = doc;
|
||||
if (rect.top < 0) {
|
||||
root.scrollTop += top;
|
||||
|
||||
@ -3258,8 +3258,11 @@
|
||||
if (!(rect.top <= 0 || rect.left <= 0)) {
|
||||
return;
|
||||
}
|
||||
headRect = Header.bar.getBoundingClientRect();
|
||||
top = rect.top - headRect.top - headRect.height;
|
||||
top = rect.top;
|
||||
if (Conf['Fixed Header'] && !Conf['Bottom Header']) {
|
||||
headRect = Header.bar.getBoundingClientRect();
|
||||
top += -headRect.top - headRect.height;
|
||||
}
|
||||
root = doc;
|
||||
if (rect.top < 0) {
|
||||
root.scrollTop += top;
|
||||
|
||||
@ -3122,8 +3122,11 @@
|
||||
if (!(rect.top <= 0 || rect.left <= 0)) {
|
||||
return;
|
||||
}
|
||||
headRect = Header.bar.getBoundingClientRect();
|
||||
top = rect.top - headRect.top - headRect.height;
|
||||
top = rect.top;
|
||||
if (Conf['Fixed Header'] && !Conf['Bottom Header']) {
|
||||
headRect = Header.bar.getBoundingClientRect();
|
||||
top += -headRect.top - headRect.height;
|
||||
}
|
||||
root = d.body;
|
||||
if (rect.top < 0) {
|
||||
root.scrollTop += top;
|
||||
|
||||
@ -71,10 +71,11 @@ ImageExpand =
|
||||
rect = post.nodes.root.getBoundingClientRect()
|
||||
return unless rect.top <= 0 or rect.left <= 0
|
||||
|
||||
# Scroll back to the thumbnail when contracting the image
|
||||
# to avoid being left miles away from the relevant post.
|
||||
headRect = Header.bar.getBoundingClientRect()
|
||||
top = rect.top - headRect.top - headRect.height
|
||||
{top} = rect
|
||||
if Conf['Fixed Header'] and not Conf['Bottom Header']
|
||||
headRect = Header.bar.getBoundingClientRect()
|
||||
top += - headRect.top - headRect.height
|
||||
|
||||
root = <% if (type === 'crx') { %>d.body<% } else { %>doc<% } %>
|
||||
|
||||
root.scrollTop += top if rect.top < 0
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user