Merge Chromium + Blink git repositories
[chromium-blink-merge.git] / third_party / WebKit / LayoutTests / fast / spatial-navigation / snav-1st-stop.html
blobab48e3bfdb8164069a13aa03e8530a18a84342a8
1 <html>
2 <!--
3 This test ensures the correctness of Spatial Navigation (SNav) algorithm from a non-focus scenario.
5 * Pre-conditions:
6 1) DRT support for SNav enable/disable.
8 * Navigation steps:
9 1) Loads this page and send key down.
10 2) The 1st link should be focused.
11 -->
12 <head>
13 <script src="../../resources/js-test.js"></script>
14 <script src="resources/spatial-navigation-utils.js"></script>
15 <script type="application/javascript">
17 var resultMap = [
18 ["Down", "1"],
19 ["DONE", "DONE"]
22 if (window.testRunner) {
23 testRunner.dumpAsText();
24 testRunner.overridePreference("WebKitTabToLinksPreferenceKey", 1);
25 window.internals.settings.setSpatialNavigationEnabled(true);
26 testRunner.waitUntilDone();
29 function runTest()
31 // starting the test from no focused node.
32 initTest(resultMap, testCompleted);
35 function testCompleted()
37 if (window.testRunner)
38 testRunner.notifyDone();
41 window.onload = runTest;
43 </script>
44 </head>
45 <body id="some-content" xmlns="http://www.w3.org/1999/xhtml">
46 <table style="text-align: left; width: 100%; margin-left: auto; margin-right: auto;" border="1" cellpadding="2" cellspacing="1">
47 <tbody>
48 <tr>
49 <td style="vertical-align: top; text-align: center;"><a id="1" href="a">1</a></td>
50 <td style="vertical-align: top; text-align: center;"><a id="2" href="a">2</a></td>
51 <td style="vertical-align: top; text-align: center;"><a id="3" href="a">3</a></td>
52 </tr>
53 <tr>
54 <td style="vertical-align: top; text-align: center;"><a id="4" href="a">4</a></td>
55 <td style="vertical-align: top; text-align: center;"><a id="5" href="a">5</td>
56 <td style="vertical-align: top; text-align: center;"><a id="6" href="a">6</a></td>
57 </tr>
58 <tr>
59 <td style="vertical-align: top; text-align: center;"><a id="7" href="a">7</a></td>
60 <td style="vertical-align: top; text-align: center;"><a id="8" href="a">8</a></td>
61 <td style="vertical-align: top; text-align: center;"><a id="9" href="a">9</a></td>
62 </tr>
63 </tbody>
64 </table>
65 <div id="console"></div>
66 </body>
67 </html>