Skip to content

Commit 3ba0533

Browse files
Merge pull request #207 from WisdomCode/master
Add non US Backslash for international keyboards on Linux
2 parents 1a7ed53 + b122403 commit 3ba0533

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

sunshine/platform/linux/input.cpp

+3-2
Original file line numberDiff line numberDiff line change
@@ -51,8 +51,8 @@ struct keycode_t {
5151

5252
constexpr auto UNKNOWN = 0;
5353

54-
static constexpr std::array<keycode_t, 0xDF> init_keycodes() {
55-
std::array<keycode_t, 0xDF> keycodes {};
54+
static constexpr std::array<keycode_t, 0xE3> init_keycodes() {
55+
std::array<keycode_t, 0xE3> keycodes {};
5656

5757
#define __CONVERT(wincode, linuxcode, scancode) \
5858
static_assert(wincode < keycodes.size(), "Keycode doesn't fit into keycode array"); \
@@ -182,6 +182,7 @@ static constexpr std::array<keycode_t, 0xDF> init_keycodes() {
182182
__CONVERT(0xDC /* VKEY_OEM_5 */, KEY_BACKSLASH, 0x70031);
183183
__CONVERT(0xDD /* VKEY_OEM_6 */, KEY_RIGHTBRACE, 0x70030);
184184
__CONVERT(0xDE /* VKEY_OEM_7 */, KEY_APOSTROPHE, 0x70034);
185+
__CONVERT(0xE2 /* VKEY_NON_US_BACKSLASH */, KEY_102ND, 0x70064);
185186
#undef __CONVERT
186187

187188
return keycodes;

0 commit comments

Comments
 (0)