Skip to content
This repository was archived by the owner on Apr 3, 2020. It is now read-only.

Commit 9653b26

Browse files
author
Kevin Schoedel
committed
Fix VKEY determination for non-US layouts under Ozone.
We attempt to match Windows behaviour for the value of VKEY on a keystroke. Some XKB layouts generate characters for AltGr+key combinations that are not present in the reference (Windows-based) sources, which led to mismtaches in the mappings, and incorrect VKEY values for those keys. To avoid this, we match on any AltGr+key result in cases the reference has none. The corresponding test is revised to use a valid dummy character for those cases, rather than 'NoSymbol'. TBR=spang BUG=480529 Review URL: https://codereview.chromium.org/1100393005 Cr-Commit-Position: refs/heads/master@{#326695} (cherry picked from commit e63d52e) Review URL: https://codereview.chromium.org/1109873003 Cr-Commit-Position: refs/branch-heads/2357@{#235} Cr-Branched-From: 59d4494-refs/heads/master@{#323860}
1 parent e1e37a4 commit 9653b26

File tree

2 files changed

+56
-68
lines changed

2 files changed

+56
-68
lines changed

ui/events/ozone/layout/xkb/xkb_keyboard_layout_engine.cc

Lines changed: 37 additions & 49 deletions
Original file line numberDiff line numberDiff line change
@@ -96,7 +96,7 @@ const PrintableSubEntry kU0022[] = {
9696
const PrintableSubEntry kU0023[] = {
9797
{DomCode::BACKQUOTE, 0, 0, kAny, kAny, VKEY_OEM_7},
9898
{DomCode::BACKSLASH, 1, 0, 0x0027, kAny, VKEY_OEM_2}, // apostrophe
99-
{DomCode::BACKSLASH, 1, 1, 0x007E, kNone, VKEY_OEM_7}}; // ~, NoSymbol
99+
{DomCode::BACKSLASH, 1, 0, 0x007E, kAny, VKEY_OEM_7}}; // ~, NoSymbol
100100

101101
// U+0024 dollar sign
102102
const PrintableSubEntry kU0024[] = {
@@ -109,19 +109,17 @@ const PrintableSubEntry kU0027[] = {
109109
{DomCode::KEY_Q, 0, 0, kAny, kAny, VKEY_OEM_7},
110110
{DomCode::BRACKET_RIGHT, 0, 0, kAny, kAny, VKEY_OEM_1},
111111
{DomCode::SLASH, 0, 0, kAny, kAny, VKEY_OEM_7},
112-
{DomCode::QUOTE, 1, 0, 0x0022, kAny, VKEY_OEM_7}, // quote
113-
{DomCode::BACKQUOTE, 1, 0, 0x0022, kAny, VKEY_OEM_3}, // quote
114-
{DomCode::BACKQUOTE, 1, 0, 0x00B7, kAny, VKEY_OEM_5}, // middle dot
115-
{DomCode::BACKSLASH, 1, 0, kNone, kAny, VKEY_OEM_5}, // NoSymbol
116-
{DomCode::MINUS, 1, 1, 0x003F, kNone, VKEY_OEM_4}, // ?, NoSymbol
117-
{DomCode::MINUS, 1, 1, 0x003F, 0x00DD, VKEY_OEM_4}, // ?, Y acute
118-
{DomCode::EQUAL, 1, 1, 0x002A, kNone, VKEY_OEM_PLUS}, // *, NoSymbol
119-
{DomCode::QUOTE, 1, 1, 0x0040, kNone, VKEY_OEM_3}, // @, NoSymbol
120-
{DomCode::BACKSLASH, 1, 1, 0x002A, kNone, VKEY_OEM_2}, // *, NoSymbol
112+
{DomCode::QUOTE, 1, 0, 0x0022, kAny, VKEY_OEM_7}, // quote
113+
{DomCode::BACKQUOTE, 1, 0, 0x0022, kAny, VKEY_OEM_3}, // quote
114+
{DomCode::BACKQUOTE, 1, 0, 0x00B7, kAny, VKEY_OEM_5}, // middle dot
115+
{DomCode::BACKSLASH, 1, 0, kNone, kAny, VKEY_OEM_5}, // NoSymbol
116+
{DomCode::MINUS, 1, 0, 0x003F, kAny, VKEY_OEM_4}, // ?
117+
{DomCode::EQUAL, 1, 0, 0x002A, kAny, VKEY_OEM_PLUS}, // *
118+
{DomCode::QUOTE, 1, 0, 0x0040, kAny, VKEY_OEM_3}, // @
121119
{DomCode::BACKSLASH, 1, 1, 0x002A, 0x00BD, VKEY_OEM_5}, // *, one half
122-
{DomCode::BACKSLASH, 1, 1, 0x002A, 0x0141, VKEY_OEM_2}, // *, L stroke
123-
{DomCode::KEY_Z, 1, 1, 0x0022, kNone, VKEY_Z}, // quote, NoSymbol
124-
{DomCode::KEY_Z, 1, 1, 0x0022, 0x0158, VKEY_OEM_7}}; // quote, R caron
120+
{DomCode::BACKSLASH, 1, 0, 0x002A, kAny, VKEY_OEM_2}, // *, NoSymbol
121+
{DomCode::KEY_Z, 1, 1, 0x0022, 0x0158, VKEY_OEM_7}, // quote, R caron
122+
{DomCode::KEY_Z, 1, 0, 0x0022, kAny, VKEY_Z}}; // quote
125123

