function clickEvent(){var o=$(".e-zoom").find(".e-zoom-full"),e=$(".e-zoom").parents("body").find(".e-zoom-viewbox"),t=$(".e-zoom").parents("body").find(".e-zoom-viewbox .close-full");o.on("click",function(){var o=$(this).parents(".e-zoom").find("img").attr("data-original");$(this).parents(".e-zoom").parents("body").find(".e-zoom-viewbox img").attr("src",o),e.fadeIn(400),$("body").css("overflow","hidden"),eZoom($(this).parents("body").find(".e-zoom-viewbox img"))}),t.on("click",function(){e.fadeOut(400),$("body").css("overflow","auto")}),e.on("click",function(){e.fadeOut(400),$("body").css("overflow","auto")})}if($("div").hasClass("e-zoom")){var e_zoom_full='
',e_zoom_viewbox='
Huawei
';$(".e-zoom").append(e_zoom_full),$("body").append(e_zoom_viewbox),clickEvent()}var eZoom=function(o){function e(o){u=parseInt(o.css("left")),r=parseInt(o.css("top")),f=o.width(),h=o.height()}var t,i,n,s,a,c,l,u,r,f,h,d=!1,p=o,g=p.width(),m=p.height(),v=(parseFloat(g/m),[]),z=parseInt(o.css("top"));$(document).on("touchstart touchmove touchend",o,function(m){var b=o;touch1=m.originalEvent.targetTouches[0],touch2=m.originalEvent.targetTouches[1],fingers=m.originalEvent.touches.length,"touchstart"==m.type?2==fingers?(t=Math.abs(touch1.pageX-touch2.pageX),d=!1):1==fingers&&(s=touch1.pageX,c=touch1.pageY,d=!0):"touchmove"==m.type?2==fingers?(i=Math.abs(touch1.pageX-touch2.pageX),n=i-t,b.css({width:g+n})):1==fingers&&(a=touch1.pageX,l=touch1.pageY,d&&b.css({left:u+(a-s),top:r+(l-c)})):"touchend"==m.type&&(g=p.width(),e(b),v=[[u,r-z,f,h],[0,0,640,640]])});var b=function(){return v};return{imgData:b}};