custom scroll bar

JavaScript performance comparison

Test case created by Ken

Preparation code

<script src="https://ajax.googleapis.com/ajax/libs/jquery/1/jquery.min.js">
</script>
<script src="http://ajax.googleapis.com/ajax/libs/jqueryui/1.8/jquery-ui.min.js"></script>
<a href="http://manos.malihu.gr/jquery-custom-content-scroller" class="postURL"></a>
<div class="info">
  <span class="blue">
    malihu
  </span>
  <br />
  <span class="big">
    Custom Scrollbar
  </span>
  plugin
</div>
<!-- content block -->
<div id="mcs_container">
  <div class="customScrollBox">
    <div class="container">
      <div class="content">
        <h1>
          Adjustable scroller height with easing
        </h1>
        <p>
          <a href="#" onclick="LoadNewContent('mcs_container','dynamic_content.html');return false">Load new content dynamically</a>
        </p>
        <p style="color:#C96;">
          Aliquam erat volutpat. Maecenas non tortor nulla, non malesuada velit. Nullam felis
          tellus, tristique nec egestas in, luctus sed diam. Suspendisse potenti.
        </p>
        <p class="alt">
          <em>
            consectetur adipiscing elit. Nulla consectetur libero consectetur quam consequat
            nec tincidunt massa feugiat. Donec egestas mi turpis. Fusce adipiscing dui eu metus
            gravida vel facilisis ligula iaculis. Cras a rhoncus massa. Donec sed purus eget
            nunc placerat consequat.
          </em>
        </p>
        <img src="mcsImg1.jpg" />
        <p>
          Aliquam erat volutpat. Maecenas non tortor nulla, non malesuada velit. Nullam felis
          tellus, tristique nec egestas in, luctus sed diam. Suspendisse potenti. Cras venenatis
          condimentum nibh a mollis. Duis id sapien nibh. Vivamus porttitor, felis quis blandit
          tincidunt, erat magna scelerisque urna, a faucibus erat nisl eget nisl. Aliquam consequat
          turpis id velit egestas a posuere orci semper. Mauris suscipit erat quis urna adipiscing
          ultricies. In hac habitasse platea dictumst. Nulla scelerisque lorem quis dui sagittis
          egestas.
        </p>
        <p class="alt">
          Etiam sed massa felis, aliquam pellentesque est. Quisque quis ante tortor, sed egestas
          risus. Maecenas varius adipiscing nulla, nec rhoncus est mattis id. Aenean blandit
          convallis nisi at fringilla. Nunc id massa eu sapien fringilla posuere.
        </p>
        <img src="mcsImg2.jpg" />
        <p style="color:#C96;">
          Nam eu arcu at purus tincidunt pharetra ultrices at ipsum. Mauris urna nunc, vulputate
          quis gravida in, pharetra id mauris. Ut sit amet mi dictum nulla lobortis adipiscing
          quis a nulla. Etiam diam ante, imperdiet vel scelerisque eget, venenatis non eros.
          Praesent ipsum sem, eleifend ut gravida eget, tristique id orci. Nam adipiscing,
          sem in mattis vulputate, risus libero adipiscing risus, eu molestie mi justo eget
          nulla.
        </p>
        <p>
          Cras venenatis metus et urna egestas non laoreet orci rutrum. Pellentesque ullamcorper
          dictum nisl a tincidunt. Quisque et lacus quam, sed hendrerit mi. Mauris pretium,
          sapien et malesuada pulvinar, lorem leo viverra leo, et egestas mi nisl quis odio.
        </p>
        <p>
          Aliquam erat volutpat. Sed urna arcu, tempus eu vulputate adipiscing, consectetur
          et orci. Vivamus congue, nunc vitae fringilla convallis, libero massa lacinia lorem,
          id convallis mauris elit ut leo. Nulla vel odio sem. Duis lorem urna, congue vitae
          rutrum sed, tincidunt vel tortor. In hac habitasse platea dictumst. Nunc vitae enim
          ante, vitae facilisis massa. Etiam sagittis sapien at nibh fermentum consectetur
          convallis lacus blandit.
        </p>
        <h1>
          the end.
        </h1>
      </div>
    </div>
    <div class="dragger_container">
      <div class="dragger">
      </div>
    </div>
  </div>
  <a href="#" class="scrollUpBtn"></a>
  <a href="#" class="scrollDownBtn"></a>
</div>
<!-- content block -->
<div id="mcs2_container">
  <div class="customScrollBox">
    <div class="container">
      <div class="content">
        <h1>
          Adjustable scroller height without easing
        </h1>
        <p>
          <a href="#" onclick="LoadNewContent('mcs2_container','dynamic_content.html');return false">Load new content dynamically</a>
        </p>
        <p class="alt">
          Aliquam erat volutpat. Maecenas non tortor nulla, non malesuada velit. Nullam felis
          tellus, tristique nec egestas in, luctus sed diam.
        </p>
        <p>
          <em>
            consectetur adipiscing elit. Nulla consectetur libero consectetur quam consequat
            nec tincidunt massa feugiat. Fusce adipiscing dui eu metus gravida vel facilisis
            ligula iaculis.
          </em>
        </p>
        <img src="mcsImg2.jpg" />
        <p>
          In hac habitasse platea dictumst. Aliquam erat volutpat. Maecenas non tortor nulla,
          non malesuada velit. Nullam felis tellus, tristique nec egestas in, luctus sed diam.
          Suspendisse potenti. Cras venenatis condimentum nibh a mollis. Duis id sapien nibh.
          Vivamus porttitor, felis quis blandit tincidunt, erat magna scelerisque urna, a faucibus
          erat nisl eget nisl. Aliquam consequat turpis id velit egestas a posuere orci semper.
        </p>
        <h1>
          the end.
        </h1>
      </div>
    </div>
    <div class="dragger_container">
      <div class="dragger">
        &#9618;
      </div>
    </div>
  </div>
</div>
<!-- content block -->
<div id="mcs3_container">
  <div class="customScrollBox">
    <div class="container">
      <div class="content">
        <h3>
          Adjustable scroller height with 1/3 range and greater easing, without mouse-wheel
          support
        </h3>
        <p>
          Aliquam erat volutpat. Maecenas non tortor nulla, non malesuada velit. Nullam felis
          tellus, tristique nec egestas in, luctus sed diam. Suspendisse potenti.
        </p>
        <p>
          consectetur adipiscing elit. Nulla consectetur libero consectetur quam consequat
          nec tincidunt massa feugiat. Donec egestas mi turpis. Fusce adipiscing dui eu metus
          gravida vel facilisis ligula iaculis. Cras a rhoncus massa. Donec sed purus eget
          nunc placerat consequat. Nulla facilisi. Nam vel augue odio, dignissim mattis dolor.
          Nullam at mi aliquet quam interdum consectetur. Duis tempus mauris in lorem dictum
          eget euismod urna aliquet. In vestibulum tempor porta.
        </p>
        <p>
          Morbi porttitor rhoncus nisi, eget vehicula quam sodales at. Maecenas ipsum tellus,
          mollis quis faucibus id, feugiat molestie lacus. Sed nec quam purus, at condimentum
          quam. Integer imperdiet faucibus urna tempus consectetur. Nullam non purus ligula,
          et tincidunt nulla. Aenean tincidunt, dui at elementum egestas, sem turpis volutpat
          turpis, nec congue purus quam quis ligula. Nam dictum rutrum pulvinar. Aenean sed
          cursus purus. Curabitur non dui eu nibh fermentum interdum a id dui. Fusce iaculis
          blandit tellus, nec tincidunt massa adipiscing id. Aliquam dui massa, porttitor eget
          molestie at, semper eu libero. Suspendisse sit amet velit et elit viverra convallis
          vitae ut turpis. Maecenas vehicula blandit odio sollicitudin eleifend. Curabitur
          molestie porta neque ac imperdiet. Phasellus nec nisl non lectus pharetra porttitor
          sit amet tristique mi. Integer vehicula vestibulum sem vitae varius. Ut scelerisque
          semper posuere.
        </p>
        <img src="mcsImg1.jpg" />
        <p>
          Aliquam erat volutpat. Maecenas non tortor nulla, non malesuada velit. Nullam felis
          tellus, tristique nec egestas in, luctus sed diam. Suspendisse potenti. Cras venenatis
          condimentum nibh a mollis. Duis id sapien nibh. Vivamus porttitor, felis quis blandit
          tincidunt, erat magna scelerisque urna, a faucibus erat nisl eget nisl. Aliquam consequat
          turpis id velit egestas a posuere orci semper. Mauris suscipit erat quis urna adipiscing
          ultricies. In hac habitasse platea dictumst. Nulla scelerisque lorem quis dui sagittis
          egestas. Etiam sed massa felis, aliquam pellentesque est. Quisque quis ante tortor,
          sed egestas risus. Maecenas varius adipiscing nulla, nec rhoncus est mattis id. Aenean
          blandit convallis nisi at fringilla. Nunc id massa eu sapien fringilla posuere.
        </p>
        <img src="mcsImg2.jpg" />
        <p>
          Nam eu arcu at purus tincidunt pharetra ultrices at ipsum. Mauris urna nunc, vulputate
          quis gravida in, pharetra id mauris. Ut sit amet mi dictum nulla lobortis adipiscing
          quis a nulla. Etiam diam ante, imperdiet vel scelerisque eget, venenatis non eros.
          Praesent ipsum sem, eleifend ut gravida eget, tristique id orci. Nam adipiscing,
          sem in mattis vulputate, risus libero adipiscing risus, eu molestie mi justo eget
          nulla. Cras venenatis metus et urna egestas non laoreet orci rutrum. Pellentesque
          ullamcorper dictum nisl a tincidunt. Quisque et lacus quam, sed hendrerit mi. Mauris
          pretium, sapien et malesuada pulvinar, lorem leo viverra leo, et egestas mi nisl
          quis odio. Aliquam erat volutpat. Sed urna arcu, tempus eu vulputate adipiscing,
          consectetur et orci. Vivamus congue, nunc vitae fringilla convallis, libero massa
          lacinia lorem, id convallis mauris elit ut leo. Nulla vel odio sem. Duis lorem urna,
          congue vitae rutrum sed, tincidunt vel tortor. In hac habitasse platea dictumst.
          Nunc vitae enim ante, vitae facilisis massa. Etiam sagittis sapien at nibh fermentum
          consectetur convallis lacus blandit.
        </p>
        <img src="mcsImg1.jpg" />
        <p>
          Aliquam erat volutpat. Maecenas non tortor nulla, non malesuada velit. Nullam felis
          tellus, tristique nec egestas in, luctus sed diam. Suspendisse potenti. Cras venenatis
          condimentum nibh a mollis. Duis id sapien nibh. Vivamus porttitor, felis quis blandit
          tincidunt, erat magna scelerisque urna, a faucibus erat nisl eget nisl. Aliquam consequat
          turpis id velit egestas a posuere orci semper. Mauris suscipit erat quis urna adipiscing
          ultricies. In hac habitasse platea dictumst. Nulla scelerisque lorem quis dui sagittis
          egestas. Etiam sed massa felis, aliquam pellentesque est. Quisque quis ante tortor,
          sed egestas risus. Maecenas varius adipiscing nulla, nec rhoncus est mattis id. Aenean
          blandit convallis nisi at fringilla. Nunc id massa eu sapien fringilla posuere.
        </p>
        <img src="mcsImg2.jpg" />
        <p>
          Nam eu arcu at purus tincidunt pharetra ultrices at ipsum. Mauris urna nunc, vulputate
          quis gravida in, pharetra id mauris. Ut sit amet mi dictum nulla lobortis adipiscing
          quis a nulla. Etiam diam ante, imperdiet vel scelerisque eget, venenatis non eros.
          Praesent ipsum sem, eleifend ut gravida eget, tristique id orci. Nam adipiscing,
          sem in mattis vulputate, risus libero adipiscing risus, eu molestie mi justo eget
          nulla. Cras venenatis metus et urna egestas non laoreet orci rutrum. Pellentesque
          ullamcorper dictum nisl a tincidunt. Quisque et lacus quam, sed hendrerit mi. Mauris
          pretium, sapien et malesuada pulvinar, lorem leo viverra leo, et egestas mi nisl
          quis odio. Aliquam erat volutpat. Sed urna arcu, tempus eu vulputate adipiscing,
          consectetur et orci. Vivamus congue, nunc vitae fringilla convallis, libero massa
          lacinia lorem, id convallis mauris elit ut leo. Nulla vel odio sem. Duis lorem urna,
          congue vitae rutrum sed, tincidunt vel tortor. In hac habitasse platea dictumst.
          Nunc vitae enim ante, vitae facilisis massa. Etiam sagittis sapien at nibh fermentum
          consectetur convallis lacus blandit.
        </p>
        <p>
          the end.
        </p>
      </div>
    </div>
    <div class="dragger_container">
      <div class="dragger">
      </div>
    </div>
  </div>