126124
// U+0028 left parenthesis
127125
const PrintableSubEntry kU0028[] = {
@@ -148,9 +146,8 @@ const PrintableSubEntry kU002B[] = {
148146
{DomCode::BRACKET_RIGHT, 0, 0, kAny, kAny, VKEY_OEM_PLUS},
149147
{DomCode::SEMICOLON, 0, 0, kAny, kAny, VKEY_OEM_PLUS},
150148
{DomCode::BACKSLASH, 0, 0, kAny, kAny, VKEY_OEM_2},
151-
{DomCode::MINUS, 1, 1, 0x003F, kNone, VKEY_OEM_PLUS}, // ?, NoSymbol
152149
{DomCode::MINUS, 1, 1, 0x003F, 0x005C, VKEY_OEM_MINUS}, // ?, backslash
153-
{DomCode::MINUS, 1, 1, 0x003F, 0x0151, VKEY_OEM_PLUS}}; // ?, o''
150+
{DomCode::MINUS, 1, 0, 0x003F, kAny, VKEY_OEM_PLUS}}; // ?
154151

155152
// U+002C comma
156153
const PrintableSubEntry kU002C[] = {
@@ -171,12 +168,10 @@ const PrintableSubEntry kU002D[] = {
171168
{DomCode::KEY_A, 0, 0, kAny, kAny, VKEY_OEM_MINUS},
172169
{DomCode::QUOTE, 0, 0, kAny, kAny, VKEY_OEM_MINUS},
173170
{DomCode::SLASH, 1, 0, 0x003D, kAny, VKEY_OEM_MINUS}, // =
174-
{DomCode::EQUAL, 1, 1, 0x005F, kNone, VKEY_OEM_MINUS}, // _, NoSymbol
175-
{DomCode::EQUAL, 1, 1, 0x005F, 0x0157, VKEY_OEM_4}, // _, r cedilla
176-
{DomCode::SLASH, 1, 1, 0x005F, kNone, VKEY_OEM_MINUS}, // _, NoSymbol
177-
{DomCode::SLASH, 1, 1, 0x005F, 0x002A, VKEY_OEM_MINUS}, // _, *
178-
{DomCode::SLASH, 1, 1, 0x005F, 0x002F, VKEY_OEM_2}, // _, /
179-
{DomCode::SLASH, 1, 1, 0x005F, 0x006E, VKEY_OEM_MINUS}}; // _, n
171+
{DomCode::EQUAL, 1, 1, 0x005F, 0x0157, VKEY_OEM_4}, // _, r cedilla
172+
{DomCode::EQUAL, 1, 0, 0x005F, kAny, VKEY_OEM_MINUS}, // _
173+
{DomCode::SLASH, 1, 1, 0x005F, 0x002F, VKEY_OEM_2}, // _, /
174+
{DomCode::SLASH, 1, 0, 0x005F, kAny, VKEY_OEM_MINUS}}; // _
180175

