2010-12-07 09:30:05 +03:00
|
|
|
<!DOCTYPE HTML><html><head>
|
2011-06-29 22:22:39 +04:00
|
|
|
<script type="text/javascript" src="/tests/SimpleTest/EventUtils.js"></script>
|
2010-12-07 09:30:05 +03:00
|
|
|
</head>
|
|
|
|
<body>
|
2017-05-22 16:45:31 +03:00
|
|
|
<textarea id="target" style="height: 100px; -moz-appearance: none; appearance: none" spellcheck="false"
|
2010-12-07 09:30:05 +03:00
|
|
|
onkeydown="this.style.display='block';this.style.height='200px';">foo</textarea>
|
|
|
|
<script>
|
|
|
|
var t = document.querySelector("textarea");
|
|
|
|
t.focus();
|
2011-05-12 17:52:38 +04:00
|
|
|
t.selectionStart = t.selectionEnd = t.value.length;
|
2014-02-15 04:57:39 +04:00
|
|
|
sendKey('RETURN');
|
2010-12-07 09:30:05 +03:00
|
|
|
document.body.appendChild(document.createTextNode(t.selectionStart + " - " + t.selectionEnd));
|
|
|
|
</script>
|
|
|
|
</body>
|
|
|
|
</html>
|