| OLD | NEW |
| 1 <!DOCTYPE html> | 1 <!DOCTYPE html> |
| 2 <html> | 2 <html> |
| 3 <head> | 3 <head> |
| 4 <script src="../../../resources/js-test.js"></script> | 4 <script src="../../../resources/js-test.js"></script> |
| 5 <script src="resources/shadow-dom.js"></script> | 5 <script src="resources/shadow-dom.js"></script> |
| 6 </head> | 6 </head> |
| 7 <body> | 7 <body> |
| 8 <p>This tests that pressing Tab key should traverse into shadow DOM subtrees, an
d pressing Shift-Tab should reverse the order.</p> | 8 <p>This tests that pressing Tab key should traverse into shadow DOM subtrees, an
d pressing Shift-Tab should reverse the order.</p> |
| 9 <pre id="console"></pre> | 9 <pre id="console"></pre> |
| 10 <script> | 10 <script> |
| (...skipping 16 matching lines...) Expand all Loading... |
| 27 createDOM('input', {'id': 'younger-A', 'tabindex
': 0}), | 27 createDOM('input', {'id': 'younger-A', 'tabindex
': 0}), |
| 28 createDOM('shadow', {}), | 28 createDOM('shadow', {}), |
| 29 createDOM('input', {'id': 'younger-B', 'tabindex
': 0})), | 29 createDOM('input', {'id': 'younger-B', 'tabindex
': 0})), |
| 30 createDOM('input', {'id': 'light-child-A', 'tabindex
': 0}), | 30 createDOM('input', {'id': 'light-child-A', 'tabindex
': 0}), |
| 31 createDOM('input', {'id': 'light-child-B', 'tabindex
': 0})), | 31 createDOM('input', {'id': 'light-child-B', 'tabindex
': 0})), |
| 32 createDOM('input', {'id': 'B', 'tabindex': 0}))); | 32 createDOM('input', {'id': 'B', 'tabindex': 0}))); |
| 33 parent.offsetLeft; | 33 parent.offsetLeft; |
| 34 } | 34 } |
| 35 | 35 |
| 36 function test() { | 36 function test() { |
| 37 if (window.testRunner) | |
| 38 testRunner.dumpAsText(); | |
| 39 | |
| 40 if (!window.eventSender) { | 37 if (!window.eventSender) { |
| 41 testFailed(''); | 38 testFailed(''); |
| 42 return; | 39 return; |
| 43 } | 40 } |
| 44 | 41 |
| 45 prepareDOMTree(document.body); | 42 prepareDOMTree(document.body); |
| 46 | 43 |
| 47 var elementsInFocusNavigationOrder = [ | 44 var elementsInFocusNavigationOrder = [ |
| 48 'A', | 45 'A', |
| 49 'host', | 46 'host', |
| 50 'host///younger-A', | 47 'host///younger-A', |
| 51 'host//older-A', | 48 'host//older-A', |
| 52 'host//older-B', | 49 'host//older-B', |
| 53 'host///younger-B', | 50 'host///younger-B', |
| 54 'B', | 51 'B', |
| 55 ]; | 52 ]; |
| 56 | 53 |
| 57 testFocusNavigationForward(elementsInFocusNavigationOrder); | 54 testFocusNavigationForward(elementsInFocusNavigationOrder); |
| 58 elementsInFocusNavigationOrder.reverse(); | 55 elementsInFocusNavigationOrder.reverse(); |
| 59 testFocusNavigationBackward(elementsInFocusNavigationOrder); | 56 testFocusNavigationBackward(elementsInFocusNavigationOrder); |
| 60 | 57 |
| 61 debug('Test finished.'); | 58 debug('Test finished.'); |
| 62 } | 59 } |
| 63 | 60 |
| 64 test(); | 61 test(); |
| 65 | 62 |
| 66 </script> | 63 </script> |
| 67 </body> | 64 </body> |
| 68 </html> | 65 </html> |
| OLD | NEW |