181176
// U+002E full stop
182177
const PrintableSubEntry kU002E[] = {
@@ -220,16 +215,15 @@ const PrintableSubEntry kU003B[] = {
220215
{DomCode::KEY_Z, 0, 0, kAny, kAny, VKEY_OEM_1},
221216
{DomCode::COMMA, 0, 0, kAny, kAny, VKEY_OEM_PERIOD},
222217
{DomCode::SLASH, 0, 0, kAny, kAny, VKEY_OEM_2}};
223-
224218
// U+003D =
225219
const PrintableSubEntry kU003D[] = {
226220
{DomCode::DIGIT8, 0, 0, kAny, kAny, VKEY_8},
227221
{DomCode::EQUAL, 0, 0, kAny, kAny, VKEY_OEM_PLUS},
228222
{DomCode::BRACKET_RIGHT, 0, 0, kAny, kAny, VKEY_OEM_PLUS},
229-
{DomCode::SLASH, 1, 0, 0x0025, kAny, VKEY_OEM_8}, // %
230-
{DomCode::SLASH, 1, 0, 0x002B, kAny, VKEY_OEM_PLUS}, // +
231-
{DomCode::MINUS, 1, 1, 0x0025, kNone, VKEY_OEM_PLUS}, // %, NoSymbol
232-
{DomCode::MINUS, 1, 1, 0x0025, 0x002D, VKEY_OEM_MINUS}}; // %, -
223+
{DomCode::SLASH, 1, 0, 0x0025, kAny, VKEY_OEM_8}, // %
224+
{DomCode::SLASH, 1, 0, 0x002B, kAny, VKEY_OEM_PLUS}, // +
225+
{DomCode::MINUS, 1, 1, 0x0025, 0x002D, VKEY_OEM_MINUS}, // %, -
226+
{DomCode::MINUS, 1, 0, 0x0025, kAny, VKEY_OEM_PLUS}}; // %, NoSymbol
233227

