tor-browser

The Tor Browser
git clone https://git.dasho.dev/tor-browser.git
Log | Files | Refs | README | LICENSE

test_bug386996.html (1178B)


      1 <!DOCTYPE HTML>
      2 <html>
      3 <!--
      4 https://bugzilla.mozilla.org/show_bug.cgi?id=386996
      5 -->
      6 <head>
      7  <title>Test for Bug 386996</title>
      8  <script src="/tests/SimpleTest/SimpleTest.js"></script>        
      9  <script src="/tests/SimpleTest/EventUtils.js"></script>        
     10  <link rel="stylesheet" type="text/css" href="/tests/SimpleTest/test.css" />
     11 </head>
     12 <body>
     13 <a target="_blank" href="https://bugzilla.mozilla.org/show_bug.cgi?id=386996">Mozilla Bug 386996</a>
     14 <p id="display"></p>
     15 <div id="content">
     16  <input id="input1"><input disabled><input id="input2">
     17 </div>
     18 <pre id="test">
     19 <script class="testbody" type="text/javascript">
     20 
     21 /** Test for Bug 386996 */
     22 
     23 var frame = document.getElementById("testIframe");
     24 
     25 function testContentEditable() {
     26  var focusedElement;
     27  document.getElementById("input1").onfocus = function() { focusedElement = this };
     28  document.getElementById("input2").onfocus = function() { focusedElement = this };
     29 
     30  document.getElementById("input1").focus();
     31  synthesizeKey("KEY_Tab");
     32 
     33  is(focusedElement.id, "input2");
     34 }
     35 
     36 SimpleTest.waitForExplicitFinish();
     37 addLoadEvent(testContentEditable);
     38 addLoadEvent(SimpleTest.finish);
     39 
     40 </script>
     41 </pre>
     42 </body>
     43 </html>