summaryrefslogtreecommitdiffstats
path: root/WebCore/manual-tests/qt/numpad-enter-key.html
diff options
context:
space:
mode:
Diffstat (limited to 'WebCore/manual-tests/qt/numpad-enter-key.html')
-rw-r--r--WebCore/manual-tests/qt/numpad-enter-key.html22
1 files changed, 22 insertions, 0 deletions
diff --git a/WebCore/manual-tests/qt/numpad-enter-key.html b/WebCore/manual-tests/qt/numpad-enter-key.html
new file mode 100644
index 0000000..ea9b800
--- /dev/null
+++ b/WebCore/manual-tests/qt/numpad-enter-key.html
@@ -0,0 +1,22 @@
+<html>
+<head>
+ <script type="text/javascript">
+ window.onload = function() {
+ document.getElementById('test').addEventListener('keypress', function(e) {
+ out = document.getElementById('out');
+ out.innerHTML = 'keyCode: ' + e.keyCode + ' (should be 13)';
+ if (e.keyCode == 13)
+ out.style.background = '#6f6';
+ else
+ out.style.background = '#f66';
+ }, false);
+ document.getElementById('test').focus()
+ };
+ </script>
+</head>
+<body>
+ <p>Press the numpad Enter key while the input box below is focused:</p>
+ <p><input type="text" id="test" /></p>
+ <p id="out"></p>
+</body>
+</html>