diff --git a/dist/jquery.magnify.css b/dist/jquery.magnify.css index c3c9b24..3b411d0 100644 --- a/dist/jquery.magnify.css +++ b/dist/jquery.magnify.css @@ -6,7 +6,7 @@ * | | | | _ | \_/ | |\ |_| |_| | | | * |__| |__|__| |__|\____/|_|__| \__|_____|__| |__| * - * jquery.magnify - v1.4.2 + * jquery.magnify - v1.4.3 * A jQuery plugin to view images just like in windows * https://github.com/nzbin/magnify#readme * @@ -179,6 +179,7 @@ border-style: solid; border-color: rgba(0, 0, 0, 0.5) rgba(0, 0, 0, 0.5) rgba(0, 0, 0, 0.5) rgba(255, 255, 255, 0.5); border-radius: 100%; + vertical-align: middle; -webkit-animation: magnifyLoading 1s infinite linear; animation: magnifyLoading 1s infinite linear; } diff --git a/dist/jquery.magnify.js b/dist/jquery.magnify.js index 99bef1a..52d8943 100644 --- a/dist/jquery.magnify.js +++ b/dist/jquery.magnify.js @@ -6,7 +6,7 @@ * | | | | _ | \_/ | |\ |_| |_| | | | * |__| |__|__| |__|\____/|_|__| \__|_____|__| |__| * - * jquery.magnify - v1.4.2 + * jquery.magnify - v1.4.3 * A jQuery plugin to view images just like in windows * https://github.com/nzbin/magnify#readme * @@ -566,7 +566,7 @@ Magnify.prototype = { } }, - _creatBtns: function (toolbar, btns) { + _createBtns: function (toolbar, btns) { var btnsStr = ''; @@ -577,10 +577,10 @@ Magnify.prototype = { return btnsStr; }, - _creatTitle: function () { + _createTitle: function () { return (this.options.title ? '
' : ''); }, - creatDOM: function () { + render: function () { var btnsTpl = { minimize: '",maximize:'",close:'",zoomIn:'",zoomOut:'",prev:'",next:'",fullscreen:'",actualSize:'",rotateLeft:'",rotateRight:'"};return'
'+this._creatBtns(this.options.headToolbar,t)+"
"+this._creatTitle()+'
"},build:function(){var t=this.creatDOM(),i=Y(t);this.$magnify=i,this.$header=i.find(".magnify-header"),this.$headToolbar=i.find(".magnify-head-toolbar"),this.$footer=i.find(".magnify-footer"),this.$footToolbar=i.find(".magnify-foot-toolbar"),this.$stage=i.find(".magnify-stage"),this.$title=i.find(".magnify-title"),this.$image=i.find(".magnify-image"),this.$close=i.find(".magnify-button-close"),this.$maximize=i.find(".magnify-button-maximize"),this.$minimize=i.find(".magnify-button-minimize"),this.$zoomIn=i.find(".magnify-button-zoom-in"),this.$zoomOut=i.find(".magnify-button-zoom-out"),this.$actualSize=i.find(".magnify-button-actual-size"),this.$fullscreen=i.find(".magnify-button-fullscreen"),this.$rotateLeft=i.find(".magnify-button-rotate-left"),this.$rotateRight=i.find(".magnify-button-rotate-right"),this.$prev=i.find(".magnify-button-prev"),this.$next=i.find(".magnify-button-next"),this.$stage.addClass("stage-ready"),this.$image.addClass("image-ready"),this.$magnify.css("z-index",M.zIndex),this.options.dragHandle&&".magnify-modal"!==this.options.dragHandle?this.dragHandle=this.$magnify.find(this.options.dragHandle):this.dragHandle=this.$magnify},open:function(){if(this.options.multiInstances||Y(".magnify-modal").eq(0).remove(),!Y(".magnify-modal").length&&this.options.fixedContent&&(Y("html").css({overflow:"hidden"}),document.body.scrollHeight>(window.innerHeight||document.documentElement.clientHeight))){var t=function(){var t=document.createElement("div");t.style.cssText="width: 99px; height: 99px; overflow: scroll; position: absolute; top: -9999px;",document.body.appendChild(t);var i=t.offsetWidth-t.clientWidth;return document.body.removeChild(t),i}();t&&Y("html").css({"padding-right":t})}this.build(),this._triggerHook("beforeOpen",this.$el),Y("body").append(this.$magnify),this.addEvents(),this.setModalPos(this.$magnify),this._triggerHook("opened",this.$el)},close:function(t){this._triggerHook("beforeClose",this.$el),this.$magnify.remove(),this.isOpened=!1,this.isMaximized=!1,this.isRotated=!1,this.rotateAngle=0;var i=!Y(".magnify-modal").length;i&&this.options.fixedContent&&Y("html").css({overflow:"","padding-right":""}),i&&this.options.multiInstances&&(M.zIndex=this.options.zIndex),Y(".magnify-modal").length||(b.off(s+$),f.off(a+$)),this._triggerHook("closed",this.$el)},setModalPos:function(t){var i=f.width(),e=f.height(),a=b.scrollLeft(),s=b.scrollTop(),o=this.options.modalWidth,n=this.options.modalHeight;this.options.initMaximized?(t.addClass("magnify-maximize"),t.css({width:"100%",height:"100%",left:0,top:0}),this.isOpened=!0,this.isMaximized=!0):t.css({width:o,height:n,left:(i-o)/2+a+"px",top:(e-n)/2+s+"px"})},setModalSize:function(t){var i=this,e=f.width(),a=f.height(),s=b.scrollLeft(),o=b.scrollTop(),n={left:this.$stage.css("left"),right:this.$stage.css("right"),top:this.$stage.css("top"),bottom:this.$stage.css("bottom"),borderLeft:this.$stage.css("border-left-width"),borderRight:this.$stage.css("border-right-width"),borderTop:this.$stage.css("border-top-width"),borderBottom:this.$stage.css("border-bottom-width")},h=t.width+parseFloat(n.left)+parseFloat(n.right)+parseFloat(n.borderLeft)+parseFloat(n.borderRight),r=t.height+parseFloat(n.top)+parseFloat(n.bottom)+parseFloat(n.borderTop)+parseFloat(n.borderBottom),l=(0'),this.$stage.addClass("stage-ready"),this.$image.addClass("image-ready"),this.$image.removeAttr("style").attr("src",""),this.isRotated=!1,this.rotateAngle=0,this.options.initAnimation&&!this.options.progressiveLoading&&this.$image.hide(),B()?this.$stage.html(''):this.$image.attr("src",t),a=t,s=function(t){h.img=t,h.imageData={originalWidth:t.width,originalHeight:t.height},h.isMaximized||h.isOpened&&h.options.fixedModalPos?h.setImageSize(t):h.setModalSize(t),i&&i.call()},o=function(){h.$magnify.find(".magnify-loader").remove(),e&&e.call()},(n=new Image).onload=function(){s(n)},n.onerror=function(){o(n)},n.src=a,this.options.title&&this.setImgTitle(t)},getImgGroup:function(t,a){var s=this;s.groupData=[],Y(t).each(function(t,i){var e=o(this);s.groupData.push({src:e,caption:Y(this).attr("data-caption")}),a===e&&(s.groupIndex=t)})},setImgTitle:function(t){var i=this.groupIndex,e=(e=this.groupData[i].caption)||t.replace(/^.*?\/*([^/?]*)\.[a-z]+(\?.+|$)/gi,"$1");this.$title.html(e)},jump:function(t){this._triggerHook("beforeChange",this.groupIndex),this.groupIndex=this.groupIndex+t,this.jumpTo(this.groupIndex)},jumpTo:function(t){var i=this;0<=(t%=this.groupData.length)?t%=this.groupData.length:t<0&&(t=(this.groupData.length+t)%this.groupData.length),this.groupIndex=t,this.loadImg(this.groupData[t].src,function(){i._triggerHook("changed",t)},function(){i._triggerHook("changed",t)})},wheel:function(t){t.preventDefault();var i=1;t.originalEvent.deltaY?i=0this.options.maxRatio||t'),i=Y('
'),e=Y('
'),a=Y('
'),s=Y('
'),o=Y('
'),n=Y('
'),h=Y('
'),r={e:t,s:e,se:s,n:a,w:i,nw:h,ne:n,sw:o};Y(C).append(t,i,e,a,s,o,n,h);var O=!1,H=0,R=0,j={w:0,h:0,l:0,t:0},k={w:0,h:0,l:0,t:0},l={w:0,h:0,l:0,t:0},q=0,L=0,A=0,P="",g=function(t){(t=t||window.event).preventDefault();var i,e,a,s,o,n,h,r,l,g,m,c,d,f,p,u,v,y,_,b=B()?Y(S).find(D):Y(D);if(O&&!E.isMaximized){var x="touchmove"===t.type?t.originalEvent.targetTouches[0].pageX:t.clientX,w="touchmove"===t.type?t.originalEvent.targetTouches[0].pageY:t.clientY,z=x-H,$=w-R,M=(p=P,v=$,y=-(u=z)+j.w>I?u+j.l:j.l+j.w-I,_=-v+j.h>W?v+j.t:j.t+j.h-W,{e:{width:Math.max(u+j.w,I)+"px"},s:{height:Math.max(v+j.h,W)+"px"},se:{width:Math.max(u+j.w,I)+"px",height:Math.max(v+j.h,W)+"px"},w:{width:Math.max(-u+j.w,I)+"px",left:y+"px"},n:{height:Math.max(-v+j.h,W)+"px",top:_+"px"},nw:{width:Math.max(-u+j.w,I)+"px",height:Math.max(-v+j.h,W)+"px",top:_+"px",left:y+"px"},ne:{width:Math.max(u+j.w,I)+"px",height:Math.max(-v+j.h,W)+"px",top:_+"px"},sw:{width:Math.max(-u+j.w,I)+"px",height:Math.max(v+j.h,W)+"px",left:y+"px"}}[p]);Y(C).css(M);var T=(i=P,e=z,a=$,s=B()?Y(S).find(D):Y(D),o=B()?s.position().left+q:s.position().left,n=B()?s.position().top-q:s.position().top,h=e+j.w>I?k.w-L+e-q:I-(j.w-k.w)-L-q,r=a+j.h>W?k.h-A+a+q:W-(j.h-k.h)-A+q,l=-e+j.w>I?k.w-L-e-q:I-(j.w-k.w)-L-q,g=-a+j.h>W?k.h-A-a+q:W-(j.h-k.h)-A+q,m=(0this._parameters.duration;if(i&&!this._parameters.animatedGif)clearTimeout(this._timer);else{if(this._canvas||this._vimage||this._img){var e=this._parameters.easing(0,t-this._animateStartTime,this._animateStartAngle,this._parameters.animateTo-this._animateStartAngle,this._parameters.duration);this._rotate(~~(10*e)/10)}this._parameters.step&&this._parameters.step(this._angle);var a=this;this._timer=setTimeout(function(){a._animate.call(a)},10)}this._parameters.callback&&i&&(this._angle=this._parameters.animateTo,this._rotate(this._angle),this._parameters.callback.call(this._rootObj))},_rotate:(df=Math.PI/180,IE?function(t){this._angle=t,this._container.style.rotation=t%360+"deg",this._vimage.style.top=-(this._rotationCenterY-this._imgHeight/2)+"px",this._vimage.style.left=-(this._rotationCenterX-this._imgWidth/2)+"px",this._container.style.top=this._rotationCenterY-this._imgHeight/2+"px",this._container.style.left=this._rotationCenterX-this._imgWidth/2+"px"}:supportedCSS?function(t){this._angle=t,this._img.style[supportedCSS]="rotate("+t%360+"deg)",this._img.style[supportedCSSOrigin]=this._parameters.center.join(" ")}:function(t){t=(this._angle=t)%360*df,this._canvas.width=this._width,this._canvas.height=this._height,this._cnv.translate(this._imgWidth*this._aspectW,this._imgHeight*this._aspectH),this._cnv.translate(this._rotationCenterX,this._rotationCenterY),this._cnv.rotate(t),this._cnv.translate(-this._rotationCenterX,-this._rotationCenterY),this._cnv.scale(this._aspectW,this._aspectH),this._cnv.drawImage(this._img,0,0)})},IE&&(Wilq32.PhotoEffect.prototype.createVMLNode=function(){document.createStyleSheet().addRule(".rvml","behavior:url(#default#VML)");try{return!document.namespaces.rvml&&document.namespaces.add("rvml","urn:schemas-microsoft-com:vml"),function(t){return document.createElement("')}}catch(t){return function(t){return document.createElement("<"+t+' xmlns="urn:schemas-microsoft.com:vml" class="rvml">')}}}())}(jQuery); \ No newline at end of file +!function(t){"function"==typeof define&&define.amd?define(["jquery"],t):"object"==typeof exports?t(require("jquery")):t(jQuery)}(function(C){"use strict";function o(t){return C(t).attr("data-src")?C(t).attr("data-src"):C(t).attr("href")}function S(t,i,e,a){var s=a?t.h:t.w,o=a?t.w:t.h;(o>i.h||s>i.w)&&e.addClass("is-grab"),o<=i.h&&s<=i.w&&e.removeClass("is-grab")}function t(){return!!("ontouchstart"in window||window.DocumentTouch&&document instanceof DocumentTouch)}function D(){return"Microsoft Internet Explorer"==navigator.appName&&0 ',maximize:' ',close:' ',zoomIn:' ',zoomOut:' ',prev:' ',next:' ',fullscreen:' ',actualSize:' ',rotateLeft:' ',rotateRight:' '},i18n:{minimize:"minimize",maximize:"maximize",close:"close",zoomIn:"zoom-in(+)",zoomOut:"zoom-out(-)",prev:"prev(←)",next:"next(→)",fullscreen:"fullscreen",actualSize:"actual-size(Ctrl+Alt+0)",rotateLeft:"rotate-left(Ctrl+,)",rotateRight:"rotate-right(Ctrl+.)"},multiInstances:!0,initEvent:"click",initAnimation:!0,fixedModalPos:!1,zIndex:1090,dragHandle:!1,callbacks:{beforeOpen:C.noop,opened:C.noop,beforeClose:C.noop,closed:C.noop,beforeChange:C.noop,changed:C.noop},progressiveLoading:!0},R={isMoving:!1,isResizing:!1,zIndex:r.zIndex},l=null;a.prototype={init:function(t,i){var e=o(t);this.groupName=null;var a=C(t).attr("data-group"),s=I.find('[data-group="'+a+'"]');void 0!==a?(this.groupName=a,this.getImgGroup(s,e)):this.getImgGroup(l.not("[data-group]"),e),this.open(),this.loadImg(e),i.draggable&&this.draggable(this.$magnify,this.dragHandle,".magnify-button"),i.movable&&this.movable(this.$stage,D()?".magnify-image":this.$image),i.resizable&&this.resizable(this.$magnify,this.$stage,D()?".magnify-image":this.$image,i.modalWidth,i.modalHeight)},_createBtns:function(t,e){var a="";return C.each(t,function(t,i){a+=e[i]}),a},_createTitle:function(){return this.options.title?'
':""},render:function(){var t={minimize:'",maximize:'",close:'",zoomIn:'",zoomOut:'",prev:'",next:'",fullscreen:'",actualSize:'",rotateLeft:'",rotateRight:'"};return'
'+this._createBtns(this.options.headToolbar,t)+"
"+this._createTitle()+'
"},build:function(){var t=this.render(),i=C(t);this.$magnify=i,this.$header=i.find(".magnify-header"),this.$headToolbar=i.find(".magnify-head-toolbar"),this.$footer=i.find(".magnify-footer"),this.$footToolbar=i.find(".magnify-foot-toolbar"),this.$stage=i.find(".magnify-stage"),this.$title=i.find(".magnify-title"),this.$image=i.find(".magnify-image"),this.$close=i.find(".magnify-button-close"),this.$maximize=i.find(".magnify-button-maximize"),this.$minimize=i.find(".magnify-button-minimize"),this.$zoomIn=i.find(".magnify-button-zoom-in"),this.$zoomOut=i.find(".magnify-button-zoom-out"),this.$actualSize=i.find(".magnify-button-actual-size"),this.$fullscreen=i.find(".magnify-button-fullscreen"),this.$rotateLeft=i.find(".magnify-button-rotate-left"),this.$rotateRight=i.find(".magnify-button-rotate-right"),this.$prev=i.find(".magnify-button-prev"),this.$next=i.find(".magnify-button-next"),this.$stage.addClass("stage-ready"),this.$image.addClass("image-ready"),this.$magnify.css("z-index",R.zIndex),this.options.dragHandle&&".magnify-modal"!==this.options.dragHandle?this.dragHandle=this.$magnify.find(this.options.dragHandle):this.dragHandle=this.$magnify},open:function(){if(this.options.multiInstances||C(".magnify-modal").eq(0).remove(),!C(".magnify-modal").length&&this.options.fixedContent&&(C("html").css({overflow:"hidden"}),document.body.scrollHeight>(window.innerHeight||document.documentElement.clientHeight))){var t=function(){var t=document.createElement("div");t.style.cssText="width: 99px; height: 99px; overflow: scroll; position: absolute; top: -9999px;",document.body.appendChild(t);var i=t.offsetWidth-t.clientWidth;return document.body.removeChild(t),i}();t&&C("html").css({"padding-right":t})}this.build(),this._triggerHook("beforeOpen",this.$el),C("body").append(this.$magnify),this.addEvents(),this.setModalPos(this.$magnify),this._triggerHook("opened",this.$el)},close:function(t){this._triggerHook("beforeClose",this.$el),this.$magnify.remove(),this.isOpened=!1,this.isMaximized=!1,this.isRotated=!1,this.rotateAngle=0;var i=!C(".magnify-modal").length;i&&this.options.fixedContent&&C("html").css({overflow:"","padding-right":""}),i&&this.options.multiInstances&&(R.zIndex=this.options.zIndex),C(".magnify-modal").length||(I.off(n+H),f.off(s+H)),this._triggerHook("closed",this.$el)},setModalPos:function(t){var i=f.width(),e=f.height(),a=I.scrollLeft(),s=I.scrollTop(),o=this.options.modalWidth,n=this.options.modalHeight;this.options.initMaximized?(t.addClass("magnify-maximize"),t.css({width:"100%",height:"100%",left:0,top:0}),this.isOpened=!0,this.isMaximized=!0):t.css({width:o,height:n,left:(i-o)/2+a+"px",top:(e-n)/2+s+"px"})},setModalSize:function(t){var i=this,e=f.width(),a=f.height(),s=I.scrollLeft(),o=I.scrollTop(),n={left:this.$stage.css("left"),right:this.$stage.css("right"),top:this.$stage.css("top"),bottom:this.$stage.css("bottom"),borderLeft:this.$stage.css("border-left-width"),borderRight:this.$stage.css("border-right-width"),borderTop:this.$stage.css("border-top-width"),borderBottom:this.$stage.css("border-bottom-width")},h=t.width+parseFloat(n.left)+parseFloat(n.right)+parseFloat(n.borderLeft)+parseFloat(n.borderRight),r=t.height+parseFloat(n.top)+parseFloat(n.bottom)+parseFloat(n.borderTop)+parseFloat(n.borderBottom),l=(0'),this.$stage.addClass("stage-ready"),this.$image.addClass("image-ready"),this.options.initAnimation&&!this.options.progressiveLoading&&this.$image.hide(),D()?this.$stage.html(''):this.$image.attr("src",t),function(t,i,e){var a=new Image;a.onload=function(){i(a)},a.onerror=function(){e(a)},a.src=t}(t,function(t){a.img=t,a.imageData={originalWidth:t.width,originalHeight:t.height},a.isMaximized||a.isOpened&&a.options.fixedModalPos?a.setImageSize(t):a.setModalSize(t),i&&i.call()},function(){a.$magnify.find(".magnify-loader").remove(),e&&e.call()}),this.options.title&&this.setImgTitle(t)},getImgGroup:function(t,a){var s=this;s.groupData=[],C(t).each(function(t,i){var e=o(this);s.groupData.push({src:e,caption:C(this).attr("data-caption")}),a===e&&(s.groupIndex=t)})},setImgTitle:function(t){var i=this.groupIndex,e=(e=this.groupData[i].caption)||function(t){return t.replace(/^.*?\/*([^/?]*)\.[a-z]+(\?.+|$)/gi,"$1")}(t);this.$title.html(e)},jump:function(t){this._triggerHook("beforeChange",this.groupIndex),this.groupIndex=this.groupIndex+t,this.jumpTo(this.groupIndex)},jumpTo:function(t){var i=this;0<=(t%=this.groupData.length)?t%=this.groupData.length:t<0&&(t=(this.groupData.length+t)%this.groupData.length),this.groupIndex=t,this.loadImg(this.groupData[t].src,function(){i._triggerHook("changed",t)},function(){i._triggerHook("changed",t)})},wheel:function(t){t.preventDefault();var i=1;t.originalEvent.deltaY?i=0this.options.maxRatio||t'),i=C('
'),e=C('
'),a=C('
'),s=C('
'),o=C('
'),n=C('
'),h=C('
'),g={e:t,s:e,se:s,n:a,w:i,nw:h,ne:n,sw:o};C(r).append(t,i,e,a,s,o,n,h);var m=!1,c=0,d=0,y={w:0,h:0,l:0,t:0},_={w:0,h:0,l:0,t:0},b={w:0,h:0,l:0,t:0},x=0,w=0,z=0,$="",M=function(t){(t=t||window.event).preventDefault();var i=D()?C(f).find(p):C(p);if(m&&!l.isMaximized){var e="touchmove"===t.type?t.originalEvent.targetTouches[0].pageX:t.clientX,a="touchmove"===t.type?t.originalEvent.targetTouches[0].pageY:t.clientY,s=e-c,o=a-d,n=function(t,i,e){var a=-i+y.w>u?i+y.l:y.l+y.w-u,s=-e+y.h>v?e+y.t:y.t+y.h-v;return{e:{width:Math.max(i+y.w,u)+"px"},s:{height:Math.max(e+y.h,v)+"px"},se:{width:Math.max(i+y.w,u)+"px",height:Math.max(e+y.h,v)+"px"},w:{width:Math.max(-i+y.w,u)+"px",left:a+"px"},n:{height:Math.max(-e+y.h,v)+"px",top:s+"px"},nw:{width:Math.max(-i+y.w,u)+"px",height:Math.max(-e+y.h,v)+"px",top:s+"px",left:a+"px"},ne:{width:Math.max(i+y.w,u)+"px",height:Math.max(-e+y.h,v)+"px",top:s+"px"},sw:{width:Math.max(-i+y.w,u)+"px",height:Math.max(e+y.h,v)+"px",left:a+"px"}}[t]}($,s,o);C(r).css(n);var h=function(t,i,e){var a=D()?C(f).find(p):C(p),s=D()?a.position().left+x:a.position().left,o=D()?a.position().top-x:a.position().top,n=i+y.w>u?_.w-w+i-x:u-(y.w-_.w)-w-x,h=e+y.h>v?_.h-z+e+x:v-(y.h-_.h)-z+x,r=-i+y.w>u?_.w-w-i-x:u-(y.w-_.w)-w-x,l=-e+y.h>v?_.h-z-e+x:v-(y.h-_.h)-z+x,g=(0this._parameters.duration;if(i&&!this._parameters.animatedGif)clearTimeout(this._timer);else{if(this._canvas||this._vimage||this._img){var e=this._parameters.easing(0,t-this._animateStartTime,this._animateStartAngle,this._parameters.animateTo-this._animateStartAngle,this._parameters.duration);this._rotate(~~(10*e)/10)}this._parameters.step&&this._parameters.step(this._angle);var a=this;this._timer=setTimeout(function(){a._animate.call(a)},10)}this._parameters.callback&&i&&(this._angle=this._parameters.animateTo,this._rotate(this._angle),this._parameters.callback.call(this._rootObj))},_rotate:(cf=Math.PI/180,IE?function(t){this._angle=t,this._container.style.rotation=t%360+"deg",this._vimage.style.top=-(this._rotationCenterY-this._imgHeight/2)+"px",this._vimage.style.left=-(this._rotationCenterX-this._imgWidth/2)+"px",this._container.style.top=this._rotationCenterY-this._imgHeight/2+"px",this._container.style.left=this._rotationCenterX-this._imgWidth/2+"px"}:supportedCSS?function(t){this._angle=t,this._img.style[supportedCSS]="rotate("+t%360+"deg)",this._img.style[supportedCSSOrigin]=this._parameters.center.join(" ")}:function(t){t=(this._angle=t)%360*cf,this._canvas.width=this._width,this._canvas.height=this._height,this._cnv.translate(this._imgWidth*this._aspectW,this._imgHeight*this._aspectH),this._cnv.translate(this._rotationCenterX,this._rotationCenterY),this._cnv.rotate(t),this._cnv.translate(-this._rotationCenterX,-this._rotationCenterY),this._cnv.scale(this._aspectW,this._aspectH),this._cnv.drawImage(this._img,0,0)})},IE&&(Wilq32.PhotoEffect.prototype.createVMLNode=function(){document.createStyleSheet().addRule(".rvml","behavior:url(#default#VML)");try{return document.namespaces.rvml||document.namespaces.add("rvml","urn:schemas-microsoft-com:vml"),function(t){return document.createElement("')}}catch(t){return function(t){return document.createElement("<"+t+' xmlns="urn:schemas-microsoft.com:vml" class="rvml">')}}}())}(jQuery); \ No newline at end of file diff --git a/docs/css/jquery.magnify.css b/docs/css/jquery.magnify.css index c3c9b24..3b411d0 100644 --- a/docs/css/jquery.magnify.css +++ b/docs/css/jquery.magnify.css @@ -6,7 +6,7 @@ * | | | | _ | \_/ | |\ |_| |_| | | | * |__| |__|__| |__|\____/|_|__| \__|_____|__| |__| * - * jquery.magnify - v1.4.2 + * jquery.magnify - v1.4.3 * A jQuery plugin to view images just like in windows * https://github.com/nzbin/magnify#readme * @@ -179,6 +179,7 @@ border-style: solid; border-color: rgba(0, 0, 0, 0.5) rgba(0, 0, 0, 0.5) rgba(0, 0, 0, 0.5) rgba(255, 255, 255, 0.5); border-radius: 100%; + vertical-align: middle; -webkit-animation: magnifyLoading 1s infinite linear; animation: magnifyLoading 1s infinite linear; } diff --git a/docs/js/jquery.magnify.js b/docs/js/jquery.magnify.js index 99bef1a..52d8943 100644 --- a/docs/js/jquery.magnify.js +++ b/docs/js/jquery.magnify.js @@ -6,7 +6,7 @@ * | | | | _ | \_/ | |\ |_| |_| | | | * |__| |__|__| |__|\____/|_|__| \__|_____|__| |__| * - * jquery.magnify - v1.4.2 + * jquery.magnify - v1.4.3 * A jQuery plugin to view images just like in windows * https://github.com/nzbin/magnify#readme * @@ -566,7 +566,7 @@ Magnify.prototype = { } }, - _creatBtns: function (toolbar, btns) { + _createBtns: function (toolbar, btns) { var btnsStr = ''; @@ -577,10 +577,10 @@ Magnify.prototype = { return btnsStr; }, - _creatTitle: function () { + _createTitle: function () { return (this.options.title ? '
' : ''); }, - creatDOM: function () { + render: function () { var btnsTpl = { minimize: '