Skip to content

Commit

Permalink
Traverse past hidden nodes before starting iteration
Browse files Browse the repository at this point in the history
  • Loading branch information
kriszyp authored and Kenneth G. Franqueiro committed Sep 12, 2012
1 parent c21f147 commit f81405e
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions OnDemandList.js
Original file line number Diff line number Diff line change
Expand Up @@ -251,6 +251,10 @@ return declare([List, _StoreMixin], {
function adjustHeight(preload, noMax){
preload.node.style.height = Math.min(preload.count * grid.rowHeight, noMax ? Infinity : grid.maxEmptySpace) + "px";
}
while(preload && !preload.node.offsetWidth){
// skip past preloads that are not currently connected
preload = preload.previous;
}
// there can be multiple preloadNodes (if they split, or multiple queries are created),
// so we can traverse them until we find whatever is in the current viewport, making
// sure we don't backtrack
Expand Down

0 comments on commit f81405e

Please sign in to comment.