</div>
<!-- content block -->
<div id="mcs4_container">
  <div class="customScrollBox">
    <div class="container">
      <div class="content">
        <h2>
          Non-adjustable scroller height with minor easing
        </h2>
        <p>
          Lorem ipsum dolor sit amet. Aliquam erat volutpat. Maecenas non tortor nulla, non
          malesuada velit. Nullam felis tellus, tristique nec egestas in, luctus sed diam.
          Suspendisse potenti.
        </p>
        <p>
          consectetur adipiscing elit. Nulla consectetur libero consectetur quam consequat
          nec tincidunt massa feugiat. Donec egestas mi turpis. Fusce adipiscing dui eu metus
          gravida vel facilisis ligula iaculis. Cras a rhoncus massa. Donec sed purus eget
          nunc placerat consequat. Nulla facilisi. Nam vel augue odio, dignissim mattis dolor.
          Nullam at mi aliquet quam interdum consectetur. Duis tempus mauris in lorem dictum
          eget euismod urna aliquet. In vestibulum tempor porta.
        </p>
        <p>
          Aliquam erat volutpat. Maecenas non tortor nulla, non malesuada velit. Nullam felis
          tellus, tristique nec egestas in, luctus sed diam. Suspendisse potenti. Cras venenatis
          condimentum nibh a mollis. Duis id sapien nibh. Vivamus porttitor, felis quis blandit
          tincidunt, erat magna scelerisque urna, a faucibus erat nisl eget nisl. Aliquam consequat
          turpis id velit egestas a posuere orci semper. Mauris suscipit erat quis urna adipiscing
          ultricies. In hac habitasse platea dictumst. Nulla scelerisque lorem quis dui sagittis
          egestas. Etiam sed massa felis, aliquam pellentesque est. Quisque quis ante tortor,
          sed egestas risus. Maecenas varius adipiscing nulla, nec rhoncus est mattis id. Aenean
          blandit convallis nisi at fringilla. Nunc id massa eu sapien fringilla posuere.
        </p>
        <h2>
          the end.
        </h2>
      </div>
    </div>
    <div class="dragger_container">
      <div class="dragger">
      </div>
    </div>
  </div>
</div>
<!-- content block -->
<div id="mcs5_container">
  <div class="customScrollBox">
    <!-- horWrapper div is important for horizontal scrollers! -->
    <div class="horWrapper">
      <div class="container">
        <div class="content">
          <h4>
            Horizontal non-adjustable image scroller with easing
          </h4>
          <p>
            <img src="mcsThumb1.jpg" />
            <img src="mcsThumb2.jpg" />
            <img src="mcsThumb3.jpg" />
            <img src="mcsThumb4.jpg" />
            <img src="mcsThumb5.jpg" />
            <img src="mcsThumb6.jpg" />
            <img src="mcsThumb7.jpg" />
            <img src="mcsThumb8.jpg" />
            <img src="mcsThumb1.jpg" />
            <img src="mcsThumb2.jpg" />
            <img src="mcsThumb3.jpg" />
            <img src="mcsThumb4.jpg" />
          </p>
        </div>
      </div>
      <div class="dragger_container">
        <div class="dragger">
        </div>
      </div>
    </div>
  </div>
  <a href="#" class="scrollUpBtn">&#8678;</a>
  <a href="#" class="scrollDownBtn">&#8680;</a>
</div>
      
