Changed event type, fixed fallback option fixes issue #1980 (#1981)

* UI: Changed event type, fixed fallback option
This commit is contained in:
Marcello Urbani 2018-09-30 08:04:19 +01:00 committed by Christian Günter
parent 44327bf5a1
commit f002715b47

View File

@ -932,7 +932,7 @@ Hotkeys.prototype.onkeydown = function(oEvent){
}
var
sKey = oEvent.key || oEvent.keyCode,
sKey = oEvent.key || String.fromCharCode(oEvent.keyCode),
fnHotkey = this.oKeyMap[sKey];
if (fnHotkey) {
@ -944,7 +944,7 @@ function setKeyBindings(oKeyMap){
var oHotkeys = new Hotkeys(oKeyMap);
document.addEventListener('keydown', oHotkeys.onkeydown.bind(oHotkeys));
document.addEventListener('keypress', oHotkeys.onkeydown.bind(oHotkeys));
}