From c2fbf64ab8065d416decda659d258d1651389640 Mon Sep 17 00:00:00 2001 From: Julian Sauer Date: Fri, 10 Jun 2016 09:53:52 +0200 Subject: [PATCH] Fixed scroll bug when carousels contained elements of different size. --- src/jquery.cycle2.carousel.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/jquery.cycle2.carousel.js b/src/jquery.cycle2.carousel.js index cbc48dd..66910e8 100644 --- a/src/jquery.cycle2.carousel.js +++ b/src/jquery.cycle2.carousel.js @@ -234,7 +234,7 @@ $.fn.cycle.transitions.carousel = { } else { for (i=currSlide; i > currSlide+hops; i--) - moveBy += this.getDim( opts, i, vert); + moveBy += this.getDim( opts, i-1, vert); } return moveBy; },