<script>
Benchmark.prototype.setup = function() {
  jQuery.easing['jswing'] = jQuery.easing['swing'];
  
  (function($) {
  	$.fn.hCustomScrollbar = function(options) {
  
  		var d = { // defaults
  			axis: 'y',
  			duration: 500,
  			easing: 'easeOutCirc',
  			bottom: 1,
  			draggerResize: true,
  			mousewheel: true,
  			scrollButtons: true,
  			scrollButtonsSpeed: 1
  		};
  		
  		$.extend(d, options);
  		
  		var self = $(this),
  			customScroll = self.find('.customScrollBox'),
  			scrollContainer = customScroll.find('.container'), 
  			scrollContent = scrollContainer.find('.content'),
  			draggerContainer = customScroll.find('.dragger_container'),
  			dragger = draggerContainer.find('.dragger'),
  			scrollUp = customScroll.find('.scrollUpBtn'),
  			scrollDown = customScroll.find('.scrollDownBtn'),
  			horizontalWrapper = customScroll.find('.horWrapper'),
  			size, distance, visibleSize, pageScroll, scrollAmount, totalContent, minDraggerSize, draggerContainerSize, targDistance, draggerSize;
  
  		if(d.axis === 'x') {
  			size = 'width';
  			distance = 'left';
  			pageScroll = 'pageX';
  
  			//set a rediculously high width value ;)
  			horizontalWrapper.css('width', 999999);
  			customScroll.data('totalContent', scrollContainerSize);
  			horizontalWrapper.css('width', scrollContainerSize);
  
  		} else {
  			size = 'height';
  			distance = 'top';
  			pageScroll = 'pageY';
  		}
  		
  		visibleSize = customScroll[size]();
  		scrollContainerSize = scrollContainer[size]()
  		minDraggerSize = dragger[size]()
  		contentSize = scrollContainer[size]()
  		totalContent = scrollContent[size]();
  		minDraggerSize = customScroll.data('minDraggerSize');
  		draggerContainerSize = draggerContainer[size]();
  		targDistance = 0;
  		draggerSize = dragger[size]();
  		scrollAmount = (totalContent - (visibleSize / d.bottom)) / (draggerContainerSize - draggerSize);
  
  		//get & store minimum dragger size (defined in css)
  		if(!customScroll.data('minDraggerSize')) {
  			customScroll.data('minDraggerSize', minDraggerSize);
  		}
  
  		//get & store original content size
  		if(!customScroll.data('contentSize')) {
  			customScroll.data('contentSize', contentSize);
  		}
  
  		customScroller();
  
  		function customScroller(reloadType) {
  
  			// rewriting
  			function adjustDraggerSize() {
  				if(d.draggerResize) {
  					var adjDraggerSize = Math.round(totalContent - ((totalContent - visibleSize) * 1.3));
  					//adjust dragger width analogous to content
  					if(adjDraggerSize <= minDraggerSize) {//minimum dragger width
  						dragger.css(size, minDraggerSize + 'px').css('line-height', minDraggerSize + 'px');
  					} else if(adjDraggerSize >= draggerContainerSize) {
  						dragger.css(size, draggerContainerSize - 10 + 'px').css('line-height', draggerContainerSize - 10 + 'px');
  					} else {
  						dragger.css(size, adjDraggerSize + 'px').css('line-height', adjDraggerSize + 'px');
  					}
  				}
  			}
  
  			function Btnsscroll(dir) {
  
  				var btnsScrollTo, scrollSpeed = Math.abs(dragger.position()[distance] - btnsScrollTo) * (100 / scrollBtnsSpeed), obj = {};
  
  				if(dir == 'down') {
  					btnsScrollTo = draggerContainerSize - draggerSize;
  					obj[distance] = btnsScrollTo;
  
  				} else {
  					btnsScrollTo = 0;
  					obj[distance] = btnsScrollTo;
  
  				}
  
  				dragger.stop().animate(obj, scrollSpeed, 'linear');
  				clearInterval(btnsScrollTimer);
  				btnsScrollTimer = setInterval(scroll, 20);
  
  			}
  
  			function BtnsScrollStop() {
  				clearInterval(btnsScrollTimer);
  				dragger.stop();
  			}
  
  			function scroll() {
  				var draggerPos = dragger.position()[distance], targPos = -draggerPos * scrollAmount, thePos = scrollContainer.position()[distance] - targPos, obj = {};
  
  				obj[distance] = '-=' + thePos;
  				scrollContainer.stop().animate(obj, d.duration, d.easing, function() {
  					self.trigger('scrolled');
  				});
  				self.trigger('scrolled');
  			}
  
  			function draggerPress() {
  				dragger.addClass('dragger_pressed');
  			}
  
  			function draggerRelease() {
  				dragger.removeClass('dragger_pressed');
  			}
  
  			if(scrollContainerSize > visibleSize) {
  
  				dragger.css('display', 'block');
  				if(reloadType != 'resize' && scrollContainerSize != customScroll.data('contentSize')) {
  					dragger.css(distance, 0);
  					scrollContainer.css(distance, 0);
  					customScroll.data('contentSize', scrollContainerSize);
  				}
  				draggerContainer.css('display', 'block');
  				scrollDown.css('display', 'inline-block');
  				scrollUp.css('display', 'inline-block');
  
  				adjustDraggerSize();
  
  				dragger.draggable({
  					// axis : d.axis,
  					axis : d.axis,
  					containment : 'parent',
  					drag : scroll,
  					stop : draggerRelease
  				});
  
  				draggerContainer.click(function(e) {
  					var self = $(this), mouseCoord = (e[pageScroll] - self.offset()[distance]), draggerDistance = dragger.position()[distance], targetPos;
  
  					if(mouseCoord < draggerDistance || mouseCoord > draggerDistance + draggerSize) {
  						targetPos = mouseCoord + draggerSize;
  
  						if(targetPos < draggerContainerSize) {
  							dragger.css(distance, mouseCoord);
  							scroll();
  						} else {
  							dragger.css(distance, draggerContainerSize - draggerSize);
  							scroll();
  						}
  					}
  				});
  				//mousewheel
  				$(function($) {
  					if(d.mousewheel) {
  						customScroll.unbind('mousewheel');
  						customScroll.bind('mousewheel', function(event, delta) {
  							var vel = Math.abs(delta * 10), draggerDistance = dragger.position()[distance];
  
  							dragger.css(distance, draggerDistance - (delta * vel));
  							scroll();
  
  							if(draggerDistance < 0) {
  								dragger.css(distance, 0);
  								scrollContainer.stop();
  								scroll();
  							}
  
  							if(draggerDistance > draggerContainerSize - draggerSize) {
  								dragger.css(distance, draggerContainerSize - draggerSize);
  								scrollContainer.stop();
  								scroll();
  							}
  
  							return false;
  						});
  					}
  				});
  				//scroll buttons
  				if(d.scrollButtons) {
  
  					scrollDown.bind({
  						mouseup : BtnsScrollStop,
  						mousedown : function() {
  							Btnsscroll('down');
  						},
  						mouseout : BtnsScrollStop,
  						click : function(e) {
  							e.preventDefault();
  						}
  					});
  
  					scrollUp.bind({
  						mouseup : BtnsScrollStop,
  						mousedown : function() {
  							Btnsscroll('up');
  						},
  						mouseout : BtnsScrollStop,
  						click : function(e) {
  							e.preventDefault();
  						}
  					});
  					btnsScrollTimer = 0;
  
  				}
  
  			} else {
  				dragger.css(distance, 0).css('display', 'none');
  				//reset content scroll
  				scrollContainer.css(distance, 0);
  				draggerContainer.css('display', 'none');
  				scrollDown.css('display', 'none');
  				scrollUp.css('display', 'none');
  
  			}
  
  			dragger.bind({
  				mouseup : draggerRelease,
  				mousedown : draggerPress
  			});
  
  		}
  
  
  		$(window).resize(function() {
  			if(dragger.position()[distance] > draggerContainerSize - draggerSize) {
  				dragger.css(distance, draggerContainerSize - draggerSize);
  			}
  			customScroller('resize');
  		});
  	};
  })(jQuery);
  
  
  jQuery.extend( jQuery.easing,
  {
  	def: 'easeOutQuad',
  	swing: function (x, t, b, c, d) {
  		//alert(jQuery.easing.default);
  		return jQuery.easing[jQuery.easing.def](x, t, b, c, d);
  	},
  	easeInQuad: function (x, t, b, c, d) {
  		return c*(t/=d)*t + b;
  	},
  	easeOutQuad: function (x, t, b, c, d) {
  		return -c *(t/=d)*(t-2) + b;
  	},
  	easeInOutQuad: function (x, t, b, c, d) {
  		if ((t/=d/2) < 1) return c/2*t*t + b;
  		return -c/2 * ((--t)*(t-2) - 1) + b;
  	},
  	easeInCubic: function (x, t, b, c, d) {
  		return c*(t/=d)*t*t + b;
  	},
  	easeOutCubic: function (x, t, b, c, d) {
  		return c*((t=t/d-1)*t*t + 1) + b;
  	},
  	easeInOutCubic: function (x, t, b, c, d) {
  		if ((t/=d/2) < 1) return c/2*t*t*t + b;
  		return c/2*((t-=2)*t*t + 2) + b;
  	},
  	easeInQuart: function (x, t, b, c, d) {
  		return c*(t/=d)*t*t*t + b;
  	},
  	easeOutQuart: function (x, t, b, c, d) {
  		return -c * ((t=t/d-1)*t*t*t - 1) + b;
  	},
  	easeInOutQuart: function (x, t, b, c, d) {
  		if ((t/=d/2) < 1) return c/2*t*t*t*t + b;
  		return -c/2 * ((t-=2)*t*t*t - 2) + b;
  	},
  	easeInQuint: function (x, t, b, c, d) {
  		return c*(t/=d)*t*t*t*t + b;
  	},
  	easeOutQuint: function (x, t, b, c, d) {
  		return c*((t=t/d-1)*t*t*t*t + 1) + b;
  	},
  	easeInOutQuint: function (x, t, b, c, d) {
  		if ((t/=d/2) < 1) return c/2*t*t*t*t*t + b;
  		return c/2*((t-=2)*t*t*t*t + 2) + b;
  	},
  	easeInSine: function (x, t, b, c, d) {
  		return -c * Math.cos(t/d * (Math.PI/2)) + c + b;
  	},
  	easeOutSine: function (x, t, b, c, d) {
  		return c * Math.sin(t/d * (Math.PI/2)) + b;
  	},
  	easeInOutSine: function (x, t, b, c, d) {
  		return -c/2 * (Math.cos(Math.PI*t/d) - 1) + b;
  	},
  	easeInExpo: function (x, t, b, c, d) {
  		return (t==0) ? b : c * Math.pow(2, 10 * (t/d - 1)) + b;
  	},
  	easeOutExpo: function (x, t, b, c, d) {
  		return (t==d) ? b+c : c * (-Math.pow(2, -10 * t/d) + 1) + b;
  	},
  	easeInOutExpo: function (x, t, b, c, d) {
  		if (t==0) return b;
  		if (t==d) return b+c;
  		if ((t/=d/2) < 1) return c/2 * Math.pow(2, 10 * (t - 1)) + b;
  		return c/2 * (-Math.pow(2, -10 * --t) + 2) + b;
  	},
  	easeInCirc: function (x, t, b, c, d) {
  		return -c * (Math.sqrt(1 - (t/=d)*t) - 1) + b;
  	},
  	easeOutCirc: function (x, t, b, c, d) {
  		return c * Math.sqrt(1 - (t=t/d-1)*t) + b;
  	},
  	easeInOutCirc: function (x, t, b, c, d) {
  		if ((t/=d/2) < 1) return -c/2 * (Math.sqrt(1 - t*t) - 1) + b;
  		return c/2 * (Math.sqrt(1 - (t-=2)*t) + 1) + b;
  	},
  	easeInElastic: function (x, t, b, c, d) {
  		var s=1.70158;var p=0;var a=c;
  		if (t==0) return b;  if ((t/=d)==1) return b+c;  if (!p) p=d*.3;
  		if (a < Math.abs(c)) { a=c; var s=p/4; }
  		else var s = p/(2*Math.PI) * Math.asin (c/a);
  		return -(a*Math.pow(2,10*(t-=1)) * Math.sin( (t*d-s)*(2*Math.PI)/p )) + b;
  	},
  	easeOutElastic: function (x, t, b, c, d) {
  		var s=1.70158;var p=0;var a=c;
  		if (t==0) return b;  if ((t/=d)==1) return b+c;  if (!p) p=d*.3;
  		if (a < Math.abs(c)) { a=c; var s=p/4; }
  		else var s = p/(2*Math.PI) * Math.asin (c/a);
  		return a*Math.pow(2,-10*t) * Math.sin( (t*d-s)*(2*Math.PI)/p ) + c + b;
  	},
  	easeInOutElastic: function (x, t, b, c, d) {
  		var s=1.70158;var p=0;var a=c;
  		if (t==0) return b;  if ((t/=d/2)==2) return b+c;  if (!p) p=d*(.3*1.5);
  		if (a < Math.abs(c)) { a=c; var s=p/4; }
  		else var s = p/(2*Math.PI) * Math.asin (c/a);
  		if (t < 1) return -.5*(a*Math.pow(2,10*(t-=1)) * Math.sin( (t*d-s)*(2*Math.PI)/p )) + b;
  		return a*Math.pow(2,-10*(t-=1)) * Math.sin( (t*d-s)*(2*Math.PI)/p )*.5 + c + b;
  	},
  	easeInBack: function (x, t, b, c, d, s) {
  		if (s == undefined) s = 1.70158;
  		return c*(t/=d)*t*((s+1)*t - s) + b;
  	},
  	easeOutBack: function (x, t, b, c, d, s) {
  		if (s == undefined) s = 1.70158;
  		return c*((t=t/d-1)*t*((s+1)*t + s) + 1) + b;
  	},
  	easeInOutBack: function (x, t, b, c, d, s) {
  		if (s == undefined) s = 1.70158; 
  		if ((t/=d/2) < 1) return c/2*(t*t*(((s*=(1.525))+1)*t - s)) + b;
  		return c/2*((t-=2)*t*(((s*=(1.525))+1)*t + s) + 2) + b;
  	},
  	easeInBounce: function (x, t, b, c, d) {
  		return c - jQuery.easing.easeOutBounce (x, d-t, 0, c, d) + b;
  	},
  	easeOutBounce: function (x, t, b, c, d) {
  		if ((t/=d) < (1/2.75)) {
  			return c*(7.5625*t*t) + b;
  		} else if (t < (2/2.75)) {
  			return c*(7.5625*(t-=(1.5/2.75))*t + .75) + b;
  		} else if (t < (2.5/2.75)) {
  			return c*(7.5625*(t-=(2.25/2.75))*t + .9375) + b;
  		} else {
  			return c*(7.5625*(t-=(2.625/2.75))*t + .984375) + b;
  		}
  	},
  	easeInOutBounce: function (x, t, b, c, d) {
  		if (t < d/2) return jQuery.easing.easeInBounce (x, t*2, 0, c, d) * .5 + b;
  		return jQuery.easing.easeOutBounce (x, t*2-d, 0, c, d) * .5 + c*.5 + b;
  	}
  });
  
  function LoadNewContent(id, file) {
    $("#" + id + " .customScrollBox .content").load(file, function() {
      mCustomScrollbars();
    });
  }
  
  (function($) {
    $.fx.prototype.cur = function() {
      if (this.elem[this.prop] != null && (!this.elem.style || this.elem.style[this.prop] == null)) {
        return this.elem[this.prop];
      }
      var r = parseFloat(jQuery.css(this.elem, this.prop));
      return typeof r == 'undefined' ? 0 : r;
    }
  
    $.fn.mCustomScrollbar = function(scrollType, animSpeed, easeType, bottomSpace, draggerDimType, mouseWheelSupport, scrollBtnsSupport, scrollBtnsSpeed) {
      var id = $(this).attr("id");
      var $customScrollBox = $("#" + id + " .customScrollBox");
      var $customScrollBox_container = $("#" + id + " .customScrollBox .container");
      var $customScrollBox_content = $("#" + id + " .customScrollBox .content");
      var $dragger_container = $("#" + id + " .dragger_container");
      var $dragger = $("#" + id + " .dragger");
      var $scrollUpBtn = $("#" + id + " .scrollUpBtn");
      var $scrollDownBtn = $("#" + id + " .scrollDownBtn");
      var $customScrollBox_horWrapper = $("#" + id + " .customScrollBox .horWrapper");
  
      //get & store minimum dragger height & width (defined in css)
      if (!$customScrollBox.data("minDraggerHeight")) {
        $customScrollBox.data("minDraggerHeight", $dragger.height());
      }
      if (!$customScrollBox.data("minDraggerWidth")) {
        $customScrollBox.data("minDraggerWidth", $dragger.width());
      }
  
      //get & store original content height & width
      if (!$customScrollBox.data("contentHeight")) {
        $customScrollBox.data("contentHeight", $customScrollBox_container.height());
      }
      if (!$customScrollBox.data("contentWidth")) {
        $customScrollBox.data("contentWidth", $customScrollBox_container.width());
      }
  
      CustomScroller();
  
      function CustomScroller(reloadType) {
        //horizontal scrolling ------------------------------
        if (scrollType == "horizontal") {
          var visibleWidth = $customScrollBox.width();
          //set content width automatically
          $customScrollBox_horWrapper.css("width", 999999); //set a rediculously high width value ;)
          $customScrollBox.data("totalContent", $customScrollBox_container.width()); //get inline div width
          $customScrollBox_horWrapper.css("width", $customScrollBox.data("totalContent")); //set back the proper content width value
          if ($customScrollBox_container.width() > visibleWidth) { //enable scrollbar if content is long
            $dragger.css("display", "block");
            if (reloadType != "resize" && $customScrollBox_container.width() != $customScrollBox.data("contentWidth")) {
              $dragger.css("left", 0);
              $customScrollBox_container.css("left", 0);
              $customScrollBox.data("contentWidth", $customScrollBox_container.width());
            }
            $dragger_container.css("display", "block");
            $scrollDownBtn.css("display", "inline-block");
            $scrollUpBtn.css("display", "inline-block");
            var totalContent = $customScrollBox_content.width();
            var minDraggerWidth = $customScrollBox.data("minDraggerWidth");
            var draggerContainerWidth = $dragger_container.width();
  
            function AdjustDraggerWidth() {
              if (draggerDimType == "auto") {
                var adjDraggerWidth = Math.round(totalContent - ((totalContent - visibleWidth) * 1.3)); //adjust dragger width analogous to content
                if (adjDraggerWidth <= minDraggerWidth) { //minimum dragger width
                  $dragger.css("width", minDraggerWidth + "px");
                } else if (adjDraggerWidth >= draggerContainerWidth) {
                  $dragger.css("width", draggerContainerWidth - 10 + "px");
                } else {
                  $dragger.css("width", adjDraggerWidth + "px");
                }
              }
            }
            AdjustDraggerWidth();
  
            var targX = 0;
            var draggerWidth = $dragger.width();
            $dragger.draggable({
              axis: "x",
              containment: "parent",
              drag: function(event, ui) {
                ScrollX();
              },
              stop: function(event, ui) {
                DraggerRelease();
              }
            });
  
            $dragger_container.click(function(e) {
              var $this = $(this);
              var mouseCoord = (e.pageX - $this.offset().left);
              if (mouseCoord < $dragger.position().left || mouseCoord > ($dragger.position().left + $dragger.width())) {
                var targetPos = mouseCoord + $dragger.width();
                if (targetPos < $dragger_container.width()) {
                  $dragger.css("left", mouseCoord);
                  ScrollX();
                } else {
                  $dragger.css("left", $dragger_container.width() - $dragger.width());
                  ScrollX();
                }
              }
            });
  
            //mousewheel
            $(function($) {
              if (mouseWheelSupport == "yes") {
                $customScrollBox.unbind("mousewheel");
                $customScrollBox.bind("mousewheel", function(event, delta) {
                  var vel = Math.abs(delta * 10);
                  $dragger.css("left", $dragger.position().left - (delta * vel));
                  ScrollX();
                  if ($dragger.position().left < 0) {
                    $dragger.css("left", 0);
                    $customScrollBox_container.stop();
                    ScrollX();
                  }
                  if ($dragger.position().left > $dragger_container.width() - $dragger.width()) {
                    $dragger.css("left", $dragger_container.width() - $dragger.width());
                    $customScrollBox_container.stop();
                    ScrollX();
                  }
                  return false;
                });
              }
            });
  
            //scroll buttons
            if (scrollBtnsSupport == "yes") {
              $scrollDownBtn.mouseup(function() {
                BtnsScrollXStop();
              }).mousedown(function() {
                BtnsScrollX("down");
              }).mouseout(function() {
                BtnsScrollXStop();
              });
  
              $scrollUpBtn.mouseup(function() {
                BtnsScrollXStop();
              }).mousedown(function() {
                BtnsScrollX("up");
              }).mouseout(function() {
                BtnsScrollXStop();
              });
  
              $scrollDownBtn.click(function(e) {
                e.preventDefault();
              });
              $scrollUpBtn.click(function(e) {
                e.preventDefault();
              });
  
              btnsScrollTimerX = 0;
  
              function BtnsScrollX(dir) {
                if (dir == "down") {
                  var btnsScrollTo = $dragger_container.width() - $dragger.width();
                  var scrollSpeed = Math.abs($dragger.position().left - btnsScrollTo) * (100 / scrollBtnsSpeed);
                  $dragger.stop().animate({
                    left: btnsScrollTo
                  }, scrollSpeed, "linear");
                } else {
                  var btnsScrollTo = 0;
                  var scrollSpeed = Math.abs($dragger.position().left - btnsScrollTo) * (100 / scrollBtnsSpeed);
                  $dragger.stop().animate({
                    left: -btnsScrollTo
                  }, scrollSpeed, "linear");
                }
                clearInterval(btnsScrollTimerX);
                btnsScrollTimerX = setInterval(ScrollX, 20);
              }
  
              function BtnsScrollXStop() {
                clearInterval(btnsScrollTimerX);
                $dragger.stop();
              }
            }
  
            //scroll
            var scrollAmount = (totalContent - visibleWidth) / (draggerContainerWidth - draggerWidth);
  
            function ScrollX() {
              var draggerX = $dragger.position().left;
              var targX = -draggerX * scrollAmount;
              var thePos = $customScrollBox_container.position().left - targX;
              $customScrollBox_container.stop().animate({
                left: "-=" + thePos
              }, animSpeed, easeType);
            }
          } else { //disable scrollbar if content is short
            $dragger.css("left", 0).css("display", "none"); //reset content scroll
            $customScrollBox_container.css("left", 0);
            $dragger_container.css("display", "none");
            $scrollDownBtn.css("display", "none");
            $scrollUpBtn.css("display", "none");
          }
          //vertical scrolling ------------------------------
        } else {
          var visibleHeight = $customScrollBox.height();
          if ($customScrollBox_container.height() > visibleHeight) { //enable scrollbar if content is long
            $dragger.css("display", "block");
            if (reloadType != "resize" && $customScrollBox_container.height() != $customScrollBox.data("contentHeight")) {
              $dragger.css("top", 0);
              $customScrollBox_container.css("top", 0);
              $customScrollBox.data("contentHeight", $customScrollBox_container.height());
            }
            $dragger_container.css("display", "block");
            $scrollDownBtn.css("display", "inline-block");
            $scrollUpBtn.css("display", "inline-block");
            var totalContent = $customScrollBox_content.height();
            var minDraggerHeight = $customScrollBox.data("minDraggerHeight");
            var draggerContainerHeight = $dragger_container.height();
  
            function AdjustDraggerHeight() {
              if (draggerDimType == "auto") {
                var adjDraggerHeight = Math.round(totalContent - ((totalContent - visibleHeight) * 1.3)); //adjust dragger height analogous to content
                if (adjDraggerHeight <= minDraggerHeight) { //minimum dragger height
                  $dragger.css("height", minDraggerHeight + "px").css("line-height", minDraggerHeight + "px");
                } else if (adjDraggerHeight >= draggerContainerHeight) {
                  $dragger.css("height", draggerContainerHeight - 10 + "px").css("line-height", draggerContainerHeight - 10 + "px");
                } else {
                  $dragger.css("height", adjDraggerHeight + "px").css("line-height", adjDraggerHeight + "px");
                }
              }
            }
            AdjustDraggerHeight();
  
            var targY = 0;
            var draggerHeight = $dragger.height();
            $dragger.draggable({
              axis: "y",
              containment: "parent",
              drag: function(event, ui) {
                Scroll();
              },
              stop: function(event, ui) {
                DraggerRelease();
              }
            });
  
            $dragger_container.click(function(e) {
              var $this = $(this);
              var mouseCoord = (e.pageY - $this.offset().top);
              if (mouseCoord < $dragger.position().top || mouseCoord > ($dragger.position().top + $dragger.height())) {
                var targetPos = mouseCoord + $dragger.height();
                if (targetPos < $dragger_container.height()) {
                  $dragger.css("top", mouseCoord);
                  Scroll();
                } else {
                  $dragger.css("top", $dragger_container.height() - $dragger.height());
                  Scroll();
                }
              }
            });
  
            //mousewheel
            $(function($) {
              if (mouseWheelSupport == "yes") {
                $customScrollBox.unbind("mousewheel");
                $customScrollBox.bind("mousewheel", function(event, delta) {
                  var vel = Math.abs(delta * 10);
                  $dragger.css("top", $dragger.position().top - (delta * vel));
                  Scroll();
                  if ($dragger.position().top < 0) {
                    $dragger.css("top", 0);
                    $customScrollBox_container.stop();
                    Scroll();
                  }
                  if ($dragger.position().top > $dragger_container.height() - $dragger.height()) {
                    $dragger.css("top", $dragger_container.height() - $dragger.height());
                    $customScrollBox_container.stop();
                    Scroll();
                  }
                  return false;
                });
              }
            });
  
            //scroll buttons
            if (scrollBtnsSupport == "yes") {
              $scrollDownBtn.mouseup(function() {
                BtnsScrollStop();
              }).mousedown(function() {
                BtnsScroll("down");
              }).mouseout(function() {
                BtnsScrollStop();
              });
  
              $scrollUpBtn.mouseup(function() {
                BtnsScrollStop();
              }).mousedown(function() {
                BtnsScroll("up");
              }).mouseout(function() {
                BtnsScrollStop();
              });
  
              $scrollDownBtn.click(function(e) {
                e.preventDefault();
              });
              $scrollUpBtn.click(function(e) {
                e.preventDefault();
              });
  
              btnsScrollTimer = 0;
  
              function BtnsScroll(dir) {
                if (dir == "down") {
                  var btnsScrollTo = $dragger_container.height() - $dragger.height();
                  var scrollSpeed = Math.abs($dragger.position().top - btnsScrollTo) * (100 / scrollBtnsSpeed);
                  $dragger.stop().animate({
                    top: btnsScrollTo
                  }, scrollSpeed, "linear");
                } else {
                  var btnsScrollTo = 0;
                  var scrollSpeed = Math.abs($dragger.position().top - btnsScrollTo) * (100 / scrollBtnsSpeed);
                  $dragger.stop().animate({
                    top: -btnsScrollTo
                  }, scrollSpeed, "linear");
                }
                clearInterval(btnsScrollTimer);
                btnsScrollTimer = setInterval(Scroll, 20);
              }
  
              function BtnsScrollStop() {
                clearInterval(btnsScrollTimer);
                $dragger.stop();
              }
            }
  
            //scroll
            if (bottomSpace < 1) {
              bottomSpace = 1; //minimum bottomSpace value is 1
            }
            var scrollAmount = (totalContent - (visibleHeight / bottomSpace)) / (draggerContainerHeight - draggerHeight);
  
            function Scroll() {
              var draggerY = $dragger.position().top;
              var targY = -draggerY * scrollAmount;
              var thePos = $customScrollBox_container.position().top - targY;
              $customScrollBox_container.stop().animate({
                top: "-=" + thePos
              }, animSpeed, easeType);
            }
          } else { //disable scrollbar if content is short
            $dragger.css("top", 0).css("display", "none"); //reset content scroll
            $customScrollBox_container.css("top", 0);
            $dragger_container.css("display", "none");
            $scrollDownBtn.css("display", "none");
            $scrollUpBtn.css("display", "none");
          }
        }
  
        $dragger.mouseup(function() {
          DraggerRelease();
        }).mousedown(function() {
          DraggerPress();
        });
  
        function DraggerPress() {
          $dragger.addClass("dragger_pressed");
        }
  
        function DraggerRelease() {
          $dragger.removeClass("dragger_pressed");
        }
      }
  
      $(window).resize(function() {
        if (scrollType == "horizontal") {
          if ($dragger.position().left > $dragger_container.width() - $dragger.width()) {
            $dragger.css("left", $dragger_container.width() - $dragger.width());
          }
        } else {
          if ($dragger.position().top > $dragger_container.height() - $dragger.height()) {
            $dragger.css("top", $dragger_container.height() - $dragger.height());
          }
        }
        CustomScroller("resize");
      });
    };
    $.fn.kCustomScrollbar = function(scrollType, animSpeed, easeType, bottomSpace, draggerDimType, mouseWheelSupport, scrollBtnsSupport, scrollBtnsSpeed) {
  
      var self = $(this),
          customScroll = self.find('.customScrollBox'),
          scrollContainer = customScroll.find('.container'),
          scrollContent = scrollContainer.find('.content'),
          draggerContainer = customScroll.find('.dragger_container'),
          dragger = draggerContainer.find('.dragger'),
          scrollUp = customScroll.find('.scrollUpBtn'),
          scrollDown = customScroll.find('.scrollDownBtn'),
          horizontalWrapper = customScroll.find('.horWrapper'),
          size, distance, visibleSize, pageScroll, scrollAmount, totalContent, minDraggerSize, draggerContainerSize, targDistance, draggerSize;
  
      if (scrollType == 'horizontal') {
        size = 'width';
        distance = 'left';
        pageScroll = 'pageX';
  
        horizontalWrapper.css('width', 999999);
        //set a rediculously high width value ;)
        customScroll.data('totalContent', scrollContainerSize);
        //get inline div width
        horizontalWrapper.css('width', scrollContainerSize);
  
      } else {
        size = 'height';
        distance = 'top';
        pageScroll = 'pageY';
      }
      visibleSize = customScroll[size]();
      scrollContainerSize = scrollContainer[size]()
      minDraggerSize = dragger[size]()
      contentSize = scrollContainer[size]()
      totalContent = scrollContent[size]();
      minDraggerSize = customScroll.data('minDraggerSize');
      draggerContainerSize = draggerContainer[size]();
      targDistance = 0;
      draggerSize = dragger[size]();
      scrollAmount = (totalContent - (visibleSize / bottomSpace)) / (draggerContainerSize - draggerSize);
  
      //get & store minimum dragger size (defined in css)
      if (!customScroll.data('minDraggerSize')) {
        customScroll.data('minDraggerSize', minDraggerSize);
      }
  
      //get & store original content size
      if (!customScroll.data('contentSize')) {
        customScroll.data('contentSize', contentSize);
      }
  
      customScroller();
  
      function customScroller(reloadType) {
  
        // rewriting
  
  
        function adjustDraggerSize() {
          if (draggerDimType == 'auto') {
            var adjDraggerSize = Math.round(totalContent - ((totalContent - visibleSize) * 1.3));
            //adjust dragger width analogous to content
            if (adjDraggerSize <= minDraggerSize) { //minimum dragger width
              dragger.css(size, minDraggerSize + 'px').css('line-height', minDraggerSize + 'px');
            } else if (adjDraggerSize >= draggerContainerSize) {
              dragger.css(size, draggerContainerSize - 10 + 'px').css('line-height', draggerContainerSize - 10 + 'px');
            } else {
              dragger.css(size, adjDraggerSize + 'px').css('line-height', adjDraggerSize + 'px');
            }
          }
        }
  
        function Btnsscroll(dir) {
  
          var btnsScrollTo, scrollSpeed = Math.abs(dragger.position()[distance] - btnsScrollTo) * (100 / scrollBtnsSpeed),
              obj = {};
  
          if (dir == 'down') {
            btnsScrollTo = draggerContainer[size]() - draggerSize;
            obj[distance] = btnsScrollTo;
  
          } else {
            btnsScrollTo = 0;
            obj[distance] = btnsScrollTo;
  
          }
  
          dragger.stop().animate(obj, scrollSpeed, 'linear');
          clearInterval(btnsScrollTimer);
          btnsScrollTimer = setInterval(scroll, 20);
  
        }
  
        function BtnsScrollStop() {
          clearInterval(btnsScrollTimer);
          dragger.stop();
        }
  
        function scroll() {
          var draggerPos = dragger.position()[distance];
          var targPos = -draggerPos * scrollAmount;
          var thePos = scrollContainer.position()[distance] - targPos;
          var obj = {};
  
          obj[distance] = '-=' + thePos;
          scrollContainer.stop().animate(obj, animSpeed, easeType, function() {
            self.trigger('scrolled');
          });
          self.trigger('scrolled');
        }
  
        function draggerPress() {
          dragger.addClass('dragger_pressed');
        }
  
        function draggerRelease() {
          dragger.removeClass('dragger_pressed');
        }
  
        if (scrollContainerSize > visibleSize) {
  
          dragger.css('display', 'block');
          if (reloadType != 'resize' && scrollContainerSize != customScroll.data('contentSize')) {
            dragger.css(distance, 0);
            scrollContainer.css(distance, 0);
            customScroll.data('contentSize', scrollContainerSize);
          }
          draggerContainer.css('display', 'block');
          scrollDown.css('display', 'inline-block');
          scrollUp.css('display', 'inline-block');
  
          adjustDraggerSize();
  
          dragger.draggable({
            // axis : d.axis,
            axis: scrollType == 'horizontal' ? 'x' : 'y',
            containment: 'parent',
            drag: scroll,
            stop: draggerRelease
          });
  
          draggerContainer.click(function(e) {
            var self = $(this);
            var mouseCoord = (e[pageScroll] - self.offset()[distance]);
            if (mouseCoord < dragger.position()[distance] || mouseCoord > (dragger.position()[distance] + draggerSize)) {
              var targetPos = mouseCoord + draggerSize;
              if (targetPos < draggerContainer[size]()) {
                dragger.css(distance, mouseCoord);
                scroll();
              } else {
                dragger.css(distance, draggerContainer[size]() - draggerSize);
                scroll();
              }
            }
          });
          //mousewheel
          $(function($) {
            if (mouseWheelSupport == 'yes') {
              customScroll.unbind('mousewheel');
              customScroll.bind('mousewheel', function(event, delta) {
                var vel = Math.abs(delta * 10);
                dragger.css(distance, dragger.position()[distance] - (delta * vel));
                scroll();
                if (dragger.position()[distance] < 0) {
                  dragger.css(distance, 0);
                  scrollContainer.stop();
                  scroll();
                }
                if (dragger.position()[distance] > draggerContainer[size]() - draggerSize) {
                  dragger.css(distance, draggerContainer[size]() - draggerSize);
                  scrollContainer.stop();
                  scroll();
                }
                return false;
              });
            }
          });
          //scroll buttons
          if (scrollBtnsSupport == 'yes') {
  
            scrollDown.bind({
              mouseup: BtnsScrollStop,
              mousedown: function() {
                Btnsscroll('down');
              },
              mouseout: BtnsScrollStop
            });
  
            scrollUp.mouseup(function() {
              BtnsScrollStop();
            }).mousedown(function() {
              Btnsscroll('up');
            }).mouseout(function() {
              BtnsScrollStop();
            });
  
            scrollDown.click(function(e) {
              e.preventDefault();
            });
            scrollUp.click(function(e) {
              e.preventDefault();
            });
            btnsScrollTimer = 0;
  
          }
  
        } else {
          dragger.css(distance, 0).css('display', 'none');
          //reset content scroll
          scrollContainer.css(distance, 0);
          draggerContainer.css('display', 'none');
          scrollDown.css('display', 'none');
          scrollUp.css('display', 'none');
  
        }
  
        dragger.mouseup(function() {
          draggerRelease();
        }).mousedown(function() {
          draggerPress();
        });
      }
  
  
      $(window).resize(function() {
        if (scrollType == 'horizontal') {
          if (dragger.position().left > draggerContainer.width() - draggerWidth) {
            dragger.css('left', draggerContainer.width() - draggerWidth);
          }
        } else {
          if (dragger.position().top > draggerContainer.height() - dragger.height()) {
            dragger.css('top', draggerContainer.height() - dragger.height());
          }
        }
        customScroller('resize');
      });
    };
  })(jQuery);

};
</script>

