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

Side by Side Diff: ui/events/ozone/layout/xkb/xkb_keyboard_layout_engine_unittest.cc

Issue 1908683002: Replace OS_LEFT/RIGHT with META_LEFT/RIGHT (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 8 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
« no previous file with comments | « ui/events/keycodes/keyboard_code_conversion_unittest.cc ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "ui/events/ozone/layout/xkb/xkb_keyboard_layout_engine.h" 5 #include "ui/events/ozone/layout/xkb/xkb_keyboard_layout_engine.h"
6 6
7 #include <stddef.h> 7 #include <stddef.h>
8 #include <stdint.h> 8 #include <stdint.h>
9 9
10 #include "base/macros.h" 10 #include "base/macros.h"
(...skipping 789 matching lines...) Expand 10 before | Expand all | Expand 10 after
800 800
801 TEST_F(XkbLayoutEngineVkTest, KeyboardCodeForNonPrintable) { 801 TEST_F(XkbLayoutEngineVkTest, KeyboardCodeForNonPrintable) {
802 static const struct { 802 static const struct {
803 VkTestXkbKeyboardLayoutEngine::KeysymEntry test; 803 VkTestXkbKeyboardLayoutEngine::KeysymEntry test;
804 KeyboardCode key_code; 804 KeyboardCode key_code;
805 } kVkeyTestCase[] = { 805 } kVkeyTestCase[] = {
806 {{DomCode::CONTROL_LEFT, XKB_KEY_Control_L}, VKEY_CONTROL}, 806 {{DomCode::CONTROL_LEFT, XKB_KEY_Control_L}, VKEY_CONTROL},
807 {{DomCode::CONTROL_RIGHT, XKB_KEY_Control_R}, VKEY_CONTROL}, 807 {{DomCode::CONTROL_RIGHT, XKB_KEY_Control_R}, VKEY_CONTROL},
808 {{DomCode::SHIFT_LEFT, XKB_KEY_Shift_L}, VKEY_SHIFT}, 808 {{DomCode::SHIFT_LEFT, XKB_KEY_Shift_L}, VKEY_SHIFT},
809 {{DomCode::SHIFT_RIGHT, XKB_KEY_Shift_R}, VKEY_SHIFT}, 809 {{DomCode::SHIFT_RIGHT, XKB_KEY_Shift_R}, VKEY_SHIFT},
810 {{DomCode::OS_LEFT, XKB_KEY_Super_L}, VKEY_LWIN}, 810 {{DomCode::META_LEFT, XKB_KEY_Super_L}, VKEY_LWIN},
811 {{DomCode::OS_RIGHT, XKB_KEY_Super_R}, VKEY_LWIN}, 811 {{DomCode::META_RIGHT, XKB_KEY_Super_R}, VKEY_LWIN},
812 {{DomCode::ALT_LEFT, XKB_KEY_Alt_L}, VKEY_MENU}, 812 {{DomCode::ALT_LEFT, XKB_KEY_Alt_L}, VKEY_MENU},
813 {{DomCode::ALT_RIGHT, XKB_KEY_Alt_R}, VKEY_MENU}, 813 {{DomCode::ALT_RIGHT, XKB_KEY_Alt_R}, VKEY_MENU},
814 {{DomCode::ALT_RIGHT, XKB_KEY_ISO_Level3_Shift}, VKEY_ALTGR}, 814 {{DomCode::ALT_RIGHT, XKB_KEY_ISO_Level3_Shift}, VKEY_ALTGR},
815 {{DomCode::DIGIT1, XKB_KEY_1}, VKEY_1}, 815 {{DomCode::DIGIT1, XKB_KEY_1}, VKEY_1},
816 {{DomCode::NUMPAD1, XKB_KEY_KP_1}, VKEY_1}, 816 {{DomCode::NUMPAD1, XKB_KEY_KP_1}, VKEY_1},
817 {{DomCode::CAPS_LOCK, XKB_KEY_Caps_Lock}, VKEY_CAPITAL}, 817 {{DomCode::CAPS_LOCK, XKB_KEY_Caps_Lock}, VKEY_CAPITAL},
818 {{DomCode::ENTER, XKB_KEY_Return}, VKEY_RETURN}, 818 {{DomCode::ENTER, XKB_KEY_Return}, VKEY_RETURN},
819 {{DomCode::NUMPAD_ENTER, XKB_KEY_KP_Enter}, VKEY_RETURN}, 819 {{DomCode::NUMPAD_ENTER, XKB_KEY_KP_Enter}, VKEY_RETURN},
820 {{DomCode::SLEEP, XKB_KEY_XF86Sleep}, VKEY_SLEEP}, 820 {{DomCode::SLEEP, XKB_KEY_XF86Sleep}, VKEY_SLEEP},
821 // Verify that number pad digits produce located VKEY codes. 821 // Verify that number pad digits produce located VKEY codes.
(...skipping 73 matching lines...) Expand 10 before | Expand all | Expand 10 after
895 std::string layout_id; 895 std::string layout_id;
896 std::string layout_variant; 896 std::string layout_variant;
897 XkbKeyboardLayoutEngine::ParseLayoutName(e->layout_name, &layout_id, 897 XkbKeyboardLayoutEngine::ParseLayoutName(e->layout_name, &layout_id,
898 &layout_variant); 898 &layout_variant);
899 EXPECT_EQ(layout_id, e->layout); 899 EXPECT_EQ(layout_id, e->layout);
900 EXPECT_EQ(layout_variant, e->variant); 900 EXPECT_EQ(layout_variant, e->variant);
901 } 901 }
902 } 902 }
903 903
904 } // namespace ui 904 } // namespace ui
OLDNEW
« no previous file with comments | « ui/events/keycodes/keyboard_code_conversion_unittest.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698