function onIEWinResize(D){function F(G){return(isNaN(parseInt(G,10))?0:parseInt(G,10))}if(!D){D=window.event}var A,C,B=this,E=B.getElementsByTagName("div");if(E.length>0){if(B.currentStyle){C=B.currentStyle}else{if(document.defaultView&&document.defaultView.getComputedStyle){C=document.defaultView.getComputedStyle(B,"")}else{C=B.style}}for(A=0;A<E.length;A++){if(E[A].className=="buzy_ele"){E[A].style.height=(B.offsetHeight-F(C.borderBottomWidth)-F(C.borderTopWidth));E[A].style.width=(B.offsetWidth-F(C.borderLeftWidth)-F(C.borderRightWidth));E[A].firstChild.style.height=E[A].style.height;E[A].firstChild.style.width=E[A].style.width;break}}}}function getBusyOverlay(O,P,a,c){if(typeof (O)==="object"&&document.getElementsByTagName){function X(b){return(isNaN(parseInt(b,10))?0:parseInt(b,10))}var S,e,H,J,f,Y,d,T,K,L,U,W,D,I,R,g,B,A,G,E,N,F,V,Q,M,C=true;if(O.currentStyle){I=O.currentStyle}else{if(document.defaultView&&document.defaultView.getComputedStyle){I=document.defaultView.getComputedStyle(O,"")}else{I=O.style}}while(I.display.search(/block|inline-block|table|inline-table|list-item/i)<0){O=O.parentNode;if(O.currentStyle){I=O.currentStyle}else{if(document.defaultView&&document.defaultView.getComputedStyle){I=document.defaultView.getComputedStyle(O,"")}else{I=O.style}}if(O.tagName.toUpperCase()==="BODY"){O=""}}if(typeof (O)==="object"){if(!a){a=new Object();a.opacity=0}if(!c){c=new Object();c.size=32}F=Math.max(0,Math.min(1,(typeof a.opacity==="number"?a.opacity:0)||0));V=(typeof a.color==="string"?a.color:"white");Q=(typeof a.text==="string"?a.text:"");M=(typeof a.style==="string"?a.style:"");G=document.createElement("canvas");H=G.getContext?1:0;J=navigator.userAgent.indexOf("WebKit")>-1?1:0;f=navigator.userAgent.indexOf("Gecko")>-1&&window.updateCommands?1:0;S=navigator.appName=="Microsoft Internet Explorer"&&window.navigator.systemLanguage&&!window.opera?1:0;e=document.all&&document.namespaces?1:0;B=document.createElement("div");O.style.position=(I.position=="static"?"relative":I.position);D=O.style.zIndex>=0?(O.style.zIndex-0+2):2;if(S&&!I.hasLayout){O.style.zoom=1}B.style.position="absolute";B.style.overflow="hidden";B.style.display="block";B.style.zIndex=D;B.style.left=0+"px";B.style.top=0+"px";B.style.width="100%";B.style.height=P+"px";if(S){B.className="buzy_ele";B.style.zoom=1;B.style.margin="0px";B.style.padding="0px";B.style.height=(O.offsetHeight-X(I.borderBottomWidth)-X(I.borderTopWidth));B.style.width=(O.offsetWidth-X(I.borderLeftWidth)-X(I.borderRightWidth))}if(typeof (I.borderRadius)=="undefined"){if(typeof (I.MozBorderRadius)!="undefined"){K=parseFloat(I.MozBorderRadiusTopleft)-Math.min(parseFloat(I.borderLeftWidth),parseFloat(I.borderTopWidth));L=parseFloat(I.MozBorderRadiusTopright)-Math.min(parseFloat(I.borderRightWidth),parseFloat(I.borderTopWidth));U=parseFloat(I.MozBorderRadiusBottomleft)-Math.min(parseFloat(I.borderLeftWidth),parseFloat(I.borderBottomWidth));W=parseFloat(I.MozBorderRadiusBottomright)-Math.min(parseFloat(I.borderRightWidth),parseFloat(I.borderBottomWidth));B.style.MozBorderRadiusTopleft=K+"px";B.style.MozBorderRadiusTopright=L+"px";B.style.MozBorderRadiusBottomleft=U+"px";B.style.MozBorderRadiusBottomright=W+"px"}else{if(typeof (I.WebkitBorderRadius)!="undefined"){K=parseFloat(I.WebkitBorderTopLeftRadius)-Math.min(parseFloat(I.borderLeftWidth),parseFloat(I.borderTopWidth));L=parseFloat(I.WebkitBorderTopRightRadius)-Math.min(parseFloat(I.borderRightWidth),parseFloat(I.borderTopWidth));U=parseFloat(I.WebkitBorderBottomLeftRadius)-Math.min(parseFloat(I.borderLeftWidth),parseFloat(I.borderBottomWidth));W=parseFloat(I.WebkitBorderBottomRightRadius)-Math.min(parseFloat(I.borderRightWidth),parseFloat(I.borderBottomWidth));B.style.WebkitBorderTopLeftRadius=K+"px";B.style.WebkitBorderTopRightRadius=L+"px";B.style.WebkitBorderBottomLeftRadius=U+"px";B.style.WebkitBorderBottomRightRadius=W+"px"}}}else{K=parseFloat(I.borderTopLeftRadius)-Math.min(parseFloat(I.borderLeftWidth),parseFloat(I.borderTopWidth));L=parseFloat(I.borderTopRightRadius)-Math.min(parseFloat(I.borderRightWidth),parseFloat(I.borderTopWidth));U=parseFloat(I.borderBottomLeftRadius)-Math.min(parseFloat(I.borderLeftWidth),parseFloat(I.borderBottomWidth));W=parseFloat(I.borderBottomRightRadius)-Math.min(parseFloat(I.borderRightWidth),parseFloat(I.borderBottomWidth));B.style.borderTopLeftRadius=K+"px";B.style.borderTopRightRadius=L+"px";B.style.borderBottomLeftRadius=U+"px";B.style.borderBottomRightRadius=W+"px"}O.appendChild(B);g=document.createElement("div");g.style.position="absolute";g.style.cursor="progress";g.style.display="block";g.style.zIndex=(D-1);g.style.left=0+"px";g.style.top=0+"px";g.style.width=100+"%";g.style.height=100+"%";g.style.backgroundColor=V;if(S){g.style.zoom=1;g.style.margin="0px";g.style.padding="0px";g.style.height=B.style.height;g.style.width=B.style.width}if(typeof (I.borderRadius)=="undefined"){if(typeof (I.MozBorderRadius)!="undefined"){g.style.MozBorderRadiusTopleft=K+"px";g.style.MozBorderRadiusTopright=L+"px";g.style.MozBorderRadiusBottomleft=U+"px";g.style.MozBorderRadiusBottomright=W+"px"}else{if(typeof (I.WebkitBorderRadius)!="undefined"){g.style.WebkitBorderTopLeftRadius=K+"px";g.style.WebkitBorderTopRightRadius=L+"px";g.style.WebkitBorderBottomLeftRadius=U+"px";g.style.WebkitBorderBottomRightRadius=W+"px"}}}else{g.style.borderTopLeftRadius=K+"px";g.style.borderTopRightRadius=L+"px";g.style.borderBottomLeftRadius=U+"px";g.style.borderBottomRightRadius=W+"px"}if(S){g.style.filter="alpha(opacity="+parseInt(F*100)+")"}else{g.style.opacity=F}B.appendChild(g);R=Math.max(16,Math.min(512,(typeof c.size==="number"?(c.size==0?32:c.size):32)));if(e){if(document.namespaces.v==null){var Z=document.createStyleSheet();Z.addRule("v\:*","behavior: url(#default#VML);");document.namespaces.add("v","urn:schemas-microsoft-com:vml")}}if(!H){G=document.createElement("div")}G.style.position="absolute";G.style.cursor="progress";G.style.zIndex=(D-0+1);G.style.top="50%";G.style.left="50%";G.style.marginTop="-"+(R/2)+"px";G.style.marginLeft="-"+(R/2)+"px";G.width=R;G.height=R;G.style.width=R+"px";G.style.height=R+"px";B.appendChild(G);if(typeof (Q)!=""){A=document.createElement("div");A.style.position="absolute";A.style.overflow="hidden";A.style.cursor="progress";A.style.zIndex=(D-0+1);A.style.top="50%";A.style.left="0px";A.style.marginTop=2+(R/2)+"px";A.style.textAlign="center";A.style.width=100+"%";A.style.height="auto";if(typeof (M)!=""){A.innerHTML="<span "+(M.match(/:/i)?"style":"class")+'="'+M+'">'+Q+"</span>"}else{A.innerHTML="<span>"+Q+"</span>"}B.appendChild(A)}if(f){B.style.MozUserSelect="none";g.style.MozUserSelect="none";G.style.MozUserSelect="none"}else{if(J){B.style.KhtmlUserSelect="none";g.style.KhtmlUserSelect="none";G.style.KhtmlUserSelect="none"}else{if(S){B.style.unselectable="on";g.style.unselectable="on";G.style.unselectable="on"}}}if(e){N=getBusyVL(G,c.color,c.size,c.type,c.iradius,c.weight,c.count,c.speed,c.minopac);N.start()}else{if(H){N=getBusyCV(G.getContext("2d"),c.color,c.size,c.type,c.iradius,c.weight,c.count,c.speed,c.minopac);N.start()}else{N=getBusy(G,c.color,c.size,c.type,c.iradius,c.weight,c.count,c.speed,c.minopac);N.start()}}if(S){O.onresize=onIEWinResize}return{remove:function(){if(C){C=false;N.stop();delete N;O.removeChild(B)}}}}}}function getBusy(N,H,P,B,E,K,D,V,T){function R(b){var c=b||"#000000";if(!c.match(/^#[0-9a-f][0-9a-f][0-9a-f][0-9a-f][0-9a-f][0-9a-f]$/i)){if(b.match(/^#[0-9a-f][0-9a-f][0-9a-f]$/i)){c="#"+b.substr(1,1)+b.substr(1,1)+b.substr(2,1)+b.substr(2,1)+b.substr(3,1)+b.substr(3,1)}}return c}var C=false,U=0,F=0,S=0,X=100,Y,W,Q,O,J,I,M,A,Z,a,L=new Array();Y=R(H);B=B||"t";O=(B.match(/^[coprt]/i)?B.substr(0,1).toLowerCase():"t");D=Math.max(5,Math.min(36,D||12));V=Math.max(30,Math.min(1000,V||96));P=Math.max(16,Math.min(512,P||32));E=Math.max(1,Math.min((P/2)-2,E||P/4));K=Math.max(1,Math.min((P/2)-E,K||P/10));T=Math.max(0,Math.min(0.5,T||0.25));S=360/D;A=(Math.PI/2)*-1;Z=Math.PI/180;K=(O!="c"?parseInt((K/2)*3):K);M=parseInt((P/2)-(K/2));for(U=0;U<D;U++){a=document.createElement("div");J=Math.round(M+M*Math.cos(A+(U+1)*S*Z));I=Math.round(M+M*Math.sin(A+(U+1)*S*Z));a.style.position="absolute";a.style.margin="0px";a.style.width=K+"px";a.style.height=K+"px";a.style.lineHeight="1px";a.style.fontSize="0px";a.style.top=I+"px";a.style.left=J+"px";a.style.backgroundColor=Y;if(document.all&&!window.opera){a.style.filter="alpha(opacity="+parseInt(Math.min(1,Math.max(T,1-((D+1-U)/(D+1))))*100)+")"}else{a.style.opacity=Math.min(1,Math.max(T,1-((D+1-U)/(D+1))))}N.appendChild(a);L[U]=a}function G(){if(!C){return }F=(F+1)%D;if(document.all&&!window.opera){for(U=0;U<D;U++){S=((F+U)%D);L[S].style.filter="alpha(opacity="+parseInt(Math.min(1,Math.max(T,1-((D+1-U)/(D+1))))*100)+")"}}else{for(U=0;U<D;U++){S=((F+U)%D);L[S].style.opacity=Math.min(1,Math.max(T,1-((D+1-U)/(D+1))))}}setTimeout(G,V)}G(0);return{start:function(){if(!C){C=true;G(0)}},stop:function(){C=false;for(U=0;U<D;U++){if(document.all&&!window.opera){L[U].style.filter="alpha(opacity=0)"}else{L[U].setAttribute("opacity",0)}}},pause:function(){C=false}}}function getBusyVL(O,H,Q,B,E,M,D,W,U){function S(c){var f=c||"#000000";if(!f.match(/^#[0-9a-f][0-9a-f][0-9a-f][0-9a-f][0-9a-f][0-9a-f]$/i)){if(c.match(/^#[0-9a-f][0-9a-f][0-9a-f]$/i)){f="#"+c.substr(1,1)+c.substr(1,1)+c.substr(2,1)+c.substr(2,1)+c.substr(3,1)+c.substr(3,1)}}return f}var C=false,F=0,T=0,Y=100,a,V,X,R,P,L,K,e,A,Z,d,J,b,I,N=new Array();a=S(H);B=B||"t";P=(B.match(/^[coprt]/i)?B.substr(0,1).toLowerCase():"t");D=Math.max(5,Math.min(36,D||12));W=Math.max(30,Math.min(1000,W||96));Q=Math.max(16,Math.min(512,Q||32));E=Math.max(1,Math.min((Q/2)-2,E||Q/4));M=Math.max(1,Math.min((Q/2)-E,M||Q/10));U=Math.max(0,Math.min(0.5,U||0.25));X=(Q/2)-E;L=Q/2;K=L;T=360/D;e=parseInt((Q/2)*Y);A=parseInt(e/2);Z=parseInt((M/2)*Y);d=parseInt(Z/2);J=e-parseInt(E*Y);switch(P){case"c":R="m "+e+","+(J-Z)+" ar "+(e-Z)+","+(J-Z-Z)+","+(e+Z)+","+J+","+(e-Z)+","+(J-Z-Z)+","+(e-Z)+","+(J-Z-Z)+" e";break;case"p":R="m "+(e-d)+",0 l "+(e-Z)+","+J+","+(e+Z)+","+J+","+(e+d)+",0 x e";break;case"o":R="m "+e+","+(J-A)+" ar "+(e-Z)+",0,"+(e+Z)+","+J+","+(e-Z)+",0,"+(e-Z)+",0 e";break;case"t":R="m "+(e-Z)+","+J+" l "+(e-Z)+","+Z+" qy "+e+",0 qx "+(e+Z)+","+Z+" l "+(e+Z)+","+J+" x e";break;default:R="m "+(e-Z)+",0 l "+(e-Z)+","+J+","+(e+Z)+","+J+","+(e+Z)+",0 x e";break}for(V=0;V<D;V++){b=document.createElement("v:shape");b.setAttribute("filled","t");b.setAttribute("stroked","f");b.setAttribute("coordorigin","0,0");b.setAttribute("coordsize",(Q*Y)+","+(Q*Y));b.setAttribute("path",R);b.style.rotation=(V*T);b.style.position="absolute";b.style.margin="0px";b.style.width=Q+"px";b.style.height=Q+"px";b.style.top="-1px";b.style.left="-1px";O.appendChild(b);I=document.createElement("v:fill");I.setAttribute("color",a);I.setAttribute("opacity",Math.min(1,Math.max(U,1-((D+1-V)/(D+1)))));b.appendChild(I);N[V]=I}function G(){if(!C){return }F=(F+1)%D;for(V=0;V<D;V++){T=((F+V)%D);N[T].setAttribute("opacity",Math.min(1,Math.max(U,1-((D+1-V)/(D+1)))))}setTimeout(G,W)}G(0);return{start:function(){if(!C){C=true;G(0)}},stop:function(){C=false;for(V=0;V<D;V++){N[V].setAttribute("opacity",0)}},pause:function(){C=false}}}function getBusyCV(R,J,O,A,F,M,C,V,T){function E(Z){function a(b){return(Math.max(0,Math.min(parseInt(b,16),255)))}var d=0,c=0,Y=0;Z=Z||"#000";if(Z.match(/^#[0-9a-f][0-9a-f][0-9a-f]$/i)){d=a(Z.substr(1,1)+Z.substr(1,1)),c=a(Z.substr(2,1)+Z.substr(2,1)),Y=a(Z.substr(3,1)+Z.substr(3,1))}else{if(Z.match(/^#[0-9a-f][0-9a-f][0-9a-f][0-9a-f][0-9a-f][0-9a-f]$/i)){d=a(Z.substr(1,2)),c=a(Z.substr(3,2)),Y=a(Z.substr(5,2))}}return d+","+c+","+Y}function P(Z,Y,a){Z.beginPath();Z.moveTo(-Y/2,a/2);Z.quadraticCurveTo(-Y/2,0,0,0);Z.quadraticCurveTo(Y/2,0,Y/2,a/2);Z.quadraticCurveTo(Y/2,a,0,a);Z.quadraticCurveTo(-Y/2,a,-Y/2,a/2);Z.fill()}function D(Z,Y,a){Z.beginPath();Z.moveTo(Y/2,0);Z.lineTo(-Y/2,0);Z.lineTo(-Y/2,a-(Y/2));Z.quadraticCurveTo(-Y/2,a,0,a);Z.quadraticCurveTo(Y/2,a,Y/2,a-(Y/2));Z.fill()}function H(Z,Y,a){Z.beginPath();Z.moveTo(Y/2,0);Z.lineTo(-Y/2,0);Z.lineTo(-Y/4,a);Z.lineTo(Y/4,a);Z.fill()}function Q(Y,Z,a){Y.beginPath();Y.arc(Z,Z,Z,0,Math.PI*2,false);Y.fill()}var B=false,G=0,S=0,X,U,W,N,L,K;X=E(J);A=A||"t";N=(A.match(/^[coprt]/i)?A.substr(0,1).toLowerCase():"t");C=Math.max(5,Math.min(36,C||12));V=Math.max(30,Math.min(1000,V||96));O=Math.max(16,Math.min(512,O||32));F=Math.max(1,Math.min((O/2)-2,F||O/4));M=Math.max(1,Math.min((O/2)-F,M||O/10));T=Math.max(0,Math.min(0.5,T||0.25));W=(O/2)-F;L=O/2;K=L;function I(){if(!B){return }G=(G+1)%C;R.clearRect(0,0,O,O);R.save();R.translate(L,K);for(U=0;U<C;U++){S=2*((G+U)%C)*Math.PI/C;R.save();R.translate(F*Math.sin(-S),F*Math.cos(-S));R.rotate(S);R.fillStyle="rgba("+X+","+Math.min(1,Math.max(T,1-((C+1-U)/(C+1))))+")";switch(N){case"c":Q(R,M/2,W);break;case"o":P(R,M,W);break;case"p":H(R,M,W);break;case"t":D(R,M,W);break;default:R.fillRect(-M/2,0,M,W);break}R.restore()}R.restore();setTimeout(I,V)}I(0);return{start:function(){if(!B){B=true;I(0)}},stop:function(){B=false;R.clearRect(0,0,O,O)},pause:function(){B=false}}};