Add alt condition back in, rename to specify igorance of shift
because this is really what this function is for - we want to ignore specifically shift but not necessarily alt (despite this probably not having any real impact).
This commit is contained in:
parent
d495519986
commit
d5e2a73d99
1 changed files with 3 additions and 3 deletions
|
@ -69,11 +69,11 @@ export function isOnlyCtrlOrCmdKeyEvent(ev) {
|
|||
}
|
||||
}
|
||||
|
||||
export function isCtrlOrCmdKeyEvent(ev) {
|
||||
export function isOnlyCtrlOrCmdIgnoreShiftKeyEvent(ev) {
|
||||
const isMac = navigator.platform.toUpperCase().indexOf('MAC') >= 0;
|
||||
if (isMac) {
|
||||
return ev.metaKey && !ev.ctrlKey;
|
||||
return ev.metaKey && !ev.altKey && !ev.ctrlKey;
|
||||
} else {
|
||||
return ev.ctrlKey && !ev.metaKey;
|
||||
return ev.ctrlKey && !ev.altKey && !ev.metaKey;
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue