layout/base/tests/bug613433-2.html
author Masayuki Nakano <masayuki@d-toybox.com>
Wed, 07 Dec 2011 14:13:06 +0900
changeset 83865 34b8fe0283576a3771e804b6d0c1d609eb1013c1
parent 77047 6385d30812f3a6f299ae00527059afa32407d3b3
child 83877 0c0b9724b1ada8550c34805926e57f41195250b4
permissions -rw-r--r--
Bug 700199 EventUtils.js should use synthesized events for sendKey(), sendChar() and sendString() rather than untrusted events r=ehsan+smaug+enndeakin+dolske

<!DOCTYPE html>
<html class="reftest-wait">
  <head>
    <style>
      div {
        min-height: 36px;
        overflow-y: auto;
      }
    </style>
    <script type="text/javascript" src="/tests/SimpleTest/EventUtils.js"></script>
    <script>
      function test() {
        document.querySelector("div").focus();
        // type a character, then press backspace to delete it
        sendChar("X");
        sendKey("BACK_SPACE");
        document.documentElement.removeAttribute("class");
      }
    </script>
  </head>
  <body onload="test()">
    <div id="div1" contenteditable></div>
  </body>
</html>