From 71df0860fc23f825fbddf3deeabf37029c183a67 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=C3=81lvaro=20Arranz?= Date: Wed, 28 Mar 2018 11:46:08 +0200 Subject: [PATCH] Clean up --- ckanext/ngsiview/theme/public/resource.config | 4 - .../theme/public/vendor/openlayers/ol.css | 1 - .../theme/public/vendor/openlayers/ol.js | 910 ------------------ .../theme/public/vendor/openlayers/ol.min.css | 1 - .../theme/public/vendor/openlayers/ol.min.js | 910 ------------------ .../ngsiview/theme/public/view_ngsi_chart.js | 158 --- .../theme/public/view_ngsi_chart.min.js | 159 --- .../ngsiview/theme/public/view_ngsi_map.js | 358 ------- .../theme/public/view_ngsi_map.min.js | 358 ------- 9 files changed, 2859 deletions(-) delete mode 100644 ckanext/ngsiview/theme/public/vendor/openlayers/ol.css delete mode 100644 ckanext/ngsiview/theme/public/vendor/openlayers/ol.js delete mode 100644 ckanext/ngsiview/theme/public/vendor/openlayers/ol.min.css delete mode 100644 ckanext/ngsiview/theme/public/vendor/openlayers/ol.min.js delete mode 100644 ckanext/ngsiview/theme/public/view_ngsi_chart.js delete mode 100644 ckanext/ngsiview/theme/public/view_ngsi_chart.min.js delete mode 100644 ckanext/ngsiview/theme/public/view_ngsi_map.js delete mode 100644 ckanext/ngsiview/theme/public/view_ngsi_map.min.js diff --git a/ckanext/ngsiview/theme/public/resource.config b/ckanext/ngsiview/theme/public/resource.config index 1ac67f4..4e4c5e6 100644 --- a/ckanext/ngsiview/theme/public/resource.config +++ b/ckanext/ngsiview/theme/public/resource.config @@ -7,14 +7,10 @@ main = base/main main = vendor/highlight/highlight.pack.js vendor/bootstrap/js/bootstrap.js - vendor/openlayers/ol.js vendor/dygraph/dygraph-combined.js view_ngsi.js - view_ngsi_map.js - view_ngsi_chart.js vendor/bootstrap/css/bootstrap-responsive.css vendor/bootstrap/css/bootstrap.css - vendor/openlayers/ol.css styles/github.css css/ngsi.css diff --git a/ckanext/ngsiview/theme/public/vendor/openlayers/ol.css b/ckanext/ngsiview/theme/public/vendor/openlayers/ol.css deleted file mode 100644 index ea9beaa..0000000 --- a/ckanext/ngsiview/theme/public/vendor/openlayers/ol.css +++ /dev/null @@ -1 +0,0 @@ -.ol-mouse-position{top:8px;right:8px;position:absolute}.ol-scale-line{background:#95b9e6;background:rgba(0,60,136,.3);border-radius:4px;bottom:8px;left:8px;padding:2px;position:absolute}.ol-scale-line-inner{border:1px solid #eee;border-top:none;color:#eee;font-size:10px;text-align:center;margin:1px;padding:0 2px}.ol-unsupported{display:none}.ol-viewport .ol-unselectable{-webkit-touch-callout:none;-webkit-user-select:none;-khtml-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;-webkit-tap-highlight-color:transparent}.ol-control{position:absolute;background-color:#eee;background-color:rgba(255,255,255,.4);border-radius:4px;padding:2px}.ol-control:hover{background-color:rgba(255,255,255,.6)}.ol-zoom{top:.5em;left:.5em}.ol-rotate{top:.5em;right:.5em;transition:opacity .25s linear,visibility 0s linear}.ol-rotate.ol-hidden{opacity:0;visibility:hidden;transition:opacity .25s linear,visibility 0s linear .25s}.ol-zoom-extent{top:4.643em;left:.5em}.ol-full-screen{right:.5em;top:.5em}@media print{.ol-control{display:none}}.ol-control button{display:block;margin:1px;padding:0;color:#fff;font-size:1.14em;font-weight:700;text-decoration:none;text-align:center;height:1.375em;width:1.375em;line-height:.4em;background-color:#7b98bc;background-color:rgba(0,60,136,.5);border:none;border-radius:2px}.ol-control button::-moz-focus-inner{border:none;padding:0}.ol-zoom-extent button{line-height:1.4em}.ol-compass{display:block;font-weight:400;font-size:1.2em}.ol-touch .ol-control button{font-size:1.5em}.ol-touch .ol-zoom-extent{top:5.5em}.ol-control button:focus,.ol-control button:hover{text-decoration:none;background-color:#4c6079;background-color:rgba(0,60,136,.7)}.ol-zoom .ol-zoom-in{border-radius:2px 2px 0 0}.ol-zoom .ol-zoom-out{border-radius:0 0 2px 2px}.ol-attribution{text-align:right;bottom:.5em;right:.5em;max-width:calc(100% - 1.3em)}.ol-attribution ul{margin:0;padding:0 .5em;font-size:.7rem;line-height:1.375em;color:#000;text-shadow:0 0 2px #fff}.ol-attribution li{display:inline;list-style:none;line-height:inherit}.ol-attribution li:not(:last-child):after{content:" "}.ol-attribution img{max-height:2em;max-width:inherit}.ol-attribution button,.ol-attribution ul{display:inline-block}.ol-attribution.ol-collapsed ul{display:none}.ol-attribution.ol-logo-only ul{display:block}.ol-attribution:not(.ol-collapsed){background:rgba(255,255,255,.8)}.ol-attribution.ol-uncollapsible{bottom:0;right:0;border-radius:4px 0 0;height:1.1em;line-height:1em}.ol-attribution.ol-logo-only{background:0 0;bottom:.4em;height:1.1em;line-height:1em}.ol-attribution.ol-uncollapsible img{margin-top:-.2em;max-height:1.6em}.ol-attribution.ol-logo-only button,.ol-attribution.ol-uncollapsible button{display:none}.ol-zoomslider{position:absolute;top:4.5em;left:.5em;background:#eee;background:rgba(255,255,255,.4);width:24px;height:200px}.ol-zoomslider-thumb{position:absolute;background:#7b98bc;background:rgba(0,60,136,.5);border-radius:2px;cursor:pointer;height:10px;width:22px;margin:3px}.ol-touch .ol-zoomslider{top:5.5em;width:2.052em}.ol-touch .ol-zoomslider-thumb{width:1.8em}.ol-overviewmap{position:absolute;left:.5em;bottom:.5em}.ol-overviewmap.ol-uncollapsible{bottom:0;left:0;border-radius:0 4px 0 0}.ol-overviewmap .ol-overviewmap-map,.ol-overviewmap button{display:inline-block}.ol-overviewmap .ol-overviewmap-map{border:1px solid #7b98bc;height:150px;margin:2px;width:150px}.ol-overviewmap:not(.ol-collapsed) button{bottom:1px;left:2px;position:absolute}.ol-overviewmap.ol-collapsed .ol-overviewmap-map,.ol-overviewmap.ol-uncollapsible button{display:none}.ol-overviewmap:not(.ol-collapsed){background:rgba(255,255,255,.8)}.ol-overviewmap-box{border:2px dotted rgba(0,60,136,.7)} \ No newline at end of file diff --git a/ckanext/ngsiview/theme/public/vendor/openlayers/ol.js b/ckanext/ngsiview/theme/public/vendor/openlayers/ol.js deleted file mode 100644 index 9e34f8c..0000000 --- a/ckanext/ngsiview/theme/public/vendor/openlayers/ol.js +++ /dev/null @@ -1,910 +0,0 @@ -// OpenLayers 3. See http://openlayers.org/ -// License: https://raw.githubusercontent.com/openlayers/ol3/master/LICENSE.md -// Version: v3.2.1 - -(function (root, factory) { - if (typeof define === "function" && define.amd) { - define([], factory); - } else if (typeof exports === "object") { - module.exports = factory(); - } else { - root.ol = factory(); - } -}(this, function () { - var OPENLAYERS = {}; - var l,aa=aa||{},ba=this;function m(b){return void 0!==b}function t(b,c,d){b=b.split(".");d=d||ba;b[0]in d||!d.execScript||d.execScript("var "+b[0]);for(var e;b.length&&(e=b.shift());)!b.length&&m(c)?d[e]=c:d[e]?d=d[e]:d=d[e]={}}function ca(){}function da(b){b.Ma=function(){return b.tf?b.tf:b.tf=new b}} -function ea(b){var c=typeof b;if("object"==c)if(b){if(b instanceof Array)return"array";if(b instanceof Object)return c;var d=Object.prototype.toString.call(b);if("[object Window]"==d)return"object";if("[object Array]"==d||"number"==typeof b.length&&"undefined"!=typeof b.splice&&"undefined"!=typeof b.propertyIsEnumerable&&!b.propertyIsEnumerable("splice"))return"array";if("[object Function]"==d||"undefined"!=typeof b.call&&"undefined"!=typeof b.propertyIsEnumerable&&!b.propertyIsEnumerable("call"))return"function"}else return"null"; -else if("function"==c&&"undefined"==typeof b.call)return"object";return c}function fa(b){return null===b}function ga(b){return"array"==ea(b)}function ha(b){var c=ea(b);return"array"==c||"object"==c&&"number"==typeof b.length}function ia(b){return"string"==typeof b}function ja(b){return"number"==typeof b}function ka(b){return"function"==ea(b)}function la(b){var c=typeof b;return"object"==c&&null!=b||"function"==c}function ma(b){return b[na]||(b[na]=++oa)} -var na="closure_uid_"+(1E9*Math.random()>>>0),oa=0;function pa(b,c,d){return b.call.apply(b.bind,arguments)}function qa(b,c,d){if(!b)throw Error();if(2")&&(b=b.replace(Fa,">"));-1!=b.indexOf('"')&&(b=b.replace(Ga,"""));-1!=b.indexOf("'")&&(b=b.replace(Ha,"'"));-1!=b.indexOf("\x00")&&(b=b.replace(Ia,"�"));return b}var Da=/&/g,Ea=//g,Ga=/"/g,Ha=/'/g,Ia=/\x00/g,Ca=/[\x00&<>"']/; -function Ja(b){b=m(void 0)?b.toFixed(void 0):String(b);var c=b.indexOf(".");-1==c&&(c=b.length);c=Math.max(0,2-c);return Array(c+1).join("0")+b} -function Ka(b,c){for(var d=0,e=Aa(String(b)).split("."),f=Aa(String(c)).split("."),g=Math.max(e.length,f.length),h=0;0==d&&hc?1:0};var Na=Array.prototype;function Oa(b,c,d){Na.forEach.call(b,c,d)}function Pa(b,c){return Na.filter.call(b,c,void 0)}function Ra(b,c,d){return Na.map.call(b,c,d)}function Sa(b,c){return Na.some.call(b,c,void 0)}function Ta(b){var c;a:{c=Ua;for(var d=b.length,e=ia(b)?b.split(""):b,f=0;fc?null:ia(b)?b.charAt(c):b[c]}function Va(b,c){return 0<=Na.indexOf.call(b,c,void 0)} -function Wa(b,c){var d=Na.indexOf.call(b,c,void 0),e;(e=0<=d)&&Na.splice.call(b,d,1);return e}function Xa(b){return Na.concat.apply(Na,arguments)}function Ya(b){var c=b.length;if(0=arguments.length?Na.slice.call(b,c):Na.slice.call(b,c,d)}function bb(b,c){b.sort(c||cb)}function db(b,c){if(!ha(b)||!ha(c)||b.length!=c.length)return!1;for(var d=b.length,e=eb,f=0;fc?1:bparseFloat(b))?String(c):b}(),Lb={};function Mb(b){return Lb[b]||(Lb[b]=0<=Ka(Kb,b))}var Nb=ba.document,Pb=Nb&&Bb?Ib()||("CSS1Compat"==Nb.compatMode?parseInt(Kb,10):5):void 0;var Qb="https:"===ba.location.protocol,Rb=Bb&&!Mb("9.0")&&""!==Kb;function Ub(b,c,d){return Math.min(Math.max(b,c),d)}function Vb(b,c){var d=b%c;return 0>d*c?d+c:d}function Wb(b,c,d){return b+d*(c-b)}function Xb(b){return b*Math.PI/180};function Yb(b){return function(c){if(m(c))return[Ub(c[0],b[0],b[2]),Ub(c[1],b[1],b[3])]}}function Zb(b){return b};function $b(b,c,d){var e=b.length;if(b[0]<=c)return 0;if(!(c<=b[e-1]))if(0d)for(d=1;dg?1:.5,e=Math.floor(Math.log(c/e)/Math.log(b)+g),f=Math.max(e+f,0),m(d)&&(f=Math.min(f,d)),c/Math.pow(b,f)}};function cc(b){if(m(b))return 0}function dc(b,c){if(m(b))return b+c}function ec(b){var c=2*Math.PI/b;return function(b,e){if(m(b))return b=Math.floor((b+e)/c+.5)*c}}function fc(){var b=Xb(5);return function(c,d){if(m(c))return Math.abs(c+d)<=b?0:c+d}};function gc(b,c,d){this.center=b;this.resolution=c;this.rotation=d};var hc=!Bb||Bb&&9<=Pb,ic=!Bb||Bb&&9<=Pb,jc=Bb&&!Mb("9");!Db||Mb("528");Cb&&Mb("1.9b")||Bb&&Mb("8")||Ab&&Mb("9.5")||Db&&Mb("528");Cb&&!Mb("8")||Bb&&Mb("9");function kc(){0!=lc&&(mc[ma(this)]=this);this.oa=this.oa;this.pa=this.pa}var lc=0,mc={};kc.prototype.oa=!1;kc.prototype.Ec=function(){if(!this.oa&&(this.oa=!0,this.M(),0!=lc)){var b=ma(this);delete mc[b]}};function nc(b,c){var d=sa(oc,c);b.oa?d.call(void 0):(b.pa||(b.pa=[]),b.pa.push(m(void 0)?ra(d,void 0):d))}kc.prototype.M=function(){if(this.pa)for(;this.pa.length;)this.pa.shift()()};function oc(b){b&&"function"==typeof b.Ec&&b.Ec()};function pc(b,c){this.type=b;this.b=this.target=c;this.e=!1;this.hg=!0}pc.prototype.mb=function(){this.e=!0};pc.prototype.preventDefault=function(){this.hg=!1};function qc(b){b.mb()}function rc(b){b.preventDefault()};var sc=Bb?"focusout":"DOMFocusOut";function tc(b){tc[" "](b);return b}tc[" "]=ca;function uc(b,c){pc.call(this,b?b.type:"");this.relatedTarget=this.b=this.target=null;this.i=this.f=this.button=this.screenY=this.screenX=this.clientY=this.clientX=this.offsetY=this.offsetX=0;this.n=this.c=this.d=this.j=!1;this.state=null;this.g=!1;this.a=null;b&&vc(this,b,c)}v(uc,pc);var wc=[1,4,2]; -function vc(b,c,d){b.a=c;var e=b.type=c.type;b.target=c.target||c.srcElement;b.b=d;if(d=c.relatedTarget){if(Cb){var f;a:{try{tc(d.nodeName);f=!0;break a}catch(g){}f=!1}f||(d=null)}}else"mouseover"==e?d=c.fromElement:"mouseout"==e&&(d=c.toElement);b.relatedTarget=d;Object.defineProperties?Object.defineProperties(b,{offsetX:{configurable:!0,enumerable:!0,get:b.kf,set:b.Cl},offsetY:{configurable:!0,enumerable:!0,get:b.lf,set:b.Dl}}):(b.offsetX=b.kf(),b.offsetY=b.lf());b.clientX=void 0!==c.clientX?c.clientX: -c.pageX;b.clientY=void 0!==c.clientY?c.clientY:c.pageY;b.screenX=c.screenX||0;b.screenY=c.screenY||0;b.button=c.button;b.f=c.keyCode||0;b.i=c.charCode||("keypress"==e?c.keyCode:0);b.j=c.ctrlKey;b.d=c.altKey;b.c=c.shiftKey;b.n=c.metaKey;b.g=Eb?c.metaKey:c.ctrlKey;b.state=c.state;c.defaultPrevented&&b.preventDefault()}function xc(b){return(hc?0==b.a.button:"click"==b.type?!0:!!(b.a.button&wc[0]))&&!(Db&&Eb&&b.j)}l=uc.prototype; -l.mb=function(){uc.R.mb.call(this);this.a.stopPropagation?this.a.stopPropagation():this.a.cancelBubble=!0};l.preventDefault=function(){uc.R.preventDefault.call(this);var b=this.a;if(b.preventDefault)b.preventDefault();else if(b.returnValue=!1,jc)try{if(b.ctrlKey||112<=b.keyCode&&123>=b.keyCode)b.keyCode=-1}catch(c){}};l.oh=function(){return this.a};l.kf=function(){return Db||void 0!==this.a.offsetX?this.a.offsetX:this.a.layerX}; -l.Cl=function(b){Object.defineProperties(this,{offsetX:{writable:!0,enumerable:!0,configurable:!0,value:b}})};l.lf=function(){return Db||void 0!==this.a.offsetY?this.a.offsetY:this.a.layerY};l.Dl=function(b){Object.defineProperties(this,{offsetY:{writable:!0,enumerable:!0,configurable:!0,value:b}})};var yc="closure_listenable_"+(1E6*Math.random()|0);function zc(b){return!(!b||!b[yc])}var Ac=0;function Bc(b,c,d,e,f){this.Yb=b;this.a=null;this.src=c;this.type=d;this.wc=!!e;this.sd=f;this.key=++Ac;this.tc=this.Yc=!1}function Cc(b){b.tc=!0;b.Yb=null;b.a=null;b.src=null;b.sd=null};function Dc(b){this.src=b;this.a={};this.d=0}Dc.prototype.add=function(b,c,d,e,f){var g=b.toString();b=this.a[g];b||(b=this.a[g]=[],this.d++);var h=Ec(b,c,e,f);-1f.keyCode||void 0!=f.returnValue)){a:{var g=!1;if(0==f.keyCode)try{f.keyCode=-1;break a}catch(h){g=!0}if(g||void 0==f.returnValue)f.returnValue=!0}f=[];for(g=d.b;g;g=g.parentNode)f.push(g);for(var g=b.type,k=f.length-1;!d.e&&0<=k;k--){d.b=f[k];var n=Uc(f[k],g,!0,d),e=e&&n}for(k=0;!d.e&&k>>0);function Lc(b){if(ka(b))return b;b[Wc]||(b[Wc]=function(c){return b.handleEvent(c)});return b[Wc]};function Xc(b){return function(){return b}}var Yc=Xc(!1),Zc=Xc(!0),$c=Xc(null);function ad(b){return b}function bd(b){var c;c=c||0;return function(){return b.apply(this,Array.prototype.slice.call(arguments,0,c))}}function cd(b){var c=arguments,d=c.length;return function(){for(var b,f=0;f=d||(1<=d?(h=k,f=g):(h+=d*n,f+=d*p));return[h,f]}function wd(b,c){var d=Vb(b+180,360)-180,e=Math.abs(Math.round(3600*d));return Math.floor(e/3600)+"\u00b0 "+Math.floor(e/60%60)+"\u2032 "+Math.floor(e%60)+"\u2033 "+c.charAt(0>d?1:0)} -function xd(b,c,d){return m(b)?c.replace("{x}",b[0].toFixed(d)).replace("{y}",b[1].toFixed(d)):""}function yd(b,c){for(var d=!0,e=b.length-1;0<=e;--e)if(b[e]!=c[e]){d=!1;break}return d}function zd(b,c){var d=Math.cos(c),e=Math.sin(c),f=b[1]*d+b[0]*e;b[0]=b[0]*d-b[1]*e;b[1]=f;return b}function Ad(b,c){var d=b[0]-c[0],e=b[1]-c[1];return d*d+e*e}function Bd(b,c){return xd(b,"{x}, {y}",c)};function Cd(b){this.length=b.length||b;for(var c=0;ce&&(k=k|4);hf&&(k|=2);0===k&&(k=1);return k}function Rd(){return[Infinity,Infinity,-Infinity,-Infinity]}function Ud(b,c,d,e,f){return m(f)?(f[0]=b,f[1]=c,f[2]=d,f[3]=e,f):[b,c,d,e]} -function ae(b,c){var d=b[0],e=b[1];return Ud(d,e,d,e,c)}function be(b,c){return b[0]==c[0]&&b[2]==c[2]&&b[1]==c[1]&&b[3]==c[3]}function ce(b,c){c[0]b[2]&&(b[2]=c[2]);c[1]b[3]&&(b[3]=c[3]);return b}function Sd(b,c){c[0]b[2]&&(b[2]=c[0]);c[1]b[3]&&(b[3]=c[1])} -function de(b,c,d,e,f){for(;dg;++g)h=f[g],k=e[g],f[g]=b[0]+h*c-k*d,e[g]=b[1]+h*d+k*c;return Td(f,e,void 0)}function me(b){return b[3]-b[1]} -function ne(b,c,d){d=m(d)?d:Rd();oe(b,c)&&(d[0]=b[0]>c[0]?b[0]:c[0],d[1]=b[1]>c[1]?b[1]:c[1],d[2]=b[2]=c[0]&&b[1]<=c[3]&&b[3]>=c[1]}function qe(b){return b[2]this.F)}return m(b)?this.p+b:b};l.me=function(b,c){if(!qe(b)){this.Ra(ie(b));var d=this.n(b,c),e=this.constrainResolution(d,0,0);eb?af(2*b):1-af(2*(b-.5))};function df(b){var c=b.source,d=m(b.start)?b.start:ua(),e=c[0],f=c[1],g=m(b.duration)?b.duration:1E3,h=m(b.easing)?b.easing:af;return function(b,c){if(c.time>=1;return d.join("")}function kf(b){return hf(b[0],b[1],b[2])};function lf(b,c,d,e){this.a=b;this.c=c;this.b=d;this.d=e}function mf(b,c,d,e,f){return m(f)?(f.a=b,f.c=c,f.b=d,f.d=e,f):new lf(b,c,d,e)}lf.prototype.contains=function(b){return nf(this,b[1],b[2])};function of(b,c){return b.a<=c.a&&c.c<=b.c&&b.b<=c.b&&c.d<=b.d}function nf(b,c,d){return b.a<=c&&c<=b.c&&b.b<=d&&d<=b.d}function pf(b,c){return b.a==c.a&&b.b==c.b&&b.c==c.c&&b.d==c.d};function qf(b){this.d=b.html;this.a=m(b.tileRanges)?b.tileRanges:null}qf.prototype.b=function(){return this.d};var rf=!Bb||Bb&&9<=Pb;!Cb&&!Bb||Bb&&Bb&&9<=Pb||Cb&&Mb("1.9.1");Bb&&Mb("9");zb("area base br col command embed hr img input keygen link meta param source track wbr".split(" "));zb("action","cite","data","formaction","href","manifest","poster","src");zb("embed","iframe","link","object","script","style","template");function sf(b,c){this.x=m(b)?b:0;this.y=m(c)?c:0}l=sf.prototype;l.clone=function(){return new sf(this.x,this.y)};l.ceil=function(){this.x=Math.ceil(this.x);this.y=Math.ceil(this.y);return this};l.floor=function(){this.x=Math.floor(this.x);this.y=Math.floor(this.y);return this};l.round=function(){this.x=Math.round(this.x);this.y=Math.round(this.y);return this};l.scale=function(b,c){var d=ja(c)?c:b;this.x*=b;this.y*=d;return this};function tf(b,c){this.width=b;this.height=c}l=tf.prototype;l.clone=function(){return new tf(this.width,this.height)};l.la=function(){return!(this.width*this.height)};l.ceil=function(){this.width=Math.ceil(this.width);this.height=Math.ceil(this.height);return this};l.floor=function(){this.width=Math.floor(this.width);this.height=Math.floor(this.height);return this};l.round=function(){this.width=Math.round(this.width);this.height=Math.round(this.height);return this}; -l.scale=function(b,c){var d=ja(c)?c:b;this.width*=b;this.height*=d;return this};function uf(b){return b?new vf(wf(b)):ya||(ya=new vf)}function xf(b){var c=document;return ia(b)?c.getElementById(b):b}function yf(b,c){jb(c,function(c,e){"style"==e?b.style.cssText=c:"class"==e?b.className=c:"for"==e?b.htmlFor=c:e in zf?b.setAttribute(zf[e],c):0==e.lastIndexOf("aria-",0)||0==e.lastIndexOf("data-",0)?b.setAttribute(e,c):b[e]=c})} -var zf={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 Af(b){b=b.document.documentElement;return new tf(b.clientWidth,b.clientHeight)} -function Bf(b){var c=Db?b.body||b.documentElement:b.documentElement;b=b.parentWindow||b.defaultView;return Bb&&Mb("10")&&b.pageYOffset!=c.scrollTop?new sf(c.scrollLeft,c.scrollTop):new sf(b.pageXOffset||c.scrollLeft,b.pageYOffset||c.scrollTop)} -function Cf(b,c,d){var e=arguments,f=document,g=e[0],h=e[1];if(!rf&&h&&(h.name||h.type)){g=["<",g];h.name&&g.push(' name="',Ba(h.name),'"');if(h.type){g.push(' type="',Ba(h.type),'"');var k={};yb(k,h);delete k.type;h=k}g.push(">");g=g.join("")}g=f.createElement(g);h&&(ia(h)?g.className=h:ga(h)?g.className=h.join(" "):yf(g,h));2d;++d)e[d]=c[d].toFixed(6);d=e.join(",")}else d=c.join(",");Sf(b,"matrix3d("+d+")")}else if(Qf()){e=[c[0],c[1],c[4],c[5],c[12],c[13]];if(m(6)){var f=Array(6);for(d=0;6>d;++d)f[d]=e[d].toFixed(6);d=f.join(",")}else d=e.join(",");Sf(b,"matrix("+d+")")}else b.style.left=Math.round(c[12])+"px",b.style.top=Math.round(c[13])+"px"};var Uf=["experimental-webgl","webgl","webkit-3d","moz-webgl"];function Vf(b,c){var d,e,f=Uf.length;for(e=0;e=this.left&&b.right<=this.right&&b.top>=this.top&&b.bottom<=this.bottom:b.x>=this.left&&b.x<=this.right&&b.y>=this.top&&b.y<=this.bottom:!1}; -l.ceil=function(){this.top=Math.ceil(this.top);this.right=Math.ceil(this.right);this.bottom=Math.ceil(this.bottom);this.left=Math.ceil(this.left);return this};l.floor=function(){this.top=Math.floor(this.top);this.right=Math.floor(this.right);this.bottom=Math.floor(this.bottom);this.left=Math.floor(this.left);return this};l.round=function(){this.top=Math.round(this.top);this.right=Math.round(this.right);this.bottom=Math.round(this.bottom);this.left=Math.round(this.left);return this}; -l.scale=function(b,c){var d=ja(c)?c:b;this.left*=b;this.right*=b;this.top*=d;this.bottom*=d;return this};function Cg(b,c,d,e){this.left=b;this.top=c;this.width=d;this.height=e}l=Cg.prototype;l.clone=function(){return new Cg(this.left,this.top,this.width,this.height)};l.contains=function(b){return b instanceof Cg?this.left<=b.left&&this.left+this.width>=b.left+b.width&&this.top<=b.top&&this.top+this.height>=b.top+b.height:b.x>=this.left&&b.x<=this.left+this.width&&b.y>=this.top&&b.y<=this.top+this.height}; -function Dg(b,c){var d=c.x= -A.a&&D.b<=A.d&&D.d>=A.b){u=!0;break a}}u=!1}u?(k in s&&delete s[k],r[k]=h):s[k]=h}c=[r,s];d=c[0];c=c[1];for(var x in this.n)x in d?(this.e[x]||(Mg(this.n[x],!0),this.e[x]=!0),delete d[x]):x in c?(this.e[x]&&(Mg(this.n[x],!1),delete this.e[x]),delete c[x]):(Lf(this.n[x]),delete this.n[x],delete this.e[x]);for(x in d)p=Gf("LI"),p.innerHTML=d[x].d,this.r.appendChild(p),this.n[x]=p,this.e[x]=!0;for(x in c)p=Gf("LI"),p.innerHTML=c[x].d,Mg(p,!1),this.r.appendChild(p),this.n[x]=p;x=!rb(this.e)||!rb(b.logos); -this.q!=x&&(Mg(this.element,x),this.q=x);x&&rb(this.e)?yg(this.element,"ol-logo-only"):zg(this.element,"ol-logo-only");var T;b=b.logos;x=this.H;for(T in x)T in b||(Lf(x[T]),delete x[T]);for(var O in b)O in x||(T=new Image,T.src=O,d=b[O],""===d?d=T:(d=Cf("A",{href:d}),d.appendChild(T)),this.p.appendChild(d),x[O]=d);Mg(this.p,!rb(b))}}l=Vg.prototype;l.oj=function(b){b.preventDefault();Xg(this)};function Xg(b){Ag(b.element,"ol-collapsed");b.c?Mf(b.s,b.F):Mf(b.F,b.s);b.c=!b.c}l.nj=function(){return this.g}; -l.qj=function(b){this.g!==b&&(this.g=b,Ag(this.element,"ol-uncollapsible"),!b&&this.c&&Xg(this))};l.pj=function(b){this.g&&this.c!==b&&Xg(this)};l.mj=function(){return this.c};function Yg(b){b=m(b)?b:{};var c=m(b.className)?b.className:"ol-rotate",d=m(b.label)?b.label:"\u21e7";this.c=null;ia(d)?this.c=Cf("SPAN","ol-compass",d):(this.c=d,yg(this.c,"ol-compass"));d=Cf("BUTTON",{"class":c+"-reset",type:"button",title:m(b.tipLabel)?b.tipLabel:"Reset rotation"},this.c);w(d,"click",Yg.prototype.p,!1,this);w(d,["mouseout",sc],function(){this.blur()},!1);c=Cf("DIV",c+" ol-unselectable ol-control",d);Ug.call(this,{element:c,render:m(b.render)?b.render:Zg,target:b.target});this.g= -m(b.duration)?b.duration:250;this.e=m(b.autoHide)?b.autoHide:!0;this.n=void 0;this.e&&yg(this.element,"ol-hidden")}v(Yg,Ug);Yg.prototype.p=function(b){b.preventDefault();b=this.a;var c=b.a();if(null!==c){for(var d=c.c();d<-Math.PI;)d+=2*Math.PI;for(;d>Math.PI;)d-=2*Math.PI;m(d)&&(02*this.b&&vh(this),!0):!1};function vh(b){if(b.b!=b.a.length){for(var c=0,d=0;c=b||96<=b&&106>=b||65<=b&&90>=b||Db&&0==b)return!0;switch(b){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!0;default:return!1}}function Bh(b){if(Cb)b=Ch(b);else if(Eb&&Db)a:switch(b){case 93:b=91;break a}return b} -function Ch(b){switch(b){case 61:return 187;case 59:return 186;case 173:return 189;case 224:return 91;case 0:return 224;default:return b}};function Dh(b,c){ed.call(this);b&&Eh(this,b,c)}v(Dh,ed);l=Dh.prototype;l.aa=null;l.ud=null;l.te=null;l.vd=null;l.Na=-1;l.Gb=-1;l.ge=!1; -var Fh={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},Gh={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},Hh=Bb||Db&&Mb("525"),Ih=Eb&&Cb; -Dh.prototype.a=function(b){Db&&(17==this.Na&&!b.j||18==this.Na&&!b.d||Eb&&91==this.Na&&!b.n)&&(this.Gb=this.Na=-1);-1==this.Na&&(b.j&&17!=b.f?this.Na=17:b.d&&18!=b.f?this.Na=18:b.n&&91!=b.f&&(this.Na=91));Hh&&!zh(b.f,this.Na,b.c,b.j,b.d)?this.handleEvent(b):(this.Gb=Bh(b.f),Ih&&(this.ge=b.d))};Dh.prototype.d=function(b){this.Gb=this.Na=-1;this.ge=b.d}; -Dh.prototype.handleEvent=function(b){var c=b.a,d,e,f=c.altKey;Bb&&"keypress"==b.type?(d=this.Gb,e=13!=d&&27!=d?c.keyCode:0):Db&&"keypress"==b.type?(d=this.Gb,e=0<=c.charCode&&63232>c.charCode&&Ah(d)?c.charCode:0):Ab?(d=this.Gb,e=Ah(d)?c.keyCode:0):(d=c.keyCode||this.Gb,e=c.charCode||0,Ih&&(f=this.ge),Eb&&63==e&&224==d&&(d=191));var g=d=Bh(d),h=c.keyIdentifier;d?63232<=d&&d in Fh?g=Fh[d]:25==d&&b.c&&(g=9):h&&h in Gh&&(g=Gh[h]);this.Na=g;b=new Kh(g,e,0,c);b.d=f;this.dispatchEvent(b)}; -function Eh(b,c,d){b.vd&&Lh(b);b.aa=c;b.ud=w(b.aa,"keypress",b,d);b.te=w(b.aa,"keydown",b.a,d,b);b.vd=w(b.aa,"keyup",b.d,d,b)}function Lh(b){b.ud&&(Tc(b.ud),Tc(b.te),Tc(b.vd),b.ud=null,b.te=null,b.vd=null);b.aa=null;b.Na=-1;b.Gb=-1}Dh.prototype.M=function(){Dh.R.M.call(this);Lh(this)};function Kh(b,c,d,e){uc.call(this,e);this.type="key";this.f=b;this.i=c}v(Kh,uc);function Mh(b,c){ed.call(this);var d=this.aa=b;(d=la(d)&&1==d.nodeType?this.aa:this.aa?this.aa.body:null)&&Fg(d,"direction");this.a=w(this.aa,Cb?"DOMMouseScroll":"mousewheel",this,c)}v(Mh,ed); -Mh.prototype.handleEvent=function(b){var c=0,d=0,e=0;b=b.a;if("mousewheel"==b.type){d=1;if(Bb||Db&&(Fb||Mb("532.0")))d=40;e=Nh(-b.wheelDelta,d);m(b.wheelDeltaX)?(c=Nh(-b.wheelDeltaX,d),d=Nh(-b.wheelDeltaY,d)):d=e}else e=b.detail,100e&&(e=-3),m(b.axis)&&b.axis===b.HORIZONTAL_AXIS?c=e:d=e;ja(this.d)&&Ub(c,-this.d,this.d);ja(this.b)&&(d=Ub(d,-this.b,this.b));c=new Oh(e,b,0,d);this.dispatchEvent(c)};function Nh(b,c){return Db&&(Eb||Hb)&&0!=b%c?b:b/c} -Mh.prototype.M=function(){Mh.R.M.call(this);Tc(this.a);this.a=null};function Oh(b,c,d,e){uc.call(this,c);this.type="mousewheel";this.detail=b;this.l=e}v(Oh,uc);function Ph(b,c,d){pc.call(this,b);this.a=c;b=m(d)?d:{};this.buttons=Qh(b);this.pressure=Rh(b,this.buttons);this.bubbles=ub(b,"bubbles",!1);this.cancelable=ub(b,"cancelable",!1);this.view=ub(b,"view",null);this.detail=ub(b,"detail",null);this.screenX=ub(b,"screenX",0);this.screenY=ub(b,"screenY",0);this.clientX=ub(b,"clientX",0);this.clientY=ub(b,"clientY",0);this.button=ub(b,"button",0);this.relatedTarget=ub(b,"relatedTarget",null);this.pointerId=ub(b,"pointerId",0);this.width=ub(b,"width",0);this.height= -ub(b,"height",0);this.pointerType=ub(b,"pointerType","");this.isPrimary=ub(b,"isPrimary",!1);c.preventDefault&&(this.preventDefault=function(){c.preventDefault()})}v(Ph,pc);function Qh(b){if(b.buttons||Sh)b=b.buttons;else switch(b.which){case 1:b=1;break;case 2:b=4;break;case 3:b=2;break;default:b=0}return b}function Rh(b,c){var d=0;b.pressure?d=b.pressure:d=c?.5:0;return d}var Sh=!1;try{Sh=1===(new MouseEvent("click",{buttons:1})).buttons}catch(Th){};function Uh(b,c){this.a=b;this.f=c};function Vh(b){Uh.call(this,b,{mousedown:this.Ii,mousemove:this.Ji,mouseup:this.Mi,mouseover:this.Li,mouseout:this.Ki});this.d=b.d;this.b=[]}v(Vh,Uh);function Wh(b,c){for(var d=b.b,e=c.clientX,f=c.clientY,g=0,h=d.length,k;g=Math.abs(e-k[0])&&25>=n)return!0}return!1}function Xh(b){var c=Yh(b,b.a),d=c.preventDefault;c.preventDefault=function(){b.preventDefault();d()};c.pointerId=1;c.isPrimary=!0;c.pointerType="mouse";return c}l=Vh.prototype; -l.Ii=function(b){if(!Wh(this,b)){(1).toString()in this.d&&this.cancel(b);var c=Xh(b);this.d[(1).toString()]=b;Zh(this.a,$h,c,b)}};l.Ji=function(b){if(!Wh(this,b)){var c=Xh(b);Zh(this.a,ai,c,b)}};l.Mi=function(b){if(!Wh(this,b)){var c=this.d[(1).toString()];c&&c.button===b.button&&(c=Xh(b),Zh(this.a,bi,c,b),tb(this.d,(1).toString()))}};l.Li=function(b){if(!Wh(this,b)){var c=Xh(b);ci(this.a,c,b)}};l.Ki=function(b){if(!Wh(this,b)){var c=Xh(b);di(this.a,c,b)}}; -l.cancel=function(b){var c=Xh(b);this.a.cancel(c,b);tb(this.d,(1).toString())};function ei(b){Uh.call(this,b,{MSPointerDown:this.Ri,MSPointerMove:this.Si,MSPointerUp:this.Vi,MSPointerOut:this.Ti,MSPointerOver:this.Ui,MSPointerCancel:this.Qi,MSGotPointerCapture:this.Oi,MSLostPointerCapture:this.Pi});this.d=b.d;this.b=["","unavailable","touch","pen","mouse"]}v(ei,Uh);function fi(b,c){var d=c;ja(c.a.pointerType)&&(d=Yh(c,c.a),d.pointerType=b.b[c.a.pointerType]);return d}l=ei.prototype;l.Ri=function(b){this.d[b.a.pointerId]=b;var c=fi(this,b);Zh(this.a,$h,c,b)}; -l.Si=function(b){var c=fi(this,b);Zh(this.a,ai,c,b)};l.Vi=function(b){var c=fi(this,b);Zh(this.a,bi,c,b);tb(this.d,b.a.pointerId)};l.Ti=function(b){var c=fi(this,b);di(this.a,c,b)};l.Ui=function(b){var c=fi(this,b);ci(this.a,c,b)};l.Qi=function(b){var c=fi(this,b);this.a.cancel(c,b);tb(this.d,b.a.pointerId)};l.Pi=function(b){this.a.dispatchEvent(new Ph("lostpointercapture",b,b.a))};l.Oi=function(b){this.a.dispatchEvent(new Ph("gotpointercapture",b,b.a))};function gi(b){Uh.call(this,b,{pointerdown:this.Sk,pointermove:this.Tk,pointerup:this.Wk,pointerout:this.Uk,pointerover:this.Vk,pointercancel:this.Rk,gotpointercapture:this.Yh,lostpointercapture:this.Hi})}v(gi,Uh);l=gi.prototype;l.Sk=function(b){hi(this.a,b)};l.Tk=function(b){hi(this.a,b)};l.Wk=function(b){hi(this.a,b)};l.Uk=function(b){hi(this.a,b)};l.Vk=function(b){hi(this.a,b)};l.Rk=function(b){hi(this.a,b)};l.Hi=function(b){hi(this.a,b)};l.Yh=function(b){hi(this.a,b)};function ii(b,c){Uh.call(this,b,{touchstart:this.Ql,touchmove:this.Pl,touchend:this.Ol,touchcancel:this.Nl});this.d=b.d;this.g=c;this.b=void 0;this.e=0;this.c=void 0}v(ii,Uh);l=ii.prototype;l.gg=function(){this.e=0;this.c=void 0}; -function ji(b,c,d){c=Yh(c,d);c.pointerId=d.identifier+2;c.bubbles=!0;c.cancelable=!0;c.detail=b.e;c.button=0;c.buttons=1;c.width=d.webkitRadiusX||d.radiusX||0;c.height=d.webkitRadiusY||d.radiusY||0;c.pressure=d.webkitForce||d.force||.5;c.isPrimary=b.b===d.identifier;c.pointerType="touch";c.clientX=d.clientX;c.clientY=d.clientY;c.screenX=d.screenX;c.screenY=d.screenY;return c} -function ki(b,c,d){function e(){c.preventDefault()}var f=Array.prototype.slice.call(c.a.changedTouches),g=f.length,h,k;for(h=0;h=c.length){var f=[],g,h,k;for(g=0;g=b.minResolution&&c=this.minZoom;){if(c.call(d,b,Ui(this,f,b,e)))return!0;--b}return!1};l.gd=function(){return this.maxZoom}; -l.hd=function(){return this.minZoom};l.Lb=function(b){return null===this.c?this.e[b]:this.c};l.na=function(b){return this.a[b]};l.Kd=function(){return this.a};l.md=function(b,c,d){return b[0]b.c&&(b.c=e.c),e.bb.d&&(b.d=e.d)):b[c][d]=e:(b[c]={},b[c][d]=e)} -function jj(b,c,d,e){return function(f,g,h){f=c.Fb(f,g,h,d,e);return b(f)?f:null}}function kj(b,c,d){return[c*(Math.round(b[0]/c)+d[0]%2/2),c*(Math.round(b[1]/c)+d[1]%2/2)]} -function lj(b,c,d,e,f,g,h,k,n,p){var q=ma(c).toString();q in b.wantedTiles||(b.wantedTiles[q]={});var r=b.wantedTiles[q];b=b.tileQueue;var s=d.minZoom,u,y,A,z,D,x;for(x=h;x>=s;--x)for(y=Ui(d,g,x,y),A=d.na(x),z=y.a;z<=y.c;++z)for(D=y.b;D<=y.d;++D)h-x<=k?(u=c.Fb(x,z,D,e,f),0==u.state&&(r[kf(u.a)]=!0,u.nb()in b.b||mj(b,[u,q,Xi(d,u.a),A])),m(n)&&n.call(p,u)):c.Oe(x,z,D)};function nj(b){this.p=b.opacity;this.q=b.rotateWithView;this.i=b.rotation;this.n=b.scale;this.r=b.snapToPixel}l=nj.prototype;l.Fd=function(){return this.p};l.kd=function(){return this.q};l.Gd=function(){return this.i};l.Hd=function(){return this.n};l.ld=function(){return this.r};l.Id=function(b){this.i=b};l.Jd=function(b){this.n=b};function oj(b){b=m(b)?b:{};this.f=m(b.anchor)?b.anchor:[.5,.5];this.c=null;this.d=m(b.anchorOrigin)?b.anchorOrigin:"top-left";this.g=m(b.anchorXUnits)?b.anchorXUnits:"fraction";this.j=m(b.anchorYUnits)?b.anchorYUnits:"fraction";var c=m(b.crossOrigin)?b.crossOrigin:null,d=m(b.img)?b.img:null,e=b.src;m(e)&&0!==e.length||null===d||(e=d.src);var f=m(b.src)?0:2,g=pj.Ma(),h=g.get(e,c);null===h&&(h=new qj(d,e,c,f),g.set(e,c,h));this.a=h;this.s=m(b.offset)?b.offset:[0,0];this.b=m(b.offsetOrigin)?b.offsetOrigin: -"top-left";this.e=null;this.l=m(b.size)?b.size:null;nj.call(this,{opacity:m(b.opacity)?b.opacity:1,rotation:m(b.rotation)?b.rotation:0,scale:m(b.scale)?b.scale:1,snapToPixel:m(b.snapToPixel)?b.snapToPixel:!0,rotateWithView:m(b.rotateWithView)?b.rotateWithView:!1})}v(oj,nj);l=oj.prototype; -l.ub=function(){if(null!==this.c)return this.c;var b=this.f,c=this.cb();if("fraction"==this.g||"fraction"==this.j){if(null===c)return null;b=this.f.slice();"fraction"==this.g&&(b[0]*=c[0]);"fraction"==this.j&&(b[1]*=c[1])}if("top-left"!=this.d){if(null===c)return null;b===this.f&&(b=this.f.slice());if("top-right"==this.d||"bottom-right"==this.d)b[0]=-b[0]+c[0];if("bottom-left"==this.d||"bottom-right"==this.d)b[1]=-b[1]+c[1]}return this.c=b};l.zb=function(){return this.a.a};l.ed=function(){return this.a.d}; -l.Jc=function(){return this.a.b};l.Ed=function(){var b=this.a;if(null===b.f)if(b.j){var c=b.d[0],d=b.d[1],e=Pf(c,d);e.fillRect(0,0,c,d);b.f=e.canvas}else b.f=b.a;return b.f};l.Ab=function(){if(null!==this.e)return this.e;var b=this.s;if("top-left"!=this.b){var c=this.cb(),d=this.a.d;if(null===c||null===d)return null;b=b.slice();if("top-right"==this.b||"bottom-right"==this.b)b[0]=d[0]-c[0]-b[0];if("bottom-left"==this.b||"bottom-right"==this.b)b[1]=d[1]-c[1]-b[1]}return this.e=b};l.hk=function(){return this.a.e}; -l.cb=function(){return null===this.l?this.a.d:this.l};l.ve=function(b,c){return w(this.a,"change",b,!1,c)};l.load=function(){this.a.load()};l.Ne=function(b,c){Sc(this.a,"change",b,!1,c)};function qj(b,c,d,e){ed.call(this);this.f=null;this.a=null===b?new Image:b;null!==d&&(this.a.crossOrigin=d);this.c=null;this.b=e;this.d=null;this.e=c;this.j=!1}v(qj,ed);qj.prototype.g=function(){this.b=3;Oa(this.c,Tc);this.c=null;this.dispatchEvent("change")}; -qj.prototype.i=function(){this.b=2;this.d=[this.a.width,this.a.height];Oa(this.c,Tc);this.c=null;var b=Pf(1,1);b.drawImage(this.a,0,0);try{b.getImageData(0,0,1,1)}catch(c){this.j=!0}this.dispatchEvent("change")};qj.prototype.load=function(){if(0==this.b){this.b=1;this.c=[Rc(this.a,"error",this.g,!1,this),Rc(this.a,"load",this.i,!1,this)];try{this.a.src=this.e}catch(b){this.g()}}};function pj(){this.a={};this.d=0}da(pj);pj.prototype.clear=function(){this.a={};this.d=0}; -pj.prototype.get=function(b,c){var d=c+":"+b;return d in this.a?this.a[d]:null};pj.prototype.set=function(b,c,d){this.a[c+":"+b]=d;++this.d};function rj(b,c,d,e,f,g,h,k){Kd(b);0===c&&0===d||Nd(b,c,d);1==e&&1==f||Od(b,e,f);0!==g&&Pd(b,g);0===h&&0===k||Nd(b,h,k);return b}function sj(b,c){return b[0]==c[0]&&b[1]==c[1]&&b[4]==c[4]&&b[5]==c[5]&&b[12]==c[12]&&b[13]==c[13]}function tj(b,c,d){var e=b[1],f=b[5],g=b[13],h=c[0];c=c[1];d[0]=b[0]*h+b[4]*c+b[12];d[1]=e*h+f*c+g;return d};function uj(b,c){kc.call(this);this.b=c;this.c=null;this.g={}}v(uj,kc);function vj(b){var c=b.viewState,d=b.coordinateToPixelMatrix;rj(d,b.size[0]/2,b.size[1]/2,1/c.resolution,-1/c.resolution,-c.rotation,-c.center[0],-c.center[1]);Md(d,b.pixelToCoordinateMatrix)}l=uj.prototype;l.$c=function(b){return new cj(this,b)};l.M=function(){jb(this.g,oc);uj.R.M.call(this)}; -function wj(){var b=pj.Ma();if(32>1;){var n=2*c+1,p=2*c+2,n=pc;){var h=d-1>>1;if(b[h]>g)e[d]=e[h],b[d]=b[h],d=h;else break}e[d]=f;b[d]=g}function Dj(b){var c=b.e,d=b.a,e=b.d,f=0,g=d.length,h,k,n;for(k=0;k>1)-1;0<=c;c--)Bj(b,c)};function Ej(b,c){zj.call(this,function(c){return b.apply(null,c)},function(b){return b[0].nb()});this.j=c;this.c=0}v(Ej,zj);Ej.prototype.g=function(){--this.c;this.j()};function Fj(b,c,d){this.c=b;this.b=c;this.e=d;this.a=[];this.d=this.f=0}Fj.prototype.update=function(b,c){this.a.push(b,c,ua())};function Gj(b,c){var d=b.c,e=b.d,f=b.b-e,g=Hj(b);return df({source:c,duration:g,easing:function(b){return e*(Math.exp(d*b*g)-1)/f}})}function Hj(b){return Math.log(b.b/b.d)/b.c};function Ij(b){od.call(this);this.n=null;this.b(!0);this.handleEvent=b.handleEvent}v(Ij,od);Ij.prototype.a=function(){return this.get("active")};Ij.prototype.getActive=Ij.prototype.a;Ij.prototype.b=function(b){this.set("active",b)};Ij.prototype.setActive=Ij.prototype.b;Ij.prototype.setMap=function(b){this.n=b};function Jj(b,c,d,e,f){if(null!=d){var g=c.c(),h=c.b();m(g)&&m(h)&&m(f)&&0d.a.length)d=!1;else{var e=ua()-d.e,f=d.a.length-3;if(d.a[f+2]e;)g-=3;var e=d.a[f+2]-d.a[g+2],h=d.a[f]-d.a[g],f=d.a[f+1]-d.a[g+1];d.f=Math.atan2(f,h);d.d=Math.sqrt(h*h+f*f)/e;d=d.d>d.b}}d&&(d=this.c,d=(d.b-d.d)/d.c,f=this.c.f,g=c.b(),this.g=Gj(this.c,g),b.Wa(this.g),g=b.e(g),d=b.ia([g[0]-d*Math.cos(f),g[1]-d*Math.sin(f)]),d=c.i(d),c.Ra(d));Ze(c,-1);b.render(); -return!1}this.e=null;return!0}function Zj(b){if(0b||0!==this.g&&b<=this.g)return this;var c=b.toString();if(this.e.hasOwnProperty(c))return this.e[c];var d=this.mc(b);if(d.k.lengthf&&(f=g);g=k;h=n}return f}function sk(b,c,d,e,f){var g,h;g=0;for(h=d.length;gk){for(;cu&&(p=q,u=x)}u>f&&(n[(p-c)/e]=1,s+eV&&JbV)&&(0>ta&&Qata)||(A[h++]=x,A[h++]=T,z=x,D=T);x=O;T=W}}A[h++]=x;A[h++]=T}}k.push(h);c=q}return h};function Ck(b,c){ik.call(this);this.b=this.j=-1;this.V(b,c)}v(Ck,ik);l=Ck.prototype;l.clone=function(){var b=new Ck(null);Dk(b,this.a,this.k.slice());return b};l.Xa=function(b,c,d,e){if(eg!=q>g&&f<(p-k)*(g-n)/(q-n)+k&&(h=!h);k=p;n=q}return h}function Ik(b,c,d,e,f,g){if(0===d.length||!Hk(b,c,d[0],e,f,g))return!1;var h;c=1;for(h=d.length;cr&&(p=(p+q)/2,Ik(b,c,d,e,p,s)&&(y=p,r=A));p=q}isNaN(y)&&(y=f[g]);return m(h)?(h.push(y,s),h):[y,s]};function Kk(b,c,d,e,f){for(var g=[b[c],b[c+1]],h=[],k;c+e=f[0]&&g[2]<=f[2]||g[1]>=f[1]&&g[3]<=f[3]?!0:Kk(b,c,d,e,function(b,c){var d=!1,e=$d(f,b),g=$d(f,c);if(1===e||1===g)d=!0;else{var r=f[0],s=f[1],u=f[2],y=f[3],A=c[0],z=c[1],D=(z-b[1])/(A-b[0]);g&2&&!(e&2)?(s=A-(z-y)/D,d=s>=r&&s<=u):g&4&&!(e&4)?(r=z-(A-u)*D,d=r>=s&&r<=y):g&8&&!(e&8)?(s=A-(z-s)/D,d=s>=r&&s<=u):g&16&&!(e&16)&&(r=z-(A-r)*D,d=r>=s&&r<=y)}return d}):!1} -function Mk(b,c,d,e,f){var g=d[0];if(!(Lk(b,c,g,e,f)||Hk(b,c,g,e,f[0],f[1])||Hk(b,c,g,e,f[0],f[3])||Hk(b,c,g,e,f[2],f[1])||Hk(b,c,g,e,f[2],f[3])))return!1;if(1===d.length)return!0;c=1;for(g=d.length;cb||this.b.length<=b)return null;var c=new Ck(null);Dk(c,this.a,this.k.slice(0===b?0:this.b[b-1],this.b[b]));return c};l.fd=function(){var b=this.a,c=this.k,d=this.b,e=[],f=0,g,h;g=0;for(h=d.length;gf;++f)e[f]=c.charCodeAt(d++)|c.charCodeAt(d++)<<8|c.charCodeAt(d++)<<16|c.charCodeAt(d++)<<24;else for(f=0;16>f;++f)e[f]=c[d++]|c[d++]<<8|c[d++]<<16|c[d++]<<24;c=b.a[0];d=b.a[1];var f=b.a[2],g=b.a[3],h=0,h=c+(g^d&(f^g))+e[0]+3614090360&4294967295;c=d+(h<<7&4294967295|h>>>25);h=g+(f^c&(d^f))+e[1]+3905402710&4294967295;g=c+(h<<12&4294967295|h>>>20);h=f+(d^g&(c^d))+e[2]+606105819&4294967295;f=g+(h<<17&4294967295|h>>>15);h=d+(c^f&(g^ -c))+e[3]+3250441966&4294967295;d=f+(h<<22&4294967295|h>>>10);h=c+(g^d&(f^g))+e[4]+4118548399&4294967295;c=d+(h<<7&4294967295|h>>>25);h=g+(f^c&(d^f))+e[5]+1200080426&4294967295;g=c+(h<<12&4294967295|h>>>20);h=f+(d^g&(c^d))+e[6]+2821735955&4294967295;f=g+(h<<17&4294967295|h>>>15);h=d+(c^f&(g^c))+e[7]+4249261313&4294967295;d=f+(h<<22&4294967295|h>>>10);h=c+(g^d&(f^g))+e[8]+1770035416&4294967295;c=d+(h<<7&4294967295|h>>>25);h=g+(f^c&(d^f))+e[9]+2336552879&4294967295;g=c+(h<<12&4294967295|h>>>20);h=f+ -(d^g&(c^d))+e[10]+4294925233&4294967295;f=g+(h<<17&4294967295|h>>>15);h=d+(c^f&(g^c))+e[11]+2304563134&4294967295;d=f+(h<<22&4294967295|h>>>10);h=c+(g^d&(f^g))+e[12]+1804603682&4294967295;c=d+(h<<7&4294967295|h>>>25);h=g+(f^c&(d^f))+e[13]+4254626195&4294967295;g=c+(h<<12&4294967295|h>>>20);h=f+(d^g&(c^d))+e[14]+2792965006&4294967295;f=g+(h<<17&4294967295|h>>>15);h=d+(c^f&(g^c))+e[15]+1236535329&4294967295;d=f+(h<<22&4294967295|h>>>10);h=c+(f^g&(d^f))+e[1]+4129170786&4294967295;c=d+(h<<5&4294967295| -h>>>27);h=g+(d^f&(c^d))+e[6]+3225465664&4294967295;g=c+(h<<9&4294967295|h>>>23);h=f+(c^d&(g^c))+e[11]+643717713&4294967295;f=g+(h<<14&4294967295|h>>>18);h=d+(g^c&(f^g))+e[0]+3921069994&4294967295;d=f+(h<<20&4294967295|h>>>12);h=c+(f^g&(d^f))+e[5]+3593408605&4294967295;c=d+(h<<5&4294967295|h>>>27);h=g+(d^f&(c^d))+e[10]+38016083&4294967295;g=c+(h<<9&4294967295|h>>>23);h=f+(c^d&(g^c))+e[15]+3634488961&4294967295;f=g+(h<<14&4294967295|h>>>18);h=d+(g^c&(f^g))+e[4]+3889429448&4294967295;d=f+(h<<20&4294967295| -h>>>12);h=c+(f^g&(d^f))+e[9]+568446438&4294967295;c=d+(h<<5&4294967295|h>>>27);h=g+(d^f&(c^d))+e[14]+3275163606&4294967295;g=c+(h<<9&4294967295|h>>>23);h=f+(c^d&(g^c))+e[3]+4107603335&4294967295;f=g+(h<<14&4294967295|h>>>18);h=d+(g^c&(f^g))+e[8]+1163531501&4294967295;d=f+(h<<20&4294967295|h>>>12);h=c+(f^g&(d^f))+e[13]+2850285829&4294967295;c=d+(h<<5&4294967295|h>>>27);h=g+(d^f&(c^d))+e[2]+4243563512&4294967295;g=c+(h<<9&4294967295|h>>>23);h=f+(c^d&(g^c))+e[7]+1735328473&4294967295;f=g+(h<<14&4294967295| -h>>>18);h=d+(g^c&(f^g))+e[12]+2368359562&4294967295;d=f+(h<<20&4294967295|h>>>12);h=c+(d^f^g)+e[5]+4294588738&4294967295;c=d+(h<<4&4294967295|h>>>28);h=g+(c^d^f)+e[8]+2272392833&4294967295;g=c+(h<<11&4294967295|h>>>21);h=f+(g^c^d)+e[11]+1839030562&4294967295;f=g+(h<<16&4294967295|h>>>16);h=d+(f^g^c)+e[14]+4259657740&4294967295;d=f+(h<<23&4294967295|h>>>9);h=c+(d^f^g)+e[1]+2763975236&4294967295;c=d+(h<<4&4294967295|h>>>28);h=g+(c^d^f)+e[4]+1272893353&4294967295;g=c+(h<<11&4294967295|h>>>21);h=f+(g^ -c^d)+e[7]+4139469664&4294967295;f=g+(h<<16&4294967295|h>>>16);h=d+(f^g^c)+e[10]+3200236656&4294967295;d=f+(h<<23&4294967295|h>>>9);h=c+(d^f^g)+e[13]+681279174&4294967295;c=d+(h<<4&4294967295|h>>>28);h=g+(c^d^f)+e[0]+3936430074&4294967295;g=c+(h<<11&4294967295|h>>>21);h=f+(g^c^d)+e[3]+3572445317&4294967295;f=g+(h<<16&4294967295|h>>>16);h=d+(f^g^c)+e[6]+76029189&4294967295;d=f+(h<<23&4294967295|h>>>9);h=c+(d^f^g)+e[9]+3654602809&4294967295;c=d+(h<<4&4294967295|h>>>28);h=g+(c^d^f)+e[12]+3873151461&4294967295; -g=c+(h<<11&4294967295|h>>>21);h=f+(g^c^d)+e[15]+530742520&4294967295;f=g+(h<<16&4294967295|h>>>16);h=d+(f^g^c)+e[2]+3299628645&4294967295;d=f+(h<<23&4294967295|h>>>9);h=c+(f^(d|~g))+e[0]+4096336452&4294967295;c=d+(h<<6&4294967295|h>>>26);h=g+(d^(c|~f))+e[7]+1126891415&4294967295;g=c+(h<<10&4294967295|h>>>22);h=f+(c^(g|~d))+e[14]+2878612391&4294967295;f=g+(h<<15&4294967295|h>>>17);h=d+(g^(f|~c))+e[5]+4237533241&4294967295;d=f+(h<<21&4294967295|h>>>11);h=c+(f^(d|~g))+e[12]+1700485571&4294967295;c=d+ -(h<<6&4294967295|h>>>26);h=g+(d^(c|~f))+e[3]+2399980690&4294967295;g=c+(h<<10&4294967295|h>>>22);h=f+(c^(g|~d))+e[10]+4293915773&4294967295;f=g+(h<<15&4294967295|h>>>17);h=d+(g^(f|~c))+e[1]+2240044497&4294967295;d=f+(h<<21&4294967295|h>>>11);h=c+(f^(d|~g))+e[8]+1873313359&4294967295;c=d+(h<<6&4294967295|h>>>26);h=g+(d^(c|~f))+e[15]+4264355552&4294967295;g=c+(h<<10&4294967295|h>>>22);h=f+(c^(g|~d))+e[6]+2734768916&4294967295;f=g+(h<<15&4294967295|h>>>17);h=d+(g^(f|~c))+e[13]+1309151649&4294967295; -d=f+(h<<21&4294967295|h>>>11);h=c+(f^(d|~g))+e[4]+4149444226&4294967295;c=d+(h<<6&4294967295|h>>>26);h=g+(d^(c|~f))+e[11]+3174756917&4294967295;g=c+(h<<10&4294967295|h>>>22);h=f+(c^(g|~d))+e[2]+718787259&4294967295;f=g+(h<<15&4294967295|h>>>17);h=d+(g^(f|~c))+e[9]+3951481745&4294967295;b.a[0]=b.a[0]+c&4294967295;b.a[1]=b.a[1]+(f+(h<<21&4294967295|h>>>11))&4294967295;b.a[2]=b.a[2]+f&4294967295;b.a[3]=b.a[3]+g&4294967295} -dl.prototype.update=function(b,c){m(c)||(c=b.length);for(var d=c-this.d,e=this.f,f=this.b,g=0;gc.b?c.d:2*c.d)-c.b);d[0]=128;for(b=1;bb;++b)for(var f=0;32>f;f+=8)d[e++]=c.a[b]>>>f&255; -if(8192>d.length)c=String.fromCharCode.apply(null,d);else for(c="",b=0;bthis.l&&(this.c=!0));this.g=d;b=b.map;d=Jg(b.b);e=Xj(this.f);e[0]-=d.x;e[1]-=d.y;this.e=b.ia(e);this.c&&(d=b.a(),e=d.c(),b.render(),Jj(b,d,e+c,this.e))}function Bl(b){if(2>this.f.length){b=b.map;var c=b.a();Ze(c,-1);if(this.c){var d=c.c(),e=this.e,d=c.constrainRotation(d,0);Jj(b,c,d,e,250)}return!1}return!0} -function zl(b){return 2<=this.f.length?(b=b.map,this.e=null,this.g=void 0,this.c=!1,this.i=0,this.p||Ze(b.a(),1),b.render(),!0):!1}yl.prototype.q=Yc;function Cl(b){Vj.call(this,{handleDownEvent:Dl,handleDragEvent:El,handleUpEvent:Fl});b=m(b)?b:{};this.e=null;this.i=m(b.duration)?b.duration:400;this.c=void 0;this.g=1}v(Cl,Vj);function El(b){var c=1,d=this.f[0],e=this.f[1],f=d.clientX-e.clientX,d=d.clientY-e.clientY,f=Math.sqrt(f*f+d*d);m(this.c)&&(c=this.c/f);this.c=f;1!=c&&(this.g=c);b=b.map;var f=b.a(),d=f.a(),e=Jg(b.b),g=Xj(this.f);g[0]-=e.x;g[1]-=e.y;this.e=b.ia(g);b.render();Lj(b,f,d*c,this.e)} -function Fl(b){if(2>this.f.length){b=b.map;var c=b.a();Ze(c,-1);var d=c.a(),e=this.e,f=this.i,d=c.constrainResolution(d,0,this.g-1);Lj(b,c,d,e,f);return!1}return!0}function Dl(b){return 2<=this.f.length?(b=b.map,this.e=null,this.c=void 0,this.g=1,this.p||Ze(b.a(),1),b.render(),!0):!1}Cl.prototype.q=Yc;function Gl(b){b=m(b)?b:{};var c=new C,d=new Fj(-.005,.05,100);(m(b.altShiftDragRotate)?b.altShiftDragRotate:1)&&c.push(new ck);(m(b.doubleClickZoom)?b.doubleClickZoom:1)&&c.push(new Mj({delta:b.zoomDelta,duration:b.zoomDuration}));(m(b.dragPan)?b.dragPan:1)&&c.push(new Yj({kinetic:d}));(m(b.pinchRotate)?b.pinchRotate:1)&&c.push(new yl);(m(b.pinchZoom)?b.pinchZoom:1)&&c.push(new Cl({duration:b.zoomDuration}));if(m(b.keyboard)?b.keyboard:1)c.push(new sl),c.push(new ul({delta:b.zoomDelta,duration:b.zoomDuration})); -(m(b.mouseWheelZoom)?b.mouseWheelZoom:1)&&c.push(new wl({duration:b.zoomDuration}));(m(b.shiftDragZoom)?b.shiftDragZoom:1)&&c.push(new rl);return c};function H(b){var c=m(b)?b:{};b=wb(c);delete b.layers;c=c.layers;E.call(this,b);this.a=null;w(this,sd("layers"),this.ni,!1,this);null!=c?ga(c)&&(c=new C(c.slice())):c=new C;this.r(c)}v(H,E);l=H.prototype;l.of=function(){this.b()&&this.o()}; -l.ni=function(){null!==this.a&&(Oa(mb(this.a),Tc),this.a=null);var b=this.Zb();if(null!=b){this.a={add:w(b,"add",this.mi,!1,this),remove:w(b,"remove",this.oi,!1,this)};var b=b.a,c,d,e;c=0;for(d=b.length;cthis.f&&(this.f=this.b.lineWidth,this.c=null)}; -function mm(b,c,d){cm.call(this,b,c,d);this.b={bf:void 0,Dc:void 0,yc:void 0,zc:null,Ac:void 0,Bc:void 0,Cc:void 0,fillStyle:void 0,strokeStyle:void 0,lineCap:void 0,lineDash:null,lineJoin:void 0,lineWidth:void 0,miterLimit:void 0}}v(mm,cm); -function nm(b,c,d,e,f){var g=b.b,h=[1];b.d.push(h);b.a.push(h);var k,h=0;for(k=e.length;hthis.f&&(this.f=d.lineWidth,this.c=null))}; -function om(b){var c=b.b,d=c.fillStyle,e=c.strokeStyle,f=c.lineCap,g=c.lineDash,h=c.lineJoin,k=c.lineWidth,n=c.miterLimit;m(d)&&c.bf!=d&&(b.d.push([9,d]),c.bf=c.fillStyle);!m(e)||c.Dc==e&&c.yc==f&&c.zc==g&&c.Ac==h&&c.Bc==k&&c.Cc==n||(b.d.push([10,e,k,f,h,n,g]),c.Dc=e,c.yc=f,c.zc=g,c.Ac=h,c.Bc=k,c.Cc=n)}function pm(b,c,d){cm.call(this,b,c,d);this.s=this.r=this.q=null;this.j="";this.p=this.l=this.n=this.i=0;this.g=this.e=this.b=null}v(pm,cm); -pm.prototype.tb=function(b,c,d,e,f,g){if(""!==this.j&&null!==this.g&&(null!==this.b||null!==this.e)){if(null!==this.b){f=this.b;var h=this.q;if(null===h||h.fillStyle!=f.fillStyle){var k=[9,f.fillStyle];this.d.push(k);this.a.push(k);null===h?this.q={fillStyle:f.fillStyle}:h.fillStyle=f.fillStyle}}null!==this.e&&(f=this.e,h=this.r,null===h||h.lineCap!=f.lineCap||h.lineDash!=f.lineDash||h.lineJoin!=f.lineJoin||h.lineWidth!=f.lineWidth||h.miterLimit!=f.miterLimit||h.strokeStyle!=f.strokeStyle)&&(k=[10, -f.strokeStyle,f.lineWidth,f.lineCap,f.lineJoin,f.miterLimit,f.lineDash,!1],this.d.push(k),this.a.push(k),null===h?this.r={lineCap:f.lineCap,lineDash:f.lineDash,lineJoin:f.lineJoin,lineWidth:f.lineWidth,miterLimit:f.miterLimit,strokeStyle:f.strokeStyle}:(h.lineCap=f.lineCap,h.lineDash=f.lineDash,h.lineJoin=f.lineJoin,h.lineWidth=f.lineWidth,h.miterLimit=f.miterLimit,h.strokeStyle=f.strokeStyle));f=this.g;h=this.s;if(null===h||h.font!=f.font||h.textAlign!=f.textAlign||h.textBaseline!=f.textBaseline)k= -[11,f.font,f.textAlign,f.textBaseline],this.d.push(k),this.a.push(k),null===h?this.s={font:f.font,textAlign:f.textAlign,textBaseline:f.textBaseline}:(h.font=f.font,h.textAlign=f.textAlign,h.textBaseline=f.textBaseline);em(this,g);f=this.coordinates.length;b=dm(this,b,c,d,e,!1);b=[5,f,b,this.j,this.i,this.n,this.l,this.p,null!==this.b,null!==this.e];this.d.push(b);this.a.push(b);hm(this,g)}}; -pm.prototype.Aa=function(b){if(null===b)this.j="";else{var c=b.a;null===c?this.b=null:(c=c.a,c=sg(null===c?gl:c),null===this.b?this.b={fillStyle:c}:this.b.fillStyle=c);var d=b.e;if(null===d)this.e=null;else{var c=d.a,e=d.c,f=d.b,g=d.f,h=d.d,d=d.e,e=m(e)?e:"round",f=null!=f?f.slice():hl,g=m(g)?g:"round",h=m(h)?h:1,d=m(d)?d:10,c=sg(null===c?il:c);if(null===this.e)this.e={lineCap:e,lineDash:f,lineJoin:g,lineWidth:h,miterLimit:d,strokeStyle:c};else{var k=this.e;k.lineCap=e;k.lineDash=f;k.lineJoin=g;k.lineWidth= -h;k.miterLimit=d;k.strokeStyle=c}}var n=b.c,c=b.i,e=b.n,f=b.f,h=b.d,d=b.b,g=b.g,k=b.j;b=m(n)?n:"10px sans-serif";g=m(g)?g:"center";k=m(k)?k:"middle";null===this.g?this.g={font:b,textAlign:g,textBaseline:k}:(n=this.g,n.font=b,n.textAlign=g,n.textBaseline=k);this.j=m(d)?d:"";this.i=m(c)?c:0;this.n=m(e)?e:0;this.l=m(f)?f:0;this.p=m(h)?h:1}};function qm(b,c,d,e){this.i=b;this.c=c;this.j=d;this.f=e;this.d={};this.e=Pf(1,1);this.g=Gd()} -function rm(b){for(var c in b.d){var d=b.d[c],e;for(e in d)d[e].Kb()}}qm.prototype.b=function(b,c,d,e,f){var g=this.g;rj(g,.5,.5,1/c,-1/c,-d,-b[0],-b[1]);var h=this.e;h.clearRect(0,0,1,1);var k;m(this.f)&&(k=Rd(),Sd(k,b),Vd(k,c*this.f,k));return sm(this,h,g,d,e,function(b){if(0b||0!==this.g&&b>1,q=h(d,g[p]),0s?(d=(d-g[-s-2])/(g[-s-1]-g[-s-2]),c+=(-s-2)*e,g=Wb(b[c],b[c+e],d),h=Wb(b[c+1],b[c+e+1],d)):(g=b[c+s*e],h=b[c+s*e+1])}return null!=f? -(f[0]=g,f[1]=h,f):[g,h]}function Hm(b,c,d,e,f,g){if(d==c)return null;if(f>1,fb||this.b.length<=b)return null;var c=new L(null);Jm(c,this.a,this.k.slice(0===b?0:this.b[b-1],this.b[b]));return c};l.Gc=function(){var b=this.k,c=this.b,d=this.a,e=[],f=0,g,h;g=0;for(h=c.length;gb||c<=b)return null;c=new Ek(null);Fk(c,this.a,this.k.slice(b*this.t,(b+1)*this.t));return c};l.zd=function(){var b=this.k,c=this.a,d=this.t,e=[],f,g;f=0;for(g=b.length;fb||this.b.length<=b)return null;var c;0===b?c=0:(c=this.b[b-1],c=c[c.length-1]);b=this.b[b].slice();var d=b[b.length-1];if(0!==c){var e,f;e=0;for(f=b.length;e=b[0]&&c[3]>=b[1]}function r(b,c,d,e,f){for(var g=[c,d],h;g.length;)d=g.pop(),c=g.pop(),d-c<=e||(h=c+Math.ceil((d-c)/e/2)*e,s(b,c,d,h,f),g.push(c,h,h,d))}function s(b,c,d,e,f){for(var g,h,k,n,p;d>c;){600h-g/2?-1:1),k=Math.max(c,Math.floor(e-h*n/g+p)),h=Math.min(d,Math.floor(e+(g-h)*n/g+p)),s(b,k,h,e,f));g=b[e];h=c;n=d;u(b,c,e);for(0f(b[h],g);)h++;for(;0this.fe)this.Yg(e,c),c--;else break;this.Sg(d,e,c)},Yg:function(b,c){var e=b[c],f=e.children.length,g=this.Xe;this.Tg(e,g,f);f={children:e.children.splice(this.Ug(e,g,f)),height:e.height};e.xa&&(f.xa=!0);d(e,this.Ia);d(f,this.Ia);c?b[c-1].children.push(f):this.Ye(e, -f)},Ye:function(b,c){this.data={children:[b,c],height:b.height+1};d(this.data,this.Ia)},Ug:function(b,c,d){var f,g,h,n,p,q,r;p=q=Infinity;for(f=c;f<=d-c;f++){g=e(b,0,f,this.Ia);h=e(b,f,d,this.Ia);var s=g,u=h;n=Math.max(s[0],u[0]);var Sb=Math.max(s[1],u[1]),Gb=Math.min(s[2],u[2]),s=Math.min(s[3],u[3]);n=Math.max(0,Gb-n)*Math.max(0,s-Sb);g=k(g)+k(h);n=c;q--)r=b.children[q],f(k,b.xa?g(r):r.bbox),p+=n(k);return p},Sg:function(b,c,d){for(;0<=d;d--)f(c[d].bbox,b)},Wg:function(b){for(var c=b.length-1,e;0<=c;c--)0===b[c].children.length?0z||this.b[1]>D)?(x.width=z,x.height=D,this.b=[z,D],this.i=!zm(this.b),this.c=null):(z=this.b[0],D=this.b[1],p==this.p&&of(this.c,A)||(this.c=null)));var O,W;null===this.c?(z/=q,D/=q,O=A.a-Math.floor((z-(A.c-A.a+1))/2),W=A.b-Math.floor((D-(A.d-A.b+1))/2),this.p=p,this.c=new lf(O,O+z-1,W,W+D-1),this.j=Array(z*D),D=this.c):(D=this.c,z=D.c-D.a+1);x={};x[p]={};var V=[],ta=ra(h.le,h,x,jj(function(b){return null!==b&&2==b.state},h,d,f)),Jb=g.da(),Qa=Rd(),Sb=new lf(0,0,0,0),Gb,La,Tb; -for(W=A.a;W<=A.c;++W)for(Tb=A.b;Tb<=A.d;++Tb)La=h.Fb(p,W,Tb,d,f),O=La.state,2==O||4==O||3==O&&!Jb?x[p][kf(La.a)]=La:(Gb=k.bd(La.a,ta,null,Sb,Qa),Gb||(V.push(La),Gb=k.md(La.a,Sb,Qa),null===Gb||ta(p+1,Gb)));ta=0;for(Gb=V.length;taV&&Kf(this.target,A.target,0)}else b.viewHints[0]||b.viewHints[1]||An(A,s,D);else Lf(A.target),delete this.b[V];c.opacity!=this.i&&(this.i=this.target.style.opacity=c.opacity);c.visible&&!this.c&&(Mg(this.target,!0),this.c=!0);ij(b.usedTiles,h,p,q);lj(b,h,k,d,f,s,p,g.r());fj(b,h);hj(b,h);return!0}; -function wn(b,c){this.target=Gf("DIV");this.target.style.position="absolute";this.target.style.width="100%";this.target.style.height="100%";this.c=b;this.b=c;this.e=ke(Ti(b,c));this.g=b.na(c[0]);this.d={};this.a=null;this.f=Id()} -function xn(b,c,d){var e=c.a,f=e[0],g=e[1],h=e[2],e=kf(e);if(!(e in b.d)){var f=b.c.va(f),k=c.Qa(b),n=k.style;n.maxWidth="none";var p,q;0=k;){n=this.b[p];u=this.n[p];x=ma(u).toString();if(!m(r[x])&&(!m(y)||oe(y,u.N().D()))&&(g.clear(g.COLOR_BUFFER_BIT|g.DEPTH_BUFFER_BIT),g.drawElements(4,q-n,e,n*b),q=s(u))){r=q;break a}q=n;p--}r=void 0}else g.clear(g.COLOR_BUFFER_BIT|g.DEPTH_BUFFER_BIT),ao(this,g,b,r,this.g,this.e),r=(r=s(null))?r:void 0;x=r}else ao(this,g,b,r,this.ha,this.p);g.disableVertexAttribArray(z.c); -g.disableVertexAttribArray(z.a);g.disableVertexAttribArray(z.f);g.disableVertexAttribArray(z.d);g.disableVertexAttribArray(z.b);return x}; -function ao(b,c,d,e,f,g){var h=d.b?5125:5123;d=d.b?4:2;if(rb(e)){var k;b=0;e=f.length;for(k=0;bc[0]||c[0]>f[0]||0>c[1]||c[1]>f[1])&& -(null===this.e&&(this.e=Pf(1,1)),this.e.clearRect(0,0,1,1),this.e.drawImage(this.b.a(),c[0],c[1],1,1,0,0,1,1),0.75*f||c.height>.75*e?Po(this):Yd(d,b)||(b=this.c,d=this.a.a(),b.a().Ra(d.b()))}Qo(this)}l.Bf=function(){Oo(this)};function Po(b){var c=b.a;b=b.c;var d=c.f(),c=c.a().g(d),d=b.f();b=b.a();var e=Math.log(7.5)/Math.LN2;re(c,1/(.1*Math.pow(2,e/2)));b.me(c,d)} -function Qo(b){var c=b.a,d=b.c;if(null!==c.c&&null!==d.c){var e=c.f(),f=c.a(),g=d.a();d.f();var c=f.c(),h=b.n,d=b.n.c(),f=f.g(e),e=g.a(),g=fe(f),f=he(f),k;b=b.a.a().b();m(b)&&(k=[g[0]-b[0],g[1]-b[1]],zd(k,c),ud(k,b));h.e(k);null!=d&&(k=new tf(Math.abs((g[0]-f[0])/e),Math.abs((f[1]-g[1])/e)),uf(wf(d)),!Bb||Mb("10")||Mb("8")?(d=d.style,Cb?d.MozBoxSizing="border-box":Db?d.WebkitBoxSizing="border-box":d.boxSizing="border-box",d.width=Math.max(k.width,0)+"px",d.height=Math.max(k.height,0)+"px"):(b=d.style, -c=Pg(d,"padding"),d=Sg(d),b.pixelWidth=k.width-d.left-c.left-c.right-d.right,b.pixelHeight=k.height-d.top-c.top-c.bottom-d.bottom))}}l.tj=function(b){b.preventDefault();Ro(this)};function Ro(b){Ag(b.element,"ol-collapsed");b.e?Mf(b.p,b.q):Mf(b.q,b.p);b.e=!b.e;var c=b.c;b.e||null!==c.c||(c.l(),Po(b),Rc(c,"postrender",function(){Qo(this)},!1,b))}l.sj=function(){return this.g};l.vj=function(b){this.g!==b&&(this.g=b,Ag(this.element,"ol-uncollapsible"),!b&&this.e&&Ro(this))}; -l.uj=function(b){this.g&&this.e!==b&&Ro(this)};l.rj=function(){return this.e};function So(b){b=m(b)?b:{};var c=m(b.className)?b.className:"ol-scale-line";this.g=Cf("DIV",c+"-inner");this.aa=Cf("DIV",c+" ol-unselectable",this.g);this.r=null;this.n=m(b.minWidth)?b.minWidth:64;this.c=!1;this.F=void 0;this.s="";this.e=null;Ug.call(this,{element:this.aa,render:m(b.render)?b.render:To,target:b.target});w(this,sd("units"),this.H,!1,this);this.q(b.units||"metric")}v(So,Ug);var Uo=[1,2,5];So.prototype.p=function(){return this.get("units")};So.prototype.getUnits=So.prototype.p; -function To(b){b=b.frameState;null===b?this.r=null:this.r=b.viewState;Vo(this)}So.prototype.H=function(){Vo(this)};So.prototype.q=function(b){this.set("units",b)};So.prototype.setUnits=So.prototype.q; -function Vo(b){var c=b.r;if(null===c)b.c&&(Mg(b.aa,!1),b.c=!1);else{var d=c.center,e=c.projection,c=e.re(c.resolution,d),f=e.d,g=b.p();"degrees"!=f||"metric"!=g&&"imperial"!=g&&"us"!=g&&"nautical"!=g?"ft"!=f&&"m"!=f||"degrees"!=g?b.e=null:(null===b.e&&(b.e=Ae(e,Be("EPSG:4326"))),d=Math.cos(Xb(b.e(d)[1])),e=ve.radius,"ft"==f&&(e/=.3048),c*=180/(Math.PI*d*e)):(b.e=null,d=Math.cos(Xb(d[1])),c*=Math.PI*d*ve.radius/180);d=b.n*c;f="";"degrees"==g?d<1/60?(f="\u2033",c*=3600):1>d?(f="\u2032",c*=60):f="\u00b0": -"imperial"==g?.9144>d?(f="in",c/=.0254):1609.344>d?(f="ft",c/=.3048):(f="mi",c/=1609.344):"nautical"==g?(c/=1852,f="nm"):"metric"==g?1>d?(f="mm",c*=1E3):1E3>d?f="m":(f="km",c/=1E3):"us"==g&&(.9144>d?(f="in",c*=39.37):1609.344>d?(f="ft",c/=.30480061):(f="mi",c/=1609.3472));for(d=3*Math.floor(Math.log(b.n*c)/Math.log(10));;){e=Uo[d%3]*Math.pow(10,Math.floor(d/3));g=Math.round(e/c);if(isNaN(g)){Mg(b.aa,!1);b.c=!1;return}if(g>=b.n)break;++d}c=e+" "+f;b.s!=c&&(b.g.innerHTML=c,b.s=c);b.F!=g&&(b.g.style.width= -g+"px",b.F=g);b.c||(Mg(b.aa,!0),b.c=!0)}};function Wo(b){kc.call(this);this.d=b;this.a={}}v(Wo,kc);var Xo=[];Wo.prototype.Oa=function(b,c,d,e){ga(c)||(c&&(Xo[0]=c.toString()),c=Xo);for(var f=0;fd.height?(this.g=1,d=new Cg(0,0,e,0)):(this.g=hp,d=new Cg(0,0,0,c));this.c.a=d||new Cg(NaN,NaN,NaN,NaN);this.p=!0}b=b.frameState.viewState.resolution;b!==this.e&&(this.e=b,b=1-We(this.a.a())(b),d=this.c,c=Nf(this.element),1==this.g?Gg(c,d.a.left+d.a.width*b):Gg(c, -d.a.left,d.a.top+d.a.height*b))}}l.Zh=function(b){var c=this.a,d=c.a(),e=d.a();c.Wa(ff({resolution:e,duration:200,easing:$e}));b=jp(this,b.offsetX-this.n[0]/2,b.offsetY-this.n[1]/2);b=kp(this,b);d.f(d.constrainResolution(b))};l.bi=function(){Ze(this.a.a(),1)};l.$h=function(b){b=jp(this,b.left,b.top);this.e=kp(this,b);this.a.a().f(this.e)};l.ai=function(){var b=this.a,c=b.a();Ze(c,-1);b.Wa(ff({resolution:this.e,duration:200,easing:$e}));b=c.constrainResolution(this.e);c.f(b)}; -function jp(b,c,d){var e=b.c.a;return Ub(1===b.g?(c-e.left)/e.width:(d-e.top)/e.height,0,1)}function kp(b,c){return Ve(b.a.a())(1-c)};function lp(b){b=m(b)?b:{};this.c=m(b.extent)?b.extent:null;var c=m(b.className)?b.className:"ol-zoom-extent",d=Cf("BUTTON",{type:"button",title:m(b.tipLabel)?b.tipLabel:"Fit to extent"},m(b.label)?b.label:"E");w(d,"click",this.e,!1,this);w(d,["mouseout",sc],function(){this.blur()},!1);c=Cf("DIV",c+" ol-unselectable ol-control",d);Ug.call(this,{element:c,target:b.target})}v(lp,Ug); -lp.prototype.e=function(b){b.preventDefault();var c=this.a;b=c.a();var d=null===this.c?b.q.D():this.c,c=c.f();b.me(d,c)};function mp(b){od.call(this);b=m(b)?b:{};this.a=null;w(this,sd("tracking"),this.n,!1,this);this.b(m(b.tracking)?b.tracking:!1)}v(mp,od);mp.prototype.M=function(){this.b(!1);mp.R.M.call(this)}; -mp.prototype.l=function(b){b=b.a;if(null!=b.alpha){var c=Xb(b.alpha);this.set("alpha",c);"boolean"==typeof b.absolute&&b.absolute?this.set("heading",c):null!=b.webkitCompassHeading&&null!=b.webkitCompassAccuracy&&-1!=b.webkitCompassAccuracy&&this.set("heading",Xb(b.webkitCompassHeading))}null!=b.beta&&this.set("beta",Xb(b.beta));null!=b.gamma&&this.set("gamma",Xb(b.gamma));this.o()};mp.prototype.f=function(){return this.get("alpha")};mp.prototype.getAlpha=mp.prototype.f;mp.prototype.e=function(){return this.get("beta")}; -mp.prototype.getBeta=mp.prototype.e;mp.prototype.g=function(){return this.get("gamma")};mp.prototype.getGamma=mp.prototype.g;mp.prototype.i=function(){return this.get("heading")};mp.prototype.getHeading=mp.prototype.i;mp.prototype.c=function(){return this.get("tracking")};mp.prototype.getTracking=mp.prototype.c;mp.prototype.n=function(){if(ag){var b=this.c();b&&null===this.a?this.a=w(ba,"deviceorientation",this.l,!1,this):b||null===this.a||(Tc(this.a),this.a=null)}}; -mp.prototype.b=function(b){this.set("tracking",b)};mp.prototype.setTracking=mp.prototype.b;function np(b){od.call(this);this.i=b;w(this.i,["change","input"],this.g,!1,this);w(this,sd("value"),this.n,!1,this);w(this,sd("checked"),this.e,!1,this)}v(np,od);np.prototype.a=function(){return this.get("checked")};np.prototype.getChecked=np.prototype.a;np.prototype.b=function(){return this.get("value")};np.prototype.getValue=np.prototype.b;np.prototype.f=function(b){this.set("value",b)};np.prototype.setValue=np.prototype.f;np.prototype.c=function(b){this.set("checked",b)}; -np.prototype.setChecked=np.prototype.c;np.prototype.g=function(){var b=this.i;"checkbox"===b.type||"radio"===b.type?this.c(b.checked):this.f(b.value)};np.prototype.e=function(){this.i.checked=this.a()};np.prototype.n=function(){this.i.value=this.b()};function P(b){od.call(this);this.X=void 0;this.b="geometry";this.g=null;this.a=void 0;this.e=null;w(this,sd(this.b),this.rd,!1,this);m(b)&&(b instanceof gk||null===b?this.Pa(b):this.G(b))}v(P,od);P.prototype.clone=function(){var b=new P(this.L());b.f(this.b);var c=this.N();null!=c&&b.Pa(c.clone());c=this.g;null===c||b.i(c);return b};P.prototype.N=function(){return this.get(this.b)};P.prototype.getGeometry=P.prototype.N;l=P.prototype;l.wh=function(){return this.X};l.vh=function(){return this.b}; -l.cj=function(){return this.g};l.dj=function(){return this.a};l.ii=function(){this.o()};l.rd=function(){null!==this.e&&(Tc(this.e),this.e=null);var b=this.N();null!=b&&(this.e=w(b,"change",this.ii,!1,this),this.o())};l.Pa=function(b){this.set(this.b,b)};P.prototype.setGeometry=P.prototype.Pa;P.prototype.i=function(b){this.g=b;null===b?b=void 0:ka(b)||(b=ga(b)?b:[b],b=Xc(b));this.a=b;this.o()};P.prototype.c=function(b){this.X=b;this.o()}; -P.prototype.f=function(b){Sc(this,sd(this.b),this.rd,!1,this);this.b=b;w(this,sd(this.b),this.rd,!1,this);this.rd()};function op(b){b=m(b)?b:{};this.g=this.f=this.c=this.d=this.b=this.a=null;this.e=void 0;this.Af(m(b.style)?b.style:pl);m(b.features)?ga(b.features)?this.Nc(new C(b.features.slice())):this.Nc(b.features):this.Nc(new C);m(b.map)&&this.setMap(b.map)}l=op.prototype;l.yf=function(b){this.a.push(b)};l.Xi=function(){return this.a};l.Yi=function(){return this.c};l.zf=function(){pp(this)};l.gi=function(b){b=b.element;this.d[ma(b).toString()]=w(b,"change",this.zf,!1,this);pp(this)}; -l.hi=function(b){b=ma(b.element).toString();Tc(this.d[b]);delete this.d[b];pp(this)};l.aj=function(){pp(this)};l.bj=function(b){if(null!==this.a){var c=this.e;m(c)||(c=pl);var d=b.a;b=b.frameState;var e=b.viewState.resolution,f=Sm(e,b.pixelRatio),g,h,k,n;this.a.forEach(function(b){n=b.a;k=m(n)?n.call(b,e):c(b,e);if(null!=k)for(h=k.length,g=0;gd?b[1]="?":d==c.length-1&&(b[1]=void 0)}return b.join("")} -function Ir(b,c,d){if(ga(c))for(var e=0;ec)throw Error("Bad port number "+c);b.sc=c}else b.sc=null}function Nr(b,c,d){c instanceof Pr?(b.a=c,Vr(b.a,b.Wb)):(d||(c=Qr(c,Wr)),b.a=new Pr(c,0,b.Wb))}function Xr(b){return b instanceof Kr?b.clone():new Kr(b,void 0)} -function Yr(b,c){b instanceof Kr||(b=Xr(b));c instanceof Kr||(c=Xr(c));var d=b,e=c,f=d.clone(),g=!!e.Pb;g?Lr(f,e.Pb):g=!!e.ec;g?f.ec=e.ec:g=!!e.qb;g?f.qb=e.qb:g=null!=e.sc;var h=e.ob;if(g)Mr(f,e.sc);else if(g=!!e.ob)if("/"!=h.charAt(0)&&(d.qb&&!d.ob?h="/"+h:(d=f.ob.lastIndexOf("/"),-1!=d&&(h=f.ob.substr(0,d+1)+h))),d=h,".."==d||"."==d)h="";else if(-1!=d.indexOf("./")||-1!=d.indexOf("/.")){for(var h=0==d.lastIndexOf("/",0),d=d.split("/"),k=[],n=0;n>4&15).toString(16)+(b&15).toString(16)} -var Rr=/[#\/\?@]/g,Tr=/[\#\?:]/g,Sr=/[\#\?]/g,Wr=/[\#\?@]/g,Ur=/#/g;function Pr(b,c,d){this.a=b||null;this.d=!!d}function $r(b){b.fa||(b.fa=new uh,b.wa=0,b.a&&Gr(b.a,function(c,d){b.add(decodeURIComponent(c.replace(/\+/g," ")),d)}))}l=Pr.prototype;l.fa=null;l.wa=null;l.Tb=function(){$r(this);return this.wa};l.add=function(b,c){$r(this);this.a=null;b=as(this,b);var d=this.fa.get(b);d||this.fa.set(b,d=[]);d.push(c);this.wa++;return this}; -l.remove=function(b){$r(this);b=as(this,b);return wh(this.fa.d,b)?(this.a=null,this.wa-=this.fa.get(b).length,this.fa.remove(b)):!1};l.clear=function(){this.fa=this.a=null;this.wa=0};l.la=function(){$r(this);return 0==this.wa};function bs(b,c){$r(b);c=as(b,c);return wh(b.fa.d,c)}l.J=function(){$r(this);for(var b=this.fa.lb(),c=this.fa.J(),d=[],e=0;ee;++e){var f=parseInt(d[e],10).toString(16);d[e]=1==f.length?"0"+f:f}Dq(b,d.join(""))} -function dt(b,c,d){qq({node:b},et,ft,[c],d)}function gt(b,c,d){var e={node:b};null!=c.X&&b.setAttribute("id",c.X);b=c.L();var f=c.a;m(f)&&(f=f.call(c,0),null!==f&&0f?~(f<<1):f<<1;d="";e=0;for(f=b.length;e>=5;h=g+63;k+=String.fromCharCode(h);d+=k}return d} -function qu(b,c){var d=m(c)?c:1E5,e=[],f=0,g=0,h,k;h=0;for(k=b.length;hn?(e.push(f),g=f=0):g+=5}f=0;for(g=e.length;f>1):h>>1;f=0;for(g=e.length;f=b||"."==b&&!d} -function Su(b){var c=b.d.charAt(++b.a),d={position:b.a,value:c};if("("==c)d.type=2;else if(","==c)d.type=5;else if(")"==c)d.type=3;else if(Uu(c)||"-"==c){d.type=4;var e,c=b.a,f=!1;do"."==e&&(f=!0),e=b.d.charAt(++b.a);while(Uu(e,f));b=parseFloat(b.d.substring(c,b.a--));d.value=b}else if("a"<=c&&"z">=c||"A"<=c&&"Z">=c){d.type=1;c=b.a;do e=b.d.charAt(++b.a);while("a"<=e&&"z">=e||"A"<=e&&"Z">=e);b=b.d.substring(c,b.a--).toUpperCase();d.value=b}else{if(" "==c||"\t"==c||"\r"==c||"\n"==c)return Su(b);if(""=== -c)d.type=6;else throw Error("Unexpected character: "+c);}return d}function Qu(b){this.d=b}l=Qu.prototype;l.match=function(b){if(b=this.a.type==b)this.a=Su(this.d);return b}; -function Tu(b){var c=b.a;if(b.match(1)){var d=c.value;if("GEOMETRYCOLLECTION"==d){a:{if(b.match(2)){c=[];do c.push(Tu(b));while(b.match(5));if(b.match(3)){b=c;break a}}else if(Vu(b)){b=[];break a}throw Error(Wu(b));}return new Cm(b)}var e=Xu[d],c=Yu[d];if(!m(e)||!m(c))throw Error("Invalid geometry type: "+d);b=e.call(b);return new c(b)}throw Error(Wu(b));}l.De=function(){if(this.match(2)){var b=Zu(this);if(this.match(3))return b}else if(Vu(this))return null;throw Error(Wu(this));}; -l.Ce=function(){if(this.match(2)){var b=$u(this);if(this.match(3))return b}else if(Vu(this))return[];throw Error(Wu(this));};l.Ee=function(){if(this.match(2)){var b=av(this);if(this.match(3))return b}else if(Vu(this))return[];throw Error(Wu(this));};l.Pk=function(){if(this.match(2)){var b;if(2==this.a.type)for(b=[this.De()];this.match(5);)b.push(this.De());else b=$u(this);if(this.match(3))return b}else if(Vu(this))return[];throw Error(Wu(this));}; -l.Ok=function(){if(this.match(2)){var b=av(this);if(this.match(3))return b}else if(Vu(this))return[];throw Error(Wu(this));};l.Qk=function(){if(this.match(2)){for(var b=[this.Ee()];this.match(5);)b.push(this.Ee());if(this.match(3))return b}else if(Vu(this))return[];throw Error(Wu(this));};function Zu(b){for(var c=[],d=0;2>d;++d){var e=b.a;if(b.match(4))c.push(e.value);else break}if(2==c.length)return c;throw Error(Wu(b));}function $u(b){for(var c=[Zu(b)];b.match(5);)c.push(Zu(b));return c} -function av(b){for(var c=[b.Ce()];b.match(5);)c.push(b.Ce());return c}function Vu(b){var c=1==b.a.type&&"EMPTY"==b.a.value;c&&(b.a=Su(b.d));return c}function Wu(b){return"Unexpected `"+b.a.value+"` at position "+b.a.position+" in `"+b.d.d+"`"}var Yu={POINT:Ek,LINESTRING:L,POLYGON:G,MULTIPOINT:Nm,MULTILINESTRING:Km,MULTIPOLYGON:Om},Xu={POINT:Qu.prototype.De,LINESTRING:Qu.prototype.Ce,POLYGON:Qu.prototype.Ee,MULTIPOINT:Qu.prototype.Pk,MULTILINESTRING:Qu.prototype.Ok,MULTIPOLYGON:Qu.prototype.Qk};function bv(){this.version=void 0}v(bv,Vt);bv.prototype.d=function(b){for(b=b.firstChild;null!==b;b=b.nextSibling)if(1==b.nodeType)return this.a(b);return null};bv.prototype.a=function(b){this.version=Aa(b.getAttribute("version"));b=U({version:this.version},cv,b,[]);return m(b)?b:null};function dv(b,c){return U({},ev,b,c)}function fv(b,c){return U({},gv,b,c)}function hv(b,c){var d=dv(b,c);if(m(d)){var e=[Bq(b.getAttribute("width")),Bq(b.getAttribute("height"))];d.size=e;return d}} -function iv(b,c){return U([],jv,b,c)} -var kv=[null,"http://www.opengis.net/wms"],cv=R(kv,{Service:Q(function(b,c){return U({},lv,b,c)}),Capability:Q(function(b,c){return U({},mv,b,c)})}),mv=R(kv,{Request:Q(function(b,c){return U({},nv,b,c)}),Exception:Q(function(b,c){return U([],ov,b,c)}),Layer:Q(function(b,c){return U({},pv,b,c)})}),lv=R(kv,{Name:Q(X),Title:Q(X),Abstract:Q(X),KeywordList:Q(iv),OnlineResource:Q(Ut),ContactInformation:Q(function(b,c){return U({},qv,b,c)}),Fees:Q(X),AccessConstraints:Q(X),LayerLimit:Q(Aq),MaxWidth:Q(Aq), -MaxHeight:Q(Aq)}),qv=R(kv,{ContactPersonPrimary:Q(function(b,c){return U({},rv,b,c)}),ContactPosition:Q(X),ContactAddress:Q(function(b,c){return U({},sv,b,c)}),ContactVoiceTelephone:Q(X),ContactFacsimileTelephone:Q(X),ContactElectronicMailAddress:Q(X)}),rv=R(kv,{ContactPerson:Q(X),ContactOrganization:Q(X)}),sv=R(kv,{AddressType:Q(X),Address:Q(X),City:Q(X),StateOrProvince:Q(X),PostCode:Q(X),Country:Q(X)}),ov=R(kv,{Format:gq(X)}),pv=R(kv,{Name:Q(X),Title:Q(X),Abstract:Q(X),KeywordList:Q(iv),CRS:iq(X), -EX_GeographicBoundingBox:Q(function(b,c){var d=U({},tv,b,c);if(m(d)){var e=d.westBoundLongitude,f=d.southBoundLatitude,g=d.eastBoundLongitude,d=d.northBoundLatitude;return m(e)&&m(f)&&m(g)&&m(d)?[e,f,g,d]:void 0}}),BoundingBox:iq(function(b){var c=[zq(b.getAttribute("minx")),zq(b.getAttribute("miny")),zq(b.getAttribute("maxx")),zq(b.getAttribute("maxy"))],d=[zq(b.getAttribute("resx")),zq(b.getAttribute("resy"))];return{crs:b.getAttribute("CRS"),extent:c,res:d}}),Dimension:iq(function(b){return{name:b.getAttribute("name"), -units:b.getAttribute("units"),unitSymbol:b.getAttribute("unitSymbol"),"default":b.getAttribute("default"),multipleValues:wq(b.getAttribute("multipleValues")),nearestValue:wq(b.getAttribute("nearestValue")),current:wq(b.getAttribute("current")),values:X(b)}}),Attribution:Q(function(b,c){return U({},uv,b,c)}),AuthorityURL:iq(function(b,c){var d=dv(b,c);if(m(d))return d.name=b.getAttribute("name"),d}),Identifier:iq(X),MetadataURL:iq(function(b,c){var d=dv(b,c);if(m(d))return d.type=b.getAttribute("type"), -d}),DataURL:iq(dv),FeatureListURL:iq(dv),Style:iq(function(b,c){return U({},vv,b,c)}),MinScaleDenominator:Q(yq),MaxScaleDenominator:Q(yq),Layer:iq(function(b,c){var d=c[c.length-1],e=U({},pv,b,c);if(m(e)){var f=wq(b.getAttribute("queryable"));m(f)||(f=d.queryable);e.queryable=m(f)?f:!1;f=Bq(b.getAttribute("cascaded"));m(f)||(f=d.cascaded);e.cascaded=f;f=wq(b.getAttribute("opaque"));m(f)||(f=d.opaque);e.opaque=m(f)?f:!1;f=wq(b.getAttribute("noSubsets"));m(f)||(f=d.noSubsets);e.noSubsets=m(f)?f:!1; -f=zq(b.getAttribute("fixedWidth"));m(f)||(f=d.fixedWidth);e.fixedWidth=f;f=zq(b.getAttribute("fixedHeight"));m(f)||(f=d.fixedHeight);e.fixedHeight=f;Oa(["Style","CRS","AuthorityURL"],function(b){var c=d[b];if(m(c)){var f=vb(e,b),f=f.concat(c);e[b]=f}});Oa("EX_GeographicBoundingBox BoundingBox Dimension Attribution MinScaleDenominator MaxScaleDenominator".split(" "),function(b){m(e[b])||(e[b]=d[b])});return e}})}),uv=R(kv,{Title:Q(X),OnlineResource:Q(Ut),LogoURL:Q(hv)}),tv=R(kv,{westBoundLongitude:Q(yq), -eastBoundLongitude:Q(yq),southBoundLatitude:Q(yq),northBoundLatitude:Q(yq)}),nv=R(kv,{GetCapabilities:Q(fv),GetMap:Q(fv),GetFeatureInfo:Q(fv)}),gv=R(kv,{Format:iq(X),DCPType:iq(function(b,c){return U({},wv,b,c)})}),wv=R(kv,{HTTP:Q(function(b,c){return U({},xv,b,c)})}),xv=R(kv,{Get:Q(dv),Post:Q(dv)}),vv=R(kv,{Name:Q(X),Title:Q(X),Abstract:Q(X),LegendURL:iq(hv),StyleSheetURL:Q(dv),StyleURL:Q(dv)}),ev=R(kv,{Format:Q(X),OnlineResource:Q(Ut)}),jv=R(kv,{Keyword:gq(X)});function yv(){this.b="http://mapserver.gis.umn.edu/mapserver";this.d=new Oq;this.defaultDataProjection=null}v(yv,rq); -function zv(b,c,d){c.namespaceURI=b.b;var e=Pp(c),f=[];if(0===c.childNodes.length)return f;"msGMLOutput"==e&&Oa(c.childNodes,function(b){if(1===b.nodeType){var c=d[0],e=b.localName,n=RegExp,p;p="_layer".replace(/([-()\[\]{}+?*.$\^|,:#=c.j&&c.cancel())}this.p?this.p.call(this.l,this):this.i=!0;this.a||(b=new xw,yw(this),zw(this,!1,b))}};ww.prototype.n=function(b,c){this.g=!1;zw(this,b,c)};function zw(b,c,d){b.a=!0;b.b=d;b.c=!c;Aw(b)} -function yw(b){if(b.a){if(!b.i)throw new Bw;b.i=!1}}function Cw(b,c,d,e){b.f.push([c,d,e]);b.a&&Aw(b)}ww.prototype.then=function(b,c,d){var e,f,g=new iw(function(b,c){e=b;f=c});Cw(this,e,function(b){b instanceof xw?g.cancel():f(b)});return g.then(b,c,d)};$v(ww);function Dw(b){return Sa(b.f,function(b){return ka(b[1])})} -function Aw(b){if(b.e&&b.a&&Dw(b)){var c=b.e,d=Ew[c];d&&(ba.clearTimeout(d.X),delete Ew[c]);b.e=0}b.d&&(b.d.j--,delete b.d);for(var c=b.b,e=d=!1;b.f.length&&!b.g;){var f=b.f.shift(),g=f[0],h=f[1],f=f[2];if(g=b.c?h:g)try{var k=g.call(f||b.l,c);m(k)&&(b.c=b.c&&(k==c||k instanceof Error),b.b=c=k);aw(c)&&(e=!0,b.g=!0)}catch(n){c=n,b.c=!0,Dw(b)||(d=!0)}}b.b=c;e&&(k=ra(b.n,b,!0),e=ra(b.n,b,!1),c instanceof ww?(Cw(c,k,e),c.q=!0):c.then(k,e));d&&(c=new Fw(c),Ew[c.X]=c,b.e=c.X)} -function Bw(){xa.call(this)}v(Bw,xa);Bw.prototype.message="Deferred has already fired";Bw.prototype.name="AlreadyCalledError";function xw(){xa.call(this)}v(xw,xa);xw.prototype.message="Deferred was canceled";xw.prototype.name="CanceledError";function Fw(b){this.X=ba.setTimeout(ra(this.d,this),0);this.a=b}Fw.prototype.d=function(){delete Ew[this.X];throw this.a;};var Ew={};function Gw(b,c){m(b.name)?(this.name=b.name,this.code=qb[b.name]):(this.code=b.code,this.name=Hw(b.code));xa.call(this,za("%s %s",this.name,c))}v(Gw,xa);function Hw(b){var c=pb(function(c){return b==c});if(!m(c))throw Error("Invalid code: "+b);return c}var qb={AbortError:3,EncodingError:5,InvalidModificationError:9,InvalidStateError:7,NotFoundError:1,NotReadableError:4,NoModificationAllowedError:6,PathExistsError:12,QuotaExceededError:10,SecurityError:2,SyntaxError:8,TypeMismatchError:11};function Iw(b,c){pc.call(this,b.type,c)}v(Iw,pc);function Jw(){ed.call(this);this.eb=new FileReader;this.eb.onloadstart=ra(this.a,this);this.eb.onprogress=ra(this.a,this);this.eb.onload=ra(this.a,this);this.eb.onabort=ra(this.a,this);this.eb.onerror=ra(this.a,this);this.eb.onloadend=ra(this.a,this)}v(Jw,ed);Jw.prototype.getError=function(){return this.eb.error&&new Gw(this.eb.error,"reading file")};Jw.prototype.a=function(b){this.dispatchEvent(new Iw(b,this))};Jw.prototype.M=function(){Jw.R.M.call(this);delete this.eb}; -function Kw(b){var c=new ww;b.Oa("loadend",sa(function(b,c){var f=c.eb.result,g=c.getError();null==f||g?(yw(b),zw(b,!1,g)):(yw(b),zw(b,!0,f));c.Ec()},c,b));return c};function Lw(b){b=m(b)?b:{};Ij.call(this,{handleEvent:Zc});this.e=m(b.formatConstructors)?b.formatConstructors:[];this.l=m(b.projection)?Be(b.projection):null;this.f=null;this.c=void 0}v(Lw,Ij);Lw.prototype.M=function(){m(this.c)&&Tc(this.c);Lw.R.M.call(this)};Lw.prototype.g=function(b){b=b.a.dataTransfer.files;var c,d,e;c=0;for(d=b.length;c=d[0]||0>=d[1]?c=!1:(c=c.a(),c=null!==c&&Ye(c)?!0:!1)}else c=!1;if(!c)return!0;c=!0;b.type===Hi?c=bx(this,b):b.type===Bi&&(c=!1);return Wj.call(this,b)&&c}function Vw(b){return this.Va(b)?(this.S=b.pixel,!0):!1} -function Xw(b){var c=this.S,d=b.pixel,e=c[0]-d[0],c=c[1]-d[1],d=!0;4>=e*e+c*c&&(bx(this,b),null===this.i?cx(this,b):this.c===Yw||dx(this,b)?this.U():(b=b.coordinate,e=this.g.N(),this.c===Zw?(this.i=b.slice(),c=e.K(),c.push(b.slice()),e.V(c)):this.c===$w&&(this.e[0].push(b.slice()),e.V(this.e)),ex(this)),d=!1);return d} -function bx(b,c){if(b.c===Yw&&null===b.i)cx(b,c);else if(null===b.i){var d=c.coordinate.slice();null===b.l?(b.l=new P(new Ek(d)),ex(b)):b.l.N().V(d)}else{var d=c.coordinate,e=b.g.N(),f,g;b.c===Yw?(g=e.K(),g[0]=d[0],g[1]=d[1],e.V(g)):(b.c===Zw?f=e.K():b.c===$w&&(f=b.e[0]),dx(b,c)&&(d=b.i.slice()),b.l.N().V(d),g=f[f.length-1],g[0]=d[0],g[1]=d[1],b.c===Zw?e.V(f):b.c===$w&&(b.r.N().V(f),e.V(b.e)));ex(b)}return!0} -function dx(b,c){var d=!1;if(null!==b.g){var e=b.g.N(),f=!1,g=[b.i];b.c===Zw?f=2b.Da,g=[b.e[0][0],b.e[0][b.e[0].length-2]]);if(f)for(var e=c.map,f=0,h=g.length;fd?h[1]:h[0]);nx(b,k);d={};d[ma(h)]=!0;c=1;for(n=g.length;cd&&(b.index+=f)})}function lx(){var b=ql();return function(){return b.Point}};function px(b){Ij.call(this,{handleEvent:qx});b=m(b)?b:{};this.i=m(b.condition)?b.condition:Qj;this.e=m(b.addCondition)?b.addCondition:Yc;this.q=m(b.removeCondition)?b.removeCondition:Yc;this.s=m(b.toggleCondition)?b.toggleCondition:Sj;this.g=m(b.multi)?b.multi:!1;var c;if(m(b.layers))if(ka(b.layers))c=b.layers;else{var d=b.layers;c=function(b){return Va(d,b)}}else c=Zc;this.f=c;this.c=new op({style:m(b.style)?b.style:rx()});b=this.c.a;w(b,"add",this.l,!1,this);w(b,"remove",this.r,!1,this)}v(px,Ij); -px.prototype.p=function(){return this.c.a};function qx(b){if(!this.i(b))return!0;var c=this.e(b),d=this.q(b),e=this.s(b),f=b.map,g=this.c.a,h=[],k=[];if(c||d||e){f.ne(b.pixel,function(b){-1==Na.indexOf.call(g.a,b,void 0)?(c||e)&&k.push(b):(d||e)&&h.push(b)},void 0,this.f);for(f=h.length-1;0<=f;--f)g.remove(h[f]);g.we(k)}else f.ne(b.pixel,function(b){k.push(b)},void 0,this.f),0b.f}function Px(b,c){for(var d,e;Ox(b)&&!(d=b.a.fc,e=d.a[0].toString(),e in c&&c[e].contains(d.a));)b.pop().Ec()};function Qx(b){$i.call(this,{attributions:b.attributions,extent:b.extent,logo:b.logo,opaque:b.opaque,projection:b.projection,state:m(b.state)?b.state:void 0,tileGrid:b.tileGrid,tilePixelRatio:b.tilePixelRatio});this.tileUrlFunction=m(b.tileUrlFunction)?b.tileUrlFunction:Kx;this.crossOrigin=m(b.crossOrigin)?b.crossOrigin:null;this.b=new Nx;this.tileLoadFunction=m(b.tileLoadFunction)?b.tileLoadFunction:Rx;this.tileClass=m(b.tileClass)?b.tileClass:Wv}v(Qx,$i);function Rx(b,c){b.Qa().src=c}l=Qx.prototype; -l.Dd=function(){return Ox(this.b)};l.Be=function(b){Px(this.b,b)};l.Fb=function(b,c,d,e,f){var g=this.ib(b,c,d);if(Bo(this.b,g))return this.b.get(g);b=[b,c,d];e=this.tileUrlFunction(b,e,f);e=new this.tileClass(b,m(e)?0:4,m(e)?e:"",this.crossOrigin,this.tileLoadFunction);this.b.set(g,e);return e};l.jb=function(){return this.tileLoadFunction};l.kb=function(){return this.tileUrlFunction};l.pb=function(b){this.b.clear();this.tileLoadFunction=b;this.o()}; -l.sa=function(b){this.b.clear();this.tileUrlFunction=b;this.o()};l.Oe=function(b,c,d){b=this.ib(b,c,d);Bo(this.b,b)&&this.b.get(b)};function Sx(b){var c=m(b.extent)?b.extent:Il,d=Yi(c,b.maxZoom,b.tileSize);Ri.call(this,{minZoom:b.minZoom,origin:je(c,"top-left"),resolutions:d,tileSize:b.tileSize})}v(Sx,Ri); -Sx.prototype.Cb=function(b){b=m(b)?b:{};var c=this.minZoom,d=this.maxZoom,e=m(b.wrapX)?b.wrapX:!0,f=null;if(m(b.extent)){var f=Array(d+1),g;for(g=0;g<=d;++g)f[g]=gq||p<=q)return null;b=b[2];return b<-p||-1=this.minZoom;--b)if(e.a=e.c>>=1,e.b=e.d>>=1,c.call(d,b,e))return!0;return!1};function Tx(b){Qx.call(this,{crossOrigin:"anonymous",opaque:!0,projection:Be("EPSG:3857"),state:"loading",tileLoadFunction:b.tileLoadFunction});this.c=m(b.culture)?b.culture:"en-us";this.a=m(b.maxZoom)?b.maxZoom:-1;this.j=m(b.wrapX)?b.wrapX:!0;var c=new Kr((Qb?"https:":"http:")+"//dev.virtualearth.net/REST/v1/Imagery/Metadata/"+b.imagerySet);(new Cx(c,"jsonp")).send({include:"ImageryProviders",uriScheme:Qb?"https":"http",key:b.key},ra(this.e,this))}v(Tx,Qx);var Ux=new qf({html:'Terms of Use'}); -Tx.prototype.e=function(b){if(200!=b.statusCode||"OK"!=b.statusDescription||"ValidCredentials"!=b.authenticationResultCode||1!=b.resourceSets.length||1!=b.resourceSets[0].resources.length)Li(this,"error");else{var c=b.brandLogoUri,d=b.resourceSets[0].resources[0],e=-1==this.a?d.zoomMax:this.a,f=new Sx({extent:Zi(this.g),minZoom:d.zoomMin,maxZoom:e,tileSize:d.imageWidth});this.tileGrid=f;var g=this.c;this.tileUrlFunction=Lx(f.Cb({wrapX:this.j}),Jx(Ra(d.imageUrlSubdomains,function(b){var c=d.imageUrl.replace("{subdomain}", -b).replace("{culture}",g);return function(b){return null===b?void 0:c.replace("{quadkey}",jf(b))}})));if(d.imageryProviders){var h=Ae(Be("EPSG:4326"),this.g);b=Ra(d.imageryProviders,function(b){var c=b.attribution,d={};Oa(b.coverageAreas,function(b){var c=b.zoomMin,g=Math.min(b.zoomMax,e);b=b.bbox;b=se([b[1],b[0],b[3],b[2]],h);var k,n;for(k=c;k<=g;++k)n=k.toString(),c=Ui(f,b,k),n in d?d[n].push(c):d[n]=[c]});return new qf({html:c,tileRanges:d})});b.push(Ux);this.f=b}this.r=c;Li(this,"ready")}};function Vx(b){fn.call(this,{attributions:b.attributions,extent:b.extent,logo:b.logo,projection:b.projection});this.l=void 0;this.q=m(b.distance)?b.distance:20;this.a=[];this.p=b.source;this.p.u("change",Vx.prototype.s,this)}v(Vx,fn);Vx.prototype.Hb=function(b,c,d){c!==this.l&&(this.clear(),this.l=c,this.p.Hb(b,c,d),Wx(this),this.Ea(this.a))};Vx.prototype.s=function(){this.clear();Wx(this);this.Ea(this.a);this.o()}; -function Wx(b){if(m(b.l)){b.a.length=0;for(var c=Rd(),d=b.q*b.l,e=b.p.ya(),f={},g=0,h=e.length;gk*h?g*f/(k*p):h*f/(n*p);d=ie(d);e={OPERATION:this.H?"GETDYNAMICMAPOVERLAYIMAGE":"GETMAPIMAGE",VERSION:"2.0.0",LOCALE:"en",CLIENTAGENT:"ol.source.ImageMapGuide source",CLIP:"1",SETDISPLAYDPI:this.e,SETDISPLAYWIDTH:Math.round(e[0]),SETDISPLAYHEIGHT:Math.round(e[1]),SETVIEWSCALE:f,SETVIEWCENTERX:d[0],SETVIEWCENTERY:d[1]};yb(e,c);return Hr(Jr([b],e))};l.Lj=function(b){this.b=null;this.a=b;this.o()};function Ay(b){var c=m(b.attributions)?b.attributions:null,d=b.imageExtent,e,f;m(b.imageSize)&&(e=me(d)/b.imageSize[1],f=[e]);var g=m(b.crossOrigin)?b.crossOrigin:null,h=m(b.imageLoadFunction)?b.imageLoadFunction:Ym;Wm.call(this,{attributions:c,logo:b.logo,projection:Be(b.projection),resolutions:f});this.a=new Vv(d,e,1,c,b.url,g,h)}v(Ay,Wm);Ay.prototype.rc=function(b){return oe(b,this.a.D())?this.a:null};function By(b){b=m(b)?b:{};Wm.call(this,{attributions:b.attributions,logo:b.logo,projection:b.projection,resolutions:b.resolutions});this.F=m(b.crossOrigin)?b.crossOrigin:null;this.c=b.url;this.i=m(b.imageLoadFunction)?b.imageLoadFunction:Ym;this.a=b.params;this.e=!0;Cy(this);this.s=b.serverType;this.H=m(b.hidpi)?b.hidpi:!0;this.b=null;this.l=[0,0];this.q=0;this.p=m(b.ratio)?b.ratio:1.5}v(By,Wm);var Dy=[101,101];l=By.prototype; -l.Sj=function(b,c,d,e){if(m(this.c)){var f=le(b,c,0,Dy),g={SERVICE:"WMS",VERSION:"1.3.0",REQUEST:"GetFeatureInfo",FORMAT:"image/png",TRANSPARENT:!0,QUERY_LAYERS:this.a.LAYERS};yb(g,this.a,e);e=Math.floor((f[3]-b[1])/c);g[this.e?"I":"X"]=Math.floor((b[0]-f[0])/c);g[this.e?"J":"Y"]=e;return Ey(this,f,Dy,1,Be(d),g)}};l.Uj=function(){return this.a}; -l.rc=function(b,c,d,e){if(!m(this.c))return null;c=Xm(this,c);1==d||this.H&&m(this.s)||(d=1);var f=this.b;if(null!==f&&this.q==this.d&&f.resolution==c&&f.f==d&&Yd(f.D(),b))return f;f={SERVICE:"WMS",VERSION:"1.3.0",REQUEST:"GetMap",FORMAT:"image/png",TRANSPARENT:!0};yb(f,this.a);b=b.slice();var g=(b[0]+b[2])/2,h=(b[1]+b[3])/2;if(1!=this.p){var k=this.p*pe(b)/2,n=this.p*me(b)/2;b[0]=g-k;b[1]=h-n;b[2]=g+k;b[3]=h+n}var k=c/d,n=Math.ceil(pe(b)/k),p=Math.ceil(me(b)/k);b[0]=g-k*n/2;b[2]=g+k*n/2;b[1]=h-k* -p/2;b[3]=h+k*p/2;this.l[0]=n;this.l[1]=p;e=Ey(this,b,this.l,d,e,f);this.b=new Vv(b,c,d,this.f,e,this.F,this.i);this.q=this.d;return this.b};l.Tj=function(){return this.i}; -function Ey(b,c,d,e,f,g){g[b.e?"CRS":"SRS"]=f.a;"STYLES"in b.a||(g.STYLES=new String(""));if(1!=e)switch(b.s){case "geoserver":g.FORMAT_OPTIONS="dpi:"+(90*e+.5|0);break;case "mapserver":g.MAP_RESOLUTION=90*e;break;case "carmentaserver":case "qgis":g.DPI=90*e}g.WIDTH=d[0];g.HEIGHT=d[1];d=f.b;var h;b.e&&"ne"==d.substr(0,2)?h=[c[1],c[0],c[3],c[2]]:h=c;g.BBOX=h.join(",");return Hr(Jr([b.c],g))}l.Vj=function(){return this.c};l.Wj=function(b){this.b=null;this.i=b;this.o()}; -l.Xj=function(b){b!=this.c&&(this.c=b,this.b=null,this.o())};l.Yj=function(b){yb(this.a,b);Cy(this);this.b=null;this.o()};function Cy(b){b.e=0<=Ka(ub(b.a,"VERSION","1.3.0"),"1.3")};function Fy(b){b=m(b)?b:{};vy.call(this,{attributions:b.attributions,doc:b.doc,format:new es({extractStyles:b.extractStyles,defaultStyle:b.defaultStyle}),logo:b.logo,node:b.node,projection:b.projection,text:b.text,url:b.url,urls:b.urls})}v(Fy,vy);function Gy(b){var c=m(b.projection)?b.projection:"EPSG:3857",d=new Sx({extent:Zi(c),maxZoom:b.maxZoom,tileSize:b.tileSize});Qx.call(this,{attributions:b.attributions,crossOrigin:b.crossOrigin,logo:b.logo,projection:c,tileGrid:d,tileLoadFunction:b.tileLoadFunction,tilePixelRatio:b.tilePixelRatio,tileUrlFunction:Kx});this.c=d.Cb({wrapX:b.wrapX});m(b.tileUrlFunction)?this.sa(b.tileUrlFunction):m(b.urls)?this.sa(Ix(b.urls)):m(b.url)&&this.a(b.url)}v(Gy,Qx); -Gy.prototype.sa=function(b){Gy.R.sa.call(this,Lx(this.c,b))};Gy.prototype.a=function(b){this.sa(Ix(Mx(b)))};function Hy(b){b=m(b)?b:{};var c;m(b.attributions)?c=b.attributions:c=[Iy];var d=Qb?"https:":"http:";Gy.call(this,{attributions:c,crossOrigin:m(b.crossOrigin)?b.crossOrigin:"anonymous",opaque:!0,maxZoom:m(b.maxZoom)?b.maxZoom:19,tileLoadFunction:b.tileLoadFunction,url:m(b.url)?b.url:d+"//{a-c}.tile.openstreetmap.org/{z}/{x}/{y}.png",wrapX:b.wrapX})}v(Hy,Gy);var Iy=new qf({html:'© OpenStreetMap contributors.'});function Jy(b){b=m(b)?b:{};var c=Ky[b.layer],d=Qb?"https:":"http:";Gy.call(this,{attributions:c.attributions,crossOrigin:"anonymous",logo:"//developer.mapquest.com/content/osm/mq_logo.png",maxZoom:c.maxZoom,opaque:!0,tileLoadFunction:b.tileLoadFunction,url:m(b.url)?b.url:d+"//otile{1-4}-s.mqcdn.com/tiles/1.0.0/"+b.layer+"/{z}/{x}/{y}.jpg"})}v(Jy,Gy); -var Ly=new qf({html:'Tiles Courtesy of MapQuest'}),Ky={osm:{maxZoom:19,attributions:[Ly,Iy]},sat:{maxZoom:18,attributions:[Ly,new qf({html:"Portions Courtesy NASA/JPL-Caltech and U.S. Depart. of Agriculture, Farm Service Agency"})]},hyb:{maxZoom:18,attributions:[Ly,Iy]}};function My(b){b=m(b)?b:{};vy.call(this,{attributions:b.attributions,doc:b.doc,format:new Ot,logo:b.logo,node:b.node,projection:b.projection,text:b.text,url:b.url,urls:b.urls})}v(My,vy);function Ny(b){ty.call(this,{attributions:b.attributions,format:b.format,logo:b.logo,projection:b.projection});this.p=new an;this.q=b.loader;this.s=m(b.strategy)?b.strategy:ux;this.l={}}v(Ny,ty);Ny.prototype.gb=function(b){var c=[],d,e;d=0;for(e=b.length;dStamen Design, under CC BY 3.0.'}),Iy];function Sy(b,c){Pi.call(this,b,2);this.b=c.va(b[0]);this.d={}}v(Sy,Pi);Sy.prototype.Qa=function(b){b=m(b)?ma(b):-1;if(b in this.d)return this.d[b];var c=this.b,d=Pf(c,c);d.strokeStyle="black";d.strokeRect(.5,.5,c+.5,c+.5);d.fillStyle="black";d.textAlign="center";d.textBaseline="middle";d.font="24px sans-serif";d.fillText(kf(this.a),c/2,c/2);return this.d[b]=d.canvas};function Ty(b){$i.call(this,{opaque:!1,projection:b.projection,tileGrid:b.tileGrid});this.a=new Nx}v(Ty,$i);Ty.prototype.Dd=function(){return Ox(this.a)}; -Ty.prototype.Be=function(b){Px(this.a,b)};Ty.prototype.Fb=function(b,c,d){var e=this.ib(b,c,d);if(Bo(this.a,e))return this.a.get(e);b=new Sy([b,c,d],this.tileGrid);this.a.set(e,b);return b};function Uy(b){Qx.call(this,{crossOrigin:b.crossOrigin,projection:Be("EPSG:3857"),state:"loading",tileLoadFunction:b.tileLoadFunction});this.a=b.wrapX;(new Cx(b.url)).send(void 0,ra(this.c,this))}v(Uy,Qx); -Uy.prototype.c=function(b){var c=Be("EPSG:4326"),d=this.g,e;m(b.bounds)&&(e=se(b.bounds,Ae(c,d)));var f=b.minzoom||0,g=b.maxzoom||22;this.tileGrid=d=new Sx({extent:Zi(d),maxZoom:g,minZoom:f});this.tileUrlFunction=Lx(d.Cb({extent:e,wrapX:this.a}),Ix(b.tiles));if(m(b.attribution)){c=m(e)?e:c.D();e={};for(var h;f<=g;++f)h=f.toString(),e[h]=[Ui(d,c,f)];this.f=[new qf({html:b.attribution,tileRanges:e})]}Li(this,"ready")};function Vy(b){$i.call(this,{projection:Be("EPSG:3857"),state:"loading"});this.e=m(b.preemptive)?b.preemptive:!0;this.b=Kx;this.a=new Nx;this.c=void 0;(new Cx(b.url)).send(void 0,ra(this.Zj,this))}v(Vy,$i);l=Vy.prototype;l.Dd=function(){return Ox(this.a)};l.Be=function(b){Px(this.a,b)};l.Ph=function(){return this.c};l.nh=function(b,c,d,e,f){null===this.tileGrid?!0===f?oh(function(){d.call(e,null)}):d.call(e,null):(c=this.tileGrid.Vb(b,c),Wy(this.Fb(c[0],c[1],c[2],1,this.g),b,d,e,f))}; -l.Zj=function(b){var c=Be("EPSG:4326"),d=this.g,e;m(b.bounds)&&(e=se(b.bounds,Ae(c,d)));var f=b.minzoom||0,g=b.maxzoom||22;this.tileGrid=d=new Sx({extent:Zi(d),maxZoom:g,minZoom:f});this.c=b.template;var h=b.grids;if(null!=h){this.b=Lx(d.Cb({extent:e}),Ix(h));if(m(b.attribution)){c=m(e)?e:c.D();for(e={};f<=g;++f)h=f.toString(),e[h]=[Ui(d,c,f)];this.f=[new qf({html:b.attribution,tileRanges:e})]}Li(this,"ready")}else Li(this,"error")}; -l.Fb=function(b,c,d,e,f){var g=this.ib(b,c,d);if(Bo(this.a,g))return this.a.get(g);b=[b,c,d];e=this.b(b,e,f);e=new Xy(b,m(e)?0:4,m(e)?e:"",Ti(this.tileGrid,b),this.e);this.a.set(g,e);return e};l.Oe=function(b,c,d){b=this.ib(b,c,d);Bo(this.a,b)&&this.a.get(b)};function Xy(b,c,d,e,f){Pi.call(this,b,c);this.g=d;this.d=e;this.j=f;this.c=this.f=this.b=null}v(Xy,Pi);l=Xy.prototype;l.Qa=function(){return null}; -function Yy(b,c){if(null===b.b||null===b.f||null===b.c)return null;var d=b.b[Math.floor((1-(c[1]-b.d[1])/(b.d[3]-b.d[1]))*b.b.length)];if(!ia(d))return null;d=d.charCodeAt(Math.floor((c[0]-b.d[0])/(b.d[2]-b.d[0])*d.length));93<=d&&d--;35<=d&&d--;d=b.f[d-32];return null!=d?b.c[d]:null}function Wy(b,c,d,e,f){0==b.state&&!0===f?(Rc(b,"change",function(){d.call(e,Yy(this,c))},!1,b),Zy(b)):!0===f?oh(function(){d.call(e,Yy(this,c))},b):d.call(e,Yy(b,c))}l.nb=function(){return this.g}; -l.di=function(){this.state=3;Qi(this)};l.pi=function(b){this.b=b.grid;this.f=b.keys;this.c=b.data;this.state=4;Qi(this)};function Zy(b){0==b.state&&(b.state=1,(new Cx(b.g)).send(void 0,ra(b.pi,b),ra(b.di,b)))}l.load=function(){this.j&&Zy(this)};function $y(b){ty.call(this,{attributions:b.attributions,format:b.format,logo:b.logo,projection:b.projection});this.p=b.tileGrid;this.q=Kx;this.s=this.p.Cb();this.l={};m(b.tileUrlFunction)?(this.q=b.tileUrlFunction,this.o()):m(b.urls)?(this.q=Ix(b.urls),this.o()):m(b.url)&&(this.q=Ix(Mx(b.url)),this.o())}v($y,ty);l=$y.prototype;l.clear=function(){sb(this.l)}; -function az(b,c,d,e){var f=b.l;b=b.p.Vb(c,d);f=f[b[0]+"/"+b[1]+"/"+b[2]];if(m(f))for(b=0,d=f.length;bp||n<=p)return null;b=b[2];return b<-n||-1g||e>g;)f.push([Math.ceil(d/g),Math.ceil(e/g)]),g+=g;break;case "truncated":for(;d>g||e>g;)f.push([Math.ceil(d/g),Math.ceil(e/g)]),d>>=1,e>>=1}f.push([1,1]);f.reverse();for(var g=[1],h=[0],e=1,d=f.length;ethis.b||d+this.a>this.b)return null;e=oz(this,!1,b,c,d,e,g);if(null===e)return null;b=oz(this,!0,b,c,d,m(f)?f:$c,g);return{offsetX:e.offsetX,offsetY:e.offsetY,image:e.image,sf:b.image}}; -function oz(b,c,d,e,f,g,h){var k=c?b.e:b.f,n,p,q;p=0;for(q=k.length;p=c+this.a&&g.height>=d+this.a)return k={offsetX:g.x+this.a,offsetY:g.y+this.a,image:this.b},this.c[b]=k,e.call(f,this.f,g.x+this.a,g.y+this.a),b=h,c=c+this.a,d=d+this.a,f=e=void 0,g.width-c>g.height-d?(e={x:g.x+c,y:g.y,width:g.width-c,height:g.height},f={x:g.x,y:g.y+d,width:c,height:g.height-d},pz(this,b,e,f)):(e={x:g.x+c,y:g.y,width:g.width-c,height:d},f={x:g.x,y:g.y+d,width:g.width,height:g.height- -d},pz(this,b,e,f)),k;return null};function pz(b,c,d,e){c=[c,1];0>>0),oa=0;function pa(b,c,d){return b.call.apply(b.bind,arguments)}function qa(b,c,d){if(!b)throw Error();if(2")&&(b=b.replace(Fa,">"));-1!=b.indexOf('"')&&(b=b.replace(Ga,"""));-1!=b.indexOf("'")&&(b=b.replace(Ha,"'"));-1!=b.indexOf("\x00")&&(b=b.replace(Ia,"�"));return b}var Da=/&/g,Ea=//g,Ga=/"/g,Ha=/'/g,Ia=/\x00/g,Ca=/[\x00&<>"']/; -function Ja(b){b=m(void 0)?b.toFixed(void 0):String(b);var c=b.indexOf(".");-1==c&&(c=b.length);c=Math.max(0,2-c);return Array(c+1).join("0")+b} -function Ka(b,c){for(var d=0,e=Aa(String(b)).split("."),f=Aa(String(c)).split("."),g=Math.max(e.length,f.length),h=0;0==d&&hc?1:0};var Na=Array.prototype;function Oa(b,c,d){Na.forEach.call(b,c,d)}function Pa(b,c){return Na.filter.call(b,c,void 0)}function Ra(b,c,d){return Na.map.call(b,c,d)}function Sa(b,c){return Na.some.call(b,c,void 0)}function Ta(b){var c;a:{c=Ua;for(var d=b.length,e=ia(b)?b.split(""):b,f=0;fc?null:ia(b)?b.charAt(c):b[c]}function Va(b,c){return 0<=Na.indexOf.call(b,c,void 0)} -function Wa(b,c){var d=Na.indexOf.call(b,c,void 0),e;(e=0<=d)&&Na.splice.call(b,d,1);return e}function Xa(b){return Na.concat.apply(Na,arguments)}function Ya(b){var c=b.length;if(0=arguments.length?Na.slice.call(b,c):Na.slice.call(b,c,d)}function bb(b,c){b.sort(c||cb)}function db(b,c){if(!ha(b)||!ha(c)||b.length!=c.length)return!1;for(var d=b.length,e=eb,f=0;fc?1:bparseFloat(b))?String(c):b}(),Lb={};function Mb(b){return Lb[b]||(Lb[b]=0<=Ka(Kb,b))}var Nb=ba.document,Pb=Nb&&Bb?Ib()||("CSS1Compat"==Nb.compatMode?parseInt(Kb,10):5):void 0;var Qb="https:"===ba.location.protocol,Rb=Bb&&!Mb("9.0")&&""!==Kb;function Ub(b,c,d){return Math.min(Math.max(b,c),d)}function Vb(b,c){var d=b%c;return 0>d*c?d+c:d}function Wb(b,c,d){return b+d*(c-b)}function Xb(b){return b*Math.PI/180};function Yb(b){return function(c){if(m(c))return[Ub(c[0],b[0],b[2]),Ub(c[1],b[1],b[3])]}}function Zb(b){return b};function $b(b,c,d){var e=b.length;if(b[0]<=c)return 0;if(!(c<=b[e-1]))if(0d)for(d=1;dg?1:.5,e=Math.floor(Math.log(c/e)/Math.log(b)+g),f=Math.max(e+f,0),m(d)&&(f=Math.min(f,d)),c/Math.pow(b,f)}};function cc(b){if(m(b))return 0}function dc(b,c){if(m(b))return b+c}function ec(b){var c=2*Math.PI/b;return function(b,e){if(m(b))return b=Math.floor((b+e)/c+.5)*c}}function fc(){var b=Xb(5);return function(c,d){if(m(c))return Math.abs(c+d)<=b?0:c+d}};function gc(b,c,d){this.center=b;this.resolution=c;this.rotation=d};var hc=!Bb||Bb&&9<=Pb,ic=!Bb||Bb&&9<=Pb,jc=Bb&&!Mb("9");!Db||Mb("528");Cb&&Mb("1.9b")||Bb&&Mb("8")||Ab&&Mb("9.5")||Db&&Mb("528");Cb&&!Mb("8")||Bb&&Mb("9");function kc(){0!=lc&&(mc[ma(this)]=this);this.oa=this.oa;this.pa=this.pa}var lc=0,mc={};kc.prototype.oa=!1;kc.prototype.Ec=function(){if(!this.oa&&(this.oa=!0,this.M(),0!=lc)){var b=ma(this);delete mc[b]}};function nc(b,c){var d=sa(oc,c);b.oa?d.call(void 0):(b.pa||(b.pa=[]),b.pa.push(m(void 0)?ra(d,void 0):d))}kc.prototype.M=function(){if(this.pa)for(;this.pa.length;)this.pa.shift()()};function oc(b){b&&"function"==typeof b.Ec&&b.Ec()};function pc(b,c){this.type=b;this.b=this.target=c;this.e=!1;this.hg=!0}pc.prototype.mb=function(){this.e=!0};pc.prototype.preventDefault=function(){this.hg=!1};function qc(b){b.mb()}function rc(b){b.preventDefault()};var sc=Bb?"focusout":"DOMFocusOut";function tc(b){tc[" "](b);return b}tc[" "]=ca;function uc(b,c){pc.call(this,b?b.type:"");this.relatedTarget=this.b=this.target=null;this.i=this.f=this.button=this.screenY=this.screenX=this.clientY=this.clientX=this.offsetY=this.offsetX=0;this.n=this.c=this.d=this.j=!1;this.state=null;this.g=!1;this.a=null;b&&vc(this,b,c)}v(uc,pc);var wc=[1,4,2]; -function vc(b,c,d){b.a=c;var e=b.type=c.type;b.target=c.target||c.srcElement;b.b=d;if(d=c.relatedTarget){if(Cb){var f;a:{try{tc(d.nodeName);f=!0;break a}catch(g){}f=!1}f||(d=null)}}else"mouseover"==e?d=c.fromElement:"mouseout"==e&&(d=c.toElement);b.relatedTarget=d;Object.defineProperties?Object.defineProperties(b,{offsetX:{configurable:!0,enumerable:!0,get:b.kf,set:b.Cl},offsetY:{configurable:!0,enumerable:!0,get:b.lf,set:b.Dl}}):(b.offsetX=b.kf(),b.offsetY=b.lf());b.clientX=void 0!==c.clientX?c.clientX: -c.pageX;b.clientY=void 0!==c.clientY?c.clientY:c.pageY;b.screenX=c.screenX||0;b.screenY=c.screenY||0;b.button=c.button;b.f=c.keyCode||0;b.i=c.charCode||("keypress"==e?c.keyCode:0);b.j=c.ctrlKey;b.d=c.altKey;b.c=c.shiftKey;b.n=c.metaKey;b.g=Eb?c.metaKey:c.ctrlKey;b.state=c.state;c.defaultPrevented&&b.preventDefault()}function xc(b){return(hc?0==b.a.button:"click"==b.type?!0:!!(b.a.button&wc[0]))&&!(Db&&Eb&&b.j)}l=uc.prototype; -l.mb=function(){uc.R.mb.call(this);this.a.stopPropagation?this.a.stopPropagation():this.a.cancelBubble=!0};l.preventDefault=function(){uc.R.preventDefault.call(this);var b=this.a;if(b.preventDefault)b.preventDefault();else if(b.returnValue=!1,jc)try{if(b.ctrlKey||112<=b.keyCode&&123>=b.keyCode)b.keyCode=-1}catch(c){}};l.oh=function(){return this.a};l.kf=function(){return Db||void 0!==this.a.offsetX?this.a.offsetX:this.a.layerX}; -l.Cl=function(b){Object.defineProperties(this,{offsetX:{writable:!0,enumerable:!0,configurable:!0,value:b}})};l.lf=function(){return Db||void 0!==this.a.offsetY?this.a.offsetY:this.a.layerY};l.Dl=function(b){Object.defineProperties(this,{offsetY:{writable:!0,enumerable:!0,configurable:!0,value:b}})};var yc="closure_listenable_"+(1E6*Math.random()|0);function zc(b){return!(!b||!b[yc])}var Ac=0;function Bc(b,c,d,e,f){this.Yb=b;this.a=null;this.src=c;this.type=d;this.wc=!!e;this.sd=f;this.key=++Ac;this.tc=this.Yc=!1}function Cc(b){b.tc=!0;b.Yb=null;b.a=null;b.src=null;b.sd=null};function Dc(b){this.src=b;this.a={};this.d=0}Dc.prototype.add=function(b,c,d,e,f){var g=b.toString();b=this.a[g];b||(b=this.a[g]=[],this.d++);var h=Ec(b,c,e,f);-1f.keyCode||void 0!=f.returnValue)){a:{var g=!1;if(0==f.keyCode)try{f.keyCode=-1;break a}catch(h){g=!0}if(g||void 0==f.returnValue)f.returnValue=!0}f=[];for(g=d.b;g;g=g.parentNode)f.push(g);for(var g=b.type,k=f.length-1;!d.e&&0<=k;k--){d.b=f[k];var n=Uc(f[k],g,!0,d),e=e&&n}for(k=0;!d.e&&k>>0);function Lc(b){if(ka(b))return b;b[Wc]||(b[Wc]=function(c){return b.handleEvent(c)});return b[Wc]};function Xc(b){return function(){return b}}var Yc=Xc(!1),Zc=Xc(!0),$c=Xc(null);function ad(b){return b}function bd(b){var c;c=c||0;return function(){return b.apply(this,Array.prototype.slice.call(arguments,0,c))}}function cd(b){var c=arguments,d=c.length;return function(){for(var b,f=0;f=d||(1<=d?(h=k,f=g):(h+=d*n,f+=d*p));return[h,f]}function wd(b,c){var d=Vb(b+180,360)-180,e=Math.abs(Math.round(3600*d));return Math.floor(e/3600)+"\u00b0 "+Math.floor(e/60%60)+"\u2032 "+Math.floor(e%60)+"\u2033 "+c.charAt(0>d?1:0)} -function xd(b,c,d){return m(b)?c.replace("{x}",b[0].toFixed(d)).replace("{y}",b[1].toFixed(d)):""}function yd(b,c){for(var d=!0,e=b.length-1;0<=e;--e)if(b[e]!=c[e]){d=!1;break}return d}function zd(b,c){var d=Math.cos(c),e=Math.sin(c),f=b[1]*d+b[0]*e;b[0]=b[0]*d-b[1]*e;b[1]=f;return b}function Ad(b,c){var d=b[0]-c[0],e=b[1]-c[1];return d*d+e*e}function Bd(b,c){return xd(b,"{x}, {y}",c)};function Cd(b){this.length=b.length||b;for(var c=0;ce&&(k=k|4);hf&&(k|=2);0===k&&(k=1);return k}function Rd(){return[Infinity,Infinity,-Infinity,-Infinity]}function Ud(b,c,d,e,f){return m(f)?(f[0]=b,f[1]=c,f[2]=d,f[3]=e,f):[b,c,d,e]} -function ae(b,c){var d=b[0],e=b[1];return Ud(d,e,d,e,c)}function be(b,c){return b[0]==c[0]&&b[2]==c[2]&&b[1]==c[1]&&b[3]==c[3]}function ce(b,c){c[0]b[2]&&(b[2]=c[2]);c[1]b[3]&&(b[3]=c[3]);return b}function Sd(b,c){c[0]b[2]&&(b[2]=c[0]);c[1]b[3]&&(b[3]=c[1])} -function de(b,c,d,e,f){for(;dg;++g)h=f[g],k=e[g],f[g]=b[0]+h*c-k*d,e[g]=b[1]+h*d+k*c;return Td(f,e,void 0)}function me(b){return b[3]-b[1]} -function ne(b,c,d){d=m(d)?d:Rd();oe(b,c)&&(d[0]=b[0]>c[0]?b[0]:c[0],d[1]=b[1]>c[1]?b[1]:c[1],d[2]=b[2]=c[0]&&b[1]<=c[3]&&b[3]>=c[1]}function qe(b){return b[2]this.F)}return m(b)?this.p+b:b};l.me=function(b,c){if(!qe(b)){this.Ra(ie(b));var d=this.n(b,c),e=this.constrainResolution(d,0,0);eb?af(2*b):1-af(2*(b-.5))};function df(b){var c=b.source,d=m(b.start)?b.start:ua(),e=c[0],f=c[1],g=m(b.duration)?b.duration:1E3,h=m(b.easing)?b.easing:af;return function(b,c){if(c.time>=1;return d.join("")}function kf(b){return hf(b[0],b[1],b[2])};function lf(b,c,d,e){this.a=b;this.c=c;this.b=d;this.d=e}function mf(b,c,d,e,f){return m(f)?(f.a=b,f.c=c,f.b=d,f.d=e,f):new lf(b,c,d,e)}lf.prototype.contains=function(b){return nf(this,b[1],b[2])};function of(b,c){return b.a<=c.a&&c.c<=b.c&&b.b<=c.b&&c.d<=b.d}function nf(b,c,d){return b.a<=c&&c<=b.c&&b.b<=d&&d<=b.d}function pf(b,c){return b.a==c.a&&b.b==c.b&&b.c==c.c&&b.d==c.d};function qf(b){this.d=b.html;this.a=m(b.tileRanges)?b.tileRanges:null}qf.prototype.b=function(){return this.d};var rf=!Bb||Bb&&9<=Pb;!Cb&&!Bb||Bb&&Bb&&9<=Pb||Cb&&Mb("1.9.1");Bb&&Mb("9");zb("area base br col command embed hr img input keygen link meta param source track wbr".split(" "));zb("action","cite","data","formaction","href","manifest","poster","src");zb("embed","iframe","link","object","script","style","template");function sf(b,c){this.x=m(b)?b:0;this.y=m(c)?c:0}l=sf.prototype;l.clone=function(){return new sf(this.x,this.y)};l.ceil=function(){this.x=Math.ceil(this.x);this.y=Math.ceil(this.y);return this};l.floor=function(){this.x=Math.floor(this.x);this.y=Math.floor(this.y);return this};l.round=function(){this.x=Math.round(this.x);this.y=Math.round(this.y);return this};l.scale=function(b,c){var d=ja(c)?c:b;this.x*=b;this.y*=d;return this};function tf(b,c){this.width=b;this.height=c}l=tf.prototype;l.clone=function(){return new tf(this.width,this.height)};l.la=function(){return!(this.width*this.height)};l.ceil=function(){this.width=Math.ceil(this.width);this.height=Math.ceil(this.height);return this};l.floor=function(){this.width=Math.floor(this.width);this.height=Math.floor(this.height);return this};l.round=function(){this.width=Math.round(this.width);this.height=Math.round(this.height);return this}; -l.scale=function(b,c){var d=ja(c)?c:b;this.width*=b;this.height*=d;return this};function uf(b){return b?new vf(wf(b)):ya||(ya=new vf)}function xf(b){var c=document;return ia(b)?c.getElementById(b):b}function yf(b,c){jb(c,function(c,e){"style"==e?b.style.cssText=c:"class"==e?b.className=c:"for"==e?b.htmlFor=c:e in zf?b.setAttribute(zf[e],c):0==e.lastIndexOf("aria-",0)||0==e.lastIndexOf("data-",0)?b.setAttribute(e,c):b[e]=c})} -var zf={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 Af(b){b=b.document.documentElement;return new tf(b.clientWidth,b.clientHeight)} -function Bf(b){var c=Db?b.body||b.documentElement:b.documentElement;b=b.parentWindow||b.defaultView;return Bb&&Mb("10")&&b.pageYOffset!=c.scrollTop?new sf(c.scrollLeft,c.scrollTop):new sf(b.pageXOffset||c.scrollLeft,b.pageYOffset||c.scrollTop)} -function Cf(b,c,d){var e=arguments,f=document,g=e[0],h=e[1];if(!rf&&h&&(h.name||h.type)){g=["<",g];h.name&&g.push(' name="',Ba(h.name),'"');if(h.type){g.push(' type="',Ba(h.type),'"');var k={};yb(k,h);delete k.type;h=k}g.push(">");g=g.join("")}g=f.createElement(g);h&&(ia(h)?g.className=h:ga(h)?g.className=h.join(" "):yf(g,h));2d;++d)e[d]=c[d].toFixed(6);d=e.join(",")}else d=c.join(",");Sf(b,"matrix3d("+d+")")}else if(Qf()){e=[c[0],c[1],c[4],c[5],c[12],c[13]];if(m(6)){var f=Array(6);for(d=0;6>d;++d)f[d]=e[d].toFixed(6);d=f.join(",")}else d=e.join(",");Sf(b,"matrix("+d+")")}else b.style.left=Math.round(c[12])+"px",b.style.top=Math.round(c[13])+"px"};var Uf=["experimental-webgl","webgl","webkit-3d","moz-webgl"];function Vf(b,c){var d,e,f=Uf.length;for(e=0;e=this.left&&b.right<=this.right&&b.top>=this.top&&b.bottom<=this.bottom:b.x>=this.left&&b.x<=this.right&&b.y>=this.top&&b.y<=this.bottom:!1}; -l.ceil=function(){this.top=Math.ceil(this.top);this.right=Math.ceil(this.right);this.bottom=Math.ceil(this.bottom);this.left=Math.ceil(this.left);return this};l.floor=function(){this.top=Math.floor(this.top);this.right=Math.floor(this.right);this.bottom=Math.floor(this.bottom);this.left=Math.floor(this.left);return this};l.round=function(){this.top=Math.round(this.top);this.right=Math.round(this.right);this.bottom=Math.round(this.bottom);this.left=Math.round(this.left);return this}; -l.scale=function(b,c){var d=ja(c)?c:b;this.left*=b;this.right*=b;this.top*=d;this.bottom*=d;return this};function Cg(b,c,d,e){this.left=b;this.top=c;this.width=d;this.height=e}l=Cg.prototype;l.clone=function(){return new Cg(this.left,this.top,this.width,this.height)};l.contains=function(b){return b instanceof Cg?this.left<=b.left&&this.left+this.width>=b.left+b.width&&this.top<=b.top&&this.top+this.height>=b.top+b.height:b.x>=this.left&&b.x<=this.left+this.width&&b.y>=this.top&&b.y<=this.top+this.height}; -function Dg(b,c){var d=c.x= -A.a&&D.b<=A.d&&D.d>=A.b){u=!0;break a}}u=!1}u?(k in s&&delete s[k],r[k]=h):s[k]=h}c=[r,s];d=c[0];c=c[1];for(var x in this.n)x in d?(this.e[x]||(Mg(this.n[x],!0),this.e[x]=!0),delete d[x]):x in c?(this.e[x]&&(Mg(this.n[x],!1),delete this.e[x]),delete c[x]):(Lf(this.n[x]),delete this.n[x],delete this.e[x]);for(x in d)p=Gf("LI"),p.innerHTML=d[x].d,this.r.appendChild(p),this.n[x]=p,this.e[x]=!0;for(x in c)p=Gf("LI"),p.innerHTML=c[x].d,Mg(p,!1),this.r.appendChild(p),this.n[x]=p;x=!rb(this.e)||!rb(b.logos); -this.q!=x&&(Mg(this.element,x),this.q=x);x&&rb(this.e)?yg(this.element,"ol-logo-only"):zg(this.element,"ol-logo-only");var T;b=b.logos;x=this.H;for(T in x)T in b||(Lf(x[T]),delete x[T]);for(var O in b)O in x||(T=new Image,T.src=O,d=b[O],""===d?d=T:(d=Cf("A",{href:d}),d.appendChild(T)),this.p.appendChild(d),x[O]=d);Mg(this.p,!rb(b))}}l=Vg.prototype;l.oj=function(b){b.preventDefault();Xg(this)};function Xg(b){Ag(b.element,"ol-collapsed");b.c?Mf(b.s,b.F):Mf(b.F,b.s);b.c=!b.c}l.nj=function(){return this.g}; -l.qj=function(b){this.g!==b&&(this.g=b,Ag(this.element,"ol-uncollapsible"),!b&&this.c&&Xg(this))};l.pj=function(b){this.g&&this.c!==b&&Xg(this)};l.mj=function(){return this.c};function Yg(b){b=m(b)?b:{};var c=m(b.className)?b.className:"ol-rotate",d=m(b.label)?b.label:"\u21e7";this.c=null;ia(d)?this.c=Cf("SPAN","ol-compass",d):(this.c=d,yg(this.c,"ol-compass"));d=Cf("BUTTON",{"class":c+"-reset",type:"button",title:m(b.tipLabel)?b.tipLabel:"Reset rotation"},this.c);w(d,"click",Yg.prototype.p,!1,this);w(d,["mouseout",sc],function(){this.blur()},!1);c=Cf("DIV",c+" ol-unselectable ol-control",d);Ug.call(this,{element:c,render:m(b.render)?b.render:Zg,target:b.target});this.g= -m(b.duration)?b.duration:250;this.e=m(b.autoHide)?b.autoHide:!0;this.n=void 0;this.e&&yg(this.element,"ol-hidden")}v(Yg,Ug);Yg.prototype.p=function(b){b.preventDefault();b=this.a;var c=b.a();if(null!==c){for(var d=c.c();d<-Math.PI;)d+=2*Math.PI;for(;d>Math.PI;)d-=2*Math.PI;m(d)&&(02*this.b&&vh(this),!0):!1};function vh(b){if(b.b!=b.a.length){for(var c=0,d=0;c=b||96<=b&&106>=b||65<=b&&90>=b||Db&&0==b)return!0;switch(b){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!0;default:return!1}}function Bh(b){if(Cb)b=Ch(b);else if(Eb&&Db)a:switch(b){case 93:b=91;break a}return b} -function Ch(b){switch(b){case 61:return 187;case 59:return 186;case 173:return 189;case 224:return 91;case 0:return 224;default:return b}};function Dh(b,c){ed.call(this);b&&Eh(this,b,c)}v(Dh,ed);l=Dh.prototype;l.aa=null;l.ud=null;l.te=null;l.vd=null;l.Na=-1;l.Gb=-1;l.ge=!1; -var Fh={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},Gh={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},Hh=Bb||Db&&Mb("525"),Ih=Eb&&Cb; -Dh.prototype.a=function(b){Db&&(17==this.Na&&!b.j||18==this.Na&&!b.d||Eb&&91==this.Na&&!b.n)&&(this.Gb=this.Na=-1);-1==this.Na&&(b.j&&17!=b.f?this.Na=17:b.d&&18!=b.f?this.Na=18:b.n&&91!=b.f&&(this.Na=91));Hh&&!zh(b.f,this.Na,b.c,b.j,b.d)?this.handleEvent(b):(this.Gb=Bh(b.f),Ih&&(this.ge=b.d))};Dh.prototype.d=function(b){this.Gb=this.Na=-1;this.ge=b.d}; -Dh.prototype.handleEvent=function(b){var c=b.a,d,e,f=c.altKey;Bb&&"keypress"==b.type?(d=this.Gb,e=13!=d&&27!=d?c.keyCode:0):Db&&"keypress"==b.type?(d=this.Gb,e=0<=c.charCode&&63232>c.charCode&&Ah(d)?c.charCode:0):Ab?(d=this.Gb,e=Ah(d)?c.keyCode:0):(d=c.keyCode||this.Gb,e=c.charCode||0,Ih&&(f=this.ge),Eb&&63==e&&224==d&&(d=191));var g=d=Bh(d),h=c.keyIdentifier;d?63232<=d&&d in Fh?g=Fh[d]:25==d&&b.c&&(g=9):h&&h in Gh&&(g=Gh[h]);this.Na=g;b=new Kh(g,e,0,c);b.d=f;this.dispatchEvent(b)}; -function Eh(b,c,d){b.vd&&Lh(b);b.aa=c;b.ud=w(b.aa,"keypress",b,d);b.te=w(b.aa,"keydown",b.a,d,b);b.vd=w(b.aa,"keyup",b.d,d,b)}function Lh(b){b.ud&&(Tc(b.ud),Tc(b.te),Tc(b.vd),b.ud=null,b.te=null,b.vd=null);b.aa=null;b.Na=-1;b.Gb=-1}Dh.prototype.M=function(){Dh.R.M.call(this);Lh(this)};function Kh(b,c,d,e){uc.call(this,e);this.type="key";this.f=b;this.i=c}v(Kh,uc);function Mh(b,c){ed.call(this);var d=this.aa=b;(d=la(d)&&1==d.nodeType?this.aa:this.aa?this.aa.body:null)&&Fg(d,"direction");this.a=w(this.aa,Cb?"DOMMouseScroll":"mousewheel",this,c)}v(Mh,ed); -Mh.prototype.handleEvent=function(b){var c=0,d=0,e=0;b=b.a;if("mousewheel"==b.type){d=1;if(Bb||Db&&(Fb||Mb("532.0")))d=40;e=Nh(-b.wheelDelta,d);m(b.wheelDeltaX)?(c=Nh(-b.wheelDeltaX,d),d=Nh(-b.wheelDeltaY,d)):d=e}else e=b.detail,100e&&(e=-3),m(b.axis)&&b.axis===b.HORIZONTAL_AXIS?c=e:d=e;ja(this.d)&&Ub(c,-this.d,this.d);ja(this.b)&&(d=Ub(d,-this.b,this.b));c=new Oh(e,b,0,d);this.dispatchEvent(c)};function Nh(b,c){return Db&&(Eb||Hb)&&0!=b%c?b:b/c} -Mh.prototype.M=function(){Mh.R.M.call(this);Tc(this.a);this.a=null};function Oh(b,c,d,e){uc.call(this,c);this.type="mousewheel";this.detail=b;this.l=e}v(Oh,uc);function Ph(b,c,d){pc.call(this,b);this.a=c;b=m(d)?d:{};this.buttons=Qh(b);this.pressure=Rh(b,this.buttons);this.bubbles=ub(b,"bubbles",!1);this.cancelable=ub(b,"cancelable",!1);this.view=ub(b,"view",null);this.detail=ub(b,"detail",null);this.screenX=ub(b,"screenX",0);this.screenY=ub(b,"screenY",0);this.clientX=ub(b,"clientX",0);this.clientY=ub(b,"clientY",0);this.button=ub(b,"button",0);this.relatedTarget=ub(b,"relatedTarget",null);this.pointerId=ub(b,"pointerId",0);this.width=ub(b,"width",0);this.height= -ub(b,"height",0);this.pointerType=ub(b,"pointerType","");this.isPrimary=ub(b,"isPrimary",!1);c.preventDefault&&(this.preventDefault=function(){c.preventDefault()})}v(Ph,pc);function Qh(b){if(b.buttons||Sh)b=b.buttons;else switch(b.which){case 1:b=1;break;case 2:b=4;break;case 3:b=2;break;default:b=0}return b}function Rh(b,c){var d=0;b.pressure?d=b.pressure:d=c?.5:0;return d}var Sh=!1;try{Sh=1===(new MouseEvent("click",{buttons:1})).buttons}catch(Th){};function Uh(b,c){this.a=b;this.f=c};function Vh(b){Uh.call(this,b,{mousedown:this.Ii,mousemove:this.Ji,mouseup:this.Mi,mouseover:this.Li,mouseout:this.Ki});this.d=b.d;this.b=[]}v(Vh,Uh);function Wh(b,c){for(var d=b.b,e=c.clientX,f=c.clientY,g=0,h=d.length,k;g=Math.abs(e-k[0])&&25>=n)return!0}return!1}function Xh(b){var c=Yh(b,b.a),d=c.preventDefault;c.preventDefault=function(){b.preventDefault();d()};c.pointerId=1;c.isPrimary=!0;c.pointerType="mouse";return c}l=Vh.prototype; -l.Ii=function(b){if(!Wh(this,b)){(1).toString()in this.d&&this.cancel(b);var c=Xh(b);this.d[(1).toString()]=b;Zh(this.a,$h,c,b)}};l.Ji=function(b){if(!Wh(this,b)){var c=Xh(b);Zh(this.a,ai,c,b)}};l.Mi=function(b){if(!Wh(this,b)){var c=this.d[(1).toString()];c&&c.button===b.button&&(c=Xh(b),Zh(this.a,bi,c,b),tb(this.d,(1).toString()))}};l.Li=function(b){if(!Wh(this,b)){var c=Xh(b);ci(this.a,c,b)}};l.Ki=function(b){if(!Wh(this,b)){var c=Xh(b);di(this.a,c,b)}}; -l.cancel=function(b){var c=Xh(b);this.a.cancel(c,b);tb(this.d,(1).toString())};function ei(b){Uh.call(this,b,{MSPointerDown:this.Ri,MSPointerMove:this.Si,MSPointerUp:this.Vi,MSPointerOut:this.Ti,MSPointerOver:this.Ui,MSPointerCancel:this.Qi,MSGotPointerCapture:this.Oi,MSLostPointerCapture:this.Pi});this.d=b.d;this.b=["","unavailable","touch","pen","mouse"]}v(ei,Uh);function fi(b,c){var d=c;ja(c.a.pointerType)&&(d=Yh(c,c.a),d.pointerType=b.b[c.a.pointerType]);return d}l=ei.prototype;l.Ri=function(b){this.d[b.a.pointerId]=b;var c=fi(this,b);Zh(this.a,$h,c,b)}; -l.Si=function(b){var c=fi(this,b);Zh(this.a,ai,c,b)};l.Vi=function(b){var c=fi(this,b);Zh(this.a,bi,c,b);tb(this.d,b.a.pointerId)};l.Ti=function(b){var c=fi(this,b);di(this.a,c,b)};l.Ui=function(b){var c=fi(this,b);ci(this.a,c,b)};l.Qi=function(b){var c=fi(this,b);this.a.cancel(c,b);tb(this.d,b.a.pointerId)};l.Pi=function(b){this.a.dispatchEvent(new Ph("lostpointercapture",b,b.a))};l.Oi=function(b){this.a.dispatchEvent(new Ph("gotpointercapture",b,b.a))};function gi(b){Uh.call(this,b,{pointerdown:this.Sk,pointermove:this.Tk,pointerup:this.Wk,pointerout:this.Uk,pointerover:this.Vk,pointercancel:this.Rk,gotpointercapture:this.Yh,lostpointercapture:this.Hi})}v(gi,Uh);l=gi.prototype;l.Sk=function(b){hi(this.a,b)};l.Tk=function(b){hi(this.a,b)};l.Wk=function(b){hi(this.a,b)};l.Uk=function(b){hi(this.a,b)};l.Vk=function(b){hi(this.a,b)};l.Rk=function(b){hi(this.a,b)};l.Hi=function(b){hi(this.a,b)};l.Yh=function(b){hi(this.a,b)};function ii(b,c){Uh.call(this,b,{touchstart:this.Ql,touchmove:this.Pl,touchend:this.Ol,touchcancel:this.Nl});this.d=b.d;this.g=c;this.b=void 0;this.e=0;this.c=void 0}v(ii,Uh);l=ii.prototype;l.gg=function(){this.e=0;this.c=void 0}; -function ji(b,c,d){c=Yh(c,d);c.pointerId=d.identifier+2;c.bubbles=!0;c.cancelable=!0;c.detail=b.e;c.button=0;c.buttons=1;c.width=d.webkitRadiusX||d.radiusX||0;c.height=d.webkitRadiusY||d.radiusY||0;c.pressure=d.webkitForce||d.force||.5;c.isPrimary=b.b===d.identifier;c.pointerType="touch";c.clientX=d.clientX;c.clientY=d.clientY;c.screenX=d.screenX;c.screenY=d.screenY;return c} -function ki(b,c,d){function e(){c.preventDefault()}var f=Array.prototype.slice.call(c.a.changedTouches),g=f.length,h,k;for(h=0;h=c.length){var f=[],g,h,k;for(g=0;g=b.minResolution&&c=this.minZoom;){if(c.call(d,b,Ui(this,f,b,e)))return!0;--b}return!1};l.gd=function(){return this.maxZoom}; -l.hd=function(){return this.minZoom};l.Lb=function(b){return null===this.c?this.e[b]:this.c};l.na=function(b){return this.a[b]};l.Kd=function(){return this.a};l.md=function(b,c,d){return b[0]b.c&&(b.c=e.c),e.bb.d&&(b.d=e.d)):b[c][d]=e:(b[c]={},b[c][d]=e)} -function jj(b,c,d,e){return function(f,g,h){f=c.Fb(f,g,h,d,e);return b(f)?f:null}}function kj(b,c,d){return[c*(Math.round(b[0]/c)+d[0]%2/2),c*(Math.round(b[1]/c)+d[1]%2/2)]} -function lj(b,c,d,e,f,g,h,k,n,p){var q=ma(c).toString();q in b.wantedTiles||(b.wantedTiles[q]={});var r=b.wantedTiles[q];b=b.tileQueue;var s=d.minZoom,u,y,A,z,D,x;for(x=h;x>=s;--x)for(y=Ui(d,g,x,y),A=d.na(x),z=y.a;z<=y.c;++z)for(D=y.b;D<=y.d;++D)h-x<=k?(u=c.Fb(x,z,D,e,f),0==u.state&&(r[kf(u.a)]=!0,u.nb()in b.b||mj(b,[u,q,Xi(d,u.a),A])),m(n)&&n.call(p,u)):c.Oe(x,z,D)};function nj(b){this.p=b.opacity;this.q=b.rotateWithView;this.i=b.rotation;this.n=b.scale;this.r=b.snapToPixel}l=nj.prototype;l.Fd=function(){return this.p};l.kd=function(){return this.q};l.Gd=function(){return this.i};l.Hd=function(){return this.n};l.ld=function(){return this.r};l.Id=function(b){this.i=b};l.Jd=function(b){this.n=b};function oj(b){b=m(b)?b:{};this.f=m(b.anchor)?b.anchor:[.5,.5];this.c=null;this.d=m(b.anchorOrigin)?b.anchorOrigin:"top-left";this.g=m(b.anchorXUnits)?b.anchorXUnits:"fraction";this.j=m(b.anchorYUnits)?b.anchorYUnits:"fraction";var c=m(b.crossOrigin)?b.crossOrigin:null,d=m(b.img)?b.img:null,e=b.src;m(e)&&0!==e.length||null===d||(e=d.src);var f=m(b.src)?0:2,g=pj.Ma(),h=g.get(e,c);null===h&&(h=new qj(d,e,c,f),g.set(e,c,h));this.a=h;this.s=m(b.offset)?b.offset:[0,0];this.b=m(b.offsetOrigin)?b.offsetOrigin: -"top-left";this.e=null;this.l=m(b.size)?b.size:null;nj.call(this,{opacity:m(b.opacity)?b.opacity:1,rotation:m(b.rotation)?b.rotation:0,scale:m(b.scale)?b.scale:1,snapToPixel:m(b.snapToPixel)?b.snapToPixel:!0,rotateWithView:m(b.rotateWithView)?b.rotateWithView:!1})}v(oj,nj);l=oj.prototype; -l.ub=function(){if(null!==this.c)return this.c;var b=this.f,c=this.cb();if("fraction"==this.g||"fraction"==this.j){if(null===c)return null;b=this.f.slice();"fraction"==this.g&&(b[0]*=c[0]);"fraction"==this.j&&(b[1]*=c[1])}if("top-left"!=this.d){if(null===c)return null;b===this.f&&(b=this.f.slice());if("top-right"==this.d||"bottom-right"==this.d)b[0]=-b[0]+c[0];if("bottom-left"==this.d||"bottom-right"==this.d)b[1]=-b[1]+c[1]}return this.c=b};l.zb=function(){return this.a.a};l.ed=function(){return this.a.d}; -l.Jc=function(){return this.a.b};l.Ed=function(){var b=this.a;if(null===b.f)if(b.j){var c=b.d[0],d=b.d[1],e=Pf(c,d);e.fillRect(0,0,c,d);b.f=e.canvas}else b.f=b.a;return b.f};l.Ab=function(){if(null!==this.e)return this.e;var b=this.s;if("top-left"!=this.b){var c=this.cb(),d=this.a.d;if(null===c||null===d)return null;b=b.slice();if("top-right"==this.b||"bottom-right"==this.b)b[0]=d[0]-c[0]-b[0];if("bottom-left"==this.b||"bottom-right"==this.b)b[1]=d[1]-c[1]-b[1]}return this.e=b};l.hk=function(){return this.a.e}; -l.cb=function(){return null===this.l?this.a.d:this.l};l.ve=function(b,c){return w(this.a,"change",b,!1,c)};l.load=function(){this.a.load()};l.Ne=function(b,c){Sc(this.a,"change",b,!1,c)};function qj(b,c,d,e){ed.call(this);this.f=null;this.a=null===b?new Image:b;null!==d&&(this.a.crossOrigin=d);this.c=null;this.b=e;this.d=null;this.e=c;this.j=!1}v(qj,ed);qj.prototype.g=function(){this.b=3;Oa(this.c,Tc);this.c=null;this.dispatchEvent("change")}; -qj.prototype.i=function(){this.b=2;this.d=[this.a.width,this.a.height];Oa(this.c,Tc);this.c=null;var b=Pf(1,1);b.drawImage(this.a,0,0);try{b.getImageData(0,0,1,1)}catch(c){this.j=!0}this.dispatchEvent("change")};qj.prototype.load=function(){if(0==this.b){this.b=1;this.c=[Rc(this.a,"error",this.g,!1,this),Rc(this.a,"load",this.i,!1,this)];try{this.a.src=this.e}catch(b){this.g()}}};function pj(){this.a={};this.d=0}da(pj);pj.prototype.clear=function(){this.a={};this.d=0}; -pj.prototype.get=function(b,c){var d=c+":"+b;return d in this.a?this.a[d]:null};pj.prototype.set=function(b,c,d){this.a[c+":"+b]=d;++this.d};function rj(b,c,d,e,f,g,h,k){Kd(b);0===c&&0===d||Nd(b,c,d);1==e&&1==f||Od(b,e,f);0!==g&&Pd(b,g);0===h&&0===k||Nd(b,h,k);return b}function sj(b,c){return b[0]==c[0]&&b[1]==c[1]&&b[4]==c[4]&&b[5]==c[5]&&b[12]==c[12]&&b[13]==c[13]}function tj(b,c,d){var e=b[1],f=b[5],g=b[13],h=c[0];c=c[1];d[0]=b[0]*h+b[4]*c+b[12];d[1]=e*h+f*c+g;return d};function uj(b,c){kc.call(this);this.b=c;this.c=null;this.g={}}v(uj,kc);function vj(b){var c=b.viewState,d=b.coordinateToPixelMatrix;rj(d,b.size[0]/2,b.size[1]/2,1/c.resolution,-1/c.resolution,-c.rotation,-c.center[0],-c.center[1]);Md(d,b.pixelToCoordinateMatrix)}l=uj.prototype;l.$c=function(b){return new cj(this,b)};l.M=function(){jb(this.g,oc);uj.R.M.call(this)}; -function wj(){var b=pj.Ma();if(32>1;){var n=2*c+1,p=2*c+2,n=pc;){var h=d-1>>1;if(b[h]>g)e[d]=e[h],b[d]=b[h],d=h;else break}e[d]=f;b[d]=g}function Dj(b){var c=b.e,d=b.a,e=b.d,f=0,g=d.length,h,k,n;for(k=0;k>1)-1;0<=c;c--)Bj(b,c)};function Ej(b,c){zj.call(this,function(c){return b.apply(null,c)},function(b){return b[0].nb()});this.j=c;this.c=0}v(Ej,zj);Ej.prototype.g=function(){--this.c;this.j()};function Fj(b,c,d){this.c=b;this.b=c;this.e=d;this.a=[];this.d=this.f=0}Fj.prototype.update=function(b,c){this.a.push(b,c,ua())};function Gj(b,c){var d=b.c,e=b.d,f=b.b-e,g=Hj(b);return df({source:c,duration:g,easing:function(b){return e*(Math.exp(d*b*g)-1)/f}})}function Hj(b){return Math.log(b.b/b.d)/b.c};function Ij(b){od.call(this);this.n=null;this.b(!0);this.handleEvent=b.handleEvent}v(Ij,od);Ij.prototype.a=function(){return this.get("active")};Ij.prototype.getActive=Ij.prototype.a;Ij.prototype.b=function(b){this.set("active",b)};Ij.prototype.setActive=Ij.prototype.b;Ij.prototype.setMap=function(b){this.n=b};function Jj(b,c,d,e,f){if(null!=d){var g=c.c(),h=c.b();m(g)&&m(h)&&m(f)&&0d.a.length)d=!1;else{var e=ua()-d.e,f=d.a.length-3;if(d.a[f+2]e;)g-=3;var e=d.a[f+2]-d.a[g+2],h=d.a[f]-d.a[g],f=d.a[f+1]-d.a[g+1];d.f=Math.atan2(f,h);d.d=Math.sqrt(h*h+f*f)/e;d=d.d>d.b}}d&&(d=this.c,d=(d.b-d.d)/d.c,f=this.c.f,g=c.b(),this.g=Gj(this.c,g),b.Wa(this.g),g=b.e(g),d=b.ia([g[0]-d*Math.cos(f),g[1]-d*Math.sin(f)]),d=c.i(d),c.Ra(d));Ze(c,-1);b.render(); -return!1}this.e=null;return!0}function Zj(b){if(0b||0!==this.g&&b<=this.g)return this;var c=b.toString();if(this.e.hasOwnProperty(c))return this.e[c];var d=this.mc(b);if(d.k.lengthf&&(f=g);g=k;h=n}return f}function sk(b,c,d,e,f){var g,h;g=0;for(h=d.length;gk){for(;cu&&(p=q,u=x)}u>f&&(n[(p-c)/e]=1,s+eV&&JbV)&&(0>ta&&Qata)||(A[h++]=x,A[h++]=T,z=x,D=T);x=O;T=W}}A[h++]=x;A[h++]=T}}k.push(h);c=q}return h};function Ck(b,c){ik.call(this);this.b=this.j=-1;this.V(b,c)}v(Ck,ik);l=Ck.prototype;l.clone=function(){var b=new Ck(null);Dk(b,this.a,this.k.slice());return b};l.Xa=function(b,c,d,e){if(eg!=q>g&&f<(p-k)*(g-n)/(q-n)+k&&(h=!h);k=p;n=q}return h}function Ik(b,c,d,e,f,g){if(0===d.length||!Hk(b,c,d[0],e,f,g))return!1;var h;c=1;for(h=d.length;cr&&(p=(p+q)/2,Ik(b,c,d,e,p,s)&&(y=p,r=A));p=q}isNaN(y)&&(y=f[g]);return m(h)?(h.push(y,s),h):[y,s]};function Kk(b,c,d,e,f){for(var g=[b[c],b[c+1]],h=[],k;c+e=f[0]&&g[2]<=f[2]||g[1]>=f[1]&&g[3]<=f[3]?!0:Kk(b,c,d,e,function(b,c){var d=!1,e=$d(f,b),g=$d(f,c);if(1===e||1===g)d=!0;else{var r=f[0],s=f[1],u=f[2],y=f[3],A=c[0],z=c[1],D=(z-b[1])/(A-b[0]);g&2&&!(e&2)?(s=A-(z-y)/D,d=s>=r&&s<=u):g&4&&!(e&4)?(r=z-(A-u)*D,d=r>=s&&r<=y):g&8&&!(e&8)?(s=A-(z-s)/D,d=s>=r&&s<=u):g&16&&!(e&16)&&(r=z-(A-r)*D,d=r>=s&&r<=y)}return d}):!1} -function Mk(b,c,d,e,f){var g=d[0];if(!(Lk(b,c,g,e,f)||Hk(b,c,g,e,f[0],f[1])||Hk(b,c,g,e,f[0],f[3])||Hk(b,c,g,e,f[2],f[1])||Hk(b,c,g,e,f[2],f[3])))return!1;if(1===d.length)return!0;c=1;for(g=d.length;cb||this.b.length<=b)return null;var c=new Ck(null);Dk(c,this.a,this.k.slice(0===b?0:this.b[b-1],this.b[b]));return c};l.fd=function(){var b=this.a,c=this.k,d=this.b,e=[],f=0,g,h;g=0;for(h=d.length;gf;++f)e[f]=c.charCodeAt(d++)|c.charCodeAt(d++)<<8|c.charCodeAt(d++)<<16|c.charCodeAt(d++)<<24;else for(f=0;16>f;++f)e[f]=c[d++]|c[d++]<<8|c[d++]<<16|c[d++]<<24;c=b.a[0];d=b.a[1];var f=b.a[2],g=b.a[3],h=0,h=c+(g^d&(f^g))+e[0]+3614090360&4294967295;c=d+(h<<7&4294967295|h>>>25);h=g+(f^c&(d^f))+e[1]+3905402710&4294967295;g=c+(h<<12&4294967295|h>>>20);h=f+(d^g&(c^d))+e[2]+606105819&4294967295;f=g+(h<<17&4294967295|h>>>15);h=d+(c^f&(g^ -c))+e[3]+3250441966&4294967295;d=f+(h<<22&4294967295|h>>>10);h=c+(g^d&(f^g))+e[4]+4118548399&4294967295;c=d+(h<<7&4294967295|h>>>25);h=g+(f^c&(d^f))+e[5]+1200080426&4294967295;g=c+(h<<12&4294967295|h>>>20);h=f+(d^g&(c^d))+e[6]+2821735955&4294967295;f=g+(h<<17&4294967295|h>>>15);h=d+(c^f&(g^c))+e[7]+4249261313&4294967295;d=f+(h<<22&4294967295|h>>>10);h=c+(g^d&(f^g))+e[8]+1770035416&4294967295;c=d+(h<<7&4294967295|h>>>25);h=g+(f^c&(d^f))+e[9]+2336552879&4294967295;g=c+(h<<12&4294967295|h>>>20);h=f+ -(d^g&(c^d))+e[10]+4294925233&4294967295;f=g+(h<<17&4294967295|h>>>15);h=d+(c^f&(g^c))+e[11]+2304563134&4294967295;d=f+(h<<22&4294967295|h>>>10);h=c+(g^d&(f^g))+e[12]+1804603682&4294967295;c=d+(h<<7&4294967295|h>>>25);h=g+(f^c&(d^f))+e[13]+4254626195&4294967295;g=c+(h<<12&4294967295|h>>>20);h=f+(d^g&(c^d))+e[14]+2792965006&4294967295;f=g+(h<<17&4294967295|h>>>15);h=d+(c^f&(g^c))+e[15]+1236535329&4294967295;d=f+(h<<22&4294967295|h>>>10);h=c+(f^g&(d^f))+e[1]+4129170786&4294967295;c=d+(h<<5&4294967295| -h>>>27);h=g+(d^f&(c^d))+e[6]+3225465664&4294967295;g=c+(h<<9&4294967295|h>>>23);h=f+(c^d&(g^c))+e[11]+643717713&4294967295;f=g+(h<<14&4294967295|h>>>18);h=d+(g^c&(f^g))+e[0]+3921069994&4294967295;d=f+(h<<20&4294967295|h>>>12);h=c+(f^g&(d^f))+e[5]+3593408605&4294967295;c=d+(h<<5&4294967295|h>>>27);h=g+(d^f&(c^d))+e[10]+38016083&4294967295;g=c+(h<<9&4294967295|h>>>23);h=f+(c^d&(g^c))+e[15]+3634488961&4294967295;f=g+(h<<14&4294967295|h>>>18);h=d+(g^c&(f^g))+e[4]+3889429448&4294967295;d=f+(h<<20&4294967295| -h>>>12);h=c+(f^g&(d^f))+e[9]+568446438&4294967295;c=d+(h<<5&4294967295|h>>>27);h=g+(d^f&(c^d))+e[14]+3275163606&4294967295;g=c+(h<<9&4294967295|h>>>23);h=f+(c^d&(g^c))+e[3]+4107603335&4294967295;f=g+(h<<14&4294967295|h>>>18);h=d+(g^c&(f^g))+e[8]+1163531501&4294967295;d=f+(h<<20&4294967295|h>>>12);h=c+(f^g&(d^f))+e[13]+2850285829&4294967295;c=d+(h<<5&4294967295|h>>>27);h=g+(d^f&(c^d))+e[2]+4243563512&4294967295;g=c+(h<<9&4294967295|h>>>23);h=f+(c^d&(g^c))+e[7]+1735328473&4294967295;f=g+(h<<14&4294967295| -h>>>18);h=d+(g^c&(f^g))+e[12]+2368359562&4294967295;d=f+(h<<20&4294967295|h>>>12);h=c+(d^f^g)+e[5]+4294588738&4294967295;c=d+(h<<4&4294967295|h>>>28);h=g+(c^d^f)+e[8]+2272392833&4294967295;g=c+(h<<11&4294967295|h>>>21);h=f+(g^c^d)+e[11]+1839030562&4294967295;f=g+(h<<16&4294967295|h>>>16);h=d+(f^g^c)+e[14]+4259657740&4294967295;d=f+(h<<23&4294967295|h>>>9);h=c+(d^f^g)+e[1]+2763975236&4294967295;c=d+(h<<4&4294967295|h>>>28);h=g+(c^d^f)+e[4]+1272893353&4294967295;g=c+(h<<11&4294967295|h>>>21);h=f+(g^ -c^d)+e[7]+4139469664&4294967295;f=g+(h<<16&4294967295|h>>>16);h=d+(f^g^c)+e[10]+3200236656&4294967295;d=f+(h<<23&4294967295|h>>>9);h=c+(d^f^g)+e[13]+681279174&4294967295;c=d+(h<<4&4294967295|h>>>28);h=g+(c^d^f)+e[0]+3936430074&4294967295;g=c+(h<<11&4294967295|h>>>21);h=f+(g^c^d)+e[3]+3572445317&4294967295;f=g+(h<<16&4294967295|h>>>16);h=d+(f^g^c)+e[6]+76029189&4294967295;d=f+(h<<23&4294967295|h>>>9);h=c+(d^f^g)+e[9]+3654602809&4294967295;c=d+(h<<4&4294967295|h>>>28);h=g+(c^d^f)+e[12]+3873151461&4294967295; -g=c+(h<<11&4294967295|h>>>21);h=f+(g^c^d)+e[15]+530742520&4294967295;f=g+(h<<16&4294967295|h>>>16);h=d+(f^g^c)+e[2]+3299628645&4294967295;d=f+(h<<23&4294967295|h>>>9);h=c+(f^(d|~g))+e[0]+4096336452&4294967295;c=d+(h<<6&4294967295|h>>>26);h=g+(d^(c|~f))+e[7]+1126891415&4294967295;g=c+(h<<10&4294967295|h>>>22);h=f+(c^(g|~d))+e[14]+2878612391&4294967295;f=g+(h<<15&4294967295|h>>>17);h=d+(g^(f|~c))+e[5]+4237533241&4294967295;d=f+(h<<21&4294967295|h>>>11);h=c+(f^(d|~g))+e[12]+1700485571&4294967295;c=d+ -(h<<6&4294967295|h>>>26);h=g+(d^(c|~f))+e[3]+2399980690&4294967295;g=c+(h<<10&4294967295|h>>>22);h=f+(c^(g|~d))+e[10]+4293915773&4294967295;f=g+(h<<15&4294967295|h>>>17);h=d+(g^(f|~c))+e[1]+2240044497&4294967295;d=f+(h<<21&4294967295|h>>>11);h=c+(f^(d|~g))+e[8]+1873313359&4294967295;c=d+(h<<6&4294967295|h>>>26);h=g+(d^(c|~f))+e[15]+4264355552&4294967295;g=c+(h<<10&4294967295|h>>>22);h=f+(c^(g|~d))+e[6]+2734768916&4294967295;f=g+(h<<15&4294967295|h>>>17);h=d+(g^(f|~c))+e[13]+1309151649&4294967295; -d=f+(h<<21&4294967295|h>>>11);h=c+(f^(d|~g))+e[4]+4149444226&4294967295;c=d+(h<<6&4294967295|h>>>26);h=g+(d^(c|~f))+e[11]+3174756917&4294967295;g=c+(h<<10&4294967295|h>>>22);h=f+(c^(g|~d))+e[2]+718787259&4294967295;f=g+(h<<15&4294967295|h>>>17);h=d+(g^(f|~c))+e[9]+3951481745&4294967295;b.a[0]=b.a[0]+c&4294967295;b.a[1]=b.a[1]+(f+(h<<21&4294967295|h>>>11))&4294967295;b.a[2]=b.a[2]+f&4294967295;b.a[3]=b.a[3]+g&4294967295} -dl.prototype.update=function(b,c){m(c)||(c=b.length);for(var d=c-this.d,e=this.f,f=this.b,g=0;gc.b?c.d:2*c.d)-c.b);d[0]=128;for(b=1;bb;++b)for(var f=0;32>f;f+=8)d[e++]=c.a[b]>>>f&255; -if(8192>d.length)c=String.fromCharCode.apply(null,d);else for(c="",b=0;bthis.l&&(this.c=!0));this.g=d;b=b.map;d=Jg(b.b);e=Xj(this.f);e[0]-=d.x;e[1]-=d.y;this.e=b.ia(e);this.c&&(d=b.a(),e=d.c(),b.render(),Jj(b,d,e+c,this.e))}function Bl(b){if(2>this.f.length){b=b.map;var c=b.a();Ze(c,-1);if(this.c){var d=c.c(),e=this.e,d=c.constrainRotation(d,0);Jj(b,c,d,e,250)}return!1}return!0} -function zl(b){return 2<=this.f.length?(b=b.map,this.e=null,this.g=void 0,this.c=!1,this.i=0,this.p||Ze(b.a(),1),b.render(),!0):!1}yl.prototype.q=Yc;function Cl(b){Vj.call(this,{handleDownEvent:Dl,handleDragEvent:El,handleUpEvent:Fl});b=m(b)?b:{};this.e=null;this.i=m(b.duration)?b.duration:400;this.c=void 0;this.g=1}v(Cl,Vj);function El(b){var c=1,d=this.f[0],e=this.f[1],f=d.clientX-e.clientX,d=d.clientY-e.clientY,f=Math.sqrt(f*f+d*d);m(this.c)&&(c=this.c/f);this.c=f;1!=c&&(this.g=c);b=b.map;var f=b.a(),d=f.a(),e=Jg(b.b),g=Xj(this.f);g[0]-=e.x;g[1]-=e.y;this.e=b.ia(g);b.render();Lj(b,f,d*c,this.e)} -function Fl(b){if(2>this.f.length){b=b.map;var c=b.a();Ze(c,-1);var d=c.a(),e=this.e,f=this.i,d=c.constrainResolution(d,0,this.g-1);Lj(b,c,d,e,f);return!1}return!0}function Dl(b){return 2<=this.f.length?(b=b.map,this.e=null,this.c=void 0,this.g=1,this.p||Ze(b.a(),1),b.render(),!0):!1}Cl.prototype.q=Yc;function Gl(b){b=m(b)?b:{};var c=new C,d=new Fj(-.005,.05,100);(m(b.altShiftDragRotate)?b.altShiftDragRotate:1)&&c.push(new ck);(m(b.doubleClickZoom)?b.doubleClickZoom:1)&&c.push(new Mj({delta:b.zoomDelta,duration:b.zoomDuration}));(m(b.dragPan)?b.dragPan:1)&&c.push(new Yj({kinetic:d}));(m(b.pinchRotate)?b.pinchRotate:1)&&c.push(new yl);(m(b.pinchZoom)?b.pinchZoom:1)&&c.push(new Cl({duration:b.zoomDuration}));if(m(b.keyboard)?b.keyboard:1)c.push(new sl),c.push(new ul({delta:b.zoomDelta,duration:b.zoomDuration})); -(m(b.mouseWheelZoom)?b.mouseWheelZoom:1)&&c.push(new wl({duration:b.zoomDuration}));(m(b.shiftDragZoom)?b.shiftDragZoom:1)&&c.push(new rl);return c};function H(b){var c=m(b)?b:{};b=wb(c);delete b.layers;c=c.layers;E.call(this,b);this.a=null;w(this,sd("layers"),this.ni,!1,this);null!=c?ga(c)&&(c=new C(c.slice())):c=new C;this.r(c)}v(H,E);l=H.prototype;l.of=function(){this.b()&&this.o()}; -l.ni=function(){null!==this.a&&(Oa(mb(this.a),Tc),this.a=null);var b=this.Zb();if(null!=b){this.a={add:w(b,"add",this.mi,!1,this),remove:w(b,"remove",this.oi,!1,this)};var b=b.a,c,d,e;c=0;for(d=b.length;cthis.f&&(this.f=this.b.lineWidth,this.c=null)}; -function mm(b,c,d){cm.call(this,b,c,d);this.b={bf:void 0,Dc:void 0,yc:void 0,zc:null,Ac:void 0,Bc:void 0,Cc:void 0,fillStyle:void 0,strokeStyle:void 0,lineCap:void 0,lineDash:null,lineJoin:void 0,lineWidth:void 0,miterLimit:void 0}}v(mm,cm); -function nm(b,c,d,e,f){var g=b.b,h=[1];b.d.push(h);b.a.push(h);var k,h=0;for(k=e.length;hthis.f&&(this.f=d.lineWidth,this.c=null))}; -function om(b){var c=b.b,d=c.fillStyle,e=c.strokeStyle,f=c.lineCap,g=c.lineDash,h=c.lineJoin,k=c.lineWidth,n=c.miterLimit;m(d)&&c.bf!=d&&(b.d.push([9,d]),c.bf=c.fillStyle);!m(e)||c.Dc==e&&c.yc==f&&c.zc==g&&c.Ac==h&&c.Bc==k&&c.Cc==n||(b.d.push([10,e,k,f,h,n,g]),c.Dc=e,c.yc=f,c.zc=g,c.Ac=h,c.Bc=k,c.Cc=n)}function pm(b,c,d){cm.call(this,b,c,d);this.s=this.r=this.q=null;this.j="";this.p=this.l=this.n=this.i=0;this.g=this.e=this.b=null}v(pm,cm); -pm.prototype.tb=function(b,c,d,e,f,g){if(""!==this.j&&null!==this.g&&(null!==this.b||null!==this.e)){if(null!==this.b){f=this.b;var h=this.q;if(null===h||h.fillStyle!=f.fillStyle){var k=[9,f.fillStyle];this.d.push(k);this.a.push(k);null===h?this.q={fillStyle:f.fillStyle}:h.fillStyle=f.fillStyle}}null!==this.e&&(f=this.e,h=this.r,null===h||h.lineCap!=f.lineCap||h.lineDash!=f.lineDash||h.lineJoin!=f.lineJoin||h.lineWidth!=f.lineWidth||h.miterLimit!=f.miterLimit||h.strokeStyle!=f.strokeStyle)&&(k=[10, -f.strokeStyle,f.lineWidth,f.lineCap,f.lineJoin,f.miterLimit,f.lineDash,!1],this.d.push(k),this.a.push(k),null===h?this.r={lineCap:f.lineCap,lineDash:f.lineDash,lineJoin:f.lineJoin,lineWidth:f.lineWidth,miterLimit:f.miterLimit,strokeStyle:f.strokeStyle}:(h.lineCap=f.lineCap,h.lineDash=f.lineDash,h.lineJoin=f.lineJoin,h.lineWidth=f.lineWidth,h.miterLimit=f.miterLimit,h.strokeStyle=f.strokeStyle));f=this.g;h=this.s;if(null===h||h.font!=f.font||h.textAlign!=f.textAlign||h.textBaseline!=f.textBaseline)k= -[11,f.font,f.textAlign,f.textBaseline],this.d.push(k),this.a.push(k),null===h?this.s={font:f.font,textAlign:f.textAlign,textBaseline:f.textBaseline}:(h.font=f.font,h.textAlign=f.textAlign,h.textBaseline=f.textBaseline);em(this,g);f=this.coordinates.length;b=dm(this,b,c,d,e,!1);b=[5,f,b,this.j,this.i,this.n,this.l,this.p,null!==this.b,null!==this.e];this.d.push(b);this.a.push(b);hm(this,g)}}; -pm.prototype.Aa=function(b){if(null===b)this.j="";else{var c=b.a;null===c?this.b=null:(c=c.a,c=sg(null===c?gl:c),null===this.b?this.b={fillStyle:c}:this.b.fillStyle=c);var d=b.e;if(null===d)this.e=null;else{var c=d.a,e=d.c,f=d.b,g=d.f,h=d.d,d=d.e,e=m(e)?e:"round",f=null!=f?f.slice():hl,g=m(g)?g:"round",h=m(h)?h:1,d=m(d)?d:10,c=sg(null===c?il:c);if(null===this.e)this.e={lineCap:e,lineDash:f,lineJoin:g,lineWidth:h,miterLimit:d,strokeStyle:c};else{var k=this.e;k.lineCap=e;k.lineDash=f;k.lineJoin=g;k.lineWidth= -h;k.miterLimit=d;k.strokeStyle=c}}var n=b.c,c=b.i,e=b.n,f=b.f,h=b.d,d=b.b,g=b.g,k=b.j;b=m(n)?n:"10px sans-serif";g=m(g)?g:"center";k=m(k)?k:"middle";null===this.g?this.g={font:b,textAlign:g,textBaseline:k}:(n=this.g,n.font=b,n.textAlign=g,n.textBaseline=k);this.j=m(d)?d:"";this.i=m(c)?c:0;this.n=m(e)?e:0;this.l=m(f)?f:0;this.p=m(h)?h:1}};function qm(b,c,d,e){this.i=b;this.c=c;this.j=d;this.f=e;this.d={};this.e=Pf(1,1);this.g=Gd()} -function rm(b){for(var c in b.d){var d=b.d[c],e;for(e in d)d[e].Kb()}}qm.prototype.b=function(b,c,d,e,f){var g=this.g;rj(g,.5,.5,1/c,-1/c,-d,-b[0],-b[1]);var h=this.e;h.clearRect(0,0,1,1);var k;m(this.f)&&(k=Rd(),Sd(k,b),Vd(k,c*this.f,k));return sm(this,h,g,d,e,function(b){if(0b||0!==this.g&&b>1,q=h(d,g[p]),0s?(d=(d-g[-s-2])/(g[-s-1]-g[-s-2]),c+=(-s-2)*e,g=Wb(b[c],b[c+e],d),h=Wb(b[c+1],b[c+e+1],d)):(g=b[c+s*e],h=b[c+s*e+1])}return null!=f? -(f[0]=g,f[1]=h,f):[g,h]}function Hm(b,c,d,e,f,g){if(d==c)return null;if(f>1,fb||this.b.length<=b)return null;var c=new L(null);Jm(c,this.a,this.k.slice(0===b?0:this.b[b-1],this.b[b]));return c};l.Gc=function(){var b=this.k,c=this.b,d=this.a,e=[],f=0,g,h;g=0;for(h=c.length;gb||c<=b)return null;c=new Ek(null);Fk(c,this.a,this.k.slice(b*this.t,(b+1)*this.t));return c};l.zd=function(){var b=this.k,c=this.a,d=this.t,e=[],f,g;f=0;for(g=b.length;fb||this.b.length<=b)return null;var c;0===b?c=0:(c=this.b[b-1],c=c[c.length-1]);b=this.b[b].slice();var d=b[b.length-1];if(0!==c){var e,f;e=0;for(f=b.length;e=b[0]&&c[3]>=b[1]}function r(b,c,d,e,f){for(var g=[c,d],h;g.length;)d=g.pop(),c=g.pop(),d-c<=e||(h=c+Math.ceil((d-c)/e/2)*e,s(b,c,d,h,f),g.push(c,h,h,d))}function s(b,c,d,e,f){for(var g,h,k,n,p;d>c;){600h-g/2?-1:1),k=Math.max(c,Math.floor(e-h*n/g+p)),h=Math.min(d,Math.floor(e+(g-h)*n/g+p)),s(b,k,h,e,f));g=b[e];h=c;n=d;u(b,c,e);for(0f(b[h],g);)h++;for(;0this.fe)this.Yg(e,c),c--;else break;this.Sg(d,e,c)},Yg:function(b,c){var e=b[c],f=e.children.length,g=this.Xe;this.Tg(e,g,f);f={children:e.children.splice(this.Ug(e,g,f)),height:e.height};e.xa&&(f.xa=!0);d(e,this.Ia);d(f,this.Ia);c?b[c-1].children.push(f):this.Ye(e, -f)},Ye:function(b,c){this.data={children:[b,c],height:b.height+1};d(this.data,this.Ia)},Ug:function(b,c,d){var f,g,h,n,p,q,r;p=q=Infinity;for(f=c;f<=d-c;f++){g=e(b,0,f,this.Ia);h=e(b,f,d,this.Ia);var s=g,u=h;n=Math.max(s[0],u[0]);var Sb=Math.max(s[1],u[1]),Gb=Math.min(s[2],u[2]),s=Math.min(s[3],u[3]);n=Math.max(0,Gb-n)*Math.max(0,s-Sb);g=k(g)+k(h);n=c;q--)r=b.children[q],f(k,b.xa?g(r):r.bbox),p+=n(k);return p},Sg:function(b,c,d){for(;0<=d;d--)f(c[d].bbox,b)},Wg:function(b){for(var c=b.length-1,e;0<=c;c--)0===b[c].children.length?0z||this.b[1]>D)?(x.width=z,x.height=D,this.b=[z,D],this.i=!zm(this.b),this.c=null):(z=this.b[0],D=this.b[1],p==this.p&&of(this.c,A)||(this.c=null)));var O,W;null===this.c?(z/=q,D/=q,O=A.a-Math.floor((z-(A.c-A.a+1))/2),W=A.b-Math.floor((D-(A.d-A.b+1))/2),this.p=p,this.c=new lf(O,O+z-1,W,W+D-1),this.j=Array(z*D),D=this.c):(D=this.c,z=D.c-D.a+1);x={};x[p]={};var V=[],ta=ra(h.le,h,x,jj(function(b){return null!==b&&2==b.state},h,d,f)),Jb=g.da(),Qa=Rd(),Sb=new lf(0,0,0,0),Gb,La,Tb; -for(W=A.a;W<=A.c;++W)for(Tb=A.b;Tb<=A.d;++Tb)La=h.Fb(p,W,Tb,d,f),O=La.state,2==O||4==O||3==O&&!Jb?x[p][kf(La.a)]=La:(Gb=k.bd(La.a,ta,null,Sb,Qa),Gb||(V.push(La),Gb=k.md(La.a,Sb,Qa),null===Gb||ta(p+1,Gb)));ta=0;for(Gb=V.length;taV&&Kf(this.target,A.target,0)}else b.viewHints[0]||b.viewHints[1]||An(A,s,D);else Lf(A.target),delete this.b[V];c.opacity!=this.i&&(this.i=this.target.style.opacity=c.opacity);c.visible&&!this.c&&(Mg(this.target,!0),this.c=!0);ij(b.usedTiles,h,p,q);lj(b,h,k,d,f,s,p,g.r());fj(b,h);hj(b,h);return!0}; -function wn(b,c){this.target=Gf("DIV");this.target.style.position="absolute";this.target.style.width="100%";this.target.style.height="100%";this.c=b;this.b=c;this.e=ke(Ti(b,c));this.g=b.na(c[0]);this.d={};this.a=null;this.f=Id()} -function xn(b,c,d){var e=c.a,f=e[0],g=e[1],h=e[2],e=kf(e);if(!(e in b.d)){var f=b.c.va(f),k=c.Qa(b),n=k.style;n.maxWidth="none";var p,q;0=k;){n=this.b[p];u=this.n[p];x=ma(u).toString();if(!m(r[x])&&(!m(y)||oe(y,u.N().D()))&&(g.clear(g.COLOR_BUFFER_BIT|g.DEPTH_BUFFER_BIT),g.drawElements(4,q-n,e,n*b),q=s(u))){r=q;break a}q=n;p--}r=void 0}else g.clear(g.COLOR_BUFFER_BIT|g.DEPTH_BUFFER_BIT),ao(this,g,b,r,this.g,this.e),r=(r=s(null))?r:void 0;x=r}else ao(this,g,b,r,this.ha,this.p);g.disableVertexAttribArray(z.c); -g.disableVertexAttribArray(z.a);g.disableVertexAttribArray(z.f);g.disableVertexAttribArray(z.d);g.disableVertexAttribArray(z.b);return x}; -function ao(b,c,d,e,f,g){var h=d.b?5125:5123;d=d.b?4:2;if(rb(e)){var k;b=0;e=f.length;for(k=0;bc[0]||c[0]>f[0]||0>c[1]||c[1]>f[1])&& -(null===this.e&&(this.e=Pf(1,1)),this.e.clearRect(0,0,1,1),this.e.drawImage(this.b.a(),c[0],c[1],1,1,0,0,1,1),0.75*f||c.height>.75*e?Po(this):Yd(d,b)||(b=this.c,d=this.a.a(),b.a().Ra(d.b()))}Qo(this)}l.Bf=function(){Oo(this)};function Po(b){var c=b.a;b=b.c;var d=c.f(),c=c.a().g(d),d=b.f();b=b.a();var e=Math.log(7.5)/Math.LN2;re(c,1/(.1*Math.pow(2,e/2)));b.me(c,d)} -function Qo(b){var c=b.a,d=b.c;if(null!==c.c&&null!==d.c){var e=c.f(),f=c.a(),g=d.a();d.f();var c=f.c(),h=b.n,d=b.n.c(),f=f.g(e),e=g.a(),g=fe(f),f=he(f),k;b=b.a.a().b();m(b)&&(k=[g[0]-b[0],g[1]-b[1]],zd(k,c),ud(k,b));h.e(k);null!=d&&(k=new tf(Math.abs((g[0]-f[0])/e),Math.abs((f[1]-g[1])/e)),uf(wf(d)),!Bb||Mb("10")||Mb("8")?(d=d.style,Cb?d.MozBoxSizing="border-box":Db?d.WebkitBoxSizing="border-box":d.boxSizing="border-box",d.width=Math.max(k.width,0)+"px",d.height=Math.max(k.height,0)+"px"):(b=d.style, -c=Pg(d,"padding"),d=Sg(d),b.pixelWidth=k.width-d.left-c.left-c.right-d.right,b.pixelHeight=k.height-d.top-c.top-c.bottom-d.bottom))}}l.tj=function(b){b.preventDefault();Ro(this)};function Ro(b){Ag(b.element,"ol-collapsed");b.e?Mf(b.p,b.q):Mf(b.q,b.p);b.e=!b.e;var c=b.c;b.e||null!==c.c||(c.l(),Po(b),Rc(c,"postrender",function(){Qo(this)},!1,b))}l.sj=function(){return this.g};l.vj=function(b){this.g!==b&&(this.g=b,Ag(this.element,"ol-uncollapsible"),!b&&this.e&&Ro(this))}; -l.uj=function(b){this.g&&this.e!==b&&Ro(this)};l.rj=function(){return this.e};function So(b){b=m(b)?b:{};var c=m(b.className)?b.className:"ol-scale-line";this.g=Cf("DIV",c+"-inner");this.aa=Cf("DIV",c+" ol-unselectable",this.g);this.r=null;this.n=m(b.minWidth)?b.minWidth:64;this.c=!1;this.F=void 0;this.s="";this.e=null;Ug.call(this,{element:this.aa,render:m(b.render)?b.render:To,target:b.target});w(this,sd("units"),this.H,!1,this);this.q(b.units||"metric")}v(So,Ug);var Uo=[1,2,5];So.prototype.p=function(){return this.get("units")};So.prototype.getUnits=So.prototype.p; -function To(b){b=b.frameState;null===b?this.r=null:this.r=b.viewState;Vo(this)}So.prototype.H=function(){Vo(this)};So.prototype.q=function(b){this.set("units",b)};So.prototype.setUnits=So.prototype.q; -function Vo(b){var c=b.r;if(null===c)b.c&&(Mg(b.aa,!1),b.c=!1);else{var d=c.center,e=c.projection,c=e.re(c.resolution,d),f=e.d,g=b.p();"degrees"!=f||"metric"!=g&&"imperial"!=g&&"us"!=g&&"nautical"!=g?"ft"!=f&&"m"!=f||"degrees"!=g?b.e=null:(null===b.e&&(b.e=Ae(e,Be("EPSG:4326"))),d=Math.cos(Xb(b.e(d)[1])),e=ve.radius,"ft"==f&&(e/=.3048),c*=180/(Math.PI*d*e)):(b.e=null,d=Math.cos(Xb(d[1])),c*=Math.PI*d*ve.radius/180);d=b.n*c;f="";"degrees"==g?d<1/60?(f="\u2033",c*=3600):1>d?(f="\u2032",c*=60):f="\u00b0": -"imperial"==g?.9144>d?(f="in",c/=.0254):1609.344>d?(f="ft",c/=.3048):(f="mi",c/=1609.344):"nautical"==g?(c/=1852,f="nm"):"metric"==g?1>d?(f="mm",c*=1E3):1E3>d?f="m":(f="km",c/=1E3):"us"==g&&(.9144>d?(f="in",c*=39.37):1609.344>d?(f="ft",c/=.30480061):(f="mi",c/=1609.3472));for(d=3*Math.floor(Math.log(b.n*c)/Math.log(10));;){e=Uo[d%3]*Math.pow(10,Math.floor(d/3));g=Math.round(e/c);if(isNaN(g)){Mg(b.aa,!1);b.c=!1;return}if(g>=b.n)break;++d}c=e+" "+f;b.s!=c&&(b.g.innerHTML=c,b.s=c);b.F!=g&&(b.g.style.width= -g+"px",b.F=g);b.c||(Mg(b.aa,!0),b.c=!0)}};function Wo(b){kc.call(this);this.d=b;this.a={}}v(Wo,kc);var Xo=[];Wo.prototype.Oa=function(b,c,d,e){ga(c)||(c&&(Xo[0]=c.toString()),c=Xo);for(var f=0;fd.height?(this.g=1,d=new Cg(0,0,e,0)):(this.g=hp,d=new Cg(0,0,0,c));this.c.a=d||new Cg(NaN,NaN,NaN,NaN);this.p=!0}b=b.frameState.viewState.resolution;b!==this.e&&(this.e=b,b=1-We(this.a.a())(b),d=this.c,c=Nf(this.element),1==this.g?Gg(c,d.a.left+d.a.width*b):Gg(c, -d.a.left,d.a.top+d.a.height*b))}}l.Zh=function(b){var c=this.a,d=c.a(),e=d.a();c.Wa(ff({resolution:e,duration:200,easing:$e}));b=jp(this,b.offsetX-this.n[0]/2,b.offsetY-this.n[1]/2);b=kp(this,b);d.f(d.constrainResolution(b))};l.bi=function(){Ze(this.a.a(),1)};l.$h=function(b){b=jp(this,b.left,b.top);this.e=kp(this,b);this.a.a().f(this.e)};l.ai=function(){var b=this.a,c=b.a();Ze(c,-1);b.Wa(ff({resolution:this.e,duration:200,easing:$e}));b=c.constrainResolution(this.e);c.f(b)}; -function jp(b,c,d){var e=b.c.a;return Ub(1===b.g?(c-e.left)/e.width:(d-e.top)/e.height,0,1)}function kp(b,c){return Ve(b.a.a())(1-c)};function lp(b){b=m(b)?b:{};this.c=m(b.extent)?b.extent:null;var c=m(b.className)?b.className:"ol-zoom-extent",d=Cf("BUTTON",{type:"button",title:m(b.tipLabel)?b.tipLabel:"Fit to extent"},m(b.label)?b.label:"E");w(d,"click",this.e,!1,this);w(d,["mouseout",sc],function(){this.blur()},!1);c=Cf("DIV",c+" ol-unselectable ol-control",d);Ug.call(this,{element:c,target:b.target})}v(lp,Ug); -lp.prototype.e=function(b){b.preventDefault();var c=this.a;b=c.a();var d=null===this.c?b.q.D():this.c,c=c.f();b.me(d,c)};function mp(b){od.call(this);b=m(b)?b:{};this.a=null;w(this,sd("tracking"),this.n,!1,this);this.b(m(b.tracking)?b.tracking:!1)}v(mp,od);mp.prototype.M=function(){this.b(!1);mp.R.M.call(this)}; -mp.prototype.l=function(b){b=b.a;if(null!=b.alpha){var c=Xb(b.alpha);this.set("alpha",c);"boolean"==typeof b.absolute&&b.absolute?this.set("heading",c):null!=b.webkitCompassHeading&&null!=b.webkitCompassAccuracy&&-1!=b.webkitCompassAccuracy&&this.set("heading",Xb(b.webkitCompassHeading))}null!=b.beta&&this.set("beta",Xb(b.beta));null!=b.gamma&&this.set("gamma",Xb(b.gamma));this.o()};mp.prototype.f=function(){return this.get("alpha")};mp.prototype.getAlpha=mp.prototype.f;mp.prototype.e=function(){return this.get("beta")}; -mp.prototype.getBeta=mp.prototype.e;mp.prototype.g=function(){return this.get("gamma")};mp.prototype.getGamma=mp.prototype.g;mp.prototype.i=function(){return this.get("heading")};mp.prototype.getHeading=mp.prototype.i;mp.prototype.c=function(){return this.get("tracking")};mp.prototype.getTracking=mp.prototype.c;mp.prototype.n=function(){if(ag){var b=this.c();b&&null===this.a?this.a=w(ba,"deviceorientation",this.l,!1,this):b||null===this.a||(Tc(this.a),this.a=null)}}; -mp.prototype.b=function(b){this.set("tracking",b)};mp.prototype.setTracking=mp.prototype.b;function np(b){od.call(this);this.i=b;w(this.i,["change","input"],this.g,!1,this);w(this,sd("value"),this.n,!1,this);w(this,sd("checked"),this.e,!1,this)}v(np,od);np.prototype.a=function(){return this.get("checked")};np.prototype.getChecked=np.prototype.a;np.prototype.b=function(){return this.get("value")};np.prototype.getValue=np.prototype.b;np.prototype.f=function(b){this.set("value",b)};np.prototype.setValue=np.prototype.f;np.prototype.c=function(b){this.set("checked",b)}; -np.prototype.setChecked=np.prototype.c;np.prototype.g=function(){var b=this.i;"checkbox"===b.type||"radio"===b.type?this.c(b.checked):this.f(b.value)};np.prototype.e=function(){this.i.checked=this.a()};np.prototype.n=function(){this.i.value=this.b()};function P(b){od.call(this);this.X=void 0;this.b="geometry";this.g=null;this.a=void 0;this.e=null;w(this,sd(this.b),this.rd,!1,this);m(b)&&(b instanceof gk||null===b?this.Pa(b):this.G(b))}v(P,od);P.prototype.clone=function(){var b=new P(this.L());b.f(this.b);var c=this.N();null!=c&&b.Pa(c.clone());c=this.g;null===c||b.i(c);return b};P.prototype.N=function(){return this.get(this.b)};P.prototype.getGeometry=P.prototype.N;l=P.prototype;l.wh=function(){return this.X};l.vh=function(){return this.b}; -l.cj=function(){return this.g};l.dj=function(){return this.a};l.ii=function(){this.o()};l.rd=function(){null!==this.e&&(Tc(this.e),this.e=null);var b=this.N();null!=b&&(this.e=w(b,"change",this.ii,!1,this),this.o())};l.Pa=function(b){this.set(this.b,b)};P.prototype.setGeometry=P.prototype.Pa;P.prototype.i=function(b){this.g=b;null===b?b=void 0:ka(b)||(b=ga(b)?b:[b],b=Xc(b));this.a=b;this.o()};P.prototype.c=function(b){this.X=b;this.o()}; -P.prototype.f=function(b){Sc(this,sd(this.b),this.rd,!1,this);this.b=b;w(this,sd(this.b),this.rd,!1,this);this.rd()};function op(b){b=m(b)?b:{};this.g=this.f=this.c=this.d=this.b=this.a=null;this.e=void 0;this.Af(m(b.style)?b.style:pl);m(b.features)?ga(b.features)?this.Nc(new C(b.features.slice())):this.Nc(b.features):this.Nc(new C);m(b.map)&&this.setMap(b.map)}l=op.prototype;l.yf=function(b){this.a.push(b)};l.Xi=function(){return this.a};l.Yi=function(){return this.c};l.zf=function(){pp(this)};l.gi=function(b){b=b.element;this.d[ma(b).toString()]=w(b,"change",this.zf,!1,this);pp(this)}; -l.hi=function(b){b=ma(b.element).toString();Tc(this.d[b]);delete this.d[b];pp(this)};l.aj=function(){pp(this)};l.bj=function(b){if(null!==this.a){var c=this.e;m(c)||(c=pl);var d=b.a;b=b.frameState;var e=b.viewState.resolution,f=Sm(e,b.pixelRatio),g,h,k,n;this.a.forEach(function(b){n=b.a;k=m(n)?n.call(b,e):c(b,e);if(null!=k)for(h=k.length,g=0;gd?b[1]="?":d==c.length-1&&(b[1]=void 0)}return b.join("")} -function Ir(b,c,d){if(ga(c))for(var e=0;ec)throw Error("Bad port number "+c);b.sc=c}else b.sc=null}function Nr(b,c,d){c instanceof Pr?(b.a=c,Vr(b.a,b.Wb)):(d||(c=Qr(c,Wr)),b.a=new Pr(c,0,b.Wb))}function Xr(b){return b instanceof Kr?b.clone():new Kr(b,void 0)} -function Yr(b,c){b instanceof Kr||(b=Xr(b));c instanceof Kr||(c=Xr(c));var d=b,e=c,f=d.clone(),g=!!e.Pb;g?Lr(f,e.Pb):g=!!e.ec;g?f.ec=e.ec:g=!!e.qb;g?f.qb=e.qb:g=null!=e.sc;var h=e.ob;if(g)Mr(f,e.sc);else if(g=!!e.ob)if("/"!=h.charAt(0)&&(d.qb&&!d.ob?h="/"+h:(d=f.ob.lastIndexOf("/"),-1!=d&&(h=f.ob.substr(0,d+1)+h))),d=h,".."==d||"."==d)h="";else if(-1!=d.indexOf("./")||-1!=d.indexOf("/.")){for(var h=0==d.lastIndexOf("/",0),d=d.split("/"),k=[],n=0;n>4&15).toString(16)+(b&15).toString(16)} -var Rr=/[#\/\?@]/g,Tr=/[\#\?:]/g,Sr=/[\#\?]/g,Wr=/[\#\?@]/g,Ur=/#/g;function Pr(b,c,d){this.a=b||null;this.d=!!d}function $r(b){b.fa||(b.fa=new uh,b.wa=0,b.a&&Gr(b.a,function(c,d){b.add(decodeURIComponent(c.replace(/\+/g," ")),d)}))}l=Pr.prototype;l.fa=null;l.wa=null;l.Tb=function(){$r(this);return this.wa};l.add=function(b,c){$r(this);this.a=null;b=as(this,b);var d=this.fa.get(b);d||this.fa.set(b,d=[]);d.push(c);this.wa++;return this}; -l.remove=function(b){$r(this);b=as(this,b);return wh(this.fa.d,b)?(this.a=null,this.wa-=this.fa.get(b).length,this.fa.remove(b)):!1};l.clear=function(){this.fa=this.a=null;this.wa=0};l.la=function(){$r(this);return 0==this.wa};function bs(b,c){$r(b);c=as(b,c);return wh(b.fa.d,c)}l.J=function(){$r(this);for(var b=this.fa.lb(),c=this.fa.J(),d=[],e=0;ee;++e){var f=parseInt(d[e],10).toString(16);d[e]=1==f.length?"0"+f:f}Dq(b,d.join(""))} -function dt(b,c,d){qq({node:b},et,ft,[c],d)}function gt(b,c,d){var e={node:b};null!=c.X&&b.setAttribute("id",c.X);b=c.L();var f=c.a;m(f)&&(f=f.call(c,0),null!==f&&0f?~(f<<1):f<<1;d="";e=0;for(f=b.length;e>=5;h=g+63;k+=String.fromCharCode(h);d+=k}return d} -function qu(b,c){var d=m(c)?c:1E5,e=[],f=0,g=0,h,k;h=0;for(k=b.length;hn?(e.push(f),g=f=0):g+=5}f=0;for(g=e.length;f>1):h>>1;f=0;for(g=e.length;f=b||"."==b&&!d} -function Su(b){var c=b.d.charAt(++b.a),d={position:b.a,value:c};if("("==c)d.type=2;else if(","==c)d.type=5;else if(")"==c)d.type=3;else if(Uu(c)||"-"==c){d.type=4;var e,c=b.a,f=!1;do"."==e&&(f=!0),e=b.d.charAt(++b.a);while(Uu(e,f));b=parseFloat(b.d.substring(c,b.a--));d.value=b}else if("a"<=c&&"z">=c||"A"<=c&&"Z">=c){d.type=1;c=b.a;do e=b.d.charAt(++b.a);while("a"<=e&&"z">=e||"A"<=e&&"Z">=e);b=b.d.substring(c,b.a--).toUpperCase();d.value=b}else{if(" "==c||"\t"==c||"\r"==c||"\n"==c)return Su(b);if(""=== -c)d.type=6;else throw Error("Unexpected character: "+c);}return d}function Qu(b){this.d=b}l=Qu.prototype;l.match=function(b){if(b=this.a.type==b)this.a=Su(this.d);return b}; -function Tu(b){var c=b.a;if(b.match(1)){var d=c.value;if("GEOMETRYCOLLECTION"==d){a:{if(b.match(2)){c=[];do c.push(Tu(b));while(b.match(5));if(b.match(3)){b=c;break a}}else if(Vu(b)){b=[];break a}throw Error(Wu(b));}return new Cm(b)}var e=Xu[d],c=Yu[d];if(!m(e)||!m(c))throw Error("Invalid geometry type: "+d);b=e.call(b);return new c(b)}throw Error(Wu(b));}l.De=function(){if(this.match(2)){var b=Zu(this);if(this.match(3))return b}else if(Vu(this))return null;throw Error(Wu(this));}; -l.Ce=function(){if(this.match(2)){var b=$u(this);if(this.match(3))return b}else if(Vu(this))return[];throw Error(Wu(this));};l.Ee=function(){if(this.match(2)){var b=av(this);if(this.match(3))return b}else if(Vu(this))return[];throw Error(Wu(this));};l.Pk=function(){if(this.match(2)){var b;if(2==this.a.type)for(b=[this.De()];this.match(5);)b.push(this.De());else b=$u(this);if(this.match(3))return b}else if(Vu(this))return[];throw Error(Wu(this));}; -l.Ok=function(){if(this.match(2)){var b=av(this);if(this.match(3))return b}else if(Vu(this))return[];throw Error(Wu(this));};l.Qk=function(){if(this.match(2)){for(var b=[this.Ee()];this.match(5);)b.push(this.Ee());if(this.match(3))return b}else if(Vu(this))return[];throw Error(Wu(this));};function Zu(b){for(var c=[],d=0;2>d;++d){var e=b.a;if(b.match(4))c.push(e.value);else break}if(2==c.length)return c;throw Error(Wu(b));}function $u(b){for(var c=[Zu(b)];b.match(5);)c.push(Zu(b));return c} -function av(b){for(var c=[b.Ce()];b.match(5);)c.push(b.Ce());return c}function Vu(b){var c=1==b.a.type&&"EMPTY"==b.a.value;c&&(b.a=Su(b.d));return c}function Wu(b){return"Unexpected `"+b.a.value+"` at position "+b.a.position+" in `"+b.d.d+"`"}var Yu={POINT:Ek,LINESTRING:L,POLYGON:G,MULTIPOINT:Nm,MULTILINESTRING:Km,MULTIPOLYGON:Om},Xu={POINT:Qu.prototype.De,LINESTRING:Qu.prototype.Ce,POLYGON:Qu.prototype.Ee,MULTIPOINT:Qu.prototype.Pk,MULTILINESTRING:Qu.prototype.Ok,MULTIPOLYGON:Qu.prototype.Qk};function bv(){this.version=void 0}v(bv,Vt);bv.prototype.d=function(b){for(b=b.firstChild;null!==b;b=b.nextSibling)if(1==b.nodeType)return this.a(b);return null};bv.prototype.a=function(b){this.version=Aa(b.getAttribute("version"));b=U({version:this.version},cv,b,[]);return m(b)?b:null};function dv(b,c){return U({},ev,b,c)}function fv(b,c){return U({},gv,b,c)}function hv(b,c){var d=dv(b,c);if(m(d)){var e=[Bq(b.getAttribute("width")),Bq(b.getAttribute("height"))];d.size=e;return d}} -function iv(b,c){return U([],jv,b,c)} -var kv=[null,"http://www.opengis.net/wms"],cv=R(kv,{Service:Q(function(b,c){return U({},lv,b,c)}),Capability:Q(function(b,c){return U({},mv,b,c)})}),mv=R(kv,{Request:Q(function(b,c){return U({},nv,b,c)}),Exception:Q(function(b,c){return U([],ov,b,c)}),Layer:Q(function(b,c){return U({},pv,b,c)})}),lv=R(kv,{Name:Q(X),Title:Q(X),Abstract:Q(X),KeywordList:Q(iv),OnlineResource:Q(Ut),ContactInformation:Q(function(b,c){return U({},qv,b,c)}),Fees:Q(X),AccessConstraints:Q(X),LayerLimit:Q(Aq),MaxWidth:Q(Aq), -MaxHeight:Q(Aq)}),qv=R(kv,{ContactPersonPrimary:Q(function(b,c){return U({},rv,b,c)}),ContactPosition:Q(X),ContactAddress:Q(function(b,c){return U({},sv,b,c)}),ContactVoiceTelephone:Q(X),ContactFacsimileTelephone:Q(X),ContactElectronicMailAddress:Q(X)}),rv=R(kv,{ContactPerson:Q(X),ContactOrganization:Q(X)}),sv=R(kv,{AddressType:Q(X),Address:Q(X),City:Q(X),StateOrProvince:Q(X),PostCode:Q(X),Country:Q(X)}),ov=R(kv,{Format:gq(X)}),pv=R(kv,{Name:Q(X),Title:Q(X),Abstract:Q(X),KeywordList:Q(iv),CRS:iq(X), -EX_GeographicBoundingBox:Q(function(b,c){var d=U({},tv,b,c);if(m(d)){var e=d.westBoundLongitude,f=d.southBoundLatitude,g=d.eastBoundLongitude,d=d.northBoundLatitude;return m(e)&&m(f)&&m(g)&&m(d)?[e,f,g,d]:void 0}}),BoundingBox:iq(function(b){var c=[zq(b.getAttribute("minx")),zq(b.getAttribute("miny")),zq(b.getAttribute("maxx")),zq(b.getAttribute("maxy"))],d=[zq(b.getAttribute("resx")),zq(b.getAttribute("resy"))];return{crs:b.getAttribute("CRS"),extent:c,res:d}}),Dimension:iq(function(b){return{name:b.getAttribute("name"), -units:b.getAttribute("units"),unitSymbol:b.getAttribute("unitSymbol"),"default":b.getAttribute("default"),multipleValues:wq(b.getAttribute("multipleValues")),nearestValue:wq(b.getAttribute("nearestValue")),current:wq(b.getAttribute("current")),values:X(b)}}),Attribution:Q(function(b,c){return U({},uv,b,c)}),AuthorityURL:iq(function(b,c){var d=dv(b,c);if(m(d))return d.name=b.getAttribute("name"),d}),Identifier:iq(X),MetadataURL:iq(function(b,c){var d=dv(b,c);if(m(d))return d.type=b.getAttribute("type"), -d}),DataURL:iq(dv),FeatureListURL:iq(dv),Style:iq(function(b,c){return U({},vv,b,c)}),MinScaleDenominator:Q(yq),MaxScaleDenominator:Q(yq),Layer:iq(function(b,c){var d=c[c.length-1],e=U({},pv,b,c);if(m(e)){var f=wq(b.getAttribute("queryable"));m(f)||(f=d.queryable);e.queryable=m(f)?f:!1;f=Bq(b.getAttribute("cascaded"));m(f)||(f=d.cascaded);e.cascaded=f;f=wq(b.getAttribute("opaque"));m(f)||(f=d.opaque);e.opaque=m(f)?f:!1;f=wq(b.getAttribute("noSubsets"));m(f)||(f=d.noSubsets);e.noSubsets=m(f)?f:!1; -f=zq(b.getAttribute("fixedWidth"));m(f)||(f=d.fixedWidth);e.fixedWidth=f;f=zq(b.getAttribute("fixedHeight"));m(f)||(f=d.fixedHeight);e.fixedHeight=f;Oa(["Style","CRS","AuthorityURL"],function(b){var c=d[b];if(m(c)){var f=vb(e,b),f=f.concat(c);e[b]=f}});Oa("EX_GeographicBoundingBox BoundingBox Dimension Attribution MinScaleDenominator MaxScaleDenominator".split(" "),function(b){m(e[b])||(e[b]=d[b])});return e}})}),uv=R(kv,{Title:Q(X),OnlineResource:Q(Ut),LogoURL:Q(hv)}),tv=R(kv,{westBoundLongitude:Q(yq), -eastBoundLongitude:Q(yq),southBoundLatitude:Q(yq),northBoundLatitude:Q(yq)}),nv=R(kv,{GetCapabilities:Q(fv),GetMap:Q(fv),GetFeatureInfo:Q(fv)}),gv=R(kv,{Format:iq(X),DCPType:iq(function(b,c){return U({},wv,b,c)})}),wv=R(kv,{HTTP:Q(function(b,c){return U({},xv,b,c)})}),xv=R(kv,{Get:Q(dv),Post:Q(dv)}),vv=R(kv,{Name:Q(X),Title:Q(X),Abstract:Q(X),LegendURL:iq(hv),StyleSheetURL:Q(dv),StyleURL:Q(dv)}),ev=R(kv,{Format:Q(X),OnlineResource:Q(Ut)}),jv=R(kv,{Keyword:gq(X)});function yv(){this.b="http://mapserver.gis.umn.edu/mapserver";this.d=new Oq;this.defaultDataProjection=null}v(yv,rq); -function zv(b,c,d){c.namespaceURI=b.b;var e=Pp(c),f=[];if(0===c.childNodes.length)return f;"msGMLOutput"==e&&Oa(c.childNodes,function(b){if(1===b.nodeType){var c=d[0],e=b.localName,n=RegExp,p;p="_layer".replace(/([-()\[\]{}+?*.$\^|,:#=c.j&&c.cancel())}this.p?this.p.call(this.l,this):this.i=!0;this.a||(b=new xw,yw(this),zw(this,!1,b))}};ww.prototype.n=function(b,c){this.g=!1;zw(this,b,c)};function zw(b,c,d){b.a=!0;b.b=d;b.c=!c;Aw(b)} -function yw(b){if(b.a){if(!b.i)throw new Bw;b.i=!1}}function Cw(b,c,d,e){b.f.push([c,d,e]);b.a&&Aw(b)}ww.prototype.then=function(b,c,d){var e,f,g=new iw(function(b,c){e=b;f=c});Cw(this,e,function(b){b instanceof xw?g.cancel():f(b)});return g.then(b,c,d)};$v(ww);function Dw(b){return Sa(b.f,function(b){return ka(b[1])})} -function Aw(b){if(b.e&&b.a&&Dw(b)){var c=b.e,d=Ew[c];d&&(ba.clearTimeout(d.X),delete Ew[c]);b.e=0}b.d&&(b.d.j--,delete b.d);for(var c=b.b,e=d=!1;b.f.length&&!b.g;){var f=b.f.shift(),g=f[0],h=f[1],f=f[2];if(g=b.c?h:g)try{var k=g.call(f||b.l,c);m(k)&&(b.c=b.c&&(k==c||k instanceof Error),b.b=c=k);aw(c)&&(e=!0,b.g=!0)}catch(n){c=n,b.c=!0,Dw(b)||(d=!0)}}b.b=c;e&&(k=ra(b.n,b,!0),e=ra(b.n,b,!1),c instanceof ww?(Cw(c,k,e),c.q=!0):c.then(k,e));d&&(c=new Fw(c),Ew[c.X]=c,b.e=c.X)} -function Bw(){xa.call(this)}v(Bw,xa);Bw.prototype.message="Deferred has already fired";Bw.prototype.name="AlreadyCalledError";function xw(){xa.call(this)}v(xw,xa);xw.prototype.message="Deferred was canceled";xw.prototype.name="CanceledError";function Fw(b){this.X=ba.setTimeout(ra(this.d,this),0);this.a=b}Fw.prototype.d=function(){delete Ew[this.X];throw this.a;};var Ew={};function Gw(b,c){m(b.name)?(this.name=b.name,this.code=qb[b.name]):(this.code=b.code,this.name=Hw(b.code));xa.call(this,za("%s %s",this.name,c))}v(Gw,xa);function Hw(b){var c=pb(function(c){return b==c});if(!m(c))throw Error("Invalid code: "+b);return c}var qb={AbortError:3,EncodingError:5,InvalidModificationError:9,InvalidStateError:7,NotFoundError:1,NotReadableError:4,NoModificationAllowedError:6,PathExistsError:12,QuotaExceededError:10,SecurityError:2,SyntaxError:8,TypeMismatchError:11};function Iw(b,c){pc.call(this,b.type,c)}v(Iw,pc);function Jw(){ed.call(this);this.eb=new FileReader;this.eb.onloadstart=ra(this.a,this);this.eb.onprogress=ra(this.a,this);this.eb.onload=ra(this.a,this);this.eb.onabort=ra(this.a,this);this.eb.onerror=ra(this.a,this);this.eb.onloadend=ra(this.a,this)}v(Jw,ed);Jw.prototype.getError=function(){return this.eb.error&&new Gw(this.eb.error,"reading file")};Jw.prototype.a=function(b){this.dispatchEvent(new Iw(b,this))};Jw.prototype.M=function(){Jw.R.M.call(this);delete this.eb}; -function Kw(b){var c=new ww;b.Oa("loadend",sa(function(b,c){var f=c.eb.result,g=c.getError();null==f||g?(yw(b),zw(b,!1,g)):(yw(b),zw(b,!0,f));c.Ec()},c,b));return c};function Lw(b){b=m(b)?b:{};Ij.call(this,{handleEvent:Zc});this.e=m(b.formatConstructors)?b.formatConstructors:[];this.l=m(b.projection)?Be(b.projection):null;this.f=null;this.c=void 0}v(Lw,Ij);Lw.prototype.M=function(){m(this.c)&&Tc(this.c);Lw.R.M.call(this)};Lw.prototype.g=function(b){b=b.a.dataTransfer.files;var c,d,e;c=0;for(d=b.length;c=d[0]||0>=d[1]?c=!1:(c=c.a(),c=null!==c&&Ye(c)?!0:!1)}else c=!1;if(!c)return!0;c=!0;b.type===Hi?c=bx(this,b):b.type===Bi&&(c=!1);return Wj.call(this,b)&&c}function Vw(b){return this.Va(b)?(this.S=b.pixel,!0):!1} -function Xw(b){var c=this.S,d=b.pixel,e=c[0]-d[0],c=c[1]-d[1],d=!0;4>=e*e+c*c&&(bx(this,b),null===this.i?cx(this,b):this.c===Yw||dx(this,b)?this.U():(b=b.coordinate,e=this.g.N(),this.c===Zw?(this.i=b.slice(),c=e.K(),c.push(b.slice()),e.V(c)):this.c===$w&&(this.e[0].push(b.slice()),e.V(this.e)),ex(this)),d=!1);return d} -function bx(b,c){if(b.c===Yw&&null===b.i)cx(b,c);else if(null===b.i){var d=c.coordinate.slice();null===b.l?(b.l=new P(new Ek(d)),ex(b)):b.l.N().V(d)}else{var d=c.coordinate,e=b.g.N(),f,g;b.c===Yw?(g=e.K(),g[0]=d[0],g[1]=d[1],e.V(g)):(b.c===Zw?f=e.K():b.c===$w&&(f=b.e[0]),dx(b,c)&&(d=b.i.slice()),b.l.N().V(d),g=f[f.length-1],g[0]=d[0],g[1]=d[1],b.c===Zw?e.V(f):b.c===$w&&(b.r.N().V(f),e.V(b.e)));ex(b)}return!0} -function dx(b,c){var d=!1;if(null!==b.g){var e=b.g.N(),f=!1,g=[b.i];b.c===Zw?f=2b.Da,g=[b.e[0][0],b.e[0][b.e[0].length-2]]);if(f)for(var e=c.map,f=0,h=g.length;fd?h[1]:h[0]);nx(b,k);d={};d[ma(h)]=!0;c=1;for(n=g.length;cd&&(b.index+=f)})}function lx(){var b=ql();return function(){return b.Point}};function px(b){Ij.call(this,{handleEvent:qx});b=m(b)?b:{};this.i=m(b.condition)?b.condition:Qj;this.e=m(b.addCondition)?b.addCondition:Yc;this.q=m(b.removeCondition)?b.removeCondition:Yc;this.s=m(b.toggleCondition)?b.toggleCondition:Sj;this.g=m(b.multi)?b.multi:!1;var c;if(m(b.layers))if(ka(b.layers))c=b.layers;else{var d=b.layers;c=function(b){return Va(d,b)}}else c=Zc;this.f=c;this.c=new op({style:m(b.style)?b.style:rx()});b=this.c.a;w(b,"add",this.l,!1,this);w(b,"remove",this.r,!1,this)}v(px,Ij); -px.prototype.p=function(){return this.c.a};function qx(b){if(!this.i(b))return!0;var c=this.e(b),d=this.q(b),e=this.s(b),f=b.map,g=this.c.a,h=[],k=[];if(c||d||e){f.ne(b.pixel,function(b){-1==Na.indexOf.call(g.a,b,void 0)?(c||e)&&k.push(b):(d||e)&&h.push(b)},void 0,this.f);for(f=h.length-1;0<=f;--f)g.remove(h[f]);g.we(k)}else f.ne(b.pixel,function(b){k.push(b)},void 0,this.f),0b.f}function Px(b,c){for(var d,e;Ox(b)&&!(d=b.a.fc,e=d.a[0].toString(),e in c&&c[e].contains(d.a));)b.pop().Ec()};function Qx(b){$i.call(this,{attributions:b.attributions,extent:b.extent,logo:b.logo,opaque:b.opaque,projection:b.projection,state:m(b.state)?b.state:void 0,tileGrid:b.tileGrid,tilePixelRatio:b.tilePixelRatio});this.tileUrlFunction=m(b.tileUrlFunction)?b.tileUrlFunction:Kx;this.crossOrigin=m(b.crossOrigin)?b.crossOrigin:null;this.b=new Nx;this.tileLoadFunction=m(b.tileLoadFunction)?b.tileLoadFunction:Rx;this.tileClass=m(b.tileClass)?b.tileClass:Wv}v(Qx,$i);function Rx(b,c){b.Qa().src=c}l=Qx.prototype; -l.Dd=function(){return Ox(this.b)};l.Be=function(b){Px(this.b,b)};l.Fb=function(b,c,d,e,f){var g=this.ib(b,c,d);if(Bo(this.b,g))return this.b.get(g);b=[b,c,d];e=this.tileUrlFunction(b,e,f);e=new this.tileClass(b,m(e)?0:4,m(e)?e:"",this.crossOrigin,this.tileLoadFunction);this.b.set(g,e);return e};l.jb=function(){return this.tileLoadFunction};l.kb=function(){return this.tileUrlFunction};l.pb=function(b){this.b.clear();this.tileLoadFunction=b;this.o()}; -l.sa=function(b){this.b.clear();this.tileUrlFunction=b;this.o()};l.Oe=function(b,c,d){b=this.ib(b,c,d);Bo(this.b,b)&&this.b.get(b)};function Sx(b){var c=m(b.extent)?b.extent:Il,d=Yi(c,b.maxZoom,b.tileSize);Ri.call(this,{minZoom:b.minZoom,origin:je(c,"top-left"),resolutions:d,tileSize:b.tileSize})}v(Sx,Ri); -Sx.prototype.Cb=function(b){b=m(b)?b:{};var c=this.minZoom,d=this.maxZoom,e=m(b.wrapX)?b.wrapX:!0,f=null;if(m(b.extent)){var f=Array(d+1),g;for(g=0;g<=d;++g)f[g]=gq||p<=q)return null;b=b[2];return b<-p||-1=this.minZoom;--b)if(e.a=e.c>>=1,e.b=e.d>>=1,c.call(d,b,e))return!0;return!1};function Tx(b){Qx.call(this,{crossOrigin:"anonymous",opaque:!0,projection:Be("EPSG:3857"),state:"loading",tileLoadFunction:b.tileLoadFunction});this.c=m(b.culture)?b.culture:"en-us";this.a=m(b.maxZoom)?b.maxZoom:-1;this.j=m(b.wrapX)?b.wrapX:!0;var c=new Kr((Qb?"https:":"http:")+"//dev.virtualearth.net/REST/v1/Imagery/Metadata/"+b.imagerySet);(new Cx(c,"jsonp")).send({include:"ImageryProviders",uriScheme:Qb?"https":"http",key:b.key},ra(this.e,this))}v(Tx,Qx);var Ux=new qf({html:'Terms of Use'}); -Tx.prototype.e=function(b){if(200!=b.statusCode||"OK"!=b.statusDescription||"ValidCredentials"!=b.authenticationResultCode||1!=b.resourceSets.length||1!=b.resourceSets[0].resources.length)Li(this,"error");else{var c=b.brandLogoUri,d=b.resourceSets[0].resources[0],e=-1==this.a?d.zoomMax:this.a,f=new Sx({extent:Zi(this.g),minZoom:d.zoomMin,maxZoom:e,tileSize:d.imageWidth});this.tileGrid=f;var g=this.c;this.tileUrlFunction=Lx(f.Cb({wrapX:this.j}),Jx(Ra(d.imageUrlSubdomains,function(b){var c=d.imageUrl.replace("{subdomain}", -b).replace("{culture}",g);return function(b){return null===b?void 0:c.replace("{quadkey}",jf(b))}})));if(d.imageryProviders){var h=Ae(Be("EPSG:4326"),this.g);b=Ra(d.imageryProviders,function(b){var c=b.attribution,d={};Oa(b.coverageAreas,function(b){var c=b.zoomMin,g=Math.min(b.zoomMax,e);b=b.bbox;b=se([b[1],b[0],b[3],b[2]],h);var k,n;for(k=c;k<=g;++k)n=k.toString(),c=Ui(f,b,k),n in d?d[n].push(c):d[n]=[c]});return new qf({html:c,tileRanges:d})});b.push(Ux);this.f=b}this.r=c;Li(this,"ready")}};function Vx(b){fn.call(this,{attributions:b.attributions,extent:b.extent,logo:b.logo,projection:b.projection});this.l=void 0;this.q=m(b.distance)?b.distance:20;this.a=[];this.p=b.source;this.p.u("change",Vx.prototype.s,this)}v(Vx,fn);Vx.prototype.Hb=function(b,c,d){c!==this.l&&(this.clear(),this.l=c,this.p.Hb(b,c,d),Wx(this),this.Ea(this.a))};Vx.prototype.s=function(){this.clear();Wx(this);this.Ea(this.a);this.o()}; -function Wx(b){if(m(b.l)){b.a.length=0;for(var c=Rd(),d=b.q*b.l,e=b.p.ya(),f={},g=0,h=e.length;gk*h?g*f/(k*p):h*f/(n*p);d=ie(d);e={OPERATION:this.H?"GETDYNAMICMAPOVERLAYIMAGE":"GETMAPIMAGE",VERSION:"2.0.0",LOCALE:"en",CLIENTAGENT:"ol.source.ImageMapGuide source",CLIP:"1",SETDISPLAYDPI:this.e,SETDISPLAYWIDTH:Math.round(e[0]),SETDISPLAYHEIGHT:Math.round(e[1]),SETVIEWSCALE:f,SETVIEWCENTERX:d[0],SETVIEWCENTERY:d[1]};yb(e,c);return Hr(Jr([b],e))};l.Lj=function(b){this.b=null;this.a=b;this.o()};function Ay(b){var c=m(b.attributions)?b.attributions:null,d=b.imageExtent,e,f;m(b.imageSize)&&(e=me(d)/b.imageSize[1],f=[e]);var g=m(b.crossOrigin)?b.crossOrigin:null,h=m(b.imageLoadFunction)?b.imageLoadFunction:Ym;Wm.call(this,{attributions:c,logo:b.logo,projection:Be(b.projection),resolutions:f});this.a=new Vv(d,e,1,c,b.url,g,h)}v(Ay,Wm);Ay.prototype.rc=function(b){return oe(b,this.a.D())?this.a:null};function By(b){b=m(b)?b:{};Wm.call(this,{attributions:b.attributions,logo:b.logo,projection:b.projection,resolutions:b.resolutions});this.F=m(b.crossOrigin)?b.crossOrigin:null;this.c=b.url;this.i=m(b.imageLoadFunction)?b.imageLoadFunction:Ym;this.a=b.params;this.e=!0;Cy(this);this.s=b.serverType;this.H=m(b.hidpi)?b.hidpi:!0;this.b=null;this.l=[0,0];this.q=0;this.p=m(b.ratio)?b.ratio:1.5}v(By,Wm);var Dy=[101,101];l=By.prototype; -l.Sj=function(b,c,d,e){if(m(this.c)){var f=le(b,c,0,Dy),g={SERVICE:"WMS",VERSION:"1.3.0",REQUEST:"GetFeatureInfo",FORMAT:"image/png",TRANSPARENT:!0,QUERY_LAYERS:this.a.LAYERS};yb(g,this.a,e);e=Math.floor((f[3]-b[1])/c);g[this.e?"I":"X"]=Math.floor((b[0]-f[0])/c);g[this.e?"J":"Y"]=e;return Ey(this,f,Dy,1,Be(d),g)}};l.Uj=function(){return this.a}; -l.rc=function(b,c,d,e){if(!m(this.c))return null;c=Xm(this,c);1==d||this.H&&m(this.s)||(d=1);var f=this.b;if(null!==f&&this.q==this.d&&f.resolution==c&&f.f==d&&Yd(f.D(),b))return f;f={SERVICE:"WMS",VERSION:"1.3.0",REQUEST:"GetMap",FORMAT:"image/png",TRANSPARENT:!0};yb(f,this.a);b=b.slice();var g=(b[0]+b[2])/2,h=(b[1]+b[3])/2;if(1!=this.p){var k=this.p*pe(b)/2,n=this.p*me(b)/2;b[0]=g-k;b[1]=h-n;b[2]=g+k;b[3]=h+n}var k=c/d,n=Math.ceil(pe(b)/k),p=Math.ceil(me(b)/k);b[0]=g-k*n/2;b[2]=g+k*n/2;b[1]=h-k* -p/2;b[3]=h+k*p/2;this.l[0]=n;this.l[1]=p;e=Ey(this,b,this.l,d,e,f);this.b=new Vv(b,c,d,this.f,e,this.F,this.i);this.q=this.d;return this.b};l.Tj=function(){return this.i}; -function Ey(b,c,d,e,f,g){g[b.e?"CRS":"SRS"]=f.a;"STYLES"in b.a||(g.STYLES=new String(""));if(1!=e)switch(b.s){case "geoserver":g.FORMAT_OPTIONS="dpi:"+(90*e+.5|0);break;case "mapserver":g.MAP_RESOLUTION=90*e;break;case "carmentaserver":case "qgis":g.DPI=90*e}g.WIDTH=d[0];g.HEIGHT=d[1];d=f.b;var h;b.e&&"ne"==d.substr(0,2)?h=[c[1],c[0],c[3],c[2]]:h=c;g.BBOX=h.join(",");return Hr(Jr([b.c],g))}l.Vj=function(){return this.c};l.Wj=function(b){this.b=null;this.i=b;this.o()}; -l.Xj=function(b){b!=this.c&&(this.c=b,this.b=null,this.o())};l.Yj=function(b){yb(this.a,b);Cy(this);this.b=null;this.o()};function Cy(b){b.e=0<=Ka(ub(b.a,"VERSION","1.3.0"),"1.3")};function Fy(b){b=m(b)?b:{};vy.call(this,{attributions:b.attributions,doc:b.doc,format:new es({extractStyles:b.extractStyles,defaultStyle:b.defaultStyle}),logo:b.logo,node:b.node,projection:b.projection,text:b.text,url:b.url,urls:b.urls})}v(Fy,vy);function Gy(b){var c=m(b.projection)?b.projection:"EPSG:3857",d=new Sx({extent:Zi(c),maxZoom:b.maxZoom,tileSize:b.tileSize});Qx.call(this,{attributions:b.attributions,crossOrigin:b.crossOrigin,logo:b.logo,projection:c,tileGrid:d,tileLoadFunction:b.tileLoadFunction,tilePixelRatio:b.tilePixelRatio,tileUrlFunction:Kx});this.c=d.Cb({wrapX:b.wrapX});m(b.tileUrlFunction)?this.sa(b.tileUrlFunction):m(b.urls)?this.sa(Ix(b.urls)):m(b.url)&&this.a(b.url)}v(Gy,Qx); -Gy.prototype.sa=function(b){Gy.R.sa.call(this,Lx(this.c,b))};Gy.prototype.a=function(b){this.sa(Ix(Mx(b)))};function Hy(b){b=m(b)?b:{};var c;m(b.attributions)?c=b.attributions:c=[Iy];var d=Qb?"https:":"http:";Gy.call(this,{attributions:c,crossOrigin:m(b.crossOrigin)?b.crossOrigin:"anonymous",opaque:!0,maxZoom:m(b.maxZoom)?b.maxZoom:19,tileLoadFunction:b.tileLoadFunction,url:m(b.url)?b.url:d+"//{a-c}.tile.openstreetmap.org/{z}/{x}/{y}.png",wrapX:b.wrapX})}v(Hy,Gy);var Iy=new qf({html:'© OpenStreetMap contributors.'});function Jy(b){b=m(b)?b:{};var c=Ky[b.layer],d=Qb?"https:":"http:";Gy.call(this,{attributions:c.attributions,crossOrigin:"anonymous",logo:"//developer.mapquest.com/content/osm/mq_logo.png",maxZoom:c.maxZoom,opaque:!0,tileLoadFunction:b.tileLoadFunction,url:m(b.url)?b.url:d+"//otile{1-4}-s.mqcdn.com/tiles/1.0.0/"+b.layer+"/{z}/{x}/{y}.jpg"})}v(Jy,Gy); -var Ly=new qf({html:'Tiles Courtesy of MapQuest'}),Ky={osm:{maxZoom:19,attributions:[Ly,Iy]},sat:{maxZoom:18,attributions:[Ly,new qf({html:"Portions Courtesy NASA/JPL-Caltech and U.S. Depart. of Agriculture, Farm Service Agency"})]},hyb:{maxZoom:18,attributions:[Ly,Iy]}};function My(b){b=m(b)?b:{};vy.call(this,{attributions:b.attributions,doc:b.doc,format:new Ot,logo:b.logo,node:b.node,projection:b.projection,text:b.text,url:b.url,urls:b.urls})}v(My,vy);function Ny(b){ty.call(this,{attributions:b.attributions,format:b.format,logo:b.logo,projection:b.projection});this.p=new an;this.q=b.loader;this.s=m(b.strategy)?b.strategy:ux;this.l={}}v(Ny,ty);Ny.prototype.gb=function(b){var c=[],d,e;d=0;for(e=b.length;dStamen Design, under CC BY 3.0.'}),Iy];function Sy(b,c){Pi.call(this,b,2);this.b=c.va(b[0]);this.d={}}v(Sy,Pi);Sy.prototype.Qa=function(b){b=m(b)?ma(b):-1;if(b in this.d)return this.d[b];var c=this.b,d=Pf(c,c);d.strokeStyle="black";d.strokeRect(.5,.5,c+.5,c+.5);d.fillStyle="black";d.textAlign="center";d.textBaseline="middle";d.font="24px sans-serif";d.fillText(kf(this.a),c/2,c/2);return this.d[b]=d.canvas};function Ty(b){$i.call(this,{opaque:!1,projection:b.projection,tileGrid:b.tileGrid});this.a=new Nx}v(Ty,$i);Ty.prototype.Dd=function(){return Ox(this.a)}; -Ty.prototype.Be=function(b){Px(this.a,b)};Ty.prototype.Fb=function(b,c,d){var e=this.ib(b,c,d);if(Bo(this.a,e))return this.a.get(e);b=new Sy([b,c,d],this.tileGrid);this.a.set(e,b);return b};function Uy(b){Qx.call(this,{crossOrigin:b.crossOrigin,projection:Be("EPSG:3857"),state:"loading",tileLoadFunction:b.tileLoadFunction});this.a=b.wrapX;(new Cx(b.url)).send(void 0,ra(this.c,this))}v(Uy,Qx); -Uy.prototype.c=function(b){var c=Be("EPSG:4326"),d=this.g,e;m(b.bounds)&&(e=se(b.bounds,Ae(c,d)));var f=b.minzoom||0,g=b.maxzoom||22;this.tileGrid=d=new Sx({extent:Zi(d),maxZoom:g,minZoom:f});this.tileUrlFunction=Lx(d.Cb({extent:e,wrapX:this.a}),Ix(b.tiles));if(m(b.attribution)){c=m(e)?e:c.D();e={};for(var h;f<=g;++f)h=f.toString(),e[h]=[Ui(d,c,f)];this.f=[new qf({html:b.attribution,tileRanges:e})]}Li(this,"ready")};function Vy(b){$i.call(this,{projection:Be("EPSG:3857"),state:"loading"});this.e=m(b.preemptive)?b.preemptive:!0;this.b=Kx;this.a=new Nx;this.c=void 0;(new Cx(b.url)).send(void 0,ra(this.Zj,this))}v(Vy,$i);l=Vy.prototype;l.Dd=function(){return Ox(this.a)};l.Be=function(b){Px(this.a,b)};l.Ph=function(){return this.c};l.nh=function(b,c,d,e,f){null===this.tileGrid?!0===f?oh(function(){d.call(e,null)}):d.call(e,null):(c=this.tileGrid.Vb(b,c),Wy(this.Fb(c[0],c[1],c[2],1,this.g),b,d,e,f))}; -l.Zj=function(b){var c=Be("EPSG:4326"),d=this.g,e;m(b.bounds)&&(e=se(b.bounds,Ae(c,d)));var f=b.minzoom||0,g=b.maxzoom||22;this.tileGrid=d=new Sx({extent:Zi(d),maxZoom:g,minZoom:f});this.c=b.template;var h=b.grids;if(null!=h){this.b=Lx(d.Cb({extent:e}),Ix(h));if(m(b.attribution)){c=m(e)?e:c.D();for(e={};f<=g;++f)h=f.toString(),e[h]=[Ui(d,c,f)];this.f=[new qf({html:b.attribution,tileRanges:e})]}Li(this,"ready")}else Li(this,"error")}; -l.Fb=function(b,c,d,e,f){var g=this.ib(b,c,d);if(Bo(this.a,g))return this.a.get(g);b=[b,c,d];e=this.b(b,e,f);e=new Xy(b,m(e)?0:4,m(e)?e:"",Ti(this.tileGrid,b),this.e);this.a.set(g,e);return e};l.Oe=function(b,c,d){b=this.ib(b,c,d);Bo(this.a,b)&&this.a.get(b)};function Xy(b,c,d,e,f){Pi.call(this,b,c);this.g=d;this.d=e;this.j=f;this.c=this.f=this.b=null}v(Xy,Pi);l=Xy.prototype;l.Qa=function(){return null}; -function Yy(b,c){if(null===b.b||null===b.f||null===b.c)return null;var d=b.b[Math.floor((1-(c[1]-b.d[1])/(b.d[3]-b.d[1]))*b.b.length)];if(!ia(d))return null;d=d.charCodeAt(Math.floor((c[0]-b.d[0])/(b.d[2]-b.d[0])*d.length));93<=d&&d--;35<=d&&d--;d=b.f[d-32];return null!=d?b.c[d]:null}function Wy(b,c,d,e,f){0==b.state&&!0===f?(Rc(b,"change",function(){d.call(e,Yy(this,c))},!1,b),Zy(b)):!0===f?oh(function(){d.call(e,Yy(this,c))},b):d.call(e,Yy(b,c))}l.nb=function(){return this.g}; -l.di=function(){this.state=3;Qi(this)};l.pi=function(b){this.b=b.grid;this.f=b.keys;this.c=b.data;this.state=4;Qi(this)};function Zy(b){0==b.state&&(b.state=1,(new Cx(b.g)).send(void 0,ra(b.pi,b),ra(b.di,b)))}l.load=function(){this.j&&Zy(this)};function $y(b){ty.call(this,{attributions:b.attributions,format:b.format,logo:b.logo,projection:b.projection});this.p=b.tileGrid;this.q=Kx;this.s=this.p.Cb();this.l={};m(b.tileUrlFunction)?(this.q=b.tileUrlFunction,this.o()):m(b.urls)?(this.q=Ix(b.urls),this.o()):m(b.url)&&(this.q=Ix(Mx(b.url)),this.o())}v($y,ty);l=$y.prototype;l.clear=function(){sb(this.l)}; -function az(b,c,d,e){var f=b.l;b=b.p.Vb(c,d);f=f[b[0]+"/"+b[1]+"/"+b[2]];if(m(f))for(b=0,d=f.length;bp||n<=p)return null;b=b[2];return b<-n||-1g||e>g;)f.push([Math.ceil(d/g),Math.ceil(e/g)]),g+=g;break;case "truncated":for(;d>g||e>g;)f.push([Math.ceil(d/g),Math.ceil(e/g)]),d>>=1,e>>=1}f.push([1,1]);f.reverse();for(var g=[1],h=[0],e=1,d=f.length;ethis.b||d+this.a>this.b)return null;e=oz(this,!1,b,c,d,e,g);if(null===e)return null;b=oz(this,!0,b,c,d,m(f)?f:$c,g);return{offsetX:e.offsetX,offsetY:e.offsetY,image:e.image,sf:b.image}}; -function oz(b,c,d,e,f,g,h){var k=c?b.e:b.f,n,p,q;p=0;for(q=k.length;p=c+this.a&&g.height>=d+this.a)return k={offsetX:g.x+this.a,offsetY:g.y+this.a,image:this.b},this.c[b]=k,e.call(f,this.f,g.x+this.a,g.y+this.a),b=h,c=c+this.a,d=d+this.a,f=e=void 0,g.width-c>g.height-d?(e={x:g.x+c,y:g.y,width:g.width-c,height:g.height},f={x:g.x,y:g.y+d,width:c,height:g.height-d},pz(this,b,e,f)):(e={x:g.x+c,y:g.y,width:g.width-c,height:d},f={x:g.x,y:g.y+d,width:g.width,height:g.height- -d},pz(this,b,e,f)),k;return null};function pz(b,c,d,e){c=[c,1];0=3){range_s = false;} - makeGraph(DygraphContent, range_s); - - - var dbtn =""; - $("#chart").before(dbtn); - document.getElementById('dbtn').addEventListener('click', function () { - - if(preload_resource['name'] == ''){var filename = 'Unnamed resource';} - else{var filename = preload_resource['name'];} - var a = document.createElement('a'); - if(v_list.length != 0){ - a.href = 'data:attachment/csv,' + csvContent; - a.target = '_blank'; - a.download = filename+'.csv'; - } - else{ - a.href = 'data:attachment/json,' + JSON.stringify(data); - a.target = '_blank'; - a.download = filename+'.json'; - - } - document.body.appendChild(a); - a.click(); - }, false); - } - } - }, - error:function(jqXHR,textStatus,errorThrown){ - if(textStatus=='error'&&jqXHR.responseText.length){ - document.getElementById('chart').style.height = '0px'; - document.getElementById('chart').style.border = '0px'; - } - else{document.getElementById('chart').style.height = '0px';; - document.getElementById('chart').style.border = '0px';}} - }); - } - } - } -}); - diff --git a/ckanext/ngsiview/theme/public/view_ngsi_chart.min.js b/ckanext/ngsiview/theme/public/view_ngsi_chart.min.js deleted file mode 100644 index 611fe73..0000000 --- a/ckanext/ngsiview/theme/public/view_ngsi_chart.min.js +++ /dev/null @@ -1,159 +0,0 @@ -ckan.module('ngsiviewchart',function(jQuery,_){ - return{ - options:{ - i18n:{error:_('An error occurred: %(text)s %(error)s')}, - parameters:{contentType:'application/json', - dataType:'json', - dataConverter:function(data){return JSON.stringify(data,null,2);}, - language:'json',type:'GET'}}, - initialize:function(){ - var self=this; - var p; - p=this.options.parameters; - - if(typeof(view_enable) == 'undefined'){ - view_enable = []; - view_enable[0] = true; - resource_url = preload_resource['url'] - } - - function makeGraph(DygraphContent, range_s){ - new Dygraph( - document.getElementById("chart"), - DygraphContent, - { - fillGraph: 'true', - rollover : '14', - connectSeparatedPoints: 'true', - axisLabelFontSize: 10, - legend: 'always', - labelsDivStyles: { 'textAlign': 'right' }, - showRangeSelector: range_s, - } - ); - } - - if(view_enable[0]){ - jQuery.ajax(resource_url,{ - type:p.type, - contentType:p.contentType, - dataType:p.dataType, - success:function(data,textStatus,jqXHR){ - if(preload_resource['format'].toLowerCase() == 'ngsi-h'){ - document.getElementById('chart').style.height = '400px'; - document.getElementById('chart').style.border = '1px solid rgba(0, 0, 0, 0.15)'; - - if(typeof(data.contextResponses) != 'undefined'){ - var entity_id = ''; - var attribute_name = ''; - var attributes = []; - var h_list = ['Date']; - var v_list = []; - var d_list = []; - for(i=0;i=3){range_s = false;} - makeGraph(DygraphContent, range_s); - - - var dbtn =""; - $("#chart").before(dbtn); - document.getElementById('dbtn').addEventListener('click', function () { - - if(preload_resource['name'] == ''){var filename = 'Unnamed resource';} - else{var filename = preload_resource['name'];} - var a = document.createElement('a'); - if(v_list.length != 0){ - a.href = 'data:attachment/csv,' + csvContent; - a.target = '_blank'; - a.download = filename+'.csv'; - } - else{ - a.href = 'data:attachment/json,' + JSON.stringify(data); - a.target = '_blank'; - a.download = filename+'.json'; - - } - document.body.appendChild(a); - a.click(); - }, false); - } - } - }, - error:function(jqXHR,textStatus,errorThrown){ - if(textStatus=='error'&&jqXHR.responseText.length){ - document.getElementById('chart').style.height = '0px'; - document.getElementById('chart').style.border = '0px'; - } - else{document.getElementById('chart').style.height = '0px';; - document.getElementById('chart').style.border = '0px';}} - }); - } - } - } -}); - diff --git a/ckanext/ngsiview/theme/public/view_ngsi_map.js b/ckanext/ngsiview/theme/public/view_ngsi_map.js deleted file mode 100644 index 914a45e..0000000 --- a/ckanext/ngsiview/theme/public/view_ngsi_map.js +++ /dev/null @@ -1,358 +0,0 @@ -ckan.module('ngsiviewmap',function(jQuery,_){ - return{ - options:{ - i18n:{error:_('An error occurred: %(text)s %(error)s')}, - parameters:{contentType:'application/json', - dataType:'json', - dataConverter:function(data){return JSON.stringify(data,null,2);}, - language:'json',type:'GET'}}, - initialize:function(){ - if (preload_resource['format'].toLowerCase() === "fiware-ngsi") { - document.getElementById('map').style.height = '400px'; - document.getElementById('map').style.border = '1px solid rgba(0, 0, 0, 0.15)'; - - var self = this; - var p; - p = this.options.parameters; - - var map_content = "
"; - $('#map').append(map_content); - - if(typeof(view_enable) == 'undefined'){ - view_enable = []; - view_enable[0] = true; - resource_url = preload_resource['url']; - } - if(view_enable[0]){ - jQuery.ajax(resource_url,{ - type:p.type, - contentType:p.contentType, - dataType:p.dataType, - success:function(data,textStatus,jqXHR){ - var i; - var pos_list = new Array(); - var listlat = new Array(); - var listlon = new Array(); - - if(typeof(data.contextElement) != 'undefined'){ - var contextElement = data; - data = {}; - data['contextResponses'] = [contextElement]; - } - - if(typeof(data.contextResponses) != 'undefined'){ - for(i=0;i 40){attributes[x].value = attributes[x].value.substring(0, 37)+"...";} - info += ""+attributes[x].name+": "+attributes[x].value+""; - } - info += ""; - dat.attrib = info; - pos_list[pos_list.length] = dat; - listlat[listlat.length] = parseFloat(cd[0]); - listlon[listlon.length] = parseFloat(cd[1]); - } - if(attributes[e].type == 'urn:x-ogc:def:phenomenon:IDAS:1.0:latitude'){ - lat = parseFloat(attributes[e].value); - } - if(attributes[e].type == 'urn:x-ogc:def:phenomenon:IDAS:1.0:longitude'){ - lon = parseFloat(attributes[e].value); - } - } - } - if(lat.length != 0 && lon.length !=0){ - var dat = {} - dat.pos = [lon,lat]; - dat.name = data.contextResponses[i]['contextElement']['id']; - var x; - info += ""; - for(x=0;x 40){attributes[x].value = attributes[x].value.substring(0, 37)+"...";} - info += ""; - } - info += "
"+attributes[x].name+": "+attributes[x].value+"
"; - dat.attrib = info; - pos_list[pos_list.length] = dat; - listlat[listlat.length] = lat; - listlon[listlon.length] = lon; - } - } - } - - if (pos_list.length == 0){ - document.getElementById('map').style.height = '0px'; - document.getElementById('map').style.border = '0px'; - } - - var dbtn =""; - $("#map").before(dbtn); - document.getElementById('dbtn').addEventListener('click', function () { - var d_file = JSON.stringify(data); - if(preload_resource['name'] == ''){var filename = 'Unnamed resource';} - else{var filename = preload_resource['name'];} - var a = document.createElement('a'); - a.href = 'data:attachment/json,' + d_file; - a.target = '_blank'; - a.download = filename+'.json'; - - document.body.appendChild(a); - a.click(); - }, false); - - - - var iconStyle = new ol.style.Style({ - image: new ol.style.Icon(/** @type {olx.style.IconOptions} */ ({ - anchor: [0.5, 46], - anchorXUnits: 'fraction', - anchorYUnits: 'pixels', - opacity: 0.75, - src: '/images/marker-icon.png' - })) - }); - - var feats = new Array(); - for(var z=0;z1){ - if(size>30){ - style = [new ol.style.Style({ - image: new ol.style.Circle({ - radius: 20, - stroke: new ol.style.Stroke({ - color: 'rgba(241, 128, 23, 0.3)', - width: 5, - }), - fill: new ol.style.Fill({ - color: 'rgba(241, 128, 23, 0.8)' - }) - }), - text: new ol.style.Text({ - text: size.toString(), - fill: new ol.style.Fill({ - color: '#000' - }) - }) - })]; - styleCache[size] = style; - } - - else if(size>10){ - style = [new ol.style.Style({ - image: new ol.style.Circle({ - radius: 15, - stroke: new ol.style.Stroke({ - color: 'rgba(110, 204, 57, 0.3)', - width: 4, - }), - fill: new ol.style.Fill({ - color: 'rgba(110, 204, 57, 0.8)' - }) - }), - text: new ol.style.Text({ - text: size.toString(), - fill: new ol.style.Fill({ - color: '#000' - }) - }) - })]; - styleCache[size] = style; - } - else{ - style = [new ol.style.Style({ - image: new ol.style.Circle({ - radius: 10, - stroke: new ol.style.Stroke({ - color: 'rgba(241, 211, 87, 0.3)', - width: 3, - }), - fill: new ol.style.Fill({ - color: 'rgba(241, 211, 87, 0.8)' - }) - }), - text: new ol.style.Text({ - text: size.toString(), - fill: new ol.style.Fill({ - color: '#000' - }) - }) - })]; - styleCache[size] = style; - } - } - else{ - style = [new ol.style.Style({ - image: new ol.style.Icon({ - anchor: [0.5, 46], - anchorXUnits: 'fraction', - anchorYUnits: 'pixels', - opacity: 0.75, - src: '/images/marker-icon.png' - }) - })]; - } - } - return style; - } - }); - var map = new ol.Map({ - view: view, - layers: [ - new ol.layer.Tile({source: new ol.source.MapQuest({layer: 'osm'})}), - clusters - ], - target: 'map'}); - - var element = document.getElementById('popup'); - var popup = new ol.Overlay({ - element: element, - positioning: 'bottom-center', - stopEvent: false - }); - map.addOverlay(popup); - - var feature; - // display popup on click - map.on('click', function(evt) { - feature = map.forEachFeatureAtPixel(evt.pixel, - function(feature, layer){return feature;}); - - var pan = ol.animation.pan({ - duration: 1500, - source: /** @type {ol.Coordinate} */ (view.getCenter()) - }); - var zoom = ol.animation.zoom({ - duration: 2000, - resolution: map.getView().getResolution() - }); - - if (feature){ - if(feature.get('features').length==1){ - $(element).popover('destroy'); - $(element).popover({ - 'title':'
'+feature.get('features')[0].get('name')+'
', - 'delay': { show: 500, hide: 50 }, - 'html': true, - 'content': feature.get('features')[0].get('attrib'), - }); - var geometry = feature.getGeometry(); - var coord = geometry.getCoordinates(); - popup.setPosition(coord); - $(element).popover('show'); - map.beforeRender(pan); - view.setCenter(coord); - } - else{ - map.beforeRender(pan); - var geometry = feature.getGeometry(); - var coord = geometry.getCoordinates(); - view.setCenter(coord); - map.beforeRender(zoom); - map.getView().setResolution(map.getView().getResolution()/4); - } - } - else {$(element).popover('destroy');} - }); - - function mapZoom(){ - - var maxlat = Math.max.apply(null, listlat); - var minlat = Math.min.apply(null, listlat); - var maxlon = Math.max.apply(null, listlon); - var minlon = Math.min.apply(null, listlon); - - //centerzoom - centerlat = (maxlat + minlat)/2; - centerlon = (maxlon + minlon)/2; - var autofocus = ol.proj.transform([centerlon, centerlat], 'EPSG:4326', 'EPSG:3857'); - - dist = []; - for(i=0;i11){level = 11;} - autozoom = zoomlist[level]; - - var pan = ol.animation.pan({ - duration: 2000, - source: /** @type {ol.Coordinate} */ (view.getCenter()) - }); - map.beforeRender(pan); - view.setCenter(autofocus); - - var zoom = ol.animation.zoom({ - duration: 2000, - resolution: map.getView().getResolution() - }); - map.beforeRender(zoom); - map.getView().setZoom(autozoom); - } - setTimeout(mapZoom, 2000); - - }, - error:function(jqXHR,textStatus,errorThrown){ - if(textStatus=='error'&&jqXHR.responseText.length){ - document.getElementById('map').style.height = '0px'; - document.getElementById('map').style.border = '0px'; - } - else{document.getElementById('map').style.height = '0px';; - document.getElementById('map').style.border = '0px';}}}); - } - else{ - document.getElementById('map').style.height = '0px'; - document.getElementById('map').style.border = '0px'; - } - } - } - }; -}); - diff --git a/ckanext/ngsiview/theme/public/view_ngsi_map.min.js b/ckanext/ngsiview/theme/public/view_ngsi_map.min.js deleted file mode 100644 index 914a45e..0000000 --- a/ckanext/ngsiview/theme/public/view_ngsi_map.min.js +++ /dev/null @@ -1,358 +0,0 @@ -ckan.module('ngsiviewmap',function(jQuery,_){ - return{ - options:{ - i18n:{error:_('An error occurred: %(text)s %(error)s')}, - parameters:{contentType:'application/json', - dataType:'json', - dataConverter:function(data){return JSON.stringify(data,null,2);}, - language:'json',type:'GET'}}, - initialize:function(){ - if (preload_resource['format'].toLowerCase() === "fiware-ngsi") { - document.getElementById('map').style.height = '400px'; - document.getElementById('map').style.border = '1px solid rgba(0, 0, 0, 0.15)'; - - var self = this; - var p; - p = this.options.parameters; - - var map_content = "
"; - $('#map').append(map_content); - - if(typeof(view_enable) == 'undefined'){ - view_enable = []; - view_enable[0] = true; - resource_url = preload_resource['url']; - } - if(view_enable[0]){ - jQuery.ajax(resource_url,{ - type:p.type, - contentType:p.contentType, - dataType:p.dataType, - success:function(data,textStatus,jqXHR){ - var i; - var pos_list = new Array(); - var listlat = new Array(); - var listlon = new Array(); - - if(typeof(data.contextElement) != 'undefined'){ - var contextElement = data; - data = {}; - data['contextResponses'] = [contextElement]; - } - - if(typeof(data.contextResponses) != 'undefined'){ - for(i=0;i 40){attributes[x].value = attributes[x].value.substring(0, 37)+"...";} - info += ""+attributes[x].name+": "+attributes[x].value+""; - } - info += ""; - dat.attrib = info; - pos_list[pos_list.length] = dat; - listlat[listlat.length] = parseFloat(cd[0]); - listlon[listlon.length] = parseFloat(cd[1]); - } - if(attributes[e].type == 'urn:x-ogc:def:phenomenon:IDAS:1.0:latitude'){ - lat = parseFloat(attributes[e].value); - } - if(attributes[e].type == 'urn:x-ogc:def:phenomenon:IDAS:1.0:longitude'){ - lon = parseFloat(attributes[e].value); - } - } - } - if(lat.length != 0 && lon.length !=0){ - var dat = {} - dat.pos = [lon,lat]; - dat.name = data.contextResponses[i]['contextElement']['id']; - var x; - info += ""; - for(x=0;x 40){attributes[x].value = attributes[x].value.substring(0, 37)+"...";} - info += ""; - } - info += "
"+attributes[x].name+": "+attributes[x].value+"
"; - dat.attrib = info; - pos_list[pos_list.length] = dat; - listlat[listlat.length] = lat; - listlon[listlon.length] = lon; - } - } - } - - if (pos_list.length == 0){ - document.getElementById('map').style.height = '0px'; - document.getElementById('map').style.border = '0px'; - } - - var dbtn =""; - $("#map").before(dbtn); - document.getElementById('dbtn').addEventListener('click', function () { - var d_file = JSON.stringify(data); - if(preload_resource['name'] == ''){var filename = 'Unnamed resource';} - else{var filename = preload_resource['name'];} - var a = document.createElement('a'); - a.href = 'data:attachment/json,' + d_file; - a.target = '_blank'; - a.download = filename+'.json'; - - document.body.appendChild(a); - a.click(); - }, false); - - - - var iconStyle = new ol.style.Style({ - image: new ol.style.Icon(/** @type {olx.style.IconOptions} */ ({ - anchor: [0.5, 46], - anchorXUnits: 'fraction', - anchorYUnits: 'pixels', - opacity: 0.75, - src: '/images/marker-icon.png' - })) - }); - - var feats = new Array(); - for(var z=0;z1){ - if(size>30){ - style = [new ol.style.Style({ - image: new ol.style.Circle({ - radius: 20, - stroke: new ol.style.Stroke({ - color: 'rgba(241, 128, 23, 0.3)', - width: 5, - }), - fill: new ol.style.Fill({ - color: 'rgba(241, 128, 23, 0.8)' - }) - }), - text: new ol.style.Text({ - text: size.toString(), - fill: new ol.style.Fill({ - color: '#000' - }) - }) - })]; - styleCache[size] = style; - } - - else if(size>10){ - style = [new ol.style.Style({ - image: new ol.style.Circle({ - radius: 15, - stroke: new ol.style.Stroke({ - color: 'rgba(110, 204, 57, 0.3)', - width: 4, - }), - fill: new ol.style.Fill({ - color: 'rgba(110, 204, 57, 0.8)' - }) - }), - text: new ol.style.Text({ - text: size.toString(), - fill: new ol.style.Fill({ - color: '#000' - }) - }) - })]; - styleCache[size] = style; - } - else{ - style = [new ol.style.Style({ - image: new ol.style.Circle({ - radius: 10, - stroke: new ol.style.Stroke({ - color: 'rgba(241, 211, 87, 0.3)', - width: 3, - }), - fill: new ol.style.Fill({ - color: 'rgba(241, 211, 87, 0.8)' - }) - }), - text: new ol.style.Text({ - text: size.toString(), - fill: new ol.style.Fill({ - color: '#000' - }) - }) - })]; - styleCache[size] = style; - } - } - else{ - style = [new ol.style.Style({ - image: new ol.style.Icon({ - anchor: [0.5, 46], - anchorXUnits: 'fraction', - anchorYUnits: 'pixels', - opacity: 0.75, - src: '/images/marker-icon.png' - }) - })]; - } - } - return style; - } - }); - var map = new ol.Map({ - view: view, - layers: [ - new ol.layer.Tile({source: new ol.source.MapQuest({layer: 'osm'})}), - clusters - ], - target: 'map'}); - - var element = document.getElementById('popup'); - var popup = new ol.Overlay({ - element: element, - positioning: 'bottom-center', - stopEvent: false - }); - map.addOverlay(popup); - - var feature; - // display popup on click - map.on('click', function(evt) { - feature = map.forEachFeatureAtPixel(evt.pixel, - function(feature, layer){return feature;}); - - var pan = ol.animation.pan({ - duration: 1500, - source: /** @type {ol.Coordinate} */ (view.getCenter()) - }); - var zoom = ol.animation.zoom({ - duration: 2000, - resolution: map.getView().getResolution() - }); - - if (feature){ - if(feature.get('features').length==1){ - $(element).popover('destroy'); - $(element).popover({ - 'title':'
'+feature.get('features')[0].get('name')+'
', - 'delay': { show: 500, hide: 50 }, - 'html': true, - 'content': feature.get('features')[0].get('attrib'), - }); - var geometry = feature.getGeometry(); - var coord = geometry.getCoordinates(); - popup.setPosition(coord); - $(element).popover('show'); - map.beforeRender(pan); - view.setCenter(coord); - } - else{ - map.beforeRender(pan); - var geometry = feature.getGeometry(); - var coord = geometry.getCoordinates(); - view.setCenter(coord); - map.beforeRender(zoom); - map.getView().setResolution(map.getView().getResolution()/4); - } - } - else {$(element).popover('destroy');} - }); - - function mapZoom(){ - - var maxlat = Math.max.apply(null, listlat); - var minlat = Math.min.apply(null, listlat); - var maxlon = Math.max.apply(null, listlon); - var minlon = Math.min.apply(null, listlon); - - //centerzoom - centerlat = (maxlat + minlat)/2; - centerlon = (maxlon + minlon)/2; - var autofocus = ol.proj.transform([centerlon, centerlat], 'EPSG:4326', 'EPSG:3857'); - - dist = []; - for(i=0;i11){level = 11;} - autozoom = zoomlist[level]; - - var pan = ol.animation.pan({ - duration: 2000, - source: /** @type {ol.Coordinate} */ (view.getCenter()) - }); - map.beforeRender(pan); - view.setCenter(autofocus); - - var zoom = ol.animation.zoom({ - duration: 2000, - resolution: map.getView().getResolution() - }); - map.beforeRender(zoom); - map.getView().setZoom(autozoom); - } - setTimeout(mapZoom, 2000); - - }, - error:function(jqXHR,textStatus,errorThrown){ - if(textStatus=='error'&&jqXHR.responseText.length){ - document.getElementById('map').style.height = '0px'; - document.getElementById('map').style.border = '0px'; - } - else{document.getElementById('map').style.height = '0px';; - document.getElementById('map').style.border = '0px';}}}); - } - else{ - document.getElementById('map').style.height = '0px'; - document.getElementById('map').style.border = '0px'; - } - } - } - }; -}); -