Permalink
Browse files

Unbinding of keydown after an error in the server reponse

  • Loading branch information...
1 parent cab6109 commit fd12fec8c8269976c15b2a35e3dbcee0a4b55085 @tonytomov committed Jul 8, 2011
Showing with 2 additions and 1 deletion.
  1. +2 −1 js/grid.inlinedit.js
View
3 js/grid.inlinedit.js
@@ -215,6 +215,7 @@ $.jgrid.extend({
if(fr >= 0) { $t.p.savedRow.splice(fr,1); }
if( $.isFunction(o.aftersavefunc) ) { o.aftersavefunc.call($t, rowid,resp); }
success = true;
+ $(ind).unbind("keydown");
} else {
$("#lui_"+$t.p.id).show();
tmp3 = $.extend({},tmp,tmp3);
@@ -244,6 +245,7 @@ $.jgrid.extend({
if(fr >= 0) { $t.p.savedRow.splice(fr,1); }
if( $.isFunction(o.aftersavefunc) ) { o.aftersavefunc.call($t, rowid,res); }
success = true;
+ $(ind).unbind("keydown");
} else {
if($.isFunction(o.errorfunc) ) {
o.errorfunc.call($t, rowid, res, stat);
@@ -272,7 +274,6 @@ $.jgrid.extend({
}
}, $.jgrid.ajaxOptions, $t.p.ajaxRowOptions || {}));
}
- $(ind).unbind("keydown");
}
return success;
},

0 comments on commit fd12fec

Please sign in to comment.