diff --git a/responsiveslides.js b/responsiveslides.js index 80d097d..ee1dcb4 100644 --- a/responsiveslides.js +++ b/responsiveslides.js @@ -65,6 +65,7 @@ $slide = $this.children(), length = $slide.size(), fadetime = parseFloat(settings.speed), + maxw = parseFloat(settings.maxwidth), // Namespacing namespace = settings.namespace, @@ -114,7 +115,7 @@ // Add max-width and classes $this.addClass(namespace + " " + namespaceIdx); if (options && options.maxwidth) { - $this.css("max-width", parseFloat(settings.maxwidth)); + $this.css("max-width", maxw); } // Hide all slides, then show first one @@ -257,8 +258,8 @@ if (typeof document.body.style.maxWidth === "undefined" && options && options.maxwidth) { var widthSupport = function () { $this.css("width", "100%"); - if ($this.width() > parseFloat(settings.maxwidth)) { - $this.css("width", parseFloat(settings.maxwidth)); + if ($this.width() > maxw) { + $this.css("width", maxw); } }; diff --git a/responsiveslides.min.js b/responsiveslides.min.js index 93b17f1..1fd6654 100644 --- a/responsiveslides.min.js +++ b/responsiveslides.min.js @@ -1,6 +1,5 @@ /*! http://responsive-slides.viljamis.com v1.23 by @viljamis */ -(function(c,B,t){c.fn.responsiveSlides=function(e){var b=c.extend({auto:!0,speed:1E3,timeout:4E3,pager:!1,nav:!1,prevText:"Previous",nextText:"Next",maxwidth:"",controls:"",namespace:"rslides"},e);return this.each(function(){t++;var d=c(this),l,o,p,u,m,k=0,f=d.children(),v=f.size(),w=parseFloat(b.speed),g=b.namespace,h=g+t,i=g+"_nav "+h+"_nav",q=g+"_here",j=h+"_on",x=h+"_s",n=c("