Detect arrow keys on Windows Edge
This commit is contained in:
1 parent
64869e5a87
commit
fbeaec600c
1 file changed
+6
-2
+6
-2
@@ -44,9 +44,13 @@ class Keyboard {
|
||||
// Convert space and arrow keys to their Scratch key names.
|
||||
switch (keyString) {
|
||||
case ' ': return 'space';
|
||||
case 'ArrowLeft': return 'left arrow';
|
||||
case 'ArrowUp': return 'up arrow';
|
||||
case 'ArrowLeft':
|
||||
case 'Left': return 'left arrow';
|
||||
case 'ArrowUp':
|
||||
case 'Up': return 'up arrow';
|
||||
case 'Right':
|
||||
case 'ArrowRight': return 'right arrow';
|
||||
case 'Down':
|
||||
case 'ArrowDown': return 'down arrow';
|
||||
}
|
||||
// Ignore modifier keys
|
||||
|
||||
Reference in new issue
Block a user