Wrap core functionality in an each function

If we have many DOM elements that match the PerfectScrollbar selector,
then all elemets get scrolled if one of them is scrolled.
This commit is contained in:
Ahmad Sherif 2013-05-22 11:48:51 +02:00
parent c6c087275c
commit d5dd3422cf
3 changed files with 288 additions and 286 deletions

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View File

@ -11,6 +11,7 @@
$.fn.perfectScrollbar = function (suppliedSettings, option) {
return this.each(function() {
// Use the default settings
var settings = $.extend(true, {}, defaultSettings);
if (typeof suppliedSettings === "object") {
@ -320,5 +321,6 @@
initialize();
return $this;
});
};
})(jQuery));