layout/reftests/editor/spellcheck-textarea-focused-notreadonly.html
author Ehsan Akhgari <ehsan.akhgari@gmail.com>
Fri, 23 Mar 2012 11:35:40 -0400
changeset 93470 f7b3bfdcd4e42a8f2ca8ae4028f6ec898eca4f66
permissions -rw-r--r--
Bug 737889 - Make sure that clearing the readonly attribute does not disable spell checking; r=roc

<!DOCTYPE html>
<html>
<body>

  <textarea id="testBox" readonly></textarea>
  <script type="text/javascript">
    //Adding focus to the textbox should trigger a spellcheck
    var textbox = document.getElementById("testBox");
    addEventListener("load", function() {
      textbox.readOnly = false;
      textbox.focus();
      textbox.value = "blahblahblah";
      textbox.selectionStart = textbox.selectionEnd = 0;
    }, false);
  </script>

</body>
</html>