From 6e1ffa238d2c6da828beef56a5265b959807583e Mon Sep 17 00:00:00 2001 From: Hannes Papenberg Date: Thu, 19 Mar 2026 10:00:22 +0100 Subject: [PATCH] Update iviewer to latest version and optimise repo --- .drone.yml | 4 +- css/jquery.iviewer.css | 18 ++++---- images/grab.cur | Bin 0 -> 1150 bytes images/hand.cur | Bin 0 -> 1150 bytes .../iviewer.rotate_left.png | Bin .../iviewer.rotate_right.png | Bin {img/iviewer => images}/iviewer.zoom_fit.png | Bin {img/iviewer => images}/iviewer.zoom_in.png | Bin {img/iviewer => images}/iviewer.zoom_out.png | Bin {img/iviewer => images}/iviewer.zoom_zero.png | Bin {img => images}/loader.gif | Bin img/glyphicons-halflings-white.png | Bin 4352 -> 0 bytes img/glyphicons-halflings.png | Bin 4352 -> 0 bytes img/iviewer/grab.cur | 0 img/iviewer/hand.cur | 0 img/iviewer/iviewer.zoom_fit2.gif | Bin 95 -> 0 bytes img/iviewer/iviewer.zoom_in2.gif | Bin 90 -> 0 bytes img/iviewer/iviewer.zoom_out2.gif | Bin 69 -> 0 bytes img/iviewer/iviewer.zoom_zero2.gif | Bin 98 -> 0 bytes js/jquery.iviewer.min.js | 39 +++--------------- 20 files changed, 16 insertions(+), 45 deletions(-) create mode 100644 images/grab.cur create mode 100644 images/hand.cur rename {img/iviewer => images}/iviewer.rotate_left.png (100%) rename {img/iviewer => images}/iviewer.rotate_right.png (100%) rename {img/iviewer => images}/iviewer.zoom_fit.png (100%) rename {img/iviewer => images}/iviewer.zoom_in.png (100%) rename {img/iviewer => images}/iviewer.zoom_out.png (100%) rename {img/iviewer => images}/iviewer.zoom_zero.png (100%) rename {img => images}/loader.gif (100%) delete mode 100644 img/glyphicons-halflings-white.png delete mode 100644 img/glyphicons-halflings.png delete mode 100644 img/iviewer/grab.cur delete mode 100644 img/iviewer/hand.cur delete mode 100644 img/iviewer/iviewer.zoom_fit2.gif delete mode 100644 img/iviewer/iviewer.zoom_in2.gif delete mode 100644 img/iviewer/iviewer.zoom_out2.gif delete mode 100644 img/iviewer/iviewer.zoom_zero2.gif diff --git a/.drone.yml b/.drone.yml index 2356f8c..52310b6 100644 --- a/.drone.yml +++ b/.drone.yml @@ -18,7 +18,7 @@ steps: from_secret: mattermost_nightly_hook commands: - mkdir build - - cp -r -v archived.html css/ images/ img/ js/ index.html results.html robots.txt 403.html 404.html .htaccess ./build + - cp -r -v archived.html css/ fonts/ images/ js/ index.html results.html robots.txt 403.html 404.html .htaccess ./build .well-known/ - mkdir -p ~/.ssh - eval $(ssh-agent -s) - echo -e "Host *\n\tStrictHostKeyChecking no\n\n" > ~/.ssh/config @@ -143,6 +143,6 @@ trigger: --- kind: signature -hmac: a002e30e04f1c87e97ac1d7ca091e3a71f5d958b15cb162c91a2e6200701f48b +hmac: effbd7d9d4bcc398c1bbbeb859ee869432f0c2efec2c4601e0424143bbeef3f4 ... diff --git a/css/jquery.iviewer.css b/css/jquery.iviewer.css index d68c642..c529fd8 100644 --- a/css/jquery.iviewer.css +++ b/css/jquery.iviewer.css @@ -7,11 +7,11 @@ } .iviewer_cursor { - cursor: url(../img/iviewer/hand.cur) 6 8, pointer; + cursor: url(../images/hand.cur) 6 8, pointer; } .iviewer_drag_cursor { - cursor: url(../img/iviewer/grab.cur) 6 8, pointer; + cursor: url(../images/grab.cur) 6 8, pointer; } .iviewer_button { @@ -23,22 +23,22 @@ .iviewer_zoom_in { left: 20px; - background: url(../img/iviewer/iviewer.zoom_in.png); + background: url(../images/iviewer.zoom_in.png); } .iviewer_zoom_out { left: 55px; - background: url(../img/iviewer/iviewer.zoom_out.png); + background: url(../images/iviewer.zoom_out.png); } .iviewer_zoom_zero { left: 90px; - background: url(../img/iviewer/iviewer.zoom_zero.png); + background: url(../images/iviewer.zoom_zero.png); } .iviewer_zoom_fit { left: 125px; - background: url(../img/iviewer/iviewer.zoom_fit.png); + background: url(../images/iviewer.zoom_fit.png); } .iviewer_zoom_status { @@ -52,12 +52,12 @@ .iviewer_rotate_left { left: 227px; - background: #fff url(../img/iviewer/iviewer.rotate_left.png) center center no-repeat; + background: #fff url(../images/iviewer.rotate_left.png) center center no-repeat; } .iviewer_rotate_right { left: 262px; - background: #fff url(../img/iviewer/iviewer.rotate_right.png) center center no-repeat; + background: #fff url(../images/iviewer.rotate_right.png) center center no-repeat; } .viewer @@ -65,7 +65,7 @@ width: 100%; height: 500px; position: relative; - background: transparent url('../img/loader.gif') no-repeat center center; + background: transparent url('../images/loader.gif') no-repeat center center; } .viewer img diff --git a/images/grab.cur b/images/grab.cur new file mode 100644 index 0000000000000000000000000000000000000000..ef540be09383a215ba21287683ae956b74a6dbbf GIT binary patch literal 1150 zcmeHEF%H8Z3_L;+LM2k9N*yv~>~H#wK9i4B>Jy?)*;1Rr5Mf~HSVzWizBA$iDEg)e zv@Up@fGdC-B|(IIaVjw`XMnR4do4(}ceLED$#?I4PhZt?V;F{(zNyX4aU6>oTI<~I zR%1+|Z@pO>D9unx@mz^sV2R6KAHrH&a3w(Uah_+1dcf$ic$W0J$AsEGc`x}F-{G8# oT0W#ZA~$;zN&n?%4r~@-v(K$0B;Q#;t literal 0 HcmV?d00001 diff --git a/images/hand.cur b/images/hand.cur new file mode 100644 index 0000000000000000000000000000000000000000..1a5bafb5263fd4937dda4098b04aa5c70e2de924 GIT binary patch literal 1150 zcma)3OKyWe4E694LIn}22q6~8?0U4`qB$BzVUYuLnN^5A#g-vqrbZ8co}UNC0FIu^ z1?Y|NodI+J@I{~!RsQPaynTKEFe0{|*)R-iM9cJuPktQ*F&}vmxJX7;nU}sFz)ZF&&*%FGe4jtO*5mbhJzhV&et11z&&^B?xH$MZ007{+ZK!Jj01(PQ zJBFS4pH$0DefCd1HM@h*JNkcsi%oOXzj>qsEle$eQ7ApHL(XYdn5Y$Lk_3-J9p9d) zFeVfl3J47_g1XaoDXWsnBp9ZzZ74CI9RN-Nw{>+8A&#rBpZgc9WX2H3Ssv6doZP?t zS!g}lGvW1<9%?dj_G_x}3WUMN(8(x{a6_pd0yiUsf^67GGS50uS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5o^flxcEGJRDAZjOjF zQ0Iea%DG$E3bP&!(93|2RCY3l5t3s3J*JOik0=hGeaJ@3@H8tD7CVRqHg&`+R3j0a8@kqB}PI}{$m!yRab zvul5lL(>3*TF>n~)*#hsmwUTtKRAA2Fnk0PENdI!9GrZLu@zyKzs+&m-IKFviqv>& kg1Lm#gqI~e;$iYPkmG5c&N-g{UI@TVLkokN>#mRg2V?7pi2wiq diff --git a/img/iviewer/grab.cur b/img/iviewer/grab.cur deleted file mode 100644 index e69de29..0000000 diff --git a/img/iviewer/hand.cur b/img/iviewer/hand.cur deleted file mode 100644 index e69de29..0000000 diff --git a/img/iviewer/iviewer.zoom_fit2.gif b/img/iviewer/iviewer.zoom_fit2.gif deleted file mode 100644 index 3199a1e3e1f6c2c9e189a4718ac3e7fee5204dcc..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 95 zcmZ?wbhEHblwpuzXkcUjg8%>j>wsvG2m_N{Pyfo(Z~3KXY?;^Pc&YH??aJsCHEo`3 w8eZ!(AMJatv3kpyYro>2$M)>r+u)qoRbjGiisBQYX$xZ(3D5f)$iQF?09S=3^#A|> diff --git a/img/iviewer/iviewer.zoom_in2.gif b/img/iviewer/iviewer.zoom_in2.gif deleted file mode 100644 index 5d596181627a30344f9783d466ce0558279fe729..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 90 zcmZ?wbhEHblwpuzXkcUjg8%>j>wsvG2m_O4Pyfo(Z}}I`;fT1UbHL~G(^^jrxfIDc qOSLxju^l&BbLLyj{a>m(=kzlMwFoEmw|glD9`i8f>~-Q|um%7;9UyH0 diff --git a/img/iviewer/iviewer.zoom_out2.gif b/img/iviewer/iviewer.zoom_out2.gif deleted file mode 100644 index 77ec19af216c5525438e73e4fafef1ce08db3cf3..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 69 zcmZ?wbhEHblwpuzXkcUjg8%>j>wsvG2m_N!Pyfo(Z}}I`*>bCU^SwRQTrH10rZprj VQ(Lv|A^Y)9KG(nX7PB%~0{{a@8tMQ5 diff --git a/img/iviewer/iviewer.zoom_zero2.gif b/img/iviewer/iviewer.zoom_zero2.gif deleted file mode 100644 index e56c670fe62062458276fab5512701433b37af4e..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 98 zcmZ?wbhEHblwpuzXkcUjg8%>j>wsvG2m_O2Pyfo(Z}}I`*>bDfkfCt*S=$8WwkJC( z0?1:-1;me.zoom_by(zoom);return false}).prependTo(this.container);this.container.bind("mousemove",function(ev){me._handleMouseMove(ev)});this.loadImage(this.options.src);if(!this.options.ui_disabled)this.createui();this._mouseInit()},destroy:function(){this._mouseDestroy()}, -_updateContainerInfo:function(){this.options.height=this.container.height();this.options.width=this.container.width()},loadImage:function(src){this.current_zoom=this.options.zoom;var me=this;this._trigger("onStartLoad",0,src);this.img_object.load(src,function(){me.container.addClass("iviewer_cursor");if(me.options.zoom=="fit")me.fit(true);else me.set_zoom(me.options.zoom,true);if(me.options.onFinishLoad)me._trigger("onFinishLoad",0,src)})},fit:function(skip_animation){var aspect_ratio=this.img_object.orig_width()/ -this.img_object.orig_height();var window_ratio=this.options.width/this.options.height;var choose_left=aspect_ratio>window_ratio;var new_zoom=0;if(choose_left)new_zoom=this.options.width/this.img_object.orig_width()*100;else new_zoom=this.options.height/this.img_object.orig_height()*100;this.set_zoom(new_zoom,skip_animation)},center:function(){this.setCoords(-Math.round((this.img_object.display_width()-this.options.width)/2),-Math.round((this.img_object.display_height()-this.options.height)/2))},moveTo:function(x, -y){var dx=x-Math.round(this.options.width/2);var dy=y-Math.round(this.options.height/2);var new_x=this.img_object.x()-dx;var new_y=this.img_object.y()-dy;this.setCoords(new_x,new_y)},getContainerOffset:function(){return jQuery.extend({},this.container.offset())},setCoords:function(x,y){if(!this.img_object.loaded())return;var coords=this._correctCoords(x,y);this.img_object.x(coords.x);this.img_object.y(coords.y)},_correctCoords:function(x,y){x=parseInt(x,10);y=parseInt(y,10);if(y>0)y=0;if(x>0)x=0; -if(y+this.img_object.display_height()this.options.zoom_max)new_zoom=this.options.zoom_max;if(this.current_zoom=="fit"){var old_x=Math.round(this.options.width/2+this.img_object.orig_width()/2);var old_y=Math.round(this.options.height/2+this.img_object.orig_height()/2);this.current_zoom=100}else{var old_x= --this.img_object.x()+Math.round(this.options.width/2);var old_y=-this.img_object.y()+Math.round(this.options.height/2)}var new_width=util.scaleValue(this.img_object.orig_width(),new_zoom);var new_height=util.scaleValue(this.img_object.orig_height(),new_zoom);var new_x=util.scaleValue(util.descaleValue(old_x,this.current_zoom),new_zoom);var new_y=util.scaleValue(util.descaleValue(old_y,this.current_zoom),new_zoom);new_x=this.options.width/2-new_x;new_y=this.options.height/2-new_y;this.img_object.display_width(new_width); -this.img_object.display_height(new_height);var coords=this._correctCoords(new_x,new_y),self=this;this.img_object.setImageProps(new_width,new_height,coords.x,coords.y,skip_animation,function(){self._trigger("onAfterZoom",0,new_zoom)});this.current_zoom=new_zoom;this.update_status()},zoom_by:function(delta){var closest_rate=this.find_closest_zoom_rate(this.current_zoom);var next_rate=closest_rate+delta;var next_zoom=this.options.zoom_base*Math.pow(this.options.zoom_delta,next_rate);if(delta>0&&next_zoom< -this.current_zoom)next_zoom*=this.options.zoom_delta;if(delta<0&&next_zoom>this.current_zoom)next_zoom/=this.options.zoom_delta;this.set_zoom(next_zoom)},angle:function(deg,abs){if(arguments.length===0)return this.img_object.angle();if(deg<-270||deg>270||deg%90!==0)return;if(!abs)deg+=this.img_object.angle();if(deg<0)deg+=360;if(deg>=360)deg-=360;if(deg===this.img_object.angle())return;this.img_object.angle(deg);this.center();this._trigger("angle",0,{angle:this.img_object.angle()})},find_closest_zoom_rate:function(value){if(value== -this.options.zoom_base)return 0;function div(val1,val2){return val1/val2}function mul(val1,val2){return val1*val2}var func=value>this.options.zoom_base?mul:div;var sgn=value>this.options.zoom_base?1:-1;var mltplr=this.options.zoom_delta;var rate=1;while(Math.abs(func(this.options.zoom_base,Math.pow(mltplr,rate))-value)>Math.abs(func(this.options.zoom_base,Math.pow(mltplr,rate+1))-value))rate++;return sgn*rate},update_status:function(){if(!this.options.ui_disabled){var percent=Math.round(100*this.img_object.display_height()/ -this.img_object.orig_height());if(percent)this.zoom_object.html(percent+"%")}},info:function(param,withoutRotation){if(!param)return;switch(param){case "orig_width":case "orig_height":if(withoutRotation)return this.img_object.angle()%180===0?this.img_object[param]():param==="orig_width"?this.img_object.orig_height():this.img_object.orig_width();else return this.img_object[param]();case "display_width":case "display_height":case "angle":return this.img_object[param]();case "zoom":return this.current_zoom; -case "src":return this.img_object.object().attr("src")}},_mouseStart:function(e){$.ui.mouse.prototype._mouseStart.call(this,e);if(this._trigger("onStartDrag",0,this._getMouseCoords(e))===false)return false;this.container.addClass("iviewer_drag_cursor");this.dx=e.pageX-this.img_object.x();this.dy=e.pageY-this.img_object.y();return true},_mouseCapture:function(e){return true},_handleMouseMove:function(e){this._trigger("onMouseMove",e,this._getMouseCoords(e))},_mouseDrag:function(e){$.ui.mouse.prototype._mouseDrag.call(this, -e);var ltop=e.pageY-this.dy;var lleft=e.pageX-this.dx;this.setCoords(lleft,ltop);this._trigger("onDrag",e,this._getMouseCoords(e));return false},_mouseStop:function(e){$.ui.mouse.prototype._mouseStop.call(this,e);this.container.removeClass("iviewer_drag_cursor");this._trigger("onStopDrag",0,this._getMouseCoords(e))},_click:function(e){this._trigger("onClick",0,this._getMouseCoords(e))},createui:function(){var me=this;$("
",{"class":"iviewer_zoom_in iviewer_common iviewer_button"}).bind("mousedown touchstart", -function(){me.zoom_by(1);return false}).appendTo(this.container);$("
",{"class":"iviewer_zoom_out iviewer_common iviewer_button"}).bind("mousedown touchstart",function(){me.zoom_by(-1);return false}).appendTo(this.container);$("
",{"class":"iviewer_zoom_zero iviewer_common iviewer_button"}).bind("mousedown touchstart",function(){me.set_zoom(100);return false}).appendTo(this.container);$("
",{"class":"iviewer_zoom_fit iviewer_common iviewer_button"}).bind("mousedown touchstart",function(){me.fit(this); -return false}).appendTo(this.container);this.zoom_object=$("
").addClass("iviewer_zoom_status iviewer_common").appendTo(this.container);$("
",{"class":"iviewer_rotate_left iviewer_common iviewer_button"}).bind("mousedown touchstart",function(){me.angle(-90);return false}).appendTo(this.container);$("
",{"class":"iviewer_rotate_right iviewer_common iviewer_button"}).bind("mousedown touchstart",function(){me.angle(90);return false}).appendTo(this.container);this.update_status()}});$.ui.iviewer.ImageObject= -function(do_anim){this._img=$("").css({position:"absolute",top:"0px",left:"0px"});this._loaded=false;this._swapDimensions=false;this._do_anim=do_anim||false;this.x(0,true);this.y(0,true);this.angle(0)};(function(){this._reset=function(w,h){this._angle=0;this._swapDimensions=false;this.x(0);this.y(0);this.orig_width(w);this.orig_height(h);this.display_width(w);this.display_height(h)};this.loaded=function(){return this._loaded};this.load=function(src,loaded){var self=this;loaded=loaded||jQuery.noop; -this._loaded=false;var img=new Image;img.onload=function(){self._loaded=true;self._reset(this.width,this.height);self._img[0].src=src;loaded()};img.src=src;this._img.removeAttr("src").removeAttr("width").removeAttr("height").removeAttr("style").css({position:"absolute",top:"0px",left:"0px"});this.angle(0)};this._dimension=function(prefix,name){var horiz="_"+prefix+"_"+name,vert="_"+prefix+"_"+(name==="height"?"width":"height");return setter(function(val){this[this._swapDimensions?horiz:vert]=val}, -function(){return this[this._swapDimensions?horiz:vert]})};this.display_width=this._dimension("display","width"),this.display_height=this._dimension("display","height"),this.display_diff=function(){return Math.floor(this.display_width()-this.display_height())};this.orig_width=this._dimension("orig","width"),this.orig_height=this._dimension("orig","height"),this.x=setter(function(val,skipCss){this._x=val;if(!skipCss)this._img.css("left",this._x+(this._swapDimensions?this.display_diff()/2:0)+"px")}, -function(){return this._x});this.y=setter(function(val,skipCss){this._y=val;if(!skipCss)this._img.css("top",this._y-(this._swapDimensions?this.display_diff()/2:0)+"px")},function(){return this._y});this.angle=setter(function(deg){var prevSwap=this._swapDimensions;this._angle=deg;this._swapDimensions=deg%180!==0;if(prevSwap!==this._swapDimensions){var verticalMod=this._swapDimensions?-1:1;this.x(this.x()-verticalMod*this.display_diff()/2,true);this.y(this.y()+verticalMod*this.display_diff()/2,true)}var cssVal= -"rotate("+deg+"deg)",img=this._img;jQuery.each(["","-webkit-","-moz-","-o-","-ms-"],function(i,prefix){img.css(prefix+"transform",cssVal)});if(useIeTransforms){jQuery.each(["-ms-",""],function(i,prefix){img.css(prefix+"filter",ieTransforms[deg].filter)});img.css({marginLeft:ieTransforms[deg].marginLeft*this.display_diff()/2,marginTop:ieTransforms[deg].marginTop*this.display_diff()/2})}},function(){return this._angle});this.toOriginalCoords=function(point){switch(this.angle()){case 0:return{x:point.x, -y:point.y};case 90:return{x:point.y,y:this.display_width()-point.x};case 180:return{x:this.display_width()-point.x,y:this.display_height()-point.y};case 270:return{x:this.display_height()-point.y,y:point.x}}};this.toRealCoords=function(point){switch(this.angle()){case 0:return{x:this.x()+point.x,y:this.y()+point.y};case 90:return{x:this.x()+this.display_width()-point.y,y:this.y()+point.x};case 180:return{x:this.x()+this.display_width()-point.x,y:this.y()+this.display_height()-point.y};case 270:return{x:this.x()+ -point.y,y:this.y()+this.display_height()-point.x}}};this.object=setter(jQuery.noop,function(){return this._img});this.setImageProps=function(disp_w,disp_h,x,y,skip_animation,complete){complete=complete||jQuery.noop;this.display_width(disp_w);this.display_height(disp_h);this.x(x,true);this.y(y,true);var w=this._swapDimensions?disp_h:disp_w;var h=this._swapDimensions?disp_w:disp_h;var params={width:w,height:h,top:y-(this._swapDimensions?this.display_diff()/2:0)+"px",left:x+(this._swapDimensions?this.display_diff()/ -2:0)+"px"};if(useIeTransforms)jQuery.extend(params,{marginLeft:ieTransforms[this.angle()].marginLeft*this.display_diff()/2,marginTop:ieTransforms[this.angle()].marginTop*this.display_diff()/2});var swapDims=this._swapDimensions,img=this._img;if(useIeTransforms&&swapDims){var ieh=this._img.width(),iew=this._img.height(),iedh=params.height-ieh;iedw=params.width-iew;delete params.width;delete params.height}if(this._do_anim&&!skip_animation)this._img.animate(params,{duration:200,complete:complete,step:function(now, -fx){if(useIeTransforms&&swapDims&&fx.prop==="top"){var percent=(now-fx.start)/(fx.end-fx.start);img.height(ieh+iedh*percent);img.width(iew+iedw*percent);img.css("top",now)}}});else{this._img.css(params);setTimeout(complete,0)}}}).apply($.ui.iviewer.ImageObject.prototype);var util={scaleValue:function(value,toZoom){return value*toZoom/100},descaleValue:function(value,fromZoom){return value*100/fromZoom}}})(jQuery,undefined); + +!function($,undefined){function makeMouseEvent(event){var touch=event.originalEvent.changedTouches[0];return $.extend(event,{type:mouseEvents[event.type],which:1,pageX:touch.pageX,pageY:touch.pageY,screenX:touch.screenX,screenY:touch.screenY,clientX:touch.clientX,clientY:touch.clientY,isTouchEvent:!0})}var mouseEvents={touchstart:"mousedown",touchmove:"mousemove",touchend:"mouseup"},gesturesSupport="ongesturestart"in document.createElement("div"),mouseProto=$.ui.mouse.prototype,_mouseInit=$.ui.mouse.prototype._mouseInit;mouseProto._mouseInit=function(){var self=this;self._touchActive=!1,this.element.bind("touchstart."+this.widgetName,function(event){return gesturesSupport&&event.originalEvent.touches.length>1?void 0:(self._touchActive=!0,self._mouseDown(makeMouseEvent(event)))}),this._mouseMoveDelegate=function(event){return gesturesSupport&&event.originalEvent.touches&&event.originalEvent.touches.length>1?void 0:self._touchActive?self._mouseMove(makeMouseEvent(event)):void 0},this._mouseUpDelegate=function(event){return self._touchActive?(self._touchActive=!1,self._mouseUp(makeMouseEvent(event))):void 0},$(document).bind("touchmove."+this.widgetName,this._mouseMoveDelegate).bind("touchend."+this.widgetName,this._mouseUpDelegate),_mouseInit.apply(this)};var setter=function(setter,getter){return function(){return 0===arguments.length?getter.apply(this):void setter.apply(this,arguments)}},ieTransforms={0:{marginLeft:0,marginTop:0,filter:'progid:DXImageTransform.Microsoft.Matrix(M11=1, M12=0, M21=0, M22=1, SizingMethod="auto expand")'},90:{marginLeft:-1,marginTop:1,filter:'progid:DXImageTransform.Microsoft.Matrix(M11=0, M12=-1, M21=1, M22=0, SizingMethod="auto expand")'},180:{marginLeft:0,marginTop:0,filter:'progid:DXImageTransform.Microsoft.Matrix(M11=-1, M12=0, M21=0, M22=-1, SizingMethod="auto expand")'},270:{marginLeft:-1,marginTop:1,filter:'progid:DXImageTransform.Microsoft.Matrix(M11=0, M12=1, M21=-1, M22=0, SizingMethod="auto expand")'}},useIeTransforms=function(){for(var modElem=document.createElement("modernizr"),mStyle=modElem.style,omPrefixes="Webkit Moz O ms",domPrefixes=omPrefixes.toLowerCase().split(" "),props=("transform "+domPrefixes.join("Transform ")+"Transform").split(" "),i=0;i0?1:-1,container_offset=me.container.offset(),mouse_pos={x:(ev.pageX||ev.originalEvent.pageX)-container_offset.left,y:(ev.pageY||ev.originalEvent.pageX)-container_offset.top};return me.zoom_by(zoom,mouse_pos),!1}),gesturesSupport)){var originalScale,originalCenter,gestureThrottle=+new Date;this.img_object.object().bind("touchstart",function(ev){originalScale=me.current_zoom;var container_offset,touches=ev.originalEvent.touches;2==touches.length?(container_offset=me.container.offset(),originalCenter={x:(touches[0].pageX+touches[1].pageX)/2-container_offset.left,y:(touches[0].pageY+touches[1].pageY)/2-container_offset.top}):originalCenter=null}).bind("gesturechange.iviewer",function(ev){var d=+new Date;if(!(50>d-gestureThrottle)){gestureThrottle=d;var zoom=originalScale*ev.originalEvent.scale;me.set_zoom(zoom,originalCenter),ev.preventDefault()}}).bind("gestureend.iviewer",function(){originalCenter=null})}var useDblClick=!!this.options.onDblClick||this.options.zoom_on_dblclick,dblClickTimer=null,clicksNumber=0;this.img_object.object().prependTo(this.container),useDblClick?this.img_object.object().click(function(e){clicksNumber++,clearTimeout(dblClickTimer),dblClickTimer=setTimeout(function(){clicksNumber=0,me._click(e)},300)}).dblclick(function(e){2===clicksNumber&&(clearTimeout(dblClickTimer),clicksNumber=0,me._dblclick(e))}):this.img_object.object().click(function(e){me._click(e)}),this.container.bind("mousemove.iviewer",function(ev){me._handleMouseMove(ev)}),this.loadImage(this.options.src),this.options.ui_disabled||this.createui(),this.controls=this.container.find(".iviewer_common")||{},this._mouseInit()}},destroy:function(){$.Widget.prototype.destroy.call(this),this._mouseDestroy(),this.img_object.object().remove(),this.controls.remove(),this.container.off(".iviewer"),this.container.css("overflow","")},_updateContainerInfo:function(){this.options.height=this.container.height(),this.options.width=this.container.width()},update:function(){this._updateContainerInfo(),this.setCoords(this.img_object.x(),this.img_object.y())},loadImage:function(src){this.current_zoom=this.options.zoom;var me=this;this._trigger("onStartLoad",0,src),this.container.addClass("iviewer_loading"),this.img_object.load(src,function(){me._fill_orig_dimensions={width:me.img_object.orig_width(),height:me.img_object.orig_height()},me._imageLoaded(src)},function(){me._trigger("onErrorLoad",0,src)})},_imageLoaded:function(src){this.container.removeClass("iviewer_loading"),this.container.addClass("iviewer_cursor"),"fit"==this.options.zoom?this.fit(!0):this.set_zoom(this.options.zoom,!0),this._trigger("onFinishLoad",0,src),this.options.fill_container&&this.fill_container(!0)},fit:function(skip_animation){var aspect_ratio=this.img_object.orig_width()/this.img_object.orig_height(),window_ratio=this.options.width/this.options.height,choose_left=aspect_ratio>window_ratio,new_zoom=0;new_zoom=choose_left?this.options.width/this.img_object.orig_width()*100:this.options.height/this.img_object.orig_height()*100,this.set_zoom(new_zoom,skip_animation)},center:function(){this.setCoords(-Math.round((this.img_object.display_width()-this.options.width)/2),-Math.round((this.img_object.display_height()-this.options.height)/2))},moveTo:function(x,y){var dx=x-Math.round(this.options.width/2),dy=y-Math.round(this.options.height/2),new_x=this.img_object.x()-dx,new_y=this.img_object.y()-dy;this.setCoords(new_x,new_y)},getContainerOffset:function(){return jQuery.extend({},this.container.offset())},setCoords:function(x,y){if(this.img_object.loaded()){var coords=this._correctCoords(x,y);this.img_object.x(coords.x),this.img_object.y(coords.y)}},_correctCoords:function(x,y){return x=parseInt(x,10),y=parseInt(y,10),y>0&&(y=0),x>0&&(x=0),y+this.img_object.display_height()1?this.img_object.orig_width(this.img_object.orig_height()*ratio):this.img_object.orig_height(this.img_object.orig_width()*ratio)}else this.img_object.orig_width(this._fill_orig_dimensions.width),this.img_object.orig_height(this._fill_orig_dimensions.height);this.set_zoom(this.current_zoom)},set_zoom:function(new_zoom,skip_animation,zoom_center){if(0!=this._trigger("onZoom",0,new_zoom)&&this.img_object.loaded()){zoom_center=zoom_center||{x:Math.round(this.options.width/2),y:Math.round(this.options.height/2)},new_zoomthis.options.zoom_max&&(new_zoom=this.options.zoom_max);var old_x,old_y;"fit"==this.current_zoom?(old_x=zoom_center.x+Math.round(this.img_object.orig_width()/2),old_y=zoom_center.y+Math.round(this.img_object.orig_height()/2),this.current_zoom=100):(old_x=-this.img_object.x()+zoom_center.x,old_y=-this.img_object.y()+zoom_center.y);var new_width=util.scaleValue(this.img_object.orig_width(),new_zoom),new_height=util.scaleValue(this.img_object.orig_height(),new_zoom),new_x=util.scaleValue(util.descaleValue(old_x,this.current_zoom),new_zoom),new_y=util.scaleValue(util.descaleValue(old_y,this.current_zoom),new_zoom);new_x=zoom_center.x-new_x,new_y=zoom_center.y-new_y,new_width=Math.floor(new_width),new_height=Math.floor(new_height),new_x=Math.floor(new_x),new_y=Math.floor(new_y),this.img_object.display_width(new_width),this.img_object.display_height(new_height);var coords=this._correctCoords(new_x,new_y),self=this;this.img_object.setImageProps(new_width,new_height,coords.x,coords.y,skip_animation,function(){self._trigger("onAfterZoom",0,new_zoom)}),this.current_zoom=new_zoom,this.update_status()}},showControls:function(flag){flag?this.controls.fadeIn():this.controls.fadeOut()},zoom_by:function(delta,zoom_center){var closest_rate=this.find_closest_zoom_rate(this.current_zoom),next_rate=closest_rate+delta,next_zoom=this.options.zoom_base*Math.pow(this.options.zoom_delta,next_rate);delta>0&&next_zoomdelta&&next_zoom>this.current_zoom&&(next_zoom/=this.options.zoom_delta),this.set_zoom(next_zoom,undefined,zoom_center)},angle:function(deg,abs){return 0===arguments.length?this.img_object.angle():void(-270>deg||deg>270||deg%90!==0||(abs||(deg+=this.img_object.angle()),0>deg&&(deg+=360),deg>=360&&(deg-=360),deg!==this.img_object.angle()&&(this.img_object.angle(deg),this.center(),this._trigger("angle",0,{angle:this.img_object.angle()}))))},find_closest_zoom_rate:function(value){function div(val1,val2){return val1/val2}function mul(val1,val2){return val1*val2}if(value==this.options.zoom_base)return 0;for(var func=value>this.options.zoom_base?mul:div,sgn=value>this.options.zoom_base?1:-1,mltplr=this.options.zoom_delta,rate=1;Math.abs(func(this.options.zoom_base,Math.pow(mltplr,rate))-value)>Math.abs(func(this.options.zoom_base,Math.pow(mltplr,rate+1))-value);)rate++;return sgn*rate},update_status:function(){if(!this.options.ui_disabled){var percent=Math.round(100*this.img_object.display_height()/this.img_object.orig_height());percent&&this.zoom_object.html(percent+"%")}},info:function(param,withoutRotation){if(param)switch(param){case"orig_width":case"orig_height":return withoutRotation?this.img_object.angle()%180===0?this.img_object[param]():"orig_width"===param?this.img_object.orig_height():this.img_object.orig_width():this.img_object[param]();case"display_width":case"display_height":case"angle":return this.img_object[param]();case"zoom":return this.current_zoom;case"options":return this.options;case"src":return this.img_object.object().attr("src");case"coords":return{x:this.img_object.x(),y:this.img_object.y()}}},_mouseStart:function(e){return $.ui.mouse.prototype._mouseStart.call(this,e),this._trigger("onStartDrag",0,this._getMouseCoords(e))===!1?!1:(this.container.addClass("iviewer_drag_cursor"),this._dragInitialized=!(e.originalEvent.changedTouches&&1==e.originalEvent.changedTouches.length),this.dx=e.pageX-this.img_object.x(),this.dy=e.pageY-this.img_object.y(),!0)},_mouseCapture:function(){return!0},_handleMouseMove:function(e){this._trigger("onMouseMove",e,this._getMouseCoords(e))},_mouseDrag:function(e){$.ui.mouse.prototype._mouseDrag.call(this,e),this._dragInitialized||(this.dx=e.pageX-this.img_object.x(),this.dy=e.pageY-this.img_object.y(),this._dragInitialized=!0);var ltop=e.pageY-this.dy,lleft=e.pageX-this.dx;return this.setCoords(lleft,ltop),this._trigger("onDrag",e,this._getMouseCoords(e)),!1},_mouseStop:function(e){$.ui.mouse.prototype._mouseStop.call(this,e),this.container.removeClass("iviewer_drag_cursor"),this._trigger("onStopDrag",0,this._getMouseCoords(e))},_click:function(e){this._trigger("onClick",0,this._getMouseCoords(e))},_dblclick:function(ev){if(this.options.onDblClick&&this._trigger("onDblClick",0,this._getMouseCoords(ev)),this.options.zoom_on_dblclick){var container_offset=this.container.offset(),mouse_pos={x:ev.pageX-container_offset.left,y:ev.pageY-container_offset.top};this.zoom_by(1,mouse_pos)}},createui:function(){var me=this;$("
",{"class":"iviewer_zoom_in iviewer_common iviewer_button"}).bind("mousedown touchstart",function(){return me.zoom_by(1),!1}).appendTo(this.container),$("
",{"class":"iviewer_zoom_out iviewer_common iviewer_button"}).bind("mousedown touchstart",function(){return me.zoom_by(-1),!1}).appendTo(this.container),$("
",{"class":"iviewer_zoom_zero iviewer_common iviewer_button"}).bind("mousedown touchstart",function(){return me.set_zoom(100),!1}).appendTo(this.container),$("
",{"class":"iviewer_zoom_fit iviewer_common iviewer_button"}).bind("mousedown touchstart",function(){return me.fit(this),!1}).appendTo(this.container),this.zoom_object=$("
").addClass("iviewer_zoom_status iviewer_common").appendTo(this.container),$("
",{"class":"iviewer_rotate_left iviewer_common iviewer_button"}).bind("mousedown touchstart",function(){return me.angle(-90),!1}).appendTo(this.container),$("
",{"class":"iviewer_rotate_right iviewer_common iviewer_button"}).bind("mousedown touchstart",function(){return me.angle(90),!1}).appendTo(this.container),this.update_status()}}),$.ui.iviewer.ImageObject=function(do_anim){this._img=$("").css({position:"absolute",top:"0px",left:"0px"}),this._loaded=!1,this._swapDimensions=!1,this._do_anim=do_anim||!1,this.x(0,!0),this.y(0,!0),this.angle(0)},function(){this._reset=function(w,h){this._angle=0,this._swapDimensions=!1,this.x(0),this.y(0),this.orig_width(w),this.orig_height(h),this.display_width(w),this.display_height(h)},this.loaded=function(){return this._loaded},this.load=function(src,loaded,error){var self=this;loaded=loaded||jQuery.noop,this._loaded=!1;var img=new Image;img.onload=function(){self._loaded=!0,self._reset(this.width,this.height),self._img.removeAttr("width").removeAttr("height").removeAttr("style").css({position:"absolute",top:"0px",left:"0px",maxWidth:"none"}),self._img[0].src=src,loaded()},img.onerror=error,setTimeout(function(){img.src=src},0),this.angle(0)},this._dimension=function(prefix,name){var horiz="_"+prefix+"_"+name,vert="_"+prefix+"_"+("height"===name?"width":"height");return setter(function(val){this[this._swapDimensions?horiz:vert]=val},function(){return this[this._swapDimensions?horiz:vert]})},this.display_width=this._dimension("display","width"),this.display_height=this._dimension("display","height"),this.display_diff=function(){return Math.floor(this.display_width()-this.display_height())},this.orig_width=this._dimension("orig","width"),this.orig_height=this._dimension("orig","height"),this.x=setter(function(val,skipCss){this._x=val,skipCss||(this._finishAnimation(),this._img.css("left",this._x+(this._swapDimensions?this.display_diff()/2:0)+"px"))},function(){return this._x}),this.y=setter(function(val,skipCss){this._y=val,skipCss||(this._finishAnimation(),this._img.css("top",this._y-(this._swapDimensions?this.display_diff()/2:0)+"px"))},function(){return this._y}),this.angle=setter(function(deg){var prevSwap=this._swapDimensions;if(this._angle=deg,this._swapDimensions=deg%180!==0,prevSwap!==this._swapDimensions){var verticalMod=this._swapDimensions?-1:1;this.x(this.x()-verticalMod*this.display_diff()/2,!0),this.y(this.y()+verticalMod*this.display_diff()/2,!0)}var cssVal="rotate("+deg+"deg)",img=this._img;jQuery.each(["","-webkit-","-moz-","-o-","-ms-"],function(i,prefix){img.css(prefix+"transform",cssVal)}),useIeTransforms&&(jQuery.each(["-ms-",""],function(i,prefix){img.css(prefix+"filter",ieTransforms[deg].filter)}),img.css({marginLeft:ieTransforms[deg].marginLeft*this.display_diff()/2,marginTop:ieTransforms[deg].marginTop*this.display_diff()/2}))},function(){return this._angle}),this.toOriginalCoords=function(point){switch(this.angle()){case 0:return{x:point.x,y:point.y};case 90:return{x:point.y,y:this.display_width()-point.x};case 180:return{x:this.display_width()-point.x,y:this.display_height()-point.y};case 270:return{x:this.display_height()-point.y,y:point.x}}},this.toRealCoords=function(point){switch(this.angle()){case 0:return{x:this.x()+point.x,y:this.y()+point.y};case 90:return{x:this.x()+this.display_width()-point.y,y:this.y()+point.x};case 180:return{x:this.x()+this.display_width()-point.x,y:this.y()+this.display_height()-point.y};case 270:return{x:this.x()+point.y,y:this.y()+this.display_height()-point.x}}},this.object=setter(jQuery.noop,function(){return this._img}),this.setImageProps=function(disp_w,disp_h,x,y,skip_animation,complete){complete=complete||jQuery.noop,this.display_width(disp_w),this.display_height(disp_h),this.x(x,!0),this.y(y,!0);var w=this._swapDimensions?disp_h:disp_w,h=this._swapDimensions?disp_w:disp_h,params={width:w,height:h,top:y-(this._swapDimensions?this.display_diff()/2:0)+"px",left:x+(this._swapDimensions?this.display_diff()/2:0)+"px"};useIeTransforms&&jQuery.extend(params,{marginLeft:ieTransforms[this.angle()].marginLeft*this.display_diff()/2,marginTop:ieTransforms[this.angle()].marginTop*this.display_diff()/2});var swapDims=this._swapDimensions,img=this._img;if(useIeTransforms&&swapDims){var ieh=this._img.width(),iew=this._img.height(),iedh=params.height-ieh;iedw=params.width-iew,delete params.width,delete params.height}this._do_anim&&!skip_animation?this._img.stop(!0).animate(params,{duration:200,complete:complete,step:function(now,fx){if(useIeTransforms&&swapDims&&"top"===fx.prop){var percent=(now-fx.start)/(fx.end-fx.start);img.height(ieh+iedh*percent),img.width(iew+iedw*percent),img.css("top",now)}}}):(this._img.css(params),setTimeout(complete,0))},this._finishAnimation=function(){this._img.stop(!0,!0)}}.apply($.ui.iviewer.ImageObject.prototype);var util={scaleValue:function(value,toZoom){return value*toZoom/100},descaleValue:function(value,fromZoom){return 100*value/fromZoom}}}(jQuery,void 0);