2008-05-05 16:01:07 -07:00
|
|
|
<?xml version="1.0"?>
|
|
|
|
<?xml-stylesheet href="chrome://global/skin" type="text/css"?>
|
|
|
|
<?xml-stylesheet href="chrome://mochikit/content/tests/SimpleTest/test.css"
|
|
|
|
type="text/css"?>
|
|
|
|
<window title="Key event tests"
|
|
|
|
onload="runTest()"
|
|
|
|
xmlns:html="http://www.w3.org/1999/xhtml"
|
|
|
|
xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul">
|
|
|
|
|
|
|
|
<title>Key event tests</title>
|
|
|
|
<script type="application/javascript"
|
|
|
|
src="chrome://mochikit/content/tests/SimpleTest/SimpleTest.js" />
|
2012-06-26 19:26:38 -07:00
|
|
|
<script type="application/javascript"
|
|
|
|
src="chrome://mochikit/content/tests/SimpleTest/NativeKeyCodes.js" />
|
2008-05-05 16:01:07 -07:00
|
|
|
|
2008-05-08 15:41:13 -07:00
|
|
|
<keyset>
|
|
|
|
<key id="unshiftedKey" key=";" modifiers="accel" oncommand="this.activeCount++"/>
|
|
|
|
<key id="shiftedKey" key=":" modifiers="accel" oncommand="this.activeCount++"/>
|
|
|
|
<key id="commandOptionF" key='f' modifiers="accel,alt" oncommand="this.activeCount++"/>
|
|
|
|
<key id="question" key='?' modifiers="accel" oncommand="this.activeCount++"/>
|
2008-05-11 17:39:29 -07:00
|
|
|
<key id="unshiftedX" key="x" modifiers="accel" oncommand="this.activeCount++"/>
|
|
|
|
<key id="shiftedX" key="X" modifiers="accel,shift" oncommand="this.activeCount++"/>
|
|
|
|
<key id="unshiftedPlus" key="+" modifiers="accel" oncommand="this.activeCount++"/>
|
2008-05-08 15:41:13 -07:00
|
|
|
</keyset>
|
|
|
|
|
2008-05-05 16:01:07 -07:00
|
|
|
<body xmlns="http://www.w3.org/1999/xhtml">
|
|
|
|
<p id="display">
|
|
|
|
<!-- for some reason, if we don't have 'accesskey' here, adding it dynamically later
|
|
|
|
doesn't work! -->
|
|
|
|
<button id="button" accesskey="z">Hello</button>
|
2008-10-13 23:01:51 -07:00
|
|
|
<input type="text" id="textbox" value=""/>
|
2008-05-05 16:01:07 -07:00
|
|
|
</p>
|
|
|
|
<div id="content" style="display: none">
|
|
|
|
|
|
|
|
</div>
|
|
|
|
<pre id="test">
|
|
|
|
</pre>
|
|
|
|
</body>
|
|
|
|
|
|
|
|
<script class="testbody" type="application/javascript">
|
|
|
|
<![CDATA[
|
|
|
|
|
2009-03-30 14:42:11 -07:00
|
|
|
const IS_MAC = navigator.platform.indexOf("Mac") == 0;
|
|
|
|
const IS_WIN = navigator.platform.indexOf("Win") == 0;
|
2008-05-05 16:01:07 -07:00
|
|
|
|
|
|
|
function synthesizeNativeKey(aLayout, aKeyCode, aModifiers, aSystemChars,
|
|
|
|
aSystemUnmodifiedChars, aWindow)
|
|
|
|
{
|
|
|
|
if (!aWindow)
|
|
|
|
aWindow = window;
|
|
|
|
|
|
|
|
var utils = aWindow.QueryInterface(Components.interfaces.nsIInterfaceRequestor).
|
|
|
|
getInterface(Components.interfaces.nsIDOMWindowUtils);
|
|
|
|
|
|
|
|
if (utils) {
|
|
|
|
var modifiers = 0;
|
|
|
|
if (aModifiers.capsLock) modifiers |= 0x01;
|
|
|
|
if (aModifiers.numLock) modifiers |= 0x02;
|
|
|
|
if (aModifiers.shift) modifiers |= 0x0100;
|
|
|
|
if (aModifiers.shiftRight) modifiers |= 0x0200;
|
|
|
|
if (aModifiers.ctrl) modifiers |= 0x0400;
|
|
|
|
if (aModifiers.ctrlRight) modifiers |= 0x0800;
|
|
|
|
if (aModifiers.alt) modifiers |= 0x1000;
|
|
|
|
if (aModifiers.altRight) modifiers |= 0x2000;
|
2012-06-15 02:52:51 -07:00
|
|
|
if (IS_WIN && aModifiers.altGr) {
|
|
|
|
if (!aModifiers.ctrl && !aModifiers.ctrlRight) {
|
|
|
|
modifiers |= 0x0400;
|
|
|
|
}
|
|
|
|
if (!aModifiers.alt && !aModifiers.altRight) {
|
|
|
|
modifiers |= 0x1000;
|
|
|
|
}
|
|
|
|
}
|
2008-05-05 16:01:07 -07:00
|
|
|
if (aModifiers.command) modifiers |= 0x4000;
|
2008-10-18 01:37:59 -07:00
|
|
|
if (aModifiers.commandRight) modifiers |= 0x8000;
|
|
|
|
if (aModifiers.help) modifiers |= 0x10000;
|
|
|
|
if (aModifiers.function) modifiers |= 0x100000;
|
2008-05-05 16:01:07 -07:00
|
|
|
if (aModifiers.numericKeyPad) modifiers |= 0x01000000;
|
2008-10-18 01:37:59 -07:00
|
|
|
|
2008-05-05 16:01:07 -07:00
|
|
|
utils.sendNativeKeyEvent(aLayout, aKeyCode, modifiers,
|
|
|
|
aSystemChars, aSystemUnmodifiedChars);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
var keyboardLayouts;
|
2009-03-30 14:42:11 -07:00
|
|
|
if (IS_MAC) {
|
2012-03-29 20:37:40 -07:00
|
|
|
// Any unused number is okay for adding new keyboard layout.
|
|
|
|
// When you add new keyboard layout here, you need to modify
|
|
|
|
// TISInputSourceWrapper::InitByLayoutID().
|
2008-05-05 16:01:07 -07:00
|
|
|
keyboardLayouts = {
|
2012-03-29 20:37:40 -07:00
|
|
|
"US": 0,
|
|
|
|
"Greek": 1,
|
|
|
|
"German": 2,
|
|
|
|
"Swedish": 3,
|
|
|
|
"Dvorak-Qwerty": 4,
|
|
|
|
"Thai": 5
|
2008-05-05 16:01:07 -07:00
|
|
|
};
|
2009-03-30 14:42:11 -07:00
|
|
|
} else if (IS_WIN) {
|
2008-05-05 16:01:07 -07:00
|
|
|
// These constants can be found by inspecting registry keys under
|
|
|
|
// HKEY_LOCAL_MACHINE\System\CurrentControlSet\Control\Keyboard Layouts
|
|
|
|
keyboardLayouts = {
|
|
|
|
"US":0x409,
|
2012-05-17 00:04:16 -07:00
|
|
|
"German":0x407,
|
2008-05-08 15:41:13 -07:00
|
|
|
"Greek":0x408,
|
2012-06-15 02:52:51 -07:00
|
|
|
"Spanish":0x40a,
|
2012-05-17 00:04:16 -07:00
|
|
|
"French":0x40c,
|
2008-05-11 17:39:29 -07:00
|
|
|
"Swedish":0x41d,
|
|
|
|
"Arabic":0x401,
|
|
|
|
"Hebrew":0x40d,
|
2008-10-13 23:01:51 -07:00
|
|
|
"Japanese":0x411,
|
2012-05-17 00:04:16 -07:00
|
|
|
"Norwegian":0x414,
|
2013-07-24 23:04:17 -07:00
|
|
|
"BrazilianABNT":0x416,
|
2012-05-29 17:47:03 -07:00
|
|
|
"Lithuanian":0x10427,
|
|
|
|
"Thai": 0x2041e
|
2008-05-05 16:01:07 -07:00
|
|
|
};
|
|
|
|
}
|
|
|
|
|
2008-05-08 15:41:13 -07:00
|
|
|
function eventToString(aEvent)
|
|
|
|
{
|
2012-05-17 00:04:16 -07:00
|
|
|
var name = aEvent.layout + " keyCode=" +
|
|
|
|
aEvent.keyCode + " (0x" + aEvent.keyCode.toString(16).toUpperCase() +
|
|
|
|
") chars='" + aEvent.chars + "'";
|
2008-05-08 15:41:13 -07:00
|
|
|
if (aEvent.shift) {
|
|
|
|
name += " [Shift]";
|
|
|
|
}
|
2008-10-18 01:37:59 -07:00
|
|
|
if (aEvent.shiftRight) {
|
|
|
|
name += " [Right Shift]";
|
|
|
|
}
|
2008-05-08 15:41:13 -07:00
|
|
|
if (aEvent.ctrl) {
|
|
|
|
name += " [Ctrl]";
|
|
|
|
}
|
2008-10-18 01:37:59 -07:00
|
|
|
if (aEvent.ctrlRight) {
|
|
|
|
name += " [Right Ctrl]";
|
|
|
|
}
|
2008-05-08 15:41:13 -07:00
|
|
|
if (aEvent.alt) {
|
|
|
|
name += " [Alt]";
|
|
|
|
}
|
2008-10-18 01:37:59 -07:00
|
|
|
if (aEvent.altRight) {
|
|
|
|
name += " [Right Alt]";
|
|
|
|
}
|
2008-05-08 15:41:13 -07:00
|
|
|
if (aEvent.command) {
|
|
|
|
name += " [Command]";
|
|
|
|
}
|
2008-10-18 01:37:59 -07:00
|
|
|
if (aEvent.commandRight) {
|
|
|
|
name += " [Right Command]";
|
|
|
|
}
|
2008-05-08 15:41:13 -07:00
|
|
|
|
|
|
|
return name;
|
|
|
|
}
|
|
|
|
|
2008-10-13 23:01:51 -07:00
|
|
|
function synthesizeKey(aEvent, aFocusElementId)
|
2008-05-08 15:41:13 -07:00
|
|
|
{
|
2008-10-13 23:01:51 -07:00
|
|
|
document.getElementById(aFocusElementId).focus();
|
2008-05-08 15:41:13 -07:00
|
|
|
|
|
|
|
synthesizeNativeKey(keyboardLayouts[aEvent.layout],
|
|
|
|
aEvent.keyCode, aEvent, aEvent.chars, aEvent.unmodifiedChars);
|
|
|
|
}
|
|
|
|
|
2008-10-15 20:04:39 -07:00
|
|
|
// Test the charcodes and modifiers being delivered to keypress handlers and
|
|
|
|
// also keydown/keyup events too.
|
|
|
|
function runKeyEventTests()
|
2008-05-05 16:01:07 -07:00
|
|
|
{
|
2012-05-17 00:04:16 -07:00
|
|
|
const nsIDOMKeyEvent = Components.interfaces.nsIDOMKeyEvent;
|
2012-07-18 18:28:17 -07:00
|
|
|
var eventList, keyDownFlags, keyUpFlags, testingEvent, expectedDOMKeyCode;
|
2008-10-15 20:04:39 -07:00
|
|
|
const kShiftFlag = 0x1;
|
|
|
|
const kCtrlFlag = 0x2;
|
|
|
|
const kAltFlag = 0x4;
|
|
|
|
const kMetaFlag = 0x8;
|
|
|
|
const kNumLockFlag = 0x10;
|
|
|
|
const kCapsLockFlag = 0x20;
|
|
|
|
|
|
|
|
function onKeyEvent(e)
|
2008-05-05 16:01:07 -07:00
|
|
|
{
|
2008-10-15 20:04:39 -07:00
|
|
|
function removeFlag(e, aFlag)
|
|
|
|
{
|
|
|
|
if (e.type == "keydown") {
|
|
|
|
var oldValue = keyDownFlags;
|
|
|
|
keyDownFlags &= ~aFlag;
|
|
|
|
return oldValue != keyDownFlags;
|
|
|
|
} else if (e.type == "keyup") {
|
|
|
|
var oldValue = keyUpFlags;
|
|
|
|
keyUpFlags &= ~aFlag;
|
|
|
|
return oldValue != keyUpFlags;
|
|
|
|
}
|
|
|
|
return false;
|
|
|
|
}
|
|
|
|
|
|
|
|
function isStateChangingModifierKeyEvent(e)
|
|
|
|
{
|
2012-06-15 02:52:51 -07:00
|
|
|
var flags = 0;
|
|
|
|
if (e.type == "keydown") {
|
|
|
|
flags = keyDownFlags ^ keyUpFlags;
|
|
|
|
} else if (e.type == "keyup") {
|
|
|
|
flags = keyUpFlags;
|
|
|
|
}
|
2008-10-15 20:04:39 -07:00
|
|
|
switch (e.keyCode) {
|
|
|
|
case e.DOM_VK_SHIFT:
|
2012-06-15 02:52:51 -07:00
|
|
|
is(e.ctrlKey, (flags & kCtrlFlag) != 0, name + ", Ctrl of Shift " + e.type + " event mismatch");
|
|
|
|
is(e.metaKey, (flags & kMetaFlag) != 0, name + ", Command of Shift " + e.type + " event mismatch");
|
|
|
|
is(e.altKey, (flags & kAltFlag) != 0, name + ", Alt of Shift " + e.type + " event mismatch");
|
|
|
|
is(e.shiftKey, e.type == "keydown", name + ", Shift of Shift " + e.type + " event mismatch");
|
2012-07-18 18:28:17 -07:00
|
|
|
return (testingEvent.shift || testingEvent.shiftRight) && removeFlag(e, kShiftFlag) && expectedDOMKeyCode != e.keyCode;
|
2008-10-15 20:04:39 -07:00
|
|
|
case e.DOM_VK_CONTROL:
|
2012-06-15 02:52:51 -07:00
|
|
|
is(e.ctrlKey, e.type == "keydown", name + ", Ctrl of Ctrl " + e.type + " event mismatch");
|
|
|
|
is(e.metaKey, (flags & kMetaFlag) != 0, name + ", Command of Ctrl " + e.type + " event mismatch");
|
|
|
|
is(e.altKey, (flags & kAltFlag) != 0, name + ", Alt of Ctrl " + e.type + " event mismatch");
|
|
|
|
is(e.shiftKey, (flags & kShiftFlag) != 0, name + ", Shift of Ctrl " + e.type + " event mismatch");
|
2012-07-18 18:28:17 -07:00
|
|
|
return (testingEvent.ctrl || testingEvent.ctrlRight || (IS_WIN && testingEvent.altGr)) && removeFlag(e, kCtrlFlag) && expectedDOMKeyCode != e.keyCode;
|
2008-10-15 20:04:39 -07:00
|
|
|
case e.DOM_VK_ALT:
|
2012-06-15 02:52:51 -07:00
|
|
|
is(e.ctrlKey, (flags & kCtrlFlag) != 0, name + ", Ctrl of Alt " + e.type + " event mismatch");
|
|
|
|
is(e.metaKey, (flags & kMetaFlag) != 0, name + ", Command of Alt " + e.type + " event mismatch");
|
|
|
|
is(e.altKey, e.type == "keydown", name + ", Alt of Alt " + e.type + " event mismatch");
|
|
|
|
is(e.shiftKey, (flags & kShiftFlag) != 0, name + ", Shift of Alt " + e.type + " event mismatch");
|
2012-07-18 18:28:17 -07:00
|
|
|
return (testingEvent.alt || testingEvent.altRight || (IS_WIN && testingEvent.altGr)) && removeFlag(e, kAltFlag) && expectedDOMKeyCode != e.keyCode;
|
2008-10-15 20:04:39 -07:00
|
|
|
case e.DOM_VK_META:
|
2012-06-15 02:52:51 -07:00
|
|
|
is(e.ctrlKey, (flags & kCtrlFlag) != 0, name + ", Ctrl of Command " + e.type + " evnet mismatch");
|
|
|
|
is(e.metaKey, e.type == "keydown", name + ", Command of Command " + e.type + " evnet mismatch");
|
|
|
|
is(e.altKey, (flags & kAltFlag) != 0, name + ", Alt of Command " + e.type + " evnet mismatch");
|
|
|
|
is(e.shiftKey, (flags & kShiftFlag) != 0, name + ", Shift of Command " + e.type + " evnet mismatch");
|
2012-07-18 18:28:17 -07:00
|
|
|
return testingEvent.command && removeFlag(e, kMetaFlag) && expectedDOMKeyCode != e.keyCode;
|
2008-10-15 20:04:39 -07:00
|
|
|
case e.DOM_VK_NUM_LOCK:
|
2012-06-15 02:52:51 -07:00
|
|
|
is(e.ctrlKey, (flags & kCtrlFlag) != 0, name + ", Ctrl of NumLock " + e.type + " event mismatch");
|
|
|
|
is(e.metaKey, (flags & kMetaFlag) != 0, name + ", Command of NumLock " + e.type + " event mismatch");
|
|
|
|
is(e.altKey, (flags & kAltFlag) != 0, name + ", Alt of NumLock " + e.type + " event mismatch");
|
|
|
|
is(e.shiftKey, (flags & kShiftFlag) != 0, name + ", Shift of NumLock " + e.type + " event mismatch");
|
2012-07-18 18:28:17 -07:00
|
|
|
return testingEvent.numLock && removeFlag(e, kNumLockFlag) && expectedDOMKeyCode != e.keyCode;
|
2008-10-15 20:04:39 -07:00
|
|
|
case e.DOM_VK_CAPS_LOCK:
|
2012-06-15 02:52:51 -07:00
|
|
|
is(e.ctrlKey, (flags & kCtrlFlag) != 0, name + ", Ctrl of CapsLock " + e.type + " event mismatch");
|
|
|
|
is(e.metaKey, (flags & kMetaFlag) != 0, name + ", Command of CapsLock " + e.type + " event mismatch");
|
|
|
|
is(e.altKey, (flags & kAltFlag) != 0, name + ", Alt of CapsLock " + e.type + " event mismatch");
|
|
|
|
is(e.shiftKey, (flags & kShiftFlag) != 0, name + ", Shift of CapsLock " + e.type + " event mismatch");
|
2012-07-18 18:28:17 -07:00
|
|
|
return testingEvent.capsLock && removeFlag(e, kCapsLockFlag) && expectedDOMKeyCode != e.keyCode;
|
2008-10-15 20:04:39 -07:00
|
|
|
}
|
|
|
|
return false;
|
|
|
|
}
|
|
|
|
|
|
|
|
// Ignore the state changing key events which is fired by the testing event.
|
|
|
|
if (!isStateChangingModifierKeyEvent(e))
|
|
|
|
eventList.push(e);
|
2013-07-24 23:09:29 -07:00
|
|
|
if (e.type == "keypress") {
|
|
|
|
e.preventDefault();
|
|
|
|
}
|
2008-05-05 16:01:07 -07:00
|
|
|
}
|
|
|
|
|
2008-10-15 20:04:39 -07:00
|
|
|
const SHOULD_DELIVER_NONE = 0x0;
|
|
|
|
const SHOULD_DELIVER_KEYDOWN = 0x1;
|
|
|
|
const SHOULD_DELIVER_KEYPRESS = 0x2;
|
|
|
|
const SHOULD_DELIVER_KEYUP = 0x4;
|
2012-06-15 02:52:51 -07:00
|
|
|
const SHOULD_NOT_CAUSE_INPUT = 0x8;
|
2008-10-15 20:04:39 -07:00
|
|
|
const SHOULD_DELIVER_ALL = SHOULD_DELIVER_KEYDOWN |
|
|
|
|
SHOULD_DELIVER_KEYPRESS |
|
|
|
|
SHOULD_DELIVER_KEYUP;
|
2012-06-15 02:52:51 -07:00
|
|
|
const SHOULD_DELIVER_ALL_BUT_NOT_CAUSE_INPUT = SHOULD_DELIVER_ALL |
|
|
|
|
SHOULD_NOT_CAUSE_INPUT;
|
2008-10-15 20:04:39 -07:00
|
|
|
const SHOULD_DELIVER_KEYDOWN_KEYUP = SHOULD_DELIVER_KEYDOWN |
|
|
|
|
SHOULD_DELIVER_KEYUP;
|
|
|
|
const SHOULD_DELIVER_KEYDOWN_KEYPRESS = SHOULD_DELIVER_KEYDOWN |
|
|
|
|
SHOULD_DELIVER_KEYPRESS;
|
|
|
|
|
2008-05-05 16:01:07 -07:00
|
|
|
// The first parameter is the complete input event. The second parameter is
|
2008-10-15 20:04:39 -07:00
|
|
|
// what to test against. The third parameter is which key events should be
|
|
|
|
// delived for the event.
|
2012-05-17 00:04:16 -07:00
|
|
|
function testKey(aEvent, aExpectedGeckoKeyCode, aExpectGeckoChar,
|
2012-07-18 18:28:17 -07:00
|
|
|
aShouldDelivedEvent, aExpectLocation)
|
2008-05-05 16:01:07 -07:00
|
|
|
{
|
2012-05-17 00:04:16 -07:00
|
|
|
ok(aExpectedGeckoKeyCode != undefined, "keycode is undefined");
|
2008-10-15 20:04:39 -07:00
|
|
|
eventList = [];
|
|
|
|
|
|
|
|
// The modifier key events which are fired for state changing are har to
|
|
|
|
// test. We should ignore them for now.
|
|
|
|
keyDownFlags = keyUpFlags = 0;
|
2009-03-30 14:42:11 -07:00
|
|
|
if (!IS_MAC) {
|
2008-10-15 20:04:39 -07:00
|
|
|
// On Mac, nsChildView doesn't generate modifier keydown/keyup events for
|
|
|
|
// state changing for synthesizeNativeKeyEvent.
|
|
|
|
if (aEvent.shift || aEvent.shiftRight)
|
|
|
|
keyDownFlags |= kShiftFlag;
|
2012-06-15 02:52:51 -07:00
|
|
|
if (aEvent.ctrl || aEvent.ctrlRight || (IS_WIN && aEvent.altGr))
|
2008-10-15 20:04:39 -07:00
|
|
|
keyDownFlags |= kCtrlFlag;
|
2012-06-15 02:52:51 -07:00
|
|
|
if (aEvent.alt || aEvent.altRight || (IS_WIN && aEvent.altGr))
|
2008-10-15 20:04:39 -07:00
|
|
|
keyDownFlags |= kAltFlag;
|
|
|
|
if (aEvent.command)
|
|
|
|
keyDownFlags |= kMetaFlag;
|
|
|
|
if (aEvent.numLock)
|
|
|
|
keyDownFlags |= kNumLockFlag;
|
|
|
|
if (aEvent.capsLock)
|
|
|
|
keyDownFlags |= kCapsLockFlag;
|
|
|
|
keyUpFlags = keyDownFlags;
|
|
|
|
}
|
2009-03-30 14:42:11 -07:00
|
|
|
|
2008-10-15 20:04:39 -07:00
|
|
|
testingEvent = aEvent;
|
2012-07-18 18:28:17 -07:00
|
|
|
expectedDOMKeyCode = aExpectedGeckoKeyCode;
|
2008-10-15 20:04:39 -07:00
|
|
|
|
2008-10-13 23:01:51 -07:00
|
|
|
synthesizeKey(aEvent, "button");
|
2008-05-05 16:01:07 -07:00
|
|
|
|
2008-05-08 15:41:13 -07:00
|
|
|
var name = eventToString(aEvent);
|
2008-05-05 16:01:07 -07:00
|
|
|
|
2008-10-15 20:04:39 -07:00
|
|
|
var expectEventTypeList = [];
|
|
|
|
if (aShouldDelivedEvent & SHOULD_DELIVER_KEYDOWN)
|
|
|
|
expectEventTypeList.push("keydown");
|
2012-06-15 02:52:51 -07:00
|
|
|
if (aShouldDelivedEvent & SHOULD_DELIVER_KEYPRESS) {
|
2008-10-15 20:04:39 -07:00
|
|
|
expectEventTypeList.push("keypress");
|
2012-06-15 02:52:51 -07:00
|
|
|
for (var i = 1; i < aExpectGeckoChar.length; i++) {
|
|
|
|
expectEventTypeList.push("keypress");
|
|
|
|
}
|
|
|
|
}
|
2008-10-15 20:04:39 -07:00
|
|
|
if (aShouldDelivedEvent & SHOULD_DELIVER_KEYUP)
|
|
|
|
expectEventTypeList.push("keyup");
|
|
|
|
is(eventList.length, expectEventTypeList.length, name + ", wrong number of key events");
|
|
|
|
|
|
|
|
var longerLength = Math.max(eventList.length, expectEventTypeList.length);
|
2012-06-15 02:52:51 -07:00
|
|
|
var keypressCount = 0;
|
2008-10-15 20:04:39 -07:00
|
|
|
for (var i = 0; i < longerLength; i++) {
|
|
|
|
var firedEventType = i < eventList.length ? eventList[i].type : "";
|
|
|
|
var expectEventType = i < expectEventTypeList.length ? expectEventTypeList[i] : "";
|
|
|
|
if (firedEventType != "")
|
|
|
|
is(firedEventType, expectEventType, name + ", wrong type event fired");
|
|
|
|
else
|
|
|
|
is(firedEventType, expectEventType, name + ", a needed event is not fired");
|
|
|
|
|
|
|
|
if (firedEventType != "") {
|
|
|
|
var e = eventList[i];
|
2012-06-15 02:52:51 -07:00
|
|
|
if (e.type == "keypress") {
|
|
|
|
var isCtrlExpected = aEvent.ctrl || aEvent.ctrlRight || false;
|
|
|
|
var isAltExpected = aEvent.alt || aEvent.altRight || false;
|
|
|
|
if (IS_WIN && aEvent.altGr) {
|
|
|
|
isCtrlExpected = isAltExpected =
|
|
|
|
((aShouldDelivedEvent & SHOULD_NOT_CAUSE_INPUT) != 0);
|
|
|
|
}
|
|
|
|
is(e.ctrlKey, isCtrlExpected, name + ", Ctrl mismatch");
|
|
|
|
is(e.metaKey, aEvent.command || aEvent.commandRight || false, name + ", Command mismatch");
|
|
|
|
is(e.altKey, isAltExpected, name + ", Alt mismatch");
|
|
|
|
is(e.shiftKey, aEvent.shift || aEvent.shiftRight || false, name + ", Shift mismatch");
|
|
|
|
}
|
2008-10-15 20:04:39 -07:00
|
|
|
|
2012-05-17 00:04:16 -07:00
|
|
|
if (aExpectGeckoChar.length > 0 && e.type == "keypress") {
|
2012-06-15 02:52:51 -07:00
|
|
|
is(e.charCode, aExpectGeckoChar.charCodeAt(keypressCount++), name + ", charcode");
|
2012-05-17 00:04:16 -07:00
|
|
|
if (aExpectedGeckoKeyCode >= 0) {
|
|
|
|
if (aExpectGeckoChar) {
|
|
|
|
is(e.keyCode, 0, name + ", wrong keycode");
|
|
|
|
} else {
|
|
|
|
is(e.keyCode, aExpectedGeckoKeyCode, name + ", wrong keycode");
|
|
|
|
}
|
|
|
|
}
|
|
|
|
} else {
|
2008-10-15 20:04:39 -07:00
|
|
|
is(e.charCode, 0, name + ", no charcode");
|
2012-05-17 00:04:16 -07:00
|
|
|
if (aExpectedGeckoKeyCode >= 0) {
|
|
|
|
is(e.keyCode, aExpectedGeckoKeyCode, name + ", wrong keycode");
|
|
|
|
}
|
|
|
|
}
|
2012-07-18 18:28:17 -07:00
|
|
|
is(e.location, aExpectLocation, name + ", wrong location");
|
2008-10-15 20:04:39 -07:00
|
|
|
}
|
2008-05-05 16:01:07 -07:00
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2008-05-08 15:41:13 -07:00
|
|
|
// These tests have to be per-plaform.
|
2008-10-15 20:04:39 -07:00
|
|
|
document.addEventListener("keydown", onKeyEvent, false);
|
|
|
|
document.addEventListener("keypress", onKeyEvent, false);
|
|
|
|
document.addEventListener("keyup", onKeyEvent, false);
|
2008-05-05 16:01:07 -07:00
|
|
|
|
2009-03-30 14:42:11 -07:00
|
|
|
if (IS_MAC) {
|
2008-05-05 16:01:07 -07:00
|
|
|
// On Mac, you can produce event records for any desired keyboard input
|
2011-07-20 17:33:16 -07:00
|
|
|
// by running with NSPR_LOG_MODULES=TextInputHandlerWidgets:5 and typing
|
|
|
|
// into the browser. We will dump the key event fields to the console
|
|
|
|
// (Find TextInputHandler::HandleKeyDownEvent or
|
|
|
|
// TextInputHandler::HandleKeyUpEvent in the log). Use the International system
|
2008-05-05 16:01:07 -07:00
|
|
|
// preferences widget to enable other keyboard layouts and select them from the
|
|
|
|
// input menu to see what keyboard events they generate.
|
|
|
|
// Note that it's possible to send bogus key events here, e.g.
|
|
|
|
// {keyCode:0, chars:"z", unmodifiedChars:"P"} --- sendNativeKeyEvent
|
|
|
|
// makes no attempt to verify that the keyCode matches the characters. So only
|
|
|
|
// test key event records that you saw Cocoa send.
|
|
|
|
|
|
|
|
// Ctrl keys
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_A, ctrl:1, chars:"\u0001", unmodifiedChars:"a"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_A, "a", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_A, ctrl:1, shift:1, chars:"\u0001", unmodifiedChars:"A"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_A, "A", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2008-05-05 16:01:07 -07:00
|
|
|
|
|
|
|
// Alt keys
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_A, alt:1, chars:"\u00e5", unmodifiedChars:"a"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_A, "\u00e5", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_A, alt:1, shift:1, chars:"\u00c5", unmodifiedChars:"A"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_A, "\u00c5", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2008-05-05 16:01:07 -07:00
|
|
|
|
|
|
|
// Command keys
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_A, command:1, chars:"a", unmodifiedChars:"a"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_A, "a", SHOULD_DELIVER_KEYDOWN_KEYPRESS, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2008-05-08 17:01:29 -07:00
|
|
|
// Shift-cmd gives us the shifted character
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_A, command:1, shift:1, chars:"a", unmodifiedChars:"A"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_A, "A", SHOULD_DELIVER_KEYDOWN_KEYPRESS, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2008-05-05 16:01:07 -07:00
|
|
|
// Ctrl-cmd gives us the unshifted character
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_A, command:1, ctrl:1, chars:"\u0001", unmodifiedChars:"a"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_A, "a", SHOULD_DELIVER_KEYDOWN_KEYPRESS, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2008-05-08 17:01:29 -07:00
|
|
|
// Alt-cmd gives us the shifted character
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_A, command:1, alt:1, chars:"\u00e5", unmodifiedChars:"a"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_A, "\u00e5", SHOULD_DELIVER_KEYDOWN_KEYPRESS, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_A, command:1, alt:1, shift:1, chars:"\u00c5", unmodifiedChars:"a"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_A, "\u00c5", SHOULD_DELIVER_KEYDOWN_KEYPRESS, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2008-05-05 16:01:07 -07:00
|
|
|
|
|
|
|
// Greek ctrl keys produce Latin charcodes
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"Greek", keyCode:MAC_VK_ANSI_A, ctrl:1, chars:"\u0001", unmodifiedChars:"\u03b1"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_A, "a", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"Greek", keyCode:MAC_VK_ANSI_A, ctrl:1, shift:1, chars:"\u0001", unmodifiedChars:"\u0391"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_A, "A", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2008-05-05 16:01:07 -07:00
|
|
|
|
|
|
|
// Greek command keys
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"Greek", keyCode:MAC_VK_ANSI_A, command:1, chars:"a", unmodifiedChars:"\u03b1"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_A, "a", SHOULD_DELIVER_KEYDOWN_KEYPRESS, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2008-05-08 17:01:29 -07:00
|
|
|
// Shift-cmd gives us the shifted character
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"Greek", keyCode:MAC_VK_ANSI_A, command:1, shift:1, chars:"a", unmodifiedChars:"\u0391"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_A, "A", SHOULD_DELIVER_KEYDOWN_KEYPRESS, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2008-05-05 16:01:07 -07:00
|
|
|
// Ctrl-cmd gives us the unshifted character
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"Greek", keyCode:MAC_VK_ANSI_A, command:1, ctrl:1, chars:"\u0001", unmodifiedChars:"\u03b1"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_A, "a", SHOULD_DELIVER_KEYDOWN_KEYPRESS, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2008-05-08 17:01:29 -07:00
|
|
|
// Alt-cmd gives us the shifted character
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"Greek", keyCode:MAC_VK_ANSI_A, command:1, alt:1, chars:"\u00a8", unmodifiedChars:"\u03b1"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_A, "\u00a8", SHOULD_DELIVER_KEYDOWN_KEYPRESS, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"Greek", keyCode:MAC_VK_ANSI_A, command:1, alt:1, shift:1, chars:"\u00b9", unmodifiedChars:"\u0391"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_A, "\u00b9", SHOULD_DELIVER_KEYDOWN_KEYPRESS, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2008-05-07 14:54:21 -07:00
|
|
|
|
2012-05-17 00:04:16 -07:00
|
|
|
// German
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"German", keyCode:MAC_VK_ANSI_A, chars:"a", unmodifiedChars:"a"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_A, "a", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"German", keyCode:MAC_VK_ANSI_LeftBracket, chars:"\u00fc", unmodifiedChars:"\u00fc"},
|
2012-07-18 18:28:17 -07:00
|
|
|
0, "\u00fc", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"German", keyCode:MAC_VK_ANSI_Minus, chars:"\u00df", unmodifiedChars:"\u00df"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_QUESTION_MARK, "\u00df", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"German", keyCode:MAC_VK_ANSI_Minus, shift:1, chars:"?", unmodifiedChars:"?"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_QUESTION_MARK, "?", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-05-17 00:04:16 -07:00
|
|
|
// Note that Shift+SS is '?' but Cmd+Shift+SS is '/' on German layout.
|
|
|
|
// Therefore, when Cmd key is pressed, the SS key's keycode is changed.
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"German", keyCode:MAC_VK_ANSI_Minus, command:1, chars:"\u00df", unmodifiedChars:"\u00df"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_SLASH, "\u00df", SHOULD_DELIVER_KEYDOWN_KEYPRESS, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"German", keyCode:MAC_VK_ANSI_Minus, command:1, shift:1, chars:"/", unmodifiedChars:"?"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_SLASH, "?", SHOULD_DELIVER_KEYDOWN_KEYPRESS, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2008-10-15 20:04:39 -07:00
|
|
|
|
|
|
|
// Caps Lock key event
|
|
|
|
// XXX keyup event of Caps Lock key is not fired.
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_CapsLock, capsLock:1, chars:"", unmodifiedChars:""},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_CAPS_LOCK, "", SHOULD_DELIVER_KEYDOWN, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_CapsLock, capsLock:0, chars:"", unmodifiedChars:""},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_CAPS_LOCK, "", SHOULD_DELIVER_KEYDOWN, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2008-10-18 01:37:59 -07:00
|
|
|
|
|
|
|
// Shift/RightShift key event
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_Shift, shift:1, chars:"", unmodifiedChars:""},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_SHIFT, "", SHOULD_DELIVER_KEYDOWN, KeyboardEvent.DOM_KEY_LOCATION_LEFT);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_Shift, shift:0, chars:"", unmodifiedChars:""},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_SHIFT, "", SHOULD_DELIVER_KEYUP, KeyboardEvent.DOM_KEY_LOCATION_LEFT);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_RightShift, shiftRight:1, chars:"", unmodifiedChars:""},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_SHIFT, "", SHOULD_DELIVER_KEYDOWN, KeyboardEvent.DOM_KEY_LOCATION_RIGHT);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_RightShift, shiftRight:0, chars:"", unmodifiedChars:""},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_SHIFT, "", SHOULD_DELIVER_KEYUP, KeyboardEvent.DOM_KEY_LOCATION_RIGHT);
|
2008-10-18 01:37:59 -07:00
|
|
|
|
|
|
|
// Control/RightControl key event
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_Control, ctrl:1, chars:"", unmodifiedChars:""},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_CONTROL, "", SHOULD_DELIVER_KEYDOWN, KeyboardEvent.DOM_KEY_LOCATION_LEFT);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_Control, ctrl:0, chars:"", unmodifiedChars:""},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_CONTROL, "", SHOULD_DELIVER_KEYUP, KeyboardEvent.DOM_KEY_LOCATION_LEFT);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_RightControl, ctrlRight:1, chars:"", unmodifiedChars:""},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_CONTROL, "", SHOULD_DELIVER_KEYDOWN, KeyboardEvent.DOM_KEY_LOCATION_RIGHT);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_RightControl, ctrlRight:0, chars:"", unmodifiedChars:""},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_CONTROL, "", SHOULD_DELIVER_KEYUP, KeyboardEvent.DOM_KEY_LOCATION_RIGHT);
|
2008-10-18 01:37:59 -07:00
|
|
|
|
|
|
|
// Option/RightOption key event
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_Option, alt:1, chars:"", unmodifiedChars:""},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_ALT, "", SHOULD_DELIVER_KEYDOWN, KeyboardEvent.DOM_KEY_LOCATION_LEFT);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_Option, alt:0, chars:"", unmodifiedChars:""},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_ALT, "", SHOULD_DELIVER_KEYUP, KeyboardEvent.DOM_KEY_LOCATION_LEFT);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_RightOption, altRight:1, chars:"", unmodifiedChars:""},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_ALT, "", SHOULD_DELIVER_KEYDOWN, KeyboardEvent.DOM_KEY_LOCATION_RIGHT);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_RightOption, altRight:0, chars:"", unmodifiedChars:""},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_ALT, "", SHOULD_DELIVER_KEYUP, KeyboardEvent.DOM_KEY_LOCATION_RIGHT);
|
2008-10-18 01:37:59 -07:00
|
|
|
|
|
|
|
// Command/RightCommand key event
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_Command, command:1, chars:"", unmodifiedChars:""},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_META, "", SHOULD_DELIVER_KEYDOWN, KeyboardEvent.DOM_KEY_LOCATION_LEFT);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_Command, command:0, chars:"", unmodifiedChars:""},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_META, "", SHOULD_DELIVER_KEYUP, KeyboardEvent.DOM_KEY_LOCATION_LEFT);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_RightCommand, commandRight:1, chars:"", unmodifiedChars:""},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_META, "", SHOULD_DELIVER_KEYDOWN, KeyboardEvent.DOM_KEY_LOCATION_RIGHT);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_RightCommand, commandRight:0, chars:"", unmodifiedChars:""},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_META, "", SHOULD_DELIVER_KEYUP, KeyboardEvent.DOM_KEY_LOCATION_RIGHT);
|
2012-03-29 20:37:40 -07:00
|
|
|
|
2012-05-17 00:04:16 -07:00
|
|
|
// all keys on keyboard (keyCode test)
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_Tab, chars:"\t", unmodifiedChars:"\t"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_TAB, "", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_KeypadClear, chars:"\uF739", unmodifiedChars:"\uF739"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_CLEAR, "", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_Return, chars:"\u000D", unmodifiedChars:"\u000D"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_RETURN, "", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_F15, chars:"\uF712", unmodifiedChars:"\uF712"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_PAUSE, "", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_Escape, chars:"\u001B", unmodifiedChars:"\u001B"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_ESCAPE, "", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_Space, chars:" ", unmodifiedChars:" "},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_SPACE, " ", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_PageUp, chars:"\uF72C", unmodifiedChars:"\uF72C"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_PAGE_UP, "", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_PageDown, chars:"\uF72D", unmodifiedChars:"\uF72D"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_PAGE_DOWN, "", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_End, chars:"\uF72B", unmodifiedChars:"\uF72B"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_END, "", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_Home, chars:"\uF729", unmodifiedChars:"\uF729"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_HOME, "", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_LeftArrow, chars:"\uF702", unmodifiedChars:"\uF702"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_LEFT, "", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_UpArrow, chars:"\uF700", unmodifiedChars:"\uF700"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_UP, "", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_RightArrow, chars:"\uF703", unmodifiedChars:"\uF703"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_RIGHT, "", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_DownArrow, chars:"\uF701", unmodifiedChars:"\uF701"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_DOWN, "", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_PC_PrintScreen, chars:"\uF710", unmodifiedChars:"\uF710"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_PRINTSCREEN, "", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_PC_Delete, chars:"\uF728", unmodifiedChars:"\uF728"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_DELETE, "", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_PC_Pause, chars:"\uF711", unmodifiedChars:"\uF711"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_SCROLL_LOCK, "", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-05-17 00:04:16 -07:00
|
|
|
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_F1, function:1, chars:"\uF704", unmodifiedChars:"\uF704"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_F1, "", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_F2, function:1, chars:"\uF705", unmodifiedChars:"\uF705"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_F2, "", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_F3, function:1, chars:"\uF706", unmodifiedChars:"\uF706"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_F3, "", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_F4, function:1, chars:"\uF707", unmodifiedChars:"\uF707"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_F4, "", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_F5, function:1, chars:"\uF708", unmodifiedChars:"\uF708"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_F5, "", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_F6, function:1, chars:"\uF709", unmodifiedChars:"\uF709"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_F6, "", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_F7, function:1, chars:"\uF70A", unmodifiedChars:"\uF70A"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_F7, "", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_F8, function:1, chars:"\uF70B", unmodifiedChars:"\uF70B"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_F8, "", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_F9, function:1, chars:"\uF70C", unmodifiedChars:"\uF70C"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_F9, "", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_F10, function:1, chars:"\uF70D", unmodifiedChars:"\uF70D"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_F10, "", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_F11, function:1, chars:"\uF70E", unmodifiedChars:"\uF70E"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_F11, "", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_F12, function:1, chars:"\uF70F", unmodifiedChars:"\uF70F"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_F12, "", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_F16, function:1, chars:"\uF713", unmodifiedChars:"\uF713"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_F16, "", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_F17, function:1, chars:"\uF714", unmodifiedChars:"\uF714"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_F17, "", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_F18, function:1, chars:"\uF715", unmodifiedChars:"\uF715"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_F18, "", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_F19, function:1, chars:"\uF716", unmodifiedChars:"\uF716"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_F19, "", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-05-17 00:04:16 -07:00
|
|
|
|
|
|
|
// US
|
|
|
|
// Alphabet
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_A, chars:"a", unmodifiedChars:"a"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_A, "a", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_A, shift:1, chars:"A", unmodifiedChars:"A"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_A, "A", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_A, ctrl:1, chars:"\u0001", unmodifiedChars:"a"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_A, "a", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_A, alt:1, chars:"\u00E5", unmodifiedChars:"a"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_A, "\u00E5", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_A, command:1, chars:"a", unmodifiedChars:"a"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_A, "a", SHOULD_DELIVER_KEYDOWN_KEYPRESS, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_B, chars:"b", unmodifiedChars:"b"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_B, "b", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_B, shift:1, chars:"B", unmodifiedChars:"B"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_B, "B", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_B, ctrl:1, chars:"\u0002", unmodifiedChars:"b"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_B, "b", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_B, alt:1, chars:"\u222B", unmodifiedChars:"b"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_B, "\u222B", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_B, command:1, chars:"b", unmodifiedChars:"b"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_B, "b", SHOULD_DELIVER_KEYDOWN_KEYPRESS, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_C, chars:"c", unmodifiedChars:"c"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_C, "c", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_C, shift:1, chars:"C", unmodifiedChars:"C"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_C, "C", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_C, ctrl:1, chars:"\u0003", unmodifiedChars:"c"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_C, "c", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_C, alt:1, chars:"\u00E7", unmodifiedChars:"c"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_C, "\u00E7", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_C, command:1, chars:"c", unmodifiedChars:"c"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_C, "c", SHOULD_DELIVER_KEYDOWN_KEYPRESS, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_D, chars:"d", unmodifiedChars:"d"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_D, "d", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_D, shift:1, chars:"D", unmodifiedChars:"D"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_D, "D", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_D, ctrl:1, chars:"\u0004", unmodifiedChars:"d"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_D, "d", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_D, alt:1, chars:"\u2202", unmodifiedChars:"d"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_D, "\u2202", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_D, command:1, chars:"d", unmodifiedChars:"d"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_D, "d", SHOULD_DELIVER_KEYDOWN_KEYPRESS, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_E, chars:"e", unmodifiedChars:"e"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_E, "e", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_E, shift:1, chars:"E", unmodifiedChars:"E"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_E, "E", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_E, ctrl:1, chars:"\u0005", unmodifiedChars:"e"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_E, "e", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_E, alt:1, chars:"", unmodifiedChars:"e"},
|
2013-04-23 20:49:47 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_E, "", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD); // dead key
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_E, command:1, chars:"e", unmodifiedChars:"e"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_E, "e", SHOULD_DELIVER_KEYDOWN_KEYPRESS, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_F, chars:"f", unmodifiedChars:"f"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_F, "f", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_F, shift:1, chars:"F", unmodifiedChars:"F"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_F, "F", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_F, ctrl:1, chars:"\u0006", unmodifiedChars:"f"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_F, "f", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_F, alt:1, chars:"\u0192", unmodifiedChars:"f"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_F, "\u0192", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-05-17 00:04:16 -07:00
|
|
|
// XXX This test starts fullscreen mode.
|
2012-06-26 19:26:38 -07:00
|
|
|
// testKey({layout:"US", keyCode:MAC_VK_ANSI_F, command:1, chars:"f", unmodifiedChars:"f"},
|
2012-07-18 18:28:17 -07:00
|
|
|
// nsIDOMKeyEvent.DOM_VK_F, "f", SHOULD_DELIVER_KEYDOWN_KEYPRESS, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_G, chars:"g", unmodifiedChars:"g"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_G, "g", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_G, shift:1, chars:"G", unmodifiedChars:"G"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_G, "G", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_G, ctrl:1, chars:"\u0007", unmodifiedChars:"g"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_G, "g", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_G, alt:1, chars:"\u00A9", unmodifiedChars:"g"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_G, "\u00A9", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_G, command:1, chars:"g", unmodifiedChars:"g"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_G, "g", SHOULD_DELIVER_KEYDOWN_KEYPRESS, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_H, chars:"h", unmodifiedChars:"h"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_H, "h", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_H, shift:1, chars:"H", unmodifiedChars:"H"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_H, "H", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_H, ctrl:1, chars:"\u0008", unmodifiedChars:"h"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_H, "h", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_H, alt:1, chars:"\u02D9", unmodifiedChars:"h"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_H, "\u02D9", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_H, command:1, chars:"h", unmodifiedChars:"h"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_H, "h", SHOULD_DELIVER_KEYDOWN_KEYPRESS, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_I, chars:"i", unmodifiedChars:"i"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_I, "i", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_I, shift:1, chars:"I", unmodifiedChars:"I"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_I, "I", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_I, ctrl:1, chars:"\u0009", unmodifiedChars:"i"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_I, "i", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_I, alt:1, chars:"", unmodifiedChars:"i"},
|
2013-04-23 20:49:47 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_I, "", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD); // dead key
|
2012-05-17 00:04:16 -07:00
|
|
|
// XXX This test causes memory leak.
|
2012-06-26 19:26:38 -07:00
|
|
|
// testKey({layout:"US", keyCode:MAC_VK_ANSI_I, command:1, chars:"i", unmodifiedChars:"i"},
|
2012-07-18 18:28:17 -07:00
|
|
|
// nsIDOMKeyEvent.DOM_VK_I, "i", SHOULD_DELIVER_KEYDOWN_KEYPRESS, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_J, chars:"j", unmodifiedChars:"j"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_J, "j", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_J, shift:1, chars:"J", unmodifiedChars:"J"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_J, "J", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_J, ctrl:1, chars:"\u000A", unmodifiedChars:"j"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_J, "j", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_J, alt:1, chars:"\u2206", unmodifiedChars:"j"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_J, "\u2206", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_J, command:1, chars:"j", unmodifiedChars:"j"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_J, "j", SHOULD_DELIVER_KEYDOWN_KEYPRESS, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_K, chars:"k", unmodifiedChars:"k"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_K, "k", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_K, shift:1, chars:"K", unmodifiedChars:"K"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_K, "K", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_K, ctrl:1, chars:"\u000B", unmodifiedChars:"k"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_K, "k", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_K, alt:1, chars:"\u02DA", unmodifiedChars:"k"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_K, "\u02DA", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_K, command:1, chars:"k", unmodifiedChars:"k"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_K, "k", SHOULD_DELIVER_KEYDOWN_KEYPRESS, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_L, chars:"l", unmodifiedChars:"l"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_L, "l", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_L, shift:1, chars:"L", unmodifiedChars:"L"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_L, "L", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_L, ctrl:1, chars:"\u000C", unmodifiedChars:"l"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_L, "l", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_L, alt:1, chars:"\u00AC", unmodifiedChars:"l"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_L, "\u00AC", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_L, command:1, chars:"l", unmodifiedChars:"l"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_L, "l", SHOULD_DELIVER_KEYDOWN_KEYPRESS, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_M, chars:"m", unmodifiedChars:"m"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_M, "m", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_M, shift:1, chars:"M", unmodifiedChars:"M"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_M, "M", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_M, ctrl:1, chars:"\u000D", unmodifiedChars:"m"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_M, "m", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_M, alt:1, chars:"\u00B5", unmodifiedChars:"m"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_M, "\u00B5", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_M, command:1, chars:"m", unmodifiedChars:"m"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_M, "m", SHOULD_DELIVER_KEYDOWN_KEYPRESS, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_N, chars:"n", unmodifiedChars:"n"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_N, "n", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_N, shift:1, chars:"N", unmodifiedChars:"N"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_N, "N", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_N, ctrl:1, chars:"\u000E", unmodifiedChars:"n"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_N, "n", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_N, alt:1, chars:"", unmodifiedChars:"n"},
|
2013-04-23 20:49:47 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_N, "", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD); // dead key
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_N, command:1, chars:"n", unmodifiedChars:"n"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_N, "n", SHOULD_DELIVER_KEYDOWN_KEYPRESS, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_O, chars:"o", unmodifiedChars:"o"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_O, "o", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_O, shift:1, chars:"O", unmodifiedChars:"O"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_O, "O", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_O, ctrl:1, chars:"\u000F", unmodifiedChars:"o"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_O, "o", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_O, alt:1, chars:"\u00F8", unmodifiedChars:"o"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_O, "\u00F8", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_O, command:1, chars:"o", unmodifiedChars:"o"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_O, "o", SHOULD_DELIVER_KEYDOWN_KEYPRESS, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_P, chars:"p", unmodifiedChars:"p"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_P, "p", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_P, shift:1, chars:"P", unmodifiedChars:"P"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_P, "P", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_P, ctrl:1, chars:"\u0010", unmodifiedChars:"p"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_P, "p", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_P, alt:1, chars:"\u03C0", unmodifiedChars:"p"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_P, "\u03C0", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-05-17 00:04:16 -07:00
|
|
|
// XXX This test starts private browsing mode (stopped at the confirmation dialog)
|
2012-06-26 19:26:38 -07:00
|
|
|
// testKey({layout:"US", keyCode:MAC_VK_ANSI_P, command:1, chars:"p", unmodifiedChars:"p"},
|
2012-07-18 18:28:17 -07:00
|
|
|
// nsIDOMKeyEvent.DOM_VK_P, "p", SHOULD_DELIVER_KEYDOWN_KEYPRESS, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_Q, chars:"q", unmodifiedChars:"q"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_Q, "q", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_Q, shift:1, chars:"Q", unmodifiedChars:"Q"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_Q, "Q", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_Q, ctrl:1, chars:"\u0011", unmodifiedChars:"q"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_Q, "q", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_Q, alt:1, chars:"\u0153", unmodifiedChars:"q"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_Q, "\u0153", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_Q, command:1, chars:"q", unmodifiedChars:"q"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_Q, "q", SHOULD_DELIVER_KEYDOWN_KEYPRESS, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_R, chars:"r", unmodifiedChars:"r"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_R, "r", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_R, shift:1, chars:"R", unmodifiedChars:"R"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_R, "R", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_R, ctrl:1, chars:"\u0012", unmodifiedChars:"r"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_R, "r", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_R, alt:1, chars:"\u00AE", unmodifiedChars:"r"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_R, "\u00AE", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-05-17 00:04:16 -07:00
|
|
|
// XXX This test makes some tabs and dialogs.
|
2012-06-26 19:26:38 -07:00
|
|
|
// testKey({layout:"US", keyCode:MAC_VK_ANSI_R, command:1, chars:"r", unmodifiedChars:"r"},
|
2012-07-18 18:28:17 -07:00
|
|
|
// nsIDOMKeyEvent.DOM_VK_R, "r", SHOULD_DELIVER_KEYDOWN_KEYPRESS, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_S, chars:"s", unmodifiedChars:"s"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_S, "s", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_S, shift:1, chars:"S", unmodifiedChars:"S"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_S, "S", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_S, ctrl:1, chars:"\u0013", unmodifiedChars:"s"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_S, "s", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_S, alt:1, chars:"\u00DF", unmodifiedChars:"s"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_S, "\u00DF", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_S, command:1, chars:"s", unmodifiedChars:"s"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_S, "s", SHOULD_DELIVER_KEYDOWN_KEYPRESS, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_T, chars:"t", unmodifiedChars:"t"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_T, "t", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_T, shift:1, chars:"T", unmodifiedChars:"T"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_T, "T", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_T, ctrl:1, chars:"\u0014", unmodifiedChars:"t"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_T, "t", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_T, alt:1, chars:"\u2020", unmodifiedChars:"t"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_T, "\u2020", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_T, command:1, chars:"t", unmodifiedChars:"t"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_T, "t", SHOULD_DELIVER_KEYDOWN_KEYPRESS, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_U, chars:"u", unmodifiedChars:"u"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_U, "u", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_U, shift:1, chars:"U", unmodifiedChars:"U"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_U, "U", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_U, ctrl:1, chars:"\u0015", unmodifiedChars:"u"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_U, "u", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_U, alt:1, chars:"", unmodifiedChars:"u"},
|
2013-04-23 20:49:47 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_U, "", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD); // dead key
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_U, command:1, chars:"u", unmodifiedChars:"u"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_U, "u", SHOULD_DELIVER_KEYDOWN_KEYPRESS, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_V, chars:"v", unmodifiedChars:"v"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_V, "v", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_V, shift:1, chars:"V", unmodifiedChars:"V"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_V, "V", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_V, ctrl:1, chars:"\u0016", unmodifiedChars:"v"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_V, "v", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_V, alt:1, chars:"\u221A", unmodifiedChars:"v"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_V, "\u221A", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_V, command:1, chars:"v", unmodifiedChars:"v"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_V, "v", SHOULD_DELIVER_KEYDOWN_KEYPRESS, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_W, chars:"w", unmodifiedChars:"w"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_W, "w", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_W, shift:1, chars:"W", unmodifiedChars:"W"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_W, "W", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_W, ctrl:1, chars:"\u0017", unmodifiedChars:"w"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_W, "w", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_W, alt:1, chars:"\u2211", unmodifiedChars:"w"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_W, "\u2211", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_W, command:1, chars:"w", unmodifiedChars:"w"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_W, "w", SHOULD_DELIVER_KEYDOWN_KEYPRESS, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_X, chars:"x", unmodifiedChars:"x"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_X, "x", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_X, shift:1, chars:"X", unmodifiedChars:"X"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_X, "X", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_X, ctrl:1, chars:"\u0018", unmodifiedChars:"x"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_X, "x", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_X, alt:1, chars:"\u2248", unmodifiedChars:"x"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_X, "\u2248", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_X, command:1, chars:"x", unmodifiedChars:"x"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_X, "x", SHOULD_DELIVER_KEYDOWN_KEYPRESS, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_Y, chars:"y", unmodifiedChars:"y"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_Y, "y", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_Y, shift:1, chars:"Y", unmodifiedChars:"Y"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_Y, "Y", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_Y, ctrl:1, chars:"\u0019", unmodifiedChars:"y"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_Y, "y", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_Y, alt:1, chars:"\u00A5", unmodifiedChars:"y"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_Y, "\u00A5", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_Y, command:1, chars:"y", unmodifiedChars:"y"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_Y, "y", SHOULD_DELIVER_KEYDOWN_KEYPRESS, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_Z, chars:"z", unmodifiedChars:"z"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_Z, "z", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_Z, shift:1, chars:"Z", unmodifiedChars:"Z"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_Z, "Z", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_Z, ctrl:1, chars:"\u001A", unmodifiedChars:"z"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_Z, "z", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_Z, alt:1, chars:"\u03A9", unmodifiedChars:"z"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_Z, "\u03A9", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_Z, command:1, chars:"z", unmodifiedChars:"z"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_Z, "z", SHOULD_DELIVER_KEYDOWN_KEYPRESS, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-05-17 00:04:16 -07:00
|
|
|
|
|
|
|
// numeric
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_1, chars:"1", unmodifiedChars:"1"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_1, "1", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_1, shift:1, chars:"!", unmodifiedChars:"!"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_1, "!", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_1, ctrl:1, chars:"1", unmodifiedChars:"1"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_1, "1", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_1, alt:1, chars:"\u00A1", unmodifiedChars:"1"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_1, "\u00A1", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_1, command:1, chars:"1", unmodifiedChars:"1"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_1, "1", SHOULD_DELIVER_KEYDOWN_KEYPRESS, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_2, chars:"2", unmodifiedChars:"2"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_2, "2", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_2, shift:1, chars:"@", unmodifiedChars:"@"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_2, "@", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_2, ctrl:1, chars:"2", unmodifiedChars:"2"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_2, "2", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_2, alt:1, chars:"\u00A1", unmodifiedChars:"2"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_2, "\u00A1", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_2, command:1, chars:"2", unmodifiedChars:"2"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_2, "2", SHOULD_DELIVER_KEYDOWN_KEYPRESS, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_3, chars:"3", unmodifiedChars:"3"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_3, "3", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_3, shift:1, chars:"#", unmodifiedChars:"#"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_3, "#", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_3, ctrl:1, chars:"3", unmodifiedChars:"3"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_3, "3", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_3, alt:1, chars:"\u00A3", unmodifiedChars:"3"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_3, "\u00A3", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_3, command:1, chars:"3", unmodifiedChars:"3"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_3, "3", SHOULD_DELIVER_KEYDOWN_KEYPRESS, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_4, chars:"4", unmodifiedChars:"4"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_4, "4", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_4, shift:1, chars:"$", unmodifiedChars:"$"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_4, "$", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_4, ctrl:1, chars:"4", unmodifiedChars:"4"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_4, "4", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_4, alt:1, chars:"\u00A2", unmodifiedChars:"4"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_4, "\u00A2", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_4, command:1, chars:"4", unmodifiedChars:"4"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_4, "4", SHOULD_DELIVER_KEYDOWN_KEYPRESS, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_5, chars:"5", unmodifiedChars:"5"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_5, "5", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_5, shift:1, chars:"%", unmodifiedChars:"%"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_5, "%", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_5, ctrl:1, chars:"5", unmodifiedChars:"5"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_5, "5", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_5, alt:1, chars:"\u221E", unmodifiedChars:"5"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_5, "\u221E", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_5, command:1, chars:"5", unmodifiedChars:"5"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_5, "5", SHOULD_DELIVER_KEYDOWN_KEYPRESS, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_6, chars:"6", unmodifiedChars:"6"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_6, "6", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_6, shift:1, chars:"^", unmodifiedChars:"^"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_6, "^", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_6, ctrl:1, chars:"6", unmodifiedChars:"6"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_6, "6", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_6, alt:1, chars:"\u00A7", unmodifiedChars:"6"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_6, "\u00A7", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_6, command:1, chars:"6", unmodifiedChars:"6"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_6, "6", SHOULD_DELIVER_KEYDOWN_KEYPRESS, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_7, chars:"7", unmodifiedChars:"7"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_7, "7", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_7, shift:1, chars:"\u0026;", unmodifiedChars:"\u0026;"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_7, "\u0026", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_7, ctrl:1, chars:"7", unmodifiedChars:"7"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_7, "7", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_7, alt:1, chars:"\u00B6", unmodifiedChars:"7"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_7, "\u00B6", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_7, command:1, chars:"7", unmodifiedChars:"7"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_7, "7", SHOULD_DELIVER_KEYDOWN_KEYPRESS, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_8, chars:"8", unmodifiedChars:"8"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_8, "8", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_8, shift:1, chars:"*", unmodifiedChars:"*"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_8, "*", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_8, ctrl:1, chars:"8", unmodifiedChars:"8"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_8, "8", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_8, alt:1, chars:"\u2022", unmodifiedChars:"8"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_8, "\u2022", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_8, command:1, chars:"8", unmodifiedChars:"8"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_8, "8", SHOULD_DELIVER_KEYDOWN_KEYPRESS, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_9, chars:"9", unmodifiedChars:"9"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_9, "9", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_9, shift:1, chars:"(", unmodifiedChars:"("},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_9, "(", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_9, ctrl:1, chars:"9", unmodifiedChars:"9"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_9, "9", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_9, alt:1, chars:"\u00AA", unmodifiedChars:"9"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_9, "\u00AA", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_9, command:1, chars:"9", unmodifiedChars:"9"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_9, "9", SHOULD_DELIVER_KEYDOWN_KEYPRESS, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_0, chars:"0", unmodifiedChars:"0"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_0, "0", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_0, shift:1, chars:")", unmodifiedChars:")"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_0, ")", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_0, ctrl:1, chars:"0", unmodifiedChars:"0"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_0, "0", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_0, alt:1, chars:"\u00BA", unmodifiedChars:"0"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_0, "\u00BA", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_0, command:1, chars:"0", unmodifiedChars:"0"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_0, "0", SHOULD_DELIVER_KEYDOWN_KEYPRESS, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-05-17 00:04:16 -07:00
|
|
|
|
|
|
|
// other chracters
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_Grave, chars:"`", unmodifiedChars:"`"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_BACK_QUOTE, "`", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_Grave, shift:1, chars:"~", unmodifiedChars:"~"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_BACK_QUOTE, "~", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_Grave, ctrl:1, chars:"`", unmodifiedChars:"`"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_BACK_QUOTE, "`", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_Grave, alt:1, chars:"", unmodifiedChars:"`"},
|
2013-04-23 20:49:47 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_BACK_QUOTE, "", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD); // dead key
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_Grave, command:1, chars:"`", unmodifiedChars:"`"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_BACK_QUOTE, "`", SHOULD_DELIVER_KEYDOWN_KEYPRESS, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_Minus, chars:"-", unmodifiedChars:"-"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_HYPHEN_MINUS, "-", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_Minus, shift:1, chars:"_", unmodifiedChars:"_"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_HYPHEN_MINUS, "_", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-05-17 00:04:16 -07:00
|
|
|
// TODO:
|
2012-06-26 19:26:38 -07:00
|
|
|
// testKey({layout:"US", keyCode:MAC_VK_ANSI_Minus, ctrl:1, chars:"\u001F", unmodifiedChars:"-"},
|
2012-07-18 18:28:17 -07:00
|
|
|
// nsIDOMKeyEvent.DOM_VK_HYPHEN_MINUS, "-", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_Minus, alt:1, chars:"\u2013", unmodifiedChars:"-"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_HYPHEN_MINUS, "\u2013", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_Minus, command:1, chars:"-", unmodifiedChars:"-"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_HYPHEN_MINUS, "-", SHOULD_DELIVER_KEYDOWN_KEYPRESS, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_Equal, chars:"=", unmodifiedChars:"="},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_EQUALS, "=", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_Equal, shift:1, chars:"+", unmodifiedChars:"+"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_EQUALS, "+", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_Equal, ctrl:1, chars:"=", unmodifiedChars:"="},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_EQUALS, "=", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_Equal, alt:1, chars:"\u2260", unmodifiedChars:"="},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_EQUALS, "\u2260", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_Equal, command:1, chars:"=", unmodifiedChars:"="},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_EQUALS, "=", SHOULD_DELIVER_KEYDOWN_KEYPRESS, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_LeftBracket, chars:"[", unmodifiedChars:"["},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_OPEN_BRACKET, "[", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_LeftBracket, shift:1, chars:"{", unmodifiedChars:"{"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_OPEN_BRACKET, "{", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-05-17 00:04:16 -07:00
|
|
|
// TODO:
|
2012-06-26 19:26:38 -07:00
|
|
|
// testKey({layout:"US", keyCode:MAC_VK_ANSI_LeftBracket, ctrl:1, chars:"\u001B", unmodifiedChars:"["},
|
2012-07-18 18:28:17 -07:00
|
|
|
// nsIDOMKeyEvent.DOM_VK_OPEN_BRACKET, "[", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_LeftBracket, alt:1, chars:"\u201C", unmodifiedChars:"["},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_OPEN_BRACKET, "\u201C", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_LeftBracket, command:1, chars:"[", unmodifiedChars:"["},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_OPEN_BRACKET, "[", SHOULD_DELIVER_KEYDOWN_KEYPRESS, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_RightBracket, chars:"]", unmodifiedChars:"]"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_CLOSE_BRACKET, "]", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_RightBracket, shift:1, chars:"}", unmodifiedChars:"}"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_CLOSE_BRACKET, "}", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-05-17 00:04:16 -07:00
|
|
|
// TODO:
|
2012-06-26 19:26:38 -07:00
|
|
|
// testKey({layout:"US", keyCode:MAC_VK_ANSI_RightBracket, ctrl:1, chars:"\u001D", unmodifiedChars:"]"},
|
2012-07-18 18:28:17 -07:00
|
|
|
// nsIDOMKeyEvent.DOM_VK_CLOSE_BRACKET, "]", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_RightBracket, alt:1, chars:"\u2018", unmodifiedChars:"]"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_CLOSE_BRACKET, "\u2018", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_RightBracket, command:1, chars:"]", unmodifiedChars:"]"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_CLOSE_BRACKET, "]", SHOULD_DELIVER_KEYDOWN_KEYPRESS, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_Backslash, chars:"\\", unmodifiedChars:"\\"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_BACK_SLASH, "\\", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_Backslash, shift:1, chars:"|", unmodifiedChars:"|"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_BACK_SLASH, "|", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-05-17 00:04:16 -07:00
|
|
|
// TODO:
|
2012-06-26 19:26:38 -07:00
|
|
|
// testKey({layout:"US", keyCode:MAC_VK_ANSI_Backslash, ctrl:1, chars:"\u001C", unmodifiedChars:"\\"},
|
2012-07-18 18:28:17 -07:00
|
|
|
// nsIDOMKeyEvent.DOM_VK_BACK_SLASH, "\\", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_Backslash, alt:1, chars:"\u00AB", unmodifiedChars:"\\"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_BACK_SLASH, "\u00AB", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_Backslash, command:1, chars:"\\", unmodifiedChars:"\\"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_BACK_SLASH, "\\", SHOULD_DELIVER_KEYDOWN_KEYPRESS, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_Semicolon, chars:";", unmodifiedChars:";"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_SEMICOLON, ";", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_Semicolon, shift:1, chars:":", unmodifiedChars:":"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_SEMICOLON, ":", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_Semicolon, ctrl:1, chars:";", unmodifiedChars:";"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_SEMICOLON, ";", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_Semicolon, alt:1, chars:"\u2026", unmodifiedChars:";"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_SEMICOLON, "\u2026", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_Semicolon, command:1, chars:";", unmodifiedChars:";"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_SEMICOLON, ";", SHOULD_DELIVER_KEYDOWN_KEYPRESS, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_Quote, chars:"'", unmodifiedChars:"'"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_QUOTE, "'", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_Quote, shift:1, chars:"\"", unmodifiedChars:"\""},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_QUOTE, "\"", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_Quote, ctrl:1, chars:"'", unmodifiedChars:"'"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_QUOTE, "'", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_Quote, alt:1, chars:"\u00E6", unmodifiedChars:"'"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_QUOTE, "\u00E6", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_Quote, command:1, chars:"'", unmodifiedChars:"'"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_QUOTE, "'", SHOULD_DELIVER_KEYDOWN_KEYPRESS, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_Comma, chars:",", unmodifiedChars:","},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_COMMA, ",", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_Comma, shift:1, chars:"\u003C", unmodifiedChars:"\u003C"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_COMMA, "\u003C", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_Comma, ctrl:1, chars:",", unmodifiedChars:","},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_COMMA, ",", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_Comma, alt:1, chars:"\u2264", unmodifiedChars:","},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_COMMA, "\u2264", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_Comma, command:1, chars:",", unmodifiedChars:","},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_COMMA, ",", SHOULD_DELIVER_KEYDOWN_KEYPRESS, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_Period, chars:".", unmodifiedChars:"."},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_PERIOD, ".", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_Period, shift:1, chars:"\u003E", unmodifiedChars:"\u003E"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_PERIOD, "\u003E", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_Period, ctrl:1, chars:".", unmodifiedChars:"."},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_PERIOD, ".", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_Period, alt:1, chars:"\u2265", unmodifiedChars:"."},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_PERIOD, "\u2265", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_Period, command:1, chars:".", unmodifiedChars:"."},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_PERIOD, ".", SHOULD_DELIVER_KEYDOWN_KEYPRESS, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_Slash, chars:"/", unmodifiedChars:"/"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_SLASH, "/", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_Slash, shift:1, chars:"?", unmodifiedChars:"?"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_SLASH, "?", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_Slash, ctrl:1, chars:"/", unmodifiedChars:"/"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_SLASH, "/", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_Slash, alt:1, chars:"\u00F7", unmodifiedChars:"/"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_SLASH, "\u00F7", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_Slash, command:1, chars:"/", unmodifiedChars:"/"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_SLASH, "/", SHOULD_DELIVER_KEYDOWN_KEYPRESS, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-05-17 00:04:16 -07:00
|
|
|
|
|
|
|
// numpad
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_Keypad1, numLock:1, chars:"1", unmodifiedChars:"1"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_NUMPAD1, "1", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_NUMPAD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_Keypad1, numLock:1, shift:1, chars:"1", unmodifiedChars:"1"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_NUMPAD1, "1", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_NUMPAD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_Keypad1, numLock:1, ctrl:1, chars:"1", unmodifiedChars:"1"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_NUMPAD1, "1", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_NUMPAD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_Keypad1, numLock:1, alt:1, chars:"1", unmodifiedChars:"1"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_NUMPAD1, "1", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_NUMPAD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_Keypad1, numLock:1, command:1, chars:"1", unmodifiedChars:"1"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_NUMPAD1, "1", SHOULD_DELIVER_KEYDOWN_KEYPRESS, KeyboardEvent.DOM_KEY_LOCATION_NUMPAD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_Keypad2, numLock:1, chars:"2", unmodifiedChars:"2"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_NUMPAD2, "2", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_NUMPAD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_Keypad2, numLock:1, shift:1, chars:"2", unmodifiedChars:"2"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_NUMPAD2, "2", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_NUMPAD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_Keypad2, numLock:1, ctrl:1, chars:"2", unmodifiedChars:"2"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_NUMPAD2, "2", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_NUMPAD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_Keypad2, numLock:1, alt:1, chars:"2", unmodifiedChars:"2"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_NUMPAD2, "2", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_NUMPAD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_Keypad2, numLock:1, command:1, chars:"2", unmodifiedChars:"2"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_NUMPAD2, "2", SHOULD_DELIVER_KEYDOWN_KEYPRESS, KeyboardEvent.DOM_KEY_LOCATION_NUMPAD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_Keypad3, numLock:1, chars:"3", unmodifiedChars:"3"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_NUMPAD3, "3", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_NUMPAD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_Keypad3, numLock:1, shift:1, chars:"3", unmodifiedChars:"3"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_NUMPAD3, "3", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_NUMPAD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_Keypad3, numLock:1, ctrl:1, chars:"3", unmodifiedChars:"3"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_NUMPAD3, "3", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_NUMPAD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_Keypad3, numLock:1, alt:1, chars:"3", unmodifiedChars:"3"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_NUMPAD3, "3", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_NUMPAD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_Keypad3, numLock:1, command:1, chars:"3", unmodifiedChars:"3"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_NUMPAD3, "3", SHOULD_DELIVER_KEYDOWN_KEYPRESS, KeyboardEvent.DOM_KEY_LOCATION_NUMPAD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_Keypad4, numLock:1, chars:"4", unmodifiedChars:"4"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_NUMPAD4, "4", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_NUMPAD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_Keypad4, numLock:1, shift:1, chars:"4", unmodifiedChars:"4"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_NUMPAD4, "4", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_NUMPAD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_Keypad4, numLock:1, ctrl:1, chars:"4", unmodifiedChars:"4"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_NUMPAD4, "4", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_NUMPAD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_Keypad4, numLock:1, alt:1, chars:"4", unmodifiedChars:"4"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_NUMPAD4, "4", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_NUMPAD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_Keypad4, numLock:1, command:1, chars:"4", unmodifiedChars:"4"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_NUMPAD4, "4", SHOULD_DELIVER_KEYDOWN_KEYPRESS, KeyboardEvent.DOM_KEY_LOCATION_NUMPAD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_Keypad5, numLock:1, chars:"5", unmodifiedChars:"5"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_NUMPAD5, "5", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_NUMPAD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_Keypad5, numLock:1, shift:1, chars:"5", unmodifiedChars:"5"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_NUMPAD5, "5", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_NUMPAD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_Keypad5, numLock:1, ctrl:1, chars:"5", unmodifiedChars:"5"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_NUMPAD5, "5", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_NUMPAD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_Keypad5, numLock:1, alt:1, chars:"5", unmodifiedChars:"5"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_NUMPAD5, "5", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_NUMPAD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_Keypad5, numLock:1, command:1, chars:"5", unmodifiedChars:"5"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_NUMPAD5, "5", SHOULD_DELIVER_KEYDOWN_KEYPRESS, KeyboardEvent.DOM_KEY_LOCATION_NUMPAD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_Keypad6, numLock:1, chars:"6", unmodifiedChars:"6"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_NUMPAD6, "6", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_NUMPAD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_Keypad6, numLock:1, shift:1, chars:"6", unmodifiedChars:"6"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_NUMPAD6, "6", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_NUMPAD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_Keypad6, numLock:1, ctrl:1, chars:"6", unmodifiedChars:"6"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_NUMPAD6, "6", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_NUMPAD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_Keypad6, numLock:1, alt:1, chars:"6", unmodifiedChars:"6"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_NUMPAD6, "6", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_NUMPAD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_Keypad6, numLock:1, command:1, chars:"6", unmodifiedChars:"6"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_NUMPAD6, "6", SHOULD_DELIVER_KEYDOWN_KEYPRESS, KeyboardEvent.DOM_KEY_LOCATION_NUMPAD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_Keypad7, numLock:1, chars:"7", unmodifiedChars:"7"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_NUMPAD7, "7", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_NUMPAD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_Keypad7, numLock:1, shift:1, chars:"7", unmodifiedChars:"7"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_NUMPAD7, "7", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_NUMPAD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_Keypad7, numLock:1, ctrl:1, chars:"7", unmodifiedChars:"7"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_NUMPAD7, "7", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_NUMPAD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_Keypad7, numLock:1, alt:1, chars:"7", unmodifiedChars:"7"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_NUMPAD7, "7", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_NUMPAD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_Keypad7, numLock:1, command:1, chars:"7", unmodifiedChars:"7"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_NUMPAD7, "7", SHOULD_DELIVER_KEYDOWN_KEYPRESS, KeyboardEvent.DOM_KEY_LOCATION_NUMPAD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_Keypad8, numLock:1, chars:"8", unmodifiedChars:"8"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_NUMPAD8, "8", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_NUMPAD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_Keypad8, numLock:1, shift:1, chars:"8", unmodifiedChars:"8"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_NUMPAD8, "8", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_NUMPAD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_Keypad8, numLock:1, ctrl:1, chars:"8", unmodifiedChars:"8"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_NUMPAD8, "8", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_NUMPAD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_Keypad8, numLock:1, alt:1, chars:"8", unmodifiedChars:"8"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_NUMPAD8, "8", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_NUMPAD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_Keypad8, numLock:1, command:1, chars:"8", unmodifiedChars:"8"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_NUMPAD8, "8", SHOULD_DELIVER_KEYDOWN_KEYPRESS, KeyboardEvent.DOM_KEY_LOCATION_NUMPAD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_Keypad9, numLock:1, chars:"9", unmodifiedChars:"9"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_NUMPAD9, "9", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_NUMPAD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_Keypad9, numLock:1, shift:1, chars:"9", unmodifiedChars:"9"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_NUMPAD9, "9", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_NUMPAD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_Keypad9, numLock:1, ctrl:1, chars:"9", unmodifiedChars:"9"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_NUMPAD9, "9", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_NUMPAD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_Keypad9, numLock:1, alt:1, chars:"9", unmodifiedChars:"9"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_NUMPAD9, "9", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_NUMPAD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_Keypad9, numLock:1, command:1, chars:"9", unmodifiedChars:"9"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_NUMPAD9, "9", SHOULD_DELIVER_KEYDOWN_KEYPRESS, KeyboardEvent.DOM_KEY_LOCATION_NUMPAD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_Keypad0, numLock:1, chars:"0", unmodifiedChars:"0"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_NUMPAD0, "0", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_NUMPAD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_Keypad0, numLock:1, shift:1, chars:"0", unmodifiedChars:"0"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_NUMPAD0, "0", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_NUMPAD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_Keypad0, numLock:1, ctrl:1, chars:"0", unmodifiedChars:"0"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_NUMPAD0, "0", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_NUMPAD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_Keypad0, numLock:1, alt:1, chars:"0", unmodifiedChars:"0"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_NUMPAD0, "0", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_NUMPAD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_Keypad0, numLock:1, command:1, chars:"0", unmodifiedChars:"0"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_NUMPAD0, "0", SHOULD_DELIVER_KEYDOWN_KEYPRESS, KeyboardEvent.DOM_KEY_LOCATION_NUMPAD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_KeypadEquals, numLock:1, chars:"=", unmodifiedChars:"="},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_EQUALS, "=", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_NUMPAD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_KeypadEquals, numLock:1, shift:1, chars:"=", unmodifiedChars:"="},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_EQUALS, "=", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_NUMPAD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_KeypadEquals, numLock:1, ctrl:1, chars:"=", unmodifiedChars:"="},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_EQUALS, "=", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_NUMPAD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_KeypadEquals, numLock:1, alt:1, chars:"=", unmodifiedChars:"="},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_EQUALS, "=", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_NUMPAD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_KeypadEquals, numLock:1, command:1, chars:"=", unmodifiedChars:"="},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_EQUALS, "=", SHOULD_DELIVER_KEYDOWN_KEYPRESS, KeyboardEvent.DOM_KEY_LOCATION_NUMPAD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_KeypadDivide, numLock:1, chars:"/", unmodifiedChars:"/"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_DIVIDE, "/", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_NUMPAD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_KeypadDivide, numLock:1, shift:1, chars:"/", unmodifiedChars:"/"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_DIVIDE, "/", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_NUMPAD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_KeypadDivide, numLock:1, ctrl:1, chars:"/", unmodifiedChars:"/"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_DIVIDE, "/", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_NUMPAD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_KeypadDivide, numLock:1, alt:1, chars:"/", unmodifiedChars:"/"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_DIVIDE, "/", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_NUMPAD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_KeypadDivide, numLock:1, command:1, chars:"/", unmodifiedChars:"/"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_DIVIDE, "/", SHOULD_DELIVER_KEYDOWN_KEYPRESS, KeyboardEvent.DOM_KEY_LOCATION_NUMPAD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_KeypadMultiply, numLock:1, chars:"*", unmodifiedChars:"*"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_MULTIPLY, "*", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_NUMPAD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_KeypadMultiply, numLock:1, shift:1, chars:"*", unmodifiedChars:"*"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_MULTIPLY, "*", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_NUMPAD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_KeypadMultiply, numLock:1, ctrl:1, chars:"*", unmodifiedChars:"*"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_MULTIPLY, "*", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_NUMPAD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_KeypadMultiply, numLock:1, alt:1, chars:"*", unmodifiedChars:"*"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_MULTIPLY, "*", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_NUMPAD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_KeypadMultiply, numLock:1, command:1, chars:"*", unmodifiedChars:"*"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_MULTIPLY, "*", SHOULD_DELIVER_KEYDOWN_KEYPRESS, KeyboardEvent.DOM_KEY_LOCATION_NUMPAD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_KeypadMinus, numLock:1, chars:"-", unmodifiedChars:"-"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_SUBTRACT, "-", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_NUMPAD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_KeypadMinus, numLock:1, shift:1, chars:"-", unmodifiedChars:"-"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_SUBTRACT, "-", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_NUMPAD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_KeypadMinus, numLock:1, ctrl:1, chars:"-", unmodifiedChars:"-"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_SUBTRACT, "-", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_NUMPAD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_KeypadMinus, numLock:1, alt:1, chars:"-", unmodifiedChars:"-"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_SUBTRACT, "-", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_NUMPAD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_KeypadMinus, numLock:1, command:1, chars:"-", unmodifiedChars:"-"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_SUBTRACT, "-", SHOULD_DELIVER_KEYDOWN_KEYPRESS, KeyboardEvent.DOM_KEY_LOCATION_NUMPAD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_KeypadPlus, numLock:1, chars:"+", unmodifiedChars:"+"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_ADD, "+", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_NUMPAD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_KeypadPlus, numLock:1, shift:1, chars:"+", unmodifiedChars:"+"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_ADD, "+", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_NUMPAD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_KeypadPlus, numLock:1, ctrl:1, chars:"+", unmodifiedChars:"+"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_ADD, "+", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_NUMPAD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_KeypadPlus, numLock:1, alt:1, chars:"+", unmodifiedChars:"+"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_ADD, "+", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_NUMPAD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_KeypadPlus, numLock:1, command:1, chars:"+", unmodifiedChars:"+"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_ADD, "+", SHOULD_DELIVER_KEYDOWN_KEYPRESS, KeyboardEvent.DOM_KEY_LOCATION_NUMPAD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_KeypadEnter, numLock:1, chars:"\u0003", unmodifiedChars:"\u0003"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_RETURN, "", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_NUMPAD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_KeypadEnter, numLock:1, shift:1, chars:"\u0003", unmodifiedChars:"\u0003"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_RETURN, "", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_NUMPAD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_KeypadEnter, numLock:1, ctrl:1, chars:"\u0003", unmodifiedChars:"\u0003"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_RETURN, "", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_NUMPAD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_KeypadEnter, numLock:1, alt:1, chars:"\u0003", unmodifiedChars:"\u0003"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_RETURN, "", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_NUMPAD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_KeypadEnter, numLock:1, command:1, chars:"\u0003", unmodifiedChars:"\u0003"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_RETURN, "", SHOULD_DELIVER_KEYDOWN_KEYPRESS, KeyboardEvent.DOM_KEY_LOCATION_NUMPAD);
|
2012-05-17 00:04:16 -07:00
|
|
|
|
|
|
|
// French, numeric
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:MAC_VK_ANSI_1, chars:"\u0026", unmodifiedChars:"\u0026"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_1, "\u0026", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:MAC_VK_ANSI_1, shift:1, chars:"1", unmodifiedChars:"1"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_1, "1", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:MAC_VK_ANSI_1, ctrl:1, chars:"1", unmodifiedChars:"\u0026"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_1, "1", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:MAC_VK_ANSI_1, command:1, chars:"\u0026", unmodifiedChars:"\u0026"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_1, "1", SHOULD_DELIVER_KEYDOWN_KEYPRESS, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:MAC_VK_ANSI_2, chars:"\u00E9", unmodifiedChars:"\u00E9"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_2, "\u00E9", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:MAC_VK_ANSI_2, shift:1, chars:"2", unmodifiedChars:"2"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_2, "2", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:MAC_VK_ANSI_2, ctrl:1, chars:"2", unmodifiedChars:"\u00E9"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_2, "2", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:MAC_VK_ANSI_2, command:1, chars:"\u00E9", unmodifiedChars:"\u00E9"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_2, "2", SHOULD_DELIVER_KEYDOWN_KEYPRESS, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:MAC_VK_ANSI_3, chars:"\"", unmodifiedChars:"\""},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_3, "\"", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:MAC_VK_ANSI_3, shift:1, chars:"3", unmodifiedChars:"3"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_3, "3", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:MAC_VK_ANSI_3, ctrl:1, chars:"3", unmodifiedChars:"\""},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_3, "3", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:MAC_VK_ANSI_3, command:1, chars:"\"", unmodifiedChars:"\""},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_3, "3", SHOULD_DELIVER_KEYDOWN_KEYPRESS, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:MAC_VK_ANSI_4, chars:"'", unmodifiedChars:"'"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_4, "'", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:MAC_VK_ANSI_4, shift:1, chars:"4", unmodifiedChars:"4"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_4, "4", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:MAC_VK_ANSI_4, ctrl:1, chars:"4", unmodifiedChars:"'"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_4, "4", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:MAC_VK_ANSI_4, command:1, chars:"'", unmodifiedChars:"'"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_4, "4", SHOULD_DELIVER_KEYDOWN_KEYPRESS, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:MAC_VK_ANSI_5, chars:"(", unmodifiedChars:"("},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_5, "(", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:MAC_VK_ANSI_5, shift:1, chars:"5", unmodifiedChars:"5"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_5, "5", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:MAC_VK_ANSI_5, ctrl:1, chars:"5", unmodifiedChars:"("},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_5, "5", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:MAC_VK_ANSI_5, command:1, chars:"(", unmodifiedChars:"("},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_5, "5", SHOULD_DELIVER_KEYDOWN_KEYPRESS, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:MAC_VK_ANSI_6, chars:"\u00A7", unmodifiedChars:"\u00A7"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_6, "\u00A7", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:MAC_VK_ANSI_6, shift:1, chars:"6", unmodifiedChars:"6"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_6, "6", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-05-17 00:04:16 -07:00
|
|
|
// TODO:
|
2012-06-26 19:26:38 -07:00
|
|
|
// testKey({layout:"French", keyCode:MAC_VK_ANSI_6, ctrl:1, chars:"\u001D", unmodifiedChars:"\u00A7"},
|
2012-07-18 18:28:17 -07:00
|
|
|
// nsIDOMKeyEvent.DOM_VK_6, "", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD); // Ctrl+6 sets strange char
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:MAC_VK_ANSI_6, command:1, chars:"\u00A7", unmodifiedChars:"\u00A7"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_6, "6", SHOULD_DELIVER_KEYDOWN_KEYPRESS, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:MAC_VK_ANSI_7, chars:"\u00E8", unmodifiedChars:"\u00E8"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_7, "\u00E8", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:MAC_VK_ANSI_7, shift:1, chars:"7", unmodifiedChars:"7"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_7, "7", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:MAC_VK_ANSI_7, ctrl:1, chars:"7", unmodifiedChars:"\u00E8"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_7, "7", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:MAC_VK_ANSI_7, command:1, chars:"\u00E8", unmodifiedChars:"\u00E8"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_7, "7", SHOULD_DELIVER_KEYDOWN_KEYPRESS, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:MAC_VK_ANSI_8, chars:"!", unmodifiedChars:"!"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_8, "!", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:MAC_VK_ANSI_8, shift:1, chars:"8", unmodifiedChars:"8"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_8, "8", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:MAC_VK_ANSI_8, ctrl:1, chars:"8", unmodifiedChars:"!"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_8, "8", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:MAC_VK_ANSI_8, command:1, chars:"!", unmodifiedChars:"!"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_8, "8", SHOULD_DELIVER_KEYDOWN_KEYPRESS, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:MAC_VK_ANSI_9, chars:"\u00E7", unmodifiedChars:"\u00E7"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_9, "\u00E7", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:MAC_VK_ANSI_9, shift:1, chars:"9", unmodifiedChars:"9"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_9, "9", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-05-17 00:04:16 -07:00
|
|
|
// TODO:
|
2012-06-26 19:26:38 -07:00
|
|
|
// testKey({layout:"French", keyCode:MAC_VK_ANSI_9, ctrl:1, chars:"\u001C", unmodifiedChars:"\u00E7"},
|
2012-07-18 18:28:17 -07:00
|
|
|
// nsIDOMKeyEvent.DOM_VK_9, "", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD); // Ctrl+9 sets strange char
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:MAC_VK_ANSI_9, command:1, chars:"\u00E7", unmodifiedChars:"\u00E7"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_9, "9", SHOULD_DELIVER_KEYDOWN_KEYPRESS, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:MAC_VK_ANSI_0, chars:"\u00E0", unmodifiedChars:"\u00E0"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_0, "\u00E0", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:MAC_VK_ANSI_0, shift:1, chars:"0", unmodifiedChars:"0"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_0, "0", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-05-17 00:04:16 -07:00
|
|
|
// XXX No events fired, not sure the reason.
|
2012-06-26 19:26:38 -07:00
|
|
|
// testKey({layout:"French", keyCode:MAC_VK_ANSI_0, ctrl:1, chars:"", unmodifiedChars:"\u00E0"},
|
2012-07-18 18:28:17 -07:00
|
|
|
// nsIDOMKeyEvent.DOM_VK_0, "", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:MAC_VK_ANSI_0, command:1, chars:"\u00E0", unmodifiedChars:"\u00E0"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_0, "0", SHOULD_DELIVER_KEYDOWN_KEYPRESS, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-05-17 00:04:16 -07:00
|
|
|
|
|
|
|
// Thai
|
|
|
|
// keycode should be DOM_VK_[A-Z] of the key on the latest ASCII capable keyboard layout is for alphabet
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"Thai", keyCode:MAC_VK_ANSI_A, chars:"\u0E1F", unmodifiedChars:"\u0E1F"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_A, "\u0E1F", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-05-17 00:04:16 -07:00
|
|
|
// keycode should be shifted character if unshifted character isn't an ASCII character
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"Thai", keyCode:MAC_VK_ANSI_Quote, chars:"\u0E07", unmodifiedChars:"\u0E07"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_PERIOD, "\u0E07", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-05-17 00:04:16 -07:00
|
|
|
// keycode should be zero if the character of the key on the latest ASCII capable keyboard layout isn't for alphabet
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"Thai", keyCode:MAC_VK_ANSI_Period, chars:"\u0E43", unmodifiedChars:"\u0E43"},
|
2012-07-18 18:28:17 -07:00
|
|
|
0, "\u0E43", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-05-17 00:04:16 -07:00
|
|
|
// keycode should be DOM_VK_[0-9] if the key on the latest ASCII capable keyboard layout is for numeric
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"Thai", keyCode:MAC_VK_ANSI_1, chars:"\u0E45", unmodifiedChars:"\u0E45"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_1, "\u0E45", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"Thai", keyCode:MAC_VK_ANSI_2, chars:"/", unmodifiedChars:"/"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_2, "/", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"Thai", keyCode:MAC_VK_ANSI_3, chars:"_", unmodifiedChars:"_"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_3, "_", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"Thai", keyCode:MAC_VK_ANSI_4, chars:"\u0E20", unmodifiedChars:"\u0E20"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_4, "\u0E20", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"Thai", keyCode:MAC_VK_ANSI_5, chars:"\u0E16", unmodifiedChars:"\u0E16"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_5, "\u0E16", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"Thai", keyCode:MAC_VK_ANSI_6, chars:"\u0E38", unmodifiedChars:"\u0E38"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_6, "\u0E38", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"Thai", keyCode:MAC_VK_ANSI_7, chars:"\u0E36", unmodifiedChars:"\u0E36"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_7, "\u0E36", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"Thai", keyCode:MAC_VK_ANSI_8, chars:"\u0E04", unmodifiedChars:"\u0E04"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_8, "\u0E04", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"Thai", keyCode:MAC_VK_ANSI_9, chars:"\u0E15", unmodifiedChars:"\u0E15"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_9, "\u0E15", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"Thai", keyCode:MAC_VK_ANSI_0, chars:"\u0E08", unmodifiedChars:"\u0E08"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_0, "\u0E08", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-05-17 00:04:16 -07:00
|
|
|
|
|
|
|
// Dvorak-Qwerty, layout should be changed when Command key is pressed.
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"Dvorak-Qwerty", keyCode:MAC_VK_ANSI_S, chars:"o", unmodifiedChars:"o"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_O, "o", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"Dvorak-Qwerty", keyCode:MAC_VK_ANSI_S, shift:1, chars:"O", unmodifiedChars:"O"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_O, "O", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"Dvorak-Qwerty", keyCode:MAC_VK_ANSI_S, ctrl:1, chars:"\u000F", unmodifiedChars:"o"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_O, "o", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"Dvorak-Qwerty", keyCode:MAC_VK_ANSI_S, alt:1, chars:"\u00F8", unmodifiedChars:"o"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_O, "\u00F8", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"Dvorak-Qwerty", keyCode:MAC_VK_ANSI_S, command:1, chars:"s", unmodifiedChars:"o"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_S, "s", SHOULD_DELIVER_KEYDOWN_KEYPRESS, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"Dvorak-Qwerty", keyCode:MAC_VK_ANSI_D, chars:"e", unmodifiedChars:"e"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_E, "e", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"Dvorak-Qwerty", keyCode:MAC_VK_ANSI_D, shift:1, chars:"E", unmodifiedChars:"E"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_E, "E", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"Dvorak-Qwerty", keyCode:MAC_VK_ANSI_D, ctrl:1, chars:"\u0005", unmodifiedChars:"e"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_E, "e", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"Dvorak-Qwerty", keyCode:MAC_VK_ANSI_D, alt:1, chars:"", unmodifiedChars:"e"},
|
2013-04-23 20:49:47 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_E, "", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD); // dead key
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"Dvorak-Qwerty", keyCode:MAC_VK_ANSI_D, command:1, chars:"d", unmodifiedChars:"e"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_D, "d", SHOULD_DELIVER_KEYDOWN_KEYPRESS, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"Dvorak-Qwerty", keyCode:MAC_VK_ANSI_I, command:1, alt:1, chars:"^", unmodifiedChars:"c"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_I, "^", SHOULD_DELIVER_KEYDOWN_KEYPRESS, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"Dvorak-Qwerty", keyCode:MAC_VK_ANSI_I, command:1, alt:1, shift:1, chars:"\u02C6", unmodifiedChars:"C"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_I, "\u02C6", SHOULD_DELIVER_KEYDOWN_KEYPRESS, KeyboardEvent.DOM_KEY_LOCATION_STANDARD); }
|
2009-03-30 14:42:11 -07:00
|
|
|
else if (IS_WIN) {
|
2008-05-05 16:01:07 -07:00
|
|
|
// On Windows, you can use Spy++ or Winspector (free) to watch window messages.
|
|
|
|
// The keyCode is given by the wParam of the last WM_KEYDOWN message. The
|
|
|
|
// chars string is given by the wParam of the WM_CHAR message. unmodifiedChars
|
|
|
|
// is not needed on Windows.
|
|
|
|
|
|
|
|
// Plain text input
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_A, chars:"a"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_A, "a", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_B, chars:"b"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_B, "b", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_A, shift:1, chars:"A"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_A, "A", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2008-05-05 16:01:07 -07:00
|
|
|
|
|
|
|
// Ctrl keys
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_A, ctrl:1, chars:"\u0001"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_A, "a", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_A, ctrl:1, shift:1, chars:"\u0001"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_A, "A", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2008-05-05 16:01:07 -07:00
|
|
|
|
|
|
|
// Alt keys
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_A, alt:1, chars:"a"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_A, "a", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_A, alt:1, shift:1, chars:"A"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_A, "A", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2008-10-15 20:04:39 -07:00
|
|
|
|
2008-05-05 16:01:07 -07:00
|
|
|
// Shift-ctrl-alt generates no WM_CHAR, but we still get a keypress
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_A, alt:1, ctrl:1, shift:1, chars:""},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_A, "A", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2008-05-05 16:01:07 -07:00
|
|
|
|
|
|
|
// Greek plain text
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"Greek", keyCode:WIN_VK_A, chars:"\u03b1"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_A, "\u03b1", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"Greek", keyCode:WIN_VK_A, shift:1, chars:"\u0391"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_A, "\u0391", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2008-05-05 16:01:07 -07:00
|
|
|
|
|
|
|
// Greek ctrl keys produce Latin charcodes
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"Greek", keyCode:WIN_VK_A, ctrl:1, chars:"\u0001"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_A, "a", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"Greek", keyCode:WIN_VK_A, ctrl:1, shift:1, chars:"\u0001"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_A, "A", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2008-10-15 20:04:39 -07:00
|
|
|
|
|
|
|
// Caps Lock key event
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_CAPITAL, capsLock:1, chars:""},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_CAPS_LOCK, "", SHOULD_DELIVER_KEYDOWN_KEYUP, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_CAPITAL, capsLock:0, chars:""},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_CAPS_LOCK, "", SHOULD_DELIVER_KEYDOWN_KEYUP, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
|
|
|
|
|
|
|
// Shift keys
|
|
|
|
testKey({layout:"US", keyCode:WIN_VK_LSHIFT, shift:1, chars:""},
|
|
|
|
nsIDOMKeyEvent.DOM_VK_SHIFT, "", SHOULD_DELIVER_KEYDOWN_KEYUP, KeyboardEvent.DOM_KEY_LOCATION_LEFT);
|
|
|
|
testKey({layout:"US", keyCode:WIN_VK_RSHIFT, shiftRight:1, chars:""},
|
|
|
|
nsIDOMKeyEvent.DOM_VK_SHIFT, "", SHOULD_DELIVER_KEYDOWN_KEYUP, KeyboardEvent.DOM_KEY_LOCATION_RIGHT);
|
|
|
|
|
|
|
|
// Ctrl keys
|
|
|
|
testKey({layout:"US", keyCode:WIN_VK_LCONTROL, ctrl:1, chars:""},
|
|
|
|
nsIDOMKeyEvent.DOM_VK_CONTROL, "", SHOULD_DELIVER_KEYDOWN_KEYUP, KeyboardEvent.DOM_KEY_LOCATION_LEFT);
|
|
|
|
testKey({layout:"US", keyCode:WIN_VK_RCONTROL, ctrlRight:1, chars:""},
|
|
|
|
nsIDOMKeyEvent.DOM_VK_CONTROL, "", SHOULD_DELIVER_KEYDOWN_KEYUP, KeyboardEvent.DOM_KEY_LOCATION_RIGHT);
|
|
|
|
|
|
|
|
// Alt keys
|
|
|
|
testKey({layout:"US", keyCode:WIN_VK_LMENU, alt:1, chars:""},
|
|
|
|
nsIDOMKeyEvent.DOM_VK_ALT, "", SHOULD_DELIVER_KEYDOWN_KEYUP, KeyboardEvent.DOM_KEY_LOCATION_LEFT);
|
|
|
|
testKey({layout:"US", keyCode:WIN_VK_RMENU, altRight:1, chars:""},
|
|
|
|
nsIDOMKeyEvent.DOM_VK_ALT, "", SHOULD_DELIVER_KEYDOWN_KEYUP, KeyboardEvent.DOM_KEY_LOCATION_RIGHT);
|
2012-05-17 00:04:16 -07:00
|
|
|
|
|
|
|
// Win keys
|
2012-07-18 18:28:17 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_LWIN, chars:""},
|
|
|
|
nsIDOMKeyEvent.DOM_VK_WIN, "", SHOULD_DELIVER_KEYDOWN_KEYUP, KeyboardEvent.DOM_KEY_LOCATION_LEFT);
|
|
|
|
testKey({layout:"US", keyCode:WIN_VK_RWIN, chars:""},
|
|
|
|
nsIDOMKeyEvent.DOM_VK_WIN, "", SHOULD_DELIVER_KEYDOWN_KEYUP, KeyboardEvent.DOM_KEY_LOCATION_RIGHT);
|
2012-05-17 00:04:16 -07:00
|
|
|
|
|
|
|
// all keys on keyboard (keyCode test)
|
2012-07-18 18:28:17 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_BACK, chars:"\u0008"},
|
|
|
|
nsIDOMKeyEvent.DOM_VK_BACK_SPACE, "", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_TAB, chars:"\t"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_TAB, "", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_RETURN, chars:"\r"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_RETURN, "", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_PAUSE, chars:""},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_PAUSE, "", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_KANA, chars:""},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_KANA, "", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_JUNJA, chars:""},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_JUNJA, "", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_FINAL, chars:""},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_FINAL, "", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_KANJI, chars:""},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_KANJI, "", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_ESCAPE, chars:""},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_ESCAPE, "", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_CONVERT, chars:""},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_CONVERT, "", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_NONCONVERT, chars:""},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_NONCONVERT, "", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_ACCEPT, chars:""},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_ACCEPT, "", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_MODECHANGE, chars:""},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_MODECHANGE, "", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_SPACE, chars:" "},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_SPACE, " ", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_SELECT, chars:""},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_SELECT, "", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_PRINT, chars:""},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_PRINT, "", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_EXECUTE, chars:""},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_EXECUTE, "", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_SNAPSHOT, chars:""},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_PRINTSCREEN, "", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_HELP, chars:""},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_HELP, "", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_SLEEP, chars:""},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_SLEEP, "", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
|
|
|
// XXX TODO: we cannot test Home, Up, PageUp, Left, Right, End, Down, PageDown, Ins and Del.
|
2012-05-17 00:04:16 -07:00
|
|
|
|
|
|
|
// US
|
|
|
|
// Alphabet
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_A, chars:"a"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_A, "a", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_A, shift:1, chars:"A"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_A, "A", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_B, chars:"b"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_B, "b", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_B, shift:1, chars:"B"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_B, "B", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_C, chars:"c"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_C, "c", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_C, shift:1, chars:"C"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_C, "C", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_D, chars:"d"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_D, "d", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_D, shift:1, chars:"D"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_D, "D", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_E, chars:"e"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_E, "e", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_E, shift:1, chars:"E"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_E, "E", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_F, chars:"f"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_F, "f", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_F, shift:1, chars:"F"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_F, "F", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_G, chars:"g"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_G, "g", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_G, shift:1, chars:"G"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_G, "G", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_H, chars:"h"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_H, "h", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_H, shift:1, chars:"H"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_H, "H", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_I, chars:"i"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_I, "i", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_I, shift:1, chars:"I"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_I, "I", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_J, chars:"j"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_J, "j", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_J, shift:1, chars:"J"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_J, "J", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_K, chars:"k"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_K, "k", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_K, shift:1, chars:"K"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_K, "K", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_L, chars:"l"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_L, "l", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_L, shift:1, chars:"L"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_L, "L", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_M, chars:"m"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_M, "m", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_M, shift:1, chars:"M"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_M, "M", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_N, chars:"n"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_N, "n", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_N, shift:1, chars:"N"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_N, "N", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_O, chars:"o"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_O, "o", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_O, shift:1, chars:"O"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_O, "O", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_P, chars:"p"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_P, "p", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_P, shift:1, chars:"P"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_P, "P", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_Q, chars:"q"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_Q, "q", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_Q, shift:1, chars:"Q"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_Q, "Q", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_R, chars:"r"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_R, "r", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_R, shift:1, chars:"R"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_R, "R", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_S, chars:"s"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_S, "s", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_S, shift:1, chars:"S"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_S, "S", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_T, chars:"t"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_T, "t", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_T, shift:1, chars:"T"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_T, "T", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_U, chars:"u"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_U, "u", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_U, shift:1, chars:"U"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_U, "U", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_V, chars:"v"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_V, "v", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_V, shift:1, chars:"V"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_V, "V", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_W, chars:"w"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_W, "w", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_W, shift:1, chars:"W"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_W, "W", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_X, chars:"x"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_X, "x", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_X, shift:1, chars:"X"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_X, "X", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_Y, chars:"y"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_Y, "y", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_Y, shift:1, chars:"Y"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_Y, "Y", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_Z, chars:"z"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_Z, "z", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_Z, shift:1, chars:"Z"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_Z, "Z", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-05-17 00:04:16 -07:00
|
|
|
|
|
|
|
// Numeric
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_0, chars:"0"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_0, "0", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_0, shift:1, chars:")"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_0, ")", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_1, chars:"1"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_1, "1", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_1, shift:1, chars:"!"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_1, "!", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_2, chars:"2"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_2, "2", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_2, shift:1, chars:"@"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_2, "@", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_3, chars:"3"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_3, "3", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_3, shift:1, chars:"#"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_3, "#", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_4, chars:"4"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_4, "4", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_4, shift:1, chars:"$"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_4, "$", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_5, chars:"5"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_5, "5", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_5, shift:1, chars:"%"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_5, "%", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_6, chars:"6"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_6, "6", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_6, shift:1, chars:"^"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_6, "^", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_7, chars:"7"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_7, "7", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_7, shift:1, chars:"&"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_7, "&", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_8, chars:"8"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_8, "8", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_8, shift:1, chars:"*"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_8, "*", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_9, chars:"9"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_9, "9", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_9, shift:1, chars:"("},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_9, "(", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-05-17 00:04:16 -07:00
|
|
|
|
|
|
|
// OEM keys
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_OEM_MINUS, chars:"-"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_HYPHEN_MINUS, "-", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_OEM_MINUS, shift:1, chars:"_"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_HYPHEN_MINUS, "_", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_OEM_PLUS, chars:"="},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_EQUALS, "=", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_OEM_PLUS, shift:1, chars:"+"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_EQUALS, "+", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_OEM_4, chars:"["},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_OPEN_BRACKET, "[", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_OEM_4, shift:1, chars:"{"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_OPEN_BRACKET, "{", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_OEM_6, chars:"]"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_CLOSE_BRACKET, "]", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_OEM_6, shift:1, chars:"}"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_CLOSE_BRACKET, "}", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_OEM_1, chars:";"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_SEMICOLON, ";", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_OEM_1, shift:1, chars:":"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_SEMICOLON, ":", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_OEM_7, chars:"'"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_QUOTE, "'", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_OEM_7, shift:1, chars:"\""},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_QUOTE, "\"", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_OEM_5, chars:"\\"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_BACK_SLASH, "\\", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_OEM_5, shift:1, chars:"|"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_BACK_SLASH, "|", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_OEM_COMMA, chars:","},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_COMMA, ",", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_OEM_COMMA, shift:1, chars:"<"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_COMMA, "<", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_OEM_PERIOD, chars:"."},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_PERIOD, ".", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_OEM_PERIOD, shift:1, chars:">"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_PERIOD, ">", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_OEM_2, chars:"/"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_SLASH, "/", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_OEM_2, shift:1, chars:"?"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_SLASH, "?", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_OEM_3, chars:"`"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_BACK_QUOTE, "`", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_OEM_3, shift:1, chars:"~"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_BACK_QUOTE, "~", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-05-17 00:04:16 -07:00
|
|
|
|
|
|
|
// Numpad
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_NUMPAD0, numLock:1, chars:"0"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_NUMPAD0, "0", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_NUMPAD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_NUMPAD1, numLock:1, chars:"1"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_NUMPAD1, "1", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_NUMPAD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_NUMPAD2, numLock:1, chars:"2"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_NUMPAD2, "2", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_NUMPAD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_NUMPAD3, numLock:1, chars:"3"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_NUMPAD3, "3", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_NUMPAD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_NUMPAD4, numLock:1, chars:"4"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_NUMPAD4, "4", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_NUMPAD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_NUMPAD5, numLock:1, chars:"5"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_NUMPAD5, "5", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_NUMPAD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_NUMPAD6, numLock:1, chars:"6"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_NUMPAD6, "6", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_NUMPAD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_NUMPAD7, numLock:1, chars:"7"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_NUMPAD7, "7", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_NUMPAD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_NUMPAD8, numLock:1, chars:"8"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_NUMPAD8, "8", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_NUMPAD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_NUMPAD9, numLock:1, chars:"9"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_NUMPAD9, "9", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_NUMPAD);
|
2012-05-17 00:04:16 -07:00
|
|
|
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_MULTIPLY, numLock:1, chars:"*"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_MULTIPLY, "*", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_NUMPAD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_MULTIPLY, numLock:1, shift:1, chars:"*"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_MULTIPLY, "*", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_NUMPAD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_ADD, numLock:1, chars:"+"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_ADD, "+", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_NUMPAD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_ADD, numLock:1, shift:1, chars:"+"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_ADD, "+", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_NUMPAD);
|
2012-06-26 19:26:38 -07:00
|
|
|
// VK_SEPARATOR is keycode for NEC's PC-98 series whose keyboard layout was
|
|
|
|
// different from current PC's keyboard layout and it cannot connect to
|
|
|
|
// current PC. Note that even if we synthesize WM_KEYDOWN with
|
|
|
|
// VK_SEPARATOR, it doesn't work on Win7.
|
|
|
|
//testKey({layout:"US", keyCode:WIN_VK_SEPARATOR, numLock:1, chars:""},
|
2012-07-18 18:28:17 -07:00
|
|
|
// nsIDOMKeyEvent.DOM_VK_SEPARATOR, "", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_NUMPAD);
|
2012-06-26 19:26:38 -07:00
|
|
|
//testKey({layout:"US", keyCode:WIN_VK_SEPARATOR, numLock:1, shift:1, chars:""},
|
2012-07-18 18:28:17 -07:00
|
|
|
// nsIDOMKeyEvent.DOM_VK_SEPARATOR, "", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_NUMPAD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_SUBTRACT, numLock:1, chars:"-"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_SUBTRACT, "-", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_NUMPAD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_SUBTRACT, numLock:1, shift:1, chars:"-"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_SUBTRACT, "-", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_NUMPAD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_DECIMAL, numLock:1, chars:"."},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_DECIMAL, ".", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_NUMPAD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_DECIMAL, numLock:1, shift:1, chars:"."},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_DECIMAL, ".", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_NUMPAD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_DIVIDE, numLock:1, chars:"/"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_DIVIDE, "/", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_NUMPAD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_DIVIDE, numLock:1, shift:1, chars:"/"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_DIVIDE, "/", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_NUMPAD);
|
|
|
|
|
|
|
|
// Numpad without NumLock
|
|
|
|
testKey({layout:"US", keyCode:WIN_VK_PRIOR, chars:""},
|
|
|
|
nsIDOMKeyEvent.DOM_VK_PAGE_UP, "", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_NUMPAD);
|
|
|
|
testKey({layout:"US", keyCode:WIN_VK_NEXT, chars:""},
|
|
|
|
nsIDOMKeyEvent.DOM_VK_PAGE_DOWN, "", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_NUMPAD);
|
|
|
|
testKey({layout:"US", keyCode:WIN_VK_END, chars:""},
|
|
|
|
nsIDOMKeyEvent.DOM_VK_END, "", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_NUMPAD);
|
|
|
|
testKey({layout:"US", keyCode:WIN_VK_HOME, chars:""},
|
|
|
|
nsIDOMKeyEvent.DOM_VK_HOME, "", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_NUMPAD);
|
|
|
|
testKey({layout:"US", keyCode:WIN_VK_LEFT, chars:""},
|
|
|
|
nsIDOMKeyEvent.DOM_VK_LEFT, "", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_NUMPAD);
|
|
|
|
testKey({layout:"US", keyCode:WIN_VK_UP, chars:""},
|
|
|
|
nsIDOMKeyEvent.DOM_VK_UP, "", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_NUMPAD);
|
|
|
|
testKey({layout:"US", keyCode:WIN_VK_RIGHT, chars:""},
|
|
|
|
nsIDOMKeyEvent.DOM_VK_RIGHT, "", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_NUMPAD);
|
|
|
|
testKey({layout:"US", keyCode:WIN_VK_DOWN, chars:""},
|
|
|
|
nsIDOMKeyEvent.DOM_VK_DOWN, "", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_NUMPAD);
|
|
|
|
testKey({layout:"US", keyCode:WIN_VK_INSERT, chars:""},
|
|
|
|
nsIDOMKeyEvent.DOM_VK_INSERT, "", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_NUMPAD);
|
|
|
|
testKey({layout:"US", keyCode:WIN_VK_DELETE, chars:""},
|
|
|
|
nsIDOMKeyEvent.DOM_VK_DELETE, "", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_NUMPAD);
|
|
|
|
testKey({layout:"US", keyCode:WIN_VK_CLEAR, chars:""},
|
|
|
|
nsIDOMKeyEvent.DOM_VK_CLEAR, "", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_NUMPAD);
|
2012-05-17 00:04:16 -07:00
|
|
|
|
|
|
|
// Even if widget receives unknown keycode, it should dispatch key events
|
|
|
|
// whose keycode is 0 rather than native keycode.
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:0x3A, numLock:1, chars:""},
|
2012-07-18 18:28:17 -07:00
|
|
|
0, "", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-05-17 00:04:16 -07:00
|
|
|
|
|
|
|
// French
|
|
|
|
// Numeric
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:WIN_VK_0, chars:"\u00E0"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_0, "\u00E0", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:WIN_VK_0, shift:1, chars:"0"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_0, "0", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:WIN_VK_1, chars:"&"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_1, "&", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:WIN_VK_1, shift:1, chars:"1"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_1, "1", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:WIN_VK_2, chars:"\u00E9"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_2, "\u00E9", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:WIN_VK_2, shift:1, chars:"2"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_2, "2", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:WIN_VK_3, chars:"\""},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_3, "\"", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:WIN_VK_3, shift:1, chars:"3"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_3, "3", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:WIN_VK_4, chars:"'"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_4, "'", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:WIN_VK_4, shift:1, chars:"4"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_4, "4", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:WIN_VK_5, chars:"("},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_5, "(", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:WIN_VK_5, shift:1, chars:"5"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_5, "5", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:WIN_VK_6, chars:"-"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_6, "-", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:WIN_VK_6, shift:1, chars:"6"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_6, "6", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:WIN_VK_7, chars:"\u00E8"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_7, "\u00E8", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:WIN_VK_7, shift:1, chars:"7"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_7, "7", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:WIN_VK_8, chars:"_"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_8, "_", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:WIN_VK_8, shift:1, chars:"8"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_8, "8", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:WIN_VK_9, chars:"\u00E7"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_9, "\u00E7", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:WIN_VK_9, shift:1, chars:"9"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_9, "9", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-05-17 00:04:16 -07:00
|
|
|
|
|
|
|
// Numeric with ShiftLock
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:WIN_VK_0, capsLock:1, chars:"0"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_0, "0", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:WIN_VK_0, capsLock:1, shift:1, chars:"\u00E0"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_0, "\u00E0", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:WIN_VK_1, capsLock:1, chars:"1"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_1, "1", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:WIN_VK_1, capsLock:1, shift:1, chars:"&"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_1, "&", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:WIN_VK_2, capsLock:1, chars:"2"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_2, "2", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:WIN_VK_2, capsLock:1, shift:1, chars:"\u00E9"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_2, "\u00E9", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:WIN_VK_3, capsLock:1, chars:"3"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_3, "3", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:WIN_VK_3, capsLock:1, shift:1, chars:"\""},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_3, "\"", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:WIN_VK_4, capsLock:1, chars:"4"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_4, "4", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:WIN_VK_4, capsLock:1, shift:1, chars:"'"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_4, "'", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:WIN_VK_5, capsLock:1, chars:"5"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_5, "5", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:WIN_VK_5, capsLock:1, shift:1, chars:"("},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_5, "(", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:WIN_VK_6, capsLock:1, chars:"6"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_6, "6", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:WIN_VK_6, capsLock:1, shift:1, chars:"-"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_6, "-", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:WIN_VK_7, capsLock:1, chars:"7"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_7, "7", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:WIN_VK_7, capsLock:1, shift:1, chars:"\u00E8"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_7, "\u00E8", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:WIN_VK_8, capsLock:1, chars:"8"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_8, "8", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:WIN_VK_8, capsLock:1, shift:1, chars:"_"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_8, "_", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:WIN_VK_9, capsLock:1, chars:"9"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_9, "9", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:WIN_VK_9, capsLock:1, shift:1, chars:"\u00E7"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_9, "\u00E7", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-05-17 00:04:16 -07:00
|
|
|
|
|
|
|
// OEM keys
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:WIN_VK_OEM_7, chars:"\u00B2"},
|
2012-07-18 18:28:17 -07:00
|
|
|
0, "\u00B2", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:WIN_VK_OEM_7, shift:1, chars:""},
|
2012-07-18 18:28:17 -07:00
|
|
|
0, "", SHOULD_DELIVER_KEYDOWN_KEYUP, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:WIN_VK_OEM_4, chars:")"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_CLOSE_PAREN, ")", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:WIN_VK_OEM_4, shift:1, chars:"\u00B0"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_CLOSE_PAREN, "\u00B0", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:WIN_VK_OEM_PLUS, chars:"="},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_EQUALS, "=", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:WIN_VK_OEM_PLUS, shift:1, chars:"+"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_EQUALS, "+", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
//testKey({layout:"French", keyCode:WIN_VK_OEM_6, chars:""},
|
2012-07-18 18:28:17 -07:00
|
|
|
// nsIDOMKeyEvent.DOM_VK_CIRCUMFLEX, "", SHOULD_DELIVER_KEYDOWN_KEYUP, KeyboardEvent.DOM_KEY_LOCATION_STANDARD); // Dead-key
|
2012-06-26 19:26:38 -07:00
|
|
|
//testKey({layout:"French", keyCode:WIN_VK_OEM_6, shift:1, chars:""},
|
2012-07-18 18:28:17 -07:00
|
|
|
// nsIDOMKeyEvent.DOM_VK_CIRCUMFLEX, "", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD); // Dead-key
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:WIN_VK_OEM_1, chars:"$"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_DOLLAR, "$", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:WIN_VK_OEM_1, shift:1, chars:"\u00A3"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_DOLLAR, "\u00A3", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:WIN_VK_OEM_3, chars:"\u00F9"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_PERCENT, "\u00F9", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:WIN_VK_OEM_3, shift:1, chars:"%"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_PERCENT, "%", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:WIN_VK_OEM_5, chars:"*"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_ASTERISK, "*", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:WIN_VK_OEM_5, shift:1, chars:"\u00B5"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_ASTERISK, "\u00B5", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:WIN_VK_OEM_102, chars:"<"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_LESS_THAN, "<", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:WIN_VK_OEM_102, shift:1, chars:">"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_LESS_THAN, ">", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:WIN_VK_OEM_COMMA, chars:","},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_COMMA, ",", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:WIN_VK_OEM_COMMA, shift:1, chars:"?"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_COMMA, "?", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:WIN_VK_OEM_PERIOD, chars:";"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_SEMICOLON, ";", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:WIN_VK_OEM_PERIOD, shift:1, chars:"."},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_SEMICOLON, ".", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:WIN_VK_OEM_2, chars:":"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_COLON, ":", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:WIN_VK_OEM_2, shift:1, chars:"/"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_COLON, "/", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:WIN_VK_OEM_8, chars:"!"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_EXCLAMATION, "!", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:WIN_VK_OEM_8, shift:1, chars:"\u00A7"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_EXCLAMATION, "\u00A7", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-05-17 00:04:16 -07:00
|
|
|
|
|
|
|
// OEM keys with ShiftLock
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:WIN_VK_OEM_7, capsLock:1, chars:"\u00B2"},
|
2012-07-18 18:28:17 -07:00
|
|
|
0, "\u00B2", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:WIN_VK_OEM_7, capsLock:1, shift:1, chars:""},
|
2012-07-18 18:28:17 -07:00
|
|
|
0, "", SHOULD_DELIVER_KEYDOWN_KEYUP, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:WIN_VK_OEM_4, capsLock:1, chars:"\u00B0"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_CLOSE_PAREN, "\u00B0", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:WIN_VK_OEM_4, capsLock:1, shift:1, chars:")"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_CLOSE_PAREN, ")", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:WIN_VK_OEM_PLUS, capsLock:1, chars:"+"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_EQUALS, "+", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:WIN_VK_OEM_PLUS, capsLock:1, shift:1, chars:"="},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_EQUALS, "=", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
//testKey({layout:"French", keyCode:WIN_VK_OEM_6, capsLock:1, chars:""},
|
2012-07-18 18:28:17 -07:00
|
|
|
// 0, "", SHOULD_DELIVER_KEYDOWN_KEYUP, KeyboardEvent.DOM_KEY_LOCATION_STANDARD); // Dead-key
|
2012-06-26 19:26:38 -07:00
|
|
|
//testKey({layout:"French", keyCode:WIN_VK_OEM_6, capsLock:1, shift:1, chars:""},
|
2012-07-18 18:28:17 -07:00
|
|
|
// 0, "", SHOULD_DELIVER_KEYDOWN_KEYUP, KeyboardEvent.DOM_KEY_LOCATION_STANDARD); // Dead-key
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:WIN_VK_OEM_1, capsLock:1, chars:"\u00A3"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_DOLLAR, "\u00A3", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:WIN_VK_OEM_1, capsLock:1, shift:1, chars:"$"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_DOLLAR, "$", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:WIN_VK_OEM_3, capsLock:1, chars:"%"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_PERCENT, "%", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:WIN_VK_OEM_3, capsLock:1, shift:1, chars:"\u00F9"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_PERCENT, "\u00F9", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:WIN_VK_OEM_5, capsLock:1, chars:"\u00B5"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_ASTERISK, "\u00B5", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:WIN_VK_OEM_5, capsLock:1, shift:1, chars:"*"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_ASTERISK, "*", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:WIN_VK_OEM_102, capsLock:1, chars:"<"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_LESS_THAN, "<", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:WIN_VK_OEM_102, capsLock:1, shift:1, chars:">"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_LESS_THAN, ">", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:WIN_VK_OEM_COMMA, capsLock:1, chars:"?"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_COMMA, "?", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:WIN_VK_OEM_COMMA, capsLock:1, shift:1, chars:","},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_COMMA, ",", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:WIN_VK_OEM_PERIOD, capsLock:1, chars:"."},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_SEMICOLON, ".", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:WIN_VK_OEM_PERIOD, capsLock:1, shift:1, chars:";"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_SEMICOLON, ";", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:WIN_VK_OEM_2, capsLock:1, chars:"/"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_COLON, "/", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:WIN_VK_OEM_2, capsLock:1, shift:1, chars:":"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_COLON, ":", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:WIN_VK_OEM_8, capsLock:1, chars:"\u00A7"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_EXCLAMATION, "\u00A7", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:WIN_VK_OEM_8, capsLock:1, shift:1, chars:"!"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_EXCLAMATION, "!", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-05-17 00:04:16 -07:00
|
|
|
|
|
|
|
// AltGr
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:WIN_VK_0, altGr:1, chars:"@"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_0, "@", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:WIN_VK_1, altGr:1, chars:""},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_1, "&", SHOULD_DELIVER_ALL_BUT_NOT_CAUSE_INPUT, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
//testKey({layout:"French", keyCode:WIN_VK_2, altGr:1, chars:""},
|
2012-07-18 18:28:17 -07:00
|
|
|
// nsIDOMKeyEvent.DOM_VK_2, "2", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD); // Dead-key
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:WIN_VK_3, altGr:1, chars:"#"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_3, "#", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:WIN_VK_4, altGr:1, chars:"{"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_4, "{", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:WIN_VK_5, altGr:1, chars:"["},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_5, "[", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:WIN_VK_6, altGr:1, chars:"|"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_6, "|", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
//testKey({layout:"French", keyCode:WIN_VK_7, altGr:1, chars:""},
|
2012-07-18 18:28:17 -07:00
|
|
|
// nsIDOMKeyEvent.DOM_VK_7, "", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD); // Dead-key
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:WIN_VK_8, altGr:1, chars:"\\"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_8, "\\", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:WIN_VK_9, altGr:1, chars:"^"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_9, "^", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:WIN_VK_OEM_4, altGr:1, chars:"]"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_CLOSE_PAREN, "]", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:WIN_VK_OEM_PLUS, altGr:1, chars:"}"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_EQUALS, "}", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-05-17 00:04:16 -07:00
|
|
|
|
|
|
|
// German
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"German", keyCode:WIN_VK_OEM_2, chars:"#"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_HASH, "#", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"German", keyCode:WIN_VK_OEM_2, shift:1, chars:"'"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_HASH, "'", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-05-17 00:04:16 -07:00
|
|
|
|
|
|
|
// Norwegian
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"Norwegian", keyCode:WIN_VK_OEM_5, chars:"|"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_PIPE, "|", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"Norwegian", keyCode:WIN_VK_OEM_5, shift:1, chars:"\u00A7"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_PIPE, "\u00A7", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-15 02:52:51 -07:00
|
|
|
|
2013-07-24 23:04:17 -07:00
|
|
|
// Brazilian ABNT
|
|
|
|
testKey({layout:"BrazilianABNT", keyCode:WIN_VK_ABNT_C1, chars:"/"},
|
|
|
|
nsIDOMKeyEvent.DOM_VK_SLASH, "/", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
|
|
|
testKey({layout:"BrazilianABNT", keyCode:WIN_VK_ABNT_C1, shift:1, chars:"?"},
|
|
|
|
nsIDOMKeyEvent.DOM_VK_SLASH, "?", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
|
|
|
testKey({layout:"BrazilianABNT", keyCode:WIN_VK_ABNT_C2, numLock:1, chars:"."},
|
|
|
|
nsIDOMKeyEvent.DOM_VK_SEPARATOR, ".", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_NUMPAD);
|
|
|
|
testKey({layout:"BrazilianABNT", keyCode:WIN_VK_DECIMAL, numLock:1, chars:","},
|
|
|
|
nsIDOMKeyEvent.DOM_VK_DECIMAL, ",", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_NUMPAD);
|
|
|
|
|
|
|
|
// Mac JIS keyboard
|
|
|
|
// The separator key on JIS keyboard for Mac doesn't cause any character even with Japanese keyboard layout.
|
|
|
|
testKey({layout:"Japanese", keyCode:WIN_VK_ABNT_C2, numLock:1, chars:""},
|
|
|
|
nsIDOMKeyEvent.DOM_VK_SEPARATOR, "", SHOULD_DELIVER_KEYDOWN_KEYUP, KeyboardEvent.DOM_KEY_LOCATION_NUMPAD);
|
|
|
|
testKey({layout:"Japanese", keyCode:WIN_VK_DECIMAL, numLock:1, chars:"."},
|
|
|
|
nsIDOMKeyEvent.DOM_VK_DECIMAL, ".", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_NUMPAD);
|
|
|
|
|
2012-06-15 02:52:51 -07:00
|
|
|
// Dead keys on any layouts
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:WIN_VK_OEM_6, chars:""},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_CIRCUMFLEX, "", SHOULD_DELIVER_KEYDOWN_KEYUP, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:WIN_VK_OEM_6, chars:"^^"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_CIRCUMFLEX, "^^", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-15 02:52:51 -07:00
|
|
|
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:WIN_VK_OEM_6, chars:""},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_CIRCUMFLEX, "", SHOULD_DELIVER_KEYDOWN_KEYUP, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:WIN_VK_A, chars:"\u00E2"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_A, "\u00E2", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-15 02:52:51 -07:00
|
|
|
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:WIN_VK_OEM_6, chars:""},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_CIRCUMFLEX, "", SHOULD_DELIVER_KEYDOWN_KEYUP, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:WIN_VK_A, shift:1, chars:"\u00C2"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_A, "\u00C2", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-15 02:52:51 -07:00
|
|
|
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:WIN_VK_OEM_6, chars:""},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_CIRCUMFLEX, "", SHOULD_DELIVER_KEYDOWN_KEYUP, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:WIN_VK_Q, chars:"^q"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_Q, "^q", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-15 02:52:51 -07:00
|
|
|
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:WIN_VK_OEM_6, shift:1, chars:""},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_CIRCUMFLEX, "", SHOULD_DELIVER_KEYDOWN_KEYUP, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:WIN_VK_OEM_6, shift:1, chars:"\u00A8\u00A8"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_CIRCUMFLEX, "\u00A8\u00A8", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-15 02:52:51 -07:00
|
|
|
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:WIN_VK_OEM_6, shift:1, chars:""},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_CIRCUMFLEX, "", SHOULD_DELIVER_KEYDOWN_KEYUP, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:WIN_VK_A, shift:1, chars:"\u00C4"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_A, "\u00C4", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-15 02:52:51 -07:00
|
|
|
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:WIN_VK_OEM_6, shift:1, chars:""},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_CIRCUMFLEX, "", SHOULD_DELIVER_KEYDOWN_KEYUP, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:WIN_VK_A, chars:"\u00E4"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_A, "\u00E4", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-15 02:52:51 -07:00
|
|
|
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:WIN_VK_OEM_6, shift:1, chars:""},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_CIRCUMFLEX, "", SHOULD_DELIVER_KEYDOWN_KEYUP, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"French", keyCode:WIN_VK_Q, shift:1, chars:"\u00A8Q"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_Q, "\u00A8Q", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-15 02:52:51 -07:00
|
|
|
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"Spanish", keyCode:WIN_VK_OEM_1, chars:""},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_BACK_QUOTE, "", SHOULD_DELIVER_KEYDOWN_KEYUP, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"Spanish", keyCode:WIN_VK_OEM_1, chars:"``"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_BACK_QUOTE, "``", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-15 02:52:51 -07:00
|
|
|
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"Spanish", keyCode:WIN_VK_OEM_1, chars:""},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_BACK_QUOTE, "", SHOULD_DELIVER_KEYDOWN_KEYUP, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"Spanish", keyCode:WIN_VK_A, chars:"\u00E0"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_A, "\u00E0", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-15 02:52:51 -07:00
|
|
|
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"Spanish", keyCode:WIN_VK_OEM_1, chars:""},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_BACK_QUOTE, "", SHOULD_DELIVER_KEYDOWN_KEYUP, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"Spanish", keyCode:WIN_VK_A, shift:1, chars:"\u00C0"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_A, "\u00C0", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-15 02:52:51 -07:00
|
|
|
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"Spanish", keyCode:WIN_VK_OEM_1, chars:""},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_BACK_QUOTE, "", SHOULD_DELIVER_KEYDOWN_KEYUP, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"Spanish", keyCode:WIN_VK_Q, chars:"`q"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_Q, "`q", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-15 02:52:51 -07:00
|
|
|
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"Spanish", keyCode:WIN_VK_OEM_1, shift:1, chars:""},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_BACK_QUOTE, "", SHOULD_DELIVER_KEYDOWN_KEYUP, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"Spanish", keyCode:WIN_VK_OEM_1, shift:1, chars:"^^"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_BACK_QUOTE, "^^", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-15 02:52:51 -07:00
|
|
|
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"Spanish", keyCode:WIN_VK_OEM_1, shift:1, chars:""},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_BACK_QUOTE, "", SHOULD_DELIVER_KEYDOWN_KEYUP, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"Spanish", keyCode:WIN_VK_A, shift:1, chars:"\u00C2"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_A, "\u00C2", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-15 02:52:51 -07:00
|
|
|
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"Spanish", keyCode:WIN_VK_OEM_1, shift:1, chars:""},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_BACK_QUOTE, "", SHOULD_DELIVER_KEYDOWN_KEYUP, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"Spanish", keyCode:WIN_VK_A, chars:"\u00E2"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_A, "\u00E2", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-15 02:52:51 -07:00
|
|
|
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"Spanish", keyCode:WIN_VK_OEM_1, shift:1, chars:""},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_BACK_QUOTE, "", SHOULD_DELIVER_KEYDOWN_KEYUP, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"Spanish", keyCode:WIN_VK_Q, shift:1, chars:"^Q"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_Q, "^Q", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-15 02:52:51 -07:00
|
|
|
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"Spanish", keyCode:WIN_VK_OEM_7, chars:""},
|
2012-07-18 18:28:17 -07:00
|
|
|
0, "", SHOULD_DELIVER_KEYDOWN_KEYUP, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"Spanish", keyCode:WIN_VK_OEM_7, chars:"\u00B4\u00B4"},
|
2012-07-18 18:28:17 -07:00
|
|
|
0, "\u00B4\u00B4", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-15 02:52:51 -07:00
|
|
|
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"Spanish", keyCode:WIN_VK_OEM_7, chars:""},
|
2012-07-18 18:28:17 -07:00
|
|
|
0, "", SHOULD_DELIVER_KEYDOWN_KEYUP, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"Spanish", keyCode:WIN_VK_A, chars:"\u00E1"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_A, "\u00E1", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-15 02:52:51 -07:00
|
|
|
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"Spanish", keyCode:WIN_VK_OEM_7, chars:""},
|
2012-07-18 18:28:17 -07:00
|
|
|
0, "", SHOULD_DELIVER_KEYDOWN_KEYUP, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"Spanish", keyCode:WIN_VK_A, shift:1, chars:"\u00C1"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_A, "\u00C1", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-15 02:52:51 -07:00
|
|
|
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"Spanish", keyCode:WIN_VK_OEM_7, chars:""},
|
2012-07-18 18:28:17 -07:00
|
|
|
0, "", SHOULD_DELIVER_KEYDOWN_KEYUP, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"Spanish", keyCode:WIN_VK_Q, chars:"\u00B4q"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_Q, "\u00B4q", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-15 02:52:51 -07:00
|
|
|
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"Spanish", keyCode:WIN_VK_OEM_7, shift:1, chars:""},
|
2012-07-18 18:28:17 -07:00
|
|
|
0, "", SHOULD_DELIVER_KEYDOWN_KEYUP, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"Spanish", keyCode:WIN_VK_OEM_7, shift:1, chars:"\u00A8\u00A8"},
|
2012-07-18 18:28:17 -07:00
|
|
|
0, "\u00A8\u00A8", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-15 02:52:51 -07:00
|
|
|
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"Spanish", keyCode:WIN_VK_OEM_7, shift:1, chars:""},
|
2012-07-18 18:28:17 -07:00
|
|
|
0, "", SHOULD_DELIVER_KEYDOWN_KEYUP, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"Spanish", keyCode:WIN_VK_A, shift:1, chars:"\u00C4"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_A, "\u00C4", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-15 02:52:51 -07:00
|
|
|
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"Spanish", keyCode:WIN_VK_OEM_7, shift:1, chars:""},
|
2012-07-18 18:28:17 -07:00
|
|
|
0, "", SHOULD_DELIVER_KEYDOWN_KEYUP, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"Spanish", keyCode:WIN_VK_A, chars:"\u00E4"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_A, "\u00E4", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-15 02:52:51 -07:00
|
|
|
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"Spanish", keyCode:WIN_VK_OEM_7, shift:1, chars:""},
|
2012-07-18 18:28:17 -07:00
|
|
|
0, "", SHOULD_DELIVER_KEYDOWN_KEYUP, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"Spanish", keyCode:WIN_VK_Q, shift:1, chars:"\u00A8Q"},
|
2012-07-18 18:28:17 -07:00
|
|
|
nsIDOMKeyEvent.DOM_VK_Q, "\u00A8Q", SHOULD_DELIVER_ALL, KeyboardEvent.DOM_KEY_LOCATION_STANDARD);
|
2008-05-05 16:01:07 -07:00
|
|
|
}
|
|
|
|
|
2008-10-15 20:04:39 -07:00
|
|
|
document.removeEventListener("keydown", onKeyEvent, false);
|
|
|
|
document.removeEventListener("keypress", onKeyEvent, false);
|
|
|
|
document.removeEventListener("keyup", onKeyEvent, false);
|
2008-05-05 16:01:07 -07:00
|
|
|
}
|
|
|
|
|
|
|
|
// Test the activation (or not) of an HTML accesskey
|
|
|
|
function runAccessKeyTests()
|
|
|
|
{
|
|
|
|
var button = document.getElementById("button");
|
|
|
|
var activationCount;
|
|
|
|
|
|
|
|
function onClick(e)
|
|
|
|
{
|
|
|
|
++activationCount;
|
|
|
|
}
|
|
|
|
|
|
|
|
// The first parameter is the complete input event. The second and third parameters are
|
|
|
|
// what to test against.
|
|
|
|
function testKey(aEvent, aAccessKey, aShouldActivate)
|
|
|
|
{
|
|
|
|
activationCount = 0;
|
|
|
|
button.setAttribute("accesskey", aAccessKey);
|
|
|
|
|
2008-10-13 23:01:51 -07:00
|
|
|
synthesizeKey(aEvent, "button");
|
2008-05-05 16:01:07 -07:00
|
|
|
|
2008-05-08 15:41:13 -07:00
|
|
|
var name = eventToString(aEvent);
|
2008-05-05 16:01:07 -07:00
|
|
|
|
|
|
|
is(activationCount, aShouldActivate ? 1 : 0, name + ", activating '" + aAccessKey + "'");
|
|
|
|
}
|
|
|
|
|
|
|
|
button.addEventListener("click", onClick, false);
|
|
|
|
|
|
|
|
// These tests have to be per-plaform.
|
2009-03-30 14:42:11 -07:00
|
|
|
if (IS_MAC) {
|
2008-05-05 16:01:07 -07:00
|
|
|
// Basic sanity checks
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_A, chars:"a", unmodifiedChars:"a"},
|
2008-05-05 16:01:07 -07:00
|
|
|
"a", false);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_A, ctrl:1, chars:"\u0001", unmodifiedChars:"a"},
|
2012-03-15 23:29:15 -07:00
|
|
|
"a", false);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_A, ctrl:1, chars:"\u0001", unmodifiedChars:"a"},
|
2012-03-15 23:29:15 -07:00
|
|
|
"A", false);
|
2008-05-05 16:01:07 -07:00
|
|
|
|
|
|
|
// Shift-ctrl does not activate accesskeys
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_A, ctrl:1, shift:1, chars:"\u0001", unmodifiedChars:"A"},
|
2008-05-05 16:01:07 -07:00
|
|
|
"a", false);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_A, ctrl:1, shift:1, chars:"\u0001", unmodifiedChars:"A"},
|
2008-05-05 16:01:07 -07:00
|
|
|
"A", false);
|
2012-03-15 23:29:15 -07:00
|
|
|
// Alt-ctrl activate accesskeys
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_A, ctrl:1, alt:1, chars:"\u0001", unmodifiedChars:"a"},
|
2012-03-15 23:29:15 -07:00
|
|
|
"a", true);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_A, ctrl:1, alt:1, chars:"\u0001", unmodifiedChars:"a"},
|
2012-03-15 23:29:15 -07:00
|
|
|
"A", true);
|
2008-05-05 16:01:07 -07:00
|
|
|
|
|
|
|
// Greek layout can activate a Latin accesskey
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"Greek", keyCode:MAC_VK_ANSI_A, ctrl:1, alt:1, chars:"\u0001", unmodifiedChars:"\u03b1"},
|
2008-05-05 16:01:07 -07:00
|
|
|
"a", true);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"Greek", keyCode:MAC_VK_ANSI_A, ctrl:1, alt:1, chars:"\u0001", unmodifiedChars:"\u03b1"},
|
2008-05-05 16:01:07 -07:00
|
|
|
"A", true);
|
|
|
|
// ... and a Greek accesskey!
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"Greek", keyCode:MAC_VK_ANSI_A, ctrl:1, alt:1, chars:"\u0001", unmodifiedChars:"\u03b1"},
|
2008-05-05 16:01:07 -07:00
|
|
|
"\u03b1", true);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"Greek", keyCode:MAC_VK_ANSI_A, ctrl:1, alt:1, chars:"\u0001", unmodifiedChars:"\u03b1"},
|
2008-05-05 16:01:07 -07:00
|
|
|
"\u0391", true);
|
2008-05-07 14:54:21 -07:00
|
|
|
|
2008-05-08 15:41:13 -07:00
|
|
|
// bug 359638
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_Period, ctrl:1, alt:1, chars:".", unmodifiedChars:"."},
|
2008-05-08 15:41:13 -07:00
|
|
|
".", true);
|
|
|
|
|
2008-05-07 14:54:21 -07:00
|
|
|
// German (KCHR/KeyTranslate case)
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"German", keyCode:MAC_VK_ANSI_A, ctrl:1, alt:1, chars:"a", unmodifiedChars:"a"},
|
2008-05-07 14:54:21 -07:00
|
|
|
"a", true);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"German", keyCode:MAC_VK_ANSI_A, ctrl:1, alt:1, chars:"a", unmodifiedChars:"a"},
|
2008-05-07 14:54:21 -07:00
|
|
|
"A", true);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"German", keyCode:MAC_VK_ANSI_LeftBracket, ctrl:1, alt:1, chars:"\u00fc", unmodifiedChars:"\u00fc"},
|
2008-05-07 14:54:21 -07:00
|
|
|
"\u00fc", true);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"German", keyCode:MAC_VK_ANSI_LeftBracket, ctrl:1, alt:1, chars:"\u00fc", unmodifiedChars:"\u00fc"},
|
2008-05-07 14:54:21 -07:00
|
|
|
"\u00dc", true);
|
2008-05-05 16:01:07 -07:00
|
|
|
}
|
2009-03-30 14:42:11 -07:00
|
|
|
else if (IS_WIN) {
|
2008-05-05 16:01:07 -07:00
|
|
|
// Basic sanity checks
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_A, chars:"a"},
|
2008-05-05 16:01:07 -07:00
|
|
|
"a", false);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_A, shift:1, alt:1, chars:"A"},
|
2008-05-05 16:01:07 -07:00
|
|
|
"a", true);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_A, shift:1, alt:1, chars:"A"},
|
2008-05-05 16:01:07 -07:00
|
|
|
"A", true);
|
|
|
|
|
|
|
|
// shift-alt-ctrl does not activate accesskeys
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_A, ctrl:1, shift:1, alt:1, chars:""},
|
2008-05-05 16:01:07 -07:00
|
|
|
"a", false);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_A, ctrl:1, shift:1, alt:1, chars:""},
|
2008-05-05 16:01:07 -07:00
|
|
|
"A", false);
|
|
|
|
|
|
|
|
// Greek layout can activate a Latin accesskey
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"Greek", keyCode:WIN_VK_A, shift:1, alt:1, chars:"A"},
|
2008-05-06 21:46:37 -07:00
|
|
|
"a", true);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"Greek", keyCode:WIN_VK_A, shift:1, alt:1, chars:"A"},
|
2008-05-06 21:46:37 -07:00
|
|
|
"A", true);
|
2008-05-05 16:01:07 -07:00
|
|
|
// ... and a Greek accesskey!
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"Greek", keyCode:WIN_VK_A, shift:1, alt:1, chars:"A"},
|
2008-05-06 21:46:37 -07:00
|
|
|
"\u03b1", true);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"Greek", keyCode:WIN_VK_A, shift:1, alt:1, chars:"A"},
|
2008-05-06 21:46:37 -07:00
|
|
|
"\u0391", true);
|
2008-05-08 15:41:13 -07:00
|
|
|
|
|
|
|
// bug 359638
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_OEM_PERIOD, shift:1, alt:1, chars:".", unmodifiedChars:"."},
|
2008-05-08 15:41:13 -07:00
|
|
|
".", true);
|
2008-05-05 16:01:07 -07:00
|
|
|
}
|
|
|
|
|
|
|
|
button.removeEventListener("click", onClick, false);
|
|
|
|
}
|
|
|
|
|
2008-05-08 15:41:13 -07:00
|
|
|
function runXULKeyTests()
|
|
|
|
{
|
|
|
|
function testKey(aEvent, aElem, aShouldActivate)
|
|
|
|
{
|
|
|
|
var elem = document.getElementById(aElem);
|
|
|
|
elem.activeCount = 0;
|
|
|
|
|
2008-10-13 23:01:51 -07:00
|
|
|
synthesizeKey(aEvent, "button");
|
2008-05-08 15:41:13 -07:00
|
|
|
|
|
|
|
var name = eventToString(aEvent);
|
|
|
|
|
|
|
|
is(elem.activeCount, aShouldActivate ? 1 : 0,
|
|
|
|
name + " activating " + aElem);
|
|
|
|
}
|
|
|
|
|
2009-03-30 14:42:11 -07:00
|
|
|
if (IS_MAC) {
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_Semicolon, command:1, chars:";", unmodifiedChars:";"},
|
2008-05-08 15:41:13 -07:00
|
|
|
"unshiftedKey", true);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_Semicolon, command:1, chars:";", unmodifiedChars:";"},
|
2008-05-08 15:41:13 -07:00
|
|
|
"shiftedKey", false);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_Semicolon, command:1, shift:1, chars:";", unmodifiedChars:":"},
|
2008-05-08 15:41:13 -07:00
|
|
|
"shiftedKey", true);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_Semicolon, command:1, shift:1, chars:";", unmodifiedChars:":"},
|
2008-05-08 15:41:13 -07:00
|
|
|
"unshiftedKey", false);
|
|
|
|
}
|
2009-03-30 14:42:11 -07:00
|
|
|
else if (IS_WIN) {
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_OEM_1, ctrl:1, chars:";"},
|
2008-05-08 15:41:13 -07:00
|
|
|
"unshiftedKey", true);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_OEM_1, ctrl:1, chars:";"},
|
2008-05-08 15:41:13 -07:00
|
|
|
"shiftedKey", false);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_OEM_1, ctrl:1, shift:1, chars:";"},
|
2008-05-08 15:41:13 -07:00
|
|
|
"shiftedKey", true);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_OEM_1, ctrl:1, shift:1, chars:";"},
|
2008-05-08 15:41:13 -07:00
|
|
|
"unshiftedKey", false);
|
|
|
|
}
|
|
|
|
|
|
|
|
keyElems = ["commandOptionF"];
|
|
|
|
|
|
|
|
// 429160
|
2009-03-30 14:42:11 -07:00
|
|
|
if (IS_MAC) {
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:MAC_VK_ANSI_F, command:1, alt:1, chars:"\u0192", unmodifiedChars:"f"},
|
2008-05-08 15:41:13 -07:00
|
|
|
"commandOptionF", true);
|
|
|
|
}
|
2009-03-30 14:42:11 -07:00
|
|
|
else if (IS_WIN) {
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_F, ctrl:1, alt:1, chars:"\u0006"},
|
2008-05-08 15:41:13 -07:00
|
|
|
"commandOptionF", true);
|
|
|
|
}
|
|
|
|
|
|
|
|
// 432112
|
2009-03-30 14:42:11 -07:00
|
|
|
if (IS_MAC) {
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"Swedish", keyCode:MAC_VK_ANSI_Minus, command:1, shift:1, chars:"+", unmodifiedChars:"?"},
|
2009-08-17 21:47:53 -07:00
|
|
|
"question", true);
|
2008-05-08 15:41:13 -07:00
|
|
|
}
|
2009-03-30 14:42:11 -07:00
|
|
|
else if (IS_WIN) {
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"Swedish", keyCode:WIN_VK_OEM_PLUS, ctrl:1, shift:1, chars:""},
|
2008-05-08 15:41:13 -07:00
|
|
|
"question", true);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"Swedish", keyCode:WIN_VK_OEM_PLUS, ctrl:1, chars:""},
|
2008-05-08 15:41:13 -07:00
|
|
|
"question", false);
|
|
|
|
}
|
2008-05-11 17:39:29 -07:00
|
|
|
|
|
|
|
// bug 433192
|
2009-03-30 14:42:11 -07:00
|
|
|
if (IS_WIN) {
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_X, ctrl:1, chars:"\u0018"},
|
2008-05-11 17:39:29 -07:00
|
|
|
"unshiftedX", true);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_X, ctrl:1, chars:"\u0018"},
|
2008-05-11 17:39:29 -07:00
|
|
|
"shiftedX", false);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_X, ctrl:1, shift:1, chars:"\u0018"},
|
2008-05-11 17:39:29 -07:00
|
|
|
"unshiftedX", false);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_X, ctrl:1, shift:1, chars:"\u0018"},
|
2008-05-11 17:39:29 -07:00
|
|
|
"shiftedX", true);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"Arabic", keyCode:WIN_VK_X, ctrl:1, chars:"\u0018"},
|
2008-05-11 17:39:29 -07:00
|
|
|
"unshiftedX", true);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"Arabic", keyCode:WIN_VK_X, ctrl:1, chars:"\u0018"},
|
2008-05-11 17:39:29 -07:00
|
|
|
"shiftedX", false);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"Arabic", keyCode:WIN_VK_X, ctrl:1, shift:1, chars:"\u0018"},
|
2008-05-11 17:39:29 -07:00
|
|
|
"unshiftedX", false);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"Arabic", keyCode:WIN_VK_X, ctrl:1, shift:1, chars:"\u0018"},
|
2008-05-11 17:39:29 -07:00
|
|
|
"shiftedX", true);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"Hebrew", keyCode:WIN_VK_X, ctrl:1, chars:"\u0018"},
|
2008-05-11 17:39:29 -07:00
|
|
|
"unshiftedX", true);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"Hebrew", keyCode:WIN_VK_X, ctrl:1, chars:"\u0018"},
|
2008-05-11 17:39:29 -07:00
|
|
|
"shiftedX", false);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"Hebrew", keyCode:WIN_VK_X, ctrl:1, shift:1, chars:"\u0018"},
|
2008-05-11 17:39:29 -07:00
|
|
|
"unshiftedX", false);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"Hebrew", keyCode:WIN_VK_X, ctrl:1, shift:1, chars:"\u0018"},
|
2008-05-11 17:39:29 -07:00
|
|
|
"shiftedX", true);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"Japanese", keyCode:WIN_VK_OEM_PLUS, ctrl:1, chars:""},
|
2008-05-11 17:39:29 -07:00
|
|
|
"unshiftedPlus", false);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"Japanese", keyCode:WIN_VK_OEM_PLUS, ctrl:1, shift:1, chars:""},
|
2008-05-11 17:39:29 -07:00
|
|
|
"unshiftedPlus", true);
|
|
|
|
}
|
2012-05-29 17:47:03 -07:00
|
|
|
|
|
|
|
// bug 759346
|
|
|
|
if (IS_WIN) {
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"Thai", keyCode:WIN_VK_1, ctrl:1, chars:""},
|
2012-05-29 17:47:03 -07:00
|
|
|
"unshiftedPlus", false);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"Thai", keyCode:WIN_VK_1, ctrl:1, shift:1, chars:""},
|
2012-05-29 17:47:03 -07:00
|
|
|
"unshiftedPlus", true);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"Thai", keyCode:WIN_VK_OEM_PLUS, ctrl:1, chars:""},
|
2012-05-29 17:47:03 -07:00
|
|
|
"unshiftedPlus", true);
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"Thai", keyCode:WIN_VK_OEM_PLUS, ctrl:1, shift:1, chars:""},
|
2012-05-29 17:47:03 -07:00
|
|
|
"unshiftedPlus", false);
|
|
|
|
}
|
2008-05-08 15:41:13 -07:00
|
|
|
}
|
|
|
|
|
2008-10-13 23:01:51 -07:00
|
|
|
function runTextInputTests()
|
|
|
|
{
|
|
|
|
var textbox = document.getElementById("textbox");
|
|
|
|
|
|
|
|
function testKey(aEvent, aExpectText) {
|
|
|
|
textbox.value = "";
|
|
|
|
textbox.focus();
|
|
|
|
|
|
|
|
synthesizeKey(aEvent, "textbox");
|
|
|
|
|
|
|
|
var name = eventToString(aEvent);
|
|
|
|
|
|
|
|
is(textbox.value, aExpectText, name + " does not input correct text.");
|
|
|
|
}
|
|
|
|
|
2009-03-30 14:42:11 -07:00
|
|
|
if (IS_WIN) {
|
2008-10-13 23:01:51 -07:00
|
|
|
// Basic sanity checks
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_A, chars:"a"},
|
2008-10-13 23:01:51 -07:00
|
|
|
"a");
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_A, shift:1, chars:"A"},
|
2008-10-13 23:01:51 -07:00
|
|
|
"A");
|
|
|
|
// When Ctrl+Alt are pressed, any text should not be inputted.
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"US", keyCode:WIN_VK_A, ctrl:1, alt:1, chars:""},
|
2008-10-13 23:01:51 -07:00
|
|
|
"");
|
|
|
|
|
|
|
|
// Lithuanian AltGr should be consumed at 9/0 keys pressed
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"Lithuanian", keyCode:WIN_VK_8, chars:"\u016B"},
|
2008-10-13 23:01:51 -07:00
|
|
|
"\u016B");
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"Lithuanian", keyCode:WIN_VK_9, chars:"9"},
|
2008-10-13 23:01:51 -07:00
|
|
|
"9");
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"Lithuanian", keyCode:WIN_VK_0, chars:"0"},
|
2008-10-13 23:01:51 -07:00
|
|
|
"0");
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"Lithuanian", keyCode:WIN_VK_8, ctrl:1, alt:1, chars:"8"},
|
2008-10-13 23:01:51 -07:00
|
|
|
"8");
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"Lithuanian", keyCode:WIN_VK_9, ctrl:1, alt:1, chars:"9"},
|
2008-10-13 23:01:51 -07:00
|
|
|
"9");
|
2012-06-26 19:26:38 -07:00
|
|
|
testKey({layout:"Lithuanian", keyCode:WIN_VK_0, ctrl:1, alt:1, chars:"0"},
|
2008-10-13 23:01:51 -07:00
|
|
|
"0");
|
|
|
|
}
|
2009-03-30 14:42:11 -07:00
|
|
|
else
|
|
|
|
todo(false, "runTextInputTests() checks Windows only");
|
2009-02-12 02:44:38 -08:00
|
|
|
|
|
|
|
// XXX We need to move focus for canceling to search the autocomplete
|
|
|
|
// result. If we don't do here, Fx will crash at end of this tests.
|
|
|
|
document.getElementById("button").focus();
|
2008-10-13 23:01:51 -07:00
|
|
|
}
|
|
|
|
|
2008-05-05 16:01:07 -07:00
|
|
|
function runTest()
|
|
|
|
{
|
2009-03-30 14:42:11 -07:00
|
|
|
if (!IS_MAC && !IS_WIN) {
|
|
|
|
todo(false, "This test is supported on MacOSX and Windows only. (Bug 431503)");
|
|
|
|
return;
|
|
|
|
}
|
|
|
|
|
|
|
|
SimpleTest.waitForExplicitFinish();
|
|
|
|
|
2008-10-15 20:04:39 -07:00
|
|
|
runKeyEventTests();
|
2008-05-05 16:01:07 -07:00
|
|
|
runAccessKeyTests();
|
2008-05-08 15:41:13 -07:00
|
|
|
runXULKeyTests();
|
2008-10-13 23:01:51 -07:00
|
|
|
runTextInputTests();
|
2009-03-30 14:42:11 -07:00
|
|
|
|
2008-05-05 16:01:07 -07:00
|
|
|
SimpleTest.finish();
|
|
|
|
}
|
|
|
|
|
|
|
|
]]>
|
|
|
|
</script>
|
|
|
|
|
|
|
|
</window>
|