- function unveil() {
- var inview = images.filter(function() {
- var $e = $(this);
- if ($e.is(":hidden")) return;
-
- var wt = $w.scrollTop(),
- wb = wt + $w.height(),
- et = $e.offset().top,
- eb = et + $e.height();
-
- return eb >= wt - th && et <= wb + th;
- });
-
did't quite understand the usage of filter on the 2nd line . is it the Jquery filter function() ??
if it is , the filter function 1st take s a 'creteria' which i don't see being used here .
also , the above code i got frm a small lightweight pluggin : called unviel.js , its for lazy loading .