diff --git a/demos/forest/frontend/components/forest_map/SubTileZoomMapType.js b/demos/forest/frontend/components/forest_map/SubTileZoomMapType.js index 862d68a2d..1d54dbd63 100644 --- a/demos/forest/frontend/components/forest_map/SubTileZoomMapType.js +++ b/demos/forest/frontend/components/forest_map/SubTileZoomMapType.js @@ -1,3 +1,7 @@ +/** + * @fileoverview + * @suppress {missingProperties} See: b/33430503 + */ goog.provide('forest.SubTileZoomMapType'); diff --git a/javascript/build/ee_api_js.js b/javascript/build/ee_api_js.js index ad4909e86..ae86c09cc 100644 --- a/javascript/build/ee_api_js.js +++ b/javascript/build/ee_api_js.js @@ -24,13 +24,13 @@ a);else{var c=a.type,d=a.Fb;b.removeEventListener?b.removeEventListener(c,d,a.ca b){if(a.Ka)return!0;if(!Eb){if(!b)a:{b=["window","event"];for(var c=k,d;d=b.shift();)if(null!=c[d])c=c[d];else{b=null;break a}b=c}d=b;b=new Gb(d,this);c=!0;if(!(0>d.keyCode||void 0!=d.returnValue)){a:{var e=!1;if(0==d.keyCode)try{d.keyCode=-1;break a}catch(g){e=!0}if(e||void 0==d.returnValue)d.returnValue=!0}d=[];for(e=b.currentTarget;e;e=e.parentNode)d.push(e);a=a.type;for(e=d.length-1;!b.Ja&&0<=e;e--){b.currentTarget=d[e];var f=cc(d[e],a,!0,b),c=c&&f}for(e=0;!b.Ja&&e>>0),Tb=function(a){z(a,"Listener can not be null.");if(r(a))return a;z(a.handleEvent,"An object listener must have handleEvent method.");a[dc]||(a[dc]=function(b){return a.handleEvent(b)});return a[dc]};var ec=function(a){A.call(this);this.ta=a;this.i={}};x(ec,A);var fc=[];ec.prototype.X=function(a,b,c,d){n(b)||(b&&(fc[0]=b.toString()),b=fc);for(var e=0;e++d,"infinite loop")}c=this.Pd;d=a.type||a;if(p(a))a=new B(a,c);else if(a instanceof B)a.target=a.target||c;else{var e=a;a=new B(d,c);jb(a,e)}var e=!0,f;if(b)for(var g=b.length-1;!a.Ja&&0<=g;g--)f=a.currentTarget=b[g],e=ic(f,d,!0,a)&&e;a.Ja||(f=a.currentTarget=c,e=ic(f,d,!0,a)&&e,a.Ja||(e=ic(f,d,!1,a)&&e));if(b)for(g=0;!a.Ja&&g++d,"infinite loop")}c=this.Pd;d=a.type||a;if(p(a))a=new B(a,c);else if(a instanceof B)a.target=a.target||c;else{var e=a;a=new B(d,c);jb(a,e)}var e=!0,f;if(b)for(var g=b.length-1;!a.Ja&&0<=g;g--)f=a.currentTarget=b[g],e=ic(f,d,!0,a)&&e;a.Ja||(f=a.currentTarget=c,e=ic(f,d,!0,a)&&e,a.Ja||(e=ic(f,d,!1,a)&&e));if(b)for(g=0;!a.Ja&&g=b.ac&&b.cancel())}this.yd?this.yd.call(this.ad,this):this.Fc=!0;this.Fa||Qc(this,new Rc)}};Pc.prototype.Yc=function(a,b){this.$b=!1;Sc(this,a,b)}; -var Sc=function(a,b,c){a.Fa=!0;a.fa=c;a.Xa=!b;Tc(a)},Vc=function(a){if(a.Fa){if(!a.Fc)throw new Uc;a.Fc=!1}};Pc.prototype.bc=function(a){Vc(this);Wc(a);Sc(this,!0,a)};var Qc=function(a,b){Vc(a);Wc(b);Sc(a,!1,b)},Wc=function(a){z(!(a instanceof Pc),"An execution sequence may not be initiated with a blocking Deferred.")},Xc=function(a,b,c){z(!a.Tc,"Blocking Deferreds can not be re-used");a.Jb.push([b,c,void 0]);a.Fa&&Tc(a)}; +var Pc=function(a,b){this.Jb=[];this.yd=a;this.bd=b||null;this.Xa=this.Fa=!1;this.fa=void 0;this.Gc=this.Uc=this.$b=!1;this.Rb=0;this.m=null;this.ac=0};Pc.prototype.cancel=function(a){if(this.Fa)this.fa instanceof Pc&&this.fa.cancel();else{if(this.m){var b=this.m;delete this.m;a?b.cancel(a):(b.ac--,0>=b.ac&&b.cancel())}this.yd?this.yd.call(this.bd,this):this.Gc=!0;this.Fa||Qc(this,new Rc)}};Pc.prototype.Zc=function(a,b){this.$b=!1;Sc(this,a,b)}; +var Sc=function(a,b,c){a.Fa=!0;a.fa=c;a.Xa=!b;Tc(a)},Vc=function(a){if(a.Fa){if(!a.Gc)throw new Uc;a.Gc=!1}};Pc.prototype.bc=function(a){Vc(this);Wc(a);Sc(this,!0,a)};var Qc=function(a,b){Vc(a);Wc(b);Sc(a,!1,b)},Wc=function(a){z(!(a instanceof Pc),"An execution sequence may not be initiated with a blocking Deferred.")},Xc=function(a,b,c){z(!a.Uc,"Blocking Deferreds can not be re-used");a.Jb.push([b,c,void 0]);a.Fa&&Tc(a)}; Pc.prototype.then=function(a,b,c){var d,e,f=new Bc(function(a,b){d=a;e=b});Xc(this,d,function(a){a instanceof Rc?f.cancel():e(a)});return f.then(a,b,c)};xc(Pc); -var Yc=function(a){return Ja(a.Jb,function(a){return r(a[1])})},Tc=function(a){if(a.Rb&&a.Fa&&Yc(a)){var b=a.Rb,c=Zc[b];c&&(k.clearTimeout(c.da),delete Zc[b]);a.Rb=0}a.m&&(a.m.ac--,delete a.m);for(var b=a.fa,d=c=!1;a.Jb.length&&!a.$b;){var e=a.Jb.shift(),f=e[0],g=e[1],e=e[2];if(f=a.Xa?g:f)try{var l=f.call(e||a.ad,b);m(l)&&(a.Xa=a.Xa&&(l==b||l instanceof Error),a.fa=b=l);if(yc(b)||"function"===typeof k.Promise&&b instanceof k.Promise)d=!0,a.$b=!0}catch(w){b=w,a.Xa=!0,Yc(a)||(c=!0)}}a.fa=b;d&&(l=u(a.Yc, -a,!0),d=u(a.Yc,a,!1),b instanceof Pc?(Xc(b,l,d),b.Tc=!0):b.then(l,d));c&&(b=new $c(b),Zc[b.da]=b,a.Rb=b.da)},Uc=function(){y.call(this)};x(Uc,y);Uc.prototype.message="Deferred has already fired";Uc.prototype.name="AlreadyCalledError";var Rc=function(){y.call(this)};x(Rc,y);Rc.prototype.message="Deferred was canceled";Rc.prototype.name="CanceledError";var $c=function(a){this.da=k.setTimeout(u(this.we,this),0);this.qb=a}; +var Yc=function(a){return Ja(a.Jb,function(a){return r(a[1])})},Tc=function(a){if(a.Rb&&a.Fa&&Yc(a)){var b=a.Rb,c=Zc[b];c&&(k.clearTimeout(c.da),delete Zc[b]);a.Rb=0}a.m&&(a.m.ac--,delete a.m);for(var b=a.fa,d=c=!1;a.Jb.length&&!a.$b;){var e=a.Jb.shift(),f=e[0],g=e[1],e=e[2];if(f=a.Xa?g:f)try{var l=f.call(e||a.bd,b);m(l)&&(a.Xa=a.Xa&&(l==b||l instanceof Error),a.fa=b=l);if(yc(b)||"function"===typeof k.Promise&&b instanceof k.Promise)d=!0,a.$b=!0}catch(w){b=w,a.Xa=!0,Yc(a)||(c=!0)}}a.fa=b;d&&(l=u(a.Zc, +a,!0),d=u(a.Zc,a,!1),b instanceof Pc?(Xc(b,l,d),b.Uc=!0):b.then(l,d));c&&(b=new $c(b),Zc[b.da]=b,a.Rb=b.da)},Uc=function(){y.call(this)};x(Uc,y);Uc.prototype.message="Deferred has already fired";Uc.prototype.name="AlreadyCalledError";var Rc=function(){y.call(this)};x(Rc,y);Rc.prototype.message="Deferred was canceled";Rc.prototype.name="CanceledError";var $c=function(a){this.da=k.setTimeout(u(this.we,this),0);this.qb=a}; $c.prototype.we=function(){z(Zc[this.da],"Cannot throw an error that is not scheduled.");delete Zc[this.da];throw this.qb;};var Zc={};var bd=function(a,b){m(a.name)?(this.name=a.name,this.code=bb[a.name]):(this.code=a.code,this.name=ad(a.code));y.call(this,ma("%s %s",this.name,b))};x(bd,y);var ad=function(a){var b=cb(function(b){return a==b});if(!m(b))throw Error("Invalid code: "+a);return b},bb={AbortError:3,EncodingError:5,InvalidModificationError:9,InvalidStateError:7,NotFoundError:1,NotReadableError:4,NoModificationAllowedError:6,PathExistsError:12,QuotaExceededError:10,SecurityError:2,SyntaxError:8,TypeMismatchError:11};var cd=function(a,b){B.call(this,a.type,b);this.ia=a};x(cd,B);var dd=function(){D.call(this);this.K=new FileReader;this.K.onloadstart=u(this.Da,this);this.K.onprogress=u(this.Da,this);this.K.onload=u(this.Da,this);this.K.onabort=u(this.Da,this);this.K.onerror=u(this.Da,this);this.K.onloadend=u(this.Da,this)};x(dd,D);h=dd.prototype;h.abort=function(){try{this.K.abort()}catch(a){throw new bd(a,"aborting read");}};h.ja=function(){return this.K.readyState};h.Da=function(a){this.dispatchEvent(new cd(a,this))};h.c=function(){dd.j.c.call(this);delete this.K}; h.readAsArrayBuffer=function(a){this.K.readAsArrayBuffer(a)};h.readAsText=function(a,b){this.K.readAsText(a,b)};var ed=function(a){return/^\s*$/.test(a)?!1:/^[\],:{}\s\u2028\u2029]*$/.test(a.replace(/\\["\\\/bfnrtu]/g,"@").replace(/(?:"[^"\\\n\r\u2028\u2029\x00-\x08\x0a-\x1f]*"|true|false|null|-?\d+(?:\.\d*)?(?:[eE][+\-]?\d+)?)[\s\u2028\u2029]*(?=:|,|]|}|$)/g,"]").replace(/(?:^|:|,)(?:[\s\u2028\u2029]*\[)+/g,""))},fd=function(a){a=String(a);if(ed(a))try{return eval("("+a+")")}catch(b){}throw Error("Invalid JSON string: "+a);},gd=function(a){return eval("("+a+")")},id=function(a){return(new hd(void 0)).v(a)}, hd=function(a){this.Hb=a};hd.prototype.v=function(a){var b=[];jd(this,a,b);return b.join("")}; var jd=function(a,b,c){if(null==b)c.push("null");else{if("object"==typeof b){if(n(b)){var d=b;b=d.length;c.push("[");for(var e="",f=0;f=a.length)throw pd;if(b in a)return a[b++];b++}};return c}throw Error("Not implemented");},sd=function(a,b){if(ea(a))try{Ga(a,b,void 0)}catch(c){if(c!==pd)throw c;}else{a=rd(a);try{for(;;)b.call(void 0,a.next(),void 0,a)}catch(c){if(c!==pd)throw c;}}};var td=function(a,b){this.u={};this.i=[];this.ib=this.h=0;var c=arguments.length;if(12*this.h&&ud(this),!0):!1};var ud=function(a){if(a.h!=a.i.length){for(var b=0,c=0;b=d.i.length)throw pd;var e=d.i[b++];return a?e:d.u[e]};return e};var vd=function(a,b){return Object.prototype.hasOwnProperty.call(a,b)};var wd=function(a){if(a.s&&"function"==typeof a.s)return a.s();if(p(a))return a.split("");if(ea(a)){for(var b=[],c=a.length,d=0;d=Jd(this).value)for(r(b)&&(b=b()),a=new Cd(a,String(b),this.ne),c&&(a.dd=c),c="log:"+a.me,k.console&&(k.console.timeStamp?k.console.timeStamp(c):k.console.markTimeline&&k.console.markTimeline(c)),k.msWriteProfilerMark&&k.msWriteProfilerMark(c),c=this;c;){var d=c,e=a;if(d.nd)for(var f=0;b=d.nd[f];f++)b(e);c=c.getParent()}}; -var Kd={},Ld=null,Md=function(a){Ld||(Ld=new Ed(""),Kd[""]=Ld,Ld.Kd(Hd));var b;if(!(b=Kd[a])){b=new Ed(a);var c=a.lastIndexOf("."),d=a.substr(c+1),c=Md(a.substr(0,c));c.kd()[d]=b;b.m=c;Kd[a]=b}return b};var Nd=function(a,b){a&&a.log(Id,b,void 0)};var Od=function(a,b,c){if(r(a))c&&(a=u(a,c));else if(a&&"function"==typeof a.handleEvent)a=u(a.handleEvent,a);else throw Error("Invalid listener argument");return 2147483647=Jd(this).value)for(r(b)&&(b=b()),a=new Cd(a,String(b),this.ne),c&&(a.ed=c),c="log:"+a.me,k.console&&(k.console.timeStamp?k.console.timeStamp(c):k.console.markTimeline&&k.console.markTimeline(c)),k.msWriteProfilerMark&&k.msWriteProfilerMark(c),c=this;c;){var d=c,e=a;if(d.od)for(var f=0;b=d.od[f];f++)b(e);c=c.getParent()}}; +var Kd={},Ld=null,Md=function(a){Ld||(Ld=new Ed(""),Kd[""]=Ld,Ld.Kd(Hd));var b;if(!(b=Kd[a])){b=new Ed(a);var c=a.lastIndexOf("."),d=a.substr(c+1),c=Md(a.substr(0,c));c.ld()[d]=b;b.m=c;Kd[a]=b}return b};var Nd=function(a,b){a&&a.log(Id,b,void 0)};var Od=function(a,b,c){if(r(a))c&&(a=u(a,c));else if(a&&"function"==typeof a.handleEvent)a=u(a.handleEvent,a);else throw Error("Invalid listener argument");return 2147483647");c=c.join("")}c=a.createElement(c);d&&(p(d)?c.className=d:n(d)?c.className=d.join(" "):ne(c,d));2a.y||a.y>=d)return c.createElement("div");var e=a.x%d;0>e&&(e+=d);d=new google.maps.Point(e,a.y);a=[[a.x,a.y,b,this.na].join("-"),this.Jc.md()].join("-");var f=this.$c(d,b,c,a);f.tileSize=this.tileSize;ve(f.H,this.opacity);this.oa.set(a,f);this.ca.X(f,"status-changed",function(){"loaded"==f.getStatus()&&this.dispatchEvent(new ye(this.nc()));"failed"==f.getStatus()&&this.dispatchEvent(new ze)});this.Jc.vd(f,(new Date).getTime()/1E3);return f.H}; -h.releaseTile=function(a){var b=this.oa.get(a.id);this.oa.remove(a.id);b&&(b.abort(),Wa(b))};h.c=function(){we.j.c.call(this);this.oa.forEach(Wa);this.oa.clear();this.oa=null;Wa(this.ca);this.Jc=this.ca=null};var xe=function(a,b){return La(a.oa.s(),function(a){return a.getStatus()==b})},ye=function(){B.call(this,"tile-load")};x(ye,B);var ze=function(){B.call(this,"tile-fail")};x(ze,B); -var Ae=function(a,b,c,d){D.call(this);this.Ca=a;this.zoom=b;this.H=c.createElement("div");this.H.id=d;this.ke=1;this.Gb=function(){};this.Gc="new";this.Gd=0;this.uc=!1};x(Ae,D); -var Ce=function(a){if(!a.uc&&"loading"==a.getStatus())throw Error("startLoad() can only be invoked once. Use retryLoad() after the first attempt.");Be(a,"loading");a.Z=new E;a.Z.Ma="blob";a.Z.X("complete",function(){var a=ie(this.Z);if(200<=this.Z.getStatus()&&300>this.Z.getStatus())this.ue=je(this.Z),this.Ld=a,this.Ta();else if(a){var c=new dd;c.X("loadend",function(){this.eb(c.K.result)},void 0,this);c.readAsText(a)}else this.eb("Failed to load tile.")},!1,a);a.Z.bb("ready",ja(Wa,a.Z));a.Z.send(a.Lb, -"GET")};h=Ae.prototype;h.Ta=function(){this.Gb(this);Be(this,"loaded")};h.Ra=function(){Wa(this.Z)};h.eb=function(){this.Gd>=this.ke?Be(this,"failed"):(this.Gd++,this.uc=!0,this.Ra(),Ce(this),this.uc=!1)};h.abort=function(){this.Ra();Be(this,"aborted")};h.getStatus=function(){return this.Gc};var Be=function(a,b){a.Gc=b;a.dispatchEvent("status-changed")},De={aborted:!0,failed:!0,loaded:!0};Ae.prototype.c=function(){Ae.j.c.call(this);this.Ra();this.H.remove();this.Gb=null};var Ee=function(){A.call(this)};x(Ee,A);var Fe=function(a,b){we.call(this,a,b);this.Vc=new td;this.cd=new td};x(Fe,we);v("ee.layers.BinaryOverlay",Fe);Fe.prototype.$c=function(a,b,c,d){var e=new Ge(a,b,c,d);this.ca.X(e,"status-changed",function(){"loaded"==e.getStatus()&&(this.Vc.set(a,new Float32Array(e.Td)),this.cd.set(a,e.H))});return e};Fe.prototype.c=function(){Fe.j.c.call(this);this.cd=this.Vc=null};var Ge=function(a,b,c,d){Ae.call(this,a,b,c,d)};x(Ge,Ae); -Ge.prototype.Ta=function(){var a=new dd;a.X("loadend",function(){this.Td=a.K.result;Ae.prototype.Ta.call(this)},void 0,this);a.readAsArrayBuffer(this.Ld)};var He=function(a){for(var b=arguments[0],c=1;ca.y||a.y>=d)return c.createElement("div");var e=a.x%d;0>e&&(e+=d);d=new google.maps.Point(e,a.y);a=[[a.x,a.y,b,this.na].join("-"),this.Kc.nd()].join("-");var f=this.ad(d,b,c,a);f.tileSize=this.tileSize;ve(f.H,this.opacity);this.oa.set(a,f);this.ca.X(f,"status-changed",function(){"loaded"==f.getStatus()&&this.dispatchEvent(new ye(this.nc()));"failed"==f.getStatus()&&this.dispatchEvent(new ze)});this.Kc.vd(f,(new Date).getTime()/1E3);return f.H}; +h.releaseTile=function(a){var b=this.oa.get(a.id);this.oa.remove(a.id);b&&(b.abort(),Wa(b))};h.c=function(){we.j.c.call(this);this.oa.forEach(Wa);this.oa.clear();this.oa=null;Wa(this.ca);this.Kc=this.ca=null};var xe=function(a,b){return La(a.oa.s(),function(a){return a.getStatus()==b})},ye=function(){B.call(this,"tile-load")};x(ye,B);var ze=function(){B.call(this,"tile-fail")};x(ze,B); +var Ae=function(a,b,c,d){D.call(this);this.Ca=a;this.zoom=b;this.H=c.createElement("div");this.H.id=d;this.ke=1;this.Gb=function(){};this.Hc="new";this.Gd=0;this.vc=!1};x(Ae,D); +var Ce=function(a){if(!a.vc&&"loading"==a.getStatus())throw Error("startLoad() can only be invoked once. Use retryLoad() after the first attempt.");Be(a,"loading");a.Z=new E;a.Z.Ma="blob";a.Z.X("complete",function(){var a=ie(this.Z);if(200<=this.Z.getStatus()&&300>this.Z.getStatus())this.ue=je(this.Z),this.Ld=a,this.Ta();else if(a){var c=new dd;c.X("loadend",function(){this.eb(c.K.result)},void 0,this);c.readAsText(a)}else this.eb("Failed to load tile.")},!1,a);a.Z.bb("ready",ja(Wa,a.Z));a.Z.send(a.Lb, +"GET")};h=Ae.prototype;h.Ta=function(){this.Gb(this);Be(this,"loaded")};h.Ra=function(){Wa(this.Z)};h.eb=function(){this.Gd>=this.ke?Be(this,"failed"):(this.Gd++,this.vc=!0,this.Ra(),Ce(this),this.vc=!1)};h.abort=function(){this.Ra();Be(this,"aborted")};h.getStatus=function(){return this.Hc};var Be=function(a,b){a.Hc=b;a.dispatchEvent("status-changed")},De={aborted:!0,failed:!0,loaded:!0};Ae.prototype.c=function(){Ae.j.c.call(this);this.Ra();this.H.remove();this.Gb=null};var Ee=function(){A.call(this)};x(Ee,A);var Fe=function(a,b){we.call(this,a,b);this.Wc=new td;this.dd=new td};x(Fe,we);v("ee.layers.BinaryOverlay",Fe);Fe.prototype.ad=function(a,b,c,d){var e=new Ge(a,b,c,d);this.ca.X(e,"status-changed",function(){"loaded"==e.getStatus()&&(this.Wc.set(a,new Float32Array(e.Td)),this.dd.set(a,e.H))});return e};Fe.prototype.c=function(){Fe.j.c.call(this);this.dd=this.Wc=null};var Ge=function(a,b,c,d){Ae.call(this,a,b,c,d)};x(Ge,Ae); +Ge.prototype.Ta=function(){var a=new dd;a.X("loadend",function(){this.Td=a.K.result;Ae.prototype.Ta.call(this)},void 0,this);a.readAsArrayBuffer(this.Ld)};var He=function(a){for(var b=arguments[0],c=1;cb)throw Error("Bad port number "+b);a.Ia=b}else a.Ia=null}; -Se.prototype.getPath=function(){return this.ea};Se.prototype.setPath=function(a,b){Ue(this);this.ea=b?Xe(a,!0):a;return this};var We=function(a,b,c){Ue(a);b instanceof Ye?(a.Y=b,a.Y.Ec(a.M)):(c||(b=Ze(b,df)),a.Y=new Ye(b,0,a.M))},Ue=function(a){if(a.ge)throw Error("Tried to modify a read-only Uri");};Se.prototype.Ec=function(a){this.M=a;this.Y&&this.Y.Ec(a);return this}; +Se.prototype.getPath=function(){return this.ea};Se.prototype.setPath=function(a,b){Ue(this);this.ea=b?Xe(a,!0):a;return this};var We=function(a,b,c){Ue(a);b instanceof Ye?(a.Y=b,a.Y.Fc(a.M)):(c||(b=Ze(b,df)),a.Y=new Ye(b,0,a.M))},Ue=function(a){if(a.ge)throw Error("Tried to modify a read-only Uri");};Se.prototype.Fc=function(a){this.M=a;this.Y&&this.Y.Fc(a);return this}; var ef=function(a){return a instanceof Se?a.clone():new Se(a,void 0)},Xe=function(a,b){return a?b?decodeURI(a.replace(/%25/g,"%2525")):decodeURIComponent(a):""},Ze=function(a,b,c){return p(a)?(a=encodeURI(a).replace(b,ff),c&&(a=a.replace(/%25([0-9a-fA-F]{2})/g,"%$1")),a):null},ff=function(a){a=a.charCodeAt(0);return"%"+(a>>4&15).toString(16)+(a&15).toString(16)},$e=/[#\/\?@]/g,bf=/[\#\?:]/g,af=/[\#\?]/g,df=/[\#\?@]/g,cf=/#/g,Ye=function(a,b,c){this.h=this.l=null;this.I=a||null;this.M=!!c},gf=function(a){a.l|| (a.l=new td,a.h=0,a.I&&Qd(a.I,function(b,c){a.add(decodeURIComponent(b.replace(/\+/g," ")),c)}))};h=Ye.prototype;h.B=function(){gf(this);return this.h};h.add=function(a,b){gf(this);this.I=null;a=hf(this,a);var c=this.l.get(a);c||this.l.set(a,c=[]);c.push(b);this.h=Aa(this.h)+1;return this};h.remove=function(a){gf(this);a=hf(this,a);return this.l.ha(a)?(this.I=null,this.h=Aa(this.h)-this.l.get(a).length,this.l.remove(a)):!1};h.clear=function(){this.l=this.I=null;this.h=0}; h.isEmpty=function(){gf(this);return 0==this.h};h.ha=function(a){gf(this);a=hf(this,a);return this.l.ha(a)};h.P=function(){gf(this);for(var a=this.l.s(),b=this.l.P(),c=[],d=0;db&&(b+=e);return[Bf,"map",a.mapid,d,b,c].join("/")+"?token="+a.token};v("ee.data.getTileUrl",Lf); @@ -112,19 +112,19 @@ v("ee.data.createAssetHome",function(a,b){a=G({id:a});F("/createbucket",a,b)});v v("ee.data.deleteAsset",function(a,b){F("/delete",G({id:a}),b)});v("ee.data.getAssetAcl",function(a,b){return F("/getacl",G({id:a}),b,"GET")});v("ee.data.setAssetAcl",function(a,b,c){a={id:a,value:id(b)};F("/setacl",G(a),c)});v("ee.data.setAssetProperties",function(a,b,c){a={id:a,properties:id(b)};F("/setproperties",G(a),c)});v("ee.data.getAssetRootQuota",function(a,b){return F("/quota",G({id:a}),b,"GET")}); var Wf={Ae:"CANCEL",De:"UPDATE"},F=function(a,b,c,d){Df();var e=Tf,f={"Content-Type":"application/x-www-form-urlencoded"},g=wf();if(null!=g)f.Authorization=g;else if(c&&sf&&jf)return nf(function(){Uf(e,function(){F(a,b,c,d)})}),null;g=d||"POST";b=b?b.clone():new Ye;e&&b.add("profiling","1");b=Gf(b,a);null!=Cf&&(f["X-XSRF-Token"]=Cf);var l=function(a,b,c,d){var f=b("X-Earth-Engine-Computation-Profile");f&&e&&e(f);var g,l,w;b=(b=b("Content-Type"))?b.replace(/;.*/,""):"application/json";if("application/json"== b||"text/json"==b)try{g=gd(c),l=g.data}catch(Ri){w="Invalid JSON: "+c}else w="Response was unexpectedly not JSON, but "+b;if(t(g))"error"in g&&"message"in g.error?w=g.error.message:"data"in g||(w="Malformed response: "+c);else if(0===a)w="Failed to contact Earth Engine servers. Please check your connection, firewall, or browser extension settings.";else if(200>a||300<=a)w="Server returned HTTP code: "+a;if(d)return d(l,w),null;if(!w)return l;throw Error(w);},w=b?b.toString():"";"GET"!=g||/^[\s\xa0]*$/.test(w)|| -(a+=-1!=a.indexOf("?")?"&":"?",a+=w,w=null);var Z=zf+a;if(c)return Zf.push({url:Z,bc:function(a){a=a.target;var b=a.getStatus(),d=u(a.getResponseHeader,a),e;try{e=a.a?a.a.responseText:""}catch(Ai){Nd(a.G,"Can not get responseText: "+Ai.message),e=""}return l(b,d,e,c)},method:g,content:w,headers:f}),$f.gd(),null;var fb=Ud();fb.open(g,Z,!1);Xa(f,function(a,b){fb.setRequestHeader(b,a)});fb.send(w);return l(fb.status,function(a){try{return fb.getResponseHeader(a)}catch(Qi){return null}},fb.responseText, +(a+=-1!=a.indexOf("?")?"&":"?",a+=w,w=null);var Z=zf+a;if(c)return Zf.push({url:Z,bc:function(a){a=a.target;var b=a.getStatus(),d=u(a.getResponseHeader,a),e;try{e=a.a?a.a.responseText:""}catch(Ai){Nd(a.G,"Can not get responseText: "+Ai.message),e=""}return l(b,d,e,c)},method:g,content:w,headers:f}),$f.hd(),null;var fb=Ud();fb.open(g,Z,!1);Xa(f,function(a,b){fb.setRequestHeader(b,a)});fb.send(w);return l(fb.status,function(a){try{return fb.getResponseHeader(a)}catch(Qi){return null}},fb.responseText, null)},mf=function(a){var b=function(){k.gapi.config.update("client/cors",!0);sf||(sf=k.gapi.auth.authorize);a()};if(t(k.gapi)&&t(k.gapi.auth)&&r(k.gapi.auth.authorize))b();else{for(var c=ka().toString(36);c in k;)c+="_";k[c]=function(){delete k[c];b()};Ne("https://apis.google.com/js/client.js?onload="+c)}},qf=function(a,b,c){c.access_token?(b=c.token_type+" "+c.access_token,isFinite(c.expires_in)&&(c=900*c.expires_in,setTimeout(nf,.9*c),uf=ka()+c),lf=b,a&&a()):b&&b(c.error||"Unknown error.")},G= -function(a){var b=new Ye,c;for(c in a)b.set(c,a[c]);return b},Zf=[],$f=new Ke(function(){var a=Zf.shift();if(a){var b=a.url,c=a.bc,d=a.method,e=a.content,a=a.headers,f=Ef,g=new E;$d.push(g);c&&g.X("complete",c);g.bb("ready",g.Wd);f&&(g.Oa=Math.max(0,f));g.send(b,d,e,a)}0==Zf.length||$f.gd()},350),zf=null,Bf=null,Cf=null,Gf=kc,lf=null,uf=null,jf=null,kf=[],sf=null,Af=!1,Ef=0,Tf=null;var ag=function(){this.O=[];this.S=[]};h=ag.prototype;h.enqueue=function(a){this.S.push(a)};h.Sa=function(){0==this.O.length&&(this.O=this.S,this.O.reverse(),this.S=[]);return this.O.pop()};h.B=function(){return this.O.length+this.S.length};h.isEmpty=function(){return 0==this.O.length&&0==this.S.length};h.clear=function(){this.O=[];this.S=[]};h.contains=function(a){return 0<=Ea(this.O,a)||0<=Ea(this.S,a)}; -h.remove=function(a){var b;b=this.O;var c=Fa(b,a);0<=c?(Pa(b,c),b=!0):b=!1;return b||Qa(this.S,a)};h.s=function(){for(var a=[],b=this.O.length-1;0<=b;--b)a.push(this.O[b]);for(var c=this.S.length,b=0;bthis.Bb)throw Error("[goog.structs.Pool] Min can not be greater than max");this.V=new ag;this.ka=new yd;this.fc=0;this.vc=null;this.kb()};x(bg,A);bg.prototype.Va=function(){var a=ka();if(!(null!=this.vc&&a-this.vcthis.Bb&&0=this.B()){for(var c=this.R,d=0;d>1,a[d].getKey()>c.getKey())a[b]=a[d],b=d;else break;a[b]=c};h=eg.prototype; -h.remove=function(){var a=this.R,b=a.length,c=a[0];if(!(0>=b)){if(1==b)Oa(a);else{a[0]=a.pop();for(var a=0,b=this.R,d=b.length,e=b[a];a>1;){var f=2*a+1,g=2*a+2,f=ge.getKey())break;b[a]=b[f];a=f}b[a]=e}return c.Pc}};h.s=function(){for(var a=this.R,b=[],c=a.length,d=0;de&&(e+=d);return[a.je,c,e,b.y].join("/")};tg.prototype.nc=function(){return this.pa.length};var vg=function(a){B.call(this,"tileevent");this.count=a};x(vg,B);var wg=function(){};var xg=function(){this.ga=-1};var yg=function(){this.ga=64;this.A=Array(4);this.Rd=Array(this.ga);this.Pb=this.Qa=0;this.reset()};x(yg,xg);yg.prototype.reset=function(){this.A[0]=1732584193;this.A[1]=4023233417;this.A[2]=2562383102;this.A[3]=271733878;this.Pb=this.Qa=0}; +function(a){var b=new Ye,c;for(c in a)b.set(c,a[c]);return b},Zf=[],$f=new Ke(function(){var a=Zf.shift();if(a){var b=a.url,c=a.bc,d=a.method,e=a.content,a=a.headers,f=Ef,g=new E;$d.push(g);c&&g.X("complete",c);g.bb("ready",g.Wd);f&&(g.Oa=Math.max(0,f));g.send(b,d,e,a)}0==Zf.length||$f.hd()},350),zf=null,Bf=null,Cf=null,Gf=kc,lf=null,uf=null,jf=null,kf=[],sf=null,Af=!1,Ef=0,Tf=null;var ag=function(){this.O=[];this.S=[]};h=ag.prototype;h.enqueue=function(a){this.S.push(a)};h.Sa=function(){0==this.O.length&&(this.O=this.S,this.O.reverse(),this.S=[]);return this.O.pop()};h.B=function(){return this.O.length+this.S.length};h.isEmpty=function(){return 0==this.O.length&&0==this.S.length};h.clear=function(){this.O=[];this.S=[]};h.contains=function(a){return 0<=Ea(this.O,a)||0<=Ea(this.S,a)}; +h.remove=function(a){var b;b=this.O;var c=Fa(b,a);0<=c?(Pa(b,c),b=!0):b=!1;return b||Qa(this.S,a)};h.s=function(){for(var a=[],b=this.O.length-1;0<=b;--b)a.push(this.O[b]);for(var c=this.S.length,b=0;bthis.Bb)throw Error("[goog.structs.Pool] Min can not be greater than max");this.V=new ag;this.ka=new yd;this.fc=0;this.wc=null;this.kb()};x(bg,A);bg.prototype.Va=function(){var a=ka();if(!(null!=this.wc&&a-this.wcthis.Bb&&0=this.B()){for(var c=this.R,d=0;d>1,a[d].getKey()>c.getKey())a[b]=a[d],b=d;else break;a[b]=c};h=eg.prototype; +h.remove=function(){var a=this.R,b=a.length,c=a[0];if(!(0>=b)){if(1==b)Oa(a);else{a[0]=a.pop();for(var a=0,b=this.R,d=b.length,e=b[a];a>1;){var f=2*a+1,g=2*a+2,f=ge.getKey())break;b[a]=b[f];a=f}b[a]=e}return c.Qc}};h.s=function(){for(var a=this.R,b=[],c=a.length,d=0;de&&(e+=d);return[a.je,c,e,b.y].join("/")};tg.prototype.nc=function(){return this.pa.length};var vg=function(a){B.call(this,"tileevent");this.count=a};x(vg,B);var wg=function(){};var xg=function(){this.ga=-1};var yg=function(){this.ga=64;this.A=Array(4);this.Rd=Array(this.ga);this.Pb=this.Qa=0;this.reset()};x(yg,xg);yg.prototype.reset=function(){this.A[0]=1732584193;this.A[1]=4023233417;this.A[2]=2562383102;this.A[3]=271733878;this.Pb=this.Qa=0}; var zg=function(a,b,c){c||(c=0);var d=Array(16);if(p(b))for(var e=0;16>e;++e)d[e]=b.charCodeAt(c++)|b.charCodeAt(c++)<<8|b.charCodeAt(c++)<<16|b.charCodeAt(c++)<<24;else for(e=0;16>e;++e)d[e]=b[c++]|b[c++]<<8|b[c++]<<16|b[c++]<<24;b=a.A[0];c=a.A[1];var e=a.A[2],f=a.A[3],g;g=b+(f^c&(e^f))+d[0]+3614090360&4294967295;b=c+(g<<7&4294967295|g>>>25);g=f+(e^b&(c^e))+d[1]+3905402710&4294967295;f=b+(g<<12&4294967295|g>>>20);g=e+(c^f&(b^c))+d[2]+606105819&4294967295;e=f+(g<<17&4294967295|g>>>15);g=c+(b^e&(f^ b))+d[3]+3250441966&4294967295;c=e+(g<<22&4294967295|g>>>10);g=b+(f^c&(e^f))+d[4]+4118548399&4294967295;b=c+(g<<7&4294967295|g>>>25);g=f+(e^b&(c^e))+d[5]+1200080426&4294967295;f=b+(g<<12&4294967295|g>>>20);g=e+(c^f&(b^c))+d[6]+2821735955&4294967295;e=f+(g<<17&4294967295|g>>>15);g=c+(b^e&(f^b))+d[7]+4249261313&4294967295;c=e+(g<<22&4294967295|g>>>10);g=b+(f^c&(e^f))+d[8]+1770035416&4294967295;b=c+(g<<7&4294967295|g>>>25);g=f+(e^b&(c^e))+d[9]+2336552879&4294967295;f=b+(g<<12&4294967295|g>>>20);g=e+ (c^f&(b^c))+d[10]+4294925233&4294967295;e=f+(g<<17&4294967295|g>>>15);g=c+(b^e&(f^b))+d[11]+2304563134&4294967295;c=e+(g<<22&4294967295|g>>>10);g=b+(f^c&(e^f))+d[12]+1804603682&4294967295;b=c+(g<<7&4294967295|g>>>25);g=f+(e^b&(c^e))+d[13]+4254626195&4294967295;f=b+(g<<12&4294967295|g>>>20);g=e+(c^f&(b^c))+d[14]+2792965006&4294967295;e=f+(g<<17&4294967295|g>>>15);g=c+(b^e&(f^b))+d[15]+1236535329&4294967295;c=e+(g<<22&4294967295|g>>>10);g=b+(e^f&(c^e))+d[1]+4129170786&4294967295;b=c+(g<<5&4294967295| @@ -136,12 +136,12 @@ f=b+(g<<11&4294967295|g>>>21);g=e+(f^b^c)+d[15]+530742520&4294967295;e=f+(g<<16& (g<<6&4294967295|g>>>26);g=f+(c^(b|~e))+d[3]+2399980690&4294967295;f=b+(g<<10&4294967295|g>>>22);g=e+(b^(f|~c))+d[10]+4293915773&4294967295;e=f+(g<<15&4294967295|g>>>17);g=c+(f^(e|~b))+d[1]+2240044497&4294967295;c=e+(g<<21&4294967295|g>>>11);g=b+(e^(c|~f))+d[8]+1873313359&4294967295;b=c+(g<<6&4294967295|g>>>26);g=f+(c^(b|~e))+d[15]+4264355552&4294967295;f=b+(g<<10&4294967295|g>>>22);g=e+(b^(f|~c))+d[6]+2734768916&4294967295;e=f+(g<<15&4294967295|g>>>17);g=c+(f^(e|~b))+d[13]+1309151649&4294967295; c=e+(g<<21&4294967295|g>>>11);g=b+(e^(c|~f))+d[4]+4149444226&4294967295;b=c+(g<<6&4294967295|g>>>26);g=f+(c^(b|~e))+d[11]+3174756917&4294967295;f=b+(g<<10&4294967295|g>>>22);g=e+(b^(f|~c))+d[2]+718787259&4294967295;e=f+(g<<15&4294967295|g>>>17);g=c+(f^(e|~b))+d[9]+3951481745&4294967295;a.A[0]=a.A[0]+b&4294967295;a.A[1]=a.A[1]+(e+(g<<21&4294967295|g>>>11))&4294967295;a.A[2]=a.A[2]+e&4294967295;a.A[3]=a.A[3]+f&4294967295}; yg.prototype.update=function(a,b){m(b)||(b=a.length);for(var c=b-this.ga,d=this.Rd,e=this.Qa,f=0;fthis.Qa?this.ga:2*this.ga)-this.Qa);a[0]=128;for(var b=1;bb;++b)for(var d=0;32>d;d+=8)a[c++]=this.A[b]>>>d&255;return a};var Ag=function(a){this.jb="__ee_hash__";this.tc=!1!==a;this.Na=[];this.Ea={};this.Qc=[]};v("ee.Serializer",Ag);var Bg=new hd,Cg=new yg,Eg=function(a,b){return Dg(new Ag(m(b)?b:!0),a)};v("ee.Serializer.encode",Eg);var Fg=function(a){return Bg.v(Eg(a))};v("ee.Serializer.toJSON",Fg);var Gg=function(a){a=Dg(new Ag(!1),a);return"JSON"in k?k.JSON.stringify(a,null," "):Bg.v(a)};v("ee.Serializer.toReadableJSON",Gg); -var Dg=function(a,b){b=a.pb(b);a.tc&&(b=t(b)&&"ValueRef"==b.type&&1==a.Na.length?a.Na[0][1]:{type:"CompoundValue",scope:a.Na,value:b},a.Na=[],Ga(a.Qc,u(function(a){delete a[this.jb]},a)),a.Qc=[],a.Ea={});return b}; -Ag.prototype.pb=function(a){if(!m(a))throw Error("Can't encode an undefined value.");var b,c=t(a)?a[this.jb]:null;if(this.tc&&null!=c&&this.Ea[c])return{type:"ValueRef",value:this.Ea[c]};if(null===a||"boolean"==typeof a||q(a)||p(a))return a;if(t(a)&&"function"==typeof a.getFullYear)return{type:"Invocation",functionName:"Date",arguments:{value:Math.floor(a.getTime())}};if(a instanceof wg){if(b=a.encode(u(this.pb,this)),!(n(b)||t(b)&&"ArgumentRef"!=b.type))return b}else if(n(a))b=Ia(a,function(a){return this.pb(a)}, -this);else if(t(a)&&!r(a))b=Za(a,function(a){if(!r(a))return this.pb(a)},this),eb(b,this.jb),b={type:"Dictionary",value:b};else throw Error("Can't encode object: "+a);if(this.tc){Cg.reset();Cg.update(Bg.v(b));var c=Cg.digest().toString(),d;this.Ea[c]?d=this.Ea[c]:(d=String(this.Na.length),this.Na.push([d,b]),this.Ea[c]=d);a[this.jb]=c;this.Qc.push(a);return{type:"ValueRef",value:d}}return b};var H=function(a,b,c){if(!(this instanceof H))return I(H,arguments);if(c&&(a||b))throw Error('When "opt_varName" is specified, "func" and "args" must be null.');if(a&&!b)throw Error('When "func" is specified, "args" must not be null.');this.f=a;this.o=b;this.w=c||null};x(H,wg);v("ee.ComputedObject",H);H.prototype.evaluate=function(a){if(!a||!r(a))throw Error("evaluate() requires a callback function.");Mf({json:this.v()},a)};H.prototype.evaluate=H.prototype.evaluate; +yg.prototype.digest=function(){var a=Array((56>this.Qa?this.ga:2*this.ga)-this.Qa);a[0]=128;for(var b=1;bb;++b)for(var d=0;32>d;d+=8)a[c++]=this.A[b]>>>d&255;return a};var Ag=function(a){this.jb="__ee_hash__";this.uc=!1!==a;this.Na=[];this.Ea={};this.Rc=[]};v("ee.Serializer",Ag);var Bg=new hd,Cg=new yg,Eg=function(a,b){return Dg(new Ag(m(b)?b:!0),a)};v("ee.Serializer.encode",Eg);var Fg=function(a){return Bg.v(Eg(a))};v("ee.Serializer.toJSON",Fg);var Gg=function(a){a=Dg(new Ag(!1),a);return"JSON"in k?k.JSON.stringify(a,null," "):Bg.v(a)};v("ee.Serializer.toReadableJSON",Gg); +var Dg=function(a,b){b=a.pb(b);a.uc&&(b=t(b)&&"ValueRef"==b.type&&1==a.Na.length?a.Na[0][1]:{type:"CompoundValue",scope:a.Na,value:b},a.Na=[],Ga(a.Rc,u(function(a){delete a[this.jb]},a)),a.Rc=[],a.Ea={});return b}; +Ag.prototype.pb=function(a){if(!m(a))throw Error("Can't encode an undefined value.");var b,c=t(a)?a[this.jb]:null;if(this.uc&&null!=c&&this.Ea[c])return{type:"ValueRef",value:this.Ea[c]};if(null===a||"boolean"==typeof a||q(a)||p(a))return a;if(t(a)&&"function"==typeof a.getFullYear)return{type:"Invocation",functionName:"Date",arguments:{value:Math.floor(a.getTime())}};if(a instanceof wg){if(b=a.encode(u(this.pb,this)),!(n(b)||t(b)&&"ArgumentRef"!=b.type))return b}else if(n(a))b=Ia(a,function(a){return this.pb(a)}, +this);else if(t(a)&&!r(a))b=Za(a,function(a){if(!r(a))return this.pb(a)},this),eb(b,this.jb),b={type:"Dictionary",value:b};else throw Error("Can't encode object: "+a);if(this.uc){Cg.reset();Cg.update(Bg.v(b));var c=Cg.digest().toString(),d;this.Ea[c]?d=this.Ea[c]:(d=String(this.Na.length),this.Na.push([d,b]),this.Ea[c]=d);a[this.jb]=c;this.Rc.push(a);return{type:"ValueRef",value:d}}return b};var H=function(a,b,c){if(!(this instanceof H))return I(H,arguments);if(c&&(a||b))throw Error('When "opt_varName" is specified, "func" and "args" must be null.');if(a&&!b)throw Error('When "func" is specified, "args" must not be null.');this.f=a;this.o=b;this.w=c||null};x(H,wg);v("ee.ComputedObject",H);H.prototype.evaluate=function(a){if(!a||!r(a))throw Error("evaluate() requires a callback function.");Mf({json:this.v()},a)};H.prototype.evaluate=H.prototype.evaluate; H.prototype.W=function(a){return Mf({json:this.v()},a)};H.prototype.getInfo=H.prototype.W;H.prototype.encode=function(a){if(null===this.f&&null===this.o)return{type:"ArgumentRef",value:this.w};var b={},c;for(c in this.o)m(this.o[c])&&(b[c]=a(this.o[c]));b={type:"Invocation",arguments:b};a=a(this.f);b[p(a)?"functionName":"function"]=a;return b};H.prototype.v=function(){return Fg(this)};H.prototype.serialize=H.prototype.v;H.prototype.toString=function(){return"ee."+this.name()+"("+Gg(this)+")"}; -v("ee.ComputedObject.prototype.toString",H.prototype.toString);H.prototype.name=function(){return"ComputedObject"};H.prototype.Rc=function(a,b){var c=Sa(arguments);c[0]=this;a.apply(k,c);return this};H.prototype.aside=H.prototype.Rc;var Hg=function(a,b){if(b instanceof a.constructor)return b;var c=function(){};c.prototype=a.constructor.prototype;a=new c;a.f=b.f;a.o=b.o;a.w=b.w;return a},I=function(a,b){function c(){return a.apply(this,b)}c.prototype=a.prototype;return new c};var Ig={},Jg=function(a){return a.prototype instanceof H?a.prototype.name.call(null):a==Number?"Number":a==String?"String":a==Array?"Array":a==Date?"Date":"Object"},Kg=function(a,b){if(b==a)return!0;switch(a){case "Element":return"Element"==b||"Image"==b||"Feature"==b||"Collection"==b||"ImageCollection"==b||"FeatureCollection"==b;case "FeatureCollection":case "Collection":return"Collection"==b||"ImageCollection"==b||"FeatureCollection"==b;case "Object":return!0;default:return!1}},Lg=function(a){return q(a)|| +v("ee.ComputedObject.prototype.toString",H.prototype.toString);H.prototype.name=function(){return"ComputedObject"};H.prototype.Sc=function(a,b){var c=Sa(arguments);c[0]=this;a.apply(k,c);return this};H.prototype.aside=H.prototype.Sc;var Hg=function(a,b){if(b instanceof a.constructor)return b;var c=function(){};c.prototype=a.constructor.prototype;a=new c;a.f=b.f;a.o=b.o;a.w=b.w;return a},I=function(a,b){function c(){return a.apply(this,b)}c.prototype=a.prototype;return new c};var Ig={},Jg=function(a){return a.prototype instanceof H?a.prototype.name.call(null):a==Number?"Number":a==String?"String":a==Array?"Array":a==Date?"Date":"Object"},Kg=function(a,b){if(b==a)return!0;switch(a){case "Element":return"Element"==b||"Image"==b||"Feature"==b||"Collection"==b||"ImageCollection"==b||"FeatureCollection"==b;case "FeatureCollection":case "Collection":return"Collection"==b||"ImageCollection"==b||"FeatureCollection"==b;case "Object":return!0;default:return!1}},Lg=function(a){return q(a)|| a instanceof H&&"Number"==a.name()},Mg=function(a){return p(a)||a instanceof H&&"String"==a.name()},Ng=function(a){return t(a)&&!r(a)?(a=Object.getPrototypeOf(a),null!==a&&null===Object.getPrototypeOf(a)):!1};var J=function(){if(!(this instanceof J))return new J};x(J,wg);v("ee.Function",J);var Og=kc;J.prototype.call=function(a){return this.apply(Pg(this,Array.prototype.slice.call(arguments,0)))};J.prototype.call=J.prototype.call;J.prototype.apply=function(a){a=new H(this,Qg(this,a));return Og(a,this.F().returns)};J.prototype.apply=J.prototype.apply; var Rg=function(a,b,c){var d=m(b),e=a.F(),f=!1;if(1==c.length&&Ng(c[0])){var g=e.args;d&&(g=g.slice(1));g.length&&(f=!((1==g.length||g[1].optional)&&"Dictionary"==g[0].type))}if(f){if(c=gb(c[0]),d){d=e.args[0].name;if(d in c)throw Error("Named args for "+e.name+" can't contain keyword "+d);c[d]=b}}else c=Pg(a,d?[b].concat(c):c);return a.apply(c)},Qg=function(a,b){for(var c=a.F().args,d={},e={},f=0;fc||4c||4a.le)return!1;a.Sc++;og(a.C,a.da);setTimeout(u(a.ve,a),0);return!0}; +var Ki=function(a,b,c,d,e){A.call(this);this.da=a;this.Pc=b;this.le=m(e)?e:1;this.qc=c;this.wa=d};x(Ki,A);h=Ki.prototype;h.Tc=0;h.Aa=!1;h.C=null;h.gb=null;h.ia=null;h.Dd=null;var Ni=["load","abort","error"];Ki.prototype.getId=function(){return this.da};Ki.prototype.getUrl=function(){return this.Pc};Ki.prototype.ce=function(a){if(this.Aa)this.wa&&this.wa(this);else switch(a.type){case "load":this.ia=a;this.wa&&this.wa(this);break;case "error":case "abort":Mi(this)||(this.ia=a,this.wa&&this.wa(this))}}; +Ki.prototype.c=function(){Ki.j.c.call(this);delete this.qc;delete this.wa};var Mi=function(a){if(a.Tc>a.le)return!1;a.Tc++;og(a.C,a.da);setTimeout(u(a.ve,a),0);return!0}; Ki.prototype.ve=function(){if(!this.Aa){var a=u(function(a){this.Aa||(ng(this.C,this.da,a),Zb(this.C,Ni,u(this.ce,this)),this.C.start())},this),b=this.getUrl();if(ef(b).Y.ha("profiling")){var c=new E;c.Ma="blob";c.X("complete",u(function(){this.Dd=c.getResponseHeader("X-Earth-Engine-Computation-Profile")||null;var d;if(200<=c.getStatus()&&300>c.getStatus())try{d=URL.createObjectURL(ie(c))}catch(e){}a(d||b)},this));c.bb("ready",u(c.T,c));c.send(b,"GET")}else a(b)}};var Oi=function(){this.N=!1}; -x(Oi,A);Oi.prototype.setActive=function(a){this.N=a};Oi.prototype.rd=function(){return this.N};var Ji=function(a,b){hg.call(this,a,b)};x(Ji,hg);Ji.prototype.ec=function(){return new Oi};Ji.prototype.nb=function(a){a.T()};Ji.prototype.yc=function(a){return!a.aa&&!a.rd()};var Y=function(a,b,c,d,e){tg.call(this,a,b,c);this.minZoom=d.minZoom||0;this.maxZoom=d.maxZoom||20;if(!window.google||!window.google.maps)throw Error("Google Maps API hasn't been initialized.");this.tileSize=d.tileSize||new google.maps.Size(256,256);this.zb=m(d.zb)?d.zb:!0;this.name=d.name;this.Lc=new yd;this.zc=1;this.J=e||null};x(Y,tg);v("ee.MapLayerOverlay",Y);Y.prototype.Yb=function(a){return Sb(this,"tileevent",a)};Y.prototype.addTileCallback=Y.prototype.Yb;Y.prototype.Dc=function(a){ac(a)}; -Y.prototype.removeTileCallback=Y.prototype.Dc;Y.prototype.getTile=function(a,b,c){if(ba.y||a.y>=1<a.y||a.y>=1<>> 0); +goog.UID_PROPERTY_ = "closure_uid_" + (1e9 * Math.random() >>> 0); goog.uidCounter_ = 0; goog.getHashCode = goog.getUid; goog.removeHashCode = goog.removeUid; @@ -2386,7 +2389,7 @@ goog.events.BrowserEvent.prototype.getBrowserEvent = function() { }; goog.events.Listenable = function() { }; -goog.events.Listenable.IMPLEMENTED_BY_PROP = "closure_listenable_" + (1E6 * Math.random() | 0); +goog.events.Listenable.IMPLEMENTED_BY_PROP = "closure_listenable_" + (1e6 * Math.random() | 0); goog.events.Listenable.addImplementation = function(cls) { cls.prototype[goog.events.Listenable.IMPLEMENTED_BY_PROP] = !0; }; @@ -2502,7 +2505,7 @@ goog.events.ListenerMap.findListenerIndex_ = function(listenerArray, listener, o } return -1; }; -goog.events.LISTENER_MAP_PROP_ = "closure_lm_" + (1E6 * Math.random() | 0); +goog.events.LISTENER_MAP_PROP_ = "closure_lm_" + (1e6 * Math.random() | 0); goog.events.onString_ = "on"; goog.events.onStringMap_ = {}; goog.events.CaptureSimulationMode = {OFF_AND_FAIL:0, OFF_AND_SILENT:1, ON:2}; @@ -2763,7 +2766,7 @@ goog.events.getListenerMap_ = function(src) { var listenerMap = src[goog.events.LISTENER_MAP_PROP_]; return listenerMap instanceof goog.events.ListenerMap ? listenerMap : null; }; -goog.events.LISTENER_WRAPPER_PROP_ = "__closure_events_fn_" + (1E9 * Math.random() >>> 0); +goog.events.LISTENER_WRAPPER_PROP_ = "__closure_events_fn_" + (1e9 * Math.random() >>> 0); goog.events.wrapListener = function(listener) { goog.asserts.assert(listener, "Listener can not be null."); if (goog.isFunction(listener)) { @@ -2875,7 +2878,7 @@ goog.events.EventTarget = function() { }; goog.inherits(goog.events.EventTarget, goog.Disposable); goog.events.Listenable.addImplementation(goog.events.EventTarget); -goog.events.EventTarget.MAX_ANCESTORS_ = 1E3; +goog.events.EventTarget.MAX_ANCESTORS_ = 1000; goog.events.EventTarget.prototype.getParentEventTarget = function() { return this.parentEventTarget_; }; @@ -3255,30 +3258,36 @@ goog.functions.once = function(f) { }; }; goog.functions.debounce = function(f, interval, opt_scope) { - opt_scope && (f = goog.bind(f, opt_scope)); - var timeout = null; + var timeout = 0; return function(var_args) { goog.global.clearTimeout(timeout); var args = arguments; timeout = goog.global.setTimeout(function() { - f.apply(null, args); + f.apply(opt_scope, args); }, interval); }; }; goog.functions.throttle = function(f, interval, opt_scope) { - opt_scope && (f = goog.bind(f, opt_scope)); - var timeout = null, shouldFire = !1, args = [], handleTimeout = function() { - timeout = null; + var timeout = 0, shouldFire = !1, args = [], handleTimeout = function() { + timeout = 0; shouldFire && (shouldFire = !1, fire()); }, fire = function() { timeout = goog.global.setTimeout(handleTimeout, interval); - f.apply(null, args); + f.apply(opt_scope, args); }; return function(var_args) { args = arguments; timeout ? shouldFire = !0 : fire(); }; }; +goog.functions.rateLimit = function(f, interval, opt_scope) { + var timeout = 0, handleTimeout = function() { + timeout = 0; + }; + return function(var_args) { + timeout || (timeout = goog.global.setTimeout(handleTimeout, interval), f.apply(opt_scope, arguments)); + }; +}; goog.async.throwException = function(exception) { goog.global.setTimeout(function() { throw exception; @@ -3392,9 +3401,8 @@ goog.async.run = function(callback, opt_context) { goog.async.run.workQueue_.add(callback, opt_context); }; goog.async.run.initializeRunner_ = function() { - var Promise = goog.global.Promise; - if (-1 != String(Promise).indexOf("[native code]")) { - var promise = Promise.resolve(void 0); + if (-1 != String(goog.global.Promise).indexOf("[native code]")) { + var promise = goog.global.Promise.resolve(void 0); goog.async.run.schedule_ = function() { promise.then(goog.async.run.processWorkQueue); }; @@ -4351,7 +4359,7 @@ goog.i18n.bidi.normalizeHebrewQuote = function(str) { }; goog.i18n.bidi.wordSeparatorRe_ = /\s+/; goog.i18n.bidi.hasNumeralsRe_ = /[\d\u06f0-\u06f9]/; -goog.i18n.bidi.rtlDetectionThreshold_ = .4; +goog.i18n.bidi.rtlDetectionThreshold_ = 0.40; goog.i18n.bidi.estimateDirection = function(str, opt_isHtml) { for (var rtlCount = 0, totalCount = 0, hasWeaklyLtr = !1, tokens = goog.i18n.bidi.stripHtmlIfNeeded_(str, opt_isHtml).split(goog.i18n.bidi.wordSeparatorRe_), i = 0;i < tokens.length;i++) { var token = tokens[i]; @@ -4410,6 +4418,37 @@ goog.string.Const.create__googStringSecurityPrivate_ = function(s) { }; goog.string.Const.EMPTY = goog.string.Const.from(""); goog.html = {}; +goog.html.SafeScript = function() { + this.privateDoNotAccessOrElseSafeScriptWrappedValue_ = ""; + this.SAFE_SCRIPT_TYPE_MARKER_GOOG_HTML_SECURITY_PRIVATE_ = goog.html.SafeScript.TYPE_MARKER_GOOG_HTML_SECURITY_PRIVATE_; +}; +goog.html.SafeScript.prototype.implementsGoogStringTypedString = !0; +goog.html.SafeScript.TYPE_MARKER_GOOG_HTML_SECURITY_PRIVATE_ = {}; +goog.html.SafeScript.fromConstant = function(script) { + var scriptString = goog.string.Const.unwrap(script); + return 0 === scriptString.length ? goog.html.SafeScript.EMPTY : goog.html.SafeScript.createSafeScriptSecurityPrivateDoNotAccessOrElse(scriptString); +}; +goog.html.SafeScript.prototype.getTypedStringValue = function() { + return this.privateDoNotAccessOrElseSafeScriptWrappedValue_; +}; +goog.DEBUG && (goog.html.SafeScript.prototype.toString = function() { + return "SafeScript{" + this.privateDoNotAccessOrElseSafeScriptWrappedValue_ + "}"; +}); +goog.html.SafeScript.unwrap = function(safeScript) { + if (safeScript instanceof goog.html.SafeScript && safeScript.constructor === goog.html.SafeScript && safeScript.SAFE_SCRIPT_TYPE_MARKER_GOOG_HTML_SECURITY_PRIVATE_ === goog.html.SafeScript.TYPE_MARKER_GOOG_HTML_SECURITY_PRIVATE_) { + return safeScript.privateDoNotAccessOrElseSafeScriptWrappedValue_; + } + goog.asserts.fail("expected object of type SafeScript, got '" + safeScript + "' of type " + goog.typeOf(safeScript)); + return "type_error:SafeScript"; +}; +goog.html.SafeScript.createSafeScriptSecurityPrivateDoNotAccessOrElse = function(script) { + return (new goog.html.SafeScript).initSecurityPrivateDoNotAccessOrElse_(script); +}; +goog.html.SafeScript.prototype.initSecurityPrivateDoNotAccessOrElse_ = function(script) { + this.privateDoNotAccessOrElseSafeScriptWrappedValue_ = script; + return this; +}; +goog.html.SafeScript.EMPTY = goog.html.SafeScript.createSafeScriptSecurityPrivateDoNotAccessOrElse(""); goog.html.SafeStyle = function() { this.privateDoNotAccessOrElseSafeStyleWrappedValue_ = ""; this.SAFE_STYLE_TYPE_MARKER_GOOG_HTML_SECURITY_PRIVATE_ = goog.html.SafeStyle.TYPE_MARKER_GOOG_HTML_SECURITY_PRIVATE_; @@ -4637,9 +4676,7 @@ goog.html.TrustedResourceUrl.format = function(format, args) { return goog.html.TrustedResourceUrl.createTrustedResourceUrlSecurityPrivateDoNotAccessOrElse(result); }; goog.html.TrustedResourceUrl.FORMAT_MARKER_ = /%{(\w+)}/g; -goog.html.TrustedResourceUrl.SCHEME_AND_ORIGIN_ = "(?:(?:https:)?//[0-9a-z.:[\\]-]+)?"; -goog.html.TrustedResourceUrl.BASE_ABSOLUTE_PATH_ = "(?:/[0-9a-z_~-]+(?:[/#?]|$))"; -goog.html.TrustedResourceUrl.BASE_URL_ = new RegExp("^" + goog.html.TrustedResourceUrl.SCHEME_AND_ORIGIN_ + goog.html.TrustedResourceUrl.BASE_ABSOLUTE_PATH_, "i"); +goog.html.TrustedResourceUrl.BASE_URL_ = /^(?:https:)?\/\/[0-9a-z.:[\]-]+\/|^\/[^\/\\]/i; goog.html.TrustedResourceUrl.fromConstant = function(url) { return goog.html.TrustedResourceUrl.createTrustedResourceUrlSecurityPrivateDoNotAccessOrElse(goog.string.Const.unwrap(url)); }; @@ -4743,6 +4780,21 @@ goog.html.SafeHtml.createScriptSrc = function(src, opt_attributes) { var attributes = goog.html.SafeHtml.combineAttributes({src:src}, {}, opt_attributes); return goog.html.SafeHtml.createSafeHtmlTagSecurityPrivateDoNotAccessOrElse("script", attributes); }; +goog.html.SafeHtml.createScript = function(script, opt_attributes) { + for (var attr in opt_attributes) { + var attrLower = attr.toLowerCase(); + if ("language" == attrLower || "src" == attrLower || "text" == attrLower || "type" == attrLower) { + throw Error('Cannot set "' + attrLower + '" attribute'); + } + } + var content = ""; + script = goog.array.concat(script); + for (var i = 0;i < script.length;i++) { + content += goog.html.SafeScript.unwrap(script[i]); + } + var htmlContent = goog.html.SafeHtml.createSafeHtmlSecurityPrivateDoNotAccessOrElse(content, goog.i18n.bidi.Dir.NEUTRAL); + return goog.html.SafeHtml.createSafeHtmlTagSecurityPrivateDoNotAccessOrElse("script", opt_attributes, htmlContent); +}; goog.html.SafeHtml.createStyle = function(styleSheet, opt_attributes) { var attributes = goog.html.SafeHtml.combineAttributes({type:"text/css"}, {}, opt_attributes), content = ""; styleSheet = goog.array.concat(styleSheet); @@ -4878,37 +4930,6 @@ goog.html.SafeHtml.combineAttributes = function(fixedAttributes, defaultAttribut goog.html.SafeHtml.DOCTYPE_HTML = goog.html.SafeHtml.createSafeHtmlSecurityPrivateDoNotAccessOrElse("", goog.i18n.bidi.Dir.NEUTRAL); goog.html.SafeHtml.EMPTY = goog.html.SafeHtml.createSafeHtmlSecurityPrivateDoNotAccessOrElse("", goog.i18n.bidi.Dir.NEUTRAL); goog.html.SafeHtml.BR = goog.html.SafeHtml.createSafeHtmlSecurityPrivateDoNotAccessOrElse("
", goog.i18n.bidi.Dir.NEUTRAL); -goog.html.SafeScript = function() { - this.privateDoNotAccessOrElseSafeScriptWrappedValue_ = ""; - this.SAFE_SCRIPT_TYPE_MARKER_GOOG_HTML_SECURITY_PRIVATE_ = goog.html.SafeScript.TYPE_MARKER_GOOG_HTML_SECURITY_PRIVATE_; -}; -goog.html.SafeScript.prototype.implementsGoogStringTypedString = !0; -goog.html.SafeScript.TYPE_MARKER_GOOG_HTML_SECURITY_PRIVATE_ = {}; -goog.html.SafeScript.fromConstant = function(script) { - var scriptString = goog.string.Const.unwrap(script); - return 0 === scriptString.length ? goog.html.SafeScript.EMPTY : goog.html.SafeScript.createSafeScriptSecurityPrivateDoNotAccessOrElse(scriptString); -}; -goog.html.SafeScript.prototype.getTypedStringValue = function() { - return this.privateDoNotAccessOrElseSafeScriptWrappedValue_; -}; -goog.DEBUG && (goog.html.SafeScript.prototype.toString = function() { - return "SafeScript{" + this.privateDoNotAccessOrElseSafeScriptWrappedValue_ + "}"; -}); -goog.html.SafeScript.unwrap = function(safeScript) { - if (safeScript instanceof goog.html.SafeScript && safeScript.constructor === goog.html.SafeScript && safeScript.SAFE_SCRIPT_TYPE_MARKER_GOOG_HTML_SECURITY_PRIVATE_ === goog.html.SafeScript.TYPE_MARKER_GOOG_HTML_SECURITY_PRIVATE_) { - return safeScript.privateDoNotAccessOrElseSafeScriptWrappedValue_; - } - goog.asserts.fail("expected object of type SafeScript, got '" + safeScript + "' of type " + goog.typeOf(safeScript)); - return "type_error:SafeScript"; -}; -goog.html.SafeScript.createSafeScriptSecurityPrivateDoNotAccessOrElse = function(script) { - return (new goog.html.SafeScript).initSecurityPrivateDoNotAccessOrElse_(script); -}; -goog.html.SafeScript.prototype.initSecurityPrivateDoNotAccessOrElse_ = function(script) { - this.privateDoNotAccessOrElseSafeScriptWrappedValue_ = script; - return this; -}; -goog.html.SafeScript.EMPTY = goog.html.SafeScript.createSafeScriptSecurityPrivateDoNotAccessOrElse(""); goog.html.uncheckedconversions = {}; goog.html.uncheckedconversions.safeHtmlFromStringKnownToSatisfyTypeContract = function(justification, html, opt_dir) { goog.asserts.assertString(goog.string.Const.unwrap(justification), "must provide justification"); @@ -4961,7 +4982,7 @@ goog.math.lerp = function(a, b, x) { return a + x * (b - a); }; goog.math.nearlyEquals = function(a, b, opt_tolerance) { - return Math.abs(a - b) <= (opt_tolerance || 1E-6); + return Math.abs(a - b) <= (opt_tolerance || 0.000001); }; goog.math.standardAngle = function(angle) { return goog.math.modulo(angle, 360); @@ -5052,11 +5073,11 @@ goog.math.log10Floor = function(num) { }; goog.math.safeFloor = function(num, opt_epsilon) { goog.asserts.assert(!goog.isDef(opt_epsilon) || 0 < opt_epsilon); - return Math.floor(num + (opt_epsilon || 2E-15)); + return Math.floor(num + (opt_epsilon || 2e-15)); }; goog.math.safeCeil = function(num, opt_epsilon) { goog.asserts.assert(!goog.isDef(opt_epsilon) || 0 < opt_epsilon); - return Math.ceil(num - (opt_epsilon || 2E-15)); + return Math.ceil(num - (opt_epsilon || 2e-15)); }; goog.iter = {}; goog.iter.StopIteration = "StopIteration" in goog.global ? goog.global.StopIteration : {message:"StopIteration", stack:""}; @@ -6192,7 +6213,7 @@ goog.debug.Logger.Level.prototype.toString = function() { }; goog.debug.Logger.Level.OFF = new goog.debug.Logger.Level("OFF", Infinity); goog.debug.Logger.Level.SHOUT = new goog.debug.Logger.Level("SHOUT", 1200); -goog.debug.Logger.Level.SEVERE = new goog.debug.Logger.Level("SEVERE", 1E3); +goog.debug.Logger.Level.SEVERE = new goog.debug.Logger.Level("SEVERE", 1000); goog.debug.Logger.Level.WARNING = new goog.debug.Logger.Level("WARNING", 900); goog.debug.Logger.Level.INFO = new goog.debug.Logger.Level("INFO", 800); goog.debug.Logger.Level.CONFIG = new goog.debug.Logger.Level("CONFIG", 700); @@ -6415,7 +6436,7 @@ goog.Timer.MAX_TIMEOUT_ = 2147483647; goog.Timer.INVALID_TIMEOUT_ID_ = -1; goog.Timer.prototype.enabled = !1; goog.Timer.defaultTimerObject = goog.global; -goog.Timer.intervalScale = .8; +goog.Timer.intervalScale = 0.8; goog.Timer.prototype.timer_ = null; goog.Timer.prototype.getInterval = function() { return this.interval_; @@ -7317,6 +7338,10 @@ goog.dom.safe.setIframeSrc = function(iframe, url) { goog.dom.safe.assertIsHTMLIFrameElement_(iframe); iframe.src = goog.html.TrustedResourceUrl.unwrap(url); }; +goog.dom.safe.setIframeSrcdoc = function(iframe, html) { + goog.dom.safe.assertIsHTMLIFrameElement_(iframe); + iframe.srcdoc = goog.html.SafeHtml.unwrap(html); +}; goog.dom.safe.setLinkHrefAndRel = function(link, url, rel) { goog.dom.safe.assertIsHTMLLinkElement_(link); link.rel = rel; @@ -9077,7 +9102,7 @@ ee.layers.AbstractOverlay.prototype.getTile = function(coord, zoom, ownerDocumen tile.getStatus() == ee.layers.AbstractTile.Status.LOADED && this.dispatchEvent(new ee.layers.TileLoadEvent(this.getLoadingTilesCount())); tile.getStatus() == ee.layers.AbstractTile.Status.FAILED && this.dispatchEvent(new ee.layers.TileFailEvent(tile.sourceUrl, tile.errorMessage_)); }); - this.tileSource.loadTile(tile, (new Date).getTime() / 1E3); + this.tileSource.loadTile(tile, (new Date).getTime() / 1000); return tile.div; }; ee.layers.AbstractOverlay.prototype.releaseTile = function(tileDiv) { @@ -9349,7 +9374,7 @@ goog.async.Throttle.prototype.doAction_ = function() { }; goog.net.jsloader = {}; goog.net.jsloader.GLOBAL_VERIFY_OBJS_ = "closure_verification"; -goog.net.jsloader.DEFAULT_TIMEOUT = 5E3; +goog.net.jsloader.DEFAULT_TIMEOUT = 5000; goog.net.jsloader.scriptsToLoad_ = []; goog.net.jsloader.loadMany = function(uris, opt_options) { var trustedUris = goog.array.map(uris, goog.html.legacyconversions.trustedResourceUrlFromString); @@ -11968,12 +11993,16 @@ ee.Geometry.coordinatesToLine_ = function(coordinates) { }; ee.Geometry.construct_ = function(jsConstructorFn, apiConstructorName, depth, originalArgs) { var eeArgs = ee.Geometry.getEeApiArgs_(jsConstructorFn, originalArgs); - if (ee.Geometry.hasServerValue_(eeArgs.coordinates) || goog.isDefAndNotNull(eeArgs.crs) || goog.isDefAndNotNull(eeArgs.geodesic) || goog.isDefAndNotNull(eeArgs.maxError)) { + if (ee.Geometry.hasServerValue_(eeArgs.coordinates) || goog.isDefAndNotNull(eeArgs.crs) || goog.isDefAndNotNull(eeArgs.maxError)) { return (new ee.ApiFunction("GeometryConstructors." + apiConstructorName)).apply(eeArgs); } eeArgs.type = apiConstructorName; eeArgs.coordinates = ee.Geometry.fixDepth_(depth, eeArgs.coordinates); - !goog.isDefAndNotNull(eeArgs.evenOdd) && goog.array.contains(["Polygon", "Rectangle", "MultiPolygon"], apiConstructorName) && (eeArgs.evenOdd = !0); + var isPolygon = goog.array.contains(["Polygon", "Rectangle", "MultiPolygon"], apiConstructorName); + isPolygon && !goog.isDefAndNotNull(eeArgs.evenOdd) && (eeArgs.evenOdd = !0); + if (isPolygon && !1 === eeArgs.geodesic && !1 === eeArgs.evenOdd) { + throw Error("Planar interiors must be even/odd."); + } return eeArgs; }; ee.Geometry.getEeApiArgs_ = function(jsConstructorFn, originalArgs) { @@ -12069,7 +12098,7 @@ ee.Deserializer.decodeValue_ = function(json, namedValues) { if (!goog.isNumber(microseconds)) { throw Error("Invalid date value: " + microseconds); } - return new ee.Date(microseconds / 1E3); + return new ee.Date(microseconds / 1000); case "Bytes": var result = new ee.Encodable; result.encode = function(encoder) { @@ -13069,7 +13098,7 @@ ee.MapLayerOverlay = function(url, mapId, token, init, opt_profiler) { this.isPng = goog.isDef(init.isPng) ? init.isPng : !0; this.name = init.name; this.tiles_ = new goog.structs.Set; - this.opacity_ = 1; + this.opacity_ = 1.0; this.visible_ = !0; this.profiler_ = opt_profiler || null; }; @@ -13095,7 +13124,7 @@ ee.MapLayerOverlay.prototype.getTile = function(coord, zoom, ownerDocument) { profiling && (src += "&profiling=1"); var uniqueTileId = [tileId, this.tileCounter, this.token].join("/"); this.tileCounter += 1; - var div = goog.dom.createDom("DIV", {id:uniqueTileId}), priority = (new Date).getTime() / 1E3; + var div = goog.dom.createDom("DIV", {id:uniqueTileId}), priority = (new Date).getTime() / 1000; this.tilesLoading.push(uniqueTileId); ee.MapTileManager.getInstance().send(uniqueTileId, src, priority, goog.bind(this.handleImageCompleted_, this, div, uniqueTileId)); this.dispatchTileEvent_(); @@ -13129,7 +13158,7 @@ ee.MapLayerOverlay.prototype.handleImageCompleted_ = function(div, tileId, e, pr } else { goog.array.remove(this.tilesLoading, tileId); var tile; - e.target && e.type == goog.events.EventType.LOAD && (tile = e.target, this.tiles_.add(tile), 1 != this.opacity_ && goog.style.setOpacity(tile, this.opacity_), div.appendChild(tile)); + e.target && e.type == goog.events.EventType.LOAD && (tile = e.target, this.tiles_.add(tile), 1.0 != this.opacity_ && goog.style.setOpacity(tile, this.opacity_), div.appendChild(tile)); this.dispatchTileEvent_(); } this.profiler_ && !goog.isNull(profileId) && this.profiler_.addTile(tileId, profileId); diff --git a/javascript/src/examples/Charts/ImageSpectra.js b/javascript/src/examples/Charts/ImageSpectra.js index 3ac0d80d7..32b606e1d 100644 --- a/javascript/src/examples/Charts/ImageSpectra.js +++ b/javascript/src/examples/Charts/ImageSpectra.js @@ -45,7 +45,7 @@ bandChart.setOptions({ } }); -// From: http://landsat.usgs.gov/band_designations_landsat_satellites.php +// From: https://landsat.usgs.gov/what-are-best-spectral-bands-use-my-study var wavelengths = [.44, .48, .56, .65, .86, 1.61, 2.2]; var spectraChart = ui.Chart.image.regions({ diff --git a/javascript/src/geometry.js b/javascript/src/geometry.js index a71ae7fa8..b3c4bb65a 100644 --- a/javascript/src/geometry.js +++ b/javascript/src/geometry.js @@ -752,7 +752,6 @@ ee.Geometry.construct_ = function( // client-side initialization. if (ee.Geometry.hasServerValue_(eeArgs['coordinates']) || goog.isDefAndNotNull(eeArgs['crs']) || - goog.isDefAndNotNull(eeArgs['geodesic']) || goog.isDefAndNotNull(eeArgs['maxError'])) { // Some arguments cannot be handled in the client, so make a server call. // Note we don't declare a default evenOdd value, so the server can infer @@ -765,11 +764,22 @@ ee.Geometry.construct_ = function( geoJson['type'] = apiConstructorName; geoJson['coordinates'] = ee.Geometry.fixDepth_( depth, geoJson['coordinates']); - if (!goog.isDefAndNotNull(geoJson['evenOdd']) && goog.array.contains( - ['Polygon', 'Rectangle', 'MultiPolygon'], apiConstructorName)) { + var isPolygon = + goog.array.contains( + ['Polygon', 'Rectangle', 'MultiPolygon'], + apiConstructorName); + + if (isPolygon && !goog.isDefAndNotNull(geoJson['evenOdd'])) { // Default to evenOdd=true for any kind of polygon. geoJson['evenOdd'] = true; } + + if (isPolygon && + geoJson['geodesic'] === false && + geoJson['evenOdd'] === false) { + throw new Error('Planar interiors must be even/odd.'); + } + return geoJson; } }; diff --git a/python/ee/__init__.py b/python/ee/__init__.py index 3c6bd06b7..e9428b389 100644 --- a/python/ee/__init__.py +++ b/python/ee/__init__.py @@ -2,7 +2,7 @@ """The EE Python library.""" -__version__ = '0.1.101' +__version__ = '0.1.102' # Using lowercase function naming to match the JavaScript names. # pylint: disable=g-bad-name