Skip to content

Commit 944165b

Browse files
committed
updating to new keymasher version
Keymasher had mixed up preventDefault and stopPropagation
1 parent dfae9cd commit 944165b

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

spec/lib/jquery.keymasher.js

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
/*
22
Key Masher plugin for jQuery (https://github.com/digitalBush/jquery.keymasher)
3-
Copyright (c) 2010 Josh Bush (digitalbush.com)
3+
Copyright (c) 2010-2013 Josh Bush (digitalbush.com)
44
Licensed under the MIT license
5-
Version: 0.1
5+
Version: 0.2
66
*/
77

88
(function($,undefined){
@@ -51,9 +51,9 @@
5151
up = $.extend($.Event('keyup'), modifierState, {keyCode: key.keyCode, charCode: 0, which:key.keyCode});
5252

5353
elm.trigger(down);
54-
if(!down.isPropagationStopped() && !ignore){
54+
if(!down.isDefaultPrevented() && !ignore){
5555
elm.trigger(press);
56-
if(!press.isPropagationStopped()){
56+
if(!press.isDefaultPrevented()){
5757
//need to do caret positioning
5858
elm.val(elm.val()+String.fromCharCode(key.charCode));
5959
}

0 commit comments

Comments
 (0)