Skip to content

Commit

Permalink
bugfixes
Browse files Browse the repository at this point in the history
  • Loading branch information
Andy Eades committed Jun 28, 2015
1 parent f8a8cfe commit 50a0d8b
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions jquery.elevatezoom.js
Original file line number Diff line number Diff line change
Expand Up @@ -448,6 +448,7 @@ if ( typeof Object.create !== 'function' ) {
}).mouseleave(function(){
if(!self.scrollLock){
self.setElements("hide");
self.options.onDestroy(self.$elem);
}
});
//end ove image
Expand Down Expand Up @@ -610,11 +611,11 @@ if ( typeof Object.create !== 'function' ) {
lensHeight = String((self.options.zoomWindowHeight/self.heightRatio))
}

if(self.options.zoomWindowWidth < self.options.zoomWindowWidth){
if(self.nzWidth < self.options.zoomWindowHeight/self.heightRatio){
lensWidth = self.nzWidth;
}
else{
lensWidth = (self.options.zoomWindowWidth/self.widthRatio);
lensWidth = String((self.options.zoomWindowWidth/self.widthRatio));
}

self.zoomLens.css('width', lensWidth);
Expand Down Expand Up @@ -1185,8 +1186,6 @@ if ( typeof Object.create !== 'function' ) {
self.largeHeight = newImg.height;
self.zoomImage = largeimage;
self.zoomWindow.css({ "background-size": self.largeWidth + 'px ' + self.largeHeight + 'px' });


self.swapAction(smallimage, largeimage);
return;
}
Expand Down Expand Up @@ -1782,9 +1781,10 @@ if ( typeof Object.create !== 'function' ) {
cursor:"default", // user should set to what they want the cursor as, if they have set a click function
responsive:true,
onComplete: $.noop,
onDestroy: function() {},
onZoomedImageLoaded: function() {},
onImageSwap: $.noop,
onImageSwapComplete: $.noop
};

})( jQuery, window, document );
})( jQuery, window, document );

0 comments on commit 50a0d8b

Please sign in to comment.