Fix a regression introduced by #1058

Such regression broke the character composition/paste on macOS
This commit is contained in:
Matheus Fernandes 2016-12-02 11:22:25 -02:00
parent e31f975f78
commit 6508d05e5f
No known key found for this signature in database
GPG key ID: DD07CA4EA7B65C4F
2 changed files with 1 additions and 3 deletions

View file

@ -102,7 +102,6 @@ for (const key in allAccelerators) {
// decides if a keybard event is a Hyper Accelerator // decides if a keybard event is a Hyper Accelerator
function isAccelerator(e) { function isAccelerator(e) {
let keys = []; let keys = [];
console.log(e);
if (!e.ctrlKey && !e.metaKey && !e.altKey) { if (!e.ctrlKey && !e.metaKey && !e.altKey) {
// all accelerators needs Ctrl or Cmd or Alt // all accelerators needs Ctrl or Cmd or Alt
return false; return false;
@ -130,7 +129,6 @@ function isAccelerator(e) {
} }
keys = keys.join('+'); keys = keys.join('+');
return cache.includes(keys); return cache.includes(keys);
} }

View file

@ -166,7 +166,7 @@ hterm.Keyboard.prototype.onKeyDown_ = function (e) {
e.preventDefault(); e.preventDefault();
} }
if (isAccelerator(e)) { if (e.altKey || e.metaKey || isAccelerator(e)) {
// hterm shouldn't consume a hyper accelerator // hterm shouldn't consume a hyper accelerator
return; return;
} }