]> git.wh0rd.org Git - tt-rss.git/commitdiff
when auto selecting, only select articles actually near the buffer top
authorAndrew Dolgov <fox@madoka.volgo-balt.ru>
Thu, 16 May 2013 06:50:36 +0000 (10:50 +0400)
committerAndrew Dolgov <fox@madoka.volgo-balt.ru>
Thu, 16 May 2013 06:50:38 +0000 (10:50 +0400)
js/viewfeed.js

index de3f660bed0b638dcb4c694e7c5f8c210f17fb98..50bec1966ffa2dd990d5c3679c7bf88ac129c58d 100644 (file)
@@ -1247,7 +1247,9 @@ function headlines_scroll_handler(e) {
                        for (var i = 0; i < rows.length; i++) {
                                var child = rows[i];
 
-                               if ($("headlines-frame").scrollTop < child.offsetTop) {
+                               if ($("headlines-frame").scrollTop < child.offsetTop &&
+                                       child.offsetTop - $("headlines-frame").scrollTop < 50) {
+
                                        if (_active_article_id) {
                                                var row = $("RROW-" + _active_article_id);
                                                if (row) row.removeClassName("active");