Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(250)

Side by Side Diff: chrome/test/remoting/key_code_test_map.h

Issue 807343002: Adding the first set of remote test cases and associated framework. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fixing comments and merge issues. Created 5 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
(Empty)
1 // Copyright 2013 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4
5 // Source of data in this file:
6 // 1. ui/events/keycodes/dom4/keycode_converter_data.h
7 // 2. ui/events/keycodes/keyboard_codes.h
8 // 3. third_party/WebKit/Source/core/platform/chromium/KeyboardCodes.h
9 #ifndef CHROME_TEST_REMOTING_KEY_CODE_TEST_MAP_H_
10 #define CHROME_TEST_REMOTING_KEY_CODE_TEST_MAP_H_
11
12 #include "ui/events/keycodes/keyboard_codes.h"
13
14 namespace remoting {
15
16 typedef struct {
17 // The UIEvents (aka: DOM4Events) |code| value as defined in:
18 // https://dvcs.w3.org/hg/d4e/raw-file/tip/source_respec.htm
19 const char* code;
20
21 // The (Windows) virtual keyboard code.
22 ui::KeyboardCode vkey_code;
23 } KeyCodeTestMap;
24
25 const KeyCodeTestMap test_key_map[] = {
Jamie 2015/01/06 19:31:38 I suggest you call this |test_alpha_map|, since th
Mike Meade 2015/01/08 18:58:42 Changed. The reason for splitting these out is th
26 {"KeyA", ui::VKEY_A},
27 {"KeyB", ui::VKEY_B},
28 {"KeyC", ui::VKEY_C},
29 {"KeyD", ui::VKEY_D},
30 {"KeyE", ui::VKEY_E},
31 {"KeyF", ui::VKEY_F},
32 {"KeyG", ui::VKEY_G},
33 {"KeyH", ui::VKEY_H},
34 {"KeyI", ui::VKEY_I},
35 {"KeyJ", ui::VKEY_J},
36 {"KeyK", ui::VKEY_K},
37 {"KeyL", ui::VKEY_L},
38 {"KeyM", ui::VKEY_M},
39 {"KeyN", ui::VKEY_N},
40 {"KeyO", ui::VKEY_O},
41 {"KeyP", ui::VKEY_P},
42 {"KeyQ", ui::VKEY_Q},
43 {"KeyR", ui::VKEY_R},
44 {"KeyS", ui::VKEY_S},
45 {"KeyT", ui::VKEY_T},
46 {"KeyU", ui::VKEY_U},
47 {"KeyV", ui::VKEY_V},
48 {"KeyW", ui::VKEY_W},
49 {"KeyX", ui::VKEY_X},
50 {"KeyY", ui::VKEY_Y},
51 {"KeyZ", ui::VKEY_Z},
52 };
53
54 const KeyCodeTestMap test_digit_map[] = {
55 {"Digit1", ui::VKEY_1},
56 {"Digit2", ui::VKEY_2},
57 {"Digit3", ui::VKEY_3},
58 {"Digit4", ui::VKEY_4},
59 {"Digit5", ui::VKEY_5},
60 {"Digit6", ui::VKEY_6},
61 {"Digit7", ui::VKEY_7},
62 {"Digit8", ui::VKEY_8},
63 {"Digit9", ui::VKEY_9},
64 {"Digit0", ui::VKEY_0},
65 };
66
67 const KeyCodeTestMap test_numpad_map[] = {
68 {"Numpad0", ui::VKEY_NUMPAD0},
69 {"Numpad1", ui::VKEY_NUMPAD1},
70 {"Numpad2", ui::VKEY_NUMPAD2},
71 {"Numpad3", ui::VKEY_NUMPAD3},
72 {"Numpad4", ui::VKEY_NUMPAD4},
73 {"Numpad5", ui::VKEY_NUMPAD5},
74 {"Numpad6", ui::VKEY_NUMPAD6},
75 {"Numpad7", ui::VKEY_NUMPAD7},
76 {"Numpad8", ui::VKEY_NUMPAD8},
77 {"Numpad9", ui::VKEY_NUMPAD9},
78 {"NumpadMultiply", ui::VKEY_MULTIPLY},
79 {"NumpadAdd", ui::VKEY_ADD},
80 {"NumpadSubtract", ui::VKEY_SUBTRACT},
81 {"NumpadDecimal", ui::VKEY_DECIMAL},
82 {"NumpadDivide", ui::VKEY_DIVIDE},
83 };
84
85 const KeyCodeTestMap test_special_map[] = {
86 {"Enter", ui::VKEY_RETURN},
87 {"ShiftRight", ui::VKEY_SHIFT},
88 {"Space", ui::VKEY_SPACE},
89 {"Backquote", ui::VKEY_OEM_3},
90 {"Comma", ui::VKEY_OEM_COMMA},
91 {"Period", ui::VKEY_OEM_PERIOD},
92 {"Home", ui::VKEY_HOME},
93 };
94
95 } // namespace remoting
96 #endif // CHROME_TEST_REMOTING_KEY_CODE_TEST_MAP_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698