editor/reftests/spellcheck-textarea-focused-notreadonly.html

Wed, 31 Dec 2014 07:16:47 +0100

author
Michael Schloh von Bennewitz <michael@schloh.com>
date
Wed, 31 Dec 2014 07:16:47 +0100
branch
TOR_BUG_9701
changeset 3
141e0f1194b1
permissions
-rw-r--r--

Revert simplistic fix pending revisit of Mozilla integration attempt.

     1 <!DOCTYPE html>
     2 <html>
     3 <body>
     5   <textarea id="testBox" style="padding:2px;" readonly></textarea>
     6   <script type="text/javascript">
     7     //Adding focus to the textbox should trigger a spellcheck
     8     var textbox = document.getElementById("testBox");
     9     addEventListener("load", function() {
    10       textbox.readOnly = false;
    11       textbox.focus();
    12       textbox.value = "blahblahblah";
    13       textbox.selectionStart = textbox.selectionEnd = 0;
    14       textbox.blur();
    15     }, false);
    16   </script>
    18 </body>
    19 </html>

mercurial