Fix _+: keys in Firefox

19466b5 fixes the keys without shift; this fixes them with shift.

Related: 19466b5625
Context: https://github.com/nurdism/neko/issues/51#issuecomment-609877197
This commit is contained in:
Ellen Marie Dash 2020-04-06 13:09:32 -04:00 committed by GitHub
parent 82ca6e13ca
commit 080766481c
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -466,15 +466,15 @@
// frick you firefox // frick you firefox
getCode(e: KeyboardEvent): number { getCode(e: KeyboardEvent): number {
let key = e.keyCode let key = e.keyCode
if (key === 59 && e.key === ';') { if (key === 59 && (e.key === ';' || e.key === ':')) {
key = 186 key = 186
} }
if (key === 61 && e.key === '=') { if (key === 61 && (e.key === '=' || e.key === '+')) {
key = 187 key = 187
} }
if (key === 173 && e.key === '-') { if (key === 173 && (e.key === '-' || e.key === '_')) {
key = 189 key = 189
} }