File tree Expand file tree Collapse file tree 1 file changed +3
-4
lines changed
Expand file tree Collapse file tree 1 file changed +3
-4
lines changed Original file line number Diff line number Diff line change 254254 var keyCode = el . data ( 'mask-keycode' ) ;
255255
256256 if ( $ . inArray ( keyCode , jMask . byPassKeys ) === - 1 ) {
257- var newVal = p . getMasked ( ) ,
258- caretPos = p . getCaret ( ) ;
257+ var newVal = p . getMasked ( ) ;
259258
260259 // this is a compensation to devices/browsers that don't compensate
261260 // caret positioning the right way
262261 setTimeout ( function ( ) {
263262 p . setCaret ( p . calculateCaretPosition ( ) ) ;
264- } , 10 ) ;
263+ } , $ . jMaskGlobals . keyStrokeCompensation ) ;
265264
266265 p . val ( newVal ) ;
267- p . setCaret ( caretPos ) ;
268266 return p . callbacks ( e ) ;
269267 }
270268 } ,
568566 dataMask : true ,
569567 watchInterval : 300 ,
570568 watchInputs : true ,
569+ keyStrokeCompensation : 10 ,
571570 // old versions of chrome dont work great with input event
572571 useInput : ! / C h r o m e \/ [ 2 - 4 ] [ 0 - 9 ] | S a m s u n g B r o w s e r / . test ( window . navigator . userAgent ) && eventSupported ( 'input' ) ,
573572 watchDataMask : false ,
You can’t perform that action at this time.
0 commit comments