Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Remove row wrapping when pressing left/right to navigate cells.

  • Loading branch information...
commit e2a4cd708d0d3d6d91e9b07f4afeec1eac6baf44 1 parent 548973d
Colin Snover csnover authored
Showing with 8 additions and 11 deletions.
  1. +8 −11 List.js
19 List.js
View
@@ -61,17 +61,14 @@ function(put, declare, listen, aspect, has, TouchScroll, hasClass){
steps = steps || 1;
do{
// move in the correct direction
- if(nextSibling = current[steps < 0 ? 'previousSibling' : 'nextSibling']){
- do{
- current = nextSibling;
- if(((current && current.className) + ' ').indexOf(targetClass + ' ') > -1){
- // it's an element with the correct class name, counts as a real move
- element = current;
- steps += steps < 0 ? 1 : -1;
- break;
- }
- // if the next sibling isn't a match, drill down to search
- }while(nextSibling = current[steps < 0 ? 'lastChild' : 'firstChild']);
+ if((nextSibling = current[steps < 0 ? 'previousSibling' : 'nextSibling'])){
+ current = nextSibling;
+ if(((current && current.className) + ' ').indexOf(targetClass + ' ') > -1){
+ // it's an element with the correct class name, counts as a real move
+ element = current;
+ steps += steps < 0 ? 1 : -1;
+ break;
+ }
}else if((current = current.parentNode) == this.domNode){ // intentional assignment
// we stepped all the way out of the grid, given up now
break;
Please sign in to comment.
Something went wrong with that request. Please try again.