Preparation code output

<a href="http://manos.malihu.gr/jquery-custom-content-scroller" class="postURL"></a> <div class="info"> <span class="blue"> malihu </span> <br /> <span class="big"> Custom Scrollbar </span> plugin </div> <!-- content block --> <div id="mcs_container"> <div class="customScrollBox"> <div class="container"> <div class="content"> <h1> Adjustable scroller height with easing </h1> <p> <a href="#" onclick="LoadNewContent('mcs_container','dynamic_content.html');return false">Load new content dynamically</a> </p> <p style="color:#C96;"> Aliquam erat volutpat. Maecenas non tortor nulla, non malesuada velit. Nullam felis tellus, tristique nec egestas in, luctus sed diam. Suspendisse potenti. </p> <p class="alt"> <em> consectetur adipiscing elit. Nulla consectetur libero consectetur quam consequat nec tincidunt massa feugiat. Donec egestas mi turpis. Fusce adipiscing dui eu metus gravida vel facilisis ligula iaculis. Cras a rhoncus massa. Donec sed purus eget nunc placerat consequat. </em> </p> <img src="mcsImg1.jpg" /> <p> Aliquam erat volutpat. Maecenas non tortor nulla, non malesuada velit. Nullam felis tellus, tristique nec egestas in, luctus sed diam. Suspendisse potenti. Cras venenatis condimentum nibh a mollis. Duis id sapien nibh. Vivamus porttitor, felis quis blandit tincidunt, erat magna scelerisque urna, a faucibus erat nisl eget nisl. Aliquam consequat turpis id velit egestas a posuere orci semper. Mauris suscipit erat quis urna adipiscing ultricies. In hac habitasse platea dictumst. Nulla scelerisque lorem quis dui sagittis egestas. </p> <p class="alt"> Etiam sed massa felis, aliquam pellentesque est. Quisque quis ante tortor, sed egestas risus. Maecenas varius adipiscing nulla, nec rhoncus est mattis id. Aenean blandit convallis nisi at fringilla. Nunc id massa eu sapien fringilla posuere. </p> <img src="mcsImg2.jpg" /> <p style="color:#C96;"> Nam eu arcu at purus tincidunt pharetra ultrices at ipsum. Mauris urna nunc, vulputate quis gravida in, pharetra id mauris. Ut sit amet mi dictum nulla lobortis adipiscing quis a nulla. Etiam diam ante, imperdiet vel scelerisque eget, venenatis non eros. Praesent ipsum sem, eleifend ut gravida eget, tristique id orci. Nam adipiscing, sem in mattis vulputate, risus libero adipiscing risus, eu molestie mi justo eget nulla. </p> <p> Cras venenatis metus et urna egestas non laoreet orci rutrum. Pellentesque ullamcorper dictum nisl a tincidunt. Quisque et lacus quam, sed hendrerit mi. Mauris pretium, sapien et malesuada pulvinar, lorem leo viverra leo, et egestas mi nisl quis odio. </p> <p> Aliquam erat volutpat. Sed urna arcu, tempus eu vulputate adipiscing, consectetur et orci. Vivamus congue, nunc vitae fringilla convallis, libero massa lacinia lorem, id convallis mauris elit ut leo. Nulla vel odio sem. Duis lorem urna, congue vitae rutrum sed, tincidunt vel tortor. In hac habitasse platea dictumst. Nunc vitae enim ante, vitae facilisis massa. Etiam sagittis sapien at nibh fermentum consectetur convallis lacus blandit. </p> <h1> the end. </h1> </div> </div> <div class="dragger_container"> <div class="dragger"> </div> </div> </div> <a href="#" class="scrollUpBtn"></a> <a href="#" class="scrollDownBtn"></a> </div> <!-- content block --> <div id="mcs2_container"> <div class="customScrollBox"> <div class="container"> <div class="content"> <h1> Adjustable scroller height without easing </h1> <p> <a href="#" onclick="LoadNewContent('mcs2_container','dynamic_content.html');return false">Load new content dynamically</a> </p> <p class="alt"> Aliquam erat volutpat. Maecenas non tortor nulla, non malesuada velit. Nullam felis tellus, tristique nec egestas in, luctus sed diam. </p> <p> <em> consectetur adipiscing elit. Nulla consectetur libero consectetur quam consequat nec tincidunt massa feugiat. Fusce adipiscing dui eu metus gravida vel facilisis ligula iaculis. </em> </p> <img src="mcsImg2.jpg" /> <p> In hac habitasse platea dictumst. Aliquam erat volutpat. Maecenas non tortor nulla, non malesuada velit. Nullam felis tellus, tristique nec egestas in, luctus sed diam. Suspendisse potenti. Cras venenatis condimentum nibh a mollis. Duis id sapien nibh. Vivamus porttitor, felis quis blandit tincidunt, erat magna scelerisque urna, a faucibus erat nisl eget nisl. Aliquam consequat turpis id velit egestas a posuere orci semper. </p> <h1> the end. </h1> </div> </div> <div class="dragger_container"> <div class="dragger"> &#9618; </div> </div> </div> </div> <!-- content block --> <div id="mcs3_container"> <div class="customScrollBox"> <div class="container"> <div class="content"> <h3> Adjustable scroller height with 1/3 range and greater easing, without mouse-wheel support </h3> <p> Aliquam erat volutpat. Maecenas non tortor nulla, non malesuada velit. Nullam felis tellus, tristique nec egestas in, luctus sed diam. Suspendisse potenti. </p> <p> consectetur adipiscing elit. Nulla consectetur libero consectetur quam consequat nec tincidunt massa feugiat. Donec egestas mi turpis. Fusce adipiscing dui eu metus gravida vel facilisis ligula iaculis. Cras a rhoncus massa. Donec sed purus eget nunc placerat consequat. Nulla facilisi. Nam vel augue odio, dignissim mattis dolor. Nullam at mi aliquet quam interdum consectetur. Duis tempus mauris in lorem dictum eget euismod urna aliquet. In vestibulum tempor porta. </p> <p> Morbi porttitor rhoncus nisi, eget vehicula quam sodales at. Maecenas ipsum tellus, mollis quis faucibus id, feugiat molestie lacus. Sed nec quam purus, at condimentum quam. Integer imperdiet faucibus urna tempus consectetur. Nullam non purus ligula, et tincidunt nulla. Aenean tincidunt, dui at elementum egestas, sem turpis volutpat turpis, nec congue purus quam quis ligula. Nam dictum rutrum pulvinar. Aenean sed cursus purus. Curabitur non dui eu nibh fermentum interdum a id dui. Fusce iaculis blandit tellus, nec tincidunt massa adipiscing id. Aliquam dui massa, porttitor eget molestie at, semper eu libero. Suspendisse sit amet velit et elit viverra convallis vitae ut turpis. Maecenas vehicula blandit odio sollicitudin eleifend. Curabitur molestie porta neque ac imperdiet. Phasellus nec nisl non lectus pharetra porttitor sit amet tristique mi. Integer vehicula vestibulum sem vitae varius. Ut scelerisque semper posuere. </p> <img src="mcsImg1.jpg" /> <p> Aliquam erat volutpat. Maecenas non tortor nulla, non malesuada velit. Nullam felis tellus, tristique nec egestas in, luctus sed diam. Suspendisse potenti. Cras venenatis condimentum nibh a mollis. Duis id sapien nibh. Vivamus porttitor, felis quis blandit tincidunt, erat magna scelerisque urna, a faucibus erat nisl eget nisl. Aliquam consequat turpis id velit egestas a posuere orci semper. Mauris suscipit erat quis urna adipiscing ultricies. In hac habitasse platea dictumst. Nulla scelerisque lorem quis dui sagittis egestas. Etiam sed massa felis, aliquam pellentesque est. Quisque quis ante tortor, sed egestas risus. Maecenas varius adipiscing nulla, nec rhoncus est mattis id. Aenean blandit convallis nisi at fringilla. Nunc id massa eu sapien fringilla posuere. </p> <img src="mcsImg2.jpg" /> <p> Nam eu arcu at purus tincidunt pharetra ultrices at ipsum. Mauris urna nunc, vulputate quis gravida in, pharetra id mauris. Ut sit amet mi dictum nulla lobortis adipiscing quis a nulla. Etiam diam ante, imperdiet vel scelerisque eget, venenatis non eros. Praesent ipsum sem, eleifend ut gravida eget, tristique id orci. Nam adipiscing, sem in mattis vulputate, risus libero adipiscing risus, eu molestie mi justo eget nulla. Cras venenatis metus et urna egestas non laoreet orci rutrum. Pellentesque ullamcorper dictum nisl a tincidunt. Quisque et lacus quam, sed hendrerit mi. Mauris pretium, sapien et malesuada pulvinar, lorem leo viverra leo, et egestas mi nisl quis odio. Aliquam erat volutpat. Sed urna arcu, tempus eu vulputate adipiscing, consectetur et orci. Vivamus congue, nunc vitae fringilla convallis, libero massa lacinia lorem, id convallis mauris elit ut leo. Nulla vel odio sem. Duis lorem urna, congue vitae rutrum sed, tincidunt vel tortor. In hac habitasse platea dictumst. Nunc vitae enim ante, vitae facilisis massa. Etiam sagittis sapien at nibh fermentum consectetur convallis lacus blandit. </p> <img src="mcsImg1.jpg" /> <p> Aliquam erat volutpat. Maecenas non tortor nulla, non malesuada velit. Nullam felis tellus, tristique nec egestas in, luctus sed diam. Suspendisse potenti. Cras venenatis condimentum nibh a mollis. Duis id sapien nibh. Vivamus porttitor, felis quis blandit tincidunt, erat magna scelerisque urna, a faucibus erat nisl eget nisl. Aliquam consequat turpis id velit egestas a posuere orci semper. Mauris suscipit erat quis urna adipiscing ultricies. In hac habitasse platea dictumst. Nulla scelerisque lorem quis dui sagittis egestas. Etiam sed massa felis, aliquam pellentesque est. Quisque quis ante tortor, sed egestas risus. Maecenas varius adipiscing nulla, nec rhoncus est mattis id. Aenean blandit convallis nisi at fringilla. Nunc id massa eu sapien fringilla posuere. </p> <img src="mcsImg2.jpg" /> <p> Nam eu arcu at purus tincidunt pharetra ultrices at ipsum. Mauris urna nunc, vulputate quis gravida in, pharetra id mauris. Ut sit amet mi dictum nulla lobortis adipiscing quis a nulla. Etiam diam ante, imperdiet vel scelerisque eget, venenatis non eros. Praesent ipsum sem, eleifend ut gravida eget, tristique id orci. Nam adipiscing, sem in mattis vulputate, risus libero adipiscing risus, eu molestie mi justo eget nulla. Cras venenatis metus et urna egestas non laoreet orci rutrum. Pellentesque ullamcorper dictum nisl a tincidunt. Quisque et lacus quam, sed hendrerit mi. Mauris pretium, sapien et malesuada pulvinar, lorem leo viverra leo, et egestas mi nisl quis odio. Aliquam erat volutpat. Sed urna arcu, tempus eu vulputate adipiscing, consectetur et orci. Vivamus congue, nunc vitae fringilla convallis, libero massa lacinia lorem, id convallis mauris elit ut leo. Nulla vel odio sem. Duis lorem urna, congue vitae rutrum sed, tincidunt vel tortor. In hac habitasse platea dictumst. Nunc vitae enim ante, vitae facilisis massa. Etiam sagittis sapien at nibh fermentum consectetur convallis lacus blandit. </p> <p> the end. </p> </div> </div> <div class="dragger_container"> <div class="dragger"> </div> </div> </div> </div> <!-- content block --> <div id="mcs4_container"> <div class="customScrollBox"> <div class="container"> <div class="content"> <h2> Non-adjustable scroller height with minor easing </h2> <p> Lorem ipsum dolor sit amet. Aliquam erat volutpat. Maecenas non tortor nulla, non malesuada velit. Nullam felis tellus, tristique nec egestas in, luctus sed diam. Suspendisse potenti. </p> <p> consectetur adipiscing elit. Nulla consectetur libero consectetur quam consequat nec tincidunt massa feugiat. Donec egestas mi turpis. Fusce adipiscing dui eu metus gravida vel facilisis ligula iaculis. Cras a rhoncus massa. Donec sed purus eget nunc placerat consequat. Nulla facilisi. Nam vel augue odio, dignissim mattis dolor. Nullam at mi aliquet quam interdum consectetur. Duis tempus mauris in lorem dictum eget euismod urna aliquet. In vestibulum tempor porta. </p> <p> Aliquam erat volutpat. Maecenas non tortor nulla, non malesuada velit. Nullam felis tellus, tristique nec egestas in, luctus sed diam. Suspendisse potenti. Cras venenatis condimentum nibh a mollis. Duis id sapien nibh. Vivamus porttitor, felis quis blandit tincidunt, erat magna scelerisque urna, a faucibus erat nisl eget nisl. Aliquam consequat turpis id velit egestas a posuere orci semper. Mauris suscipit erat quis urna adipiscing ultricies. In hac habitasse platea dictumst. Nulla scelerisque lorem quis dui sagittis egestas. Etiam sed massa felis, aliquam pellentesque est. Quisque quis ante tortor, sed egestas risus. Maecenas varius adipiscing nulla, nec rhoncus est mattis id. Aenean blandit convallis nisi at fringilla. Nunc id massa eu sapien fringilla posuere. </p> <h2> the end. </h2> </div> </div> <div class="dragger_container"> <div class="dragger"> </div> </div> </div> </div> <!-- content block --> <div id="mcs5_container"> <div class="customScrollBox"> <!-- horWrapper div is important for horizontal scrollers! --> <div class="horWrapper"> <div class="container"> <div class="content"> <h4> Horizontal non-adjustable image scroller with easing </h4> <p> <img src="mcsThumb1.jpg" /> <img src="mcsThumb2.jpg" /> <img src="mcsThumb3.jpg" /> <img src="mcsThumb4.jpg" /> <img src="mcsThumb5.jpg" /> <img src="mcsThumb6.jpg" /> <img src="mcsThumb7.jpg" /> <img src="mcsThumb8.jpg" /> <img src="mcsThumb1.jpg" /> <img src="mcsThumb2.jpg" /> <img src="mcsThumb3.jpg" /> <img src="mcsThumb4.jpg" /> </p> </div> </div> <div class="dragger_container"> <div class="dragger"> </div> </div> </div> </div> <a href="#" class="scrollUpBtn">&#8678;</a> <a href="#" class="scrollDownBtn">&#8680;</a> </div>

