@@ 543-562 (lines=20) @@ | ||
540 | return focusItem; |
|
541 | }; |
|
542 | ||
543 | this.NavPrev = function(index) |
|
544 | { |
|
545 | var focusItem; |
|
546 | while (1) |
|
547 | { |
|
548 | var focusName = 'Item'+index; |
|
549 | focusItem = document.getElementById(focusName); |
|
550 | if (focusItem && focusItem.parentNode.parentNode.style.display=='block') |
|
551 | { |
|
552 | break; |
|
553 | } |
|
554 | else if (!focusItem) // last element |
|
555 | { |
|
556 | break; |
|
557 | } |
|
558 | focusItem=null; |
|
559 | index--; |
|
560 | } |
|
561 | return focusItem; |
|
562 | }; |
|
563 | ||
564 | this.ProcessKeys = function(e) |
|
565 | { |
|
@@ 522-541 (lines=20) @@ | ||
519 | }; |
|
520 | ||
521 | // return the first item with index index or higher that is visible |
|
522 | this.NavNext = function(index) |
|
523 | { |
|
524 | var focusItem; |
|
525 | while (1) |
|
526 | { |
|
527 | var focusName = 'Item'+index; |
|
528 | focusItem = document.getElementById(focusName); |
|
529 | if (focusItem && focusItem.parentNode.parentNode.style.display=='block') |
|
530 | { |
|
531 | break; |
|
532 | } |
|
533 | else if (!focusItem) // last element |
|
534 | { |
|
535 | break; |
|
536 | } |
|
537 | focusItem=null; |
|
538 | index++; |
|
539 | } |
|
540 | return focusItem; |
|
541 | }; |
|
542 | ||
543 | this.NavPrev = function(index) |
|
544 | { |