summaryrefslogtreecommitdiff
path: root/js
diff options
context:
space:
mode:
authorAndrew Dolgov <[email protected]>2013-04-06 10:33:30 +0400
committerAndrew Dolgov <[email protected]>2013-04-06 10:33:30 +0400
commit2b28c8f2da94c5cac2aacf13d83d370df11f29f3 (patch)
tree2306c54f362d8f2e7cef2bb0a923b100d3fded37 /js
parentef74a05ea2080b715e79459c45787cb4118bed33 (diff)
try to fill the buffer with headlines if possible
Diffstat (limited to 'js')
-rw-r--r--js/viewfeed.js10
1 files changed, 10 insertions, 0 deletions
diff --git a/js/viewfeed.js b/js/viewfeed.js
index db1a4bf94..77ec5ce06 100644
--- a/js/viewfeed.js
+++ b/js/viewfeed.js
@@ -210,6 +210,16 @@ function headlines_callback2(transport, offset, background, infscroll_req) {
unpackVisibleHeadlines();
+ // if we have some more space in the buffer, why not try to fill it
+
+ if (!_infscroll_disable && $("headlines-spacer").offsetTop <
+ $("headlines-frame").offsetHeight) {
+
+ window.setTimeout(function() {
+ loadMoreHeadlines();
+ }, 250);
+ }
+
notify("");
} catch (e) {