Test runner

Warning! For accurate results, please disable Firebug before running the tests. (Why?)

Java applet disabled.

Testing in CCBot 2.0.0 / Other 0.0.0
Test Ops/sec
Kenzaroli's Hardcore
$("#mcs_container").hCustomScrollbar({
axis: 'y',
		duration: 400,
		easing: 'easeOutCirc',
		bottom: 1.05,
		draggerResize: false,
		mousewheel: true,
		scrollButtons: true,
		scrollButtonsSpeed: 10
});
$("#mcs2_container").hCustomScrollbar({axis: 'y',
		duration: 0,
		easing: 'easeOutCirc',
		bottom: 1.05,
		draggerResize: true,
		mousewheel: true,
		scrollButtons: false,
		scrollButtonsSpeed: 0});
$("#mcs3_container").hCustomScrollbar({
		axis: 'y',
		duration: 900,
		easing: 'easeOutCirc',
		bottom: 1.05,
		draggerResize: false,
		mousewheel: false,
		scrollButtons: false,
		scrollButtonsSpeed: 0
});
$("#mcs4_container").hCustomScrollbar({
		axis: 'y',
		duration: 200,
		easing: 'easeOutCirc',
		bottom: 1.25,
		draggerResize: true,
		mousewheel: true,
		scrollButtons: false,
		scrollButtonsSpeed: 0
});
$("#mcs5_container").hCustomScrollbar({
		axis: 'y',
		duration: 500,
		easing: 'easeOutCirc',
		bottom: 1,
		draggerResize: false,
		mousewheel: true,
		scrollButtons: true,
		scrollButtonsSpeed: 20
});
pending…
Original
$("#mcs_container").mCustomScrollbar("vertical", 400, "easeOutCirc", 1.05, "fixed", "yes", "yes", 10);
$("#mcs2_container").mCustomScrollbar("vertical", 0, "easeOutCirc", 1.05, "auto", "yes", "no", 0);
$("#mcs3_container").mCustomScrollbar("vertical", 900, "easeOutCirc", 1.05, "fixed", "no", "no", 0);
$("#mcs4_container").mCustomScrollbar("vertical", 200, "easeOutCirc", 1.25, "auto", "yes", "no", 0);
$("#mcs5_container").mCustomScrollbar("horizontal", 500, "easeOutCirc", 1, "fixed", "yes", "yes", 20);
pending…
Kenzaroli's Simple
$("#mcs_container").kCustomScrollbar("vertical", 400, "easeOutCirc", 1.05, "fixed", "yes", "yes", 10);
$("#mcs2_container").kCustomScrollbar("vertical", 0, "easeOutCirc", 1.05, "auto", "yes", "no", 0);
$("#mcs3_container").kCustomScrollbar("vertical", 900, "easeOutCirc", 1.05, "fixed", "no", "no", 0);
$("#mcs4_container").kCustomScrollbar("vertical", 200, "easeOutCirc", 1.25, "auto", "yes", "no", 0);
$("#mcs5_container").kCustomScrollbar("horizontal", 500, "easeOutCirc", 1, "fixed", "yes", "yes", 20);
pending…

