Merge branch 'v3'

This commit is contained in:
Zixaphir 2013-08-08 17:01:51 -07:00
commit f035dabb9d
4 changed files with 54 additions and 40 deletions

View File

@ -7968,20 +7968,24 @@
i = 0; i = 0;
while (post = posts[i]) { while (post = posts[i]) {
bottom = post.nodes.root.getBoundingClientRect().bottom; bottom = post.nodes.root.getBoundingClientRect().bottom;
if (bottom > height) { if (bottom < height) {
i++; ID = post.ID;
continue; if (Conf['Quote Threading']) {
} posts.splice(i, 1);
ID = post.ID; continue;
if (Conf['Quote Threading']) { }
posts.splice(i, 1);
continue;
} else { } else {
posts.splice(0, i); if (!Conf['Quote Threading']) {
break; break;
}
} }
i++; i++;
} }
if (!Conf['Quote Threading']) {
if (i) {
posts.splice(0, i);
}
}
if (!ID) { if (!ID) {
return; return;
} }

View File

@ -10300,20 +10300,24 @@
i = 0; i = 0;
while (post = posts[i]) { while (post = posts[i]) {
bottom = post.nodes.root.getBoundingClientRect().bottom; bottom = post.nodes.root.getBoundingClientRect().bottom;
if (bottom > height) { if (bottom < height) {
i++; ID = post.ID;
continue; if (Conf['Quote Threading']) {
} posts.splice(i, 1);
ID = post.ID; continue;
if (Conf['Quote Threading']) { }
posts.splice(i, 1);
continue;
} else { } else {
posts.splice(0, i); if (!Conf['Quote Threading']) {
break; break;
}
} }
i++; i++;
} }
if (!Conf['Quote Threading']) {
if (i) {
posts.splice(0, i);
}
}
if (!ID) { if (!ID) {
return; return;
} }

View File

@ -10283,20 +10283,24 @@
i = 0; i = 0;
while (post = posts[i]) { while (post = posts[i]) {
bottom = post.nodes.root.getBoundingClientRect().bottom; bottom = post.nodes.root.getBoundingClientRect().bottom;
if (bottom > height) { if (bottom < height) {
i++; ID = post.ID;
continue; if (Conf['Quote Threading']) {
} posts.splice(i, 1);
ID = post.ID; continue;
if (Conf['Quote Threading']) { }
posts.splice(i, 1);
continue;
} else { } else {
posts.splice(0, i); if (!Conf['Quote Threading']) {
break; break;
}
} }
i++; i++;
} }
if (!Conf['Quote Threading']) {
if (i) {
posts.splice(0, i);
}
}
if (!ID) { if (!ID) {
return; return;
} }

View File

@ -123,18 +123,20 @@ Unread =
while post = posts[i] while post = posts[i]
{bottom} = post.nodes.root.getBoundingClientRect() {bottom} = post.nodes.root.getBoundingClientRect()
if bottom > height # post isnt completely read if bottom < height # post is completely read
i++ {ID} = post
continue if Conf['Quote Threading']
posts.splice i, 1
{ID} = post continue
if Conf['Quote Threading']
posts.splice i, 1
continue
else else
posts.splice 0, i unless Conf['Quote Threading']
break break
i++ i++
unless Conf['Quote Threading']
if i
posts.splice 0, i
return unless ID return unless ID
Unread.lastReadPost = ID if Unread.lastReadPost < ID or !Unread.lastReadPost Unread.lastReadPost = ID if Unread.lastReadPost < ID or !Unread.lastReadPost