X-Git-Url: https://git.mdrn.pl/wolnelektury.git/blobdiff_plain/362ea2e7f8ac4254398791139cc060090199f400..9e020f2a463e49b2aa799d3d3305f82dd01bece1:/wolnelektury/static/js/jquery.eventdelegation.js?ds=inline diff --git a/wolnelektury/static/js/jquery.eventdelegation.js b/wolnelektury/static/js/jquery.eventdelegation.js index 5ecba6e3b..52fce074a 100644 --- a/wolnelektury/static/js/jquery.eventdelegation.js +++ b/wolnelektury/static/js/jquery.eventdelegation.js @@ -1,4 +1,4 @@ -/* +/* * jQuery Event Delegation Plugin - jquery.eventdelegation.js * Fast flexible event handling * @@ -21,10 +21,10 @@ 'keydown', 'keypress', 'keyup' - ], function(i, eventName) { + ], function(i, eventName) { allowed[eventName] = true; }); - + $.fn.extend({ delegate: function (event, selector, f) { return $(this).each(function () { @@ -32,7 +32,7 @@ $(this).bind(event, function (e) { var el = $(e.target), result = false; - + while (!$(el).is('body')) { if ($(el).is(selector)) { result = f.apply($(el)[0], [e]); @@ -40,7 +40,7 @@ e.preventDefault(); return; } - + el = $(el).parent(); } });