]> git.wh0rd.org Git - tt-rss.git/commitdiff
fix infinite scrolling not working
authorAndrew Dolgov <fox@madoka.volgo-balt.ru>
Wed, 17 Nov 2010 08:34:55 +0000 (11:34 +0300)
committerAndrew Dolgov <fox@madoka.volgo-balt.ru>
Wed, 17 Nov 2010 08:34:55 +0000 (11:34 +0300)
tt-rss.php
viewfeed.js

index 98e68af4b05caf656e0baec8571096c6ad524465..5dc2a72442ac03b08d135138722cbdff618d9557 100644 (file)
                <div id="headlines-toolbar" dojoType="dijit.layout.ContentPane" region="top">
                </div>
 
-               <div id="headlines-frame" dojoType="dijit.layout.ContentPane" region="center">
+               <div id="headlines-frame" dojoType="dijit.layout.ContentPane" 
+                               onscroll="headlines_scroll_handler(this)" region="center">
                        <div id="headlinesInnerContainer">
                                <div class="whiteBox"><?php echo __('Loading, please wait...') ?></div>
                        </div>
index 22465013e0d90c1b5f20e6c7f08ef90b963216f8..99e8dffcfc839e81ed035b3520c77241a109780b 100644 (file)
@@ -133,7 +133,7 @@ function headlines_callback2(transport, feed_cur_page) {
 
                                                var ids = getSelectedArticleIds2();
        
-                                               c.innerHTML = c.innerHTML + headlines.firstChild.nodeValue;
+                                               c.innerHTML = c.innerHTML + headlines_content.firstChild.nodeValue;
 
                                                console.log("restore selected ids: " + ids);
 
@@ -1513,16 +1513,9 @@ function postMouseOut(id) {
        }
 }
 
-function headlines_scroll_handler() {
+function headlines_scroll_handler(e) {
        try {
 
-               var e = $("headlinesInnerContainer");
-
-               var toolbar_form = document.forms["main_toolbar_form"];
-
-//             console.log((e.scrollTop + e.offsetHeight) + " vs " + e.scrollHeight + " dis? " +
-//                     _infscroll_disable);
-
                if (e.scrollTop + e.offsetHeight > e.scrollHeight - 100) {
                        if (!_infscroll_disable) {
                                viewNextFeedPage();