don't fire when alt or ctrl held
This commit is contained in:
parent
475985b9f4
commit
272b7b856c
@ -371,6 +371,7 @@ keyAct = (e) ->
|
|||||||
# [0-9;=A-Z]
|
# [0-9;=A-Z]
|
||||||
unless 48 <= kc <= 90
|
unless 48 <= kc <= 90
|
||||||
return
|
return
|
||||||
|
if e.ctrlKey or e.altKey then return
|
||||||
e.preventDefault()
|
e.preventDefault()
|
||||||
char = String.fromCharCode kc
|
char = String.fromCharCode kc
|
||||||
hash = location.hash
|
hash = location.hash
|
||||||
|
|||||||
@ -457,6 +457,9 @@
|
|||||||
if (!((48 <= kc) && (kc <= 90))) {
|
if (!((48 <= kc) && (kc <= 90))) {
|
||||||
return null;
|
return null;
|
||||||
}
|
}
|
||||||
|
if (e.ctrlKey || e.altKey) {
|
||||||
|
return null;
|
||||||
|
}
|
||||||
e.preventDefault();
|
e.preventDefault();
|
||||||
char = String.fromCharCode(kc);
|
char = String.fromCharCode(kc);
|
||||||
hash = location.hash;
|
hash = location.hash;
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user