| Index: ui/events/keycodes/keyboard_code_conversion.cc
|
| diff --git a/ui/events/keycodes/keyboard_code_conversion.cc b/ui/events/keycodes/keyboard_code_conversion.cc
|
| index e31512b8c5e90efa0e642faead98db3f4f8cbf52..3fc17a162e936e504cb2c1943ceea4b5cd808496 100644
|
| --- a/ui/events/keycodes/keyboard_code_conversion.cc
|
| +++ b/ui/events/keycodes/keyboard_code_conversion.cc
|
| @@ -428,6 +428,21 @@ bool DomCodeToControlCharacter(DomCode dom_code,
|
| }
|
| }
|
|
|
| +DomKey CharacterToDomKey(uint32 character) {
|
| + switch (character) {
|
| + case 0x08:
|
| + return DomKey::BACKSPACE;
|
| + case 0x09:
|
| + return DomKey::TAB;
|
| + case 0x0D:
|
| + return DomKey::ENTER;
|
| + case 0x1B:
|
| + return DomKey::ESCAPE;
|
| + default:
|
| + return DomKey::CHARACTER;
|
| + }
|
| +}
|
| +
|
| // Returns a Windows-based VKEY for a non-printable DOM Level 3 |key|.
|
| // The returned VKEY is non-positional (e.g. VKEY_SHIFT).
|
| KeyboardCode NonPrintableDomKeyToKeyboardCode(DomKey dom_key) {
|
|
|