Compare results of other browsers

Revisions

You can edit these tests or add even more tests to this page by appending /edit to the URL.

0 Comments

malihu
Custom Scrollbar plugin

Adjustable scroller height with easing

Load new content dynamically

Aliquam erat volutpat. Maecenas non tortor nulla, non malesuada velit. Nullam felis tellus, tristique nec egestas in, luctus sed diam. Suspendisse potenti.

consectetur adipiscing elit. Nulla consectetur libero consectetur quam consequat nec tincidunt massa feugiat. Donec egestas mi turpis. Fusce adipiscing dui eu metus gravida vel facilisis ligula iaculis. Cras a rhoncus massa. Donec sed purus eget nunc placerat consequat.

Aliquam erat volutpat. Maecenas non tortor nulla, non malesuada velit. Nullam felis tellus, tristique nec egestas in, luctus sed diam. Suspendisse potenti. Cras venenatis condimentum nibh a mollis. Duis id sapien nibh. Vivamus porttitor, felis quis blandit tincidunt, erat magna scelerisque urna, a faucibus erat nisl eget nisl. Aliquam consequat turpis id velit egestas a posuere orci semper. Mauris suscipit erat quis urna adipiscing ultricies. In hac habitasse platea dictumst. Nulla scelerisque lorem quis dui sagittis egestas.

