Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
Fix for issue with Chrome 56 preventDefault inside passive event listener
  • Loading branch information
Tolc committed Apr 11, 2019
1 parent 347d35e commit 6876279
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion jquery.nicescroll.js
Original file line number Diff line number Diff line change
Expand Up @@ -2552,7 +2552,7 @@
q: false
});

(passiveSupported && active) ? el.addEventListener(name, fn, { passive: false, capture: bubble }) : el.addEventListener(name, fn, bubble || false);
(passiveSupported && (active || el == window.document || el == window.document.body || el == window)) ? el.addEventListener(name, fn, { passive: false, capture: bubble }) : el.addEventListener(name, fn, bubble || false);
};

this._unbind = function (el, name, fn, bub) { // primitive unbind
Expand Down

0 comments on commit 6876279

Please sign in to comment.