Skip to content

Commit a57cee8

Browse files
committed
numpad support
1 parent 0a883f3 commit a57cee8

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

js/jquery.knob.js

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -468,6 +468,12 @@ $(function () {
468468
"keydown"
469469
,function (e) {
470470
var kc = e.keyCode;
471+
472+
// numpad support
473+
if(kc >= 96 && kc <= 105) {
474+
kc = e.keyCode = kc - 48;
475+
}
476+
471477
kval = parseInt(String.fromCharCode(kc));
472478

473479
if (isNaN(kval)) {

0 commit comments

Comments
 (0)