Etiam sed massa felis, aliquam pellentesque est. Quisque quis ante tortor, sed egestas risus. Maecenas varius adipiscing nulla, nec rhoncus est mattis id. Aenean blandit convallis nisi at fringilla. Nunc id massa eu sapien fringilla posuere.

Nam eu arcu at purus tincidunt pharetra ultrices at ipsum. Mauris urna nunc, vulputate quis gravida in, pharetra id mauris. Ut sit amet mi dictum nulla lobortis adipiscing quis a nulla. Etiam diam ante, imperdiet vel scelerisque eget, venenatis non eros. Praesent ipsum sem, eleifend ut gravida eget, tristique id orci. Nam adipiscing, sem in mattis vulputate, risus libero adipiscing risus, eu molestie mi justo eget nulla.

Cras venenatis metus et urna egestas non laoreet orci rutrum. Pellentesque ullamcorper dictum nisl a tincidunt. Quisque et lacus quam, sed hendrerit mi. Mauris pretium, sapien et malesuada pulvinar, lorem leo viverra leo, et egestas mi nisl quis odio.

Aliquam erat volutpat. Sed urna arcu, tempus eu vulputate adipiscing, consectetur et orci. Vivamus congue, nunc vitae fringilla convallis, libero massa lacinia lorem, id convallis mauris elit ut leo. Nulla vel odio sem. Duis lorem urna, congue vitae rutrum sed, tincidunt vel tortor. In hac habitasse platea dictumst. Nunc vitae enim ante, vitae facilisis massa. Etiam sagittis sapien at nibh fermentum consectetur convallis lacus blandit.

