

(function($) {

  $.fn.handleSwipes = function() {
	  return this.each(function() {
		var api = $(this).data("scrollable");
	
		api.getRoot().addSwipeEvents()
		   .bind('swipeleft', function() {
			 api.stop().next();
		   })
		   .bind('swiperight', function() {
			 api.stop().prev();
		   });
	  });
  };
 
 
})(jQuery);
