]> git.wh0rd.org Git - tt-rss.git/commitdiff
tweak auto catchup a bit
authorAndrew Dolgov <fox@madoka.volgo-balt.ru>
Fri, 25 Nov 2011 05:51:47 +0000 (09:51 +0400)
committerAndrew Dolgov <fox@madoka.volgo-balt.ru>
Fri, 25 Nov 2011 05:51:47 +0000 (09:51 +0400)
viewfeed.js

index d5b92ebe371088a20214dd3e4452d3c47786e5c0..360384c179e024cc8288083b273936af16437f93 100644 (file)
@@ -1108,6 +1108,7 @@ function headlines_scroll_handler(e) {
                                                __("Loading, please wait...");
 
                                loadMoreHeadlines();
+                               return;
 
                        }
                } else {
@@ -1125,13 +1126,18 @@ function headlines_scroll_handler(e) {
 
                                                if (catchup_id_batch.indexOf(id) == -1)
                                                        catchup_id_batch.push(id);
+
+                                               //console.log("auto_catchup_batch: " + catchup_id_batch.toString());
                                        }
                                });
 
-                       if (catchup_id_batch.length > 0 && !_infscroll_request_sent) {
+                       if (catchup_id_batch.length > 0) {
                                window.clearTimeout(catchup_timeout_id);
-                               catchup_timeout_id = window.setTimeout('catchupBatchedArticles()',
-                                               1000);
+
+                               if (!_infscroll_request_sent) {
+                                       catchup_timeout_id = window.setTimeout('catchupBatchedArticles()',
+                                               2000);
+                               }
                        }
                }