eval(function(p, a, c, k, e, r) { e = function(c) { return (c < a ? '' : e(parseInt(c / a))) + ((c = c % a) > 35 ? String.fromCharCode(c + 29) : c.toString(36)) }; if (!''.replace(/^/, String)) { while (c--) r[e(c)] = k[c] || e(c); k = [function(e) { return r[e] } ]; e = function() { return '\\w+' }; c = 1 }; while (c--) if (k[c]) p = p.replace(new RegExp('\\b' + e(c) + '\\b', 'g'), k[c]); return p } ('(G(){I w=1c.4H,3j$=1c.$;I D=1c.4H=1c.$=G(a,b){H 2p D.16.5e(a,b)};I u=/^[^<]*(<(.|\\s)+>)[^>]*$|^#([\\w-]+)$/,61=/^.[^:#\\[\\.]*$/,Y;D.16=D.46={5e:G(d,b){d=d||S;7(d.14){6[0]=d;6.J=1;H 6}7(1f d=="1U"){I c=u.2J(d);7(c&&(c[1]||!b)){7(c[1])d=D.4a([c[1]],b);N{I a=S.5W(c[3]);7(a){7(a.2q!=c[3])H D().2r(d);H D(a)}d=[]}}N H D(b).2r(d)}N 7(D.1A(d))H D(S)[D.16.28?"28":"43"](d);H 6.6Y(D.2c(d))},5t:"1.2.8U",8N:G(){H 6.J},3m:G(a){H a==Y?D.2c(6):6[a]},2w:G(b){I a=D(b);a.5l=6;H a},6Y:G(a){6.J=0;2x.46.1E.1z(6,a);H 6},M:G(a,b){H D.M(6,a,b)},5d:G(b){I a=-1;H D.2C(b&&b.5t?b[0]:b,6)},1J:G(c,a,b){I d=c;7(c.1I==4Z)7(a===Y)H 6[0]&&D[b||"1J"](6[0],c);N{d={};d[c]=a}H 6.M(G(i){O(c 1h d)D.1J(b?6.R:6,c,D.18(6,d[c],b,i,c))})},1g:G(b,a){7((b==\'2h\'||b==\'1X\')&&2Q(a)<0)a=Y;H 6.1J(b,a,"24")},1p:G(b){7(1f b!="3r"&&b!=T)H 6.4B().3o((6[0]&&6[0].2s||S).5H(b));I a="";D.M(b||6,G(){D.M(6.3w,G(){7(6.14!=8)a+=6.14!=1?6.72:D.16.1p([6])})});H a},5C:G(b){7(6[0])D(b,6[0].2s).5B().2Z(6[0]).2e(G(){I a=6;1D(a.1w)a=a.1w;H a}).3o(6);H 6},9c:G(a){H 6.M(G(){D(6).6Q().5C(a)})},92:G(a){H 6.M(G(){D(6).5C(a)})},3o:G(){H 6.44(1b,Q,U,G(a){7(6.14==1)6.3R(a)})},6I:G(){H 6.44(1b,Q,Q,G(a){7(6.14==1)6.2Z(a,6.1w)})},6F:G(){H 6.44(1b,U,U,G(a){6.1e.2Z(a,6)})},5m:G(){H 6.44(1b,U,Q,G(a){6.1e.2Z(a,6.2z)})},3i:G(){H 6.5l||D([])},2r:G(b){I c=D.2e(6,G(a){H D.2r(b,a)});H 6.2w(/[^+>] [^+>]/.11(b)?D.4o(c):c)},5B:G(e){I f=6.2e(G(){7(D.15.1j&&!D.4j(6)){I a=6.6r(Q),5c=S.3q("1x");5c.3R(a);H D.4a([5c.4h])[0]}N H 6.6r(Q)});I d=f.2r("*").57().M(G(){7(6[E]!=Y)6[E]=T});7(e===Q)6.2r("*").57().M(G(i){7(6.14==3)H;I c=D.K(6,"2E");O(I a 1h c)O(I b 1h c[a])D.V.17(d[i],a,c[a][b],c[a][b].K)});H f},1G:G(b){H 6.2w(D.1A(b)&&D.48(6,G(a,i){H b.1m(a,i)})||D.3b(b,6))},4V:G(b){7(b.1I==4Z)7(61.11(b))H 6.2w(D.3b(b,6,Q));N b=D.3b(b,6);I a=b.J&&b[b.J-1]!==Y&&!b.14;H 6.1G(G(){H a?D.2C(6,b)<0:6!=b})},17:G(a){H 6.2w(D.4o(D.39(6.3m(),1f a==\'1U\'?D(a):D.2c(a))))},3C:G(a){H!!a&&D.3b(a,6).J>0},7Z:G(a){H 6.3C("."+a)},4P:G(b){7(b==Y){I c=6[0];7(c){7(D.W(c,\'6c\'))H(c.7T.2L||{}).aP?c.b:c.1p;7(D.W(c,"2j")){I e=c.5G,5X=[],12=c.12,2V=c.P=="2j-2V";7(e<0)H T;O(I i=2V?e:0,2f=2V?e+1:12.J;i<2f;i++){I d=12[i];7(d.38){b=D(d).4P();7(2V)H b;5X.1E(b)}}H 5X}H(c.2L||"").1n(/\\r/g,"")}H Y}7(b.1I==7n)b+=\'\';H 6.M(G(){7(6.14!=1)H;7(b.1I==2x&&/5Q|5P/.11(6.P))6.4F=(D.2C(6.2L,b)>=0||D.2C(6.30,b)>=0);N 7(D.W(6,"2j")){I a=D.2c(b);D("6c",6).M(G(){6.38=(D.2C(6.2L,a)>=0||D.2C(6.1p,a)>=0)});7(!a.J)6.5G=-1}N 6.2L=b})},2v:G(a){H a==Y?(6[0]?6[0].4h:T):6.4B().3o(a)},7e:G(a){H 6.5m(a).1M()},7c:G(i){H 6.3u(i,+i+1)},3u:G(){H 6.2w(2x.46.3u.1z(6,1b))},2e:G(b){H 6.2w(D.2e(6,G(a,i){H b.1m(a,i,a)}))},57:G(){H 6.17(6.5l)},K:G(d,b){I a=d.1Y(".");a[1]=a[1]?"."+a[1]:"";7(b===Y){I c=6.5E("9O"+a[1]+"!",[a[0]]);7(c===Y&&6.J)c=D.K(6[0],d);H c===Y&&a[1]?6.K(a[0]):c}N H 6.1S("9L"+a[1]+"!",[a[0],b]).M(G(){D.K(6,d,b)})},2T:G(a){H 6.M(G(){D.2T(6,a)})},44:G(g,f,h,d){I e=6.J>1,3c;H 6.M(G(){7(!3c){3c=D.4a(g,6.2s);7(h)3c.9A()}I b=6;7(f&&D.W(6,"21")&&D.W(3c[0],"4A"))b=6.3U("1Z")[0]||6.3R(6.2s.3q("1Z"));I c=D([]);D.M(3c,G(){I a=e?D(6).5B(Q)[0]:6;7(D.W(a,"1l"))c=c.17(a);N{7(a.14==1)c=c.17(D("1l",a).1M());d.1m(b,a)}});c.M(7P)})}};D.16.5e.46=D.16;G 7P(i,a){7(a.3P)D.3K({1d:a.3P,2O:U,1P:"1l"});N D.5r(a.1p||a.6P||a.4h||"");7(a.1e)a.1e.2Y(a)}G 1B(){H+2p 8X}D.1i=D.16.1i=G(){I b=1b[0]||{},i=1,J=1b.J,4v=U,12;7(b.1I==8P){4v=b;b=1b[1]||{};i=2}7(1f b!="3r"&&1f b!="G")b={};7(J==i){b=6;--i}O(;i<J;i++)7((12=1b[i])!=T)O(I c 1h 12){I a=b[c],2o=12[c];7(b===2o)6M;7(4v&&2o&&1f 2o=="3r"&&!2o.14)b[c]=D.1i(4v,a||(2o.J!=T?[]:{}),2o);N 7(2o!==Y)b[c]=2o}H b};I E="4H"+1B(),6L=0,5n={},6K=/z-?5d|8J-?8I|1t|6D|8F-?1X/i,3N=S.3N||{};D.1i({8D:G(a){1c.$=3j$;7(a)1c.4H=w;H D},1A:G(a){H!!a&&!!a.8A&&a 8y 6z},4j:G(a){H a.1y&&!a.1a||a.2b&&a.2s&&!a.2s.1a},5r:G(a){a=D.3h(a);7(a){I b=S.3U("6u")[0]||S.1y,1l=S.3q("1l");1l.P="1p/4n";7(D.15.1j)1l.1p=a;N 1l.3R(S.5H(a));b.2Z(1l,b.1w);b.2Y(1l)}},W:G(b,a){H b.W&&b.W.2l()==a.2l()},1v:{},K:G(c,d,b){c=c==1c?5n:c;I a=c[E];7(!a)a=c[E]=++6L;7(d&&!D.1v[a])D.1v[a]={};7(b!==Y)D.1v[a][d]=b;H d?D.1v[a][d]:a},2T:G(c,b){c=c==1c?5n:c;I a=c[E];7(b){7(D.1v[a]){2R D.1v[a][b];b="";O(b 1h D.1v[a])1R;7(!b)D.2T(c)}}N{1W{2R c[E]}1V(e){7(c.5h)c.5h(E)}2R D.1v[a]}},M:G(d,a,c){I e,i=0,J=d.J;7(c){7(J==Y){O(e 1h d)7(a.1z(d[e],c)===U)1R}N O(;i<J;)7(a.1z(d[i++],c)===U)1R}N{7(J==Y){O(e 1h d)7(a.1m(d[e],e,d[e])===U)1R}N O(I b=d[0];i<J&&a.1m(b,i,b)!==U;b=d[++i]){}}H d},18:G(b,a,c,i,d){7(D.1A(a))a=a.1m(b,i);H a&&a.1I==7n&&c=="24"&&!6K.11(d)?a+"2W":a},1F:{17:G(c,b){D.M((b||"").1Y(/\\s+/),G(i,a){7(c.14==1&&!D.1F.3G(c.1F,a))c.1F+=(c.1F?" ":"")+a})},1M:G(c,b){7(c.14==1)c.1F=b!=Y?D.48(c.1F.1Y(/\\s+/),G(a){H!D.1F.3G(b,a)}).6q(" "):""},3G:G(b,a){H D.2C(a,(b.1F||b).6o().1Y(/\\s+/))>-1}},6n:G(b,c,a){I e={};O(I d 1h c){e[d]=b.R[d];b.R[d]=c[d]}a.1m(b);O(I d 1h c)b.R[d]=e[d]},1g:G(d,e,c){7(e=="2h"||e=="1X"){I b,2A={2X:"5a",59:"1C",19:"41"},35=e=="2h"?["56","6h"]:["55","6f"];G 52(){b=e=="2h"?d.8l:d.8j;I a=0,2t=0;D.M(35,G(){a+=2Q(D.24(d,"4X"+6,Q))||0;2t+=2Q(D.24(d,"2t"+6+"3E",Q))||0});b-=27.8a(a+2t)}7(D(d).3C(":4d"))52();N D.6n(d,2A,52);H 27.2f(0,b)}H D.24(d,e,c)},24:G(f,l,k){I e,R=f.R;G 3D(b){7(!D.15.2g)H U;I a=3N.4W(b,T);H!a||a.5Y("3D")==""}7(l=="1t"&&D.15.1j){e=D.1J(R,"1t");H e==""?"1":e}7(D.15.2K&&l=="19"){I d=R.4T;R.4T="0 82 81";R.4T=d}7(l.1H(/4b/i))l=y;7(!k&&R&&R[l])e=R[l];N 7(3N.4W){7(l.1H(/4b/i))l="4b";l=l.1n(/([A-Z])/g,"-$1").3z();I c=3N.4W(f,T);7(c&&!3D(f))e=c.5Y(l);N{I g=[],2u=[],a=f,i=0;O(;a&&3D(a);a=a.1e)2u.62(a);O(;i<2u.J;i++)7(3D(2u[i])){g[i]=2u[i].R.19;2u[i].R.19="41"}e=l=="19"&&g[2u.J-1]!=T?"2H":(c&&c.5Y(l))||"";O(i=0;i<g.J;i++)7(g[i]!=T)2u[i].R.19=g[i]}7(l=="1t"&&e=="")e="1"}N 7(f.4c){I h=l.1n(/\\-(\\w)/g,G(a,b){H b.2l()});e=f.4c[l]||f.4c[h];7(!/^\\d+(2W)?$/i.11(e)&&/^\\d/.11(e)){I j=R.1u,7O=f.60.1u;f.60.1u=f.4c.1u;R.1u=e||0;e=R.aO+"2W";R.1u=j;f.60.1u=7O}}H e},4a:G(l,h){I k=[];h=h||S;7(1f h.3q==\'Y\')h=h.2s||h[0]&&h[0].2s||S;D.M(l,G(i,d){7(1f d==\'7L\')d+=\'\';7(!d)H;7(1f d=="1U"){d=d.1n(/(<(\\w+)[^>]*?)\\/>/g,G(b,a,c){H c.1H(/^(aM|42|7G|aK|4l|7C|aG|3l|aD|aC|aB)$/i)?b:a+"></"+c+">"});I f=D.3h(d).3z(),1x=h.3q("1x");I e=!f.1k("<ay")&&[1,"<2j 7u=\'7u\'>","</2j>"]||!f.1k("<au")&&[1,"<7s>","</7s>"]||f.1H(/^<(ar|1Z|aq|ap|ao)/)&&[1,"<21>","</21>"]||!f.1k("<4A")&&[2,"<21><1Z>","</1Z></21>"]||(!f.1k("<am")||!f.1k("<ak"))&&[3,"<21><1Z><4A>","</4A></1Z></21>"]||!f.1k("<7G")&&[2,"<21><1Z></1Z><7m>","</7m></21>"]||D.15.1j&&[1,"1x<1x>","</1x>"]||[0,"",""];1x.4h=e[1]+d+e[2];1D(e[0]--)1x=1x.5R;7(D.15.1j){I g=!f.1k("<21")&&f.1k("<1Z")<0?1x.1w&&1x.1w.3w:e[1]=="<21>"&&f.1k("<1Z")<0?1x.3w:[];O(I j=g.J-1;j>=0;--j)7(D.W(g[j],"1Z")&&!g[j].3w.J)g[j].1e.2Y(g[j]);7(/^\\s/.11(d))1x.2Z(h.5H(d.1H(/^\\s*/)[0]),1x.1w)}d=D.2c(1x.3w)}7(d.J===0&&(!D.W(d,"4z")&&!D.W(d,"2j")))H;7(d[0]==Y||D.W(d,"4z")||d.12)k.1E(d);N k=D.39(k,d)});H k},1J:G(d,f,c){7(!d||d.14==3||d.14==8)H Y;I e=!D.4j(d),3T=c!==Y,1j=D.15.1j;f=e&&D.2A[f]||f;7(d.2b){I g=/5v|3P|R/.11(f);7(f=="38"&&D.15.2g)d.1e.5G;7(f 1h d&&e&&!g){7(3T){7(f=="P"&&D.W(d,"4l")&&d.1e)7k"P aa a4\'t a1 9Y";d[f]=c}7(D.W(d,"4z")&&d.7g(f))H d.7g(f).72;H d[f]}7(1j&&e&&f=="R")H D.1J(d.R,"9X",c);7(3T)d.9W(f,""+c);I h=1j&&e&&g?d.4E(f,2):d.4E(f);H h===T?Y:h}7(1j&&f=="1t"){7(3T){d.6D=1;d.1G=(d.1G||"").1n(/7b\\([^)]*\\)/,"")+(3t(c)+\'\'=="9T"?"":"7b(1t="+c*78+")")}H d.1G&&d.1G.1k("1t=")>=0?(2Q(d.1G.1H(/1t=([^)]*)/)[1])/78)+\'\':""}f=f.1n(/-([a-z])/9P,G(a,b){H b.2l()});7(3T)d[f]=c;H d[f]},3h:G(a){H(a||"").1n(/^\\s+|\\s+$/g,"")},2c:G(b){I a=[];7(b!=T){I i=b.J;7(i==T||1f b==\'1U\'||b.4D)a[0]=b;N 1D(i)a[--i]=b[i]}H a},2C:G(b,a){O(I i=0,J=a.J;i<J;i++)7(a[i]===b)H i;H-1},39:G(a,b){I i=0,L,34=a.J;7(D.15.1j){1D(L=b[i++])7(L.14!=8)a[34++]=L}N 1D(L=b[i++])a[34++]=L;H a},4o:G(a){I c=[],2m={};1W{O(I i=0,J=a.J;i<J;i++){I b=D.K(a[i]);7(!2m[b]){2m[b]=Q;c.1E(a[i])}}}1V(e){c=a}H c},48:G(c,a,d){I b=[];O(I i=0,J=c.J;i<J;i++)7(!d!=!a(c[i],i))b.1E(c[i]);H b},2e:G(d,a){I c=[];O(I i=0,J=d.J;i<J;i++){I b=a(d[i],i);7(b!=T)c[c.J]=b}H c.73.1z([],c)}});I v=9M.9K.3z();D.15={5M:(v.1H(/.+(?:9I|9G|9E|9C)[\\/: ]([\\d.]+)/)||[0,\'0\'])[1],2g:/71/.11(v),2K:/2K/.11(v),1j:/1j/.11(v)&&!/2K/.11(v),3p:/3p/.11(v)&&!/(9z|71)/.11(v)};I y=D.15.1j?"7q":"70";D.1i({6Z:!D.15.1j||S.6X=="6W",2A:{"O":"9v","9s":"1F","4b":y,70:y,7q:y,9q:"9o",9n:"9m",9k:"9i",9h:"9f"}});D.M({6S:G(a){H a.1e},9e:G(a){H D.4M(a,"1e")},99:G(a){H D.31(a,2,"2z")},96:G(a){H D.31(a,2,"4y")},95:G(a){H D.4M(a,"2z")},94:G(a){H D.4M(a,"4y")},93:G(a){H D.5q(a.1e.1w,a)},91:G(a){H D.5q(a.1w)},6Q:G(a){H D.W(a,"90")?a.8Z||a.8Y.S:D.2c(a.3w)}},G(c,d){D.16[c]=G(b){I a=D.2e(6,d);7(b&&1f b=="1U")a=D.3b(b,a);H 6.2w(D.4o(a))}});D.M({6O:"3o",8W:"6I",2Z:"6F",8V:"5m",8T:"7e"},G(c,b){D.16[c]=G(){I a=1b;H 6.M(G(){O(I i=0,J=a.J;i<J;i++)D(a[i])[b](6)})}});D.M({8S:G(a){D.1J(6,a,"");7(6.14==1)6.5h(a)},8R:G(a){D.1F.17(6,a)},8Q:G(a){D.1F.1M(6,a)},8O:G(a){D.1F[D.1F.3G(6,a)?"1M":"17"](6,a)},1M:G(a){7(!a||D.1G(a,[6]).r.J){D("*",6).17([6]).M(G(){D.V.1M(6);D.2T(6)});7(6.1e)6.1e.2Y(6)}},4B:G(){D(">*",6).1M();1D(6.1w)6.2Y(6.1w)}},G(a,b){D.16[a]=G(){H 6.M(b,1b)}});D.M(["6N","3E"],G(i,c){I b=c.3z();D.16[b]=G(a){H 6[0]==1c?D.15.2K&&S.1a["5p"+c]||D.15.2g&&1c["5o"+c]||S.6X=="6W"&&S.1y["5p"+c]||S.1a["5p"+c]:6[0]==S?27.2f(27.2f(S.1a["4t"+c],S.1y["4t"+c]),27.2f(S.1a["2d"+c],S.1y["2d"+c])):a==Y?(6.J?D.1g(6[0],b):T):6.1g(b,a.1I==4Z?a:a+"2W")}});G 26(a,b){H a[0]&&3t(D.24(a[0],b,Q),10)||0}I C=D.15.2g&&3t(D.15.5M)<8M?"(?:[\\\\w*3j-]|\\\\\\\\.)":"(?:[\\\\w\\8L-\\8K*3j-]|\\\\\\\\.)",6J=2p 4s("^>\\\\s*("+C+"+)"),6H=2p 4s("^("+C+"+)(#)("+C+"+)"),6G=2p 4s("^([#.]?)("+C+"*)");D.1i({6E:{"":G(a,i,m){H m[2]=="*"||D.W(a,m[2])},"#":G(a,i,m){H a.4E("2q")==m[2]},":":{8H:G(a,i,m){H i<m[3]-0},8G:G(a,i,m){H i>m[3]-0},31:G(a,i,m){H m[3]-0==i},7c:G(a,i,m){H m[3]-0==i},3k:G(a,i){H i==0},3O:G(a,i,m,r){H i==r.J-1},6C:G(a,i){H i%2==0},6B:G(a,i){H i%2},"3k-4r":G(a){H a.1e.3U("*")[0]==a},"3O-4r":G(a){H D.31(a.1e.5R,1,"4y")==a},"8E-4r":G(a){H!D.31(a.1e.5R,2,"4y")},6S:G(a){H a.1w},4B:G(a){H!a.1w},8C:G(a,i,m){H(a.6P||a.8B||D(a).1p()||"").1k(m[3])>=0},4d:G(a){H"1C"!=a.P&&D.1g(a,"19")!="2H"&&D.1g(a,"59")!="1C"},1C:G(a){H"1C"==a.P||D.1g(a,"19")=="2H"||D.1g(a,"59")=="1C"},8z:G(a){H!a.3M},3M:G(a){H a.3M},4F:G(a){H a.4F},38:G(a){H a.38||D.1J(a,"38")},1p:G(a){H"1p"==a.P},5Q:G(a){H"5Q"==a.P},5P:G(a){H"5P"==a.P},5k:G(a){H"5k"==a.P},3L:G(a){H"3L"==a.P},5j:G(a){H"5j"==a.P},6y:G(a){H"6y"==a.P},6x:G(a){H"6x"==a.P},2k:G(a){H"2k"==a.P||D.W(a,"2k")},4l:G(a){H/4l|2j|6w|2k/i.11(a.W)},3G:G(a,i,m){H D.2r(m[3],a).J},8x:G(a){H/h\\d/i.11(a.W)},8w:G(a){H D.48(D.3J,G(b){H a==b.L}).J}}},6v:[/^(\\[) *@?([\\w:-]+) *([!*$^~=]*) *(\'?"?)(.*?)\\4 *\\]/,/^(:)([\\w-]+)\\("?\'?(.*?(\\(.*?\\))?[^(]*?)"?\'?\\)/,2p 4s("^([:.#]*)("+C+"+)")],3b:G(a,c,b){I d,1s=[];1D(a&&a!=d){d=a;I f=D.1G(a,c,b);a=f.t.1n(/^\\s*,\\s*/,"");1s=b?c=f.r:D.39(1s,f.r)}H 1s},2r:G(t,o){7(1f t!="1U")H[t];7(o&&o.14!=1&&o.14!=9)H[];o=o||S;I d=[o],2m=[],3O,W;1D(t&&3O!=t){I r=[];3O=t;t=D.3h(t);I l=U,3g=6J,m=3g.2J(t);7(m){W=m[1].2l();O(I i=0;d[i];i++)O(I c=d[i].1w;c;c=c.2z)7(c.14==1&&(W=="*"||c.W.2l()==W))r.1E(c);d=r;t=t.1n(3g,"");7(t.1k(" ")==0)6M;l=Q}N{3g=/^([>+~])\\s*(\\w*)/i;7((m=3g.2J(t))!=T){r=[];I k={};W=m[2].2l();m=m[1];O(I j=0,3f=d.J;j<3f;j++){I n=m=="~"||m=="+"?d[j].2z:d[j].1w;O(;n;n=n.2z)7(n.14==1){I g=D.K(n);7(m=="~"&&k[g])1R;7(!W||n.W.2l()==W){7(m=="~")k[g]=Q;r.1E(n)}7(m=="+")1R}}d=r;t=D.3h(t.1n(3g,""));l=Q}}7(t&&!l){7(!t.1k(",")){7(o==d[0])d.4m();2m=D.39(2m,d);r=d=[o];t=" "+t.6t(1,t.J)}N{I h=6H;I m=h.2J(t);7(m){m=[0,m[2],m[3],m[1]]}N{h=6G;m=h.2J(t)}m[2]=m[2].1n(/\\\\/g,"");I f=d[d.J-1];7(m[1]=="#"&&f&&f.5W&&!D.4j(f)){I p=f.5W(m[2]);7((D.15.1j||D.15.2K)&&p&&1f p.2q=="1U"&&p.2q!=m[2])p=D(\'[@2q="\'+m[2]+\'"]\',f)[0];d=r=p&&(!m[3]||D.W(p,m[3]))?[p]:[]}N{O(I i=0;d[i];i++){I a=m[1]=="#"&&m[3]?m[3]:m[1]!=""||m[0]==""?"*":m[2];7(a=="*"&&d[i].W.3z()=="3r")a="3l";r=D.39(r,d[i].3U(a))}7(m[1]==".")r=D.5i(r,m[2]);7(m[1]=="#"){I e=[];O(I i=0;r[i];i++)7(r[i].4E("2q")==m[2]){e=[r[i]];1R}r=e}d=r}t=t.1n(h,"")}}7(t){I b=D.1G(t,r);d=r=b.r;t=D.3h(b.t)}}7(t)d=[];7(d&&o==d[0])d.4m();2m=D.39(2m,d);H 2m},5i:G(r,m,a){m=" "+m+" ";I c=[];O(I i=0;r[i];i++){I b=(" "+r[i].1F+" ").1k(m)>=0;7(!a&&b||a&&!b)c.1E(r[i])}H c},1G:G(t,r,h){I d;1D(t&&t!=d){d=t;I p=D.6v,m;O(I i=0;p[i];i++){m=p[i].2J(t);7(m){t=t.8v(m[0].J);m[2]=m[2].1n(/\\\\/g,"");1R}}7(!m)1R;7(m[1]==":"&&m[2]=="4V")r=61.11(m[3])?D.1G(m[3],r,Q).r:D(r).4V(m[3]);N 7(m[1]==".")r=D.5i(r,m[2],h);N 7(m[1]=="["){I g=[],P=m[3];O(I i=0,3f=r.J;i<3f;i++){I a=r[i],z=a[D.2A[m[2]]||m[2]];7(z==T||/R|5v|3P|38/.11(m[2]))z=D.1J(a,m[2])||\'\';7((P==""&&!!z||P=="="&&z==m[5]||P=="!="&&z!=m[5]||P=="^="&&z&&!z.1k(m[5])||P=="$="&&z.6t(z.J-m[5].J)==m[5]||(P=="*="||P=="~=")&&z.1k(m[5])>=0)^h)g.1E(a)}r=g}N 7(m[1]==":"&&m[2]=="31-4r"){I e={},g=[],11=/(-?)(\\d*)n((?:\\+|-)?\\d*)/.2J(m[3]=="6C"&&"2n"||m[3]=="6B"&&"2n+1"||!/\\D/.11(m[3])&&"8u+"+m[3]||m[3]),3k=(11[1]+(11[2]||1))-0,d=11[3]-0;O(I i=0,3f=r.J;i<3f;i++){I j=r[i],1e=j.1e,2q=D.K(1e);7(!e[2q]){I c=1;O(I n=1e.1w;n;n=n.2z)7(n.14==1)n.4k=c++;e[2q]=Q}I b=U;7(3k==0){7(j.4k==d)b=Q}N 7((j.4k-d)%3k==0&&(j.4k-d)/3k>=0)b=Q;7(b^h)g.1E(j)}r=g}N{I f=D.6E[m[1]];7(1f f=="3r")f=f[m[2]];7(1f f=="1U")f=6s("U||G(a,i){H "+f+";}");r=D.48(r,G(a,i){H f(a,i,m,r)},h)}}H{r:r,t:t}},4M:G(b,c){I a=[],1s=b[c];1D(1s&&1s!=S){7(1s.14==1)a.1E(1s);1s=1s[c]}H a},31:G(a,e,c,b){e=e||1;I d=0;O(;a;a=a[c])7(a.14==1&&++d==e)1R;H a},5q:G(n,a){I r=[];O(;n;n=n.2z){7(n.14==1&&n!=a)r.1E(n)}H r}});D.V={17:G(f,i,g,e){7(f.14==3||f.14==8)H;7(D.15.1j&&f.4D)f=1c;7(!g.25)g.25=6.25++;7(e!=Y){I h=g;g=6.3Q(h,G(){H h.1z(6,1b)});g.K=e}I j=D.K(f,"2E")||D.K(f,"2E",{}),1q=D.K(f,"1q")||D.K(f,"1q",G(){7(1f D!="Y"&&!D.V.5g)H D.V.1q.1z(1b.3H.L,1b)});1q.L=f;D.M(i.1Y(/\\s+/),G(c,b){I a=b.1Y(".");b=a[0];g.P=a[1];I d=j[b];7(!d){d=j[b]={};7(!D.V.3y[b]||D.V.3y[b].5f.1m(f,e)===U){7(f.47)f.47(b,1q,U);N 7(f.6p)f.6p("4w"+b,1q)}}d[g.25]=g;D.V.2a[b]=Q});f=T},25:1,2a:{},1M:G(e,h,f){7(e.14==3||e.14==8)H;I i=D.K(e,"2E"),1N,5d;7(i){7(h==Y||(1f h=="1U"&&h.8t(0)=="."))O(I g 1h i)6.1M(e,g+(h||""));N{7(h.P){f=h.5z;h=h.P}D.M(h.1Y(/\\s+/),G(b,a){I c=a.1Y(".");a=c[0];7(i[a]){7(f)2R i[a][f.25];N O(f 1h i[a])7(!c[1]||i[a][f].P==c[1])2R i[a][f];O(1N 1h i[a])1R;7(!1N){7(!D.V.3y[a]||D.V.3y[a].5b.1m(e)===U){7(e.6m)e.6m(a,D.K(e,"1q"),U);N 7(e.6l)e.6l("4w"+a,D.K(e,"1q"))}1N=T;2R i[a]}}})}O(1N 1h i)1R;7(!1N){I d=D.K(e,"1q");7(d)d.L=T;D.2T(e,"2E");D.2T(e,"1q")}}},1S:G(h,c,f,g,i){c=D.2c(c);7(h.1k("!")>=0){h=h.3u(0,-1);I a=Q}7(!f){7(6.2a[h])D.M(D.1v,G(){7(6.2E&&6.2E[h])D.V.1S(h,c,6.1q.L)})}N{7(f.14==3||f.14==8)H Y;I b,1N,16=D.1A(f[h]||T),V=!c[0]||!c[0].32;7(V){c.62({P:h,2y:f,32:G(){},3e:G(){},40:40,4i:1B()});c[0][E]=Q}c[0].P=h;7(a)c[0].6k=Q;I d=D.K(f,"1q");7(d)b=d.1z(f,c);7((!16||(D.W(f,\'a\')&&h=="4C"))&&f["4w"+h]&&f["4w"+h].1z(f,c)===U)b=U;7(V)c.4m();7(i&&D.1A(i)){1N=i.1z(f,b==T?c:c.73(b));7(1N!==Y)b=1N}7(16&&g!==U&&b!==U&&!(D.W(f,\'a\')&&h=="4C")){6.5g=Q;1W{f[h]()}1V(e){}}6.5g=U}H b},1q:G(b){I a,1N,2P,58,4g;b=1b[0]=D.V.6j(b||1c.V);2P=b.P.1Y(".");b.P=2P[0];2P=2P[1];58=!2P&&!b.6k;4g=(D.K(6,"2E")||{})[b.P];O(I j 1h 4g){I c=4g[j];7(58||c.P==2P){b.5z=c;b.K=c.K;1N=c.1z(6,1b);7(a!==U)a=1N;7(1N===U){b.32();b.3e()}7(b.6i)1R}}H a},2A:"8s 8r 8q 8p 2k 8o 3F 54 6e 53 8n K 8m 8k 4f 5z 51 50 8i 8h 4Y 6d 8f 8d 4e 8b 89 88 6b 2y 4i 6a P 87 86 35".1Y(" "),6j:G(b){7(b[E])H b;I c=b;b={85:c};O(I i=6.2A.J,18;i;){18=6.2A[--i];b[18]=c[18]}b[E]=Q;b.32=G(){7(c.32)c.32();c.84=U};b.3e=G(){7(c.3e)c.3e();c.83=Q};b.40=40;b.4i=b.4i||1B();7(!b.2y)b.2y=b.6b||S;7(b.2y.14==3)b.2y=b.2y.1e;7(!b.4e&&b.4f)b.4e=b.4f==b.2y?b.6a:b.4f;7(b.4Y==T&&b.54!=T){I a=S.1y,1a=S.1a;b.4Y=b.54+(a&&a.2D||1a&&1a.2D||0)-(a.69||0);b.6d=b.6e+(a&&a.2I||1a&&1a.2I||0)-(a.68||0)}7(!b.35&&((b.3F||b.3F===0)?b.3F:b.51))b.35=b.3F||b.51;7(!b.50&&b.53)b.50=b.53;7(!b.35&&b.2k)b.35=(b.2k&1?1:(b.2k&2?3:(b.2k&4?2:0)));H b},3Q:G(a,b){b.25=a.25=a.25||b.25||6.25++;H b},3y:{28:{5f:5Z,5b:G(){}}}};G 40(){6.6i=1;6.3e()}7(!D.15.1j){I F=G(a){I b=a.4e;1D(b&&b!=6)1W{b=b.1e}1V(e){b=6}7(b!=6){a.P=a.K;D.V.1q.1z(6,1b)}};D.M({67:\'4U\',66:\'4S\'},G(b,a){D.V.3y[a]={5f:G(){D.V.17(6,b,F,a)},5b:G(){D.V.1M(6,b,F)}}})}D.16.1i({4p:G(c,a,b){H c=="4R"?6.2V(c,a,b):6.M(G(){D.V.17(6,c,b||a,b&&a)})},2V:G(d,b,c){I e=D.V.3Q(c||b,G(a){D(6).65(a,e);H(c||b).1z(6,1b)});H 6.M(G(){D.V.17(6,d,e,c&&b)})},65:G(a,b){H 6.M(G(){D.V.1M(6,a,b)})},1S:G(c,a,b){H 6.M(G(){D.V.1S(c,a,6,Q,b)})},5E:G(c,a,b){H 6[0]&&D.V.1S(c,a,6[0],U,b)},2i:G(b){I c=1b,i=1;1D(i<c.J)D.V.3Q(b,c[i++]);H 6.4C(D.V.3Q(b,G(a){6.4Q=(6.4Q||0)%i;a.32();H c[6.4Q++].1z(6,1b)||U}))},80:G(a,b){H 6.4U(a).4S(b)},28:G(a){5Z();7(D.2M)a.1m(S,D);N D.3A.1E(G(){H a.1m(6,D)});H 6}});D.1i({2M:U,3A:[],28:G(){7(!D.2M){D.2M=Q;7(D.3A){D.M(D.3A,G(){6.1m(S)});D.3A=T}D(S).5E("28")}}});I x=U;G 5Z(){7(x)H;x=Q;7(S.47&&!D.15.2K)S.47("64",D.28,U);7(D.15.1j&&1c==1Q)(G(){7(D.2M)H;1W{S.1y.7Y("1u")}1V(49){3B(1b.3H,0);H}D.28()})();7(D.15.2K)S.47("64",G(){7(D.2M)H;O(I i=0;i<S.4O.J;i++)7(S.4O[i].3M){3B(1b.3H,0);H}D.28()},U);7(D.15.2g){I a;(G(){7(D.2M)H;7(S.3d!="63"&&S.3d!="1K"){3B(1b.3H,0);H}7(a===Y)a=D("R, 7C[7X=7W]").J;7(S.4O.J!=a){3B(1b.3H,0);H}D.28()})()}D.V.17(1c,"43",D.28)}D.M(("7V,7U,43,8c,4t,4R,4C,7S,"+"8e,7R,8g,67,66,4U,4S,"+"aU,2j,5j,aT,aS,aQ,49").1Y(","),G(i,b){D.16[b]=G(a){H a?6.4p(b,a):6.1S(b)}});D(1c).4p(\'4R\',G(){O(I a 1h D.1v)7(a!=1&&D.1v[a].1q)D.V.1M(D.1v[a].1q.L)});D.16.1i({7N:D.16.43,43:G(g,d,c){7(1f g!=\'1U\')H 6.7N(g);I e=g.1k(" ");7(e>=0){I i=g.3u(e,g.J);g=g.3u(0,e)}I f="3a";7(d)7(D.1A(d)){c=d;d=T}N 7(1f d==\'3r\'){d=D.3l(d);f="7M"}I h=6;D.3K({1d:g,P:f,1P:"2v",K:d,1K:G(a,b){7(b=="23"||b=="7K")h.2v(i?D("<1x/>").3o(a.4N.1n(/<1l(.|\\s)*?\\/1l>/g,"")).2r(i):a.4N);7(c)h.M(c,[a.4N,b,a])}});H 6},aL:G(){H D.3l(6.7J())},7J:G(){H 6.2e(G(){H 6.7I?D.2c(6.7I):6}).1G(G(){H 6.30&&!6.3M&&(6.4F||/2j|6w/i.11(6.W)||/1p|1C|3L/i.11(6.P))}).2e(G(i,c){I b=D(6).4P();H b==T?T:b.1I==2x?D.2e(b,G(a,i){H{30:c.30,2L:a}}):{30:c.30,2L:b}}).3m()}});D.M("7H,6g,6A,7F,7E,7D".1Y(","),G(i,o){D.16[o]=G(f){H 6.4p(o,f)}});I B=1B();D.1i({3m:G(d,b,a,c){7(D.1A(b)){a=b;b=T}H D.3K({P:"3a",1d:d,K:b,23:a,1P:c})},aJ:G(b,a){H D.3m(b,T,a,"1l")},aH:G(c,b,a){H D.3m(c,b,a,"3s")},aF:G(d,b,a,c){7(D.1A(b)){a=b;b={}}H D.3K({P:"7M",1d:d,K:b,23:a,1P:c})},aE:G(a){D.1i(D.5V,a)},5V:{1d:4L.5v,2a:Q,P:"3a",2U:0,7z:"4q/x-aA-4z-az",7x:Q,2O:Q,K:T,5S:T,3L:T,7w:G(){H 1c.7v?2p 7v("ax.av"):2p 7t()},4u:{2G:"4q/2G, 1p/2G",2v:"1p/2v",1l:"1p/4n, 4q/4n",3s:"4q/3s, 1p/4n",1p:"1p/as",3n:"*/*"}},4K:{},3K:G(s){s=D.1i(Q,s,D.1i(Q,{},D.5V,s));I g,37=/=\\?(&|$)/g,1r,K,P=s.P.2l();7(s.K&&s.7x&&1f s.K!="1U")s.K=D.3l(s.K);7(s.1P=="4J"){7(P=="3a"){7(!s.1d.1H(37))s.1d+=(s.1d.1H(/\\?/)?"&":"?")+(s.4J||"7r")+"=?"}N 7(!s.K||!s.K.1H(37))s.K=(s.K?s.K+"&":"")+(s.4J||"7r")+"=?";s.1P="3s"}7(s.1P=="3s"&&(s.K&&s.K.1H(37)||s.1d.1H(37))){g="4J"+B++;7(s.K)s.K=(s.K+"").1n(37,"="+g+"$1");s.1d=s.1d.1n(37,"="+g+"$1");s.1P="1l";1c[g]=G(a){K=a;23();1K();1c[g]=Y;1W{2R 1c[g]}1V(e){}7(i)i.2Y(h)}}7(s.1P=="1l"&&s.1v==T)s.1v=U;7(s.1v===U&&P=="3a"){I j=1B();I k=s.1d.1n(/(\\?|&)3j=.*?(&|$)/,"$an="+j+"$2");s.1d=k+((k==s.1d)?(s.1d.1H(/\\?/)?"&":"?")+"3j="+j:"")}7(s.K&&P=="3a"){s.1d+=(s.1d.1H(/\\?/)?"&":"?")+s.K;s.K=T}7(s.2a&&!D.4I++)D.V.1S("7H");I m=/^(\\w+:)?\\/\\/([^\\/?#]+)/.2J(s.1d);7(s.1P=="1l"&&P=="3a"&&m&&(m[1]&&m[1]!=4L.7p||m[2]!=4L.al)){I i=S.3U("6u")[0];I h=S.3q("1l");h.3P=s.1d;7(s.7o)h.aj=s.7o;7(!g){I l=U;h.ai=h.ah=G(){7(!l&&(!6.3d||6.3d=="63"||6.3d=="1K")){l=Q;23();1K();i.2Y(h)}}}i.3R(h);H Y}I n=U;I c=s.7w();7(s.5S)c.7l(P,s.1d,s.2O,s.5S,s.3L);N c.7l(P,s.1d,s.2O);1W{7(s.K)c.4G("ag-af",s.7z);7(s.5O)c.4G("ae-5N-ad",D.4K[s.1d]||"ac, ab a8 a6 5K:5K:5K a3");c.4G("X-a2-a0","7t");c.4G("9Z",s.1P&&s.4u[s.1P]?s.4u[s.1P]+", */*":s.4u.3n)}1V(e){}7(s.7i&&s.7i(c,s)===U){s.2a&&D.4I--;c.7h();H U}7(s.2a)D.V.1S("7D",[c,s]);I d=G(a){7(!n&&c&&(c.3d==4||a=="2U")){n=Q;7(f){7f(f);f=T}1r=a=="2U"?"2U":!D.6T(c)?"49":s.5O&&D.6U(c,s.1d)?"7K":"23";7(1r=="23"){1W{K=D.6V(c,s.1P,s)}1V(e){1r="5J"}}7(1r=="23"){I b;1W{b=c.5I("7d-5N")}1V(e){}7(s.5O&&b)D.4K[s.1d]=b;7(!g)23()}N D.5D(s,c,1r);1K();7(s.2O)c=T}};7(s.2O){I f=4D(d,13);7(s.2U>0)3B(G(){7(c){c.7h();7(!n)d("2U")}},s.2U)}1W{c.9V(s.K)}1V(e){D.5D(s,c,T,e)}7(!s.2O)d();G 23(){7(s.23)s.23(K,1r);7(s.2a)D.V.1S("7E",[c,s])}G 1K(){7(s.1K)s.1K(c,1r);7(s.2a)D.V.1S("6A",[c,s]);7(s.2a&&!--D.4I)D.V.1S("6g")}H c},5D:G(s,a,b,e){7(s.49)s.49(a,b,e);7(s.2a)D.V.1S("7F",[a,s,e])},4I:0,6T:G(a){1W{H!a.1r&&4L.7p=="5k:"||(a.1r>=7a&&a.1r<9U)||a.1r==79||a.1r==9S||D.15.2g&&a.1r==Y}1V(e){}H U},6U:G(a,c){1W{I b=a.5I("7d-5N");H a.1r==79||b==D.4K[c]||D.15.2g&&a.1r==Y}1V(e){}H U},6V:G(a,b,s){I c=a.5I("9R-P"),2G=b=="2G"||!b&&c&&c.1k("2G")>=0,K=2G?a.9Q:a.4N;7(2G&&K.1y.2b=="5J")7k"5J";7(s&&s.77)K=s.77(K,b);7(1f K==\'1U\'){7(b=="1l")D.5r(K);7(b=="3s")K=6s("("+K+")")}H K},3l:G(a){I s=[];G 17(b,a){s[s.J]=76(b)+\'=\'+76(a)};7(a.1I==2x||a.5t)D.M(a,G(){17(6.30,6.2L)});N O(I j 1h a)7(a[j]&&a[j].1I==2x)D.M(a[j],G(){17(j,6)});N 17(j,D.1A(a[j])?a[j]():a[j]);H s.6q("&").1n(/%20/g,"+")}});D.16.1i({1L:G(c,b){H c?6.3v({1X:"1L",2h:"1L",1t:"1L"},c,b):6.1G(":1C").M(G(){6.R.19=6.5F||"";7(D.1g(6,"19")=="2H"){I a=D("<"+6.2b+" />").6O("1a");6.R.19=a.1g("19");7(6.R.19=="2H")6.R.19="41";a.1M()}}).3i()},1O:G(b,a){H b?6.3v({1X:"1O",2h:"1O",1t:"1O"},b,a):6.1G(":4d").M(G(){6.5F=6.5F||D.1g(6,"19");6.R.19="2H"}).3i()},75:D.16.2i,2i:G(a,b){H D.1A(a)&&D.1A(b)?6.75.1z(6,1b):a?6.3v({1X:"2i",2h:"2i",1t:"2i"},a,b):6.M(G(){D(6)[D(6).3C(":1C")?"1L":"1O"]()})},9N:G(c,a,b){H 6.3v({1t:a},c,b)},3v:G(k,j,i,g){I h=D.74(j,i,g);H 6[h.2N===U?"M":"2N"](G(){I f=D.1i({},h),p,1C=6.14==1&&D(6).3C(":1C"),3Y=6;O(p 1h k){7(k[p]=="1O"&&1C||k[p]=="1L"&&!1C)H f.1K.1m(6);7((p=="1X"||p=="2h")&&6.R){f.19=D.1g(6,"19");f.33=6.R.33}}7(f.33!=T)6.R.33="1C";f.3Z=D.1i({},k);D.M(k,G(c,a){I e=2p D.22(3Y,f,c);7(/2i|1L|1O/.11(a))e[a=="2i"?1C?"1L":"1O":a](k);N{I b=a.6o().1H(/^([+-]=)?([\\d+-.]+)(.*)$/),29=e.1s(Q)||0;7(b){I d=2Q(b[2]),2F=b[3]||"2W";7(2F!="2W"){3Y.R[c]=(d||1)+2F;29=((d||1)/e.1s(Q))*29;3Y.R[c]=29+2F}7(b[1])d=((b[1]=="-="?-1:1)*d)+29;e.3X(29,d,2F)}N e.3X(29,a,"")}});H Q})},2N:G(a,b){7(D.1A(a)||(a&&a.1I==2x)){b=a;a="22"}7(!a||(1f a=="1U"&&!b))H A(6[0],a);H 6.M(G(){7(b.1I==2x)A(6,a,b);N{A(6,a).1E(b);7(A(6,a).J==1)b.1m(6)}})},9J:G(b,c){I a=D.3J;7(b)6.2N([]);6.M(G(){O(I i=a.J-1;i>=0;i--)7(a[i].L==6){7(c)a[i](Q);a.7j(i,1)}});7(!c)6.5x();H 6}});D.M({9H:{1X:"1L"},9F:{1X:"1O"},a5:{1X:"2i"},9D:{1t:"1L"},a7:{1t:"1O"}},G(c,d){D.16[c]=G(b,a){H 6.3v(d,b,a)}});I A=G(b,c,a){7(b){c=c||"22";I q=D.K(b,c+"2N");7(!q||a)q=D.K(b,c+"2N",D.2c(a))}H q};D.16.5x=G(a){a=a||"22";H 6.M(G(){I q=A(6,a);q.4m();7(q.J)q[0].1m(6)})};D.1i({74:G(b,a,c){I d=b&&b.1I==a9?b:{1K:c||!c&&a||D.1A(b)&&b,2B:b,45:c&&a||a&&a.1I!=6z&&a};d.2B=D.22.9B?0:1f d.2B==\'7L\'?d.2B:D.22.5A[d.2B]||D.22.5A.3n;d.5L=d.1K;d.1K=G(){7(d.2N!==U)D(6).5x();7(D.1A(d.5L))d.5L.1m(6)};H d},45:{7Q:G(p,n,b,a){H b+a*p},5T:G(p,n,b,a){H((-27.9y(p*27.9x)/2)+0.5)*a+b}},3J:[],3W:T,22:G(b,c,a){6.12=c;6.L=b;6.18=a;7(!c.3V)c.3V={}}});D.22.46={5y:G(){7(6.12.36)6.12.36.1m(6.L,6.1B,6);(D.22.36[6.18]||D.22.36.3n)(6);7((6.18=="1X"||6.18=="2h")&&6.L.R)6.L.R.19="41"},1s:G(a){7(6.L[6.18]!=T&&(!6.L.R||6.L.R[6.18]==T))H 6.L[6.18];I r=2Q(D.1g(6.L,6.18,a));H r&&r>-9w?r:2Q(D.24(6.L,6.18))||0},3X:G(c,b,d){6.5s=1B();6.29=c;6.3i=b;6.2F=d||6.2F||"2W";6.1B=6.29;6.34=6.4x=0;I e=6;G t(a){H e.36(a)}t.L=6.L;D.3J.1E(t);7(t()&&D.3W==T){D.3W=4D(G(){I a=D.3J;O(I i=0;i<a.J;i++)7(!a[i]())a.7j(i--,1);7(!a.J){7f(D.3W);D.3W=T}},13)}},1L:G(){6.12.3V[6.18]=D.1J(6.L.R,6.18);6.12.1L=Q;6.3X(0,6.1s());7(6.18=="2h"||6.18=="1X")6.L.R[6.18]="9u";D(6.L).1L()},1O:G(){6.12.3V[6.18]=D.1J(6.L.R,6.18);6.12.1O=Q;6.3X(6.1s(),0)},36:G(a){I t=1B();7(a||t>=6.12.2B+6.5s){6.1B=6.3i;6.34=6.4x=1;6.5y();6.12.3Z[6.18]=Q;I b=Q;O(I i 1h 6.12.3Z)7(6.12.3Z[i]!==Q)b=U;7(b){7(6.12.19!=T){6.L.R.33=6.12.33;6.L.R.19=6.12.19;7(D.1g(6.L,"19")=="2H")6.L.R.19="41"}7(6.12.1O)6.L.R.19="2H";7(6.12.1O||6.12.1L)O(I p 1h 6.12.3Z)D.1J(6.L.R,p,6.12.3V[p])}7(b)6.12.1K.1m(6.L);H U}N{I n=t-6.5s;6.4x=n/6.12.2B;6.34=D.45[6.12.45||(D.45.5T?"5T":"7Q")](6.4x,n,0,1,6.12.2B);6.1B=6.29+((6.3i-6.29)*6.34);6.5y()}H Q}};D.1i(D.22,{5A:{9t:9r,at:7a,3n:9p},36:{1t:G(a){D.1J(a.L.R,"1t",a.1B)},3n:G(a){7(a.18 1h a.L)a.L[a.18]=a.1B;N 7(a.L.R)a.L.R[a.18]=a.1B+a.2F}}});D.16.2d=G(){I b=0,1Q=0,L=6[0],3x;7(L)aw(D.15){I d=L.1e,3S=L,1o=L.1o,1T=L.2s,5w=2g&&3t(5M)<9l&&!/9j/i.11(v),1g=D.24,2S=1g(L,"2X")=="2S";7(!(3p&&L==S.1a)&&L.7B){I c=L.7B();17(c.1u+27.2f(1T.1y.2D,1T.1a.2D),c.1Q+27.2f(1T.1y.2I,1T.1a.2I));17(-1T.1y.69,-1T.1y.68)}N{17(L.5U,L.5u);1D(1o){17(1o.5U,1o.5u);7(3p&&!/^t(9g|d|h)$/i.11(1o.2b)||2g&&!5w)2t(1o);7(!2S&&1g(1o,"2X")=="2S")2S=Q;3S=/^1a$/i.11(1o.2b)?3S:1o;1o=1o.1o}1D(d&&d.2b&&!/^1a|2v$/i.11(d.2b)){7(!/^aI|21.*$/i.11(1g(d,"19")))17(-d.2D,-d.2I);7(3p&&1g(d,"33")!="4d")2t(d);d=d.1e}7((5w&&(2S||1g(3S,"2X")=="5a"))||(3p&&1g(3S,"2X")!="5a"))17(-1T.1a.5U,-1T.1a.5u);7(2S)17(27.2f(1T.1y.2D,1T.1a.2D),27.2f(1T.1y.2I,1T.1a.2I))}3x={1Q:1Q,1u:b}}G 2t(a){17(D.24(a,"7y",Q),D.24(a,"7A",Q))}G 17(l,t){b+=3t(l,10)||0;1Q+=3t(t,10)||0}H 3x};D.16.1i({2X:G(){I a=0,1Q=0,3x;7(6[0]){I b=6.1o(),2d=6.2d(),3I=/^1a|2v$/i.11(b[0].2b)?{1Q:0,1u:0}:b.2d();2d.1Q-=26(6,\'9d\');2d.1u-=26(6,\'aN\');3I.1Q+=26(b,\'7A\');3I.1u+=26(b,\'7y\');3x={1Q:2d.1Q-3I.1Q,1u:2d.1u-3I.1u}}H 3x},1o:G(){I a=6[0].1o||S.1a;1D(a&&(!/^1a|2v$/i.11(a.2b)&&D.1g(a,\'2X\')==\'9b\'))a=a.1o;H D(a)}});D.M([\'56\',\'55\'],G(i,b){I c=\'4t\'+b;D.16[c]=G(a){7(!6[0])H;H a!=Y?6.M(G(){6==1c||6==S?1c.9a(!i?a:D(1c).2D(),i?a:D(1c).2I()):6[c]=a}):6[0]==1c||6[0]==S?3Y[i?\'98\':\'aR\']||D.6Z&&S.1y[c]||S.1a[c]:6[0][c]}});D.M(["6N","3E"],G(i,b){I c=i?"56":"55",42=i?"6h":"6f";D.16["5o"+b]=G(){H 6[b.3z()]()+26(6,"4X"+c)+26(6,"4X"+42)};D.16["97"+b]=G(a){H 6["5o"+b]()+26(6,"2t"+c+"3E")+26(6,"2t"+42+"3E")+(a?26(6,"6R"+c)+26(6,"6R"+42):0)}})})();', 62, 677, '||||||this|if|||||||||||||||||||||||||||||||||||function|return|var|length|data|elem|each|else|for|type|true|style|document|null|false|event|nodeName||undefined|||test|options||nodeType|browser|fn|add|prop|display|body|arguments|window|url|parentNode|typeof|css|in|extend|msie|indexOf|script|call|replace|offsetParent|text|handle|status|cur|opacity|left|cache|firstChild|div|documentElement|apply|isFunction|now|hidden|while|push|className|filter|match|constructor|attr|complete|show|remove|ret|hide|dataType|top|break|trigger|doc|string|catch|try|height|split|tbody||table|fx|success|curCSS|guid|num|Math|ready|start|global|tagName|makeArray|offset|map|max|safari|width|toggle|select|button|toUpperCase|done||copy|new|id|find|ownerDocument|border|stack|html|pushStack|Array|target|nextSibling|props|duration|inArray|scrollLeft|events|unit|xml|none|scrollTop|exec|opera|value|isReady|queue|async|namespace|parseFloat|delete|fixed|removeData|timeout|one|px|position|removeChild|insertBefore|name|nth|preventDefault|overflow|pos|which|step|jsre|selected|merge|GET|multiFilter|elems|readyState|stopPropagation|rl|re|trim|end|_|first|param|get|_default|append|mozilla|createElement|object|json|parseInt|slice|animate|childNodes|results|special|toLowerCase|readyList|setTimeout|is|color|Width|charCode|has|callee|parentOffset|timers|ajax|password|disabled|defaultView|last|src|proxy|appendChild|offsetChild|set|getElementsByTagName|orig|timerId|custom|self|curAnim|stopImmediatePropagation|block|br|load|domManip|easing|prototype|addEventListener|grep|error|clean|float|currentStyle|visible|relatedTarget|fromElement|handlers|innerHTML|timeStamp|isXMLDoc|nodeIndex|input|shift|javascript|unique|bind|application|child|RegExp|scroll|accepts|deep|on|state|previousSibling|form|tr|empty|click|setInterval|getAttribute|checked|setRequestHeader|jQuery|active|jsonp|lastModified|location|dir|responseText|styleSheets|val|lastToggle|unload|mouseleave|outline|mouseenter|not|getComputedStyle|padding|pageX|String|metaKey|keyCode|getWH|ctrlKey|clientX|Top|Left|andSelf|all|visibility|absolute|teardown|container|index|init|setup|triggered|removeAttribute|classFilter|submit|file|prevObject|after|windowData|inner|client|sibling|globalEval|startTime|jquery|offsetTop|href|safari2|dequeue|update|handler|speeds|clone|wrapAll|handleError|triggerHandler|oldblock|selectedIndex|createTextNode|getResponseHeader|parsererror|00|old|version|Modified|ifModified|checkbox|radio|lastChild|username|swing|offsetLeft|ajaxSettings|getElementById|values|getPropertyValue|bindReady|runtimeStyle|isSimple|unshift|loaded|DOMContentLoaded|unbind|mouseout|mouseover|clientTop|clientLeft|toElement|srcElement|option|pageY|clientY|Bottom|ajaxStop|Right|_sip|fix|exclusive|detachEvent|removeEventListener|swap|toString|attachEvent|join|cloneNode|eval|substr|head|parse|textarea|reset|image|Function|ajaxComplete|odd|even|zoom|expr|before|quickClass|quickID|prepend|quickChild|exclude|uuid|continue|Height|appendTo|textContent|contents|margin|parent|httpSuccess|httpNotModified|httpData|CSS1Compat|compatMode|setArray|boxModel|cssFloat|webkit|nodeValue|concat|speed|_toggle|encodeURIComponent|dataFilter|100|304|200|alpha|eq|Last|replaceWith|clearInterval|getAttributeNode|abort|beforeSend|splice|throw|open|colgroup|Number|scriptCharset|protocol|styleFloat|callback|fieldset|XMLHttpRequest|multiple|ActiveXObject|xhr|processData|borderLeftWidth|contentType|borderTopWidth|getBoundingClientRect|link|ajaxSend|ajaxSuccess|ajaxError|col|ajaxStart|elements|serializeArray|notmodified|number|POST|_load|rsLeft|evalScript|linear|mouseup|dblclick|attributes|focus|blur|stylesheet|rel|doScroll|hasClass|hover|black|solid|cancelBubble|returnValue|originalEvent|wheelDelta|view|shiftKey|screenY|round|screenX|resize|relatedNode|mousedown|prevValue|mousemove|originalTarget|newValue|offsetHeight|eventPhase|offsetWidth|detail|currentTarget|cancelable|bubbles|attrName|attrChange|altKey|charAt|0n|substring|animated|header|instanceof|enabled|hasOwnProperty|innerText|contains|noConflict|only|line|gt|lt|weight|font|uFFFF|u0128|417|size|toggleClass|Boolean|removeClass|addClass|removeAttr|replaceAll|7pre|insertAfter|prependTo|Date|contentWindow|contentDocument|iframe|children|wrap|siblings|prevAll|nextAll|prev|outer|pageYOffset|next|scrollTo|static|wrapInner|marginTop|parents|rowSpan|able|rowspan|cellSpacing|adobeair|cellspacing|522|maxLength|maxlength|readOnly|400|readonly|600|class|slow|1px|htmlFor|10000|PI|cos|compatible|reverse|off|ie|fadeIn|ra|slideUp|it|slideDown|rv|stop|userAgent|setData|navigator|fadeTo|getData|ig|responseXML|content|1223|NaN|300|send|setAttribute|cssText|changed|Accept|With|be|Requested|GMT|can|slideToggle|1970|fadeOut|Jan|Object|property|01|Thu|Since|If|Type|Content|onreadystatechange|onload|charset|th|host|td|1_|cap|colg|tfoot|thead|plain|fast|leg|XMLHTTP|with|Microsoft|opt|urlencoded|www|embed|area|hr|ajaxSetup|post|meta|getJSON|inline|getScript|img|serialize|abbr|marginLeft|pixelLeft|specified|keyup|pageXOffset|keypress|keydown|change'.split('|'), 0, {}));/*****************************************************************                                                              **  CurvyCorners                                                **  ------------                                                **                                                              **  This script generates rounded corners for your boxes.       **                                                              **  Version 2.1                                                 **  Copyright (c) 2010 Cameron Cooke                            **  Contributors: Tim Hutchison, CPK Smithies, Terry Rigel,     **                Simó Albert.                                  **                                                              **  Website: http://www.curvycorners.net                        **  SVN:     http://curvycorners.googlecode.com/                **  Email:   cameron@curvycorners.net                           **  Discuss: http://groups.google.com/group/curvycorners        **                                                              **  Please consult the SVN for a list of changes since the last **  revision.                                                   **                                                              **  This library is free software; you can redistribute         **  it and/or modify it under the terms of the GNU              **  Lesser General Public License as published by the           **  Free Software Foundation; either version 2.1 of the         **  License, or (at your option) any later version.             **                                                              **  This library is distributed in the hope that it will        **  be useful, but WITHOUT ANY WARRANTY; without even the       **  implied warranty of MERCHANTABILITY or FITNESS FOR A        **  PARTICULAR PURPOSE. See the GNU Lesser General Public       **  License for more details.                                   **                                                              **  You should have received a copy of the GNU Lesser           **  General Public License along with this library;             **  Inc., 59 Temple Place, Suite 330, Boston,                   **  MA 02111-1307 USA                                           **                                                              *****************************************************************//*Version 2.x now autoMagically applies borders via CSS rules.Opera and Chrome support rounded corners viaborder-radiusSafari and Mozilla support rounded borders via-webkit-border-radius, -moz-border-radiusWe let these browsers render their borders natively.Firefox for Windows renders non-antialiasedborders so they look a bit ugly. Google's Chrome will render its "ugly"borders as well. So if we let FireFox, Safari, Opera and Chrome rendertheir borders natively, then we only have to support IEfor rounded borders. Fortunately IE reads CSS propertiesthat it doesn't understand (Opera, Firefox and Safari discard them);so for IE we find and apply -moz-border-radius and friends.So to make curvycorners work with any major browser simply add thefollowing CSS declarations and it should be good to go....round {border-radius: 3ex;-webkit-border-radius: 3ex;-moz-border-radius: 3ex;}*/var curvyCornersVerbose = false;function browserdetect() {var agent = navigator.userAgent.toLowerCase();this.isIE = agent.indexOf("msie") > -1;if (this.isIE) {this.ieVer = /msie\s(\d\.\d)/.exec(agent)[1];this.quirksMode = !document.compatMode || document.compatMode.indexOf("BackCompat") > -1;this.get_style = function(obj, prop) {if (!(prop in obj.currentStyle)) return "";var matches = /^([\d.]+)(\w*)/.exec(obj.currentStyle[prop]);if (!matches) return obj.currentStyle[prop];if (matches[1] == 0) return '0';// now convert to pixels if necessaryif (matches[2] && matches[2] !== 'px') {var style = obj.style.left;var rtStyle = obj.runtimeStyle.left;obj.runtimeStyle.left = obj.currentStyle.left;obj.style.left = matches[1] + matches[2];matches[0] = obj.style.pixelLeft;obj.style.left = style;obj.runtimeStyle.left = rtStyle;}return matches[0];};this.supportsCorners = false;}else {this.ieVer = this.quirksMode = 0;this.get_style = function(obj, prop) {prop = prop.replace(/([a-z])([A-Z])/g, '$1-$2').toLowerCase();return document.defaultView.getComputedStyle(obj, '').getPropertyValue(prop);};this.isSafari = agent.indexOf('safari') != -1;this.isWebKit = agent.indexOf('webkit') != -1;this.isOp = 'opera' in window;if (this.isOp)this.supportsCorners = (this.isOp = window.opera.version()) >= 10.5;else {if (!this.isWebkit) { // firefox checkif (!(this.isMoz = agent.indexOf('firefox') !== -1)) {for (var i = document.childNodes.length; --i >= 0; ) if ('style' in document.childNodes[i]) {this.isMoz = 'MozBorderRadius' in document.childNodes[i];break;}}}this.supportsCorners = this.isWebKit || this.isMoz;}}}var curvyBrowser = new browserdetect;/* Force caching of bg images in IE6 */if (curvyBrowser.isIE) {try {document.execCommand("BackgroundImageCache", false, true);}catch (e) { };}// object that parses border-radius properties for a boxfunction curvyCnrSpec(selText) {this.selectorText = selText;this.tlR = this.trR = this.blR = this.brR = 0;this.tlu = this.tru = this.blu = this.bru = "";this.antiAlias = true; // default true}curvyCnrSpec.prototype.setcorner = function(tb, lr, radius, unit) {if (!tb) { // no corner specifiedthis.tlR = this.trR = this.blR = this.brR = parseInt(radius);this.tlu = this.tru = this.blu = this.bru = unit;}else { // corner specifiedpropname = tb.charAt(0) + lr.charAt(0);this[propname + 'R'] = parseInt(radius);this[propname + 'u'] = unit;}}/*get(propstring)where propstring is:- 'tR' or 'bR' : returns top or bottom radius.- 'tlR', 'trR', 'blR' or 'brR' : returns top/bottom left/right radius.- 'tlu', 'tru', 'blr' or 'bru' : returns t/b l/r unit (px, em...)- 'tRu' or 'bRu' : returns top/bottom radius+unit- 'tlRu', 'trRu', 'blRu', 'brRu' : returns t/b l/r radius+unit*/curvyCnrSpec.prototype.get = function(prop) {if (/^(t|b)(l|r)(R|u)$/.test(prop)) return this[prop];if (/^(t|b)(l|r)Ru$/.test(prop)) {var pname = prop.charAt(0) + prop.charAt(1);return this[pname + 'R'] + this[pname + 'u'];}if (/^(t|b)Ru?$/.test(prop)) {var tb = prop.charAt(0);tb += this[tb + 'lR'] > this[tb + 'rR'] ? 'l' : 'r';var retval = this[tb + 'R'];if (prop.length === 3 && prop.charAt(2) === 'u')retval += this[tb = 'u'];return retval;}throw new Error('Don\'t recognize property ' + prop);}curvyCnrSpec.prototype.radiusdiff = function(tb) {if (tb !== 't' && tb !== 'b') throw new Error("Param must be 't' or 'b'");return Math.abs(this[tb + 'lR'] - this[tb + 'rR']);}curvyCnrSpec.prototype.setfrom = function(obj) {this.tlu = this.tru = this.blu = this.bru = 'px'; // default to pxif ('tl' in obj) this.tlR = obj.tl.radius;if ('tr' in obj) this.trR = obj.tr.radius;if ('bl' in obj) this.blR = obj.bl.radius;if ('br' in obj) this.brR = obj.br.radius;if ('antiAlias' in obj) this.antiAlias = obj.antiAlias;};curvyCnrSpec.prototype.cloneOn = function(box) { // not needed by IEvar props = ['tl', 'tr', 'bl', 'br'];var converted = 0;var i, propu;for (i in props) if (!isNaN(i)) {propu = this[props[i] + 'u'];if (propu !== '' && propu !== 'px') {converted = new curvyCnrSpec;break;}}if (!converted)converted = this; // no need to cloneelse {var propi, propR, save = curvyBrowser.get_style(box, 'left');for (i in props) if (!isNaN(i)) {propi = props[i];propu = this[propi + 'u'];propR = this[propi + 'R'];if (propu !== 'px') {var save = box.style.left;box.style.left = propR + propu;propR = box.style.pixelLeft;box.style.left = save;}converted[propi + 'R'] = propR;converted[propi + 'u'] = 'px';}box.style.left = save;}return converted;}curvyCnrSpec.prototype.radiusSum = function(tb) {if (tb !== 't' && tb !== 'b') throw new Error("Param must be 't' or 'b'");return this[tb + 'lR'] + this[tb + 'rR'];}curvyCnrSpec.prototype.radiusCount = function(tb) {var count = 0;if (this[tb + 'lR']) ++count;if (this[tb + 'rR']) ++count;return count;}curvyCnrSpec.prototype.cornerNames = function() {var ret = [];if (this.tlR) ret.push('tl');if (this.trR) ret.push('tr');if (this.blR) ret.push('bl');if (this.brR) ret.push('br');return ret;}/*Object that parses Opera CSS*/function operasheet(sheetnumber) {var txt = document.styleSheets.item(sheetnumber).ownerNode.text;txt = txt.replace(/\/\*(\n|\r|.)*?\*\//g, ''); // strip comments// this pattern extracts all border-radius-containing rulesets// matches will be:// [0] = the whole lot// [1] = the selector text// [2] = all the rule text between braces// [3] = top/bottom and left/right parts if present (only if webkit/CSS3)// [4] = top|bottom// [5] = left|right// .. but 3..5 are useless as they're only the first match.var pat = new RegExp("^\\s*([\\w.#][-\\w.#, ]+)[\\n\\s]*\\{([^}]+border-((top|bottom)-(left|right)-)?radius[^}]*)\\}", "mg");var matches;this.rules = [];while ((matches = pat.exec(txt)) !== null) {var pat2 = new RegExp("(..)border-((top|bottom)-(left|right)-)?radius:\\s*([\\d.]+)(in|em|px|ex|pt)", "g");var submatches, cornerspec = new curvyCnrSpec(matches[1]);while ((submatches = pat2.exec(matches[2])) !== null)if (submatches[1] !== "z-")cornerspec.setcorner(submatches[3], submatches[4], submatches[5], submatches[6]);this.rules.push(cornerspec);}}// static class function to determine if the sheet is worth parsingoperasheet.contains_border_radius = function(sheetnumber) {return /border-((top|bottom)-(left|right)-)?radius/.test(document.styleSheets.item(sheetnumber).ownerNode.text);}/*Usage:curvyCorners(settingsObj, "selectorStr");curvyCorners(settingsObj, domObj1[, domObj2[, domObj3[, . . . [, domObjN]]]]);selectorStr::= "<complexSelector>[, <complexSelector>]..."complexSelector::= <selector>[ <selector]selector::= "[<elementname>].classname" | "#id"*/function curvyCorners() {var i, j, boxCol, settings, startIndex;// Check parametersif (typeof arguments[0] !== "object") throw curvyCorners.newError("First parameter of curvyCorners() must be an object.");if (arguments[0] instanceof curvyCnrSpec) {settings = arguments[0];if (!settings.selectorText && typeof arguments[1] === 'string')settings.selectorText = arguments[1];}else {if (typeof arguments[1] !== "object" && typeof arguments[1] !== "string") throw curvyCorners.newError("Second parameter of curvyCorners() must be an object or a class name.");j = arguments[1];if (typeof j !== 'string') j = '';if (j !== '' && j.charAt(0) !== '.' && 'autoPad' in arguments[0]) j = '.' + j; // for compatibility, prefix with dotsettings = new curvyCnrSpec(j);settings.setfrom(arguments[0]);}// Get object(s)if (settings.selectorText) {startIndex = 0;var args = settings.selectorText.replace(/\s+$/, '').split(/,\s*/); // handle comma-separated selector listboxCol = new Array;for (i = 0; i < args.length; ++i) {if ((j = args[i].lastIndexOf('#')) !== -1)args[i] = args[i].substr(j); // ignore everything on LHS of IDboxCol = boxCol.concat(curvyCorners.getElementsBySelector(args[i].split(/\s+/)));}}else {startIndex = 1;boxCol = arguments;}// Loop through each objectfor (i = startIndex, j = boxCol.length; i < j; ++i) {var theBox = boxCol[i];var skipCorners = false;if (!theBox.className)theBox.className = 'curvyIgnore'; // don't do it twiceelse {skipCorners = theBox.className.indexOf('curvyIgnore') !== -1;if (!skipCorners) theBox.className += ' curvyIgnore'; // prevent repeats}if (!skipCorners) {if (theBox.className.indexOf('curvyRedraw') !== -1) {if (typeof curvyCorners.redrawList === 'undefined') curvyCorners.redrawList = new Array;curvyCorners.redrawList.push({node: theBox,spec: settings,copy: theBox.cloneNode(false)});}var obj = new curvyObject(settings, theBox);obj.applyCorners();}}}curvyCorners.prototype.applyCornersToAll = function() { // now redundantthrow curvyCorners.newError('This function is now redundant. Just call curvyCorners(). See documentation.');};curvyCorners.redraw = function() {if (curvyBrowser.supportsCorners) return;if (!curvyCorners.redrawList) throw curvyCorners.newError('curvyCorners.redraw() has nothing to redraw.');var old_block_value = curvyCorners.block_redraw;curvyCorners.block_redraw = true;for (var i in curvyCorners.redrawList) {if (isNaN(i)) continue; // in case of added prototype methodsvar o = curvyCorners.redrawList[i];if (!o.node.clientWidth) continue; // don't resize hidden boxesvar newchild = o.copy.cloneNode(false);for (var contents = o.node.firstChild; contents != null; contents = contents.nextSibling)if (contents.className === 'autoPadDiv') break;if (!contents) {curvyCorners.alert('Couldn\'t find autoPad DIV');break;}o.node.parentNode.replaceChild(newchild, o.node);// remove script elements, if anyvar scripts = contents.getElementsByTagName('script');for (var j = scripts.length - 1; j >= 0; --j)scripts[j].parentNode.removeChild(scripts[j]);while (contents.firstChild) newchild.appendChild(contents.removeChild(contents.firstChild));o = new curvyObject(o.spec, o.node = newchild);o.applyCorners();}curvyCorners.block_redraw = old_block_value;}curvyCorners.adjust = function(obj, prop, newval) {if (!curvyBrowser.supportsCorners) {if (!curvyCorners.redrawList) throw curvyCorners.newError('curvyCorners.adjust() has nothing to adjust.');var i, j = curvyCorners.redrawList.length;for (i = 0; i < j; ++i) if (curvyCorners.redrawList[i].node === obj) break;if (i === j) throw curvyCorners.newError('Object not redrawable');obj = curvyCorners.redrawList[i].copy;}if (prop.indexOf('.') === -1)obj[prop] = newval;else eval('obj.' + prop + "='" + newval + "'");}curvyCorners.handleWinResize = function() {if (!curvyCorners.block_redraw) curvyCorners.redraw();}curvyCorners.setWinResize = function(onoff) {curvyCorners.block_redraw = !onoff;}curvyCorners.newError = function(errorMessage) {return new Error("curvyCorners Error:\n" + errorMessage)}curvyCorners.alert = function(errorMessage) {if (typeof curvyCornersVerbose === 'undefined' || curvyCornersVerbose) alert(errorMessage);}// curvyCorners object (can be called directly)function curvyObject() {var boxDisp;this.box = arguments[1];this.settings = arguments[0];this.topContainer = this.bottomContainer = this.shell = boxDisp = null;var boxWidth = this.box.clientWidth; // browser-independent IE-emulation (NB includes padding)if (('canHaveChildren' in this.box && !this.box.canHaveChildren) || this.box.tagName === 'TABLE')throw new Error(this.errmsg("You cannot apply corners to " + this.box.tagName + " elements.", "Error"));if (!boxWidth && curvyBrowser.isIE) {this.box.style.zoom = 1; // can force IE to calculate widthboxWidth = this.box.clientWidth;}// try to handle attempts to style inline elementsif (!boxWidth && curvyBrowser.get_style(this.box, 'display') === 'inline') {this.box.style.display = 'inline-block';curvyCorners.alert(this.errmsg("Converting inline element to inline-block", "warning"));boxWidth = this.box.clientWidth;}// if still no clientWidth, maybe the box or a parent has 'display:none'.if (!boxWidth) {if (!this.box.parentNode) throw this.newError("box has no parent!"); // unlikely...for (boxDisp = this.box; ; boxDisp = boxDisp.parentNode) {if (!boxDisp || boxDisp.tagName === 'BODY') { // we've hit the buffersthis.applyCorners = function() { } // make the error benigncurvyCorners.alert(this.errmsg("zero-width box with no accountable parent", "warning"));return;}if (curvyBrowser.get_style(boxDisp, 'display') === 'none') break;}// here, we've found the box whose display is set to 'none'.var boxDispSave = boxDisp.style.display;boxDisp.style.display = 'block'; // display in order to get browser to calculate clientWidthboxWidth = this.box.clientWidth;}// all attempts have failedif (!boxWidth) {curvyCorners.alert(this.errmsg("zero-width box, cannot display", "error"));this.applyCorners = function() { } // make the error harmlessreturn;}if (arguments[0] instanceof curvyCnrSpec)this.spec = arguments[0].cloneOn(this.box); // convert non-pixel unitselse {this.spec = new curvyCnrSpec('');this.spec.setfrom(this.settings); // no need for unit conversion, use settings param. directly}// Get box formatting detailsvar borderWidth = curvyBrowser.get_style(this.box, "borderTopWidth");var borderWidthB = curvyBrowser.get_style(this.box, "borderBottomWidth");var borderWidthL = curvyBrowser.get_style(this.box, "borderLeftWidth");var borderWidthR = curvyBrowser.get_style(this.box, "borderRightWidth");var borderColour = curvyBrowser.get_style(this.box, "borderTopColor");var borderColourB = curvyBrowser.get_style(this.box, "borderBottomColor");var borderColourL = curvyBrowser.get_style(this.box, "borderLeftColor");var borderColourR = curvyBrowser.get_style(this.box, "borderRightColor");var borderStyle = curvyBrowser.get_style(this.box, "borderTopStyle");var borderStyleB = curvyBrowser.get_style(this.box, "borderBottomStyle");var borderStyleL = curvyBrowser.get_style(this.box, "borderLeftStyle");var borderStyleR = curvyBrowser.get_style(this.box, "borderRightStyle");var boxColour = curvyBrowser.get_style(this.box, "backgroundColor");var backgroundImage = curvyBrowser.get_style(this.box, "backgroundImage");var backgroundRepeat = curvyBrowser.get_style(this.box, "backgroundRepeat");var backgroundPosX, backgroundPosY;if (this.box.currentStyle && this.box.currentStyle.backgroundPositionX) {backgroundPosX = curvyBrowser.get_style(this.box, "backgroundPositionX");backgroundPosY = curvyBrowser.get_style(this.box, "backgroundPositionY");}else {backgroundPosX = curvyBrowser.get_style(this.box, 'backgroundPosition');backgroundPosX = backgroundPosX.split(' ');backgroundPosY = backgroundPosX.length === 2 ? backgroundPosX[1] : 0;backgroundPosX = backgroundPosX[0];}var boxPosition = curvyBrowser.get_style(this.box, "position");var topPadding = curvyBrowser.get_style(this.box, "paddingTop");var bottomPadding = curvyBrowser.get_style(this.box, "paddingBottom");var leftPadding = curvyBrowser.get_style(this.box, "paddingLeft");var rightPadding = curvyBrowser.get_style(this.box, "paddingRight");var border = curvyBrowser.get_style(this.box, "border");var filter = curvyBrowser.ieVer > 7 ? curvyBrowser.get_style(this.box, 'filter') : null; // IE8 bug fixvar topMaxRadius = this.spec.get('tR');var botMaxRadius = this.spec.get('bR');var styleToNPx = function(val) {if (typeof val === 'number') return val;if (typeof val !== 'string') throw new Error('unexpected styleToNPx type ' + typeof val);var matches = /^[-\d.]([a-z]+)$/.exec(val);if (matches && matches[1] != 'px') throw new Error('Unexpected unit ' + matches[1]);if (isNaN(val = parseInt(val))) val = 0;return val;}var min0Px = function(val) {return val <= 0 ? "0" : val + "px";}// Set formatting propertiestry {this.borderWidth = styleToNPx(borderWidth);this.borderWidthB = styleToNPx(borderWidthB);this.borderWidthL = styleToNPx(borderWidthL);this.borderWidthR = styleToNPx(borderWidthR);this.boxColour = curvyObject.format_colour(boxColour);this.topPadding = styleToNPx(topPadding);this.bottomPadding = styleToNPx(bottomPadding);this.leftPadding = styleToNPx(leftPadding);this.rightPadding = styleToNPx(rightPadding);this.boxWidth = boxWidth;this.boxHeight = this.box.clientHeight;this.borderColour = curvyObject.format_colour(borderColour);this.borderColourB = curvyObject.format_colour(borderColourB);this.borderColourL = curvyObject.format_colour(borderColourL);this.borderColourR = curvyObject.format_colour(borderColourR);this.borderString = this.borderWidth + "px" + " " + borderStyle + " " + this.borderColour;this.borderStringB = this.borderWidthB + "px" + " " + borderStyleB + " " + this.borderColourB;this.borderStringL = this.borderWidthL + "px" + " " + borderStyleL + " " + this.borderColourL;this.borderStringR = this.borderWidthR + "px" + " " + borderStyleR + " " + this.borderColourR;this.backgroundImage = ((backgroundImage != "none") ? backgroundImage : "");this.backgroundRepeat = backgroundRepeat;}catch (e) {throw this.newError(e.message);}var clientHeight = this.boxHeight;var clientWidth = boxWidth; // save it as it gets trampled on laterif (curvyBrowser.isOp) {backgroundPosX = styleToNPx(backgroundPosX);backgroundPosY = styleToNPx(backgroundPosY);if (backgroundPosX) {var t = clientWidth + this.borderWidthL + this.borderWidthR;if (backgroundPosX > t) backgroundPosX = t;backgroundPosX = (t / backgroundPosX * 100) + '%'; // convert to percentage}if (backgroundPosY) {var t = clientHeight + this.borderWidth + this.borderWidthB;if (backgroundPosY > t) backgroundPosY = t;backgroundPosY = (t / backgroundPosY * 100) + '%'; // convert to percentage}}if (curvyBrowser.quirksMode) {}else {this.boxWidth -= this.leftPadding + this.rightPadding;this.boxHeight -= this.topPadding + this.bottomPadding;}// Create content containerthis.contentContainer = document.createElement("div");if (filter) this.contentContainer.style.filter = filter; // IE8 bug fixwhile (this.box.firstChild) this.contentContainer.appendChild(this.box.removeChild(this.box.firstChild));if (boxPosition != "absolute") this.box.style.position = "relative";this.box.style.padding = '0';this.box.style.border = this.box.style.backgroundImage = 'none';this.box.style.backgroundColor = 'transparent';this.box.style.width = (clientWidth + this.borderWidthL + this.borderWidthR) + 'px';this.box.style.height = (clientHeight + this.borderWidth + this.borderWidthB) + 'px';// Ok we add an inner div to actually put things into this will allow us to keep the heightvar newMainContainer = document.createElement("div");newMainContainer.style.position = "absolute";if (filter) newMainContainer.style.filter = filter; // IE8 bug fixif (curvyBrowser.quirksMode) {newMainContainer.style.width = (clientWidth + this.borderWidthL + this.borderWidthR) + 'px';} else {newMainContainer.style.width = clientWidth + 'px';}newMainContainer.style.height = min0Px(clientHeight + this.borderWidth + this.borderWidthB - topMaxRadius - botMaxRadius);newMainContainer.style.padding = "0";newMainContainer.style.top = topMaxRadius + "px";newMainContainer.style.left = "0";if (this.borderWidthL)newMainContainer.style.borderLeft = this.borderStringL;if (this.borderWidth && !topMaxRadius)newMainContainer.style.borderTop = this.borderString;if (this.borderWidthR)newMainContainer.style.borderRight = this.borderStringR;if (this.borderWidthB && !botMaxRadius)newMainContainer.style.borderBottom = this.borderStringB;newMainContainer.style.backgroundColor = boxColour;newMainContainer.style.backgroundImage = this.backgroundImage;newMainContainer.style.backgroundRepeat = this.backgroundRepeat;newMainContainer.style.direction = 'ltr';this.shell = this.box.appendChild(newMainContainer);boxWidth = curvyBrowser.get_style(this.shell, "width");if (boxWidth === "" || boxWidth === "auto" || boxWidth.indexOf("%") !== -1) throw this.newError('Shell width is ' + boxWidth);this.boxWidth = (boxWidth != "" && boxWidth != "auto" && boxWidth.indexOf("%") == -1) ? parseInt(boxWidth) : this.shell.clientWidth;/*This method creates the corners andapplies them to the div element.*/this.applyCorners = function() {/*Set up background offsets. This may need to be delayed untilthe background image is loaded.*/this.backgroundPosX = this.backgroundPosY = 0;if (this.backgroundObject) {var bgOffset = function(style, imglen, boxlen) {if (style === 0) return 0;var retval;if (style === 'right' || style === 'bottom') return boxlen - imglen;if (style === 'center') return (boxlen - imglen) / 2;if (style.indexOf('%') > 0) return (boxlen - imglen) * 100 / parseInt(style);return styleToNPx(style);}this.backgroundPosX = bgOffset(backgroundPosX, this.backgroundObject.width, clientWidth);this.backgroundPosY = bgOffset(backgroundPosY, this.backgroundObject.height, clientHeight);}else if (this.backgroundImage) {this.backgroundPosX = styleToNPx(backgroundPosX);this.backgroundPosY = styleToNPx(backgroundPosY);}/*Create top and bottom containers.These will be used as a parent for the corners and bars.*/// Build top bar only if a top corner is to be drawnif (topMaxRadius) {newMainContainer = document.createElement("div");newMainContainer.style.width = this.boxWidth + "px";newMainContainer.style.fontSize = "1px";newMainContainer.style.overflow = "hidden";newMainContainer.style.position = "absolute";newMainContainer.style.paddingLeft = this.borderWidth + "px";newMainContainer.style.paddingRight = this.borderWidth + "px";newMainContainer.style.height = topMaxRadius + "px";newMainContainer.style.top = -topMaxRadius + "px";newMainContainer.style.left = -this.borderWidthL + "px";this.topContainer = this.shell.appendChild(newMainContainer);}// Build bottom bar only if a bottom corner is to be drawnif (botMaxRadius) {var newMainContainer = document.createElement("div");newMainContainer.style.width = this.boxWidth + "px";newMainContainer.style.fontSize = "1px";newMainContainer.style.overflow = "hidden";newMainContainer.style.position = "absolute";newMainContainer.style.paddingLeft = this.borderWidthB + "px";newMainContainer.style.paddingRight = this.borderWidthB + "px";newMainContainer.style.height = botMaxRadius + "px";newMainContainer.style.bottom = -botMaxRadius + "px";newMainContainer.style.left = -this.borderWidthL + "px";this.bottomContainer = this.shell.appendChild(newMainContainer);}var corners = this.spec.cornerNames();  // array of available corners/*Loop for each corner*/for (var i in corners) if (!isNaN(i)) {// Get current corner type from arrayvar cc = corners[i];var specRadius = this.spec[cc + 'R'];// Has the user requested the currentCorner be round?// Code to apply correct color to top or bottomvar bwidth, bcolor, borderRadius, borderWidthTB;if (cc == "tr" || cc == "tl") {bwidth = this.borderWidth;bcolor = this.borderColour;borderWidthTB = this.borderWidth;} else {bwidth = this.borderWidthB;bcolor = this.borderColourB;borderWidthTB = this.borderWidthB;}borderRadius = specRadius - borderWidthTB;var newCorner = document.createElement("div");newCorner.style.height = this.spec.get(cc + 'Ru');newCorner.style.width = this.spec.get(cc + 'Ru');newCorner.style.position = "absolute";newCorner.style.fontSize = "1px";newCorner.style.overflow = "hidden";// THE FOLLOWING BLOCK OF CODE CREATES A ROUNDED CORNER// ---------------------------------------------------- TOPvar intx, inty, outsideColour;var trans = filter ? parseInt(/alpha\(opacity.(\d+)\)/.exec(filter)[1]) : 100; // IE8 bug fix// Cycle the x-axisfor (intx = 0; intx < specRadius; ++intx) {// Calculate the value of y1 which identifies the pixels inside the bordervar y1 = (intx + 1 >= borderRadius) ? -1 : Math.floor(Math.sqrt(Math.pow(borderRadius, 2) - Math.pow(intx + 1, 2))) - 1;// Calculate y2 and y3 only if there is a border definedif (borderRadius != specRadius) {var y2 = (intx >= borderRadius) ? -1 : Math.ceil(Math.sqrt(Math.pow(borderRadius, 2) - Math.pow(intx, 2)));var y3 = (intx + 1 >= specRadius) ? -1 : Math.floor(Math.sqrt(Math.pow(specRadius, 2) - Math.pow((intx + 1), 2))) - 1;}// Calculate y4var y4 = (intx >= specRadius) ? -1 : Math.ceil(Math.sqrt(Math.pow(specRadius, 2) - Math.pow(intx, 2)));// Draw bar on inside of the border with foreground colourif (y1 > -1) this.drawPixel(intx, 0, this.boxColour, trans, (y1 + 1), newCorner, true, specRadius);// Draw border/foreground antialiased pixels and border only if there is a border definedif (borderRadius != specRadius) {// Cycle the y-axisif (this.spec.antiAlias) {for (inty = y1 + 1; inty < y2; ++inty) {// For each of the pixels that need anti aliasing between the foreground and border colour draw single pixel divsif (this.backgroundImage != "") {var borderFract = curvyObject.pixelFraction(intx, inty, borderRadius) * 100;this.drawPixel(intx, inty, bcolor, trans, 1, newCorner, borderFract >= 30, specRadius);}else if (this.boxColour !== 'transparent') {var pixelcolour = curvyObject.BlendColour(this.boxColour, bcolor, curvyObject.pixelFraction(intx, inty, borderRadius));this.drawPixel(intx, inty, pixelcolour, trans, 1, newCorner, false, specRadius);}else this.drawPixel(intx, inty, bcolor, trans >> 1, 1, newCorner, false, specRadius);}// Draw bar for the borderif (y3 >= y2) {if (y2 == -1) y2 = 0;this.drawPixel(intx, y2, bcolor, trans, (y3 - y2 + 1), newCorner, false, 0);}outsideColour = bcolor;  // Set the colour for the outside AA curveinty = y3;               // start_pos - 1 for y-axis AA pixels}else { // no antiAliasif (y3 > y1) { // NB condition was >=, changed to avoid zero-height divsthis.drawPixel(intx, (y1 + 1), bcolor, trans, (y3 - y1), newCorner, false, 0);}}}else {outsideColour = this.boxColour;  // Set the colour for the outside curveinty = y1;               // start_pos - 1 for y-axis AA pixels}// Draw aa pixels?if (this.spec.antiAlias && this.boxColour !== 'transparent') {// Cycle the y-axis and draw the anti aliased pixels on the outside of the curvewhile (++inty < y4) {// For each of the pixels that need anti aliasing between the foreground/border colour & background draw single pixel divsthis.drawPixel(intx, inty, outsideColour, (curvyObject.pixelFraction(intx, inty, specRadius) * trans), 1, newCorner, borderWidthTB <= 0, specRadius);}}}// END OF CORNER CREATION// ---------------------------------------------------- END/*Now we have a new corner we need to reposition all the pixels unlessthe current corner is the bottom right.*/// Loop through all children (pixel bars)for (var t = 0, k = newCorner.childNodes.length; t < k; ++t) {// Get current pixel barvar pixelBar = newCorner.childNodes[t];// Get current top and left propertiesvar pixelBarTop = parseInt(pixelBar.style.top);var pixelBarLeft = parseInt(pixelBar.style.left);var pixelBarHeight = parseInt(pixelBar.style.height);// Reposition pixelsif (cc == "tl" || cc == "bl") {pixelBar.style.left = (specRadius - pixelBarLeft - 1) + "px"; // Left}if (cc == "tr" || cc == "tl") {pixelBar.style.top = (specRadius - pixelBarHeight - pixelBarTop) + "px"; // Top}pixelBar.style.backgroundRepeat = this.backgroundRepeat;if (this.backgroundImage) switch (cc) {case "tr":pixelBar.style.backgroundPosition = (this.backgroundPosX - this.borderWidthL + specRadius - clientWidth - pixelBarLeft) + "px " + (this.backgroundPosY + pixelBarHeight + pixelBarTop + this.borderWidth - specRadius) + "px";break;case "tl":pixelBar.style.backgroundPosition = (this.backgroundPosX - specRadius + pixelBarLeft + 1 + this.borderWidthL) + "px " + (this.backgroundPosY - specRadius + pixelBarHeight + pixelBarTop + this.borderWidth) + "px";break;case "bl":pixelBar.style.backgroundPosition = (this.backgroundPosX - specRadius + pixelBarLeft + 1 + this.borderWidthL) + "px " + (this.backgroundPosY - clientHeight - this.borderWidth + (curvyBrowser.quirksMode ? pixelBarTop : -pixelBarTop) + specRadius) + "px";break;case "br":if (curvyBrowser.quirksMode) {pixelBar.style.backgroundPosition = (this.backgroundPosX - this.borderWidthL - clientWidth + specRadius - pixelBarLeft) + "px " + (this.backgroundPosY - clientHeight - this.borderWidth + pixelBarTop + specRadius) + "px";} else {pixelBar.style.backgroundPosition = (this.backgroundPosX - this.borderWidthL - clientWidth + specRadius - pixelBarLeft) + "px " + (this.backgroundPosY - clientHeight - this.borderWidth + specRadius - pixelBarTop) + "px";}//break;}}// Position the containerswitch (cc) {case "tl":newCorner.style.top = newCorner.style.left = "0";this.topContainer.appendChild(newCorner);break;case "tr":newCorner.style.top = newCorner.style.right = "0";this.topContainer.appendChild(newCorner);break;case "bl":newCorner.style.bottom = newCorner.style.left = "0";this.bottomContainer.appendChild(newCorner);break;case "br":newCorner.style.bottom = newCorner.style.right = "0";this.bottomContainer.appendChild(newCorner);//break;}}/*The last thing to do is draw the rest of the filler DIVs.*/// Find out which corner has the bigger radius and get the difference amountvar radiusDiff = {t: this.spec.radiusdiff('t'),b: this.spec.radiusdiff('b')};for (z in radiusDiff) {if (typeof z === 'function') continue; // for prototype, mootools frameworksif (!this.spec.get(z + 'R')) continue; // no need if no cornersif (radiusDiff[z]) {// Get the type of corner that is the smaller onevar smallerCornerType = (this.spec[z + "lR"] < this.spec[z + "rR"]) ? z + "l" : z + "r";// First we need to create a DIV for the space under the smaller cornervar newFiller = document.createElement("div");newFiller.style.height = radiusDiff[z] + "px";newFiller.style.width = this.spec.get(smallerCornerType + 'Ru');newFiller.style.position = "absolute";newFiller.style.fontSize = "1px";newFiller.style.overflow = "hidden";newFiller.style.backgroundColor = this.boxColour;if (filter) newFiller.style.filter = filter; // IE8 bug fix// Set background image with original featuresnewFiller.style.backgroundImage = this.backgroundImage;newFiller.style.backgroundRepeat = this.backgroundRepeat;// Position fillerswitch (smallerCornerType) {case "tl":newFiller.style.bottom =newFiller.style.left = "0";newFiller.style.borderLeft = this.borderStringL;// Set background image in original positionnewFiller.style.backgroundPosition = this.backgroundPosX + "px " + (this.borderWidth + this.backgroundPosY - this.spec.tlR) + "px";this.topContainer.appendChild(newFiller);break;case "tr":newFiller.style.bottom =newFiller.style.right = "0";newFiller.style.borderRight = this.borderStringR;// Set background image in original positionnewFiller.style.backgroundPosition = (this.backgroundPosX - this.boxWidth + this.spec.trR) + "px " + (this.borderWidth + this.backgroundPosY - this.spec.trR) + "px";this.topContainer.appendChild(newFiller);break;case "bl":newFiller.style.top =newFiller.style.left = "0";newFiller.style.borderLeft = this.borderStringL;// Set background image in original positionnewFiller.style.backgroundPosition = this.backgroundPosX + "px " + (this.backgroundPosY - this.borderWidth - this.boxHeight + radiusDiff[z] + this.spec.blR) + "px";this.bottomContainer.appendChild(newFiller);break;case "br":newFiller.style.top =newFiller.style.right = "0";newFiller.style.borderRight = this.borderStringR;// Set background image in original position.newFiller.style.backgroundPosition = (this.borderWidthL + this.backgroundPosX - this.boxWidth + this.spec.brR) + "px " + (this.backgroundPosY - this.borderWidth - this.boxHeight + radiusDiff[z] + this.spec.brR) + "px";this.bottomContainer.appendChild(newFiller);//break;}}// Create the bar to fill the gap between each corner horizontallyvar newFillerBar = document.createElement("div");if (filter) newFillerBar.style.filter = filter; // IE8 bug fixnewFillerBar.style.position = "relative";newFillerBar.style.fontSize = "1px";newFillerBar.style.overflow = "hidden";newFillerBar.style.width = this.fillerWidth(z);newFillerBar.style.backgroundColor = this.boxColour;newFillerBar.style.backgroundImage = this.backgroundImage;newFillerBar.style.backgroundRepeat = this.backgroundRepeat;switch (z) {case "t":// Top Barif (this.topContainer) {if (curvyBrowser.quirksMode) {newFillerBar.style.height = 100 + topMaxRadius + "px";} else {newFillerBar.style.height = 100 + topMaxRadius - this.borderWidth + "px";}newFillerBar.style.marginLeft = this.spec.tlR ? (this.spec.tlR - this.borderWidthL) + "px" : "0";newFillerBar.style.borderTop = this.borderString;if (this.backgroundImage) {var x_offset = this.spec.tlR ?(this.borderWidthL + this.backgroundPosX - this.spec.tlR) + "px " : this.backgroundPosX + "px ";newFillerBar.style.backgroundPosition = x_offset + this.backgroundPosY + "px";// Reposition the box's background imagethis.shell.style.backgroundPosition = this.backgroundPosX + "px " + (this.backgroundPosY - topMaxRadius + this.borderWidthL) + "px";}this.topContainer.appendChild(newFillerBar);}break;case "b":if (this.bottomContainer) {// Bottom Barif (curvyBrowser.quirksMode) {newFillerBar.style.height = botMaxRadius + "px";} else {newFillerBar.style.height = botMaxRadius - this.borderWidthB + "px";}newFillerBar.style.marginLeft = this.spec.blR ? (this.spec.blR - this.borderWidthL) + "px" : "0";newFillerBar.style.borderBottom = this.borderStringB;if (this.backgroundImage) {var x_offset = this.spec.blR ?(this.backgroundPosX + this.borderWidthL - this.spec.blR) + "px " : this.backgroundPosX + "px ";newFillerBar.style.backgroundPosition = x_offset + (this.backgroundPosY - clientHeight - this.borderWidth + botMaxRadius) + "px";}this.bottomContainer.appendChild(newFillerBar);}//break;}}// style content containerthis.contentContainer.style.position = "absolute";// contentContainer.style.border = "1px dotted #000"; // DEBUG, comment for productionthis.contentContainer.className = "autoPadDiv";this.contentContainer.style.left = this.borderWidthL + "px";// Get padding amounts// Apply top paddingthis.contentContainer.style.paddingTop = this.topPadding + "px";this.contentContainer.style.top = this.borderWidth + "px";// skip bottom padding - it doesn't show!// Apply left and right paddingthis.contentContainer.style.paddingLeft = this.leftPadding + "px";this.contentContainer.style.paddingRight = this.rightPadding + "px";z = clientWidth;if (!curvyBrowser.quirksMode) z -= this.leftPadding + this.rightPadding;this.contentContainer.style.width = z + "px";this.contentContainer.style.textAlign = curvyBrowser.get_style(this.box, 'textAlign');this.box.style.textAlign = 'left'; // important otherwise layout goes wildthis.box.appendChild(this.contentContainer);if (boxDisp) boxDisp.style.display = boxDispSave;}if (this.backgroundImage) {backgroundPosX = this.backgroundCheck(backgroundPosX);backgroundPosY = this.backgroundCheck(backgroundPosY);if (this.backgroundObject) {this.backgroundObject.holdingElement = this;this.dispatch = this.applyCorners;this.applyCorners = function() {if (this.backgroundObject.complete)this.dispatch();else this.backgroundObject.onload = new Function('curvyObject.dispatch(this.holdingElement);');}}}}curvyObject.prototype.backgroundCheck = function(style) {if (style === 'top' || style === 'left' || parseInt(style) === 0) return 0;if (!(/^[-\d.]+px$/.test(style)) && !this.backgroundObject) {this.backgroundObject = new Image;var imgName = function(str) {var matches = /url\("?([^'"]+)"?\)/.exec(str);return (matches ? matches[1] : str);}this.backgroundObject.src = imgName(this.backgroundImage);}return style;}curvyObject.dispatch = function(obj) {if ('dispatch' in obj)obj.dispatch();else throw obj.newError('No dispatch function');}// append a pixel DIV to newCornercurvyObject.prototype.drawPixel = function(intx, inty, colour, transAmount, height, newCorner, image, cornerRadius) {var pixel = document.createElement("div");pixel.style.height = height + "px";pixel.style.width = "1px";pixel.style.position = "absolute";pixel.style.fontSize = "1px";pixel.style.overflow = "hidden";var topMaxRadius = this.spec.get('tR');pixel.style.backgroundColor = colour;// Don't apply background image to border pixelsif (image && this.backgroundImage != "") {pixel.style.backgroundImage = this.backgroundImage;pixel.style.backgroundPosition = "-" + (this.boxWidth - (cornerRadius - intx) + this.borderWidth) + "px -" + ((this.boxHeight + topMaxRadius + inty) - this.borderWidth) + "px";}// Set opacity if the transparency is anything other than 100if (transAmount != 100) curvyObject.setOpacity(pixel, transAmount);// Set positionpixel.style.top = inty + "px";pixel.style.left = intx + "px";newCorner.appendChild(pixel);}curvyObject.prototype.fillerWidth = function(tb) {var b_width, f_width;b_width = curvyBrowser.quirksMode ? 0 : this.spec.radiusCount(tb) * this.borderWidthL;if ((f_width = this.boxWidth - this.spec.radiusSum(tb) + b_width) < 0)throw this.newError("Radius exceeds box width");return f_width + 'px';}curvyObject.prototype.errmsg = function(msg, gravity) {var extradata = "\ntag: " + this.box.tagName;if (this.box.id) extradata += "\nid: " + this.box.id;if (this.box.className) extradata += "\nclass: " + this.box.className;var parent;if ((parent = this.box.parentNode) === null)extradata += "\n(box has no parent)";else {extradata += "\nParent tag: " + parent.tagName;if (parent.id) extradata += "\nParent ID: " + parent.id;if (parent.className) extradata += "\nParent class: " + parent.className;}if (gravity === undefined) gravity = 'warning';return 'curvyObject ' + gravity + ":\n" + msg + extradata;}curvyObject.prototype.newError = function(msg) {return new Error(this.errmsg(msg, 'exception'));}// ------------- UTILITY FUNCTIONS//  Convert a number 0..255 to hexcurvyObject.IntToHex = function(strNum) {var hexdig = ['0', '1', '2', '3', '4', '5', '6', '7', '8', '9', 'A', 'B', 'C', 'D', 'E', 'F'];return hexdig[strNum >>> 4] + '' + hexdig[strNum & 15];}/*Blends the two colours by the fractionreturns the resulting colour as a string in the format "#FFFFFF"*/curvyObject.BlendColour = function(Col1, Col2, Col1Fraction) {if (Col1 === 'transparent' || Col2 === 'transparent') throw this.newError('Cannot blend with transparent');if (Col1.charAt(0) !== '#') {//curvyCorners.alert('Found colour1 ' + Col1 + ': please let us know you saw this report.');Col1 = curvyObject.format_colour(Col1);}if (Col2.charAt(0) !== '#') {//curvyCorners.alert('Found colour2 ' + Col2 + ': please let us know you saw this report.');Col2 = curvyObject.format_colour(Col2);}var red1 = parseInt(Col1.substr(1, 2), 16);var green1 = parseInt(Col1.substr(3, 2), 16);var blue1 = parseInt(Col1.substr(5, 2), 16);var red2 = parseInt(Col2.substr(1, 2), 16);var green2 = parseInt(Col2.substr(3, 2), 16);var blue2 = parseInt(Col2.substr(5, 2), 16);if (Col1Fraction > 1 || Col1Fraction < 0) Col1Fraction = 1;var endRed = Math.round((red1 * Col1Fraction) + (red2 * (1 - Col1Fraction)));if (endRed > 255) endRed = 255;if (endRed < 0) endRed = 0;var endGreen = Math.round((green1 * Col1Fraction) + (green2 * (1 - Col1Fraction)));if (endGreen > 255) endGreen = 255;if (endGreen < 0) endGreen = 0;var endBlue = Math.round((blue1 * Col1Fraction) + (blue2 * (1 - Col1Fraction)));if (endBlue > 255) endBlue = 255;if (endBlue < 0) endBlue = 0;return "#" + curvyObject.IntToHex(endRed) + curvyObject.IntToHex(endGreen) + curvyObject.IntToHex(endBlue);}/*For a pixel cut by the line determines the fraction of the pixel on the 'inside' of theline.  Returns a number between 0 and 1*/curvyObject.pixelFraction = function(x, y, r) {var fraction;var rsquared = r * r;/*determine the co-ordinates of the two points on the perimeter of the pixel that thecircle crosses*/var xvalues = new Array(2);var yvalues = new Array(2);var point = 0;var whatsides = "";// x + 0 = Leftvar intersect = Math.sqrt(rsquared - Math.pow(x, 2));if (intersect >= y && intersect < (y + 1)) {whatsides = "Left";xvalues[point] = 0;yvalues[point] = intersect - y;++point;}// y + 1 = Topintersect = Math.sqrt(rsquared - Math.pow(y + 1, 2));if (intersect >= x && intersect < (x + 1)) {whatsides += "Top";xvalues[point] = intersect - x;yvalues[point] = 1;++point;}// x + 1 = Rightintersect = Math.sqrt(rsquared - Math.pow(x + 1, 2));if (intersect >= y && intersect < (y + 1)) {whatsides += "Right";xvalues[point] = 1;yvalues[point] = intersect - y;++point;}// y + 0 = Bottomintersect = Math.sqrt(rsquared - Math.pow(y, 2));if (intersect >= x && intersect < (x + 1)) {whatsides += "Bottom";xvalues[point] = intersect - x;yvalues[point] = 0;}/*depending on which sides of the perimeter of the pixel the circle crosses calculate thefraction of the pixel inside the circle*/switch (whatsides) {case "LeftRight":fraction = Math.min(yvalues[0], yvalues[1]) + ((Math.max(yvalues[0], yvalues[1]) - Math.min(yvalues[0], yvalues[1])) / 2);break;case "TopRight":fraction = 1 - (((1 - xvalues[0]) * (1 - yvalues[1])) / 2);break;case "TopBottom":fraction = Math.min(xvalues[0], xvalues[1]) + ((Math.max(xvalues[0], xvalues[1]) - Math.min(xvalues[0], xvalues[1])) / 2);break;case "LeftBottom":fraction = yvalues[0] * xvalues[1] / 2;break;default:fraction = 1;}return fraction;}// Returns an array of rgb valuescurvyObject.rgb2Array = function(rgbColour) {// Remove rgb()var rgbValues = rgbColour.substring(4, rgbColour.indexOf(")"));// Split RGB into arrayreturn rgbValues.split(", ");}// This function converts CSS rgb(x, x, x) to hexadecimalcurvyObject.rgb2Hex = function(rgbColour) {try {// Get array of RGB valuesvar rgbArray = curvyObject.rgb2Array(rgbColour);// Get RGB valuesvar red = parseInt(rgbArray[0]);var green = parseInt(rgbArray[1]);var blue = parseInt(rgbArray[2]);// Build hex colour codevar hexColour = "#" + curvyObject.IntToHex(red) + curvyObject.IntToHex(green) + curvyObject.IntToHex(blue);}catch (e) {var msg = 'getMessage' in e ? e.getMessage() : e.message;throw new Error("Error (" + msg + ") converting RGB value to Hex in rgb2Hex");}return hexColour;}/*Function by Simon Willison from sitepoint.comModified by Cameron Cooke adding Safari's rgba support*/curvyObject.setOpacity = function(obj, opacity) {opacity = (opacity == 100) ? 99.999 : opacity;if (curvyBrowser.isSafari && obj.tagName != "IFRAME") {// Get array of RGB valuesvar rgbArray = curvyObject.rgb2Array(obj.style.backgroundColor);// Get RGB valuesvar red = parseInt(rgbArray[0]);var green = parseInt(rgbArray[1]);var blue = parseInt(rgbArray[2]);// Safari using RGBA supportobj.style.backgroundColor = "rgba(" + red + ", " + green + ", " + blue + ", " + opacity / 100 + ")";}else if (typeof obj.style.opacity !== "undefined") { // W3Cobj.style.opacity = opacity / 100;}else if (typeof obj.style.MozOpacity !== "undefined") { // Older Mozillaobj.style.MozOpacity = opacity / 100;}else if (typeof obj.style.filter !== "undefined") { // IEobj.style.filter = "alpha(opacity=" + opacity + ")";}else if (typeof obj.style.KHTMLOpacity !== "undefined") { // Older KHTML-based browsersobj.style.KHTMLOpacity = opacity / 100;}}// Cross browser add event wrappercurvyCorners.addEvent = function(elm, evType, fn, useCapture) {if (elm.addEventListener) {elm.addEventListener(evType, fn, useCapture);return true;}if (elm.attachEvent) return elm.attachEvent('on' + evType, fn);elm['on' + evType] = fn;return false;}if (typeof addEvent === 'undefined') addEvent = curvyCorners.addEvent; // only if necessary// Gets the computed colour.curvyObject.getComputedColour = function(colour) {var d = document.createElement('DIV');d.style.backgroundColor = colour;document.body.appendChild(d);if (window.getComputedStyle) { // Mozilla, Opera, Chrome, Safarivar rtn = document.defaultView.getComputedStyle(d, null).getPropertyValue('background-color');d.parentNode.removeChild(d);if (rtn.substr(0, 3) === "rgb") rtn = curvyObject.rgb2Hex(rtn);return rtn;}else { // IEvar rng = document.body.createTextRange();rng.moveToElementText(d);rng.execCommand('ForeColor', false, colour);var iClr = rng.queryCommandValue('ForeColor');var rgb = "rgb(" + (iClr & 0xFF) + ", " + ((iClr & 0xFF00) >> 8) + ", " + ((iClr & 0xFF0000) >> 16) + ")";d.parentNode.removeChild(d);rng = null;return curvyObject.rgb2Hex(rgb);}}// convert colour name, rgb() and #RGB to #RRGGBBcurvyObject.format_colour = function(colour) {// Make sure colour is set and not transparentif (colour != "" && colour != "transparent") {// RGB Value?if (colour.substr(0, 3) === "rgb") {// Get HEX aquiv.colour = curvyObject.rgb2Hex(colour);}else if (colour.charAt(0) !== '#') {// Convert colour name to hex valuecolour = curvyObject.getComputedColour(colour);}else if (colour.length === 4) {// 3 chr colour code add remaindercolour = "#" + colour.charAt(1) + colour.charAt(1) + colour.charAt(2) + colour.charAt(2) + colour.charAt(3) + colour.charAt(3);}}return colour;}// Get elements by class by Dustin Diaz / CPKS// NB if searchClass is a class name, it MUST be preceded by '.'curvyCorners.getElementsByClass = function(searchClass, node) {var classElements = new Array;if (node === undefined) node = document;searchClass = searchClass.split('.'); // see if there's a tag in therevar tag = '*'; // prepare for no tagif (searchClass.length === 1) {tag = searchClass[0];searchClass = false;}else {if (searchClass[0]) tag = searchClass[0];searchClass = searchClass[1];}var i, els, elsLen;if (tag.charAt(0) === '#') {els = document.getElementById(tag.substr(1));if (els) classElements.push(els);}else {els = node.getElementsByTagName(tag);elsLen = els.length;if (searchClass) {var pattern = new RegExp("(^|\\s)" + searchClass + "(\\s|$)");for (i = 0; i < elsLen; ++i) {if (pattern.test(els[i].className)) classElements.push(els[i]);}}else for (i = 0; i < elsLen; ++i) classElements.push(els[i]);}return classElements;}curvyCorners.getElementsBySelector = function(selectors, parent) {var ret;var sel = selectors[0];if (parent === undefined) parent = document;if (sel.indexOf('#') !== -1)ret = [parent.getElementById(sel.substr(1))];elseret = curvyCorners.getElementsByClass(sel, parent);if (selectors.length > 1) {var subret = [];for (var i = ret.length; --i >= 0; )subret = subret.concat(curvyCorners.getElementsBySelector(selectors.slice(1), ret[i]));ret = subret;}return ret;}if (curvyBrowser.supportsCorners) {var curvyCornersNoAutoScan = true; // it won't do anything anyway.curvyCorners.init = function() { }; // make it harmless}else {// autoscan codecurvyCorners.scanStyles = function() {function units(num) {if (!parseInt(num)) return 'px'; // '0' becomes '0px' for simplicity's sakevar matches = /^[\d.]+(\w+)$/.exec(num);return matches[1];}var t, i, j;if (curvyBrowser.isIE) {function procIEStyles(rule) {var style = rule.style;if (curvyBrowser.ieVer > 6.0) {var allR = style['-moz-border-radius'] || 0;var tR = style['-moz-border-radius-topright'] || 0;var tL = style['-moz-border-radius-topleft'] || 0;var bR = style['-moz-border-radius-bottomright'] || 0;var bL = style['-moz-border-radius-bottomleft'] || 0;}else {var allR = style['moz-border-radius'] || 0;var tR = style['moz-border-radius-topright'] || 0;var tL = style['moz-border-radius-topleft'] || 0;var bR = style['moz-border-radius-bottomright'] || 0;var bL = style['moz-border-radius-bottomleft'] || 0;}if (allR) {var t = allR.split('/'); // ignore elliptical spec.t = t[0].split(/\s+/);if (t[t.length - 1] === '') t.pop();switch (t.length) {case 3:tL = t[0];tR = bL = t[1];bR = t[2];allR = false;break;case 2:tL = bR = t[0];tR = bL = t[1];allR = false;case 1:break;case 4:tL = t[0];tR = t[1];bR = t[2];bL = t[3];allR = false;break;default:curvyCorners.alert('Illegal corners specification: ' + allR);//break;}}if (allR || tL || tR || bR || bL) {var settings = new curvyCnrSpec(rule.selectorText);if (allR)settings.setcorner(null, null, parseInt(allR), units(allR));else {if (tR) settings.setcorner('t', 'r', parseInt(tR), units(tR));if (tL) settings.setcorner('t', 'l', parseInt(tL), units(tL));if (bL) settings.setcorner('b', 'l', parseInt(bL), units(bL));if (bR) settings.setcorner('b', 'r', parseInt(bR), units(bR));}curvyCorners(settings);}}for (t = 0; t < document.styleSheets.length; ++t) {try {if (document.styleSheets[t].imports) {for (i = 0; i < document.styleSheets[t].imports.length; ++i)for (j = 0; j < document.styleSheets[t].imports[i].rules.length; ++j)procIEStyles(document.styleSheets[t].imports[i].rules[j]);}for (i = 0; i < document.styleSheets[t].rules.length; ++i)procIEStyles(document.styleSheets[t].rules[i]);}catch (e) {if (typeof curvyCornersVerbose !== 'undefined' && curvyCornersVerbose)alert(e.message + " - ignored");} // catch but ignore any permission error}}else if (curvyBrowser.isOp) {for (t = 0; t < document.styleSheets.length; ++t) {if (operasheet.contains_border_radius(t)) {j = new operasheet(t);for (i in j.rules) if (!isNaN(i))curvyCorners(j.rules[i]);}}}else curvyCorners.alert('Scanstyles does nothing in Webkit/Firefox/Opera');};// Dean Edwards/Matthias Miller/John ResigcurvyCorners.init = function() {// quit if this function has already been calledif (arguments.callee.done) return;// flag this function so we don't do the same thing twicearguments.callee.done = true;// kill the timerif (curvyBrowser.isWebKit && curvyCorners.init.timer) {clearInterval(curvyCorners.init.timer);curvyCorners.init.timer = null;}// do stuffcurvyCorners.scanStyles();};}if (typeof curvyCornersNoAutoScan === 'undefined' || curvyCornersNoAutoScan === false) {if (curvyBrowser.isOp)document.addEventListener("DOMContentLoaded", curvyCorners.init, false);else curvyCorners.addEvent(window, 'load', curvyCorners.init, false);}function RegisterModalUpdateProgressEvents() {var manager = null;if (Sys.WebForms && Sys.WebForms.PageRequestManager) manager = Sys.WebForms.PageRequestManager.getInstance();if (manager == null) return;var doc = (document.documentElement != null) ? document.documentElement : document.body;doc.style.overflow = 'auto';manager.add_beginRequest(function() {var modal = document.getElementById('UpdateProgressContainer');doc.style.overflow = 'hidden';modal.style.top = doc.scrollTop + 'px';modal.style.left = doc.scrollLeft + 'px';});manager.add_endRequest(function() {doc.style.overflow = 'auto';});}RegisterModalUpdateProgressEvents();function RegisterPortalPopupMenuExecute(baseNodeID, showBelow) {$(document).ready(function() {var createShowFn = function(showBelow) {return function() {var p = $(this).children("ul");var pos = $(this).position();if (showBelow) {var height = $(this).outerHeight();p.css("top", (pos.top + height) + "px");p.css("left", pos.left + "px");}else {var width = $(this).outerWidth();p.css("left", (width + pos.left) + "px");p.css("top", pos.top + "px");}p.show();};}var hideFn = function() {$(this).children("ul").hide();};$("." + baseNodeID + " li > ul").hide();$("." + baseNodeID + " li").unbind();$("." + baseNodeID + " > ul").children("li").hover(createShowFn(showBelow), hideFn);$("." + baseNodeID + " li > ul").children("li").hover(createShowFn(false), hideFn);});}function RegisterPortalPopupMenuScripts_2() {RegisterPortalPopupMenuExecute("PortalPopUpMenu_H", true);RegisterPortalPopupMenuExecute("PortalPopUp", true);RegisterPortalPopupMenuExecute("PortalPopUpMenu", false);}function RegisterPortalPopupMenuScripts() {var manager = null;RegisterPortalPopupMenuScripts_2();if (Sys.WebForms && Sys.WebForms.PageRequestManager) manager = Sys.WebForms.PageRequestManager.getInstance();if (manager == null) return;manager.add_endRequest(RegisterPortalPopupMenuScripts_2);}RegisterPortalPopupMenuScripts();function sSwapColour(div, colour){if (div){div.style.backgroundColor = colour;}}