Skip to content

Commit

Permalink
Fix an issue where swipePrev will not work in Chrome when zoomed in.
Browse files Browse the repository at this point in the history
  • Loading branch information
andyburke committed Apr 30, 2013
1 parent 99218d1 commit 5b24d38
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion dev/idangerous.swiper.js
Original file line number Diff line number Diff line change
Expand Up @@ -1192,7 +1192,7 @@ var Swiper = function (selector, params, callback) {

_this.callPlugins('onSwipePrev');

var getTranslate = isHorizontal ? _this.getTranslate('x') : _this.getTranslate('y')
var getTranslate = Math.ceil( isHorizontal ? _this.getTranslate('x') : _this.getTranslate('y') );

var groupSize = slideSize * params.slidesPerGroup;
var newPosition = (Math.ceil(-getTranslate/groupSize)-1)*groupSize;
Expand Down

0 comments on commit 5b24d38

Please sign in to comment.