the end.

Adjustable scroller height without easing

Load new content dynamically

Aliquam erat volutpat. Maecenas non tortor nulla, non malesuada velit. Nullam felis tellus, tristique nec egestas in, luctus sed diam.

consectetur adipiscing elit. Nulla consectetur libero consectetur quam consequat nec tincidunt massa feugiat. Fusce adipiscing dui eu metus gravida vel facilisis ligula iaculis.

In hac habitasse platea dictumst. Aliquam erat volutpat. Maecenas non tortor nulla, non malesuada velit. Nullam felis tellus, tristique nec egestas in, luctus sed diam. Suspendisse potenti. Cras venenatis condimentum nibh a mollis. Duis id sapien nibh. Vivamus porttitor, felis quis blandit tincidunt, erat magna scelerisque urna, a faucibus erat nisl eget nisl. Aliquam consequat turpis id velit egestas a posuere orci semper.

the end.

Adjustable scroller height with 1/3 range and greater easing, without mouse-wheel support

Aliquam erat volutpat. Maecenas non tortor nulla, non malesuada velit. Nullam felis tellus, tristique nec egestas in, luctus sed diam. Suspendisse potenti.

consectetur adipiscing elit. Nulla consectetur libero consectetur quam consequat nec tincidunt massa feugiat. Donec egestas mi turpis. Fusce adipiscing dui eu metus gravida vel facilisis ligula iaculis. Cras a rhoncus massa. Donec sed purus eget nunc placerat consequat. Nulla facilisi. Nam vel augue odio, dignissim mattis dolor. Nullam at mi aliquet quam interdum consectetur. Duis tempus mauris in lorem dictum eget euismod urna aliquet. In vestibulum tempor porta.

Morbi porttitor rhoncus nisi, eget vehicula quam sodales at. Maecenas ipsum tellus, mollis quis faucibus id, feugiat molestie lacus. Sed nec quam purus, at condimentum quam. Integer imperdiet faucibus urna tempus consectetur. Nullam non purus ligula, et tincidunt nulla. Aenean tincidunt, dui at elementum egestas, sem turpis volutpat turpis, nec congue purus quam quis ligula. Nam dictum rutrum pulvinar. Aenean sed cursus purus. Curabitur non dui eu nibh fermentum interdum a id dui. Fusce iaculis blandit tellus, nec tincidunt massa adipiscing id. Aliquam dui massa, porttitor eget molestie at, semper eu libero. Suspendisse sit amet velit et elit viverra convallis vitae ut turpis. Maecenas vehicula blandit odio sollicitudin eleifend. Curabitur molestie porta neque ac imperdiet. Phasellus nec nisl non lectus pharetra porttitor sit amet tristique mi. Integer vehicula vestibulum sem vitae varius. Ut scelerisque semper posuere.

Aliquam erat volutpat. Maecenas non tortor nulla, non malesuada velit. Nullam felis tellus, tristique nec egestas in, luctus sed diam. Suspendisse potenti. Cras venenatis condimentum nibh a mollis. Duis id sapien nibh. Vivamus porttitor, felis quis blandit tincidunt, erat magna scelerisque urna, a faucibus erat nisl eget nisl. Aliquam consequat turpis id velit egestas a posuere orci semper. Mauris suscipit erat quis urna adipiscing ultricies. In hac habitasse platea dictumst. Nulla scelerisque lorem quis dui sagittis egestas. Etiam sed massa felis, aliquam pellentesque est. Quisque quis ante tortor, sed egestas risus. Maecenas varius adipiscing nulla, nec rhoncus est mattis id. Aenean blandit convallis nisi at fringilla. Nunc id massa eu sapien fringilla posuere.

Nam eu arcu at purus tincidunt pharetra ultrices at ipsum. Mauris urna nunc, vulputate quis gravida in, pharetra id mauris. Ut sit amet mi dictum nulla lobortis adipiscing quis a nulla. Etiam diam ante, imperdiet vel scelerisque eget, venenatis non eros. Praesent ipsum sem, eleifend ut gravida eget, tristique id orci. Nam adipiscing, sem in mattis vulputate, risus libero adipiscing risus, eu molestie mi justo eget nulla. Cras venenatis metus et urna egestas non laoreet orci rutrum. Pellentesque ullamcorper dictum nisl a tincidunt. Quisque et lacus quam, sed hendrerit mi. Mauris pretium, sapien et malesuada pulvinar, lorem leo viverra leo, et egestas mi nisl quis odio. Aliquam erat volutpat. Sed urna arcu, tempus eu vulputate adipiscing, consectetur et orci. Vivamus congue, nunc vitae fringilla convallis, libero massa lacinia lorem, id convallis mauris elit ut leo. Nulla vel odio sem. Duis lorem urna, congue vitae rutrum sed, tincidunt vel tortor. In hac habitasse platea dictumst. Nunc vitae enim ante, vitae facilisis massa. Etiam sagittis sapien at nibh fermentum consectetur convallis lacus blandit.

Aliquam erat volutpat. Maecenas non tortor nulla, non malesuada velit. Nullam felis tellus, tristique nec egestas in, luctus sed diam. Suspendisse potenti. Cras venenatis condimentum nibh a mollis. Duis id sapien nibh. Vivamus porttitor, felis quis blandit tincidunt, erat magna scelerisque urna, a faucibus erat nisl eget nisl. Aliquam consequat turpis id velit egestas a posuere orci semper. Mauris suscipit erat quis urna adipiscing ultricies. In hac habitasse platea dictumst. Nulla scelerisque lorem quis dui sagittis egestas. Etiam sed massa felis, aliquam pellentesque est. Quisque quis ante tortor, sed egestas risus. Maecenas varius adipiscing nulla, nec rhoncus est mattis id. Aenean blandit convallis nisi at fringilla. Nunc id massa eu sapien fringilla posuere.

Nam eu arcu at purus tincidunt pharetra ultrices at ipsum. Mauris urna nunc, vulputate quis gravida in, pharetra id mauris. Ut sit amet mi dictum nulla lobortis adipiscing quis a nulla. Etiam diam ante, imperdiet vel scelerisque eget, venenatis non eros. Praesent ipsum sem, eleifend ut gravida eget, tristique id orci. Nam adipiscing, sem in mattis vulputate, risus libero adipiscing risus, eu molestie mi justo eget nulla. Cras venenatis metus et urna egestas non laoreet orci rutrum. Pellentesque ullamcorper dictum nisl a tincidunt. Quisque et lacus quam, sed hendrerit mi. Mauris pretium, sapien et malesuada pulvinar, lorem leo viverra leo, et egestas mi nisl quis odio. Aliquam erat volutpat. Sed urna arcu, tempus eu vulputate adipiscing, consectetur et orci. Vivamus congue, nunc vitae fringilla convallis, libero massa lacinia lorem, id convallis mauris elit ut leo. Nulla vel odio sem. Duis lorem urna, congue vitae rutrum sed, tincidunt vel tortor. In hac habitasse platea dictumst. Nunc vitae enim ante, vitae facilisis massa. Etiam sagittis sapien at nibh fermentum consectetur convallis lacus blandit.

the end.

Non-adjustable scroller height with minor easing

Lorem ipsum dolor sit amet. Aliquam erat volutpat. Maecenas non tortor nulla, non malesuada velit. Nullam felis tellus, tristique nec egestas in, luctus sed diam. Suspendisse potenti.

consectetur adipiscing elit. Nulla consectetur libero consectetur quam consequat nec tincidunt massa feugiat. Donec egestas mi turpis. Fusce adipiscing dui eu metus gravida vel facilisis ligula iaculis. Cras a rhoncus massa. Donec sed purus eget nunc placerat consequat. Nulla facilisi. Nam vel augue odio, dignissim mattis dolor. Nullam at mi aliquet quam interdum consectetur. Duis tempus mauris in lorem dictum eget euismod urna aliquet. In vestibulum tempor porta.

Aliquam erat volutpat. Maecenas non tortor nulla, non malesuada velit. Nullam felis tellus, tristique nec egestas in, luctus sed diam. Suspendisse potenti. Cras venenatis condimentum nibh a mollis. Duis id sapien nibh. Vivamus porttitor, felis quis blandit tincidunt, erat magna scelerisque urna, a faucibus erat nisl eget nisl. Aliquam consequat turpis id velit egestas a posuere orci semper. Mauris suscipit erat quis urna adipiscing ultricies. In hac habitasse platea dictumst. Nulla scelerisque lorem quis dui sagittis egestas. Etiam sed massa felis, aliquam pellentesque est. Quisque quis ante tortor, sed egestas risus. Maecenas varius adipiscing nulla, nec rhoncus est mattis id. Aenean blandit convallis nisi at fringilla. Nunc id massa eu sapien fringilla posuere.

the end.

Horizontal non-adjustable image scroller with easing