if(!nexacro.Point){nexacro.Point=function(_a,_b){this.x=(_a|0);this.y=(_b|0);};var _pPoint=nexacro.Point.prototype;_pPoint.copy=function(){return new nexacro.Point(this.x,this.y);};_pPoint.equals=function(_a){return (this.x==_a.x&&this.y==_a.y);};_pPoint.isWithin=function(_a,_b){if(!_b){_b={x:_b};_b.y=_b.x;}return (this.x<=_a.x+_b.x&&this.x>=_a.x-_b.x&&this.y<=_a.y+_b.y&&this.y>=_a.y-_b.y);};_pPoint.translate=function(_a,_b){this.x+=(_a|0);this.y+=(_a|0);};_pPoint.roundedEquals=function(_a){return (Math.round(this.x)==Math.round(_a.x)&&Math.round(this.y)==Math.round(_a.y));};delete _pPoint;nexacro.Point.fromEvent=function(_a,_b){return new nexacro.Point(_a,_b);};}if(!nexacro.Offset){nexacro.Offset=function(_a,_b){this.x=(_a|0);this.y=(_b|0);};var _pOffset=nexacro.Offset.prototype;_pOffset.copy=function(){return new nexacro.Offset(this.x,this.y);};_pOffset.copyFrom=function(_a){this.x=_a.x;this.y=_a.y;};_pOffset.equals=function(_a){if(!(_a instanceof nexacro.Offset)){throw new Error('offset must be an instance of nexacro.Offset');}return (this.x==_a.x&&this.y==_a.y);};_pOffset.round=function(_a){if(!(( +_a)!=( +_a))){var _b=Math.pow(10,_a);this.x=Math.round(this.x*_b)/_b;this.y=Math.round(this.y*_b)/_b;}else{this.x=Math.round(this.x);this.y=Math.round(this.y);}};_pOffset.isZero=function(){return (this.x==0&&this.y==0);};nexacro.Offset.fromObject=function(_a){return new nexacro.Offset(_a.x,_a.y);};delete _pOffset;}if(!nexacro.Region){nexacro.Region=function(_a,_b,_c,_d){var _e=this;_e.top=_a;_e.right=_b;_e.bottom=_c;_e.left=_d;_e[0]=_d;_e[1]=_a;};var _pRegion=nexacro.Region.prototype;_pRegion.contains=function(_a){var _b=this;return (_a.left>=_b.left&&_a.right<=_b.right&&_a.top>=_b.top&&_a.bottom<=_b.bottom);};_pRegion.intersect=function(_a){var _b=this,_c=Math.max(_b.top,_a.top),_d=Math.min(_b.right,_a.right),_e=Math.min(_b.bottom,_a.bottom),_f=Math.max(_b.left,_a.left);if(_e>_c&&_d>_f){return new nexacro.Region(_c,_d,_e,_f);}else{return false;}};_pRegion.union=function(_a){var _b=this,_c=Math.min(_b.top,_a.top),_d=Math.max(_b.right,_a.right),_e=Math.max(_b.bottom,_a.bottom),_f=Math.min(_b.left,_a.left);return new nexacro.Region(_c,_d,_e,_f);};_pRegion.constrainTo=function(_a){var _b=this;_b.top=this.constrain(_b.top,r.top,r.bottom);_b.bottom=this.constrain(_b.bottom,r.top,r.bottom);_b.left=this.constrain(_b.left,r.left,r.right);_b.right=this.constrain(_b.right,r.left,r.right);return _b;};_pRegion.constrain=function(_a,_b,_c){_a=parseFloat(_a);if(!(( +_b)!=( +_b))){_a=Math.max(_a,_b);}if(!(( +_c)!=( +_c))){_a=Math.min(_a,_c);}return _a;};_pRegion.adjust=function(_a,_b,_c,_d){var _e=this;_e.top+=_a;_e.left+=_d;_e.right+=_b;_e.bottom+=_c;return _e;};_pRegion.getOutOfBoundOffset=function(_a,_b){if(!(_a instanceof nexacro.Offset)){if(_a=='x'){return this.getOutOfBoundOffsetX(_b);}else{return this.getOutOfBoundOffsetY(_b);}}else{_b=_a;var _c=new nexacro.Offset();_c.x=this.getOutOfBoundOffsetX(_b.x);_c.y=this.getOutOfBoundOffsetY(_b.y);return _c;}};_pRegion.getOutOfBoundOffsetX=function(_a){if(_a<=this.left){return this.left-_a;}else if(_a>=this.right){return this.right-_a;}return 0;};_pRegion.getOutOfBoundOffsetY=function(_a){if(_a<=this.top){return this.top-_a;}else if(_a>=this.bottom){return this.bottom-_a;}return 0;};_pRegion.isOutOfBound=function(_a,_b){if(!(_a instanceof nexacro.Offset)){if(_a=='x'){return this.isOutOfBoundX(_b);}else{return this.isOutOfBoundY(_b);}}else{_b=_a;return (this.isOutOfBoundX(_b.x)||this.isOutOfBoundY(_b.y));}};_pRegion.isOutOfBoundX=function(_a){return (_athis.right);};_pRegion.isOutOfBoundY=function(_a){return (_athis.bottom);};_pRegion.restrict=function(_a,_b,_c){if(_a instanceof nexacro.Offset){var _d;_c=_b;_b=_a;if(_b.copy){_d=_b.copy();}else{_d={x:_b.x,y:_b.y};}_d.x=this.restrictX(_b.x,_c);_d.y=this.restrictY(_b.y,_c);return _d;}else{if(_a=='x'){return this.restrictX(_b,_c);}else{return this.restrictY(_b,_c);}}};_pRegion.restrictX=function(_a,_b){if(!_b){_b=1;}if(_a<=this.left){_a-=(_a-this.left)*_b;}else if(_a>=this.right){_a-=(_a-this.right)*_b;}return _a;};_pRegion.restrictY=function(_a,_b){if(!_b){_b=1;}if(_a<=this.top){_a-=(_a-this.top)*_b;}else if(_a>=this.bottom){_a-=(_a-this.bottom)*_b;}return _a;};_pRegion.getSize=function(){return {width:this.right-this.left,height:this.bottom-this.top};};_pRegion.copy=function(){return new nexacro.Region(this.top,this.right,this.bottom,this.left);};_pRegion.translateBy=function(_a){this.left+=_a.x;this.right+=_a.x;this.top+=_a.y;this.bottom+=_a.y;};_pRegion.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;};_pRegion.equals=function(_a){return (this.top==_a.top&&this.right==_a.right&&this.bottom==_a.bottom&&this.left==_a.left);};delete _pRegion;}if(!nexacro.Rect){nexacro.Rect=function(_a,_b,_c,_d){this.left=(_a|0);this.top=(_b|0);this.right=(_c|0);this.bottom=(_d|0);this.width=this.right-this.left;this.height=this.bottom-this.top;};var _pRect=nexacro.Rect.prototype;_pRect.clear=function(){this.left=this.top=this.right=this.bottom=0;this.width=this.height=0;};_pRect.copy=function(_a){this.left=_a.left;this.top=_a.top;this.right=_a.right;this.bottom=_a.bottom;this.width=_a.width;this.height=_a.height;};_pRect.set=function(_a,_b,_c,_d){if(_a!=this.left||_b!=this.top||_c!=this.right||_d!=this.bottom){this.left=(_a|0);this.top=(_b|0);this.right=(_c|0);this.bottom=(_d|0);this.width=this.right-this.left;this.height=this.bottom-this.top;return true;}return false;};_pRect.clone=function(){return new nexacro.Rect(this.left,this.top,this.right,this.bottom);};_pRect.isSame=function(_a){return (this.left==_a.left)&&(this.top==_a.top)&&(this.right==_a.right)&&(this.bottom==_a.bottom);};_pRect.isSameSize=function(_a){return (this.width==_a.width)&&(this.height==_a.height);};_pRect.getWidth=function(){return this.width;};_pRect.getHeight=function(){return this.height;};_pRect=null;}if(!nexacro.SizeRect){nexacro.SizeRect=function(_a,_b,_c,_d){this.left=(_a|0);this.top=(_b|0);this.width=(_c|0);this.height=(_d|0);};_pSizeRect={};nexacro.SizeRect.prototype=_pSizeRect;_pSizeRect.clear=function(){this.left=this.top=this.width=this.height=0;};_pSizeRect.copy=function(_a){this.left=_a.left;this.top=_a.top;this.width=_a.width;this.height=_a.height;};_pSizeRect.set=function(_a,_b,_c,_d){if(_a!=this.left||_b!=this.top||_c!=this.width||_d!=this.height){this.left=(_a|0);this.top=(_b|0);this.width=(_c|0);this.height=(_d|0);return true;}return false;};_pSizeRect.clone=function(){return new nexacro.SizeRect(this.left,this.top,this.width,this.height);};_pSizeRect.isSame=function(_a){return (this.left==_a.left)&&(this.top==_a.top)&&(this.width==_a.width)&&(this.height==_a.height);};_pSizeRect.isSameSize=function(_a){return ((this.width==_a.width)&&(this.height==_a.height));};_pSizeRect=null;}if(!nexacro.Decimal){nexacro.Decimal=function(_a,_b){if(!this instanceof nexacro.Decimal){return new nexacro.Decimal(_a,_b);}this.hi=0.0;this.lo=0.0;if(_b==null){if(typeof _a=="boolean"){if(_a){this.hi=1;}else{this.hi=0;}}else if(typeof _a=="number"){this._parse(_a.toString());}else if(typeof _a=='object'&&_a instanceof nexacro.Decimal){this.hi=_a.hi;this.lo=_a.lo;}else{this._parse(_a);}}else{this.hi=(_a-0.0);this.lo=(_b-0.0);}return this;};nexacro.Decimal._fraction_10=[1e0,1e1,1e2,1e3,1e4,1e5,1e6,1e7,1e8,1e9,1e10,1e11,1e12,1e13,1e14,1e15,1e16,1e17,1e18,1e19,1e20,1e21,1e22,1e23,1e24,1e25,1e26,1e27,1e28,1e29,1e30,1e31,1e32,1e33,1e34,1e35,1e36,1e37,1e38,1e39,1e40,1e41,1e42,1e43,1e44,1e45,1e46,1e47,1e48,1e49,1e50,1e51,1e52,1e53,1e54,1e55,1e56,1e57,1e58,1e59,1e60,1e61,1e62,1e63,1e64,1e65,1e66,1e67,1e68,1e69,1e70,1e71,1e72,1e73,1e74,1e75,1e76,1e77,1e78,1e79,1e80,1e81,1e82,1e83,1e84,1e85,1e86,1e87,1e88,1e89,1e90,1e91,1e92,1e93,1e94,1e95,1e96,1e97,1e98,1e99,1e100,1e101,1e102,1e103,1e104,1e105,1e106,1e107,1e108,1e109,1e110,1e111,1e112,1e113,1e114,1e115,1e116,1e117,1e118,1e119,1e120,1e121,1e122,1e123,1e124,1e125,1e126,1e127,1e128,1e129,1e130,1e131,1e132,1e133,1e134,1e135,1e136,1e137,1e138,1e139,1e140,1e141,1e142,1e143,1e144,1e145,1e146,1e147,1e148,1e149,1e150,1e151,1e152,1e153,1e154,1e155,1e156,1e157,1e158,1e159,1e160,1e161,1e162,1e163,1e164,1e165,1e166,1e167,1e168,1e169,1e170,1e171,1e172,1e173,1e174,1e175,1e176,1e177,1e178,1e179,1e180,1e181,1e182,1e183,1e184,1e185,1e186,1e187,1e188,1e189,1e190,1e191,1e192,1e193,1e194,1e195,1e196,1e197,1e198,1e199,1e200,1e201,1e202,1e203,1e204,1e205,1e206,1e207,1e208,1e209,1e210,1e211,1e212,1e213,1e214,1e215,1e216,1e217,1e218,1e219,1e220,1e221,1e222,1e223,1e224,1e225,1e226,1e227,1e228,1e229,1e230,1e231,1e232,1e233,1e234,1e235,1e236,1e237,1e238,1e239,1e240,1e241,1e242,1e243,1e244,1e245,1e246,1e247,1e248,1e249,1e250,1e251,1e252,1e253,1e254,1e255,1e256,1e257,1e258,1e259,1e260,1e261,1e262,1e263,1e264,1e265,1e266,1e267,1e268,1e269,1e270,1e271,1e272,1e273,1e274,1e275,1e276,1e277,1e278,1e279,1e280,1e281,1e282,1e283,1e284,1e285,1e286,1e287,1e288,1e289,1e290,1e291,1e292,1e293,1e294,1e295,1e296,1e297,1e298,1e299,1e300,1e301,1e302,1e303,1e304,1e305,1e306,1e307,1e308];nexacro.Decimal._QD_SPLITTER=134217729.0;nexacro.Decimal._zero_strs=['','0','00','000','0000','00000','000000','0000000','00000000'];nexacro.Decimal._magnitude=function(_a){var _b=Math.abs(_a);var _c=Math.log(_b)*Math.LOG10E;var _d=Math.floor(_c);if(_b>=nexacro.Decimal._fraction_10[_d+1]){return _d+2;}return _d+1;};nexacro.Decimal._getPow=function(_a,_b){_b.setDouble(1.0);while(_a>0){if(_a>=14){_b.mulDouble(1e14);}else{_b.mulDouble(nexacro.Decimal._fraction_10[_a]);}_a-=14;}};var _pDecimal=nexacro.Decimal.prototype;_pDecimal._parse=function(_a){this.hi=0;this.lo=0;var _b=0;if(!_a){return;}var _c=_a.length;var _d;while(_b<_c){_d=_a.charAt(_b);if(_d!=' '&&_d!='\t'){break;}_b++ ;}if(_b>=_c){this.hi=Number.NaN;return;}var _e=0;_d=_a.charAt(_b);if(_d=='-'){_e=1;_b++ ;}else if(_d=='+'){_b++ ;}var _f=_b;var _g=_b;while(_g<_c){_d=_a.charAt(_g);if(_d<'0'||_d>'9'){break;}_g++ ;}var _h;var _i=0;var _j=_f;while(_j<_g){_b=_j;_j+=9;if(_j>_g){_j=_g;_i=_j-_b;}else{_i=9;}_h=0;while(_b<_j){_h*=10;_d=_a.charAt(_b++ );_h+=(_d-'0');}this.mulDouble(nexacro.Decimal._fraction_10[_i]);this.addDouble(_h);}var _k,_l=0;_d=_a.charAt(_g);if(_d=='.'){_g++ ;_b=_g;while(_b<_c){_d=_a.charAt(_b);if(_d<'0'||_d>'9'){break;}_b++ ;}_k=_b;_j=_g;while(_j<_k){_b=_j;_j+=9;if(_j>_k){_j=_k;_i=_j-_b;}else{_i=9;}_h=0;while(_b<_j){_h*=10;_d=_a.charAt(_b++ );_h+=(_d-'0');}this.mulDouble(nexacro.Decimal._fraction_10[_i]);this.addDouble(_h);_l+=_i;}}else{_k=_g;}_d=_a.charAt(_k);_h=0;if(_d=='e'||_d=='E'){var _n;_k++ ;_d=_a.charAt(_k);if(_d=='-'){_n=1;_k++ ;}else if(_d=='+'){_n=0;_k++ ;}else{_n=0;}_b=_k;while(_b<_c){_d=_a.charAt(_b);if(_d<'0'||_d>'9'){break;}_b++ ;}_c=_b+1;if(_c>_a.length){_c=_a.length;}_b=_k;while(_b<_c){_h*=10;_d=_a.charAt(_b++ );_h+=(_d-'0');}if(_h>=308){if(_n){this.hi=0.0;this.lo=0.0;}else{this.hi=(_e? -Infinity:Infinity);this.lo=0.0;}return;}}var _m=new nexacro.Decimal();if(_l>0){nexacro.Decimal._getPow(_l,_m);this.divDecimal(_m);}else{nexacro.Decimal._getPow(_l,_m);this.mulDecimal(_m);}if(_h>0){nexacro.Decimal._getPow(_h,_m);if(_n){this.divDecimal(_m);}else{this.mulDecimal(_m);}}if(_e){this.hi= -this.hi;this.lo= -this.lo;}};_pDecimal.setDouble=function(_a){if(typeof _a!='number'){throw new TypeError("Invalid arguments type!");}this.hi=_a;this.lo=0.0;};_pDecimal.setDecimal=function(_a){if(!_a instanceof nexacro.Decimal){throw new TypeError("Invalid arguments type!");}this.hi=_a.hi;this.lo=_a.lo;};_pDecimal.setString=function(_a){if(typeof _a!='string'){throw new TypeError("Invalid arguments type!");}this._parse(_a);};_pDecimal.isZero=function(){return (this.hi==0.0&&this.lo==0.0);};_pDecimal.isEqual=function(_a){if(!(_a instanceof nexacro.Decimal)){throw new TypeError("Invalid arguments type!");}return (this.hi==_a.hi&&this.lo==_a.lo);};_pDecimal.isInfinity=function(){return (this.hi==Infinity||this.hi== -Infinity);};_pDecimal.isNaN=function(){return (this.hi!=this.hi);};_pDecimal.isNaNOrInf=function(){return (this.hi==Infinity||this.hi== -Infinity||this.hi!=this.hi);};_pDecimal.isNegative=function(){return this.hi<0.0||(this.hi==0.0&&this.lo<0.0);};_pDecimal.addDouble=function(_a){var _b,_c,_d,_e;_c=this.hi+_a;_e=_c-this.hi;_d=_c-_e;_d=(_a-_e)+(this.hi-_d);_e=_d+this.lo;_b=_c+_e;_e=_e+(_c-_b);this.hi=_b+_e;this.lo=_e+(_b-this.hi);};_pDecimal.addDecimal=function(_a){var _b,_c,_d,_e,_f,_g,_h,_i;_f=this.hi+_a.hi;_d=this.lo+_a.lo;_h=_f-this.hi;_i=_d-this.lo;_g=_f-_h;_e=_d-_i;_g=(_a.hi-_h)+(this.hi-_g);_e=(_a.lo-_i)+(this.lo-_e);_h=_g+_d;_b=_f+_h;_c=_h+(_f-_b);_h=_e+_c;this.hi=_b+_h;this.lo=_h+(_b-this.hi);};_pDecimal.subDouble=function(_a){var _b,_c,_d,_e;_c=this.hi-_a;_e=_c-this.hi;_d=_c-_e;_d=( -_a-_e)+(this.hi-_d);_e=_d+this.lo;_b=_c+_e;_e=_e+(_c-_b);this.hi=_b+_e;this.lo=_e+(_b-this.hi);};_pDecimal.subDecimal=function(_a){var _b,_c,_d,_e,_f,_g,_h,_i;_f=this.hi-_a.hi;_d=this.lo-_a.lo;_h=_f-this.hi;_i=_d-this.lo;_g=_f-_h;_e=_d-_i;_g=( -_a.hi-_h)+(this.hi-_g);_e=( -_a.lo-_i)+(this.lo-_e);_h=_g+_d;_b=_f+_h;_c=_h+(_f-_b);_h=_e+_c;this.hi=_b+_h;this.lo=_h+(_b-this.hi);};_pDecimal.mulDouble=function(_a){var _b,_c,_d,_e,_f,_g;_f=nexacro.Decimal._QD_SPLITTER*this.hi;_b=_f-this.hi;_g=nexacro.Decimal._QD_SPLITTER*_a;_b=_f-_b;_c=this.hi-_b;_d=_g-_a;_f=this.hi*_a;_d=_g-_d;_e=_a-_d;_g=((((_b*_d-_f)+_b*_e)+_c*_d)+_c*_e)+(this.lo*_a);this.hi=_f+_g;_b=_f-this.hi;this.lo=_g+_b;};_pDecimal.mulDecimal=function(_a){var _b,_c,_d,_e,_f,_g;_f=nexacro.Decimal._QD_SPLITTER*this.hi;_b=_f-this.hi;_g=nexacro.Decimal._QD_SPLITTER*_a.hi;_b=_f-_b;_c=this.hi-_b;_d=_g-_a.hi;_f=this.hi*_a.hi;_d=_g-_d;_e=_a.hi-_d;_g=((((_b*_d-_f)+_b*_e)+_c*_d)+_c*_e)+(this.hi*_a.lo+this.lo*_a.hi);this.hi=_f+_g;_b=_f-this.hi;this.lo=_g+_b;};_pDecimal.divDouble=function(_a){var _b,_c,_d,_e,_f,_g,_h,_i;_f=this.hi/_a;_g=nexacro.Decimal._QD_SPLITTER*_f;_b=_g-_f;_i=nexacro.Decimal._QD_SPLITTER*_a;_b=_g-_b;_c=_f-_b;_d=_i-_a;_h=_f*_a;_d=_i-_d;_e=_a-_d;_i=(((_b*_d-_h)+_b*_e)+_c*_d)+_c*_e;_g=((((this.hi-_h)-_i)+this.lo))/_a;this.hi=_f+_g;this.lo=(_f-this.hi)+_g;};_pDecimal.divDecimal=function(_a){var _b,_c,_d,_e,_f,_g,_h,_i;_f=this.hi/_a.hi;_g=nexacro.Decimal._QD_SPLITTER*_f;_b=_g-_f;_i=nexacro.Decimal._QD_SPLITTER*_a.hi;_b=_g-_b;_c=_f-_b;_d=_i-_a.hi;_h=_f*_a.hi;_d=_i-_d;_e=_a.hi-_d;_i=(((_b*_d-_h)+_b*_e)+_c*_d)+_c*_e;_g=((((this.hi-_h)-_i)+this.lo)-_f*_a.lo)/_a.hi;this.hi=_f+_g;this.lo=(_f-this.hi)+_g;};_pDecimal.modDouble=function(_a){var _b=new nexacro.Decimal(this);_b.divDouble(_a);_b.floor();_b.mulDouble(_a);this.subDecimal(_b);};_pDecimal.modDecimal=function(_a){var _b=new nexacro.Decimal(this);_b.divDecimal(_a);_b.floor();_b.mulDecimal(_a);this.subDecimal(_b);};_pDecimal.abs=function(){if(this.isNegative()){this.hi= -this.hi;this.lo= -this.lo;}return this;};_pDecimal.floor=function(){var _a=Math.floor(this.hi);if(_a==this.hi){this.lo=Math.floor(this.lo);}else{this.hi=_a;this.lo=0.0;}return this;};_pDecimal.ceil=function(){var _a=Math.ceil(this.hi);if(_a==this.hi){this.lo=Math.ceil(this.lo);}else{this.hi=_a;this.lo=0.0;}return this;};_pDecimal.round=function(){this.addDouble(0.5);return this.floor();};_pDecimal.trunc=function(){if(this.hi>0.0){return this.floor();}else{return this.ceil();}};_pDecimal.toString=function(){if(this.isZero()){return "0";}if(this.isNaN()){return "NaN";}var _a=nexacro.Decimal._magnitude(this.hi);if(_a>= -5&&_a<=24){return this._toStandardStr();}return this._toScientificStr();};_pDecimal.valueOf=function(){return this.hi+this.lo;};_pDecimal._getCVT=function(){var _a='';var _b=0;var _c=new nexacro.Decimal(this);if(this.hi<0.0||this.hi==0.0&&this.lo<0.0){_b=1;_c.abs();}var _d=nexacro.Decimal._magnitude(_c.hi);var _e=new nexacro.Decimal();if(_d>8){nexacro.Decimal._getPow(_d-8,_e);_c.divDecimal(_e);}else{nexacro.Decimal._getPow(_d-8,_e);_c.mulDecimal(_e);}var _f=0,_g;var _h;var _i;while(true){_h=_c.hi|0;if(_h<0){break;}_i=String(_h);_g=_i.length;if(_g>8){_a+='99999999';_f+=8;}else if(_f==0){_a+=_i;_f+=_g;}else{_a+=nexacro.Decimal._zero_strs[8-_g];_a+=_i;_f+=8;}if(_f>=32){_f=32;break;}_c.subDouble(_h);_c.mulDouble(1e8);}if(_f>=32&&_a.charAt(_f-1)>='5'){var _k= -1;while(_f>0){ --_f;if(_a.charAt(_f-1)<'9'){_k=_f-1;break;}_k=_f-1;}if(_k> -1){_a=_a.substr(0,_k)+(Number(_a.charAt(_k))+1);}}else{while(_f>0&&_a.charAt(_f-1)=='0'){ --_f;}}var _j=new Object;_j.dec=_d;_j.sign=_b;_j.pos=_f;_j.buf=_a.substr(0,_f);return _j;};_pDecimal._toScientificStr=function(){var _a='',_b=0;var _c=this._getCVT();if(_c==null||_c.pos==0){return '0';}_b=_c.pos;if(_c.sign){_a='-';}_a+=_c.buf.charAt(0);if(_b==1){return _a;}_a+='.';_a+=_c.buf.substring(1);_a+='e+';_a+=(_c.dec-1);return _a;};_pDecimal._toStandardStr=function(){var _a='',_b=0,_c=0;var _d=this._getCVT();if(_d==null||_d.pos==0){return '0';}if(_d.sign){_a='-';}_c=_d.dec;_b=_d.pos;var _e=_d.buf;if(_c<=0){_a+='0.';for(var _f=_c;_f<0;_f++ ){_a+='0';}_a+=_e.substring(_b-(_b+(_c-1)));}else if(_b>_c){_a+=_e.substring(0,_c);_a+='.';_a+=_e.substring(_c);}else{_a+=_e;if((_c-_b)>0){for(var _f=0;_f<(_c-_b);_f++ ){_a+='0';}}}return _a;};_pDecimal.toFixed=function(_a){var _b=".";var _c=",";var _d=0;var _e="";var _f="-";var _g=this.isNegative();var _h=this._getFormattedStringValue(this,_b,_c,_d,_a,true);if(_g){_h=_f+_h;}else{_h=_e+_h;}return _h;};_pDecimal.toExponential=function(_a){};_pDecimal.toPrecision=function(_a){};_pDecimal.toLocaleString=function(_a){var _b=nexacro.Locale.getLocaleInfo(_a);var _c=_b.decimal_point;var _d=_b.thousands_sep;var _e=_b.grouping;var _f=_b.positive_sign;var _g=_b.negative_sign;var _h=this.isNegative();var _i=this._getFormattedStringValue(this,_c,_d,_e,3);if(_h){_i=_g+_i;}else{_i=_f+_i;}return _i;};_pDecimal.toLocaleCurrencyString=function(_a){var _b=nexacro.Locale.getLocaleInfo(_a);var _c=_b.mon_decimal_point;var _d=_b.mon_thousands_sep;var _e=_b.int_curr_symbol;var _f=_b.currency_symbol.trim();var _g=_b.mon_grouping;var _h=_b.int_frac_digits;var _i=_b.positive_sign;var _j=_b.negative_sign;var _k=_b.p_cs_precedes;var _l=_b.p_sep_by_space;var _m=_b.n_cs_precedes;var _n=_b.n_sep_by_space;var _o=_b.p_sign_posn;var _p=_b.n_sign_posn;var _q=_b.mon_n_sign_posn;if(_q!=undefined){_p=_q;}var _r="\u0020";var _s=this.isNegative();var _t=this._getFormattedStringValue(this,_c,_d,_g,_h,true);if(_s){if(_m){switch(_p){case 0:{switch(_n){case 0:{_t="("+_f+_t+")";}break;case 1:{_t="("+_f+_r+_t+")";}break;case 2:{_t="("+_f+_t+")";}break;}}break;case 1:{switch(_n){case 0:{_t=_j+_f+_t;}break;case 1:{_t=_j+_f+_r+_t;}break;case 2:{_t=_j+_r+_f+_t;}break;}}break;case 2:{switch(_n){case 0:{_t=_f+_t+_j;}break;case 1:{_t=_f+_r+_t+_j;}break;case 2:{_t=_f+_t+_r+_j;}break;}}break;case 3:{switch(_n){case 0:{_t=_j+_f+_t;}break;case 1:{_t=_j+_f+_r+_t;}break;case 2:{_t=_j+_r+_f+_t;}break;}}break;case 4:{switch(_n){case 0:{_t=_f+_j+_t;}break;case 1:{_t=_f+_j+_r+_t;}break;case 2:{_t=_f+_r+_j+_t;}break;}}break;}}else{switch(_p){case 0:{switch(_n){case 0:{_t="("+_t+_f+")";}break;case 1:{_t="("+_t+_r+_f+")";}break;case 2:{_t="("+_t+_r+_f+")";}break;}}break;case 1:{switch(_n){case 0:{_t=_j+_t+_f;}break;case 1:{_t=_j+_t+_r+_f;}break;case 2:{_t=_j+_t+_r+_f;}break;}}break;case 2:{switch(_n){case 0:{_t=_t+_f+_j;}break;case 1:{_t=_t+_r+_f+_j;}break;case 2:{_t=_t+_f+_r+_j;}break;}}break;case 3:{switch(_n){case 0:{_t=_t+_j+_f;}break;case 1:{_t=_t+_r+_j+_f;}break;case 2:{_t=_t+_j+_r+_f;}break;}}break;case 4:{switch(_n){case 0:{_t=_t+_f+_j;}break;case 1:{_t=_t+_r+_f+_j;}break;case 2:{_t=_t+_f+_r+_j;}break;}}break;}}}else{if(_k){switch(_o){case 0:{switch(_l){case 0:{_t="("+_f+_t+")";}break;case 1:{_t="("+_f+_r+_t+")";}break;case 2:{_t="("+_f+_t+")";}break;}}break;case 1:{switch(_l){case 0:{_t=_i+_f+_t;}break;case 1:{_t=_i+_f+_r+_t;}break;case 2:{_t=_i+_r+_f+_t;}break;}}break;case 2:{switch(_l){case 0:{_t=_f+_t+_i;}break;case 1:{_t=_f+_r+_t+_i;}break;case 2:{_t=_f+_t+_r+_i;}break;}}break;case 3:{switch(_l){case 0:{_t=_i+_f+_t;}break;case 1:{_t=_i+_f+_r+_t;}break;case 2:{_t=_i+_r+_f+_t;}break;}}break;case 4:{switch(_l){case 0:{_t=_f+_i+_t;}break;case 1:{_t=_f+_i+_r+_t;}break;case 2:{_t=_f+_r+_i+_t;}break;}}break;}}else{switch(_o){case 0:{switch(_l){case 0:{_t="("+_t+_f+")";}break;case 1:{_t="("+_t+_r+_f+")";}break;case 2:{_t="("+_t+_r+_f+")";}break;}}break;case 1:{switch(_l){case 0:{_t=_i+_t+_f;}break;case 1:{_t=_i+_t+_r+_f;}break;case 2:{_t=_i+_t+_r+_f;}break;}}break;case 2:{switch(_l){case 0:{_t=_t+_f+_i;}break;case 1:{_t=_t+_r+_f+_i;}break;case 2:{_t=_t+_f+_r+_i;}break;}}break;case 3:{switch(_l){case 0:{_t=_t+_i+_f;}break;case 1:{_t=_t+_r+_i+_f;}break;case 2:{_t=_t+_i+_r+_f;}break;}}break;case 4:{switch(_l){case 0:{_t=_t+_f+_i;}break;case 1:{_t=_t+_r+_f+_i;}break;case 2:{_t=_t+_f+_r+_i;}break;}}break;}}}return _t;};_pDecimal.toFixedLocaleString=function(_a,_b){var _c=nexacro.Locale.getLocaleInfo(_a);var _d=_c.decimal_point;var _e=_c.thousands_sep;var _f=_c.grouping;var _g=_c.positive_sign;var _h=_c.negative_sign;var _i=this.isNegative();var _j=this._getFormattedStringValue(this,_d,_e,_f,_b,true);if(_i){_j=_h+_j;}else{_j=_g+_j;}return _j;};_pDecimal._getFormattedStringValue=function(_a,_b,_c,_d,_e,_f){var _g=_a.abs().toString().split(".");var _h=_g[0];var _i=_g[1];if(!_i){_i="";}var _j="";var _k;if(!_b){_b=".";}if(!_c){_c=",";}if(_d&&_d.length>0){_k=_d[0];}if(_k<=0){_k=3;}if(_h.length>_k&&_k>0){_j=_c+_h.substr(_h.length-_k,_k)+_j;_h=_h.slice(0,_h.length-_k);}if(_d.length>1){_k=_d[1];}if(_k<=0){_k=3;}while(_h.length>_k&&_k>0){_j=_c+_h.substr(_h.length-_k,_k)+_j;_h=_h.slice(0,_h.length-_k);}_j=_h+_j;if(_f){var _l=_i.length;var _m="";while(_l<_e){_m=_m+"0";_l++ ;}_i=_i+_m;_i=_i.slice(0,_e);}if(_i){_j=_j+_b+_i;}return _j;};delete _pDecimal;}if(!nexacro.Number){nexacro.Number=function(_a){{this.value=new Number(_a);}};var _pNumber=nexacro._createPrototype(nexacro.Object,nexacro.Number);nexacro.Number.prototype=_pNumber;_pNumber.toString=function(_a){return this.value.toString();};_pNumber.valueOf=function(){return this.value;};_pNumber.isNegative=function(){return this.value<0;};_pNumber._getFormattedStringValue=function(_a,_b,_c,_d,_e,_f){var _g=Math.abs(_a).toString().split(".");var _h=_g[0];var _i=_g[1];if(!_i){_i="";}var _j="";var _k;if(!_b){_b=".";}if(!_c){_c=",";}if(_d&&_d.length>0){_k=_d[0];}if(_k<=0){_k=3;}if(_h.length>_k&&_k>0){_j=_c+_h.substr(_h.length-_k,_k)+_j;_h=_h.slice(0,_h.length-_k);}if(_d.length>1){_k=_d[1];}if(_k<=0){_k=3;}while(_h.length>_k&&_k>0){_j=_c+_h.substr(_h.length-_k,_k)+_j;_h=_h.slice(0,_h.length-_k);}_j=_h+_j;if(_f){var _l=_i.length;var _m="";while(_l<_e){_m=_m+"0";_l++ ;}_i=_i+_m;_i=_i.slice(0,_e);}if(_i){_j=_j+_b+_i;}return _j;};_pNumber.toLocaleString=function(_a){var _b=nexacro.Locale.getLocaleInfo(_a);var _c=_b.decimal_point;var _d=_b.thousands_sep;var _e=_b.grouping;var _f=_b.positive_sign;var _g=_b.negative_sign;var _h=this.isNegative();var _i=this._getFormattedStringValue(this.value,_c,_d,_e,3);if(_h){_i=_g+_i;}else{_i=_f+_i;}return _i;};_pNumber.toLocaleCurrencyString=function(_a){var _b=nexacro.Locale.getLocaleInfo(_a);var _c=_b.mon_decimal_point;var _d=_b.mon_thousands_sep;var _e=_b.int_curr_symbol;var _f=_b.currency_symbol.trim();var _g=_b.mon_grouping;var _h=_b.int_frac_digits;var _i=_b.positive_sign;var _j=_b.negative_sign;var _k=_b.p_cs_precedes;var _l=_b.p_sep_by_space;var _m=_b.n_cs_precedes;var _n=_b.n_sep_by_space;var _o=_b.p_sign_posn;var _p=_b.n_sign_posn;var _q=_b.mon_n_sign_posn;if(_q!=undefined){_p=_q;}var _r="\u0020";var _s=this.isNegative();var _t=this._getFormattedStringValue(this.value,_c,_d,_g,_h,true);if(_s){if(_m){switch(_p){case 0:{switch(_n){case 0:{_t="("+_f+_t+")";}break;case 1:{_t="("+_f+_r+_t+")";}break;case 2:{_t="("+_f+_t+")";}break;}}break;case 1:{switch(_n){case 0:{_t=_j+_f+_t;}break;case 1:{_t=_j+_f+_r+_t;}break;case 2:{_t=_j+_r+_f+_t;}break;}}break;case 2:{switch(_n){case 0:{_t=_f+_t+_j;}break;case 1:{_t=_f+_r+_t+_j;}break;case 2:{_t=_f+_t+_r+_j;}break;}}break;case 3:{switch(_n){case 0:{_t=_j+_f+_t;}break;case 1:{_t=_j+_f+_r+_t;}break;case 2:{_t=_j+_r+_f+_t;}break;}}break;case 4:{switch(_n){case 0:{_t=_f+_j+_t;}break;case 1:{_t=_f+_j+_r+_t;}break;case 2:{_t=_f+_r+_j+_t;}break;}}break;}}else{switch(_p){case 0:{switch(_n){case 0:{_t="("+_t+_f+")";}break;case 1:{_t="("+_t+_r+_f+")";}break;case 2:{_t="("+_t+_r+_f+")";}break;}}break;case 1:{switch(_n){case 0:{_t=_j+_t+_f;}break;case 1:{_t=_j+_t+_r+_f;}break;case 2:{_t=_j+_t+_r+_f;}break;}}break;case 2:{switch(_n){case 0:{_t=_t+_f+_j;}break;case 1:{_t=_t+_r+_f+_j;}break;case 2:{_t=_t+_f+_r+_j;}break;}}break;case 3:{switch(_n){case 0:{_t=_t+_j+_f;}break;case 1:{_t=_t+_r+_j+_f;}break;case 2:{_t=_t+_j+_r+_f;}break;}}break;case 4:{switch(_n){case 0:{_t=_t+_f+_j;}break;case 1:{_t=_t+_r+_f+_j;}break;case 2:{_t=_t+_f+_r+_j;}break;}}break;}}}else{if(_k){switch(_o){case 0:{switch(_l){case 0:{_t="("+_f+_t+")";}break;case 1:{_t="("+_f+_r+_t+")";}break;case 2:{_t="("+_f+_t+")";}break;}}break;case 1:{switch(_l){case 0:{_t=_i+_f+_t;}break;case 1:{_t=_i+_f+_r+_t;}break;case 2:{_t=_i+_r+_f+_t;}break;}}break;case 2:{switch(_l){case 0:{_t=_f+_t+_i;}break;case 1:{_t=_f+_r+_t+_i;}break;case 2:{_t=_f+_t+_r+_i;}break;}}break;case 3:{switch(_l){case 0:{_t=_i+_f+_t;}break;case 1:{_t=_i+_f+_r+_t;}break;case 2:{_t=_i+_r+_f+_t;}break;}}break;case 4:{switch(_l){case 0:{_t=_f+_i+_t;}break;case 1:{_t=_f+_i+_r+_t;}break;case 2:{_t=_f+_r+_i+_t;}break;}}break;}}else{switch(_o){case 0:{switch(_l){case 0:{_t="("+_t+_f+")";}break;case 1:{_t="("+_t+_r+_f+")";}break;case 2:{_t="("+_t+_r+_f+")";}break;}}break;case 1:{switch(_l){case 0:{_t=_i+_t+_f;}break;case 1:{_t=_i+_t+_r+_f;}break;case 2:{_t=_i+_t+_r+_f;}break;}}break;case 2:{switch(_l){case 0:{_t=_t+_f+_i;}break;case 1:{_t=_t+_r+_f+_i;}break;case 2:{_t=_t+_f+_r+_i;}break;}}break;case 3:{switch(_l){case 0:{_t=_t+_i+_f;}break;case 1:{_t=_t+_r+_i+_f;}break;case 2:{_t=_t+_i+_r+_f;}break;}}break;case 4:{switch(_l){case 0:{_t=_t+_f+_i;}break;case 1:{_t=_t+_r+_f+_i;}break;case 2:{_t=_t+_f+_r+_i;}break;}}break;}}}return _t;};_pNumber.toFixed=function(_a){var _b=".";var _c=",";var _d=0;var _e="";var _f="-";var _g=this.isNegative();var _h=this._getFormattedStringValue(this.value,_b,_c,_d,_a,true);if(_g){_h=_f+_h;}else{_h=_e+_h;}return _h;};_pNumber.toFixedLocaleString=function(_a,_b){var _c=nexacro.Locale.getLocaleInfo(_a);var _d=_c.decimal_point;var _e=_c.thousands_sep;var _f=_c.grouping;var _g=_c.positive_sign;var _h=_c.negative_sign;var _i=this.isNegative();var _j=this._getFormattedStringValue(this.value,_d,_e,_f,_b,true);if(_i){_j=_h+_j;}else{_j=_g+_j;}return _j;};_pNumber.toPrecesion=function(_a){};_pNumber.toExponential=function(){};delete _pNumber;}if(!nexacro.BindableValue){nexacro.BindableValue=function(_a){this._bindtype=0;this._default=_a;this._value=_a;};var _pBindableValue=nexacro._createPrototype(nexacro.Object,nexacro.BindableValue);nexacro.BindableValue.prototype=_pBindableValue;_pBindableValue._type_name="BindableValue";_pBindableValue.valueOf=function(){return this._value;};_pBindableValue.toString=function(){return this._value+"";};_pBindableValue._set=function(_a){var _b=this._default;if(_a){_b=_a.toString();}if(_a!=this._value){if(_a==""){this._value=this._default;this._bindtype=0;}else{this._bindtype=0;var _c=_b.substr(0,4);_c=_c.toUpperCase();if(_c=="EXPR"||_c=="BIND"){var _d=_b.substr(4,1);if(_c=="EXPR"&&_d=="("){_b=_b.substr(0,4)+":"+_b.substr(4);}var _e=_b.substr(4).trim();if(_c=="BIND"){this._bindtype=1;}else{this._bindtype=2;}this._bindexpr=_e.substr(1);this._value=_b.substr(0,4)+":"+this._bindexpr;}else{this._value=_a;}}}};_pBindableValue._set_intval=function(_a){var _b=_a.toString();if(_a!=this._value){if(_a==""){this._value=this._default;this._bindtype=0;}else{this._bindtype=0;var _c=_b.substr(0,4);_c=_c.toUpperCase();if(_c=="EXPR"||_c=="BIND"){var _d=_b.substr(4,1);if(_c=="EXPR"&&_d=="("){_b=_b.substr(0,4)+":"+_b.substr(4);}if(_c=="BIND"){this._bindtype=1;}else{this._bindtype=2;}var _e=_b.substr(4).trim();if(/^expr(\s*):|^bind(\s*):/.test(_b)){this._bindexpr=_e.substr(1);}else{this._bindexpr=_e.substr(1,_e.length-1);}this._value=_b;}else{this._value=(_a|0);}}}};_pBindableValue._set_enumval=function(_a,_b){var _c=_a.toString();if(_a!=this._value){if(_a==""){this._value=this._default;this._bindtype=0;}else{this._bindtype=0;var _d=_c.substr(0,4);_d=_d.toUpperCase();if(_d=="EXPR"||_d=="BIND"){var _e=_c.substr(4,1);if(_d=="EXPR"&&_e=="("){_c=_c.substr(0,4)+":"+_c.substr(4);}if(_d=="BIND"){this._bindtype=1;}else{this._bindtype=2;}var _f=_c.substr(4).trim();if(/^expr(\s*):|^bind(\s*):/.test(_c)){this._bindexpr=_f.substr(1);}else{this._bindexpr=_f.substr(1,_f.length-1);}this._value=_c;}else{var _g=_b.length;for(var _h=0;_h<_g;_h++ ){if(_a==_b[_h]){this._value=_a;return;}}this._value=this._default;}}}};}if(!nexacro.Image){nexacro.Image=function(_a){if(_a){this._target=_a;}this._event_list={"onload":1,"onerror":1};};_pImageObject=nexacro._createPrototype(nexacro.EventSinkObject,nexacro.Image);nexacro.Image.prototype=_pImageObject;_pImageObject._type_name="Image";_pImageObject.height=0;_pImageObject.width=0;_pImageObject.src="";_pImageObject._base64str="";_pImageObject._handle=null;_pImageObject.setBase64String=function(_a){if(typeof _a!="string"){return;}if(_a==""){this._base64str=_a;}else if(_a.substring(0,10).toLowerCase()!="data:image"){this._base64str="data:image;base64,"+_a;}else if(_a.substring(0,17).toLowerCase()!="data:image;base64"){var _b=_a.indexOf(",");if(_b> -1){var _c=_a.slice(_b+1,_a.legnth);this._base64str="data:image;base64,"+_c;}}};_pImageObject.getBase64String=function(){return this._base64str;};_pImageObject.set_src=function(_a){if(this.src!=_a){this.src=_a;this._handle=nexacro._getImageObject(_a,this.on_load,this);}};_pImageObject.on_load=function(_a,_b,_c,_d,_e,_f,_g,_h){this.width=_b;this.height=_c;if(_e&&_e<0){var _i;if(_f){_i=nexacro._GetSystemErrorMsg(this,_f);}this.on_fire_onerror(this,_f,_i,_g,_a,_h);}else{if(_d){this._handle=_d;}this.on_fire_onload(this,_a);}};_pImageObject.on_fire_onload=function(_a,_b){if(this.onload&&this.onload._has_handlers){var _c=new nexacro.LoadEventInfo(_a,"onload",_b);this.onload._fireEvent(_a,_c);}};_pImageObject.on_fire_onerror=function(_a,_b,_c,_d,_e,_f){if(this.onerror&&this.onerror._has_handlers){var _g=new nexacro.ErrorEventInfo(_a,"onerror",_b,_c,this,_d,_e,_f);this.onerror._fireEvent(this,_g);}};delete _pImageObject;}if(!nexacro.HotKey){nexacro.HotKey=function(_a){this._load(_a);};var _pHotKey=nexacro._createPrototype(nexacro.Object,nexacro.HotKey);nexacro.HotKey.prototype=_pHotKey;_pHotKey._modifierkey=0;_pHotKey._keycode=0;_pHotKey._is_registered=false;_pHotKey._type_name="HotKey";_pHotKey._keytable={"BACK":0x08,"TAB":0x09,"RETURN":0x0d,"PAUSE":0x13,"CAPITAL":0x14,"ESCAPE":0x1b,"SPACE":0x20,"PRIOR":0x21,"NEXT":0x22,"END":0x23,"HOME":0x24,"LEFT":0x25,"UP":0x26,"RIGHT":0x27,"DOWN":0x28,"INSERT":0x2d,"DELETE":0x2e,"NUMPAD0":0x60,"NUMPAD1":0x61,"NUMPAD2":0x62,"NUMPAD3":0x63,"NUMPAD4":0x64,"NUMPAD5":0x65,"NUMPAD6":0x66,"NUMPAD7":0x67,"NUMPAD8":0x68,"NUMPAD9":0x69,"MULTIPLY":0x6a,"ADD":0x6b,"SEPARATOR":0x6c,"SUBTRACT":0x6d,"DECIMAL":0x6e,"DIVIDE":0x6f,"F1":0x70,"F2":0x71,"F3":0x72,"F4":0x73,"F5":0x74,"F6":0x75,"F7":0x76,"F8":0x77,"F9":0x78,"F10":0x79,"F11":0x7a,"F12":0x7b,"NUMLOCK":0x90,"SCROLL":0x91};_pHotKey._clear=function(){this._modifierkey=0;this._keycode=0;};_pHotKey._load=function(_a){this._clear();if(_a&&_a!=""){var _b=_a.split("+");for(var _c=0;_c<_b.length-1;_c++ ){var _d=_b[_c].toUpperCase().trim();if(_d=="CTRL"||_d=="CONTROL"){this._modifierkey+=0x01;}if(_d=="ALT"){this._modifierkey+=0x02;}if(_d=="SHIFT"){this._modifierkey+=0x04;}}var _e=_b[_b.length-1].toUpperCase().trim();var _f=this._convToKeyCode(_e);if(_f<0){this._clear();return;}this._keycode=_f;}};_pHotKey._isEmpty=function(){if(this._keycode==0){return true;}return false;};_pHotKey._convToKeyCode=function(_a){var _b= -1;if(!_a){return _b;}if(_a.length==1){if((_a>='A'&&_a<='Z')||(_a>='0'&&_a<='9')){_b=_a.charCodeAt(0);}else if(_a>='a'&&_a<='z'){_b=_a.toUpperCase().charCodeAt(0);}}else{if(this._keytable[_a]){_b=this._keytable[_a];}}return _b;};_pHotKey._convToKeyString=function(_a){var _b= -1;if(!_a){return _b;}if((_a>=65&&_a<=90)||(_a>=48&&_a<=57)){_b=String.fromCharCode(_a);}else{for(var _c in this._keytable){if(_a==this._keytable[_c]){_b=_c;break;}}}return _b;};_pHotKey._toString=function(){var _a="";if((this._modifierkey&0x01)==0x01){_a+="CTRL";}if((this._modifierkey&0x02)==0x02){if(_a.length!=0){_a+="+";}_a+="ALT";}if((this._modifierkey&0x04)==0x04){if(_a.length!=0){_a+="+";}_a+="SHIFT";}if(_a.length!=0){_a+="+";}_a+=this._convToKeyString(this._keycode);return _a;};delete _pHotKey;}