234228
// U+003F ?
235229
const PrintableSubEntry kU003F[] = {
@@ -276,12 +270,7 @@ const PrintableSubEntry kU005F[] = {
276270
const PrintableSubEntry kU0060[] = {
277271
{DomCode::BACKQUOTE, 1, 0, kNone, kAny, VKEY_OEM_3}, // NoSymbol
278272
{DomCode::BACKQUOTE, 1, 0, 0x00AC, kAny, VKEY_OEM_8}, // not
279-
{DomCode::BACKQUOTE, 1, 1, 0x007E, kNone, VKEY_OEM_3}, // ~, NoSymbol
280-
{DomCode::BACKQUOTE, 1, 1, 0x007E, 0x0031, VKEY_OEM_3}, // ~, 1
281-
{DomCode::BACKQUOTE, 1, 1, 0x007E, 0x003B, VKEY_OEM_3}, // ~, ;
282-
{DomCode::BACKQUOTE, 1, 1, 0x007E, 0x0060, VKEY_OEM_3}, // ~, `
283-
{DomCode::BACKQUOTE, 1, 1, 0x007E, 0x00BF, VKEY_OEM_3}, // ~, inverted ?
284-
{DomCode::BACKQUOTE, 1, 1, 0x007E, 0x0151, VKEY_OEM_3}}; // ~, o''
273+
{DomCode::BACKQUOTE, 1, 0, 0x007E, kAny, VKEY_OEM_3}}; // ~
285274

286275
// U+00A7 section
287276
const PrintableSubEntry kU00A7[] = {
@@ -327,9 +316,7 @@ const PrintableSubEntry kU00E2[] = {
327316
const PrintableSubEntry kU00E4[] = {
328317
{DomCode::BRACKET_RIGHT, 0, 0, kAny, kAny, VKEY_OEM_6},
329318
{DomCode::QUOTE, 1, 0, 0x00E0, kAny, VKEY_OEM_5}, // a grave
330-
{DomCode::QUOTE, 1, 1, 0x00C4, kNone, VKEY_OEM_7}, // A dia., NoSymbol
331-
{DomCode::QUOTE, 1, 1, 0x00C4, 0x015A, VKEY_OEM_7}, // A dia., S acute
332-
{DomCode::QUOTE, 1, 1, 0x00C4, 0x0159, VKEY_OEM_7}}; // A dia., r caron
319+
{DomCode::QUOTE, 1, 0, 0x00C4, kAny, VKEY_OEM_7}}; // A dia.
333320

334321
// U+00E6 ae
335322
const PrintableSubEntry kU00E6[] = {
@@ -344,8 +331,8 @@ const PrintableSubEntry kU00E7[] = {
344331
{DomCode::QUOTE, 0, 0, kAny, kAny, VKEY_OEM_7},
345332
{DomCode::BACKSLASH, 0, 0, kAny, kAny, VKEY_OEM_2},
346333
{DomCode::COMMA, 0, 0, kAny, kAny, VKEY_OEM_COMMA},
347-
{DomCode::SEMICOLON, 1, 1, 0x00C7, kNone, VKEY_OEM_1}, // C ced., NoSy
348-
{DomCode::SEMICOLON, 1, 1, 0x00C7, 0x00DE, VKEY_OEM_3}}; // C ced., Thorn
334+
{DomCode::SEMICOLON, 1, 1, 0x00C7, 0x00DE, VKEY_OEM_3}, // C ced., Thorn
335+
{DomCode::SEMICOLON, 1, 0, 0x00C7, kAny, VKEY_OEM_1}}; // C ced., NoSy
349336

350337
// U+00E8 e grave
351338
const PrintableSubEntry kU00E8[] = {
@@ -386,9 +373,9 @@ const PrintableSubEntry kU00F6[] = {
386373
{DomCode::DIGIT0, 0, 0, kAny, kAny, VKEY_OEM_3},
387374
{DomCode::MINUS, 0, 0, kAny, kAny, VKEY_OEM_PLUS},
388375
{DomCode::BRACKET_LEFT, 0, 0, kAny, kAny, VKEY_OEM_4},
389-
{DomCode::SEMICOLON, 1, 0, 0x00E9, kAny, VKEY_OEM_7}, // e acute
390-
{DomCode::SEMICOLON, 1, 1, 0x00D6, kNone, VKEY_OEM_3}, // O dia., NoSy
391-
{DomCode::SEMICOLON, 1, 1, 0x00D6, 0x0162, VKEY_OEM_3}}; // O dia., T ced.
376+
{DomCode::SEMICOLON, 1, 0, 0x00E9, kAny, VKEY_OEM_7}, // e acute
377+
{DomCode::SEMICOLON, 1, 1, 0x00D6, 0x0162, VKEY_OEM_3}, // O dia., T ced.
378+
{DomCode::SEMICOLON, 1, 0, 0x00D6, kAny, VKEY_OEM_3}}; // O diaresis
392379

393380
// U+00F8 o stroke
394381
const PrintableSubEntry kU00F8[] = {
@@ -408,10 +395,10 @@ const PrintableSubEntry kU00FA[] = {
408395
// U+00FC u diaeresis
409396
const PrintableSubEntry kU00FC[] = {
410397
{DomCode::KEY_W, 0, 0, kAny, kAny, VKEY_W},
411-
{DomCode::BRACKET_LEFT, 1, 0, 0x00E8, kAny, VKEY_OEM_1}, // e grave
412-
{DomCode::MINUS, 1, 1, 0x00DC, kNone, VKEY_OEM_2}, // U dia., NoSy
413-
{DomCode::BRACKET_LEFT, 1, 1, 0x00DC, kNone, VKEY_OEM_1}, // U dia., NoSy
414-
{DomCode::BRACKET_LEFT, 1, 1, 0x00DC, 0x0141, VKEY_OEM_3}}; // U dia., L-
398+
{DomCode::BRACKET_LEFT, 1, 0, 0x00E8, kAny, VKEY_OEM_1}, // e grave
399+
{DomCode::MINUS, 1, 0, 0x00DC, kAny, VKEY_OEM_2}, // U diaresis
400+
{DomCode::BRACKET_LEFT, 1, 1, 0x00DC, 0x0141, VKEY_OEM_3}, // U dia., L-
401+
{DomCode::BRACKET_LEFT, 1, 0, 0x00DC, kAny, VKEY_OEM_1}}; // U diaresis
415402

416403
// U+0103 a breve
417404
const PrintableSubEntry kU0103[] = {
@@ -445,13 +432,13 @@ const PrintableSubEntry kU0117[] = {
445432
// U+0119 e ogonek
446433
const PrintableSubEntry kU0119[] = {
447434
{DomCode::DIGIT3, 0, 0, kAny, kAny, VKEY_3},
448-
{DomCode::SLASH, 1, 1, 0x0118, kNone, VKEY_OEM_MINUS}, // E ogonek, NoSy
449-
{DomCode::SLASH, 1, 1, 0x0118, 0x006E, VKEY_OEM_2}}; // E ogonek, n
435+
{DomCode::SLASH, 1, 1, 0x0118, 0x006E, VKEY_OEM_2}, // E ogonek, n
436+
{DomCode::SLASH, 1, 0, 0x0118, kAny, VKEY_OEM_MINUS}}; // E ogonek
450437

451438
// U+012F i ogonek
452439
const PrintableSubEntry kU012F[] = {
453440
{DomCode::DIGIT5, 0, 0, kAny, kAny, VKEY_5},
454-
{DomCode::BRACKET_LEFT, 1, 1, 0x012E, kNone, VKEY_OEM_4}}; // Iogonek, NoSy
441+
{DomCode::BRACKET_LEFT, 1, 0, 0x012E, kAny, VKEY_OEM_4}}; // Iogonek
455442

456443
// U+0142 l stroke
457444
const PrintableSubEntry kU0142[] = {
@@ -481,8 +468,8 @@ const PrintableSubEntry kU016B[] = {
481468
// U+0173 u ogonek
482469
const PrintableSubEntry kU0173[] = {
483470
{DomCode::DIGIT7, 0, 0, kAny, kAny, VKEY_7},
484-
{DomCode::SEMICOLON, 1, 1, 0x0172, kNone, VKEY_OEM_3}, // U ogo., NoSy
485-
{DomCode::SEMICOLON, 1, 1, 0x0172, 0x0162, VKEY_OEM_1}}; // U ogo., T ced.
471+
{DomCode::SEMICOLON, 1, 1, 0x0172, 0x0162, VKEY_OEM_1}, // U ogo., T ced.
472+
{DomCode::SEMICOLON, 1, 0, 0x0172, kAny, VKEY_OEM_3}}; // U ogonek
486473

487474
// U+017C z dot above
488475
const PrintableSubEntry kU017C[] = {
@@ -964,4 +951,5 @@ void XkbKeyboardLayoutEngine::ParseLayoutName(const std::string& layout_name,
964951
*layout_variant = layout_name.substr(dash_index + 1);
965952
}
966953
}
954+
967955
} // namespace ui

ui/events/ozone/layout/xkb/xkb_keyboard_layout_engine_unittest.cc

Lines changed: 19 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -137,7 +137,7 @@ TEST_F(XkbLayoutEngineVkTest, KeyboardCodeForPrintable) {
137137
// number sign, apostrophe, *
138138
/* 5 */ {0x0023, 0x0027, 0x2461, DomCode::BACKSLASH, VKEY_OEM_2},
139139
// number sign, tilde, unmapped
140-
/* 6 */ {0x0023, 0x007E, 0x0000, DomCode::BACKSLASH, VKEY_OEM_7},
140+
/* 6 */ {0x0023, 0x007E, 0x2461, DomCode::BACKSLASH, VKEY_OEM_7},
141141
// number sign, *, *
142142
/* 7 */ {0x0023, 0x2460, 0x2461, DomCode::BACKQUOTE, VKEY_OEM_7},
143143
// dollar sign, *, *
@@ -151,27 +151,27 @@ TEST_F(XkbLayoutEngineVkTest, KeyboardCodeForPrintable) {
151151
// apostrophe, unmapped, *
152152
/* 12 */ {0x0027, 0x0000, 0x2461, DomCode::BACKSLASH, VKEY_OEM_5},
153153
// apostrophe, quotation mark, unmapped
154-
/* 13 */ {0x0027, 0x0022, 0x0000, DomCode::KEY_Z, VKEY_Z},
154+
/* 13 */ {0x0027, 0x0022, 0x2461, DomCode::KEY_Z, VKEY_Z},
155155
// apostrophe, quotation mark, R caron
156156
/* 14 */ {0x0027, 0x0022, 0x0158, DomCode::KEY_Z, VKEY_OEM_7},
157157
// apostrophe, quotation mark, *
158158
/* 15 */ {0x0027, 0x0022, 0x2461, DomCode::BACKQUOTE, VKEY_OEM_3},
159159
// apostrophe, quotation mark, *
160160
/* 16 */ {0x0027, 0x0022, 0x2461, DomCode::QUOTE, VKEY_OEM_7},
161161
// apostrophe, asterisk, unmapped
162-
/* 17 */ {0x0027, 0x002A, 0x0000, DomCode::BACKSLASH, VKEY_OEM_2},
162+
/* 17 */ {0x0027, 0x002A, 0x2461, DomCode::BACKSLASH, VKEY_OEM_2},
163163
// apostrophe, asterisk, unmapped
164-
/* 18 */ {0x0027, 0x002A, 0x0000, DomCode::EQUAL, VKEY_OEM_PLUS},
164+
/* 18 */ {0x0027, 0x002A, 0x2461, DomCode::EQUAL, VKEY_OEM_PLUS},
165165
// apostrophe, asterisk, vulgar fraction one half
166166
/* 19 */ {0x0027, 0x002A, 0x00BD, DomCode::BACKSLASH, VKEY_OEM_5},
167167
// apostrophe, asterisk, L stroke
168168
/* 20 */ {0x0027, 0x002A, 0x0141, DomCode::BACKSLASH, VKEY_OEM_2},
169169
// apostrophe, question mark, unmapped
170-
/* 21 */ {0x0027, 0x003F, 0x0000, DomCode::MINUS, VKEY_OEM_4},
170+
/* 21 */ {0x0027, 0x003F, 0x2461, DomCode::MINUS, VKEY_OEM_4},
171171
// apostrophe, question mark, Y acute
172172
/* 22 */ {0x0027, 0x003F, 0x00DD, DomCode::MINUS, VKEY_OEM_4},
173173
// apostrophe, commercial at, unmapped
174-
/* 23 */ {0x0027, 0x0040, 0x0000, DomCode::QUOTE, VKEY_OEM_3},
174+
/* 23 */ {0x0027, 0x0040, 0x2461, DomCode::QUOTE, VKEY_OEM_3},
175175
// apostrophe, middle dot, *
176176
/* 24 */ {0x0027, 0x00B7, 0x2461, DomCode::BACKQUOTE, VKEY_OEM_5},
177177
// apostrophe, *, *
@@ -199,7 +199,7 @@ TEST_F(XkbLayoutEngineVkTest, KeyboardCodeForPrintable) {
199199
// asterisk, *, *
200200
/* 36 */ {0x002A, 0x2460, 0x2461, DomCode::BRACKET_RIGHT, VKEY_OEM_1},
201201
// plus sign, question mark, unmapped
202-
/* 37 */ {0x002B, 0x003F, 0x0000, DomCode::MINUS, VKEY_OEM_PLUS},
202+
/* 37 */ {0x002B, 0x003F, 0x2461, DomCode::MINUS, VKEY_OEM_PLUS},
203203
// plus sign, question mark, reverse solidus
204204
/* 38 */ {0x002B, 0x003F, 0x005C, DomCode::MINUS, VKEY_OEM_MINUS},
205205
// plus sign, question mark, o double acute
@@ -235,9 +235,9 @@ TEST_F(XkbLayoutEngineVkTest, KeyboardCodeForPrintable) {
235235
// hyphen-minus, equals sign, *
236236
/* 54 */ {0x002D, 0x003D, 0x2461, DomCode::SLASH, VKEY_OEM_MINUS},
237237
// hyphen-minus, low line, unmapped
238-
/* 55 */ {0x002D, 0x005F, 0x0000, DomCode::EQUAL, VKEY_OEM_MINUS},
238+
/* 55 */ {0x002D, 0x005F, 0x2461, DomCode::EQUAL, VKEY_OEM_MINUS},
239239
// hyphen-minus, low line, unmapped
240-
/* 56 */ {0x002D, 0x005F, 0x0000, DomCode::SLASH, VKEY_OEM_MINUS},
240+
/* 56 */ {0x002D, 0x005F, 0x2461, DomCode::SLASH, VKEY_OEM_MINUS},
241241
// hyphen-minus, low line, asterisk
242242
/* 57 */ {0x002D, 0x005F, 0x002A, DomCode::SLASH, VKEY_OEM_MINUS},
243243
// hyphen-minus, low line, solidus
@@ -321,7 +321,7 @@ TEST_F(XkbLayoutEngineVkTest, KeyboardCodeForPrintable) {
321321
// less-than sign, *, *
322322
/* 97 */ {0x003C, 0x2460, 0x2461, DomCode::NONE, VKEY_OEM_5},
323323
// equals sign, percent sign, unmapped
324-
/* 98 */ {0x003D, 0x0025, 0x0000, DomCode::MINUS, VKEY_OEM_PLUS},
324+
/* 98 */ {0x003D, 0x0025, 0x2461, DomCode::MINUS, VKEY_OEM_PLUS},
325325
// equals sign, percent sign, hyphen-minus
326326
/* 99 */ {0x003D, 0x0025, 0x002D, DomCode::MINUS, VKEY_OEM_MINUS},
327327
// equals sign, percent sign, *
@@ -383,7 +383,7 @@ TEST_F(XkbLayoutEngineVkTest, KeyboardCodeForPrintable) {
383383
// grave accent, unmapped, *
384384
/* 128 */ {0x0060, 0x0000, 0x2461, DomCode::BACKQUOTE, VKEY_OEM_3},
385385
// grave accent, tilde, unmapped
386-
/* 129 */ {0x0060, 0x007E, 0x0000, DomCode::BACKQUOTE, VKEY_OEM_3},
386+
/* 129 */ {0x0060, 0x007E, 0x2461, DomCode::BACKQUOTE, VKEY_OEM_3},
387387
// grave accent, tilde, digit one
388388
/* 130 */ {0x0060, 0x007E, 0x0031, DomCode::BACKQUOTE, VKEY_OEM_3},
389389
// grave accent, tilde, semicolon
@@ -459,7 +459,7 @@ TEST_F(XkbLayoutEngineVkTest, KeyboardCodeForPrintable) {
459459
// a circumflex, *, *
460460
/* 166 */ {0x00E2, 0x2460, 0x2461, DomCode::DIGIT2, VKEY_2},
461461
// a diaeresis, A diaeresis, unmapped
462-
/* 167 */ {0x00E4, 0x00C4, 0x0000, DomCode::QUOTE, VKEY_OEM_7},
462+
/* 167 */ {0x00E4, 0x00C4, 0x2461, DomCode::QUOTE, VKEY_OEM_7},
463463
// a diaeresis, A diaeresis, r caron
464464
/* 168 */ {0x00E4, 0x00C4, 0x0159, DomCode::QUOTE, VKEY_OEM_7},
465465
// a diaeresis, A diaeresis, S acute
@@ -475,7 +475,7 @@ TEST_F(XkbLayoutEngineVkTest, KeyboardCodeForPrintable) {
475475
// ae, *, *
476476
/* 174 */ {0x00E6, 0x2460, 0x2461, DomCode::SEMICOLON, VKEY_OEM_3},
477477
// c cedilla, C cedilla, unmapped
478-
/* 175 */ {0x00E7, 0x00C7, 0x0000, DomCode::SEMICOLON, VKEY_OEM_1},
478+
/* 175 */ {0x00E7, 0x00C7, 0x2461, DomCode::SEMICOLON, VKEY_OEM_1},
479479
// c cedilla, C cedilla, Thorn
480480
/* 176 */ {0x00E7, 0x00C7, 0x00DE, DomCode::SEMICOLON, VKEY_OEM_3},
481481
// c cedilla, *, *
@@ -537,7 +537,7 @@ TEST_F(XkbLayoutEngineVkTest, KeyboardCodeForPrintable) {
537537
// o tilde, *, *
538538
/* 205 */ {0x00F5, 0x2460, 0x2461, DomCode::NONE, VKEY_OEM_4},
539539
// o diaeresis, O diaeresis, unmapped
540-
/* 206 */ {0x00F6, 0x00D6, 0x0000, DomCode::SEMICOLON, VKEY_OEM_3},
540+
/* 206 */ {0x00F6, 0x00D6, 0x2461, DomCode::SEMICOLON, VKEY_OEM_3},
541541
// o diaeresis, O diaeresis, T cedilla
542542
/* 207 */ {0x00F6, 0x00D6, 0x0162, DomCode::SEMICOLON, VKEY_OEM_3},
543543
// o diaeresis, e acute, *
@@ -563,9 +563,9 @@ TEST_F(XkbLayoutEngineVkTest, KeyboardCodeForPrintable) {
563563
// u acute, *, *
564564
/* 218 */ {0x00FA, 0x2460, 0x2461, DomCode::BRACKET_RIGHT, VKEY_OEM_6},
565565
// u diaeresis, U diaeresis, unmapped
566-
/* 219 */ {0x00FC, 0x00DC, 0x0000, DomCode::BRACKET_LEFT, VKEY_OEM_1},
566+
/* 219 */ {0x00FC, 0x00DC, 0x2461, DomCode::BRACKET_LEFT, VKEY_OEM_1},
567567
// u diaeresis, U diaeresis, unmapped
568-
/* 220 */ {0x00FC, 0x00DC, 0x0000, DomCode::MINUS, VKEY_OEM_2},
568+
/* 220 */ {0x00FC, 0x00DC, 0x2461, DomCode::MINUS, VKEY_OEM_2},
569569
// u diaeresis, U diaeresis, L stroke
570570
/* 221 */ {0x00FC, 0x00DC, 0x0141, DomCode::BRACKET_LEFT, VKEY_OEM_3},
571571
// u diaeresis, e grave, *
@@ -613,7 +613,7 @@ TEST_F(XkbLayoutEngineVkTest, KeyboardCodeForPrintable) {
613613
// e dot above, *, *
614614
/* 243 */ {0x0117, 0x2460, 0x2461, DomCode::QUOTE, VKEY_OEM_7},
615615
// e ogonek, E ogonek, unmapped
616-
/* 244 */ {0x0119, 0x0118, 0x0000, DomCode::SLASH, VKEY_OEM_MINUS},
616+
/* 244 */ {0x0119, 0x0118, 0x2461, DomCode::SLASH, VKEY_OEM_MINUS},
617617
// e ogonek, E ogonek, n
618618
/* 245 */ {0x0119, 0x0118, 0x006E, DomCode::SLASH, VKEY_OEM_2},
619619
// e ogonek, *, *
@@ -629,7 +629,7 @@ TEST_F(XkbLayoutEngineVkTest, KeyboardCodeForPrintable) {
629629
// i macron, *, *
630630
/* 251 */ {0x012B, 0x2460, 0x2461, DomCode::NONE, VKEY_OEM_6},
631631
// i ogonek, I ogonek, unmapped
632-
/* 252 */ {0x012F, 0x012E, 0x0000, DomCode::BRACKET_LEFT, VKEY_OEM_4},
632+
/* 252 */ {0x012F, 0x012E, 0x2461, DomCode::BRACKET_LEFT, VKEY_OEM_4},
633633
// i ogonek, *, *
634634
/* 253 */ {0x012F, 0x2460, 0x2461, DomCode::DIGIT5, VKEY_5},
635635
// dotless i, *, *
@@ -683,7 +683,7 @@ TEST_F(XkbLayoutEngineVkTest, KeyboardCodeForPrintable) {
683683
// u double acute, *, *
684684
/* 278 */ {0x0171, 0x2460, 0x2461, DomCode::NONE, VKEY_OEM_5},
685685
// u ogonek, U ogonek, unmapped
686-
/* 279 */ {0x0173, 0x0172, 0x0000, DomCode::SEMICOLON, VKEY_OEM_3},
686+
/* 279 */ {0x0173, 0x0172, 0x2461, DomCode::SEMICOLON, VKEY_OEM_3},
687687
// u ogonek, U ogonek, T cedilla
688688
/* 280 */ {0x0173, 0x0172, 0x0162, DomCode::SEMICOLON, VKEY_OEM_1},
689689
// u ogonek, *, *

0 commit comments

Comments
 (0)