Files
openlayers/master/build/ol.js
Tom Payne 4dc48d748e Updated
2013-01-17 23:39:57 +01:00

161 lines
90 KiB
JavaScript

(function(){var h=void 0,i=!0,k=null,n=!1;function p(a){return function(){return this[a]}}var v,x=this;function y(){}function aa(a){a.wa=function(){return a.Jb?a.Jb:a.Jb=new a}}
function ba(a){var b=typeof a;if("object"==b)if(a){if(a instanceof Array)return"array";if(a instanceof Object)return b;var c=Object.prototype.toString.call(a);if("[object Window]"==c)return"object";if("[object Array]"==c||"number"==typeof a.length&&"undefined"!=typeof a.splice&&"undefined"!=typeof a.propertyIsEnumerable&&!a.propertyIsEnumerable("splice"))return"array";if("[object Function]"==c||"undefined"!=typeof a.call&&"undefined"!=typeof a.propertyIsEnumerable&&!a.propertyIsEnumerable("call"))return"function"}else return"null";
else if("function"==b&&"undefined"==typeof a.call)return"object";return b}function z(a){return a!==h}function ca(a){return"array"==ba(a)}function da(a){var b=ba(a);return"array"==b||"object"==b&&"number"==typeof a.length}function D(a){return"string"==typeof a}function ea(a){return"function"==ba(a)}function fa(a){var b=typeof a;return"object"==b&&a!=k||"function"==b}function E(a){return a[ga]||(a[ga]=++ha)}var ga="closure_uid_"+Math.floor(2147483648*Math.random()).toString(36),ha=0;
function ia(a,b,c){return a.call.apply(a.bind,arguments)}function ja(a,b,c){if(!a)throw Error();if(2<arguments.length){var d=Array.prototype.slice.call(arguments,2);return function(){var c=Array.prototype.slice.call(arguments);Array.prototype.unshift.apply(c,d);return a.apply(b,c)}}return function(){return a.apply(b,arguments)}}function ka(a,b,c){ka=Function.prototype.bind&&-1!=Function.prototype.bind.toString().indexOf("native code")?ia:ja;return ka.apply(k,arguments)}
function la(a,b){var c=Array.prototype.slice.call(arguments,1);return function(){var b=Array.prototype.slice.call(arguments);b.unshift.apply(b,c);return a.apply(this,b)}}var ma=Date.now||function(){return+new Date};function F(a,b){var c=a.split("."),d=x;!(c[0]in d)&&d.execScript&&d.execScript("var "+c[0]);for(var e;c.length&&(e=c.shift());)!c.length&&z(b)?d[e]=b:d=d[e]?d[e]:d[e]={}}function G(a,b){function c(){}c.prototype=b.prototype;a.p=b.prototype;a.prototype=new c};function na(a,b){this.b=a;this.a=b||k};function oa(a){Error.captureStackTrace?Error.captureStackTrace(this,oa):this.stack=Error().stack||"";a&&(this.message=String(a))}G(oa,Error);oa.prototype.name="CustomError";function pa(a){if(!qa.test(a))return a;-1!=a.indexOf("&")&&(a=a.replace(ra,"&amp;"));-1!=a.indexOf("<")&&(a=a.replace(sa,"&lt;"));-1!=a.indexOf(">")&&(a=a.replace(ta,"&gt;"));-1!=a.indexOf('"')&&(a=a.replace(ua,"&quot;"));return a}var ra=/&/g,sa=/</g,ta=/>/g,ua=/\"/g,qa=/[&<>\"]/;var H=Array.prototype,Ca=H.indexOf?function(a,b,c){return H.indexOf.call(a,b,c)}:function(a,b,c){c=c==k?0:0>c?Math.max(0,a.length+c):c;if(D(a))return!D(b)||1!=b.length?-1:a.indexOf(b,c);for(;c<a.length;c++)if(c in a&&a[c]===b)return c;return-1},I=H.forEach?function(a,b,c){H.forEach.call(a,b,c)}:function(a,b,c){for(var d=a.length,e=D(a)?a.split(""):a,f=0;f<d;f++)f in e&&b.call(c,e[f],f,a)},Da=H.filter?function(a,b,c){return H.filter.call(a,b,c)}:function(a,b,c){for(var d=a.length,e=[],f=0,g=D(a)?a.split(""):
a,j=0;j<d;j++)if(j in g){var s=g[j];b.call(c,s,j,a)&&(e[f++]=s)}return e},Ea=H.map?function(a,b,c){return H.map.call(a,b,c)}:function(a,b,c){for(var d=a.length,e=Array(d),f=D(a)?a.split(""):a,g=0;g<d;g++)g in f&&(e[g]=b.call(c,f[g],g,a));return e},Fa=H.some?function(a,b,c){return H.some.call(a,b,c)}:function(a,b,c){for(var d=a.length,e=D(a)?a.split(""):a,f=0;f<d;f++)if(f in e&&b.call(c,e[f],f,a))return i;return n};function Ga(a){if(!ca(a))for(var b=a.length-1;0<=b;b--)delete a[b];a.length=0}
function Ha(a){return H.concat.apply(H,arguments)}function Ia(a){var b=a.length;if(0<b){for(var c=Array(b),d=0;d<b;d++)c[d]=a[d];return c}return[]}function Ja(a,b,c,d){H.splice.apply(a,Ka(arguments,1))}function Ka(a,b,c){return 2>=arguments.length?H.slice.call(a,b):H.slice.call(a,b,c)}function La(a){H.sort.call(a,Ma)}function Ma(a,b){return a>b?1:a<b?-1:0};function Na(a,b,c){for(var d in a)b.call(c,a[d],d,a)}function Oa(a){var b=[],c=0,d;for(d in a)b[c++]=a[d];return b}function Pa(a){var b=[],c=0,d;for(d in a)b[c++]=d;return b}var Qa="constructor hasOwnProperty isPrototypeOf propertyIsEnumerable toLocaleString toString valueOf".split(" ");function Ra(a,b){for(var c,d,e=1;e<arguments.length;e++){d=arguments[e];for(c in d)a[c]=d[c];for(var f=0;f<Qa.length;f++)c=Qa[f],Object.prototype.hasOwnProperty.call(d,c)&&(a[c]=d[c])}};function Sa(a){if("function"==typeof a.I)return a.I();if(D(a))return a.split("");if(da(a)){for(var b=[],c=a.length,d=0;d<c;d++)b.push(a[d]);return b}return Oa(a)};function Ta(a,b){this.b={};this.a=[];var c=arguments.length;if(1<c){if(c%2)throw Error("Uneven number of arguments");for(var d=0;d<c;d+=2)this.set(arguments[d],arguments[d+1])}else if(a){a instanceof Ta?(c=a.P(),d=a.I()):(c=Pa(a),d=Oa(a));for(var e=0;e<c.length;e++)this.set(c[e],d[e])}}v=Ta.prototype;v.l=0;v.xb=0;v.Za=p("l");v.I=function(){Ua(this);for(var a=[],b=0;b<this.a.length;b++)a.push(this.b[this.a[b]]);return a};v.P=function(){Ua(this);return this.a.concat()};v.$=function(){return 0==this.l};
v.clear=function(){this.b={};this.xb=this.l=this.a.length=0};v.remove=function(a){return Va(this.b,a)?(delete this.b[a],this.l--,this.xb++,this.a.length>2*this.l&&Ua(this),i):n};function Ua(a){if(a.l!=a.a.length){for(var b=0,c=0;b<a.a.length;){var d=a.a[b];Va(a.b,d)&&(a.a[c++]=d);b++}a.a.length=c}if(a.l!=a.a.length){for(var e={},c=b=0;b<a.a.length;)d=a.a[b],Va(e,d)||(a.a[c++]=d,e[d]=1),b++;a.a.length=c}}function Wa(a,b){return Va(a.b,b)?a.b[b]:h}
v.set=function(a,b){Va(this.b,a)||(this.l++,this.a.push(a),this.xb++);this.b[a]=b};v.H=function(){return new Ta(this)};function Va(a,b){return Object.prototype.hasOwnProperty.call(a,b)};var Xa,Ya,Za,$a,ab,bb,cb;function db(){return x.navigator?x.navigator.userAgent:k}function eb(){return x.navigator}$a=Za=Ya=Xa=n;var fb;if(fb=db()){var gb=eb();Xa=0==fb.indexOf("Opera");Ya=!Xa&&-1!=fb.indexOf("MSIE");Za=!Xa&&-1!=fb.indexOf("WebKit");$a=!Xa&&!Za&&"Gecko"==gb.product}var hb=Xa,J=Ya,ib=$a,K=Za,jb,kb=eb();jb=kb&&kb.platform||"";ab=-1!=jb.indexOf("Mac");bb=-1!=jb.indexOf("Win");cb=-1!=jb.indexOf("Linux");var lb=!!eb()&&-1!=(eb().appVersion||"").indexOf("X11"),mb;
a:{var nb="",ob;if(hb&&x.opera)var pb=x.opera.version,nb="function"==typeof pb?pb():pb;else if(ib?ob=/rv\:([^\);]+)(\)|;)/:J?ob=/MSIE\s+([^\);]+)(\)|;)/:K&&(ob=/WebKit\/(\S+)/),ob)var qb=ob.exec(db()),nb=qb?qb[1]:"";if(J){var rb,sb=x.document;rb=sb?sb.documentMode:h;if(rb>parseFloat(nb)){mb=String(rb);break a}}mb=nb}var tb={};
function ub(a){var b;if(!(b=tb[a])){b=0;for(var c=String(mb).replace(/^[\s\xa0]+|[\s\xa0]+$/g,"").split("."),d=String(a).replace(/^[\s\xa0]+|[\s\xa0]+$/g,"").split("."),e=Math.max(c.length,d.length),f=0;0==b&&f<e;f++){var g=c[f]||"",j=d[f]||"",s=RegExp("(\\d*)(\\D*)","g"),q=RegExp("(\\d*)(\\D*)","g");do{var l=s.exec(g)||["","",""],m=q.exec(j)||["","",""];if(0==l[0].length&&0==m[0].length)break;b=((0==l[1].length?0:parseInt(l[1],10))<(0==m[1].length?0:parseInt(m[1],10))?-1:(0==l[1].length?0:parseInt(l[1],
10))>(0==m[1].length?0:parseInt(m[1],10))?1:0)||((0==l[2].length)<(0==m[2].length)?-1:(0==l[2].length)>(0==m[2].length)?1:0)||(l[2]<m[2]?-1:l[2]>m[2]?1:0)}while(0==b)}b=tb[a]=0<=b}return b}var vb={};function wb(a){return vb[a]||(vb[a]=J&&!!document.documentMode&&document.documentMode>=a)};var xb=RegExp("^(?:([^:/?#.]+):)?(?://(?:([^/?#]*)@)?([\\w\\d\\-\\u0100-\\uffff.%]*)(?::([0-9]+))?)?([^?#]+)?(?:\\?([^#]*))?(?:#(.*))?$");function yb(a){if(a[1]){var b=a[0],c=b.indexOf("#");0<=c&&(a.push(b.substr(c)),a[0]=b=b.substr(0,c));c=b.indexOf("?");0>c?a[1]="?":c==b.length-1&&(a[1]=h)}return a.join("")}function zb(a,b,c){if(ca(b))for(var d=0;d<b.length;d++)zb(a,String(b[d]),c);else b!=k&&c.push("&",a,""===b?"":"=",encodeURIComponent(String(b)))}
function Ab(a,b){for(var c in b)zb(c,b[c],a);return a};function Bb(a,b){var c;if(a instanceof Bb)this.Y=z(b)?b:a.Y,Cb(this,a.ja),c=a.Ua,Db(this),this.Ua=c,c=a.ma,Db(this),this.ma=c,Eb(this,a.Na),c=a.La,Db(this),this.La=c,Fb(this,a.a.H()),c=a.va,Db(this),this.va=c;else if(a&&(c=String(a).match(xb))){this.Y=!!b;Cb(this,c[1]||"",i);var d=c[2]||"";Db(this);this.Ua=d?decodeURIComponent(d):"";d=c[3]||"";Db(this);this.ma=d?decodeURIComponent(d):"";Eb(this,c[4]);d=c[5]||"";Db(this);this.La=d?decodeURIComponent(d):"";Fb(this,c[6]||"",i);c=c[7]||"";Db(this);this.va=
c?decodeURIComponent(c):""}else this.Y=!!b,this.a=new Gb(k,0,this.Y)}v=Bb.prototype;v.ja="";v.Ua="";v.ma="";v.Na=k;v.La="";v.va="";v.Mc=n;v.Y=n;
v.toString=function(){var a=[],b=this.ja;b&&a.push(Hb(b,Ib),":");if(b=this.ma){a.push("//");var c=this.Ua;c&&a.push(Hb(c,Ib),"@");a.push(encodeURIComponent(String(b)));b=this.Na;b!=k&&a.push(":",String(b))}if(b=this.La)this.ma&&"/"!=b.charAt(0)&&a.push("/"),a.push(Hb(b,"/"==b.charAt(0)?Jb:Kb));(b=this.a.toString())&&a.push("?",b);(b=this.va)&&a.push("#",Hb(b,Lb));return a.join("")};v.H=function(){return new Bb(this)};
function Cb(a,b,c){Db(a);a.ja=c?b?decodeURIComponent(b):"":b;a.ja&&(a.ja=a.ja.replace(/:$/,""))}function Eb(a,b){Db(a);if(b){b=Number(b);if(isNaN(b)||0>b)throw Error("Bad port number "+b);a.Na=b}else a.Na=k}
function Fb(a,b,c){Db(a);if(b instanceof Gb){a.a=b;b=a.a;if((a=a.Y)&&!b.b){Mb(b);b.a=k;var d=b.s,c=function(a,b){var c=b.toLowerCase();b!=c&&(this.remove(b),Nb(this,c,a))};if("function"==typeof d.forEach)d.forEach(c,b);else if(da(d)||D(d))I(d,c,b);else{var e;if("function"==typeof d.P)e=d.P();else if("function"!=typeof d.I)if(da(d)||D(d)){e=[];for(var f=d.length,g=0;g<f;g++)e.push(g)}else e=Pa(d);else e=h;d=Sa(d);f=d.length;for(g=0;g<f;g++)c.call(b,d[g],e&&e[g])}}b.b=a}else c||(b=Hb(b,Ob)),a.a=new Gb(b,
0,a.Y)}function Pb(a,b,c){Db(a);ca(c)||(c=[String(c)]);Nb(a.a,b,c)}function Db(a){if(a.Mc)throw Error("Tried to modify a read-only Uri");}function Hb(a,b){return D(a)?encodeURI(a).replace(b,Qb):k}function Qb(a){a=a.charCodeAt(0);return"%"+(a>>4&15).toString(16)+(a&15).toString(16)}var Ib=/[#\/\?@]/g,Kb=/[\#\?:]/g,Jb=/[\#\?]/g,Ob=/[\#\?@]/g,Lb=/#/g;function Gb(a,b,c){this.a=a||k;this.b=!!c}
function Mb(a){if(!a.s&&(a.s=new Ta,a.l=0,a.a))for(var b=a.a.split("&"),c=0;c<b.length;c++){var d=b[c].indexOf("="),e=k,f=k;0<=d?(e=b[c].substring(0,d),f=b[c].substring(d+1)):e=b[c];e=decodeURIComponent(e.replace(/\+/g," "));e=Rb(a,e);a.add(e,f?decodeURIComponent(f.replace(/\+/g," ")):"")}}v=Gb.prototype;v.s=k;v.l=k;v.Za=function(){Mb(this);return this.l};v.add=function(a,b){Mb(this);this.a=k;var a=Rb(this,a),c=Wa(this.s,a);c||this.s.set(a,c=[]);c.push(b);this.l++;return this};
v.remove=function(a){Mb(this);a=Rb(this,a);return Va(this.s.b,a)?(this.a=k,this.l-=Wa(this.s,a).length,this.s.remove(a)):n};v.clear=function(){this.s=this.a=k;this.l=0};v.$=function(){Mb(this);return 0==this.l};function Sb(a,b){Mb(a);b=Rb(a,b);return Va(a.s.b,b)}v.P=function(){Mb(this);for(var a=this.s.I(),b=this.s.P(),c=[],d=0;d<b.length;d++)for(var e=a[d],f=0;f<e.length;f++)c.push(b[d]);return c};
v.I=function(a){Mb(this);var b=[];if(a)Sb(this,a)&&(b=Ha(b,Wa(this.s,Rb(this,a))));else for(var a=this.s.I(),c=0;c<a.length;c++)b=Ha(b,a[c]);return b};v.set=function(a,b){Mb(this);this.a=k;a=Rb(this,a);Sb(this,a)&&(this.l-=Wa(this.s,a).length);this.s.set(a,[b]);this.l++;return this};function Nb(a,b,c){a.remove(b);0<c.length&&(a.a=k,a.s.set(Rb(a,b),Ia(c)),a.l+=c.length)}
v.toString=function(){if(this.a)return this.a;if(!this.s)return"";for(var a=[],b=this.s.P(),c=0;c<b.length;c++)for(var d=b[c],e=encodeURIComponent(String(d)),d=this.I(d),f=0;f<d.length;f++){var g=e;""!==d[f]&&(g+="="+encodeURIComponent(String(d[f])));a.push(g)}return this.a=a.join("&")};v.H=function(){var a=new Gb;a.a=this.a;this.s&&(a.s=this.s.H());return a};function Rb(a,b){var c=String(b);a.b&&(c=c.toLowerCase());return c};var Tb=!J||wb(9),Ub=!J||wb(9),Vb=J&&!ub("9");!K||ub("528");ib&&ub("1.9b")||J&&ub("8")||hb&&ub("9.5")||K&&ub("528");ib&&!ub("8")||J&&ub("9");function L(){0!=Wb&&(this.gd=Error().stack,Xb[E(this)]=this)}var Wb=0,Xb={};L.prototype.Pb=n;L.prototype.Ya=function(){if(!this.Pb&&(this.Pb=i,this.q(),0!=Wb)){var a=E(this);delete Xb[a]}};function Yb(a,b){a.Q||(a.Q=[]);a.Q.push(b)}L.prototype.q=function(){this.Q&&Zb.apply(k,this.Q);if(this.Wb)for(;this.Wb.length;)this.Wb.shift()()};function $b(a){a&&"function"==typeof a.Ya&&a.Ya()}function Zb(a){for(var b=0,c=arguments.length;b<c;++b){var d=arguments[b];da(d)?Zb.apply(k,d):$b(d)}};function ac(a,b){this.type=a;this.b=this.target=b}v=ac.prototype;v.Ya=function(){};v.ba=n;v.Aa=n;v.Pa=i;v.$a=function(){this.ba=i};v.v=function(){this.Aa=i;this.Pa=n};function bc(a){a.$a()};function cc(a){cc[" "](a);return a}cc[" "]=y;function dc(a,b){a&&ec(this,a,b)}G(dc,ac);var fc=[1,4,2];v=dc.prototype;v.target=k;v.zc=k;v.xc=0;v.yc=0;v.clientX=0;v.clientY=0;v.Ac=0;v.Bc=0;v.vc=0;v.ga=0;v.ya=0;v.za=n;v.M=n;v.Z=n;v.wc=n;v.Ma=n;v.C=k;
function ec(a,b,c){var d=a.type=b.type;ac.call(a,d);a.target=b.target||b.srcElement;a.b=c;if(c=b.relatedTarget){if(ib){var e;a:{try{cc(c.nodeName);e=i;break a}catch(f){}e=n}e||(c=k)}}else"mouseover"==d?c=b.fromElement:"mouseout"==d&&(c=b.toElement);a.zc=c;a.xc=K||b.offsetX!==h?b.offsetX:b.layerX;a.yc=K||b.offsetY!==h?b.offsetY:b.layerY;a.clientX=b.clientX!==h?b.clientX:b.pageX;a.clientY=b.clientY!==h?b.clientY:b.pageY;a.Ac=b.screenX||0;a.Bc=b.screenY||0;a.vc=b.button;a.ga=b.keyCode||0;a.ya=b.charCode||
("keypress"==d?b.keyCode:0);a.za=b.ctrlKey;a.M=b.altKey;a.Z=b.shiftKey;a.wc=b.metaKey;a.Ma=ab?b.metaKey:b.ctrlKey;a.d=b.state;a.C=b;b.defaultPrevented&&a.v();delete a.ba}function gc(a){return(Tb?0==a.C.button:"click"==a.type?i:!!(a.C.button&fc[0]))&&!(K&&ab&&a.za)}v.$a=function(){dc.p.$a.call(this);this.C.stopPropagation?this.C.stopPropagation():this.C.cancelBubble=i};
v.v=function(){dc.p.v.call(this);var a=this.C;if(a.preventDefault)a.preventDefault();else if(a.returnValue=n,Vb)try{if(a.ctrlKey||112<=a.keyCode&&123>=a.keyCode)a.keyCode=-1}catch(b){}};v.tc=p("C");function hc(){}var ic=0;hc.prototype.key=0;hc.prototype.ha=n;hc.prototype.a=n;hc.prototype.handleEvent=function(a){return this.b?this.qa.call(this.mb||this.src,a):this.qa.handleEvent.call(this.qa,a)};var jc={},kc={},lc={},mc={};
function M(a,b,c,d,e){if(b){if(ca(b)){for(var f=0;f<b.length;f++)M(a,b[f],c,d,e);return k}var d=!!d,g=kc;b in g||(g[b]={l:0,F:0});g=g[b];d in g||(g[d]={l:0,F:0},g.l++);var g=g[d],j=E(a),s;g.F++;if(g[j]){s=g[j];for(f=0;f<s.length;f++)if(g=s[f],g.qa==c&&g.mb==e){if(g.ha)break;return s[f].key}}else s=g[j]=[],g.l++;var q=nc,l=Ub?function(a){return q.call(l.src,l.key,a)}:function(a){a=q.call(l.src,l.key,a);if(!a)return a},f=l;f.src=a;var m=g=new hc;if(ea(c))m.b=i;else if(c&&c.handleEvent&&ea(c.handleEvent))m.b=
n;else throw Error("Invalid listener argument");m.qa=c;m.c=f;m.src=a;m.type=b;m.capture=!!d;m.mb=e;m.a=n;m.key=++ic;m.ha=n;c=g.key;f.key=c;s.push(g);jc[c]=g;lc[j]||(lc[j]=[]);lc[j].push(g);a.addEventListener?(a==x||!a.Cb)&&a.addEventListener(b,f,d):a.attachEvent(b in mc?mc[b]:mc[b]="on"+b,f);return c}throw Error("Invalid event type");}function oc(a,b,c,d,e){if(ca(b)){for(var f=0;f<b.length;f++)oc(a,b[f],c,d,e);return k}a=M(a,b,c,d,e);jc[a].a=i;return a}
function pc(a,b,c,d,e){if(ca(b))for(var f=0;f<b.length;f++)pc(a,b[f],c,d,e);else{d=!!d;a:{f=kc;if(b in f&&(f=f[b],d in f&&(f=f[d],a=E(a),f[a]))){a=f[a];break a}a=k}if(a)for(f=0;f<a.length;f++)if(a[f].qa==c&&a[f].capture==d&&a[f].mb==e){N(a[f].key);break}}}
function N(a){if(!jc[a])return n;var b=jc[a];if(b.ha)return n;var c=b.src,d=b.type,e=b.c,f=b.capture;c.removeEventListener?(c==x||!c.Cb)&&c.removeEventListener(d,e,f):c.detachEvent&&c.detachEvent(d in mc?mc[d]:mc[d]="on"+d,e);c=E(c);if(lc[c]){var e=lc[c],g=Ca(e,b);0<=g&&H.splice.call(e,g,1);0==e.length&&delete lc[c]}b.ha=i;if(b=kc[d][f][c])b.Nb=i,qc(d,f,c,b);delete jc[a];return i}
function qc(a,b,c,d){if(!d.Ja&&d.Nb){for(var e=0,f=0;e<d.length;e++)d[e].ha?d[e].c.src=k:(e!=f&&(d[f]=d[e]),f++);d.length=f;d.Nb=n;0==f&&(delete kc[a][b][c],kc[a][b].l--,0==kc[a][b].l&&(delete kc[a][b],kc[a].l--),0==kc[a].l&&delete kc[a])}}function rc(a,b,c,d,e){var f=1,b=E(b);if(a[b]){a.F--;a=a[b];a.Ja?a.Ja++:a.Ja=1;try{for(var g=a.length,j=0;j<g;j++){var s=a[j];s&&!s.ha&&(f&=sc(s,e)!==n)}}finally{a.Ja--,qc(c,d,b,a)}}return Boolean(f)}function sc(a,b){a.a&&N(a.key);return a.handleEvent(b)}
function O(a,b){var c=b.type||b,d=kc;if(!(c in d))return i;if(D(b))b=new ac(b,a);else if(b instanceof ac)b.target=b.target||a;else{var e=b,b=new ac(c,a);Ra(b,e)}var e=1,f,d=d[c],c=i in d,g;if(c){f=[];for(g=a;g;g=g.ob)f.push(g);g=d[i];g.F=g.l;for(var j=f.length-1;!b.ba&&0<=j&&g.F;j--)b.b=f[j],e&=rc(g,f[j],b.type,i,b)&&b.Pa!=n}if(n in d)if(g=d[n],g.F=g.l,c)for(j=0;!b.ba&&j<f.length&&g.F;j++)b.b=f[j],e&=rc(g,f[j],b.type,n,b)&&b.Pa!=n;else for(d=a;!b.ba&&d&&g.F;d=d.ob)b.b=d,e&=rc(g,d,b.type,n,b)&&b.Pa!=
n;return Boolean(e)}
function nc(a,b){if(!jc[a])return i;var c=jc[a],d=c.type,e=kc;if(!(d in e))return i;var e=e[d],f,g;if(!Ub){var j;if(!(j=b))a:{j=["window","event"];for(var s=x;f=j.shift();)if(s[f]!=k)s=s[f];else{j=k;break a}j=s}f=j;j=i in e;s=n in e;if(j){if(0>f.keyCode||f.returnValue!=h)return i;a:{var q=n;if(0==f.keyCode)try{f.keyCode=-1;break a}catch(l){q=i}if(q||f.returnValue==h)f.returnValue=i}}q=new dc;ec(q,f,this);f=i;try{if(j){for(var m=[],u=q.b;u;u=u.parentNode)m.push(u);g=e[i];g.F=g.l;for(var w=m.length-
1;!q.ba&&0<=w&&g.F;w--)q.b=m[w],f&=rc(g,m[w],d,i,q);if(s){g=e[n];g.F=g.l;for(w=0;!q.ba&&w<m.length&&g.F;w++)q.b=m[w],f&=rc(g,m[w],d,n,q)}}else f=sc(c,q)}finally{m&&(m.length=0)}return f}d=new dc(b,this);return f=sc(c,d)};var tc,uc=!J||wb(9);!ib&&!J||J&&wb(9)||ib&&ub("1.9.1");J&&ub("9");function vc(a,b){var c;c=a.className;c=D(c)&&c.match(/\S+/g)||[];for(var d=Ka(arguments,1),e=c.length+d.length,f=c,g=0;g<d.length;g++)0<=Ca(f,d[g])||f.push(d[g]);a.className=c.join(" ");return c.length==e};function wc(a,b,c){return Math.min(Math.max(a,b),c)}function xc(a,b){var c=a%b;return 0>c*b?c+b:c};function yc(a,b){this.x=z(a)?a:0;this.y=z(b)?b:0}yc.prototype.H=function(){return new yc(this.x,this.y)};function zc(a,b){this.width=a;this.height=b}v=zc.prototype;v.H=function(){return new zc(this.width,this.height)};v.$=function(){return!(this.width*this.height)};v.ceil=function(){this.width=Math.ceil(this.width);this.height=Math.ceil(this.height);return this};v.floor=function(){this.width=Math.floor(this.width);this.height=Math.floor(this.height);return this};v.round=function(){this.width=Math.round(this.width);this.height=Math.round(this.height);return this};function Ac(a){return a?new Bc(Cc(a)):tc||(tc=new Bc)}function Dc(a,b){Na(b,function(b,d){"style"==d?a.style.cssText=b:"class"==d?a.className=b:"for"==d?a.htmlFor=b:d in Ec?a.setAttribute(Ec[d],b):0==d.lastIndexOf("aria-",0)||0==d.lastIndexOf("data-",0)?a.setAttribute(d,b):a[d]=b})}var Ec={cellpadding:"cellPadding",cellspacing:"cellSpacing",colspan:"colSpan",frameborder:"frameBorder",height:"height",maxlength:"maxLength",role:"role",rowspan:"rowSpan",type:"type",usemap:"useMap",valign:"vAlign",width:"width"};
function Fc(a){a=a.document.documentElement;return new zc(a.clientWidth,a.clientHeight)}function Gc(a,b,c){var d=arguments,e=document,f=d[0],g=d[1];if(!uc&&g&&(g.name||g.type)){f=["<",f];g.name&&f.push(' name="',pa(g.name),'"');if(g.type){f.push(' type="',pa(g.type),'"');var j={};Ra(j,g);delete j.type;g=j}f.push(">");f=f.join("")}f=e.createElement(f);g&&(D(g)?f.className=g:ca(g)?vc.apply(k,[f].concat(g)):Dc(f,g));2<d.length&&Hc(e,f,d,2);return f}
function Hc(a,b,c,d){function e(c){c&&b.appendChild(D(c)?a.createTextNode(c):c)}for(;d<c.length;d++){var f=c[d];if(da(f)&&!(fa(f)&&0<f.nodeType)){var g=I,j;a:{if((j=f)&&"number"==typeof j.length){if(fa(j)){j="function"==typeof j.item||"string"==typeof j.item;break a}if(ea(j)){j="function"==typeof j.item;break a}}j=n}g(j?Ia(f):f,e)}else e(f)}}function Ic(a,b){Hc(Cc(a),a,arguments,1)}function Jc(a,b){a.insertBefore(b,a.childNodes[0]||k)}function Kc(a){a&&a.parentNode&&a.parentNode.removeChild(a)}
function Cc(a){return 9==a.nodeType?a:a.ownerDocument||a.document}function Bc(a){this.a=a||x.document||document}Bc.prototype.createElement=function(a){return this.a.createElement(a)};Bc.prototype.createTextNode=function(a){return this.a.createTextNode(a)};function Lc(a){var b=a.a,a=!K?b.documentElement:b.body,b=b.parentWindow||b.defaultView;return new yc(b.pageXOffset||a.scrollLeft,b.pageYOffset||a.scrollTop)}Bc.prototype.appendChild=function(a,b){a.appendChild(b)};
Bc.prototype.contains=function(a,b){if(a.contains&&1==b.nodeType)return a==b||a.contains(b);if("undefined"!=typeof a.compareDocumentPosition)return a==b||Boolean(a.compareDocumentPosition(b)&16);for(;b&&a!=b;)b=b.parentNode;return b==a};/*
Portions of this code are from MochiKit, received by
The Closure Authors under the MIT license. All other code is Copyright
2005-2009 The Closure Authors. All Rights Reserved.
*/
function Mc(a,b){this.a=[];this.f=a;this.e=b||k}v=Mc.prototype;v.V=n;v.pa=n;v.ra=0;v.ac=n;v.jc=n;v.ic=0;v.Ab=function(a,b){Nc(this,a,b);this.ra--;0==this.ra&&this.V&&Oc(this)};function Nc(a,b,c){a.V=i;a.b=c;a.pa=!b;Oc(a)}function Pc(a){if(a.V){if(!a.ac)throw new Qc(a);a.ac=n}}function Rc(a){return Fa(a.a,function(a){return ea(a[1])})}
function Oc(a){a.c&&(a.V&&Rc(a))&&(x.clearTimeout(a.c),delete a.c);a.d&&(a.d.ic--,delete a.d);for(var b=a.b,c=n,d=n;a.a.length&&0==a.ra;){var e=a.a.shift(),f=e[0],g=e[1],e=e[2];if(f=a.pa?g:f)try{var j=f.call(e||a.e,b);z(j)&&(a.pa=a.pa&&(j==b||j instanceof Error),a.b=b=j);b instanceof Mc&&(d=i,a.ra++)}catch(s){b=s,a.pa=i,Rc(a)||(c=i)}}a.b=b;d&&a.ra&&(d=b,j=ka(a.Ab,a,i),f=ka(a.Ab,a,n),d.a.push([j,f,h]),d.V&&Oc(d),b.jc=i);c&&(a.c=x.setTimeout(function(){throw b;},0))}
function Qc(a){oa.call(this);this.a=a}G(Qc,oa);Qc.prototype.message="Deferred has already fired";Qc.prototype.name="AlreadyCalledError";function Sc(a,b){var c=b||{},d=c.document||document,e=document.createElement("SCRIPT"),f={Yb:e,Ta:h},g=new Mc(Tc,f),j=k,s=c.timeout!=k?c.timeout:5E3;0<s&&(j=window.setTimeout(function(){Uc(e,i);var b=new Vc(Wc,"Timeout reached for loading script "+a);Pc(g);Nc(g,n,b)},s),f.Ta=j);e.onload=e.onreadystatechange=function(){if(!e.readyState||"loaded"==e.readyState||"complete"==e.readyState)Uc(e,c.zb||n,j),Pc(g),Nc(g,i,k)};e.onerror=function(){Uc(e,i,j);var b=new Vc($c,"Error while loading script "+a);Pc(g);
Nc(g,n,b)};Dc(e,{type:"text/javascript",charset:"UTF-8",src:a});f=d.getElementsByTagName("HEAD");(!f||0==f.length?d.documentElement:f[0]).appendChild(e);return g}function Tc(){if(this&&this.Yb){var a=this.Yb;a&&"SCRIPT"==a.tagName&&Uc(a,i,this.Ta)}}function Uc(a,b,c){c!=k&&x.clearTimeout(c);a.onload=y;a.onerror=y;a.onreadystatechange=y;b&&window.setTimeout(function(){Kc(a)},0)}var $c=0,Wc=1;function Vc(a,b){var c="Jsloader error (code #"+a+")";b&&(c+=": "+b);oa.call(this,c);this.a=a}G(Vc,oa);function ad(a){this.b=new Bb(a);this.a="jsonp";this.Ta=5E3}var bd=0;function cd(a,b){x._callbacks_[a]&&(b?delete x._callbacks_[a]:x._callbacks_[a]=y)};function dd(a,b){this.x=a;this.y=b}G(dd,yc);dd.prototype.H=function(){return new dd(this.x,this.y)};dd.prototype.add=function(a){this.x+=a.x;this.y+=a.y;return this};dd.prototype.rotate=function(a){var b=Math.cos(a),a=Math.sin(a),c=this.y*b+this.x*a;this.x=this.x*b-this.y*a;this.y=c;return this};function R(a,b){dd.call(this,a,b)}G(R,dd);function ed(a,b){var c=xc(a+180,360)-180,d=Math.abs(Math.round(3600*c));return Math.floor(d/3600)+"\u00b0 "+Math.floor(d/60%60)+"\u2032 "+Math.floor(d%60)+"\u2033 "+b.charAt(0>c?1:0)};function fd(a,b){zc.call(this,a,b)}G(fd,zc);function gd(a,b,c,d){this.h=a;this.i=b;this.j=c;this.m=d}gd.prototype.a=function(){return this.m-this.i};gd.prototype.b=function(){return this.j-this.h};function hd(a,b){return a.h<=b.j&&a.j>=b.h&&a.i<=b.m&&a.m>=b.i}gd.prototype.toString=function(){return"("+[this.h,this.i,this.j,this.m].join(", ")+")"};function S(a,b,c){dd.call(this,b,c);this.k=a}G(S,R);S.prototype.hash=function(){return(this.x<<this.k)+this.y};function id(a){var b=Array(a.k),c=1<<a.k-1,d,e;for(d=0;d<a.k;++d)e=48,a.x&c&&(e+=1),a.y&c&&(e+=2),b[d]=String.fromCharCode(e),c>>=1;return b.join("")}S.prototype.toString=function(){return[this.k,this.x,this.y].join("/")};function jd(a,b,c,d){gd.call(this,a,b,c,d)}G(jd,gd);jd.prototype.contains=function(a){return this.h<=a.x&&a.x<=this.j&&this.i<=a.y&&a.y<=this.m};jd.prototype.a=function(){return this.m-this.i+1};jd.prototype.b=function(){return this.j-this.h+1};function kd(a,b,c,d){gd.call(this,a,b,c,d)}G(kd,gd);function ld(a){var b=arguments[0],b=new kd(b.x,b.y,b.x,b.y),c;for(c=1;c<arguments.length;++c){var d=arguments[c];b.h=Math.min(b.h,d.x);b.i=Math.min(b.i,d.y);b.j=Math.max(b.j,d.x);b.m=Math.max(b.m,d.y)}return b}kd.prototype.contains=function(a){return this.h<=a.x&&a.x<=this.j&&this.i<=a.y&&a.y<=this.m};function md(a){return new R(a.h,a.m)}
kd.prototype.transform=function(a){var b=a(new R(this.h,this.i)),a=a(new R(this.j,this.m));return new kd(b.x,b.y,a.x,a.y)};function nd(){L.call(this)}G(nd,L);v=nd.prototype;v.Cb=i;v.ob=k;v.addEventListener=function(a,b,c,d){M(this,a,b,c,d)};v.removeEventListener=function(a,b,c,d){pc(this,a,b,c,d)};v.q=function(){nd.p.q.call(this);var a,b=0,c=a==k;a=!!a;if(this==k)Na(lc,function(d){for(var e=d.length-1;0<=e;e--){var f=d[e];if(c||a==f.capture)N(f.key),b++}});else{var d=E(this);if(lc[d])for(var d=lc[d],e=d.length-1;0<=e;e--){var f=d[e];if(c||a==f.capture)N(f.key),b++}}this.ob=k};function od(a){L.call(this);this.da=a;this.a=0}G(od,nd);od.prototype.getKey=function(){return E(this).toString()};function pd(a,b,c){od.call(this,a);this.e=b;this.b=new Image;c!==k&&(this.b.crossOrigin=c);this.d={};this.c=k}G(pd,od);v=pd.prototype;v.W=function(a){if(z(a)){var b,a=E(a);if(a in this.d)return this.d[a];a:{for(b in this.d){b=n;break a}b=i}b=b?this.b:this.b.cloneNode(n);return this.d[a]=b}return this.b};v.getKey=p("e");v.Ec=function(){this.a=3;I(this.c,N);this.c=k;O(this,"change")};v.Fc=function(){this.a=2;I(this.c,N);this.c=k;O(this,"change")};
v.load=function(){0==this.a&&(this.a=1,this.c=[oc(this.b,"error",this.Ec,n,this),oc(this.b,"load",this.Fc,n,this)],this.b.src=this.e)};var qd={ed:"degrees",hd:"m"};function U(a,b,c){this.a=a;this.e=b;this.d=c}U.prototype.b=p("a");U.prototype.K=p("d");U.prototype.c=p("e");function rd(a,b){U.call(this,a,b.units,k);this.Vb=b}G(rd,U);var sd={},td={},ud={};function vd(a){I(a,function(a){wd(a)});I(a,function(b){I(a,function(a){b!==a&&xd(b,a,yd)})})}function wd(a){td[a.a]=a;xd(a,a,yd)}function zd(a){return a!=k?D(a)?Ad(a):a:Ad("EPSG:3857")}function xd(a,b,c){a=a.a;b=b.a;a in ud||(ud[a]={});ud[a][b]=c}
function Ad(a){var b=td[a];"Proj4js"in x&&!z(b)&&(b=Bd(a));z(b)||(b=k);return b}function Bd(a){var b=sd[a];z(b)||(b=new Proj4js.Proj(a),b=new rd(a,b),sd[a]=b);return b}function Cd(a,b){var c=a.a,d=b.a,e;c in ud&&d in ud[c]&&(e=ud[c][d]);if("Proj4js"in x&&!z(e)){var f;f=(a instanceof rd?a:Bd(a.a)).Vb;var g;g=(b instanceof rd?b:Bd(a.a)).Vb;e=function(a){a=new Proj4js.Point(a.x,a.y);a=Proj4js.transform(f,g,a);return new R(a.x,a.y)};xd(a,b,e)}z(e)||(e=Dd);return e}
function Ed(a,b){var c=Ad(a),d=Ad(b);return Cd(c,d)}function Dd(a){return a}function yd(a){return new R(a.x,a.y)}var Fd=6378137*Math.PI,Gd=new kd(-Fd,-Fd,Fd,Fd),Hd=Ea(["EPSG:3857","EPSG:102100","EPSG:102113","EPSG:900913"],function(a){return new U(a,"m",Gd)}),Id=new kd(-180,-90,180,90),Jd=Ea(["CRS:84","EPSG:4326","urn:ogc:def:crs:EPSG:6.6:4326"],function(a){return new U(a,"degrees",Id)});vd(Hd);vd(Jd);
function Kd(a){var b=6378137*Math.PI*a.x/180,a=6378137*Math.log(Math.tan(Math.PI*(a.y+90)/360));return new R(b,a)}function Ld(a){return new R(180*a.x/(6378137*Math.PI),360*Math.atan(Math.exp(a.y/6378137))/Math.PI-90)}I(Jd,function(a){I(Hd,function(b){xd(a,b,Kd);xd(b,a,Ld)})});function Md(a,b,c,d){gd.call(this,a,b,c,d)}G(Md,gd);function Nd(a,b){var c=a.length;if(a[0]<=b)return 0;if(!(b<=a[c-1])){var d;for(d=1;d<c;++d){if(a[d]==b)return d;if(a[d]<b)return a[d-1]-b<b-a[d]?d-1:d}}return c-1};function Od(a){this.a=a.resolutions;this.g=this.a.length;this.f=z(a.extent)?a.extent:k;this.d=z(a.origin)?a.origin:k;this.e=k;z(a.Pc)&&(this.e=a.Pc);this.b=z(a.Ra)?a.Ra:new fd(256,256)}Od.prototype.c=function(a,b,c){for(var d=Pd(this,a),a=a.k-1;0<=a&&!b.call(c,a,Qd(this,d,this.a[a]));)--a};Od.prototype.K=p("f");function Rd(a,b){return a.d===k?a.e[b]:a.d}function Qd(a,b,c){var d=Sd(a,new R(b.h,b.i),c),a=Sd(a,new R(b.j,b.m),c);return new jd(d.x,d.y,a.x,a.y)}
function Td(a,b){var c=Rd(a,b.k),d=a.a[b.k],e=a.b;return new R(c.x+(b.x+0.5)*e.width*d,c.y+(b.y+0.5)*e.height*d)}function Pd(a,b){var c=Rd(a,b.k),d=a.a[b.k],e=a.b,f=c.x+b.x*e.width*d,c=c.y+b.y*e.height*d;return new kd(f,c,f+e.width*d,c+e.height*d)}
function Sd(a,b,c){var d=Nd(a.a,c),e=c/a.a[d],f=Rd(a,d),b=new R(Math.floor((b.x-f.x)/c),Math.floor((b.y-f.y)/c)),f=a.b,f=new fd(f.width/e,f.height/e),d=new S(d,Math.floor(b.x/f.width),Math.floor(b.y/f.height)),c=c/a.a[d.k],a=a.b,a=new fd(a.width/c,a.height/c),c=Math.round(d.x*a.width),e=Math.round((d.x+1)*a.width),f=Math.round(d.y*a.height),a=Math.round((d.y+1)*a.height),a=new Md(c,f,e,a);b.x<a.h?d.x-=1:b.x>=a.j&&(d.x+=1);b.y<a.i?d.y-=1:b.y>=a.m&&(d.y+=1);return d};function Ud(a){var b=/\{(\d)-(\d)\}/.exec(a)||/\{([a-z])-([a-z])\}/.exec(a);if(b){var c=[],d=b[2].charCodeAt(0),e;for(e=b[1].charCodeAt(0);e<=d;++e)c.push(a.replace(b[0],String.fromCharCode(e)));return Vd(Ea(c,Ud))}return function(b){return b===k?h:a.replace("{z}",b.k).replace("{x}",b.x).replace("{y}",b.y)}}function Vd(a){return function(b){if(b!==k){var c=xc(b.hash(),a.length);return a[c](b)}}}
function Wd(a,b){return function(c){if(c!==k)return c=Pd(b,c),yb([a,"&","BBOX","=",encodeURIComponent(String([c.h,c.i,c.j,c.m].join()))])}}function Xd(){}function Yd(a,b){return function(c){return c===k?h:b(a(c))}};function Zd(a){return function(){return a}}var $d=Zd(n),ae=Zd(i),be=Zd(k);function ce(a){L.call(this);this.e=z(a.projection)?a.projection:k;this.d=z(a.extent)?a.extent:a.projection.K();this.ta=z(a.attributions)?a.attributions:k}G(ce,nd);ce.prototype.K=p("d");ce.prototype.a=ae;function de(a){ce.call(this,{attributions:a.attributions,extent:a.extent,projection:a.projection});this.tileGrid=z(a.tileGrid)?a.tileGrid:k}G(de,ce);function ee(a){de.call(this,{attributions:a.attributions,extent:a.extent,projection:a.projection,tileGrid:a.tileGrid});this.O=z(a.O)?a.O:Xd;this.f=z(a.crossOrigin)?a.crossOrigin:"anonymous";this.b={}}G(ee,de);function fe(a,b){var c=b.toString();if(c in a.b)return a.b[c];var d=a.O(b),d=z(d)?new pd(b,d,a.f):k;return a.b[c]=d};function ge(a){var b=Array(a.maxZoom+1),c;for(c=0;c<=a.maxZoom;++c)b[c]=2*Fd/(256<<c);Od.call(this,{extent:Gd,origin:new R(-Fd,Fd),resolutions:b,Ra:new fd(256,256)})}G(ge,Od);ge.prototype.c=function(a,b,c){for(var d=a.x,e=a.y,a=a.k,f;;){a-=1;if(0>a)break;d=Math.floor(d/2);e=Math.floor(e/2);f=new jd(d,e,d,e);if(b.call(c,a,f))break}};var he={ad:"Aerial",bd:"AerialWithLabels",kd:"Road",jd:"OrdnanceSurvey",dd:"CollinsBart"};
function ie(a){ee.call(this,{projection:Ad("EPSG:3857")});this.oc=z(a.culture)?a.culture:"en-us";this.c=n;var b=new Bb("//dev.virtualearth.net/REST/v1/Imagery/Metadata/"+a.style),b=new ad(b),a={include:"ImageryProviders",key:a.key},c=ka(this.g,this),a=a||k,d="_"+(bd++).toString(36)+ma().toString(36);x._callbacks_||(x._callbacks_={});var e=b.b.H();if(a)for(var f in a)(!a.hasOwnProperty||a.hasOwnProperty(f))&&Pb(e,f,a[f]);c&&(x._callbacks_[d]=function(a){cd(d,i);c.apply(h,arguments)},Pb(e,b.a,"_callbacks_."+
d));f=Sc(e.toString(),{timeout:b.Ta,zb:i});f.a.push([k,function(){cd(d,n)},h]);f.V&&Oc(f)}G(ie,ee);
ie.prototype.g=function(a){var b=a.resourceSets[0].resources[0],c=b.zoomMin,d=b.zoomMax,e=new ge({maxZoom:d,Ra:new fd(b.imageWidth,b.imageHeight)});this.tileGrid=e;this.O=Yd(function(a){if(a.k<c||d<a.k)return k;var b=1<<a.k,e=-a.y-1;return 0>e||b<=e?k:new S(a.k,xc(a.x,b),e)},Vd(Ea(b.imageUrlSubdomains,function(a){var c=b.imageUrl.replace("{subdomain}",a).replace("{culture}",this.oc);return function(a){return a===k?h:c.replace("{quadkey}",id(a))}})));var f=Cd(Ad("EPSG:4326"),this.e);this.ta=Ea(b.imageryProviders,
function(a){var b=a.attribution,c={};I(a.coverageAreas,function(a){var b=a.zoomMin,d=a.zoomMax,a=a.bbox,a=(new kd(a[1],a[0],a[3],a[2])).transform(f),g,j;for(g=b;g<=d;++g)j=g.toString(),b=Qd(e,a,e.a[g]),j in c?c[j].push(b):c[j]=[b]});return new na(b,c)});this.c=i;O(this,"load")};ie.prototype.a=p("c");function V(a){L.call(this);z(a)&&this.Ka(a)}G(V,nd);var je={},ke={},le={};function me(a){return a.substr(0,1).toUpperCase()+a.substr(1)}function ne(a){return a.ol_accessors_||(a.ol_accessors_={})}function oe(a){return je[a]||(je[a]=a.toLowerCase()+"_changed")}function pe(a){return a.ol_bindings_||(a.ol_bindings_={})}v=V.prototype;v.hc=function(a,b,c,d){c=c||a;this.wb(a);var e=oe(c);pe(this)[a]=M(b,e,function(){qe(this,a)},h,this);ne(this)[a]={target:b,key:c};d||qe(this,a)};v.kc=y;
v.u=function(a){var b=ne(this);if(a in b){var b=b[a],a=b.target,b=b.key,c=ke[b]||(ke[b]="get"+me(b));return a[c]?a[c]():a.u(b)}return this[a]};v.Ob=function(a){var b=ne(this);a in b?(a=b[a],a.target.Ob(a.key)):qe(this,a)};function qe(a,b){var c=oe(b);O(a,c);O(a,"changed")}v.set=function(a,b){var c=ne(this);if(a in c){var d=c[a],c=d.target,d=d.key,e=le[d]||(le[d]="set"+me(d));if(c[e])c[e](b);else c.set(d,b)}else this[a]=b,qe(this,a)};
v.$b=function(a){Na(a,function(a,c){var d=le[c]||(le[c]="set"+me(c));if(this[d])this[d](a);else this.set(c,a)},this)};v.Ka=V.prototype.$b;v.wb=function(a){var b=pe(this),c=b[a];c&&(delete b[a],N(c),b=this.u(a),delete ne(this)[a],this[a]=b)};v.Yc=function(){var a=pe(this);I(Pa(a),function(a){this.wb(a)},this)};function re(a,b,c,d,e){ac.call(this,a,e);this.a=b;this.index=c;this.c=d}G(re,ac);function W(a){V.call(this);this.a=a||[];se(this)}G(W,V);v=W.prototype;v.clear=function(){for(;this.length;)this.Qb()};v.forEach=function(a,b){I(this.a,a,b)};v.rc=p("a");v.sc=function(a){return this.a[a]};v.Db=function(){return this.u("length")};v.Ca=function(a,b){Ja(this.a,a,0,b);se(this);O(this,new re("add",b,h,h,this));O(this,new re("insert_at",b,a,h,this))};v.Qb=function(){return this.Xb(this.Db()-1)};
v.push=function(a){var b=this.a.length;this.Ca(b,a);return b};v.Xb=function(a){var b=this.a[a];H.splice.call(this.a,a,1);se(this);O(this,new re("remove",b,h,h,this));O(this,new re("remove_at",h,a,b,this));return b};v.Sc=function(a,b){var c=this.length;if(a<c)c=this.a[a],this.a[a]=b,O(this,new re("set_at",b,a,c,this)),O(this,new re("remove",c,h,h,this)),O(this,new re("add",b,h,h,this));else{for(;c<a;++c)this.Ca(c,h);this.Ca(a,b)}};function se(a){a.set("length",a.a.length)};function te(a,b,c){L.call(this);this.g=a;this.f=c;this.b=b||window;this.c=ka(this.d,this)}G(te,L);te.prototype.a=k;te.prototype.e=n;function ue(a){if(a.a!=k){var b=ve(a),c=we(a);b&&!c&&a.b.mozRequestAnimationFrame?N(a.a):b&&c?c.call(a.b,a.a):a.b.clearTimeout(a.a)}a.a=k}te.prototype.d=function(){this.e&&this.a&&N(this.a);this.a=k;this.g.call(this.f,ma())};te.prototype.q=function(){ue(this);te.p.q.call(this)};
function ve(a){a=a.b;return a.requestAnimationFrame||a.webkitRequestAnimationFrame||a.mozRequestAnimationFrame||a.oRequestAnimationFrame||a.msRequestAnimationFrame||k}function we(a){a=a.b;return a.cancelRequestAnimationFrame||a.webkitCancelRequestAnimationFrame||a.mozCancelRequestAnimationFrame||a.oCancelRequestAnimationFrame||a.msCancelRequestAnimationFrame||k};function xe(a){L.call(this);this.ea=a||window;this.Ia=M(this.ea,"resize",this.Kc,n,this);this.ca=Fc(this.ea||window);if(K&&bb||hb&&this.ea.self!=this.ea.top)this.Va=window.setInterval(ka(this.yb,this),ye)}G(xe,nd);var ye=500;v=xe.prototype;v.Ia=k;v.ea=k;v.ca=k;v.Va=k;v.q=function(){xe.p.q.call(this);this.Ia&&(N(this.Ia),this.Ia=k);this.Va&&(window.clearInterval(this.Va),this.Va=k);this.ca=this.ea=k};v.Kc=function(){this.yb()};
v.yb=function(){var a=Fc(this.ea||window);if(!(a==this.ca||(!a||!this.ca?0:a.width==this.ca.width&&a.height==this.ca.height)))this.ca=a,O(this,"resize")};function ze(a,b,c,d,e){if(!J&&(!K||!ub("525")))return i;if(ab&&e)return Ae(a);if(e&&!d||!c&&(17==b||18==b)||J&&d&&b==a)return n;switch(a){case 13:return!(J&&wb(9));case 27:return!K}return Ae(a)}function Ae(a){if(48<=a&&57>=a||96<=a&&106>=a||65<=a&&90>=a||K&&0==a)return i;switch(a){case 32:case 63:case 107:case 109:case 110:case 111:case 186:case 59:case 189:case 187:case 61:case 188:case 190:case 191:case 192:case 222:case 219:case 220:case 221:return i;default:return n}}
function Be(a){switch(a){case 61:return 187;case 59:return 186;case 224:return 91;case 0:return 224;default:return a}};function Ce(a,b){L.call(this);a&&(this.Fa&&De(this),this.oa=a,this.Ea=M(this.oa,"keypress",this,b),this.nb=M(this.oa,"keydown",this.a,b,this),this.Fa=M(this.oa,"keyup",this.b,b,this))}G(Ce,nd);v=Ce.prototype;v.oa=k;v.Ea=k;v.nb=k;v.Fa=k;v.S=-1;v.R=-1;v.Wa=n;
var Ee={3:13,12:144,63232:38,63233:40,63234:37,63235:39,63236:112,63237:113,63238:114,63239:115,63240:116,63241:117,63242:118,63243:119,63244:120,63245:121,63246:122,63247:123,63248:44,63272:46,63273:36,63275:35,63276:33,63277:34,63289:144,63302:45},Fe={Up:38,Down:40,Left:37,Right:39,Enter:13,F1:112,F2:113,F3:114,F4:115,F5:116,F6:117,F7:118,F8:119,F9:120,F10:121,F11:122,F12:123,"U+007F":46,Home:36,End:35,PageUp:33,PageDown:34,Insert:45},Ge=J||K&&ub("525"),He=ab&&ib;
Ce.prototype.a=function(a){if(K&&(17==this.S&&!a.za||18==this.S&&!a.M))this.R=this.S=-1;Ge&&!ze(a.ga,this.S,a.Z,a.za,a.M)?this.handleEvent(a):(this.R=ib?Be(a.ga):a.ga,He&&(this.Wa=a.M))};Ce.prototype.b=function(a){this.R=this.S=-1;this.Wa=a.M};
Ce.prototype.handleEvent=function(a){var b=a.C,c,d,e=b.altKey;J&&"keypress"==a.type?(c=this.R,d=13!=c&&27!=c?b.keyCode:0):K&&"keypress"==a.type?(c=this.R,d=0<=b.charCode&&63232>b.charCode&&Ae(c)?b.charCode:0):hb?(c=this.R,d=Ae(c)?b.keyCode:0):(c=b.keyCode||this.R,d=b.charCode||0,He&&(e=this.Wa),ab&&(63==d&&224==c)&&(c=191));var f=c,g=b.keyIdentifier;c?63232<=c&&c in Ee?f=Ee[c]:25==c&&a.Z&&(f=9):g&&g in Fe&&(f=Fe[g]);a=f==this.S;this.S=f;b=new Ie(f,d,a,b);b.M=e;O(this,b)};
function De(a){a.Ea&&(N(a.Ea),N(a.nb),N(a.Fa),a.Ea=k,a.nb=k,a.Fa=k);a.oa=k;a.S=-1;a.R=-1}Ce.prototype.q=function(){Ce.p.q.call(this);De(this)};function Ie(a,b,c,d){d&&ec(this,d,h);this.type="key";this.ga=a;this.ya=b;this.a=c}G(Ie,dc);function Je(a,b,c,d){this.top=a;this.right=b;this.bottom=c;this.left=d}Je.prototype.H=function(){return new Je(this.top,this.right,this.bottom,this.left)};Je.prototype.contains=function(a){return!this||!a?n:a instanceof Je?a.left>=this.left&&a.right<=this.right&&a.top>=this.top&&a.bottom<=this.bottom:a.x>=this.left&&a.x<=this.right&&a.y>=this.top&&a.y<=this.bottom};function Ke(a,b,c){D(b)?Le(a,c,b):Na(b,la(Le,a))}function Le(a,b,c){a.style[String(c).replace(/\-([a-z])/g,function(a,b){return b.toUpperCase()})]=b}function Me(a,b){var c=Cc(a);return c.defaultView&&c.defaultView.getComputedStyle&&(c=c.defaultView.getComputedStyle(a,k))?c[b]||c.getPropertyValue(b)||"":""}function Ne(a,b){return a.currentStyle?a.currentStyle[b]:k}function Oe(a,b){return Me(a,b)||Ne(a,b)||a.style&&a.style[b]}
function Pe(a,b){var c,d,e=ib&&(ab||lb)&&ub("1.9");b instanceof yc?(c=b.x,d=b.y):(c=b,d=h);a.style.left=Qe(c,e);a.style.top=Qe(d,e)}function Re(a){var b=a.getBoundingClientRect();J&&(a=a.ownerDocument,b.left-=a.documentElement.clientLeft+a.body.clientLeft,b.top-=a.documentElement.clientTop+a.body.clientTop);return b}
function Se(a){if(J&&!wb(8))return a.offsetParent;for(var b=Cc(a),c=Oe(a,"position"),d="fixed"==c||"absolute"==c,a=a.parentNode;a&&a!=b;a=a.parentNode)if(c=Oe(a,"position"),d=d&&"static"==c&&a!=b.documentElement&&a!=b.body,!d&&(a.scrollWidth>a.clientWidth||a.scrollHeight>a.clientHeight||"fixed"==c||"absolute"==c||"relative"==c))return a;return k}function Te(a,b){var c=Ue(a),d=Ue(b);return new yc(c.x-d.x,c.y-d.y)}
function Ue(a){var b=new yc;if(1==a.nodeType){if(a.getBoundingClientRect){var c=Re(a);b.x=c.left;b.y=c.top}else{c=Lc(Ac(a));var d,e=Cc(a),f=Oe(a,"position"),g=ib&&e.getBoxObjectFor&&!a.getBoundingClientRect&&"absolute"==f&&(d=e.getBoxObjectFor(a))&&(0>d.screenX||0>d.screenY),j=new yc(0,0),s;d=e?Cc(e):document;if(s=J)if(s=!wb(9))Ac(d),s=n;s=s?d.body:d.documentElement;if(a!=s)if(a.getBoundingClientRect)d=Re(a),e=Lc(Ac(e)),j.x=d.left+e.x,j.y=d.top+e.y;else if(e.getBoxObjectFor&&!g)d=e.getBoxObjectFor(a),
e=e.getBoxObjectFor(s),j.x=d.screenX-e.screenX,j.y=d.screenY-e.screenY;else{g=a;do{j.x+=g.offsetLeft;j.y+=g.offsetTop;g!=a&&(j.x+=g.clientLeft||0,j.y+=g.clientTop||0);if(K&&"fixed"==Oe(g,"position")){j.x+=e.body.scrollLeft;j.y+=e.body.scrollTop;break}g=g.offsetParent}while(g&&g!=a);if(hb||K&&"absolute"==f)j.y-=e.body.offsetTop;for(g=a;(g=Se(g))&&g!=e.body&&g!=s;)if(j.x-=g.scrollLeft,!hb||"TR"!=g.tagName)j.y-=g.scrollTop}b.x=j.x-c.x;b.y=j.y-c.y}if(ib&&!ub(12)){var q;J?q="-ms-transform":K?q="-webkit-transform":
hb?q="-o-transform":ib&&(q="-moz-transform");var l;q&&(l=Oe(a,q));l||(l=Oe(a,"transform"));l?(a=l.match(Ve),a=!a?new yc(0,0):new yc(parseFloat(a[1]),parseFloat(a[2]))):a=new yc(0,0);b=new yc(b.x+a.x,b.y+a.y)}}else q=ea(a.tc),l=a,a.targetTouches?l=a.targetTouches[0]:q&&a.C.targetTouches&&(l=a.C.targetTouches[0]),b.x=l.clientX,b.y=l.clientY;return b}function Qe(a,b){"number"==typeof a&&(a=(b?Math.round(a):a)+"px");return a}function We(a,b){a.style.display=b?"":"none"}
function Xe(a,b){Ac(Cc(a));if(J&&!ub("8")){var c=a.style,d;if(J){d=Ye(a,Ne(a,"paddingLeft"));var e=Ye(a,Ne(a,"paddingRight")),f=Ye(a,Ne(a,"paddingTop")),g=Ye(a,Ne(a,"paddingBottom"));d=new Je(f,e,g,d)}else d=Me(a,"paddingLeft"),e=Me(a,"paddingRight"),f=Me(a,"paddingTop"),g=Me(a,"paddingBottom"),d=new Je(parseFloat(f),parseFloat(e),parseFloat(g),parseFloat(d));if(J)var e=Ze(a,"borderLeft"),f=Ze(a,"borderRight"),g=Ze(a,"borderTop"),j=Ze(a,"borderBottom"),e=new Je(g,f,j,e);else e=Me(a,"borderLeftWidth"),
f=Me(a,"borderRightWidth"),g=Me(a,"borderTopWidth"),j=Me(a,"borderBottomWidth"),e=new Je(parseFloat(g),parseFloat(f),parseFloat(j),parseFloat(e));c.pixelWidth=b.width-e.left-d.left-d.right-e.right;c.pixelHeight=b.height-e.top-d.top-d.bottom-e.bottom}else c=a.style,ib?c.MozBoxSizing="border-box":K?c.WebkitBoxSizing="border-box":c.boxSizing="border-box",c.width=Math.max(b.width,0)+"px",c.height=Math.max(b.height,0)+"px"}
function Ye(a,b){if(/^\d+px?$/.test(b))return parseInt(b,10);var c=a.style.left,d=a.runtimeStyle.left;a.runtimeStyle.left=a.currentStyle.left;a.style.left=b;var e=a.style.pixelLeft;a.style.left=c;a.runtimeStyle.left=d;return e}var $e={thin:2,medium:4,thick:6};function Ze(a,b){if("none"==Ne(a,b+"Style"))return 0;var c=Ne(a,b+"Width");return c in $e?$e[c]:Ye(a,c)}var Ve=/matrix\([0-9\.\-]+, [0-9\.\-]+, [0-9\.\-]+, [0-9\.\-]+, ([0-9\.\-]+)p?x?, ([0-9\.\-]+)p?x?\)/;function af(a){L.call(this);this.a=a;a=fa(this.a)&&1==this.a.nodeType?this.a:this.a?this.a.body:k;this.e=!!a&&"rtl"==Oe(a,"direction");this.b=M(this.a,ib?"DOMMouseScroll":"mousewheel",this)}G(af,nd);
af.prototype.handleEvent=function(a){var b=0,c=0,d=0,a=a.C;if("mousewheel"==a.type){c=1;if(J||K&&(bb||ub("532.0")))c=40;d=bf(-a.wheelDelta,c);z(a.wheelDeltaX)?(b=bf(-a.wheelDeltaX,c),c=bf(-a.wheelDeltaY,c)):c=d}else d=a.detail,100<d?d=3:-100>d&&(d=-3),z(a.axis)&&a.axis===a.HORIZONTAL_AXIS?b=d:c=d;"number"==typeof this.c&&(b=wc(b,-this.c,this.c));"number"==typeof this.d&&(c=wc(c,-this.d,this.d));this.e&&(b=-b);b=new cf(d,a,b,c);O(this,b)};function bf(a,b){return K&&(ab||cb)&&0!=a%b?a:a/b}
af.prototype.q=function(){af.p.q.call(this);N(this.b);delete this.b};function cf(a,b,c,d){b&&ec(this,b,h);this.type="mousewheel";this.e=a;this.c=c;this.a=d}G(cf,dc);var df=document&&"ontouchstart"in document.documentElement;function ef(){this.d=wc(255,0,255);this.c=wc(255,0,255);this.b=wc(255,0,255);this.a=wc(1,0,1)};function ff(a){this.length=a.length||a;for(var b=0;b<this.length;b++)this[b]=a[b]||0}ff.prototype.a=4;ff.prototype.set=function(a,b){for(var b=b||0,c=0;c<a.length&&b+c<this.length;c++)this[b+c]=a[c]};ff.prototype.toString=Array.prototype.join;"undefined"==typeof Float32Array&&(ff.BYTES_PER_ELEMENT=4,ff.prototype.BYTES_PER_ELEMENT=ff.prototype.a,ff.prototype.set=ff.prototype.set,ff.prototype.toString=ff.prototype.toString,F("Float32Array",ff));function gf(a){this.length=a.length||a;for(var b=0;b<this.length;b++)this[b]=a[b]||0}gf.prototype.a=8;gf.prototype.set=function(a,b){for(var b=b||0,c=0;c<a.length&&b+c<this.length;c++)this[b+c]=a[c]};gf.prototype.toString=Array.prototype.join;"undefined"==typeof Float64Array&&(gf.BYTES_PER_ELEMENT=8,gf.prototype.BYTES_PER_ELEMENT=gf.prototype.a,gf.prototype.set=gf.prototype.set,gf.prototype.toString=gf.prototype.toString,F("Float64Array",gf));function hf(){var a=Array(16);jf(a,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0);return a}function jf(a,b,c,d,e,f,g,j,s,q,l,m,u,w,r,t,B){a[0]=b;a[1]=c;a[2]=d;a[3]=e;a[4]=f;a[5]=g;a[6]=j;a[7]=s;a[8]=q;a[9]=l;a[10]=m;a[11]=u;a[12]=w;a[13]=r;a[14]=t;a[15]=B}function kf(a){a[0]=1;a[1]=0;a[2]=0;a[3]=0;a[4]=0;a[5]=1;a[6]=0;a[7]=0;a[8]=0;a[9]=0;a[10]=1;a[11]=0;a[12]=0;a[13]=0;a[14]=0;a[15]=1}
function lf(a,b,c){var d=a[0],e=a[1],f=a[2],g=a[3],j=a[4],s=a[5],q=a[6],l=a[7],m=a[8],u=a[9],w=a[10],r=a[11],t=a[12],B=a[13],C=a[14],a=a[15],A=b[0],P=b[1],Y=b[2],T=b[3],va=b[4],wa=b[5],xa=b[6],ya=b[7],za=b[8],Aa=b[9],Ba=b[10],Q=b[11],Xc=b[12],Yc=b[13],Zc=b[14],b=b[15];c[0]=d*A+j*P+m*Y+t*T;c[1]=e*A+s*P+u*Y+B*T;c[2]=f*A+q*P+w*Y+C*T;c[3]=g*A+l*P+r*Y+a*T;c[4]=d*va+j*wa+m*xa+t*ya;c[5]=e*va+s*wa+u*xa+B*ya;c[6]=f*va+q*wa+w*xa+C*ya;c[7]=g*va+l*wa+r*xa+a*ya;c[8]=d*za+j*Aa+m*Ba+t*Q;c[9]=e*za+s*Aa+u*Ba+B*Q;
c[10]=f*za+q*Aa+w*Ba+C*Q;c[11]=g*za+l*Aa+r*Ba+a*Q;c[12]=d*Xc+j*Yc+m*Zc+t*b;c[13]=e*Xc+s*Yc+u*Zc+B*b;c[14]=f*Xc+q*Yc+w*Zc+C*b;c[15]=g*Xc+l*Yc+r*Zc+a*b}function mf(a,b,c){var d=b[0],e=b[1],b=b[2];c[0]=d*a[0]+e*a[4]+b*a[8]+a[12];c[1]=d*a[1]+e*a[5]+b*a[9]+a[13];c[2]=d*a[2]+e*a[6]+b*a[10]+a[14]}function nf(a,b,c){var d=a[1]*b+a[5]*c+0*a[9]+a[13],e=a[2]*b+a[6]*c+0*a[10]+a[14],f=a[3]*b+a[7]*c+0*a[11]+a[15];a[12]=a[0]*b+a[4]*c+0*a[8]+a[12];a[13]=d;a[14]=e;a[15]=f}
function of(a,b,c){jf(a,a[0]*b,a[1]*b,a[2]*b,a[3]*b,a[4]*c,a[5]*c,a[6]*c,a[7]*c,1*a[8],1*a[9],1*a[10],1*a[11],a[12],a[13],a[14],a[15])}function pf(a,b){var c=a[0],d=a[1],e=a[2],f=a[3],g=a[4],j=a[5],s=a[6],q=a[7],l=Math.cos(b),m=Math.sin(b);a[0]=c*l+g*m;a[1]=d*l+j*m;a[2]=e*l+s*m;a[3]=f*l+q*m;a[4]=c*-m+g*l;a[5]=d*-m+j*l;a[6]=e*-m+s*l;a[7]=f*-m+q*l}new Float64Array(3);new Float64Array(3);new Float64Array(4);new Float64Array(4);new Float64Array(4);new Float64Array(16);function qf(a,b){this.b=a;this.a=b}qf.prototype.getKey=p("b");qf.prototype.H=function(){return new qf(this.b,this.a)};function rf(a){this.a=[];if(a)a:{var b,c;if(a instanceof rf){if(b=a.P(),c=a.I(),0>=a.Za()){for(var a=this.a,d=0;d<b.length;d++)a.push(new qf(b[d],c[d]));break a}}else b=Pa(a),c=Oa(a);for(d=0;d<b.length;d++)sf(this,b[d],c[d])}}function sf(a,b,c){var d=a.a;d.push(new qf(b,c));b=d.length-1;a=a.a;for(c=a[b];0<b;)if(d=b-1>>1,a[d].getKey()>c.getKey())a[b]=a[d],b=d;else break;a[b]=c}v=rf.prototype;
v.remove=function(){var a=this.a,b=a.length,c=a[0];if(!(0>=b)){if(1==b)Ga(a);else{a[0]=a.pop();for(var a=0,b=this.a,d=b.length,e=b[a];a<d>>1;){var f=2*a+1,g=2*a+2,f=g<d&&b[g].getKey()<b[f].getKey()?g:f;if(b[f].getKey()>e.getKey())break;b[a]=b[f];a=f}b[a]=e}return c.a}};v.I=function(){for(var a=this.a,b=[],c=a.length,d=0;d<c;d++)b.push(a[d].a);return b};v.P=function(){for(var a=this.a,b=[],c=a.length,d=0;d<c;d++)b.push(a[d].getKey());return b};v.H=function(){return new rf(this)};v.Za=function(){return this.a.length};
v.$=function(){return 0==this.a.length};v.clear=function(){Ga(this.a)};function tf(){rf.call(this)}G(tf,rf);function uf(a){this.g=a;this.f=8;this.d=0;this.a=new tf;this.c={}}uf.prototype.b=function(a,b,c){if(0==a.a){var d=a.getKey();if(!(d in this.c)){var e=this.g(a,b,c);z(e)&&(sf(this.a,e,arguments),this.c[d]=i)}}};uf.prototype.e=function(){--this.d};function X(a){V.call(this);this.g=a.source;this.n(z(a.brightness)?a.brightness:0);this.o(z(a.contrast)?a.contrast:1);this.r(z(a.hue)?a.hue:0);this.w(z(a.opacity)?a.opacity:1);this.A(z(a.saturation)?a.saturation:1);this.D(z(a.visible)?a.visible:i);this.g.a()||oc(this.g,"load",this.J,n,this)}G(X,V);X.prototype.b=function(){return this.u("brightness")};X.prototype.getBrightness=X.prototype.b;X.prototype.c=function(){return this.u("contrast")};X.prototype.getContrast=X.prototype.c;X.prototype.d=function(){return this.u("hue")};
X.prototype.getHue=X.prototype.d;X.prototype.e=function(){return this.u("opacity")};X.prototype.getOpacity=X.prototype.e;X.prototype.f=function(){return this.u("saturation")};X.prototype.getSaturation=X.prototype.f;X.prototype.X=p("g");X.prototype.a=function(){return this.u("visible")};X.prototype.getVisible=X.prototype.a;X.prototype.J=function(){O(this,"load")};X.prototype.n=function(a){a=wc(a,-1,1);a!=this.b()&&this.set("brightness",a)};X.prototype.setBrightness=X.prototype.n;
X.prototype.o=function(a){a=Math.max(0,a);a!=this.c()&&this.set("contrast",a)};X.prototype.setContrast=X.prototype.o;X.prototype.r=function(a){a!=this.d()&&this.set("hue",a)};X.prototype.setHue=X.prototype.r;X.prototype.w=function(a){a=wc(a,0,1);a!=this.e()&&this.set("opacity",a)};X.prototype.setOpacity=X.prototype.w;X.prototype.A=function(a){a=Math.max(0,a);a!=this.f()&&this.set("saturation",a)};X.prototype.setSaturation=X.prototype.A;
X.prototype.D=function(a){a=!!a;a!=this.a()&&this.set("visible",a)};X.prototype.setVisible=X.prototype.D;function vf(a,b,c){ac.call(this,a);this.map=b;this.Aa=n;this.f=z(c)?c:k}G(vf,ac);vf.prototype.v=function(){vf.p.v.call(this);this.Aa=i};function wf(a,b){yc.call(this,a,b)}G(wf,yc);function xf(a,b,c){vf.call(this,a,b);this.a=c;this.e=this.d=k}G(xf,vf);xf.prototype.c=function(){this.d===k&&(this.d=yf(this.map,zf(this)));return this.d};function zf(a){if(a.e===k){var b=Te(a.a,a.map.b);a.e=new wf(b.x,b.y)}return a.e}function Af(a){this.a=a;this.d=k;this.c=n;this.f=0;this.e=this.b=k;a=this.a.b;df||M(a,["click","dblclick"],this.Xa,n,this);M(a,df?"touchstart":"mousedown",this.Gb,n,this)}G(Af,nd);
function Bf(a){if(df){var b=a.C;b.touches&&b.touches.length&&(b=b.touches[0],a.clientX=b.clientX,a.clientY=b.clientY)}}v=Af.prototype;v.Xa=function(a){if(!this.c){var b;"dblclick"!==a.type&&(b=new xf(Cf,this.a,a),O(this,b));this.f||(b=new xf(Df,this.a,a),O(this,b))}};v.Hb=function(a){if(this.d){if(!this.c){var b=(new Date).getTime();this.f=!this.f||250<b-this.f?b:0;df&&this.Xa(this.e)}this.e=k;I(this.b,N);this.d=this.b=k;this.c&&O(this,new xf(Ef,this.a,a))}};
v.Gb=function(a){this.d||(Bf(a),this.e=a,this.d={clientX:a.clientX,clientY:a.clientY},this.c=n,this.b=[M(document,df?"touchmove":"mousemove",this.pc,n,this),M(document,df?"touchend":"mouseup",this.Hb,n,this)],"mousedown"===a.type&&a.v())};v.pc=function(a){var b;this.c||(this.c=i,b=new xf(Ff,this.a,this.e),O(this,b));Bf(a);this.d={clientX:a.clientX,clientY:a.clientY};a.v();b=new xf(Gf,this.a,a);O(this,b)};
v.q=function(){var a=this.a.b;pc(a,df?"touchstart":"mousedown",this.Gb,n,this);pc(a,df?"touchend":"mouseup",this.Hb,n,this);pc(a,"click",this.Xa,n,this);this.b!==k&&(I(this.b,N),this.b=k);Af.p.q.call(this)};var Cf="click",Df="dblclick",Ff="dragstart",Gf="drag",Ef="dragend";function Hf(a,b){if(z(a))return a+b};function If(){this.a=[0,0]}G(If,V);function Jf(a){this.resolution=a;this.rotation=Hf};function Z(a){this.a=[0,0];var a=a||{},b={};b.center=z(a.center)?a.center:k;b.projection=zd(a.projection);if(z(a.resolution))b.resolution=a.resolution;else if(z(a.a)){var c=b.projection.K(),c=Math.max(c.j-c.h,c.m-c.i);b.resolution=c/(256<<a.a)}b.rotation=a.rotation;this.Ka(b);if(z(a.resolutions))var d=a.resolutions,a=function(a,b){if(z(a)){var c=Nd(d,a),c=wc(c+b,0,d.length-1);return d[c]}};else{z(a.maxResolution)&&z(a.numZoomLevels)&&z(a.zoomFactor)?(b=a.maxResolution,c=a.numZoomLevels,a=a.zoomFactor):
(a=zd(a.projection).K(),b=Math.max(a.j-a.h,a.m-a.i)/256,c=116,a=Math.exp(Math.log(2)/4));var e=a,f=b,g=c-1,a=function(a,b){if(z(a)){var c=Math.floor(Math.log(f/a)/Math.log(e)+0.5),c=Math.max(c+b,0);z(g)&&(c=Math.min(c,g));return f/Math.pow(e,c)}}}this.d=new Jf(a)}G(Z,If);Z.prototype.aa=function(){return this.u("center")};Z.prototype.getCenter=Z.prototype.aa;Z.prototype.K=function(a){var b=this.aa(),c=this.T();return new kd(b.x-c*a.width/2,b.y-c*a.height/2,b.x+c*a.width/2,b.y+c*a.height/2)};
Z.prototype.Rb=function(){return this.u("projection")};Z.prototype.getProjection=Z.prototype.Rb;Z.prototype.T=function(){return this.u("resolution")};Z.prototype.getResolution=Z.prototype.T;Z.prototype.xa=function(){return this.u("rotation")||0};Z.prototype.getRotation=Z.prototype.xa;Z.prototype.Da=function(){return this.aa()!=k&&z(this.T())};Z.prototype.b=function(a){this.set("center",a)};Z.prototype.setCenter=Z.prototype.b;Z.prototype.f=function(a){this.set("projection",a)};
Z.prototype.setProjection=Z.prototype.f;Z.prototype.c=function(a){this.set("resolution",a)};Z.prototype.setResolution=Z.prototype.c;Z.prototype.e=function(a){this.set("rotation",a)};Z.prototype.setRotation=Z.prototype.e;Z.prototype.rotate=function(a,b,c){b=this.d.rotation(b,c);this.e(b)};function Kf(a,b,c,d){var e=a.d.resolution(a.T(),c);if(e!=k&&d!=k){var c=a.aa(),f=a.T(),g=new R(d.x-e*(d.x-c.x)/f,d.y-e*(d.y-c.y)/f);Lf(b,function(){this.b(g);this.c(e)},a)}else a.c(e)};function Mf(a){L.call(this);this.element=z(a.element)?a.element:k;this.n=a.target;this.b=k;z(a.map)&&this.a(a.map)}G(Mf,L);Mf.prototype.q=function(){Kc(this.element);Mf.p.q.call(this)};Mf.prototype.a=function(a){this.b===k||Kc(this.element);this.b=a;this.b!==k&&(z(this.n)?this.n:a.o).appendChild(this.element)};function Nf(a){this.g=document.createElement("UL");var b=Gc("DIV",{"class":"ol-attribution"},this.g);Mf.call(this,{element:b,map:a.map,target:a.target});this.f=i;this.c={};this.d={};this.e=k}G(Nf,Mf);Nf.prototype.o=function(a){a=a.f;a===k?Of(this,k):Of(this,a.Sa)};Nf.prototype.a=function(a){this.e!==k&&(I(this.e,N),this.e=k);Nf.p.a.call(this,a);a!==k&&(this.e=[M(a,"postrender",this.o,n,this)])};
function Of(a,b){if(b===k)a.f&&(We(a.element,n),a.f=n);else{var c={},d={},e=a.b.u(Pf);z(e)&&e.forEach(function(a){a=a.X();a instanceof de&&(d[E(a).toString()]=a);a=a.ta;if(a!==k){var b,e;for(e=0;e<a.length;++e)b=a[e],r=E(b).toString(),c[r]=i}});var e={},f,g,j,s,q,l;for(l in b)if(f=d[l],q=f.ta,q!==k){g=b[l];for(f=0;f<q.length;++f)if(j=q[f],s=E(j).toString(),!(s in e)){var m;a:if(j.a===k)m=i;else{var u=m=h,w=h;for(w in g)if(w in j.a){u=g[w];for(m=0;m<j.a[w].length;++m)if(hd(j.a[w][m],u)){m=i;break a}}m=
n}m&&(e[s]=j)}}l=Ea(Pa(e),Number);La(l);var r;for(f=0;f<l.length;++f)r=l[f].toString(),r in a.c?a.d[r]||(We(a.c[r],i),a.d[r]=i):(g=document.createElement("LI"),g.innerHTML=e[r].b,a.g.appendChild(g),a.c[r]=g,a.d[r]=i),delete c[r];for(r in c)Kc(a.c[r]),delete a.c[r],delete a.d[r];e=0!=l.length;a.f!=e&&(We(a.element,e),a.f=e)}};function Qf(a){var b=df?"touchend":"click",c=Gc("A",{href:"#zoomIn","class":"ol-zoom-in"},"+");M(c,b,this.d,n,this);var d=Gc("A",{href:"#zoomOut","class":"ol-zoom-out"},"\u2212");M(d,b,this.e,n,this);b=Gc("DIV","ol-zoom ol-unselectable",c,d);Mf.call(this,{element:b,map:a.map,target:a.target});this.c=z(a.delta)?a.delta:1}G(Qf,Mf);Qf.prototype.d=function(a){a.v();a=this.b;Kf(a.a(),a,this.c)};Qf.prototype.e=function(a){a.v();a=this.b;Kf(a.a(),a,-this.c)};function Rf(){};function Sf(a){this.a=a}G(Sf,Rf);Sf.prototype.b=function(a){var b=a.a;if(a.type==Df&&(df||gc(a.a))){var c=a.map,d=a.c(),e=a.a.Z?-this.a:this.a;Kf(c.a(),c,e,d);a.v();b.v()}};function Tf(a){return a.M&&!a.Ma&&!a.Z}function Uf(a){return!a.M&&!a.Ma&&!a.Z}function Vf(a){return!a.M&&!a.Ma&&a.Z};function Wf(){this.f=n;this.D=this.A=this.r=this.o=0;this.sa=this.Q=k}G(Wf,Rf);Wf.prototype.g=y;Wf.prototype.n=y;Wf.prototype.d=$d;Wf.prototype.b=function(a){var b=a.map;if(b.Da()){var b=b.a(),c=a.a;this.f?a.type==Gf?(this.c=c.clientX-this.o,this.a=c.clientY-this.r,this.g(a)):a.type==Ef&&(this.c=c.clientX-this.o,this.a=c.clientY-this.r,this.n(a),this.f=n):a.type==Ff&&(this.o=c.clientX,this.r=c.clientY,this.a=this.c=0,this.Q=b.aa(),this.sa=a.c(),this.d(a)&&(this.f=i,a.v()))}};function Xf(a){Wf.call(this);this.e=a}G(Xf,Wf);Xf.prototype.g=function(a){var a=a.map,b=a.a(),c=b.T(),d=b.xa(),c=new R(-c*this.c,c*this.a);c.rotate(d);d=new R(this.Q.x+c.x,this.Q.y+c.y);Yf(a);b.b(d)};Xf.prototype.n=function(a){a=a.map;Yf(a);a=a.a();a.a[1]+=-1};Xf.prototype.d=function(a){return this.e(a.a)?(a=a.map,Yf(a),a=a.a(),a.a[1]+=1,i):n};function Zf(a){Wf.call(this);this.w=a;this.e=0}G(Zf,Wf);Zf.prototype.g=function(a){var b=a.map,c=b.e(),a=zf(a),c=Math.atan2(c.height/2-a.y,a.x-c.width/2),a=b.a();Yf(b);a.rotate(b,this.e,-c)};Zf.prototype.d=function(a){var b=a.a,c=a.map,d=c.a();return gc(b)&&this.w(b)?(Yf(c),b=c.e(),a=zf(a),a=Math.atan2(b.height/2-a.y,a.x-b.width/2),this.e=(d.xa()||0)+a,i):n};function $f(a){var b=Gc("DIV","ol-dragbox");this.c=k;this.e=a.sa;this.d=k;Mf.call(this,{element:b,map:a.map})}G($f,Mf);$f.prototype.a=function(a){this.d!==k&&(N(this.d),this.d=k);a!==k&&(this.c=ag(a,this.e),Pe(this.element,this.c),Xe(this.element,new fd(0,0)),this.d=M(a,Gf,this.f,n,this));$f.p.a.call(this,a)};$f.prototype.f=function(a){var b=this.b,a=a.c(),b=ag(b,a);Pe(this.element,new wf(Math.min(b.x,this.c.x),Math.min(b.y,this.c.y)));Xe(this.element,new fd(Math.abs(b.x-this.c.x),Math.abs(b.y-this.c.y)))};function bg(a){Wf.call(this);this.w=a;this.e=k}G(bg,Wf);bg.prototype.n=function(a){this.e.a(k);this.e=k;if(64<=this.c*this.c+this.a*this.a){var b=a.map,c=ld(this.sa,a.c());Lf(b,function(){var a=b.a(),e=b.e();a.b(new R((c.h+c.j)/2,(c.i+c.m)/2));e=Math.max((c.j-c.h)/e.width,(c.m-c.i)/e.height);e=a.d.resolution(e,0);a.c(e);a.e(0)})}};bg.prototype.d=function(a){var b=a.a;return gc(b)&&this.w(b)?(this.e=new $f({map:a.map,sa:this.sa}),i):n};function cg(a){this.a=a}G(cg,Rf);cg.prototype.b=function(a){if("key"==a.type){var b=a.a,c=b.ga;if(40==c||37==c||39==c||38==c){var d=a.map.a(),e=d.T()*this.a,c=40==c?new R(0,-e):37==c?new R(-e,0):39==c?new R(e,0):new R(0,e),e=d.aa();d.b(new R(e.x+c.x,e.y+c.y));b.v();a.v()}}};function dg(){}G(dg,Rf);dg.prototype.b=function(a){if("key"==a.type){var b=a.a,c=b.ya;if(43==c||45==c){var d=a.map;Kf(d.a(),d,43==c?4:-4);b.v();a.v()}}};function eg(a){this.a=a}G(eg,Rf);eg.prototype.b=function(a){if("mousewheel"==a.type){var b=a.map,c=a.a,d=a.c(),e=0>c.a?this.a:-this.a,f=b.a();Yf(b);Kf(f,b,e,d);a.v();c.v()}};function fg(a,b){V.call(this);this.o=a;this.a=b;M(this.a,oe("brightness"),this.bb,n,this);M(this.a,oe("contrast"),this.cb,n,this);M(this.a,oe("hue"),this.eb,n,this);M(this.a,"load",this.fb,n,this);M(this.a,oe("opacity"),this.gb,n,this);M(this.a,oe("saturation"),this.hb,n,this);M(this.a,oe("visible"),this.ib,n,this)}G(fg,V);v=fg.prototype;v.na=p("o");v.bb=y;v.cb=y;v.eb=y;v.fb=y;v.gb=y;v.hb=y;v.ib=y;
function gg(a,b,c,d){var b=E(b).toString(),e=c.toString();b in a?c in a[b]?(a=a[b][e],a.h=Math.min(a.h,d.h),a.i=Math.min(a.i,d.i),a.j=Math.max(a.j,d.j),a.m=Math.max(a.m,d.m)):a[b][e]=d:(a[b]={},a[b][e]=d)};function hg(a,b){L.call(this);this.ia=a;this.map=b;this.c={};this.f=this.d=k;this.D=[M(b,oe(ig),this.ab,n,this),M(b,oe(Pf),this.Hc,n,this),M(b,oe(jg),this.jb,n,this),M(b,oe(kg),this.kb,n,this)]}G(hg,L);v=hg.prototype;v.fa=function(a){var b=this.ua(a);this.sb(a,b)};
function lg(a){var b=a.z,c=a.Bb;kf(c);nf(c,a.size.width/2,a.size.height/2);of(c,1/b.resolution,-1/b.resolution);pf(c,-b.rotation);nf(c,-b.center.x,-b.center.y);var a=a.Ub,b=c[0],d=c[1],e=c[2],f=c[3],g=c[4],j=c[5],s=c[6],q=c[7],l=c[8],m=c[9],u=c[10],w=c[11],r=c[12],t=c[13],B=c[14],c=c[15],C=b*j-d*g,A=b*s-e*g,P=b*q-f*g,Y=d*s-e*j,T=d*q-f*j,va=e*q-f*s,wa=l*t-m*r,xa=l*B-u*r,ya=l*c-w*r,za=m*B-u*t,Aa=m*c-w*t,Ba=u*c-w*B,Q=C*Ba-A*Aa+P*za+Y*ya-T*xa+va*wa;0!=Q&&(Q=1/Q,a[0]=(j*Ba-s*Aa+q*za)*Q,a[1]=(-d*Ba+e*Aa-
f*za)*Q,a[2]=(t*va-B*T+c*Y)*Q,a[3]=(-m*va+u*T-w*Y)*Q,a[4]=(-g*Ba+s*ya-q*xa)*Q,a[5]=(b*Ba-e*ya+f*xa)*Q,a[6]=(-r*va+B*P-c*A)*Q,a[7]=(l*va-u*P+w*A)*Q,a[8]=(g*Aa-j*ya+q*wa)*Q,a[9]=(-b*Aa+d*ya-f*wa)*Q,a[10]=(r*T-t*P+c*C)*Q,a[11]=(-l*T+m*P-w*C)*Q,a[12]=(-g*za+j*xa-s*wa)*Q,a[13]=(b*za-d*xa+e*wa)*Q,a[14]=(-r*Y+t*A-B*C)*Q,a[15]=(l*Y-m*A+u*C)*Q)}v.ua=be;v.q=function(){Na(this.c,function(a){$b(a)});I(this.D,N);this.f===k||N(this.f);this.d===k||I(this.d,N);hg.p.q.call(this)};
function mg(a,b){var c=E(b);return a.c[c]}v.ab=y;v.Gc=function(a){this.fa(a.a)};v.Hc=function(){Zb(Oa(this.c));this.c={};this.d!==k&&(I(this.d,N),this.d=k);var a=this.map.u(Pf);a!=k&&(a.forEach(this.fa,this),this.d=[M(a,"add",this.Gc,n,this),M(a,"remove",this.Ic,n,this)])};v.Ic=function(a){this.qb(a.a)};v.lb=function(){ng(this.map)};v.jb=function(){ng(this.map)};v.kb=function(){this.f!==k&&(N(this.f),this.f=k);var a=this.map.a();a!=k&&(this.f=M(a,"changed",this.lb,n,this));ng(this.map)};v.qb=function(a){$b(this.rb(a))};
v.rb=function(a){a=E(a);if(a in this.c){var b=this.c[a];delete this.c[a];return b}return k};v.L=y;v.sb=function(a,b){var c=E(a);this.c[c]=b};function og(){if(!("HTMLCanvasElement"in x))return n;try{return document.createElement("CANVAS").getContext("2d")!==k}catch(a){return n}};function pg(a){X.call(this,a)}G(pg,X);function qg(a,b){fg.call(this,a,b)}G(qg,fg);function rg(a,b){fg.call(this,a,b);this.e=this.b=this.c=k;this.N=hf()}G(rg,qg);rg.prototype.W=p("c");
rg.prototype.L=function(a){function b(a,b){var c=i,e,f,g,j;for(g=b.h;g<=b.j;++g)for(j=b.i;j<=b.m;++j){e=new S(a,g,j);f=e.toString();if(u[a]&&u[a][f])return;e=fe(d,e);e!==k&&2==e.a?(u[a]||(u[a]={}),u[a][f]=e):c=n}return c}var c=a.z,d=this.a.X(),e=d.tileGrid,f=e.b,g=Nd(e.a,c.resolution),j=e.a[g],s=Qd(e,a.extent,j),q=new fd(f.width*s.b(),f.height*s.a()),l,m;this.c===k?(l=document.createElement("CANVAS"),l.width=q.width,l.height=q.height,m=l.getContext("2d"),this.c=l,this.b=q,this.e=m):(l=this.c,m=this.e,
this.b.width==q.width&&this.b.height==q.height||(l.width=q.width,l.height=q.height,this.b=q));m.clearRect(0,0,q.width,q.height);var u={};u[g]={};var q=i,w,r,t,B;for(t=s.h;t<=s.j;++t)for(B=s.i;B<=s.m;++B)if(w=new S(g,t,B),l=fe(d,w),l!==k){r=l.a;if(0==r)q=Td(e,w),a.tb.b(l,q,j);else if(2==r){u[g][w.toString()]=l;continue}else if(3==r)continue;q=n;e.c(w,b)}t=Ea(Pa(u),Number);La(t);w=md(Pd(e,new S(g,s.h,s.m)));var C,A,P;for(B=0;B<t.length;++B)if(l=t[B],r=u[l],l==g)for(A in r)l=r[A],m.drawImage(l.W(),f.width*
(l.da.x-s.h),f.height*(s.m-l.da.y));else for(A in C=e.a[l]/j,r)l=r[A],P=Pd(e,l.da),m.drawImage(l.W(),(P.h-w.x)/j,(w.y-P.m)/j,C*f.width,C*f.height);q||(a.G=i);gg(a.Sa,d,g,s);e=this.N;kf(e);nf(e,a.size.width/2,a.size.height/2);pf(e,c.rotation);of(e,j/c.resolution,j/c.resolution);nf(e,(w.x-c.center.x)/j,(c.center.y-w.y)/j)};function sg(a,b){hg.call(this,a,b);this.g=new fd(a.clientHeight,a.clientWidth);this.a=document.createElement("CANVAS");this.a.height=this.g.height;this.a.width=this.g.width;this.a.className="ol-unselectable";Jc(a,this.a);this.n=i;this.o=this.a.getContext("2d")}G(sg,hg);v=sg.prototype;v.ua=function(a){return a instanceof pg?new rg(this,a):k};v.ab=function(){ng(this.map)};v.lb=function(){sg.p.lb.call(this);ng(this.map)};v.jb=function(){sg.p.jb.call(this);ng(this.map)};
v.kb=function(){sg.p.kb.call(this);ng(this.map)};
v.L=function(a){if(a===k)this.n&&(We(this.a,n),this.n=n);else{var b=a.size;this.g.width==b.width&&this.g.height==b.height||(this.a.width=b.width,this.a.height=b.height,this.g=b);var c=this.o;c.setTransform(1,0,0,1,0,0);var d=a.backgroundColor;c.fillStyle="rgb("+d.d.toFixed(0)+","+d.c.toFixed(0)+","+d.b.toFixed(0)+")";c.globalAlpha=d.a;c.fillRect(0,0,b.width,b.height);I(a.Ha,function(b){var d=a.Ga[E(b)];if(d.visible)if(d.Oa){b=mg(this,b);b.L(a,d);var g=b.N;c.setTransform(g[0],g[1],g[4],g[5],g[12],
g[13]);c.globalAlpha=d.opacity;c.drawImage(b.W(),0,0)}else a.G=i},this);this.n||(We(this.a,i),this.n=i);lg(a)}};function tg(a,b,c){fg.call(this,a,b);this.target=c}G(tg,fg);tg.prototype.q=function(){Kc(this.target);tg.p.q.call(this)};tg.prototype.fb=function(){ng(this.o.map)};tg.prototype.gb=function(){ng(this.o.map)};tg.prototype.ib=function(){ng(this.o.map)};function ug(a,b){var c=document.createElement("DIV");c.className="ol-layer";c.style.position="absolute";tg.call(this,a,b,c);this.c=i;this.e=1;this.b={}}G(ug,tg);
ug.prototype.L=function(a,b){if(b.visible){var c=a.z,d=this.a.X(),e=d.tileGrid,f=Nd(e.a,c.resolution),g=e.a[f],j=Qd(e,a.extent,g),s={};s[f]={};var q=function(a,b){var c=i,e,f,g,j;for(g=b.h;g<=b.j;++g)for(j=b.i;j<=b.m;++j){e=new S(a,g,j);f=e.toString();if(s[a]&&s[a][f])return;e=fe(d,e);e!==k&&2==e.a?(s[a]||(s[a]={}),s[a][f]=e):c=n}return c},l=i,m,u,w,r,t;for(r=j.h;r<=j.j;++r)for(t=j.i;t<=j.m;++t)if(u=new S(f,r,t),m=fe(d,u),m!==k){w=m.a;if(0==w)l=Td(e,u),a.tb.b(m,l,g);else if(2==w){s[f][u.toString()]=
m;continue}else if(3==w)continue;l=n;e.c(u,q)}m=Ea(Pa(s),Number);La(m);var g={},B;for(r=0;r<m.length;++r){u=m[r];u in this.b?q=this.b[u]:(q=Sd(e,c.center,e.a[u]),q=new vg(e,q),g[u]=i,this.b[u]=q);u=s[u];for(B in u){t=q;w=u[B];var C=w.da,A=C.toString();if(!(A in t.c)){var P=t.e.b,Y=w.W(t),T=Y.style;T.position="absolute";T.left=(C.x-t.d.x)*P.width+"px";T.top=(t.d.y-C.y)*P.height+"px";t.b===k&&(t.b=document.createDocumentFragment());t.b.appendChild(Y);t.c[A]=w}}q.b!==k&&(q.target.appendChild(q.b),q.b=
k)}e=Ea(Pa(this.b),Number);La(e);m=hf();for(B=0;B<e.length;++B)if(u=e[B],q=this.b[u],u in s){t=q.g;r=q.f;kf(m);nf(m,a.size.width/2,a.size.height/2);pf(m,c.rotation);of(m,t/c.resolution,t/c.resolution);nf(m,(r.x-c.center.x)/t,(c.center.y-r.y)/t);t=q;r=m;if(!(r.length==t.a.length&&r[0]==t.a[0]&&r[1]==t.a[1]&&r[2]==t.a[2]&&r[3]==t.a[3]&&r[4]==t.a[4]&&r[5]==t.a[5]&&r[6]==t.a[6]&&r[7]==t.a[7]&&r[8]==t.a[8]&&r[9]==t.a[9]&&r[10]==t.a[10]&&r[11]==t.a[11]&&r[12]==t.a[12]&&r[13]==t.a[13]&&r[14]==t.a[14]&&r[15]==
t.a[15])){w=t.target;C=r;A=A=h;if(z(6)){P=Array(16);for(A=0;16>A;++A)P[A]=C[A].toFixed(6);A=P.join(",")}else A=C.join(",");C="matrix3d("+A+")";w=w.style;w.WebkitTransform=C;w.MozTransform=C;w.a=C;w.transform=C;t=t.a;t[0]=r[0];t[1]=r[1];t[2]=r[2];t[3]=r[3];t[4]=r[4];t[5]=r[5];t[6]=r[6];t[7]=r[7];t[8]=r[8];t[9]=r[9];t[10]=r[10];t[11]=r[11];t[12]=r[12];t[13]=r[13];t[14]=r[14];t[15]=r[15]}if(u in g){for(u-=1;0<=u;--u)if(u in this.b){r=this.b[u].target;r.parentNode&&r.parentNode.insertBefore(q.target,
r.nextSibling);break}0>u&&Jc(this.target,q.target)}else if(!a.B[0]&&!a.B[1]){w=Qd(q.e,a.extent,q.e.a[q.d.k]);u=[];t=r=h;for(t in q.c)r=q.c[t],w.contains(r.da)||u.push(r);w=h;for(w=0;w<u.length;++w)r=u[w],t=r.da.toString(),Kc(r.W(q)),delete q.c[t]}}else Kc(q.target),delete this.b[u];b.opacity!=this.e&&(c=b.opacity,g=this.target.style,"opacity"in g?g.opacity=c:"MozOpacity"in g?g.MozOpacity=c:"filter"in g&&(g.filter=""===c?"":"alpha(opacity="+100*c+")"),this.e=b.opacity);b.visible&&!this.c&&(We(this.target,
i),this.c=i);l||(a.G=i);gg(a.Sa,d,f,j)}else this.c&&(We(this.target,n),this.c=n)};function vg(a,b){this.target=document.createElement("DIV");this.target.style.position="absolute";this.e=a;this.d=b;this.f=md(Pd(a,b));this.g=a.a[b.k];this.c={};this.b=k;var c=Array(16);jf(c,1,0,0,0,0,1,0,0,0,0,1,0,0,0,0,1);this.a=c};function wg(a,b){hg.call(this,a,b);this.a=document.createElement("DIV");this.a.className="ol-layers-pane ol-unselectable";var c=this.a.style;c.position="absolute";c.width="100%";c.height="100%";Jc(a,this.a);this.g=i}G(wg,hg);wg.prototype.fa=function(a){wg.p.fa.call(this,a);ng(this.map)};wg.prototype.ua=function(a){return a instanceof pg?(a=new ug(this,a),this.a.appendChild(a.target),a):k};
wg.prototype.L=function(a){a===k?this.g&&(We(this.a,n),this.g=n):(I(a.Ha,function(b){var c=a.Ga[E(b)];c.Oa&&mg(this,b).L(a,c)},this),this.g||(We(this.a,i),this.g=i),lg(a))};var xg=["webgl","webgl-experimental","webkit-3d","moz-webgl"];function yg(a,b){var c,d,e=xg.length;for(d=0;d<e;++d)try{if(c=a.getContext(xg[d],b),c!==k)return c}catch(f){}return k};function zg(){if(!("WebGLRenderingContext"in x))return n;try{var a=document.createElement("CANVAS");return yg(a)!==k}catch(b){return n}};function Ag(a){this.a=a}Ag.prototype.X=p("a");function Bg(a){this.a=a}G(Bg,Ag);Bg.prototype.b=function(){return 35632};function Cg(a){this.a=a}G(Cg,Ag);Cg.prototype.b=function(){return 35633};function Dg(a,b){fg.call(this,a,b);this.w=new Float32Array(16);this.D=new Float32Array(16);this.J=new Float32Array(16);this.ia=new Float32Array(16);this.A=new Float32Array(16);this.c=i;this.bb();this.cb();this.eb();this.hb()}G(Dg,fg);function Eg(a){O(a,"change")}function Fg(a){if(a.c){var b=a.A;kf(b);lf(b,a.D,b);lf(b,a.w,b);lf(b,a.ia,b);lf(b,a.J,b);a.c=n}return a.A}v=Dg.prototype;v.na=function(){return Dg.p.na.call(this)};
v.bb=function(){var a=this.a.b(),b=this.w;kf(b);b[12]=a;b[13]=a;b[14]=a;b[15]=1;this.c=i;Eg(this)};v.cb=function(){var a=this.a.c(),b=this.D;kf(b);b[0]=a;b[5]=a;b[10]=a;b[15]=1;a=-0.5*a+0.5;b[12]=a;b[13]=a;b[14]=a;b[15]=1;this.c=i;Eg(this)};
v.eb=function(){var a=this.a.d(),b=Math.cos(a),a=Math.sin(a);jf(this.J,0.213+0.787*b-0.213*a,0.213-0.213*b+0.143*a,0.213-0.213*b-0.787*a,0,0.715-0.715*b-0.715*a,0.715+0.285*b+0.14*a,0.715-0.715*b+0.715*a,0,0.072-0.072*b+0.928*a,0.072-0.072*b-0.283*a,0.072+0.928*b+0.072*a,0,0,0,0,1);this.c=i;Eg(this)};v.fb=function(){Eg(this)};v.gb=function(){Eg(this)};
v.hb=function(){var a=this.a.f();jf(this.ia,0.213+0.787*a,0.213-0.213*a,0.213-0.213*a,0,0.715-0.715*a,0.715+0.285*a,0.715-0.715*a,0,0.072-0.072*a,0.072-0.072*a,0.072+0.928*a,0,0,0,0,1);this.c=i;Eg(this)};v.ib=function(){Eg(this)};v.Ba=y;function Gg(){this.a="precision mediump float;\n\nuniform sampler2D uTexture;\n\nvarying vec2 vTexCoord;\n\nvoid main(void) {\n gl_FragColor = texture2D(uTexture, vTexCoord);\n}"}G(Gg,Bg);aa(Gg);function Hg(){this.a="attribute vec2 aPosition;\nattribute vec2 aTexCoord;\n\nvarying vec2 vTexCoord;\n\nuniform vec4 uTileOffset;\n\nvoid main(void) {\n gl_Position.xy = aPosition * uTileOffset.xy + uTileOffset.zw;\n gl_Position.z = 0.;\n gl_Position.w = 1.;\n vTexCoord = aTexCoord;\n}"}G(Hg,Cg);aa(Hg);
function Ig(a,b){Dg.call(this,a,b);this.Qa=Gg.wa();this.ub=Hg.wa();this.e=this.g=this.f=this.t=k;this.n=h;this.d=hf();this.r=this.b=k}G(Ig,Dg);Ig.prototype.q=function(){var a=this.na().b;a.isContextLost()||(a.deleteBuffer(this.f),a.deleteFramebuffer(this.e),a.deleteTexture(this.g));Ig.p.q.call(this)};Ig.prototype.Ba=function(){this.e=this.g=this.f=this.t=k;this.n=h};
Ig.prototype.L=function(a){var b=this.na(),c=b.b,d=a.z,e=d.center,f=this.a.X(),g=f.tileGrid,j=Nd(g.a,d.resolution),s=g.a[j],q=Qd(g,a.extent,s),l;if(this.b!==k&&this.b.h==q.h&&q.j==this.b.j&&this.b.i==q.i&&q.i==this.b.i)l=this.r;else{var m=new fd(q.b(),q.a()),u=g.b,m=Math.max(m.width*u.width,m.height*u.height),m=Math.pow(2,Math.ceil(Math.log(m)/Math.log(2))),w=new fd(s*m,s*m),r=Rd(g,j),t=r.x+q.h*u.width*s,u=r.y+q.i*u.height*s;l=new kd(t,u,t+w.width,u+w.height);u=this.na().b;!z(this.n)||this.n!=m?(a.pb.push(la(function(a,
b,c){a.isContextLost()||(a.deleteFramebuffer(b),a.deleteTexture(c))},u,this.e,this.g)),t=u.createTexture(),u.bindTexture(3553,t),u.texImage2D(3553,0,6408,m,m,0,6408,5121,k),u.texParameteri(3553,10240,9729),u.texParameteri(3553,10241,9729),r=u.createFramebuffer(),u.bindFramebuffer(36160,r),u.framebufferTexture2D(36160,36064,3553,t,0),this.g=t,this.e=r,this.n=m):u.bindFramebuffer(36160,this.e);c.viewport(0,0,m,m);c.clearColor(0,0,0,0);c.clear(16384);c.disable(3042);m=Jg(b,this.Qa,this.ub);c.useProgram(m);
this.t===k&&(this.t={ka:c.getAttribLocation(m,"aPosition"),la:c.getAttribLocation(m,"aTexCoord"),Xc:c.getUniformLocation(m,"uTileOffset"),vb:c.getUniformLocation(m,"uTexture")});this.f===k?(m=c.createBuffer(),c.bindBuffer(34962,m),c.bufferData(34962,new Float32Array([0,0,0,1,1,0,1,1,0,1,0,0,1,1,1,0]),35044),this.f=m):c.bindBuffer(34962,this.f);c.enableVertexAttribArray(this.t.ka);c.vertexAttribPointer(this.t.ka,2,5126,n,16,0);c.enableVertexAttribArray(this.t.la);c.vertexAttribPointer(this.t.la,2,
5126,n,16,8);c.uniform1i(this.t.vb,0);var B={};B[j]={};var u=function(a,c){var d=i,e,g,j,l;for(j=c.h;j<=c.j;++j)for(l=c.i;l<=c.m;++l){e=new S(a,j,l);g=e.toString();if(B[a]&&B[a][g])return;e=fe(f,e);e!==k&&2==e.a&&e.getKey()in b.e?(B[a]||(B[a]={}),B[a][g]=e):d=n}return d},m=new tf,C=i,A,P,Y;for(P=q.h;P<=q.j;++P)for(Y=q.i;Y<=q.m;++Y)if(r=new S(j,P,Y),t=fe(f,r),t!==k){A=t.a;if(0==A)A=Td(g,r),a.tb.b(t,A,s);else if(2==A)if(t.getKey()in b.e){B[j][r.toString()]=t;continue}else A=Td(g,r),C=A.x-e.x,A=A.y-
e.y,C=Math.sqrt(C*C+A*A),sf(m,C,t);else if(3==A)continue;C=n;g.c(r,u)}e=Ea(Pa(B),Number);La(e);var T=new Float32Array(4);I(e,function(a){Na(B[a],function(a){var d=Pd(g,a.da),e=2*d.a()/w.height,f=2*(d.h-l.h)/w.width-1,j=2*(d.i-l.i)/w.height-1;T[0]=2*d.b()/w.width;T[1]=e;T[2]=f;T[3]=j;c.uniform4fv(this.t.Xc,T);Kg(b,a);c.drawArrays(5,0,4)},this)},this);m.$()||a.pb.push(la(function(a,b){var c,d;for(c=0;!b.$()&&4>c;++c)d=b.remove(),Kg(a,d)},b,m));C?(this.b=q,this.r=l):(this.r=this.b=k,a.G=i)}gg(a.Sa,f,
j,q);kf(this.d);nf(this.d,(d.center.x-l.h)/(l.j-l.h),(d.center.y-l.i)/(l.m-l.i));pf(this.d,d.rotation);of(this.d,a.size.width*d.resolution/(l.j-l.h),a.size.height*d.resolution/(l.m-l.i));nf(this.d,-0.5,-0.5)};function Lg(){this.a="precision mediump float;\n\nuniform mat4 uColorMatrix;\nuniform float uOpacity;\nuniform mat4 uMatrix;\nuniform sampler2D uTexture;\n\nvarying vec2 vTexCoord;\n\nvoid main(void) {\n\n vec4 texCoord = uMatrix * vec4(vTexCoord, 0., 1.);\n vec4 texColor = texture2D(uTexture, texCoord.st);\n vec4 color = uColorMatrix * vec4(texColor.rgb, 1.);\n color.a = texColor.a * uOpacity;\n\n gl_FragColor = color;\n\n}"}G(Lg,Bg);aa(Lg);
function Mg(){this.a="attribute vec2 aPosition;\nattribute vec2 aTexCoord;\n\nvarying vec2 vTexCoord;\n\nvoid main(void) {\n gl_Position = vec4(aPosition, 0., 1.);\n vTexCoord = aTexCoord;\n}"}G(Mg,Cg);aa(Mg);
function Ng(a,b){hg.call(this,a,b);this.a=document.createElement("CANVAS");this.a.height=a.clientHeight;this.a.width=a.clientWidth;this.a.className="ol-unselectable";Jc(a,this.a);this.r=i;this.A=new fd(a.clientHeight,a.clientWidth);this.b=yg(this.a,{alpha:n,antialias:i,depth:n,preserveDrawingBuffer:n,stencil:n});M(this.a,"webglcontextlost",this.Ba,n,this);M(this.a,"webglcontextrestored",this.Lc,n,this);this.o=this.t=k;this.n={};this.g={};this.e={};this.J=Lg.wa();this.N=Mg.wa();this.w={};Og(this)}
G(Ng,hg);v=Ng.prototype;v.fa=function(a){Ng.p.fa.call(this,a);a.a()&&ng(this.map)};
function Kg(a,b){var c=a.b,d=b.getKey(),e=a.e[d];z(e)?(c.bindTexture(3553,e.bc),9729!=e.Kb&&(c.texParameteri(3553,10240,9729),e.Kb=9729),9729!=e.Lb&&(c.texParameteri(3553,10240,9729),e.Lb=9729)):(e=c.createTexture(),c.bindTexture(3553,e),c.texImage2D(3553,0,6408,6408,5121,b.W()),c.texParameteri(3553,10240,9729),c.texParameteri(3553,10241,9729),c.texParameteri(3553,10242,33071),c.texParameteri(3553,10243,33071),a.e[d]={bc:e,Kb:9729,Lb:9729})}v.ua=function(a){return a instanceof pg?new Ig(this,a):k};
v.q=function(){var a=this.b;a.isContextLost()||(Na(this.g,function(b){a.deleteProgram(b)}),Na(this.n,function(b){a.deleteShader(b)}),Na(this.e,function(b){a.deleteTexture(b.bc)}));Ng.p.q.call(this)};function Jg(a,b,c){var d=E(b)+"/"+E(c);if(d in a.g)return a.g[d];var e=a.b,f=e.createProgram();e.attachShader(f,Pg(a,b));e.attachShader(f,Pg(a,c));e.linkProgram(f);return a.g[d]=f}
function Pg(a,b){var c=E(b);if(c in a.n)return a.n[c];var d=a.b,e=d.createShader(b.b());d.shaderSource(e,b.X());d.compileShader(e);return a.n[c]=e}v.ab=function(){ng(this.map)};v.Oc=function(){ng(this.map)};v.Ba=function(a){a.v();this.o=this.t=k;this.n={};this.g={};this.e={};Na(this.c,function(a){a.Ba()})};v.Lc=function(){Og(this);ng(this.map)};function Og(a){a=a.b;a.activeTexture(33984);a.blendFunc(770,771);a.disable(2884);a.disable(2929);a.disable(3089)}
v.qb=function(a){Ng.p.qb.call(this,a);a.a()&&ng(this.map)};v.rb=function(a){var b=Ng.p.rb.call(this,a);b!==k&&(a=E(a),N(this.w[a]),delete this.w[a]);return b};
v.L=function(a){var b=this.b;if(a===k)return this.r&&(We(this.a,n),this.r=n),n;I(a.Ha,function(b){var c=a.Ga[E(b)];c.visible&&c.Oa&&mg(this,b).L(a,c)},this);var c=a.size;this.A.width==c.width&&this.A.height==c.height||(this.a.width=c.width,this.a.height=c.height,this.A=c);b.bindFramebuffer(36160,k);var d=a.backgroundColor;b.clearColor(d.d/255,d.c/255,d.b/255,d.a);b.clear(16384);b.enable(3042);b.viewport(0,0,c.width,c.height);c=Jg(this,this.J,this.N);b.useProgram(c);this.t===k&&(this.t={ka:b.getAttribLocation(c,
"aPosition"),la:b.getAttribLocation(c,"aTexCoord"),Uc:b.getUniformLocation(c,"uColorMatrix"),Vc:b.getUniformLocation(c,"uMatrix"),Wc:b.getUniformLocation(c,"uOpacity"),vb:b.getUniformLocation(c,"uTexture")});this.o===k?(c=b.createBuffer(),b.bindBuffer(34962,c),b.bufferData(34962,new Float32Array([-1,-1,0,0,1,-1,1,0,-1,1,0,1,1,1,1,1]),35044),this.o=c):b.bindBuffer(34962,this.o);b.enableVertexAttribArray(this.t.ka);b.vertexAttribPointer(this.t.ka,2,5126,n,16,0);b.enableVertexAttribArray(this.t.la);
b.vertexAttribPointer(this.t.la,2,5126,n,16,8);b.uniform1i(this.t.vb,0);I(a.Ha,function(c){var d=a.Ga[E(c)];d.visible&&d.Oa&&(d=mg(this,c),b.uniformMatrix4fv(this.t.Vc,n,d.d),b.uniformMatrix4fv(this.t.Uc,n,Fg(d)),b.uniform1f(this.t.Wc,c.e()),b.bindTexture(3553,d.g),b.drawArrays(5,0,4))},this);this.r||(We(this.a,i),this.r=i);lg(a)};v.sb=function(a,b){Ng.p.sb.call(this,a,b);var c=E(a);this.w[c]=M(b,"change",this.Oc,n,this)};var Qg={cd:"canvas",fd:"dom",ld:"webgl"},Rg=["webgl","canvas","dom"],ig="backgroundColor",Pf="layers",jg="size",kg="view";
function $(a){var b,c;V.call(this);var d={};d[Pf]=z(a.layers)?a.layers:new W;d[kg]=z(a.view)?a.view:new Z;c=hg;var e;e=z(a.renderers)?a.renderers:z(a.renderer)?[a.renderer]:Rg;var f;for(b=0;b<e.length;++b)if(f=e[b],"canvas"==f){if(og()){c=sg;break}}else if("dom"==f){if(ae()){c=wg;break}}else if("webgl"==f&&zg()){c=Ng;break}z(a.controls)?e=a.controls:(e=new W,e.push(new Nf({})),e.push(new Qf({delta:z(a.zoomDelta)?a.zoomDelta:4})));if(z(a.interactions))b=a.interactions;else{b=new W;(z(a.rotate)?a.rotate:
1)&&b.push(new Zf(Tf));if(z(a.doubleClickZoom)?a.doubleClickZoom:1)b.push(new Sf(z(a.zoomDelta)?a.zoomDelta:4));(z(a.dragPan)?a.dragPan:1)&&b.push(new Xf(Uf));f=z(a.keyboardPanOffset)?a.keyboardPanOffset:80;if(z(a.keyboard)?a.keyboard:1)b.push(new cg(f)),b.push(new dg);if(z(a.mouseWheelZoom)?a.mouseWheelZoom:1)b.push(new eg(z(a.mouseWheelZoomDelta)?a.mouseWheelZoomDelta:1));(z(a.shiftDragZoom)?a.shiftDragZoom:1)&&b.push(new bg(Vf))}a=D(a.target)?document.getElementById(a.target):a.target;this.c=new te(this.Rc,
h,this);Yb(this,this.c);this.ub=hf();this.dc=hf();this.d=k;this.f=0;this.n=n;this.r=a;this.b=Gc("DIV","ol-viewport");this.b.style.position="relative";this.b.style.overflow="hidden";this.b.style.width="100%";this.b.style.height="100%";this.r.appendChild(this.b);this.o=Gc("DIV","ol-overlaycontainer");M(this.o,["click",df?"touchstart":"mousedown"],bc);this.b.appendChild(this.o);a=new Af(this);M(a,[Cf,Df,Ff,Gf,Ef],this.Sb,n,this);Yb(this,a);a=new Ce(document);M(a,"key",this.Eb,n,this);Yb(this,a);a=new af(this.b);
M(a,"mousewheel",this.Eb,n,this);Yb(this,a);this.g=e;M(this.g,"add",this.Cc,n,this);M(this.g,"remove",this.Dc,n,this);this.J=b;this.ia=new c(this.b,this);Yb(this,this.ia);this.gc=new xe;M(this.gc,"resize",this.Fb,n,this);this.N=[];this.w=[];this.cc=ka(this.Jc,this);this.A=new uf(ka(this.uc,this));this.Ka(d);this.Fb();this.g.forEach(function(a){a.a(this)},this)}G($,V);$.prototype.q=function(){Kc(this.b);$.p.q.call(this)};$.prototype.D=function(){return this.u(ig)};$.prototype.getBackgroundColor=$.prototype.D;
$.prototype.Zc=p("g");function yf(a,b){var c=a.d;if(c===k)return k;var d=[b.x,b.y,0];mf(c.Ub,d,d);return new R(d[0],d[1])}$.prototype.$c=p("J");function ag(a,b){var c=a.d;if(c===k)return k;var d=[b.x,b.y,0];mf(c.Bb,d,d);return new wf(d[0],d[1])}$.prototype.e=function(){return this.u(jg)};$.prototype.getSize=$.prototype.e;$.prototype.a=function(){return this.u(kg)};$.prototype.getView=$.prototype.a;v=$.prototype;
v.uc=function(a,b,c){if(this.d!==k){var d=this.d.z.center,a=b.x-d.x,b=b.y-d.y;return Math.sqrt(a*a+b*b)/c}};v.Eb=function(a,b){this.Sb(new xf(b||a.type,this,a))};v.Cc=function(a){a.a.a(this)};v.Dc=function(a){a.a.a(k)};v.Sb=function(a){var b=this.J.a;if(O(this,a)!==n)for(var c=b.length-1;0<=c&&!(b[c].b(a),a.Aa);c--);};
v.Jc=function(){var a=this.A;if(!a.a.$()){var b=a.a.I();a.a.clear();a.c={};var c;for(c=0;c<b.length;++c)a.b.apply(a,b[c])}for(a=this.A;!a.a.$()&&a.d<a.f;)b=a.a.remove()[0],c=b.getKey(),delete a.c[c],M(b,"change",a.e,n,a),b.load(),++a.d;I(this.w,function(a){a(this,this.d)},this);this.w.length=0};v.Fb=function(){this.Qa(new fd(this.r.clientWidth,this.r.clientHeight))};v.Da=function(){var a=this.a(),b;if(b=z(a)){if(a=a.Da())a=this.e()!=k;b=a}return b};
function ng(a){a.c.a==k&&(0===a.f?(a=a.c,ue(a),a.d()):a.n=i)}function Yf(a){if(0===a.f){if(a.c.a==k){a=a.c;ue(a);a.e=n;var b=ve(a),c=we(a);if(b&&!c&&a.b.mozRequestAnimationFrame)a.a=M(a.b,"MozBeforePaint",a.c),a.b.mozRequestAnimationFrame(k),a.e=i;else{if(b&&c)b=b.call(a.b,a.c);else{var d=a.c,e;e=e||0;b=a.b.setTimeout(function(){return d.apply(this,Array.prototype.slice.call(arguments,0,e))},20)}a.a=b}}}else a.n=i}
v.Rc=function(a){var b;if(0==this.f){b=this.e();var c=this.u(Pf),c=z(c)?c.a:h,d=this.a(),e=z(d)?this.a():h,f=k;if(z(c)&&z(b)&&z(e)&&e.Da()){var g=this.D(),d=Ia(d.a),j={};I(c,function(a){var b=E(a),c=a.b(),d=a.c(),e=a.d(),f=a.e(),g=a.X().a(),l=a.f(),a=a.a();j[b]={brightness:z(c)?c:0,contrast:z(d)?d:1,hue:z(e)?e:0,opacity:z(f)?f:1,Oa:g,saturation:z(l)?l:1,visible:z(a)?a:i}});var s;s=e.aa();var q=e.Rb(),l=e.T(),e=e.xa();s={center:new R(s.x,s.y),projection:q,resolution:l,rotation:e};f={G:n,backgroundColor:z(g)?
g:new ef,Bb:this.ub,extent:k,Ha:c,Ga:j,Ub:this.dc,pb:[],size:b,tb:this.A,Sa:{},z:s,B:d,time:a}}this.N=Da(this.N,function(a){return a(this,f)},this);if(f!==k){a=s.center;g=s.resolution;c=s.rotation;e=g*b.width/2;b=g*b.height/2;g=[new R(-e,-b),new R(-e,b),new R(e,-b),new R(e,b)];for(b=0;4>b;++b)e=g[b],e.rotate(c),e.add(a);f.extent=ld.apply(k,g)}this.ia.L(f);f!==k&&(f.G&&Yf(this),Array.prototype.push.apply(this.w,f.pb));this.d=f;this.n=n;O(this,new vf("postrender",this,f));x.setTimeout(this.cc,0)}};
v.Tc=function(a){this.set(ig,a)};$.prototype.setBackgroundColor=$.prototype.Tc;$.prototype.ec=function(a){this.set(Pf,a)};$.prototype.setLayers=$.prototype.ec;$.prototype.Qa=function(a){this.set(jg,a)};$.prototype.setSize=$.prototype.Qa;$.prototype.fc=function(a){this.set(kg,a)};$.prototype.setView=$.prototype.fc;function Lf(a,b,c){++a.f;try{b.call(c)}finally{0===--a.f&&a.n&&(a=a.c,ue(a),a.d())}};function Sg(a){return 3*a*a-2*a*a*a};function Tg(a){return 0.5>a?Sg(2*a):1-Sg(2*(a-0.5))};var Ug={lc:function(a,b,c,d){var e=z(c)?c:Date.now(),f=z(b)?b:1E3,g=z(d)?d:Tg;return function(b,c){if(c.time<e)return c.G=i,c.B[0]+=1,i;if(c.time<e+f){var d=g((c.time-e)/f),l=a-c.z.resolution;c.G=i;c.z.resolution+=d*l;c.B[0]+=1;return i}return n}},mc:function(a,b,c,d){var e=z(c)?c:Date.now(),f=a.x,g=a.y,j=z(b)?b:1E3,s=z(d)?d:Sg;return function(a,b){if(b.time<e)return b.G=i,b.B[0]+=1,i;if(b.time<e+j){var c=1-s((b.time-e)/j),d=f-b.z.center.x,w=g-b.z.center.y;b.G=i;b.z.center.x+=c*d;b.z.center.y+=c*
w;b.B[0]+=1;return i}return n}},nc:function(a,b,c,d){var e=z(c)?c:Date.now(),f=z(a)?a:1E3,g=2*(z(b)?b:1)*Math.PI,j=z(d)?d:Sg;return function(a,b){if(b.time<e)return b.G=i,b.B[0]+=1,i;if(b.time<e+f){var c=j((b.time-e)/f);b.G=i;b.z.rotation+=c*g;b.B[0]+=1;return i}return n}}};function Vg(a){var b=Gc("DIV",{"class":"ol-mouse-position"});Mf.call(this,{element:b,map:a.map,target:a.target});this.o=a.projection;this.g=a.coordinateFormat;this.N=z(a.undefinedHTML)?a.undefinedHTML:"";this.f=b.innerHTML;this.c=k;this.r=Dd;this.d=this.e=this.w=k}G(Vg,Mf);Vg.prototype.J=function(a){a=a.f;a===k?this.c=k:this.c=a.z.projection;Wg(this,this.e)};Vg.prototype.A=function(a){a=Te(a,this.b.b);a=new wf(a.x,a.y);Wg(this,a);this.e=a};Vg.prototype.D=function(){Wg(this,k);this.e=k};
Vg.prototype.a=function(a){this.d!==k&&(I(this.d,N),this.d=k);Vg.p.a.call(this,a);if(a!==k){var b=a.b;this.d=[M(b,"mousemove",this.A,n,this),M(b,"mouseout",this.D,n,this),M(a,"postrender",this.J,n,this)]}};function Wg(a,b){var c=a.N;if(b!==k){a.w!=a.c&&(a.r=z(a.o)?Cd(a.c,a.o):Dd,a.w=a.c);var d=yf(a.b,b);d!==k&&(d=a.r(d),c=z(a.g)?a.g(d):d.toString())}if(!z(a.f)||c!=a.f)a.element.innerHTML=c,a.f=c};function Xg(){this.a={}}G(Xg,Rf);Xg.prototype.c=function(a,b){var c;for(c=0;c<a.length;++c)this.a[a.charCodeAt(c)]=b};Xg.prototype.b=function(a){if("key"==a.type){var b=this.a[a.a.ya];b&&(b(),a.v())}};function Yg(a){this.b=this.a=this.f=k;this.c=[Zg,$g];this.e=this.d=k;z(a.coordinate)&&this.Zb(a.coordinate);z(a.element)&&ah(this,a.element);z(a.map)&&this.Tb(a.map);z(a.positioning)&&(this.c=a.positioning,this.U())}v=Yg.prototype;v.Ib=function(){this.e!==k&&(I(this.e,N),this.e=k);var a=this.b.a();a!=k&&(this.e=[M(a,oe("center"),this.U,n,this),M(a,oe("resolution"),this.U,n,this),M(a,oe("rotation"),this.U,n,this)],this.U())};v.Zb=function(a){this.f=a;this.U()};
function ah(a,b){a.a&&Kc(a.a);a.a=b;a.b&&(Ke(a.a,"position","absolute"),Ic(a.b.o,a.a));a.U()}v.Nc=p("a");v.Tb=function(a){this.b=a;this.d!==k&&(I(this.d,N),this.d=k);this.a&&ah(this,this.a);a!=k&&(this.d=[M(a,oe(jg),this.U,n,this),M(a,oe(kg),this.Ib,n,this)],this.Ib())};
v.U=function(){if(this.b!==k&&this.f!==k&&this.a!==k){var a=ag(this.b,this.f),b=this.b.u(jg),c=Math.round(a.x);this.c[0]===bh&&(c=b.width-c);a=Math.round(a.y);this.c[1]===$g&&(a=b.height-a);Ke(this.a,this.c[0],c+"px");Ke(this.a,this.c[1],a+"px")}};var Zg="left",bh="right",$g="bottom";function ch(a){var b=a.projection||Ad("EPSG:3857"),c=Xd;z(a.O)?c=a.O:z(a.urls)?c=Vd(Ea(a.urls,Ud)):z(a.url)&&(c=Ud(a.url));var d=new ge({maxZoom:a.maxZoom}),e=a.extent,c=e!=k?Yd(function(b){if(a.maxZoom<b.k)return k;var c=1<<b.k,j=-b.y-1;if(0>j||c<=j)return k;c=xc(b.x,c);return!hd(Pd(d,new S(b.k,c,b.y)),e)?k:new S(b.k,c,j)},c):Yd(function(b){if(a.maxZoom<b.k)return k;var c=1<<b.k,d=-b.y-1;return 0>d||c<=d?k:new S(b.k,xc(b.x,c),d)},c);ee.call(this,{attributions:a.attributions,crossOrigin:a.crossOrigin,
extent:a.extent,projection:b,tileGrid:d,O:c})}G(ch,ee);function dh(){ch.call(this,{attributions:[new na('Tiles Courtesy of <a href="http://www.mapquest.com/" target="_blank">MapQuest</a> <img src="http://developer.mapquest.com/content/osm/mq_logo.png">'),new na('Data &copy; <a href="http://www.openstreetmap.org">OpenStreetMap</a> contributors, <a href="http://creativecommons.org/licenses/by-sa/2.0/">CC BY-SA</a>')],maxZoom:28,url:"http://otile{1-4}.mqcdn.com/tiles/1.0.0/osm/{z}/{x}/{y}.jpg"})}G(dh,ch);
function eh(){ch.call(this,{attributions:[new na('Tiles Courtesy of <a href="http://www.mapquest.com/" target="_blank">MapQuest</a> <img src="http://developer.mapquest.com/content/osm/mq_logo.png">'),new na("Portions Courtesy NASA/JPL-Caltech and U.S. Depart. of Agriculture, Farm Service Agency")],maxZoom:18,url:"http://oatile{1-4}.mqcdn.com/tiles/1.0.0/sat/{z}/{x}/{y}.jpg"})}G(eh,ch);function fh(){ch.call(this,{attributions:[new na('&copy; <a href="http://www.openstreetmap.org">OpenStreetMap</a> contributors, <a href="http://creativecommons.org/licenses/by-sa/2.0/">CC BY-SA</a>')],maxZoom:18,url:"http://{a-c}.tile.openstreetmap.org/{z}/{x}/{y}.png"})}G(fh,ch);var gh={terrain:{type:"jpg",Mb:4,maxZoom:18},toner:{type:"png",Mb:0,maxZoom:20},watercolor:{type:"jpg",Mb:3,maxZoom:16}};
function hh(a){var b=new na('Map tiles by <a href="http://stamen.com">Stamen Design</a>, under <a href="http://creativecommons.org/licenses/by/3.0">CC BY 3.0</a>. Data by <a href="http://openstreetmap.org">OpenStreetMap</a>, under <a href="http://creativecommons.org/licenses/by-sa/3.0">CC BY SA</a>.'),c=a.Qc;z(a.qc)&&(c+="-"+a.qc);a=gh[a.Qc];ch.call(this,{attributions:[b],maxZoom:a.maxZoom,url:"http://{a-d}.tile.stamen.com/"+c+"/{z}/{x}/{y}."+a.type})}G(hh,ch);var ih=[];F("grid",function(a){ih.push(a)});function jh(a){ee.call(this,{projection:Ad("EPSG:3857")});this.c=n;a=this.g=Sc(a.uri,{zb:i});a.a.push([this.n,k,this]);a.V&&Oc(a)}G(jh,ee);
jh.prototype.n=function(){var a=ih.pop(),b=Ad("EPSG:4326"),c,d;z(a.bounds)?(c=a.bounds,c=new kd(c[0],c[1],c[2],c[3]),this.d=d=c.transform(Cd(b,this.e))):d=c=k;var e=a.minzoom||0,f=a.maxzoom||22,g=new ge({maxZoom:f});this.tileGrid=g;this.O=Yd(function(a){if(a.k<e||f<a.k)return k;var b=1<<a.k,c=-a.y-1;if(0>c||b<=c)return k;b=xc(a.x,b);return d!==k&&!hd(Pd(g,new S(a.k,b,a.y)),d)?k:new S(a.k,b,c)},Vd(Ea(a.tiles,Ud)));if(z(a.attribution)){b=d===k?b.K():d;c={};var j,s;for(j=e;j<=f;++j)s=j.toString(),c[s]=
[Qd(g,b,g.a[j])];this.ta=[new na(a.attribution,c)]}this.c=i;O(this,"load")};jh.prototype.a=p("c");function kh(a){var b=zd(a.projection),c=b.K(),d=z(a.extent)?a.extent:c,e=z(a.version)?a.version:"1.3",f,g;if(z(a.tileGrid))g=a.tileGrid;else{var j=a.maxZoom;g=b.K();for(var s=Math.max(g.j-g.h,g.m-g.i),q=z(h)?h:new fd(256,256),j=Array((z(j)?j:18)+1),l=0,m=j.length;l<m;++l)j[l]=s/(q.width<<l);g=new Od({origin:md(g),resolutions:j,Ra:q})}f=g;var u={SERVICE:"WMS",VERSION:e,REQUEST:"GetMap",STYLES:"",FORMAT:"image/png",TRANSPARENT:i};g=f.b;u.WIDTH=g.width;u.HEIGHT=g.height;u["1.3"<=e?"CRS":"SRS"]=b.a;Ra(u,
a.params);a.urls?(e=Ea(a.urls,function(a){a=yb(Ab([a],u));return Wd(a,f)}),e=Vd(e)):a.url?(e=yb(Ab([a.url],u)),e=Wd(e,f)):e=Xd;ee.call(this,{attributions:a.attributions,crossOrigin:a.crossOrigin,extent:d,tileGrid:f,projection:b,O:Yd(function(a){if(f.a.length<=a.k)return k;var b=a.x,e=Pd(f,a);d.h===c.h&&d.j===c.j&&(e=Math.ceil((d.j-d.h)/(e.j-e.h)),b=xc(b,e),e=Pd(f,new S(a.k,b,a.y)));return!hd(e,d)?k:new S(a.k,b,a.y)},e)})}G(kh,ee);F("goog.require",y);F("ol.Attribution",na);F("ol.BingMapsStyle",he);he.AERIAL="Aerial";he.AERIAL_WITH_LABELS="AerialWithLabels";he.COLLINS_BART="CollinsBart";he.ORDNANCE_SURVEY="OrdnanceSurvey";he.ROAD="Road";F("ol.Collection",W);W.prototype.clear=W.prototype.clear;W.prototype.forEach=W.prototype.forEach;W.prototype.getArray=W.prototype.rc;W.prototype.getAt=W.prototype.sc;W.prototype.getLength=W.prototype.Db;W.prototype.insertAt=W.prototype.Ca;W.prototype.pop=W.prototype.Qb;W.prototype.push=W.prototype.push;
W.prototype.removeAt=W.prototype.Xb;W.prototype.setAt=W.prototype.Sc;F("ol.Coordinate",R);R.toStringHDMS=function(a){return z(a)?ed(a.y,"NS")+" "+ed(a.x,"EW"):""};F("ol.Extent",kd);
function lh(a){$.call(this,{controls:a.controls,doubleClickZoom:a.doubleClickZoom,dragPan:a.dragPan,interactions:a.interactions,keyboard:a.keyboard,keyboardPanOffset:a.keyboardPanOffset,layers:a.layers,mouseWheelZoom:a.mouseWheelZoom,mouseWheelZoomDelta:a.mouseWheelZoomDelta,renderer:a.renderer,renderers:a.renderers,shiftDragZoom:a.shiftDragZoom,target:a.target,view:a.view,zoomDelta:a.zoomDelta})}G(lh,$);F("ol.Map",lh);$.prototype.getControls=$.prototype.Zc;$.prototype.getInteractions=$.prototype.$c;
xf.prototype.getCoordinate=xf.prototype.c;F("ol.Object",V);V.prototype.bindTo=V.prototype.hc;V.prototype.changed=V.prototype.kc;V.prototype.get=V.prototype.u;V.prototype.notify=V.prototype.Ob;V.prototype.set=V.prototype.set;V.prototype.setOptions=V.prototype.$b;V.prototype.setValues=V.prototype.Ka;V.prototype.unbind=V.prototype.wb;V.prototype.unbindAll=V.prototype.Yc;F("ol.Projection",U);U.addProjection=wd;U.getFromCode=Ad;U.getTransform=Cd;U.getTransformFromCodes=Ed;
U.transform=function(a,b,c){return Cd(b,c)(a)};U.transformWithCodes=function(a,b,c){return Ed(b,c)(a)};U.prototype.getCode=U.prototype.b;U.prototype.getExtent=U.prototype.K;U.prototype.getUnits=U.prototype.c;F("ol.ProjectionUnits",qd);qd.DEGREES="degrees";qd.METERS="m";F("ol.RendererHint",Qg);Qg.CANVAS="canvas";Qg.DOM="dom";Qg.WEBGL="webgl";F("ol.animation",Ug);Ug.createBounce=Ug.lc;Ug.createPanFrom=Ug.mc;Ug.createSpin=Ug.nc;function mh(a){Nf.call(this,{map:a.map,target:a.target})}G(mh,Nf);
F("ol.control.Attribution",mh);function nh(a){Vg.call(this,{coordinateFormat:a.coordinateFormat,map:a.map,projection:a.projection,target:a.target,undefinedHTML:a.undefinedHTML})}G(nh,Vg);F("ol.control.MousePosition",nh);function oh(a){Qf.call(this,{delta:a.delta,map:a.map,target:a.target})}G(oh,Qf);F("ol.control.Zoom",oh);F("ol.interaction.Keyboard",Xg);Xg.prototype.addCallback=Xg.prototype.c;
function ph(a){X.call(this,{brightness:a.brightness,contrast:a.contrast,hue:a.hue,opacity:a.opacity,saturation:a.saturation,source:a.source,visible:a.visible})}G(ph,pg);F("ol.layer.TileLayer",ph);function qh(a){Yg.call(this,{coordinate:a.coordinate,element:a.element,map:a.map,positioning:a.positioning})}G(qh,Yg);F("ol.overlay.Overlay",qh);Yg.prototype.getElement=Yg.prototype.Nc;Yg.prototype.setCoordinate=Yg.prototype.Zb;Yg.prototype.setMap=Yg.prototype.Tb;F("ol.source.BingMaps",ie);
F("ol.source.MapQuestOSM",dh);F("ol.source.MapQuestOpenAerial",eh);F("ol.source.OpenStreetMap",fh);F("ol.source.Stamen",hh);F("ol.source.TileJSON",jh);F("ol.source.TiledWMS",kh);})();