Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(28)

Side by Side Diff: LayoutTests/fast/events/tab-focus-anchor-tab-to-links.html

Issue 15238002: Disallow tabsToLinks setting to prevent tabbing to anchor with tabIndex. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: And update expected result after removing accidentally added line Created 7 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
(Empty)
1 <!DOCTYPE html>
2 <html>
3 <head>
4 <link rel="help" href="http://www.w3.org/TR/DOM-Level-3-Events/#events-WheelEven t">
5 <script src="../js/resources/js-test-pre.js"></script>
6 <script>
7 function runTest()
8 {
9 if (!window.testRunner || !window.eventSender) {
10 debug("FAIL: This test requires window.testRunner and window.eventSender .");
11 finishJSTest();
12 return;
13 }
14
15 testRunner.overridePreference('WebKitTabToLinksPreferenceKey', true);
16
17 for (var i = 0; i < 3; i++)
18 eventSender.keyDown('\t');
19
20 finishJSTest();
21 };
22
23 window.addEventListener('load', runTest);
24 </script>
25 </head>
26 <body>
27
28 <p>This test ensures that we can tab to all anchor elements. Press tab three
29 times to focus the elements below.
30
31 <p><a onfocus="testPassed('gave focus to focusable element')" href="#">Focusable </a></p>
32 <p><a onfocus="testFailed('gave focus to unfocusable element')">Not focusable</a ></p>
33 <p><a tabindex=0 onfocus="testPassed('gave focus to focusable element')" href="# ">Focusable</a></p>
34 <p><a tabindex=0 onfocus="testPassed('gave focus to focusable element')">Focusab le</a></p>
35 <p><input onfocus="testFailed('should have stopped testing before this element') "></p>
36
37 <p>Result
38
39 <div id="console"></div>
40
41 </body>
42 </html>
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698