From 8b5cdbb3b513225cdb6900332ac34250094cce79 Mon Sep 17 00:00:00 2001 From: Michael Jumper Date: Mon, 26 Jul 2021 20:11:00 -0700 Subject: [PATCH 1/3] GUACAMOLE-1386: Define "Meta" key for on-screen keyboard instead of "Super". The correct key for the "Windows" key (or the Mac "Command" key) is "Meta". The "Super" key is an entirely different key not used for that purpose, and it only currently works with Guacamole because the Guacamole's base RDP keymap specifically maps the "Super" keys to the "Windows" keys. --- .../src/main/frontend/src/layouts/de-de-qwertz.json | 13 ++++++------- .../src/main/frontend/src/layouts/en-us-qwerty.json | 12 ++++++------ .../src/main/frontend/src/layouts/es-es-qwerty.json | 13 ++++++------- .../src/main/frontend/src/layouts/fr-fr-azerty.json | 12 ++++++------ .../src/main/frontend/src/layouts/it-it-qwerty.json | 13 ++++++------- .../src/main/frontend/src/layouts/nl-nl-qwerty.json | 13 ++++++------- .../src/main/frontend/src/layouts/ru-ru-qwerty.json | 12 ++++++------ 7 files changed, 42 insertions(+), 46 deletions(-) diff --git a/guacamole/src/main/frontend/src/layouts/de-de-qwertz.json b/guacamole/src/main/frontend/src/layouts/de-de-qwertz.json index 2b746aaeb..052a3a7e0 100644 --- a/guacamole/src/main/frontend/src/layouts/de-de-qwertz.json +++ b/guacamole/src/main/frontend/src/layouts/de-de-qwertz.json @@ -78,7 +78,6 @@ "Menu" : [{ "title" : "Menu", - "modifier" : "super", "keysym" : 65383 }], "LShift" : [{ @@ -116,10 +115,10 @@ "modifier" : "alt-gr", "keysym" : 65027 }], - "Super" : [{ - "title" : "Super", - "modifier" : "super", - "keysym" : 65515 + "Meta" : [{ + "title" : "Meta", + "modifier" : "meta", + "keysym" : 65511 }], "^" : [ @@ -404,7 +403,7 @@ [ "Tab", "q", "w", "e", "r", "t", "z", "u", "i", "o", "p", "ü", "+", 1, 0.6 ], [ "Caps", "a", "s", "d", "f", "g", "h", "j", "k", "l", "ö", "ä", "#", "Enter" ], [ "LShift", "<", "y", "x", "c", "v", "b", "n", "m", ",", ".", "-", "RShift" ], - [ "LCtrl", "Super", "LAlt", "Space", "AltGr", "Menu", "RCtrl" ] + [ "LCtrl", "Meta", "LAlt", "Space", "AltGr", "Menu", "RCtrl" ] ], @@ -431,7 +430,7 @@ "RShift" : 2.1, "LCtrl" : 1.6, - "Super" : 1.6, + "Meta" : 1.6, "LAlt" : 1.6, "Space" : 6.1, "AltGr" : 1.6, diff --git a/guacamole/src/main/frontend/src/layouts/en-us-qwerty.json b/guacamole/src/main/frontend/src/layouts/en-us-qwerty.json index 13b2ddb6c..fa9a6fe68 100644 --- a/guacamole/src/main/frontend/src/layouts/en-us-qwerty.json +++ b/guacamole/src/main/frontend/src/layouts/en-us-qwerty.json @@ -87,10 +87,10 @@ "modifier" : "alt", "keysym" : 65514 }], - "Super" : [{ - "title" : "Super", - "modifier" : "super", - "keysym" : 65515 + "Meta" : [{ + "title" : "Meta", + "modifier" : "meta", + "keysym" : 65511 }], "`" : [ @@ -353,7 +353,7 @@ [ "Tab", "q", "w", "e", "r", "t", "y", "u", "i", "o", "p", "[", "]", "\\" ], [ "Caps", "a", "s", "d", "f", "g", "h", "j", "k", "l", ";", "'", "Enter" ], [ "LShift", "z", "x", "c", "v", "b", "n", "m", ",", ".", "/", "RShift" ], - [ "LCtrl", "Super", "LAlt", "Space", "RAlt", "Menu", "RCtrl" ] + [ "LCtrl", "Meta", "LAlt", "Space", "RAlt", "Menu", "RCtrl" ] ], @@ -380,7 +380,7 @@ "RShift" : 3.1, "LCtrl" : 1.6, - "Super" : 1.6, + "Meta" : 1.6, "LAlt" : 1.6, "Space" : 6.1, "RAlt" : 1.6, diff --git a/guacamole/src/main/frontend/src/layouts/es-es-qwerty.json b/guacamole/src/main/frontend/src/layouts/es-es-qwerty.json index dc330e598..e88c6cda4 100644 --- a/guacamole/src/main/frontend/src/layouts/es-es-qwerty.json +++ b/guacamole/src/main/frontend/src/layouts/es-es-qwerty.json @@ -78,7 +78,6 @@ "Menu" : [{ "title" : "Menu", - "modifier" : "super", "keysym" : 65383 }], "LShift" : [{ @@ -116,10 +115,10 @@ "modifier" : "alt-gr", "keysym" : 65027 }], - "Super" : [{ - "title" : "Super", - "modifier" : "super", - "keysym" : 65515 + "Meta" : [{ + "title" : "Meta", + "modifier" : "meta", + "keysym" : 65511 }], "º" : [ @@ -410,7 +409,7 @@ [ "Tab", "q", "w", "e", "r", "t", "y", "u", "i", "o", "p", "`", "+", 1, 0.6 ], [ "Caps", "a", "s", "d", "f", "g", "h", "j", "k", "l", "ñ", "´", "ç", "Enter" ], [ "LShift", "<", "z", "x", "c", "v", "b", "n", "m", ",", ".", "-", "RShift" ], - [ "LCtrl", "Super", "LAlt", "Space", "AltGr", "Menu", "RCtrl" ] + [ "LCtrl", "Meta", "LAlt", "Space", "AltGr", "Menu", "RCtrl" ] ], @@ -437,7 +436,7 @@ "RShift" : 2.2, "LCtrl" : 1.6, - "Super" : 1.6, + "Meta" : 1.6, "LAlt" : 1.6, "Space" : 6.4, "AltGr" : 1.6, diff --git a/guacamole/src/main/frontend/src/layouts/fr-fr-azerty.json b/guacamole/src/main/frontend/src/layouts/fr-fr-azerty.json index f24890780..bf3eaf3c9 100644 --- a/guacamole/src/main/frontend/src/layouts/fr-fr-azerty.json +++ b/guacamole/src/main/frontend/src/layouts/fr-fr-azerty.json @@ -118,10 +118,10 @@ "modifier" : "alt-gr", "keysym" : 65027 }], - "Super" : [{ - "title" : "Super", - "modifier" : "super", - "keysym" : 65515 + "Meta" : [{ + "title" : "Meta", + "modifier" : "meta", + "keysym" : 65511 }], "²" : [ @@ -400,7 +400,7 @@ [ "Tab", "a", "z", "e", "r", "t", "y", "u", "i", "o", "p", "^", "$", 1, 0.8 ], [ "Caps", "q", "s", "d", "f", "g", "h", "j", "k", "l", "m", "ù", "*", "Enter" ], [ "LShift", "<", "w", "x", "c", "v", "b", "n", ",", ";", ":", "!", "RShift" ], - [ "LCtrl", "Super", "LAlt", "Space", "AltGr", "Menu", "RCtrl" ] + [ "LCtrl", "Meta", "LAlt", "Space", "AltGr", "Menu", "RCtrl" ] ], @@ -427,7 +427,7 @@ "RShift" : 2.1, "LCtrl" : 1.6, - "Super" : 1.6, + "Meta" : 1.6, "LAlt" : 1.6, "Space" : 6.1, "AltGr" : 1.6, diff --git a/guacamole/src/main/frontend/src/layouts/it-it-qwerty.json b/guacamole/src/main/frontend/src/layouts/it-it-qwerty.json index 17ae06d5a..4775e6fd6 100644 --- a/guacamole/src/main/frontend/src/layouts/it-it-qwerty.json +++ b/guacamole/src/main/frontend/src/layouts/it-it-qwerty.json @@ -78,7 +78,6 @@ "Menu" : [{ "title" : "Menu", - "modifier" : "super", "keysym" : 65383 }], "LShift" : [{ @@ -116,10 +115,10 @@ "modifier" : "alt-gr", "keysym" : 65027 }], - "Super" : [{ - "title" : "Super", - "modifier" : "super", - "keysym" : 65515 + "Meta" : [{ + "title" : "Meta", + "modifier" : "meta", + "keysym" : 65511 }], "\\" : [ @@ -407,7 +406,7 @@ [ "Tab", "q", "w", "e", "r", "t", "y", "u", "i", "o", "p", "è", "+", 1, 0.6 ], [ "Caps", "a", "s", "d", "f", "g", "h", "j", "k", "l", "ò", "à", "ù", "Enter" ], [ "LShift", "<", "z", "x", "c", "v", "b", "n", "m", ",", ".", "-", "RShift" ], - [ "LCtrl", "Super", "LAlt", "Space", "AltGr", "Menu", "RCtrl" ] + [ "LCtrl", "Meta", "LAlt", "Space", "AltGr", "Menu", "RCtrl" ] ], @@ -434,7 +433,7 @@ "RShift" : 2.2, "LCtrl" : 1.6, - "Super" : 1.6, + "Meta" : 1.6, "LAlt" : 1.6, "Space" : 6.4, "AltGr" : 1.6, diff --git a/guacamole/src/main/frontend/src/layouts/nl-nl-qwerty.json b/guacamole/src/main/frontend/src/layouts/nl-nl-qwerty.json index 65f24cbd7..f1e874477 100644 --- a/guacamole/src/main/frontend/src/layouts/nl-nl-qwerty.json +++ b/guacamole/src/main/frontend/src/layouts/nl-nl-qwerty.json @@ -78,7 +78,6 @@ "Menu" : [{ "title" : "Menu", - "modifier" : "super", "keysym" : 65383 }], "LShift" : [{ @@ -116,10 +115,10 @@ "modifier" : "alt-gr", "keysym" : 65027 }], - "Super" : [{ - "title" : "Super", - "modifier" : "super", - "keysym" : 65515 + "Meta" : [{ + "title" : "Meta", + "modifier" : "meta", + "keysym" : 65511 }], "@" : [ @@ -419,7 +418,7 @@ [ "Tab", "q", "w", "e", "r", "t", "y", "u", "i", "o", "p", "¨", "*", 1, 0.6 ], [ "Caps", "a", "s", "d", "f", "g", "h", "j", "k", "l", "+", "´", "<", "Enter" ], [ "LShift", "]", "z", "x", "c", "v", "b", "n", "m", ",", ".", "-", "RShift" ], - [ "LCtrl", "Super", "LAlt", "Space", "AltGr", "Menu", "RCtrl" ] + [ "LCtrl", "Meta", "LAlt", "Space", "AltGr", "Menu", "RCtrl" ] ], @@ -446,7 +445,7 @@ "RShift" : 2.2, "LCtrl" : 1.6, - "Super" : 1.6, + "Meta" : 1.6, "LAlt" : 1.6, "Space" : 6.4, "AltGr" : 1.6, diff --git a/guacamole/src/main/frontend/src/layouts/ru-ru-qwerty.json b/guacamole/src/main/frontend/src/layouts/ru-ru-qwerty.json index 189dc1672..63fa1cfa4 100644 --- a/guacamole/src/main/frontend/src/layouts/ru-ru-qwerty.json +++ b/guacamole/src/main/frontend/src/layouts/ru-ru-qwerty.json @@ -87,10 +87,10 @@ "modifier" : "alt", "keysym" : 65514 }], - "Super" : [{ - "title" : "Super", - "modifier" : "super", - "keysym" : 65515 + "Meta" : [{ + "title" : "Meta", + "modifier" : "meta", + "keysym" : 65511 }], "Latin" : [{ "title" : "Latin", @@ -499,7 +499,7 @@ [ "Tab", "й", "ц", "у", "к", "е", "н", "г", "ш", "щ", "з", "х", "ъ", "\\" ], [ "Caps", "ф", "ы", "в", "а", "п", "р", "о", "л", "д", "ж", "э", "Enter" ], [ "LShift", "я", "ч", "с", "м", "и", "т", "ь", "б", "ю", "/", "RShift" ], - [ "LCtrl", "Super", "LAlt", "Space", "RAlt", "Menu", "RCtrl" ] + [ "LCtrl", "Meta", "LAlt", "Space", "RAlt", "Menu", "RCtrl" ] ], @@ -526,7 +526,7 @@ "RShift" : 3.1, "LCtrl" : 1.6, - "Super" : 1.6, + "Meta" : 1.6, "LAlt" : 1.6, "Space" : 6.1, "RAlt" : 1.6, From 01a5f6cdb9789d18f461979b1872d588265b0d44 Mon Sep 17 00:00:00 2001 From: Michael Jumper Date: Mon, 26 Jul 2021 20:26:04 -0700 Subject: [PATCH 2/3] GUACAMOLE-1386: Correct keyboard definition of "Windows" key as "Meta", not "Super". --- .../src/main/webapp/modules/Keyboard.js | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/guacamole-common-js/src/main/webapp/modules/Keyboard.js b/guacamole-common-js/src/main/webapp/modules/Keyboard.js index c6b40eb7b..2c70a4b40 100644 --- a/guacamole-common-js/src/main/webapp/modules/Keyboard.js +++ b/guacamole-common-js/src/main/webapp/modules/Keyboard.js @@ -437,8 +437,8 @@ Guacamole.Keyboard = function Keyboard(element) { 40: [0xFF54, 0xFF54, 0xFF54, 0xFFB2], // down arrow / KP 2 45: [0xFF63, 0xFF63, 0xFF63, 0xFFB0], // insert / KP 0 46: [0xFFFF, 0xFFFF, 0xFFFF, 0xFFAE], // delete / KP decimal - 91: [0xFFEB], // left window key (hyper_l) - 92: [0xFF67], // right window key (menu key?) + 91: [0xFFE7], // left windows/command key (meta_l) + 92: [0xFFE8], // right window/command key (meta_r) 93: null, // select key 96: [0xFFB0], // KP 0 97: [0xFFB1], // KP 1 @@ -583,7 +583,7 @@ Guacamole.Keyboard = function Keyboard(element) { "UIKeyInputUpArrow": [0xFF52], "Up": [0xFF52], "Undo": [0xFF65], - "Win": [0xFFEB], + "Win": [0xFFE7, 0xFFE7, 0xFFE8], "Zenkaku": [0xFF28], "ZenkakuHankaku": [0xFF2A] }; @@ -603,8 +603,8 @@ Guacamole.Keyboard = function Keyboard(element) { 0xFFE8: true, // Right meta 0xFFE9: true, // Left alt 0xFFEA: true, // Right alt - 0xFFEB: true, // Left hyper - 0xFFEC: true // Right hyper + 0xFFEB: true, // Left super/hyper + 0xFFEC: true // Right super/hyper }; /** @@ -1031,8 +1031,8 @@ Guacamole.Keyboard = function Keyboard(element) { // Resync state of hyper updateModifierState(guac_keyboard.modifiers.hyper, state.hyper, [ - 0xFFEB, // Left hyper - 0xFFEC // Right hyper + 0xFFEB, // Left super/hyper + 0xFFEC // Right super/hyper ], keyEvent); // Update state From 5c9483a810813c3d8b8002bfb06f173044f0e074 Mon Sep 17 00:00:00 2001 From: Michael Jumper Date: Mon, 26 Jul 2021 20:26:39 -0700 Subject: [PATCH 3/3] GUACAMOLE-1386: Correct/add "Menu" key definition, which is also not "Super". --- guacamole-common-js/src/main/webapp/modules/Keyboard.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/guacamole-common-js/src/main/webapp/modules/Keyboard.js b/guacamole-common-js/src/main/webapp/modules/Keyboard.js index 2c70a4b40..8f7dfe4f5 100644 --- a/guacamole-common-js/src/main/webapp/modules/Keyboard.js +++ b/guacamole-common-js/src/main/webapp/modules/Keyboard.js @@ -439,7 +439,7 @@ Guacamole.Keyboard = function Keyboard(element) { 46: [0xFFFF, 0xFFFF, 0xFFFF, 0xFFAE], // delete / KP decimal 91: [0xFFE7], // left windows/command key (meta_l) 92: [0xFFE8], // right window/command key (meta_r) - 93: null, // select key + 93: [0xFF67], // menu key 96: [0xFFB0], // KP 0 97: [0xFFB1], // KP 1 98: [0xFFB2], // KP 2