Closed axacheng closed 10 years ago
Thanks man! I just switched to jquery mobile 1.4.2 now it's working great! what was the trick you did to fix it ?
The main problem with scroll is that scroll
event is not bubble, so it's necessary to know exact element that is scrolled. In most cases it is document
and window
. LazyLoadXT binds to window
's scroll
event, and in jQueryMobile 1.4 it doesn't work. But binding to document
work. So, latest patch fixes the issue by binding to both document
's and window
's events.
PS. Actually I just run
$(['*',document,window]).each(function() {
$(this).bind('scroll', function(e){console.log(e);});
});
to see what element triggers scroll
event.
As subject that i had a hard time to debug the strange issue(the next image didn't show up once the scroll down event triggered ) until i found the barely problem came from jquery1.4.2 break the thing. Now, i've to downgrade from jquery 1.4.2 to jquery 1.3.2. and everything works perfectly! (Thanks for your contribution)
btw, Could you please try to use jquery 1.4.2 on below example and let me know how it works ?
view-source:http://ressio.github.io/lazy-load-xt/demo/jqmobile.htm#page2