Fixed numpad 0-9 keys

See
https://github.com/zhukov/webogram/commit/68496f8f621923e7a002d0de83d89a
b78f93ddf7#commitcomment-6541254
This commit is contained in:
Igor Zhukov 2014-06-04 13:01:01 +04:00
parent 158fd5b708
commit a32e8036f5

View File

@ -63,6 +63,13 @@ angular.module('myApp.directives', ['myApp.filters'])
}
return cancelEvent(e);
}
if (e.keyCode >= 96 && e.keyCode <= 105 && !e.shiftKey && e.altKey) { // Alt + [0-9 numpad keys]
var currentSelected = $(scrollableWrap).find('.im_dialog_wrap a')[(e.keyCode - 96 || 10) - 1];
if (currentSelected) {
currentSelected.click();
}
return cancelEvent(e);
}
if (e.keyCode == 27 || e.keyCode == 9 && e.shiftKey) { // ESC or Shift + Tab
if (!searchFocused) {