fix infinite scrolling not working
This commit is contained in:
parent
8a6702ad7a
commit
8624dec2db
|
@ -204,7 +204,8 @@
|
||||||
<div id="headlines-toolbar" dojoType="dijit.layout.ContentPane" region="top">
|
<div id="headlines-toolbar" dojoType="dijit.layout.ContentPane" region="top">
|
||||||
</div>
|
</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 id="headlinesInnerContainer">
|
||||||
<div class="whiteBox"><?php echo __('Loading, please wait...') ?></div>
|
<div class="whiteBox"><?php echo __('Loading, please wait...') ?></div>
|
||||||
</div>
|
</div>
|
||||||
|
|
11
viewfeed.js
11
viewfeed.js
|
@ -133,7 +133,7 @@ function headlines_callback2(transport, feed_cur_page) {
|
||||||
|
|
||||||
var ids = getSelectedArticleIds2();
|
var ids = getSelectedArticleIds2();
|
||||||
|
|
||||||
c.innerHTML = c.innerHTML + headlines.firstChild.nodeValue;
|
c.innerHTML = c.innerHTML + headlines_content.firstChild.nodeValue;
|
||||||
|
|
||||||
console.log("restore selected ids: " + ids);
|
console.log("restore selected ids: " + ids);
|
||||||
|
|
||||||
|
@ -1513,16 +1513,9 @@ function postMouseOut(id) {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
function headlines_scroll_handler() {
|
function headlines_scroll_handler(e) {
|
||||||
try {
|
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 (e.scrollTop + e.offsetHeight > e.scrollHeight - 100) {
|
||||||
if (!_infscroll_disable) {
|
if (!_infscroll_disable) {
|
||||||
viewNextFeedPage();
|
viewNextFeedPage();
|
||||||
|
|
Loading…
Reference in New Issue