diff --git a/frontend/build/production/Explorer/app.js b/frontend/build/production/Explorer/app.js index 0624bced1..bde78ebc5 100644 --- a/frontend/build/production/Explorer/app.js +++ b/frontend/build/production/Explorer/app.js @@ -1 +1 @@ -var $jscomp=$jscomp||{};$jscomp.scope={};$jscomp.defineProperty=typeof Object.defineProperties=='function'?Object.defineProperty:function(b,c,a){a=a;if(b==Array.prototype||b==Object.prototype){return}b[c]=a.value};$jscomp.getGlobal=function(a){return typeof window!='undefined'&&window===a?a:typeof global!='undefined'&&global!=null?global:a};$jscomp.global=$jscomp.getGlobal(this);$jscomp.polyfill=function(i,f,j,k){if(!f){return}var a=$jscomp.global;var b=i.split('.');for(var e=0;ec){if(--b in this){this[--d]=this[b]}else {delete this[d]}}}return this};return b},'es6-impl','es3');$jscomp.SYMBOL_PREFIX='jscomp_symbol_';$jscomp.initSymbol=function(){$jscomp.initSymbol=function(){};if(!$jscomp.global['Symbol']){$jscomp.global['Symbol']=$jscomp.Symbol}};$jscomp.symbolCounter_=0;$jscomp.Symbol=function(a){return $jscomp.SYMBOL_PREFIX+(a||'')+$jscomp.symbolCounter_++};$jscomp.initSymbolIterator=function(){$jscomp.initSymbol();var a=$jscomp.global['Symbol'].iterator;if(!a){a=$jscomp.global['Symbol'].iterator=$jscomp.global['Symbol']('iterator')}if(typeof Array.prototype[a]!='function'){$jscomp.defineProperty(Array.prototype,a,{configurable:!0,writable:!0,value:function(){return $jscomp.arrayIterator(this)}})}$jscomp.initSymbolIterator=function(){}};$jscomp.arrayIterator=function(a){var b=0;return $jscomp.iteratorPrototype(function(){if(bd){b=d}b=Number(b);if(b<0){b=Math.max(0,d+b)}for(var e=Number(c||0);e-0.25){var f=b;var g=1;var c=b;var d=0;var e=1;while(d!=c){f*=b;e*=-1;c=(d=c)+e*f/++g}return c}return Math.log(1+b)};return b},'es6-impl','es3');$jscomp.polyfill('Math.atanh',function(b){if(b){return b}var a=Math.log1p;var c=function(c){c=Number(c);return (a(c)-a(-c))/2};return c},'es6-impl','es3');$jscomp.polyfill('Math.cbrt',function(a){if(a){return a}var b=function(b){if(b===0){return b}b=Number(b);var c=Math.pow(Math.abs(b),1/3);return b<0?-c:c};return b},'es6-impl','es3');$jscomp.polyfill('Math.clz32',function(a){if(a){return a}var b=function(b){b=Number(b)>>>0;if(b===0){return 32}var c=0;if((b&4.29490176E9)===0){b<<=16;c+=16}if((b&4.27819008E9)===0){b<<=8;c+=8}if((b&4.02653184E9)===0){b<<=4;c+=4}if((b&3.221225472E9)===0){b<<=2;c+=2}if((b&2.147483648E9)===0){c++}return c};return b},'es6-impl','es3');$jscomp.polyfill('Math.cosh',function(a){if(a){return a}var b=Math.exp;var c=function(c){c=Number(c);return (b(c)+b(-c))/2};return c},'es6-impl','es3');$jscomp.polyfill('Math.expm1',function(a){if(a){return a}var b=function(b){b=Number(b);if(b<0.25&&b>-0.25){var e=b;var f=1;var c=b;var d=0;while(d!=c){e*=b/++f;c=(d=c)+e}return c}return Math.exp(b)-1};return b},'es6-impl','es3');$jscomp.polyfill('Math.hypot',function(a){if(a){return a}var b=function(c,d,h){c=Number(c);d=Number(d);var b,g,f;var e=Math.max(Math.abs(c),Math.abs(d));for(b=2;b1.0E100||e<1.0E-100){c=c/e;d=d/e;f=c*c+d*d;for(b=2;b>>16&65535;var d=b&65535;var g=c>>>16&65535;var e=c&65535;var h=f*e+d*g<<16>>>0;return d*e+h|0};return b},'es6-impl','es3');$jscomp.polyfill('Math.log10',function(a){if(a){return a}var b=function(b){return Math.log(b)/Math.LN10};return b},'es6-impl','es3');$jscomp.polyfill('Math.log2',function(a){if(a){return a}var b=function(b){return Math.log(b)/Math.LN2};return b},'es6-impl','es3');$jscomp.polyfill('Math.sign',function(a){if(a){return a}var b=function(b){b=Number(b);return b===0||isNaN(b)?b:b>0?1:-1};return b},'es6-impl','es3');$jscomp.polyfill('Math.sinh',function(a){if(a){return a}var b=Math.exp;var c=function(c){c=Number(c);if(c===0){return c}return (b(c)-b(-c))/2};return c},'es6-impl','es3');$jscomp.polyfill('Math.tanh',function(a){if(a){return a}var b=function(b){b=Number(b);if(b===0){return b}var c=Math.exp(-2*Math.abs(b));var d=(1-c)/(1+c);return b<0?-d:d};return b},'es6-impl','es3');$jscomp.polyfill('Math.trunc',function(a){if(a){return a}var b=function(b){b=Number(b);if(isNaN(b)||b===Infinity||b===-Infinity||b===0){return b}var c=Math.floor(Math.abs(b));return b<0?-c:c};return b},'es6-impl','es3');$jscomp.polyfill('Number.EPSILON',function(a){return Math.pow(2,-52)},'es6-impl','es3');$jscomp.polyfill('Number.MAX_SAFE_INTEGER',function(){return 9.007199254740991E15},'es6-impl','es3');$jscomp.polyfill('Number.MIN_SAFE_INTEGER',function(){return -9.007199254740991E15},'es6-impl','es3');$jscomp.polyfill('Number.isFinite',function(a){if(a){return a}var b=function(b){if(typeof b!=='number'){return !1}return !isNaN(b)&&b!==Infinity&&b!==-Infinity};return b},'es6-impl','es3');$jscomp.polyfill('Number.isInteger',function(a){if(a){return a}var b=function(b){if(!Number.isFinite(b)){return !1}return b===Math.floor(b)};return b},'es6-impl','es3');$jscomp.polyfill('Number.isNaN',function(a){if(a){return a}var b=function(b){return typeof b==='number'&&isNaN(b)};return b},'es6-impl','es3');$jscomp.polyfill('Number.isSafeInteger',function(a){if(a){return a}var b=function(b){return Number.isInteger(b)&&Math.abs(b)<=Number.MAX_SAFE_INTEGER};return b},'es6-impl','es3');$jscomp.polyfill('Object.assign',function(a){if(a){return a}var b=function(e,f){for(var d=1;d3?f:b,e);return !0}else {if(c.writable&&!Object.isFrozen(b)){b[d]=e;return !0}}return !1};return b},'es6','es5');$jscomp.polyfill('Reflect.setPrototypeOf',function(a){if(a){return a}if(typeof ''.__proto__!='object'){return null}var b=function(b,c){try{b.__proto__=c;return b.__proto__===c}catch(d){return !1}};return b},'es6','es5');$jscomp.ASSUME_NO_NATIVE_SET=!1;$jscomp.polyfill('Set',function(b){var c=!$jscomp.ASSUME_NO_NATIVE_SET&&function(){if(!b||!b.prototype.entries||typeof Object.seal!='function'){return !1}try{b=b;var d=Object.seal({x:4});var c=new b($jscomp.makeIterator([d]));if(!c.has(d)||c.size!=1||c.add(d)!=c||c.size!=1||c.add({x:4})!=c||c.size!=2){return !1}var e=c.entries();var a=e.next();if(a.done||a.value[0]!=d||a.value[1]!=d){return !1}a=e.next();if(a.done||a.value[0]==d||a.value[0].x!=4||a.value[1]!=a.value[0]){return !1}return e.next().done}catch(f){return !1}}();if(c){return b}$jscomp.initSymbol();$jscomp.initSymbolIterator();var a=function(a){this.map_=new Map();if(a){var e=$jscomp.makeIterator(a);var c;while(!(c=e.next()).done){var d=c.value;this.add(d)}}this.size=this.map_.size};a.prototype.add=function(a){this.map_.set(a,a);this.size=this.map_.size;return this};a.prototype['delete']=function(c){var a=this.map_['delete'](c);this.size=this.map_.size;return a};a.prototype.clear=function(){this.map_.clear();this.size=0};a.prototype.has=function(a){return this.map_.has(a)};a.prototype.entries=function(){return this.map_.entries()};a.prototype.values=function(){return this.map_.values()};a.prototype.keys=a.prototype.values;$jscomp.initSymbol();$jscomp.initSymbolIterator();a.prototype[Symbol.iterator]=a.prototype.values;a.prototype.forEach=function(c,a){var d=this;this.map_.forEach(function(e){return c.call(a,e,e,d)})};return a},'es6-impl','es3');$jscomp.checkStringArgs=function(a,c,b){if(a==null){throw new TypeError("The 'this' value for String.prototype."+b+' must not be null or undefined')}if(c instanceof RegExp){throw new TypeError('First argument to String.prototype.'+b+' must not be a regular expression')}return a+''};$jscomp.polyfill('String.prototype.codePointAt',function(a){if(a){return a}var b=function(b){var e=$jscomp.checkStringArgs(this,null,'codePointAt');var f=e.length;b=Number(b)||0;if(!(b>=0&&b56319||b+1===f){return c}var d=e.charCodeAt(b+1);if(d<56320||d>57343){return c}return (c-55296)*1024+d+9216};return b},'es6-impl','es3');$jscomp.polyfill('String.prototype.endsWith',function(a){if(a){return a}var b=function(b,c){var d=$jscomp.checkStringArgs(this,b,'endsWith');b=b+'';if(c===void 0){c=d.length}var f=Math.max(0,Math.min(c|0,d.length));var e=b.length;while(e>0&&f>0){if(d[--f]!=b[--e]){return !1}}return e<=0};return b},'es6-impl','es3');$jscomp.polyfill('String.fromCodePoint',function(a){if(a){return a}var b=function(e){var c='';for(var d=0;d1114111||b!==Math.floor(b)){throw new RangeError('invalid_code_point '+b)}if(b<=65535){c+=String.fromCharCode(b)}else {b-=65536;c+=String.fromCharCode(b>>>10&1023|55296);c+=String.fromCharCode(b&1023|56320)}}return c};return b},'es6-impl','es3');$jscomp.polyfill('String.prototype.includes',function(a){if(a){return a}var b=function(b,c){var d=$jscomp.checkStringArgs(this,b,'includes');return d.indexOf(b,c||0)!==-1};return b},'es6-impl','es3');$jscomp.polyfill('String.prototype.repeat',function(a){if(a){return a}var b=function(b){var c=$jscomp.checkStringArgs(this,null,'repeat');if(b<0||b>1342177279){throw new RangeError('Invalid count value')}b=b|0;var d='';while(b){if(b&1){d+=c}if(b>>>=1){c+=c}}return d};return b},'es6-impl','es3');$jscomp.stringPadding=function(c,a){var b=c!==undefined?String(c):' ';if(!(a>0)||!b){return ''}var d=Math.ceil(a/b.length);return b.repeat(d).substring(0,a)};$jscomp.polyfill('String.prototype.padEnd',function(a){if(a){return a}var b=function(d,c){var b=$jscomp.checkStringArgs(this,null,'padStart');var e=d-b.length;return b+$jscomp.stringPadding(c,e)};return b},'es8','es3');$jscomp.polyfill('String.prototype.padStart',function(a){if(a){return a}var b=function(d,c){var b=$jscomp.checkStringArgs(this,null,'padStart');var e=d-b.length;return $jscomp.stringPadding(c,e)+b};return b},'es8','es3');$jscomp.polyfill('String.prototype.startsWith',function(a){if(a){return a}var b=function(b,g){var c=$jscomp.checkStringArgs(this,b,'startsWith');b=b+'';var h=c.length;var e=b.length;var f=Math.max(0,Math.min(g|0,c.length));var d=0;while(d=e};return b},'es6-impl','es3');$jscomp.arrayFromIterator=function(c){var b;var a=[];while(!(b=c.next()).done){a.push(b.value)}return a};$jscomp.arrayFromIterable=function(a){if(a instanceof Array){return a}else {return $jscomp.arrayFromIterator($jscomp.makeIterator(a))}};$jscomp.inherits=function(a,b){function tempCtor(){}tempCtor.prototype=b.prototype;a.superClass_=b.prototype;a.prototype=new tempCtor();a.prototype.constructor=a;for(var c in b){if(Object.defineProperties){var d=Object.getOwnPropertyDescriptor(b,c);if(d){Object.defineProperty(a,c,d)}}else {a[c]=b[c]}}};$jscomp.polyfill('WeakSet',function(b){function isConformant(){if(!b||!Object.seal){return !1}try{var c=Object.seal({});var d=Object.seal({});var a=new b([c]);if(!a.has(c)||a.has(d)){return !1}a['delete'](c);a.add(d);return !a.has(c)&&a.has(d)}catch(e){return !1}}if(isConformant()){return b}var a=function(a){this.map_=new WeakMap();if(a){$jscomp.initSymbol();$jscomp.initSymbolIterator();var e=$jscomp.makeIterator(a);var c;while(!(c=e.next()).done){var d=c.value;this.add(d)}}};a.prototype.add=function(a){this.map_.set(a,!0);return this};a.prototype.has=function(a){return this.map_.has(a)};a.prototype['delete']=function(a){return this.map_['delete'](a)};return a},'es6-impl','es3');try{if(Array.prototype.values.toString().indexOf('[native code]')==-1){delete Array.prototype.values}}catch(a){}var Explorer=Explorer||{};if(!Explorer.model){Explorer.model={}}if(!Explorer.store){Explorer.store={}}if(!Explorer.view){Explorer.view={}}if(!Explorer.view.coadd){Explorer.view.coadd={}}if(!Explorer.view.main){Explorer.view.main={}}if(!Explorer.view.system){Explorer.view.system={}}var Ext=Ext||{};if(!Ext.Toolbar){Ext.Toolbar={}}if(!Ext.app){Ext.app={}}if(!Ext.app.bind){Ext.app.bind={}}if(!Ext.app.domain){Ext.app.domain={}}if(!Ext.app.route){Ext.app.route={}}if(!Ext.button){Ext.button={}}if(!Ext.chart){Ext.chart={}}if(!Ext.chart.axis){Ext.chart.axis={}}if(!Ext.chart.axis.layout){Ext.chart.axis.layout={}}if(!Ext.chart.axis.segmenter){Ext.chart.axis.segmenter={}}if(!Ext.chart.axis.sprite){Ext.chart.axis.sprite={}}if(!Ext.chart.grid){Ext.chart.grid={}}if(!Ext.chart.interactions){Ext.chart.interactions={}}if(!Ext.chart.label){Ext.chart.label={}}if(!Ext.chart.overrides){Ext.chart.overrides={}}if(!Ext.chart.plugin){Ext.chart.plugin={}}if(!Ext.chart.series){Ext.chart.series={}}if(!Ext.chart.series.sprite){Ext.chart.series.sprite={}}if(!Ext.chart.theme){Ext.chart.theme={}}if(!Ext.container){Ext.container={}}if(!Ext.core){Ext.core={}}if(!Ext.data){Ext.data={}}if(!Ext.data.field){Ext.data.field={}}if(!Ext.data.flash){Ext.data.flash={}}if(!Ext.data.identifier){Ext.data.identifier={}}if(!Ext.data.matrix){Ext.data.matrix={}}if(!Ext.data.operation){Ext.data.operation={}}if(!Ext.data.proxy){Ext.data.proxy={}}if(!Ext.data.reader){Ext.data.reader={}}if(!Ext.data.request){Ext.data.request={}}if(!Ext.data.schema){Ext.data.schema={}}if(!Ext.data.session){Ext.data.session={}}if(!Ext.data.validator){Ext.data.validator={}}if(!Ext.data.writer){Ext.data.writer={}}if(!Ext.dd){Ext.dd={}}if(!Ext.dom){Ext.dom={}}if(!Ext.dom.Element){Ext.dom.Element={}}if(!Ext.draw){Ext.draw={}}if(!Ext.draw.engine){Ext.draw.engine={}}if(!Ext.draw.engine.SvgContext){Ext.draw.engine.SvgContext={}}if(!Ext.draw.gradient){Ext.draw.gradient={}}if(!Ext.draw.modifier){Ext.draw.modifier={}}if(!Ext.draw.sprite){Ext.draw.sprite={}}if(!Ext.event){Ext.event={}}if(!Ext.event.gesture){Ext.event.gesture={}}if(!Ext.event.publisher){Ext.event.publisher={}}if(!Ext.form){Ext.form={}}if(!Ext.form.Action){Ext.form.Action={}}if(!Ext.form.action){Ext.form.action={}}if(!Ext.form.field){Ext.form.field={}}if(!Ext.form.trigger){Ext.form.trigger={}}if(!Ext.fx){Ext.fx={}}if(!Ext.fx.animation){Ext.fx.animation={}}if(!Ext.fx.easing){Ext.fx.easing={}}if(!Ext.fx.runner){Ext.fx.runner={}}if(!Ext.fx.target){Ext.fx.target={}}if(!Ext.grid){Ext.grid={}}if(!Ext.grid.column){Ext.grid.column={}}if(!Ext.grid.header){Ext.grid.header={}}if(!Ext.grid.locking){Ext.grid.locking={}}if(!Ext.grid.plugin){Ext.grid.plugin={}}if(!Ext.layout){Ext.layout={}}if(!Ext.layout.boxOverflow){Ext.layout.boxOverflow={}}if(!Ext.layout.component){Ext.layout.component={}}if(!Ext.layout.component.field){Ext.layout.component.field={}}if(!Ext.layout.container){Ext.layout.container={}}if(!Ext.layout.container.border){Ext.layout.container.border={}}if(!Ext.layout.container.boxOverflow){Ext.layout.container.boxOverflow={}}if(!Ext.list){Ext.list={}}if(!Ext.menu){Ext.menu={}}if(!Ext.mixin){Ext.mixin={}}if(!Ext.overrides){Ext.overrides={}}if(!Ext.overrides.app){Ext.overrides.app={}}if(!Ext.overrides.app.domain){Ext.overrides.app.domain={}}if(!Ext.overrides.dom){Ext.overrides.dom={}}if(!Ext.overrides.event){Ext.overrides.event={}}if(!Ext.overrides.event.publisher){Ext.overrides.event.publisher={}}if(!Ext.overrides.plugin){Ext.overrides.plugin={}}if(!Ext.overrides.util){Ext.overrides.util={}}if(!Ext.panel){Ext.panel={}}if(!Ext.perf){Ext.perf={}}if(!Ext.plugin){Ext.plugin={}}if(!Ext.promise){Ext.promise={}}if(!Ext.resizer){Ext.resizer={}}if(!Ext.scroll){Ext.scroll={}}if(!Ext.selection){Ext.selection={}}if(!Ext.state){Ext.state={}}if(!Ext.tab){Ext.tab={}}if(!Ext.theme){Ext.theme={}}if(!Ext.theme.crisp){Ext.theme.crisp={}}if(!Ext.theme.crisp.view){Ext.theme.crisp.view={}}if(!Ext.theme.neptune){Ext.theme.neptune={}}if(!Ext.theme.neptune.container){Ext.theme.neptune.container={}}if(!Ext.theme.neptune.grid){Ext.theme.neptune.grid={}}if(!Ext.theme.neptune.grid.column){Ext.theme.neptune.grid.column={}}if(!Ext.theme.neptune.layout){Ext.theme.neptune.layout={}}if(!Ext.theme.neptune.layout.component){Ext.theme.neptune.layout.component={}}if(!Ext.theme.neptune.menu){Ext.theme.neptune.menu={}}if(!Ext.theme.neptune.panel){Ext.theme.neptune.panel={}}if(!Ext.theme.neptune.resizer){Ext.theme.neptune.resizer={}}if(!Ext.theme.neptune.toolbar){Ext.theme.neptune.toolbar={}}if(!Ext.tip){Ext.tip={}}if(!Ext.toolbar){Ext.toolbar={}}if(!Ext.tree){Ext.tree={}}if(!Ext.util){Ext.util={}}if(!Ext.util.paintmonitor){Ext.util.paintmonitor={}}if(!Ext.util.sizemonitor){Ext.util.sizemonitor={}}if(!Ext.util.translatable){Ext.util.translatable={}}if(!Ext.ux){Ext.ux={}}if(!Ext.ux.colorpick){Ext.ux.colorpick={}}if(!Ext.ux.layout){Ext.ux.layout={}}if(!Ext.ux.rating){Ext.ux.rating={}}if(!Ext.view){Ext.view={}}if(!Ext.window){Ext.window={}}var Portal=Portal||{};var aladin=aladin||{};if(!aladin.maps){aladin.maps={}}if(!aladin.model){aladin.model={}}if(!aladin.store){aladin.store={}}var common=common||{};if(!common.contact){common.contact={}}if(!common.data){common.data={}}if(!common.data.proxy){common.data.proxy={}}if(!common.footer){common.footer={}}if(!common.header){common.header={}}if(!common.help){common.help={}}if(!common.model){common.model={}}if(!common.store){common.store={}}var visiomatic=visiomatic||{};if(!visiomatic.catalog){visiomatic.catalog={}}if(!visiomatic.crop){visiomatic.crop={}}if(!visiomatic.download){visiomatic.download={}}if(!visiomatic.filter){visiomatic.filter={}}if(!visiomatic.model){visiomatic.model={}}if(!visiomatic.store){visiomatic.store={}}(function(q){var e,p=['constructor','toString','valueOf','toLocaleString'],n={},m={},k=0,l,j,a,b,o,f,c,d,g,h,i,t=function(){var s,t;j=Ext.Base;a=Ext.ClassManager;b=Ext.Class;for(s=p.length;s-->0;){t=1<0;){H=e[l];g[H]=j[H]}if(c.$isFunction){c=c(g)}v.data=c;x=c.statics;delete c.statics;c.$className=u;if('$className' in c){g.$className=c.$className}g.extend(Q);r=g.prototype;if(E){g.xtype=c.xtype=E[0];r.xtypes=E}r.xtypesChain=M;r.xtypesMap=O;c.alias=B;m.triggerExtended(g,c,v);if(c.onClassExtended){g.onExtended(c.onClassExtended,g);delete c.onClassExtended}if(c.privates&&h){h.call(b,g,c)}if(x){if(i){g.addStatics(x)}else {for(w in x){if(x.hasOwnProperty(w)){t=x[w];if(t&&t.$isFunction&&!t.$isClass&&t!==Ext.emptyFn&&t!==Ext.identityFn){g[w]=I=t;I.$owner=g;I.$name=w}g[w]=t}}}}if(c.inheritableStatics){g.addInheritableStatics(c.inheritableStatics);delete c.inheritableStatics}if(r.onClassExtended){m.onExtended(r.onClassExtended,m);delete r.onClassExtended}if(c.platformConfig&&d){d.call(b,g,c);delete c.platformConfig}if(c.config){o.call(b,g,c)}if(c.cachedConfig&&f){f.call(b,g,c);delete c.cachedConfig}v.onBeforeCreated(g,v.data,v);for(l=0,y=D&&D.length;l0){c--;a[c]='var Ext=window.'+Ext.name+';'+a[c]}}d=a.join('');b=e[d];if(!b){b=Function.prototype.constructor.apply(Function.prototype,a);e[d]=b}return b},functionFactory:function(){var b=Array.prototype.slice.call(arguments),a;if(Ext.isSandboxed){a=b.length;if(a>0){a--;b[a]='var Ext=window.'+Ext.name+';'+b[a]}}return Function.prototype.constructor.apply(Function.prototype,b)},Logger:{verbose:a,log:a,info:a,warn:a,error:function(a){throw new Error(a)},deprecate:a},getElementById:function(a){return document.getElementById(a)},splitAndUnescape:function(){var a={};return function(e,c){if(!e){return []}else {if(!c){return [e]}}var g=a[c]||(a[c]=new RegExp('\\\\'+c,'g')),f=[],d,b;d=e.split(c);while((b=d.shift())!==undefined){while(b.charAt(b.length-1)==='\\'&&d.length>0){b=b+c+d.shift()}b=b.replace(g,c);f.push(b)}return f}}()});Ext.returnTrue.$nullFn=Ext.returnId.$nullFn=!0})();Ext.platformTags.modern=!(Ext.platformTags.classic=Ext.isClassic=!0);(function(){function toString(){var d=this,b=d.sourceClass,a=d.sourceMethod,c=d.msg;if(a){if(c){a+='(): ';a+=c}else {a+='()'}}if(b){a=a?b+'.'+a:b}return a||c||''}Ext.Error=function(b){if(Ext.isString(b)){b={msg:b}}var a=new Error();Ext.apply(a,b);a.message=a.message||a.msg;a.toString=toString;return a};Ext.apply(Ext.Error,{ignore:!1,raise:function(a){a=a||{};if(Ext.isString(a)){a={msg:a}}var d=this,b=d.raise.caller,e,c;if(b===Ext.raise){b=b.caller}if(b){if(!a.sourceMethod&&(c=b.$name)){a.sourceMethod=c}if(!a.sourceClass&&(c=b.$owner)&&(c=c.$className)){a.sourceClass=c}}if(d.handle(a)!==!0){e=toString.call(a);throw new Ext.Error(a)}},handle:function(){return this.ignore}})})();Ext.deprecated=function(a){return Ext.emptyFn};Ext.raise=function(){Ext.Error.raise.apply(Ext.Error,arguments)};Ext.Array=function(){var c=Array.prototype,b=c.slice,f=function(){var a=[],b,c=20;if(!a.splice){return !1}while(c--){a.push('A')}a.splice(15,0,'F','F','F','F','F','F','F','F','F','F','F','F','F','F','F','F','F','F','F','F','F');b=a.length;a.splice(13,0,'XXX');if(b+1!==a.length){return !1}return !0}(),i='indexOf' in c,h=!0;function stableSort(b,e){var d=b.length,c=new Array(d),a;for(a=0;ac){for(b=l;b--;){a[h+b]=a[c+b]}}}if(e&&f===j){a.length=j;a.push.apply(a,d)}else {a.length=j+e;for(b=0;b>1;f=d(i,h[e]);if(f>=0){c=e+1}else {if(f<0){b=e-1}}}return c},defaultCompare:function(a,b){return ab?1:0},lexicalCompare:function(a,b){a=String(a);b=String(b);return ab?1:0},each:function(c,e,d,g){c=a.from(c);var b,f=c.length;if(g!==!0){for(b=0;b-1;b--){if(e.call(d||c[b],c[b],b,c)===!1){return b}}}return !0},forEach:'forEach' in c?function(a,c,b){return a.forEach(c,b)}:function(b,d,c){for(var a=0,e=b.length;a=0&&b>>0,c=e;if(arguments.length<3){while(!0){if(b in a){c=a[b++];break}if(++b>=d){throw new TypeError('Reduce of empty array with no initial value')}}}for(;bb){b=a}}}return b},mean:function(b){return b.length>0?a.sum(b)/b.length:undefined},sum:function(b){var d=0,a,e,c;for(a=0,e=b.length;ab?1:-1,a;for(a=b;a!=d;a+=e){c[a]=c[a+e]}c[d]=f},replace:j,splice:p,push:function(a){var d=arguments.length,c=1,b;if(a===undefined){a=[]}else {if(!Ext.isArray(a)){a=[a]}}for(;c=d){a=0}else {a=d-a}}if(a===0){b=c+b}else {if(a>=b.length){b+=c}else {b=b.substr(0,a)+c+b.substr(a)}}return b},startsWith:function(b,a,d){var c=e(b,a);if(c){if(d){b=b.toLowerCase();a=a.toLowerCase()}c=b.lastIndexOf(a,0)===0}return c},endsWith:function(b,a,d){var c=e(b,a);if(c){if(d){b=b.toLowerCase();a=a.toLowerCase()}c=b.indexOf(a,b.length-a.length)!==-1}return c},createVarName:function(a){return a.replace(l,'')},htmlEncode:function(a){return !a?a:String(a).replace(b,h)},htmlDecode:function(a){return !a?a:String(a).replace(d,g)},hasHtmlCharacters:function(a){return b.test(a)},addCharacterEntities:function(g){var i=[],h=[],e,f;for(e in g){f=g[e];a[e]=f;c[f]=e;i.push(f);h.push(e)}b=new RegExp('('+i.join('|')+')','g');d=new RegExp('('+h.join('|')+'|&#[0-9]{1,5};)','g')},resetCharacterEntities:function(){c={};a={};this.addCharacterEntities({'&':'&','>':'>','<':'<','"':'"',''':"'"})},urlAppend:function(a,b){if(!Ext.isEmpty(b)){return a+(a.indexOf('?')===-1?'?':'&')+b}return a},trim:function(a){if(a){a=a.replace(m,'')}return a||''},capitalize:function(a){if(a){a=a.charAt(0).toUpperCase()+a.substr(1)}return a||''},uncapitalize:function(a){if(a){a=a.charAt(0).toLowerCase()+a.substr(1)}return a||''},ellipsis:function(a,c,e){if(a&&a.length>c){if(e){var b=a.substr(0,c-2),d=Math.max(b.lastIndexOf(' '),b.lastIndexOf('.'),b.lastIndexOf('!'),b.lastIndexOf('?'));if(d!==-1&&d>=c-15){return b.substr(0,d)+'...'}}return a.substr(0,c-3)+'...'}return a},escapeRegex:function(a){return a.replace(i,'\\$1')},createRegex:function(b,d,e,c){var a=b;if(b!=null&&!b.exec){a=f.escapeRegex(String(b));if(d!==!1){a='^'+a}if(e!==!1){a+='$'}a=new RegExp(a,c!==!1?'i':'')}return a},escape:function(a){return a.replace(n,'\\$1')},toggle:function(b,a,c){return b===a?c:a},leftPad:function(c,d,b){var a=String(c);b=b||' ';while(a.length daysInMonth) {','d = daysInMonth;','}','}','h = from(h, from(def.h, dt.getHours()));','i = from(i, from(def.i, dt.getMinutes()));','s = from(s, from(def.s, dt.getSeconds()));','ms = from(ms, from(def.ms, dt.getMilliseconds()));','if(z >= 0 && y >= 0){','v = me.add(new Date(y < 100 ? 100 : y, 0, 1, h, i, s, ms), me.YEAR, y < 100 ? y - 100 : 0);','v = !strict? v : (strict === true && (z <= 364 || (me.isLeapYear(v) && z <= 365))? me.add(v, me.DAY, z) : null);','}else if(strict === true && !me.isValid(y, m + 1, d, h, i, s, ms)){','v = null;','}else{','if (W) {','year = y || (new Date()).getFullYear();','jan4 = new Date(year, 0, 4, 0, 0, 0);','d = jan4.getDay();','week1monday = new Date(jan4.getTime() - ((d === 0 ? 6 : d - 1) * 86400000));','v = Ext.Date.clearTime(new Date(week1monday.getTime() + ((W - 1) * 604800000 + 43200000)));','} else {','v = me.add(new Date(y < 100 ? 100 : y, m, d, h, i, s, ms), me.YEAR, y < 100 ? y - 100 : 0);','}','}','}','}','if(v){','if(zz != null){','v = me.add(v, me.SECOND, -v.getTimezoneOffset() * 60 - zz);','}else if(o){',"v = me.add(v, me.MINUTE, -v.getTimezoneOffset() + (sn == '+'? -1 : 1) * (hr * 60 + mn));",'}','}','return (v != null) ? v : null;'].join('\n');if(!Date.prototype.toISOString){Date.prototype.toISOString=function(){var a=this;return c(a.getUTCFullYear(),4,'0')+'-'+c(a.getUTCMonth()+1,2,'0')+'-'+c(a.getUTCDate(),2,'0')+'T'+c(a.getUTCHours(),2,'0')+':'+c(a.getUTCMinutes(),2,'0')+':'+c(a.getUTCSeconds(),2,'0')+'.'+c(a.getUTCMilliseconds(),3,'0')+'Z'}}function xf(a){var b=Array.prototype.slice.call(arguments,1);return a.replace(e,function(d,c){return b[c]})}return a={now:b.now,toString:function(a){if(!a){a=new b()}return a.getFullYear()+'-'+c(a.getMonth()+1,2,'0')+'-'+c(a.getDate(),2,'0')+'T'+c(a.getHours(),2,'0')+':'+c(a.getMinutes(),2,'0')+':'+c(a.getSeconds(),2,'0')},getElapsed:function(b,c){return Math.abs(b-(c||a.now()))},useStrict:!1,formatCodeToRegex:function(c,d){var b=a.parseCodes[c];if(b){b=typeof b==='function'?b():b;a.parseCodes[c]=b}return b?Ext.applyIf({c:b.c?xf(b.c,d||'{0}'):b.c},b):{g:0,c:null,s:Ext.String.escapeRegex(c)}},parseFunctions:{'MS':function(c,d){var a=(c||'').match(f);return a?new b(((a[1]||'')+a[2])*1):null},'time':function(c,d){var a=parseInt(c,10);if(a||a===0){return new b(a)}return null},'timestamp':function(c,d){var a=parseInt(c,10);if(a||a===0){return new b(a*1000)}return null}},parseRegexes:[],formatFunctions:{'MS':function(){return '\\/Date('+this.getTime()+')\\/'},'time':function(){return this.getTime().toString()},'timestamp':function(){return a.format(this,'U')}},y2kYear:50,MILLI:'ms',SECOND:'s',MINUTE:'mi',HOUR:'h',DAY:'d',MONTH:'mo',YEAR:'y',defaults:{},dayNames:['Sunday','Monday','Tuesday','Wednesday','Thursday','Friday','Saturday'],monthNames:['January','February','March','April','May','June','July','August','September','October','November','December'],monthNumbers:{January:0,Jan:0,February:1,Feb:1,March:2,Mar:2,April:3,Apr:3,May:4,June:5,Jun:5,July:6,Jul:6,August:7,Aug:7,September:8,Sep:8,October:9,Oct:9,November:10,Nov:10,December:11,Dec:11},defaultFormat:'m/d/Y',getShortMonthName:function(b){return a.monthNames[b].substring(0,3)},getShortDayName:function(b){return a.dayNames[b].substring(0,3)},getMonthNumber:function(b){return a.monthNumbers[b.substring(0,1).toUpperCase()+b.substring(1,3).toLowerCase()]},formatContainsHourInfo:function(a){return h.test(a.replace(d,''))},formatContainsDateInfo:function(a){return g.test(a.replace(d,''))},unescapeFormat:function(a){return a.replace(i,'')},formatCodes:{d:"Ext.String.leftPad(m.getDate(), 2, '0')",D:'Ext.Date.getShortDayName(m.getDay())',j:'m.getDate()',l:'Ext.Date.dayNames[m.getDay()]',N:'(m.getDay() ? m.getDay() : 7)',S:'Ext.Date.getSuffix(m)',w:'m.getDay()',z:'Ext.Date.getDayOfYear(m)',W:"Ext.String.leftPad(Ext.Date.getWeekOfYear(m), 2, '0')",F:'Ext.Date.monthNames[m.getMonth()]',m:"Ext.String.leftPad(m.getMonth() + 1, 2, '0')",M:'Ext.Date.getShortMonthName(m.getMonth())',n:'(m.getMonth() + 1)',t:'Ext.Date.getDaysInMonth(m)',L:'(Ext.Date.isLeapYear(m) ? 1 : 0)',o:'(m.getFullYear() + (Ext.Date.getWeekOfYear(m) == 1 && m.getMonth() > 0 ? +1 : (Ext.Date.getWeekOfYear(m) >= 52 && m.getMonth() < 11 ? -1 : 0)))',Y:"Ext.String.leftPad(m.getFullYear(), 4, '0')",y:"('' + m.getFullYear()).substring(2, 4)",a:"(m.getHours() < 12 ? 'am' : 'pm')",A:"(m.getHours() < 12 ? 'AM' : 'PM')",g:'((m.getHours() % 12) ? m.getHours() % 12 : 12)',G:'m.getHours()',h:"Ext.String.leftPad((m.getHours() % 12) ? m.getHours() % 12 : 12, 2, '0')",H:"Ext.String.leftPad(m.getHours(), 2, '0')",i:"Ext.String.leftPad(m.getMinutes(), 2, '0')",s:"Ext.String.leftPad(m.getSeconds(), 2, '0')",u:"Ext.String.leftPad(m.getMilliseconds(), 3, '0')",O:'Ext.Date.getGMTOffset(m)',P:'Ext.Date.getGMTOffset(m, true)',T:'Ext.Date.getTimezone(m)',Z:'(m.getTimezoneOffset() * -60)',c:function(){var e='Y-m-dTH:i:sP',d=[],b,f=e.length,c;for(b=0;b me.y2kYear ? 1900 + ty : 2000 + ty;\n',s:'(\\d{2})'},a:{g:1,c:'if (/(am)/i.test(results[{0}])) {\nif (!h || h == 12) { h = 0; }\n} else { if (!h || h < 12) { h = (h || 0) + 12; }}',s:'(am|pm|AM|PM)',calcAtEnd:!0},A:{g:1,c:'if (/(am)/i.test(results[{0}])) {\nif (!h || h == 12) { h = 0; }\n} else { if (!h || h < 12) { h = (h || 0) + 12; }}',s:'(AM|PM|am|pm)',calcAtEnd:!0},g:{g:1,c:'h = parseInt(results[{0}], 10);\n',s:'(1[0-2]|[0-9])'},G:{g:1,c:'h = parseInt(results[{0}], 10);\n',s:'(2[0-3]|1[0-9]|[0-9])'},h:{g:1,c:'h = parseInt(results[{0}], 10);\n',s:'(1[0-2]|0[1-9])'},H:{g:1,c:'h = parseInt(results[{0}], 10);\n',s:'(2[0-3]|[0-1][0-9])'},i:{g:1,c:'i = parseInt(results[{0}], 10);\n',s:'([0-5][0-9])'},s:{g:1,c:'s = parseInt(results[{0}], 10);\n',s:'([0-5][0-9])'},u:{g:1,c:'ms = results[{0}]; ms = parseInt(ms, 10)/Math.pow(10, ms.length - 3);\n',s:'(\\d+)'},O:{g:1,c:['o = results[{0}];','var sn = o.substring(0,1),','hr = o.substring(1,3)*1 + Math.floor(o.substring(3,5) / 60),','mn = o.substring(3,5) % 60;',"o = ((-12 <= (hr*60 + mn)/60) && ((hr*60 + mn)/60 <= 14))? (sn + Ext.String.leftPad(hr, 2, '0') + Ext.String.leftPad(mn, 2, '0')) : null;\n"].join('\n'),s:'([+-]\\d{4})'},P:{g:1,c:['o = results[{0}];','var sn = o.substring(0,1),','hr = o.substring(1,3)*1 + Math.floor(o.substring(4,6) / 60),','mn = o.substring(4,6) % 60;',"o = ((-12 <= (hr*60 + mn)/60) && ((hr*60 + mn)/60 <= 14))? (sn + Ext.String.leftPad(hr, 2, '0') + Ext.String.leftPad(mn, 2, '0')) : null;\n"].join('\n'),s:'([+-]\\d{2}:\\d{2})'},T:{g:0,c:null,s:'[A-Z]{1,5}'},Z:{g:1,c:'zz = results[{0}] * 1;\nzz = (-43200 <= zz && zz <= 50400)? zz : null;\n',s:'([+-]?\\d{1,5})'},c:function(){var d=[],b=[a.formatCodeToRegex('Y',1),a.formatCodeToRegex('m',2),a.formatCodeToRegex('d',3),a.formatCodeToRegex('H',4),a.formatCodeToRegex('i',5),a.formatCodeToRegex('s',6),{c:"ms = results[7] || '0'; ms = parseInt(ms, 10)/Math.pow(10, ms.length - 3);\n"},{c:['if(results[8]) {',"if(results[8] == 'Z'){",'zz = 0;',"}else if (results[8].indexOf(':') > -1){",a.formatCodeToRegex('P',8).c,'}else{',a.formatCodeToRegex('O',8).c,'}','}'].join('\n')}],c,e;for(c=0,e=b.length;c0?'-':'+')+Ext.String.leftPad(Math.floor(Math.abs(a)/60),2,'0')+(b?':':'')+Ext.String.leftPad(Math.abs(a%60),2,'0')},getDayOfYear:function(c){var e=0,b=a.clone(c),f=c.getMonth(),d;for(d=0,b.setDate(1),b.setMonth(0);d28){d=Math.min(d,a.getLastDateOfMonth(a.add(a.getFirstDateOfMonth(f),a.MONTH,c)).getDate())};b.setDate(d);b.setMonth(f.getMonth()+c);break;case a.YEAR:d=f.getDate();if(d>28){d=Math.min(d,a.getLastDateOfMonth(a.add(a.getFirstDateOfMonth(f),a.YEAR,c)).getDate())};b.setDate(d);b.setFullYear(f.getFullYear()+c);break;}}if(g){switch(h.toLowerCase()){case a.MILLI:e=1;break;case a.SECOND:e=1000;break;case a.MINUTE:e=1000*60;break;case a.HOUR:e=1000*60*60;break;case a.DAY:e=1000*60*60*24;break;case a.MONTH:d=a.getDaysInMonth(b);e=1000*60*60*24*d;break;case a.YEAR:d=a.isLeapYear(b)?366:365;e=1000*60*60*24*d;break;}if(e){b.setTime(b.getTime()+e*g)}}return b},subtract:function(d,b,c){return a.add(d,b,-c)},between:function(c,b,d){var a=c.getTime();return b.getTime()<=a&&a<=d.getTime()},compat:function(){var c,g=['useStrict','formatCodeToRegex','parseFunctions','parseRegexes','formatFunctions','y2kYear','MILLI','SECOND','MINUTE','HOUR','DAY','MONTH','YEAR','defaults','dayNames','monthNames','monthNumbers','getShortMonthName','getShortDayName','getMonthNumber','formatCodes','isValid','parseDate','getFormatCode','createFormat','createParser','parseCodes'],h=['dateFormat','format','getTimezone','getGMTOffset','getDayOfYear','getWeekOfYear','isLeapYear','getFirstDayOfMonth','getLastDayOfMonth','getDaysInMonth','getSuffix','clone','isDST','clearTime','add','between'],j=g.length,i=h.length,f,e,d;for(d=0;dd){return b-1};return b;case a.YEAR:b=d.getFullYear()-e.getFullYear();if(a.add(e,f,b)>d){return b-1}else {return b};}},align:function(e,f,d){var c=new b(+e);switch(f.toLowerCase()){case a.MILLI:return c;case a.SECOND:c.setUTCSeconds(c.getUTCSeconds()-c.getUTCSeconds()%d);c.setUTCMilliseconds(0);return c;case a.MINUTE:c.setUTCMinutes(c.getUTCMinutes()-c.getUTCMinutes()%d);c.setUTCSeconds(0);c.setUTCMilliseconds(0);return c;case a.HOUR:c.setUTCHours(c.getUTCHours()-c.getUTCHours()%d);c.setUTCMinutes(0);c.setUTCSeconds(0);c.setUTCMilliseconds(0);return c;case a.DAY:if(d===7||d===14){c.setUTCDate(c.getUTCDate()-c.getUTCDay()+1)};c.setUTCHours(0);c.setUTCMinutes(0);c.setUTCSeconds(0);c.setUTCMilliseconds(0);return c;case a.MONTH:c.setUTCMonth(c.getUTCMonth()-(c.getUTCMonth()-1)%d,1);c.setUTCHours(0);c.setUTCMinutes(0);c.setUTCSeconds(0);c.setUTCMilliseconds(0);return c;case a.YEAR:c.setUTCFullYear(c.getUTCFullYear()-c.getUTCFullYear()%d,1,1);c.setUTCHours(0);c.setUTCMinutes(0);c.setUTCSeconds(0);c.setUTCMilliseconds(0);return e;}}}}();Ext.Function=function(){var i=0,f,c=[],l=[],m=0,e={},d=window,b=Ext.global,h=!!(b.setImmediate&&b.clearImmediate),k=d.requestAnimationFrame||d.webkitRequestAnimationFrame||d.mozRequestAnimationFrame||d.oRequestAnimationFrame||function(c){var b=Ext.now(),a=Math.max(0,16-(b-i)),e=d.setTimeout(function(){c(b+a)},a);i=b+a;return e},g=function(){var h=c.length,g,d,a;f=null;for(d=0;d0){return setTimeout(function(){if(Ext.elevateFunction){Ext.elevateFunction(a)}else {a()}},b)}a();return 0},interval:function(a,c,d,e,b){a=Ext.Function.bind(a,d,e,b);return setInterval(function(){if(Ext.elevateFunction){Ext.elevateFunction(a)}else {a()}},c)},createSequence:function(a,b,c){if(!b){return a}else {return function(){var d=a.apply(this,arguments);b.apply(c||this,arguments);return d}}},createBuffered:function(b,c,d,e){var a;return function(){var f=e||Array.prototype.slice.call(arguments,0),g=d||this;if(a){clearTimeout(a)}a=setTimeout(function(){if(Ext.elevateFunction){Ext.elevateFunction(b,g,f)}else {b.apply(g,f)}},c)}},createAnimationFrame:function(f,d,e,c){var b;c=c||3;return function(){var g=e||Array.prototype.slice.call(arguments,0);d=d||this;if(c===3&&b){a.cancelAnimationFrame(b)}if(c&1||!b){b=a.requestAnimationFrame(function(){b=null;f.apply(d,g)})}}},requestAnimationFrame:function(i,d,h){var a=++m,b=Array.prototype.slice.call(arguments,0);b[3]=a;e[a]=1;c.push(b);if(!f){f=k(Ext.elevateFunction?j:g)}return a},cancelAnimationFrame:function(a){delete e[a]},createThrottled:function(h,f,a){var e=0,d,c,b,g=function(){if(Ext.elevateFunction){Ext.elevateFunction(h,a,c)}else {h.apply(a,c)}e=Ext.now();b=null};return function(){if(!a){a=this}d=Ext.now()-e;c=arguments;if(d>=f){clearTimeout(b);g()}else {if(!b){b=Ext.defer(g,f-d)}}}},createBarrier:function(a,c,b){return function(){if(!--a){c.apply(b,arguments)}}},interceptBefore:function(b,a,e,d){var c=b[a]||Ext.emptyFn;return b[a]=function(){var f=e.apply(d||this,arguments);c.apply(this,arguments);return f}},interceptAfter:function(b,a,e,d){var c=b[a]||Ext.emptyFn;return b[a]=function(){c.apply(this,arguments);return e.apply(d||this,arguments)}},makeCallback:function(b,a){return function(){return a[b].apply(a,arguments)}},memoize:function(e,c,a){var b={},d=a&&Ext.isFunction(a);return function(g){var f=d?a.apply(c,arguments):g;if(!(f in b)){b[f]=e.apply(c,arguments)}return b[f]}}};Ext.asap=h?function(b,d,c){if(d!=null||c!=null){b=a.bind(b,d,c)}return setImmediate(function(){if(Ext.elevateFunction){Ext.elevateFunction(b)}else {b()}})}:function(b,d,c){if(d!=null||c!=null){b=a.bind(b,d,c)}return setTimeout(function(){if(Ext.elevateFunction){Ext.elevateFunction(b)}else {b()}},0,!0)},Ext.asapCancel=h?function(a){clearImmediate(a)}:function(a){clearTimeout(a)};Ext.defer=a.defer;Ext.interval=a.interval;Ext.pass=a.pass;Ext.bind=a.bind;Ext.deferCallback=a.requestAnimationFrame;return a}();Ext.Number=new function(){var b=this,d=(0.9).toFixed()!=='1',c=Math,a={count:!1,inclusive:!1,wrap:!0};Ext.apply(b,{Clip:{DEFAULT:a,COUNT:Ext.applyIf({count:!0},a),INCLUSIVE:Ext.applyIf({inclusive:!0},a),NOWRAP:Ext.applyIf({wrap:!1},a)},clipIndices:function(d,c,f){f=f||a;var h=0,i=f.wrap,g,b,e;c=c||[];for(e=0;e<2;++e){g=b;b=c[e];if(b==null){b=h}else {if(e&&f.count){b+=g;b=b>d?d:b}else {if(i){b=b<0?d+b:b}if(e&&f.inclusive){++b}b=b<0?0:b>d?d:b}}h=d}c[0]=g;c[1]=ba?a:d},snap:function(a,c,e,f){var d;if(a===undefined||a=c){a+=c}else {if(d*2<-c){a-=c}}}}return b.constrain(a,e,f)},snapInRange:function(a,d,c,e){var f;c=c||0;if(a===undefined||a=d){a+=d}}if(e!==undefined){if(a>(e=b.snapInRange(e,d,c))){a=e}}return a},sign:function(a){a=+a;if(a===0||isNaN(a)){return a}return a>0?1:-1},toFixed:d?function(d,a){a=a||0;var b=c.pow(10,a);return (c.round(d*b)/b).toFixed(a)}:function(b,a){return b.toFixed(a)},from:function(a,b){if(isFinite(a)){a=parseFloat(a)}return !isNaN(a)?a:b},randomInt:function(a,b){return c.floor(c.random()*(b-a+1)+a)},correctFloat:function(a){return parseFloat(a.toPrecision(14))}});Ext.num=function(){return b.from.apply(this,arguments)}}();(function(){var b=function(){},d=/^\?/,f=/(\[):?([^\]]*)\]/g,e=/^([^\[]+)/,c=/\+/g,a=Ext.Object={chain:Object.create||function(a){b.prototype=a;var c=new b();b.prototype=null;return c},clear:function(a){for(var b in a){delete a[b]}return a},freeze:Object.freeze?function(b,c){if(b&&typeof b==='object'&&!Object.isFrozen(b)){Object.freeze(b);if(c){for(var d in b){a.freeze(b[d],c)}}}return b}:Ext.identityFn,toQueryObjects:function(e,c,f){var g=a.toQueryObjects,d=[],b,h;if(Ext.isArray(c)){for(b=0,h=c.length;b0){o=q.split('=');a=o[0];a=a.replace(c,'%20');a=decodeURIComponent(a);g=o[1];if(g!==undefined){g=g.replace(c,'%20');g=decodeURIComponent(g)}else {g=''}if(!v){if(i.hasOwnProperty(a)){if(!Ext.isArray(i[a])){i[a]=[i[a]]}i[a].push(g)}else {i[a]=g}}else {m=a.match(f);r=a.match(e);a=r[0];k=[];if(m===null){i[a]=g;continue}for(h=0,l=m.length;h@:]*)(?:[@]([^<>@:]+))?[>](.+)$/,resolveResource:function(b){var c=b,a;if(b&&b.charAt(0)==='<'){a=Ext._resourcePoolRe.exec(b);if(a){c=Ext.getResourcePath(a[3],a[1],a[2])}}return c},urlEncode:function(){var a=Ext.Array.from(arguments),b='';if(Ext.isString(a[1])){b=a[1]+'&';a[1]=!1}return b+Ext.Object.toQueryString.apply(Ext.Object,a)},urlDecode:function(){return Ext.Object.fromQueryString.apply(Ext.Object,arguments)},getScrollbarSize:function(d){var b=Ext._scrollbarSize;if(d||!b){var c=document.body,a=document.createElement('div');a.style.width=a.style.height='100px';a.style.overflow='scroll';a.style.position='absolute';c.appendChild(a);Ext._scrollbarSize=b={width:a.offsetWidth-a.clientWidth,height:a.offsetHeight-a.clientHeight};c.removeChild(a)}return b},typeOf:function(){var a=/\S/,d=Object.prototype.toString,c={number:1,string:1,'boolean':1,'undefined':1},b={'[object Array]':'array','[object Date]':'date','[object Boolean]':'boolean','[object Number]':'number','[object RegExp]':'regexp'};return function(e){if(e===null){return 'null'}var f=typeof e,g,h;if(c[f]){return f}g=b[h=d.call(e)];if(g){return g}if(f==='function'){return 'function'}if(f==='object'){if(e.nodeType!==undefined){if(e.nodeType===3){return a.test(e.nodeValue)?'textnode':'whitespace'}else {return 'element'}}return 'object'}return h}}(),factory:function(a,f,b,d){var e=Ext.ClassManager,c;if(!a||a.isInstance){if(b&&b!==a){b.destroy()}return a}if(d){if(typeof a==='string'){return e.instantiateByAlias(d+'.'+a)}else {if(Ext.isObject(a)&&'type' in a){return e.instantiateByAlias(d+'.'+a.type,a)}}}if(a===!0){return b||Ext.create(f)}if('xtype' in a){c=e.instantiateByAlias('widget.'+a.xtype,a)}else {if('xclass' in a){c=Ext.create(a.xclass,a)}}if(c){if(b){b.destroy()}return c}if(b){return b.setConfig(a)}return Ext.create(f,a)},log:function(){var a=function(){};a.info=a.warn=a.error=Ext.emptyFn;return a}()});(function(){var b=[''],c=/([^\d\.])/,f=/[^\d]/g,g=/[\-+]/g,h=/\s/g,e=/_/g,d={classic:1,modern:1},a;Ext.Version=a=function(k,p){var b=this,n=b.padModes,o,m,d,h,j,l,i;if(k.isVersion){k=k.version}b.version=i=String(k).toLowerCase().replace(e,'.').replace(g,'');o=i.charAt(0);if(o in n){i=i.substring(1);d=n[o]}else {d=p?n[p]:0}b.pad=d;l=i.search(c);b.shortVersion=i;if(l!==-1){b.release=j=i.substr(l,k.length);b.shortVersion=i.substr(0,l);j=a.releaseValueMap[j]||j}b.releaseValue=j||d;b.shortVersion=b.shortVersion.replace(f,'');b.parts=h=i.split('.');for(m=h.length;m--;){h[m]=parseInt(h[m],10)}if(d===Infinity){h.push(d)}b.major=h[0]||d;b.minor=h[1]||d;b.patch=h[2]||d;b.build=h[3]||d;return b};a.prototype={isVersion:!0,padModes:{'~':NaN,'^':Infinity},release:'',compareTo:function(f){var g=this,m=g.pad,j=g.parts,h=j.length,e=f.isVersion?f:new a(f),n=e.pad,k=e.parts,i=k.length,l=Math.max(h,i),b,c,d;for(b=0;bd){return 1}}c=g.releaseValue;d=e.releaseValue;if(cd){return 1}return 0},toString:function(){return this.version},valueOf:function(){return this.version},getMajor:function(){return this.major},getMinor:function(){return this.minor},getPatch:function(){return this.patch},getBuild:function(){return this.build},getRelease:function(){return this.release},getReleaseValue:function(){return this.releaseValue},isGreaterThan:function(a){return this.compareTo(a)>0},isGreaterThanOrEqual:function(a){return this.compareTo(a)>=0},isLessThan:function(a){return this.compareTo(a)<0},isLessThanOrEqual:function(a){return this.compareTo(a)<=0},equals:function(a){return this.compareTo(a)===0},match:function(a){a=String(a);return this.version.substr(0,a.length)===a},toArray:function(){var a=this;return [a.getMajor(),a.getMinor(),a.getPatch(),a.getBuild(),a.getRelease()]},getShortVersion:function(){return this.shortVersion},gt:function(a){return this.compareTo(a)>0},lt:function(a){return this.compareTo(a)<0},gtEq:function(a){return this.compareTo(a)>=0},ltEq:function(a){return this.compareTo(a)<=0}};Ext.apply(a,{aliases:{from:{extjs:'ext',core:'core',touch:'modern'},to:{ext:['extjs'],'core':['core'],modern:['touch']}},releaseValueMap:{dev:-6,alpha:-5,a:-5,beta:-4,b:-4,rc:-3,'#':-2,p:-1,pl:-1},getComponentValue:function(a){return !a?0:isNaN(a)?this.releaseValueMap[a]||a:parseInt(a,10)},compare:function(b,c){var d=b.isVersion?b:new a(b);return d.compareTo(c)},set:function(g,f,c){var b=a.aliases.to[f],d=c.isVersion?c:new a(c),e;g[f]=d;if(b){for(e=b.length;e-->0;){g[b[e]]=d}}return d}});Ext.apply(Ext,{compatVersions:{},versions:{},lastRegisteredVersion:null,getCompatVersion:function(b){var c=Ext.compatVersions,d;if(!b){d=c.ext||c.touch||c.core}else {d=c[a.aliases.from[b]||b]}return d||Ext.getVersion(b)},setCompatVersion:function(b,c){a.set(Ext.compatVersions,b,c)},setVersion:function(b,c){if(b in d){Ext.toolkit=b}Ext.lastRegisteredVersion=a.set(Ext.versions,b,c);return this},getVersion:function(c){var b=Ext.versions;if(!c){return b.ext||b.touch||b.core}return b[a.aliases.from[c]||c]},checkVersion:function(o,j){var p=Ext.isArray(o),s=a.aliases.from,q=p?o:b,t=q.length,n=Ext.versions,r=n.ext||n.touch,l,c,f,i,g,m,d,e,k;if(!p){b[0]=o}for(l=0;l=0){d=d.replace(h,'')}c=d.indexOf('@');if(c<0){e=d;k=r}else {m=d.substring(0,c);if(!(k=n[s[m]||m])){if(j){return !1}continue}e=d.substring(c+1)}c=e.indexOf('-');if(c<0){if(e.charAt(c=e.length-1)==='+'){i=e.substring(0,c);g=null}else {i=g=e}}else {if(c>0){i=e.substring(0,c);g=e.substring(c+1)}else {i=null;g=e.substring(c+1)}}f=!0;if(i){i=new a(i,'~');f=i.ltEq(k)}if(f&&g){g=new a(g,'~');f=g.gtEq(k)}}if(f){if(!j){return !0}}else {if(j){return !1}}}return !!j},deprecate:function(b,e,c,d){if(a.compare(Ext.getVersion(b),e)<1){c.call(d)}}})})();(function(c){var d=c&&c.packages||{},b=c&&c.compatibility,a,e;for(a in d){e=d[a];Ext.setVersion(a,e.version)}if(b){if(Ext.isString(b)){Ext.setCompatVersion('core',b)}else {for(a in b){Ext.setCompatVersion(a,b[a])}}}if(!d.ext&&!d.touch){Ext.setVersion('ext','6.0.1.250');Ext.setVersion('core','6.0.1.250')}})(Ext.manifest);Ext.Config=function(b){var c=this,a=b.charAt(0).toUpperCase()+b.substr(1);c.name=b;c.names={internal:'_'+b,initializing:'is'+a+'Initializing',apply:'apply'+a,update:'update'+a,get:'get'+a,set:'set'+a,initGet:'initGet'+a,changeEvent:b.toLowerCase()+'change'};c.root=c};Ext.Config.map={};Ext.Config.get=function(a){var b=Ext.Config.map,c=b[a]||(b[a]=new Ext.Config(a));return c};Ext.Config.prototype={self:Ext.Config,isConfig:!0,getGetter:function(){return this.getter||(this.root.getter=this.makeGetter())},getInitGetter:function(){return this.initGetter||(this.root.initGetter=this.makeInitGetter())},getSetter:function(){return this.setter||(this.root.setter=this.makeSetter())},getEventedSetter:function(){return this.eventedSetter||(this.root.eventedSetter=this.makeEventedSetter())},getInternalName:function(a){return a.$configPrefixed?this.names.internal:this.name},mergeNew:function(b,d,f,e){var a,c;if(!d){a=b}else {if(!b){a=d}else {a=Ext.Object.chain(d);for(c in b){if(!e||!(c in a)){a[c]=b[c]}}}}return a},mergeSets:function(a,f,e){var b=f?Ext.Object.chain(f):{},c,d;if(a instanceof Array){for(c=a.length;c--;){d=a[c];if(!e||!(d in b)){b[d]=!0}}}else {if(a){if(a.constructor===Object){for(c in a){d=a[c];if(!e||!(c in b)){b[c]=d}}}else {if(!e||!(a in b)){b[a]=!0}}}}return b},makeGetter:function(){var b=this.name,a=this.names.internal;return function(){var c=this.$configPrefixed?a:b;return this[c]}},makeInitGetter:function(){var e=this.name,a=this.names,d=a.set,c=a.get,b=a.initializing;return function(){var a=this;a[b]=!0;delete a[c];a[d](a.config[e]);delete a[b];return a[c].apply(a,arguments)}},makeSetter:function(){var g=this.name,a=this.names,e=a.internal,f=a.get,d=a.apply,c=a.update,b;b=function(b){var a=this,h=a.$configPrefixed?e:g,i=a[h];delete a[f];if(!a[d]||(b=a[d](b,i))!==undefined){if(b!==(i=a[h])){a[h]=b;if(a[c]){a[c](b,i)}}}return a};b.$isDefault=!0;return b},makeEventedSetter:function(){var i=this.name,a=this.names,f=a.internal,h=a.get,d=a.apply,b=a.update,e=a.changeEvent,g=function(a,c,e,d){a[d]=c;if(a[b]){a[b](c,e)}},c;c=function(c){var a=this,k=a.$configPrefixed?f:i,j=a[k];delete a[h];if(!a[d]||(c=a[d](c,j))!==undefined){if(c!==(j=a[k])){if(a.isConfiguring){a[k]=c;if(a[b]){a[b](c,j)}}else {a.fireEventedAction(e,[a,c,j],g,a,[a,c,j,k])}}}return a};c.$isDefault=!0;return c}};(function(){var c=Ext.Config,b=c.map,a=Ext.Object;Ext.Configurator=function(d){var b=this,e=d.prototype,c=d.superclass?d.superclass.self.$config:null;b.cls=d;b.superCfg=c;if(c){b.configs=a.chain(c.configs);b.cachedConfigs=a.chain(c.cachedConfigs);b.initMap=a.chain(c.initMap);b.values=a.chain(c.values);b.needsFork=c.needsFork}else {b.configs={};b.cachedConfigs={};b.initMap={};b.values={}}e.config=e.defaultConfig=b.values;d.$config=b};Ext.Configurator.prototype={self:Ext.Configurator,needsFork:!1,initList:null,add:function(t,l){var i=this,n=i.cls,k=i.configs,v=i.cachedConfigs,p=i.initMap,g=n.prototype,r=l&&l.$config.configs,u=i.values,m,f,s,h,b,j,e,q,o,d;for(e in t){d=t[e];m=d&&d.constructor===Object;f=m&&'$value' in d?d:null;if(f){s=!!f.cached;d=f.$value;m=d&&d.constructor===Object}h=f&&f.merge;b=k[e];if(b){if(l){h=b.merge;if(!h){continue}f=null}else {h=h||b.merge}j=u[e];if(h){d=h.call(b,d,j,n,l)}else {if(m){if(j&&j.constructor===Object){d=a.merge({},j,d)}}}}else {if(r){b=r[e];f=null}else {b=c.get(e)}k[e]=b;if(b.cached||s){v[e]=!0}q=b.names;if(!g[o=q.get]){g[o]=b.getter||b.getGetter()}if(!g[o=q.set]){g[o]=f&&f.evented?b.eventedSetter||b.getEventedSetter():b.setter||b.getSetter()}}if(f){if(b.owner!==n){k[e]=b=Ext.Object.chain(b);b.owner=n}Ext.apply(b,f);delete b.$value}if(!i.needsFork&&d&&(d.constructor===Object||d instanceof Array)){i.needsFork=!0}if(d!==null){p[e]=!0}else {if(g.$configPrefixed){g[k[e].names.internal]=null}else {g[k[e].name]=null}if(e in p){p[e]=!1}}u[e]=d}},configure:function(c,h){var k=this,u=k.configs,x=k.initMap,q=k.initListMap,o=k.initList,j=k.cls.prototype,i=k.values,r=0,v=!o,n,b,m,w,d,p,l,f,e,g,t,s,y;i=k.needsFork?a.fork(i):a.chain(i);c.isConfiguring=!0;if(v){k.initList=o=[];k.initListMap=q={};c.isFirstInstance=!0;for(e in x){w=x[e];b=u[e];t=b.cached;if(w){f=b.names;g=i[e];if(!j[f.set].$isDefault||j[f.apply]||j[f.update]||typeof g==='object'){if(t){(n||(n=[])).push(b)}else {o.push(b);q[e]=!0}c[f.get]=b.initGetter||b.getInitGetter()}else {j[b.getInternalName(j)]=g}}else {if(t){j[b.getInternalName(j)]=undefined}}}}l=n&&n.length;if(l){for(d=0;d0){for(a=0;ac.maxSize){c.unlinkEntry(f.prev,!0);--c.count}}return d.value},evict:Ext.emptyFn,linkEntry:function(c){var d=this.head,e=d.next;c.next=e;c.prev=d;d.next=c;e.prev=c},unlinkEntry:function(c,f){var d=c.next,e=c.prev;e.next=d;d.prev=e;if(f){this.evict(c.key,c.value)}}};a.destroy=a.clear})();(function(){var a,d=Ext.Base,b=d.$staticMembers,c=function(a,b){return a.length-b.length||(ab?1:0)};function makeCtor(a){function constructor(){return this.constructor.apply(this,arguments)||null}return constructor}Ext.Class=a=function(b,c,d){if(typeof b!='function'){d=c;c=b;b=null}if(!c){c={}}b=a.create(b,c);a.process(b,c,d);return b};Ext.apply(a,{makeCtor:makeCtor,onBeforeCreated:function(a,c,b){a.addMembers(c);b.onCreated.call(a,a)},create:function(a,f){var e=b.length,c;if(!a){a=makeCtor()}while(e--){c=b[e];a[c]=d[c]}return a},process:function(l,f,k){var j=f.preprocessors||a.defaultPreprocessors,o=this.preprocessors,e={onBeforeCreated:this.onBeforeCreated},d=[],b,c,g,n,h,m,i;delete f.preprocessors;l._classHooks=e;for(g=0,n=j.length;g0){b=h.test(c[d])}c=o[a];if(c&&!b){d=c.length;while(!b&&d-->0){b=h.test(c[d])}}}if(b){i[a]=1;l.push(a)}}}}}return l},getPath:function(a){var e=this,d=e.paths,b='',c;if(a in d){b=d[a]}else {c=e.getPrefix(a);if(c){a=a.substring(c.length+1);b=d[c];if(b){b+='/'}}b+=a.replace(e.dotRe,'/')+'.js'}return b},getPrefix:function(a){if(a in this.paths){return a}var d=this.getPrefixes(),e=d.length,b,c;while(e-->0){b=(c=d[e]).length;if(b0){b=i[d];f=c;c=b.value||c[b.name];if(!c&&h){f[b.name]=c={}}}return c},setNamespace:function(f,d){var b=a.getNamespaceEntry(f),c=Ext.global;if(b.parent){c=a.lookupName(b.parent,!0)}c[b.name]=d;return d},setXType:function(i,d){var f=i.$className,k=f?i:a.get(f=i),b=k.prototype,j=b.xtypes,c=b.xtypesChain,h=b.xtypesMap;if(!b.hasOwnProperty('xtypes')){b.xtypes=j=[];b.xtypesChain=c=c?c.slice(0):[];b.xtypesMap=h=Ext.apply({},h)}a.addAlias(f,'widget.'+d,!0);j.push(d);c.push(d);h[d]=!0},set:function(b,d){var c=a.getName(d);a.classes[b]=a.setNamespace(b,d);if(c&&c!==b){a.addAlternate(c,b)}return a},get:function(b){return a.classes[b]||a.lookupName(b,!1)},addNameAliasMappings:function(b){a.addAlias(b)},addNameAlternateMappings:function(b){a.addAlternate(b)},getByAlias:function(b){return a.get(a.getNameByAlias(b))},getByConfig:function(c,d){var f=c.xclass,b;if(f){b=f}else {b=c.xtype;if(b){d='widget.'}else {b=c.type}b=a.getNameByAlias(d+b)}return a.get(b)},getName:function(a){return a&&a.$className||''},getClass:function(a){return a&&a.self||null},create:function(c,b,f){var d=q(c);if(typeof b==='function'){b=b(d)}b.$className=c;return new n(d,b,function(){var m=b.postprocessors||a.defaultPostprocessors,s=a.postprocessors,i=[],d,j,q,k,p,h,l;delete b.postprocessors;for(j=0,q=m.length;j0;){c=a.lookupName(arguments[b],!0)}return c}});Ext.addRootNamespaces=a.addRootNamespaces;Ext.createWidget=Ext.widget;Ext.ns=Ext.namespace;n.registerPreprocessor('className',function(b,a){if('$className' in a){b.$className=a.$className}},!0,'first');n.registerPreprocessor('alias',function(q,d){var l=q.prototype,c=g(d.xtype),i=g(d.alias),j='widget.',p=j.length,k=Array.prototype.slice.call(l.xtypesChain||[]),h=Ext.merge({},l.xtypesMap||{}),a,f,m,b;for(a=0,f=i.length;a=d){Ext[o+'p']=!0}}}if(n.is.Opera&&parseInt(a,10)<=12){Ext.isOpera12m=!0}Ext.chromeVersion=Ext.isChrome?a:0;Ext.firefoxVersion=Ext.isFirefox?a:0;Ext.ieVersion=Ext.isIE?a:0;Ext.operaVersion=Ext.isOpera?a:0;Ext.safariVersion=Ext.isSafari?a:0;Ext.webKitVersion=Ext.isWebKit?a:0;this.setFlag(c+a,!0,r);this.setFlag(c+f.getShortVersion())}for(d in j){if(j.hasOwnProperty(d)){h=j[d];this.setFlag(h,c===h)}}this.setFlag(h);if(l){this.setFlag(g+(l.getMajor()||''));this.setFlag(g+l.getShortVersion())}for(d in k){if(k.hasOwnProperty(d)){h=k[d];this.setFlag(h,g===h,r)}}this.setFlag('Standalone',!!navigator.standalone);this.setFlag('Ripple',!!document.getElementById('tinyhippos-injected')&&!Ext.isEmpty(window.top.ripple));this.setFlag('WebWorks',!!window.blackberry);if(window.PhoneGap!==undefined||window.Cordova!==undefined||window.cordova!==undefined){q=!0;this.setFlag('PhoneGap');this.setFlag('Cordova')}if(/(iPhone|iPod|iPad).*AppleWebKit(?!.*Safari)(?!.*FBAN)/i.test(e)){q=!0}this.setFlag('WebView',q);this.isStrict=Ext.isStrict=document.compatMode==='CSS1Compat';this.isSecure=Ext.isSecure;this.identity=c+a+(this.isStrict?'Strict':'Quirks')};Ext.env.Browser.prototype={constructor:Ext.env.Browser,engineNames:{webkit:'WebKit',gecko:'Gecko',presto:'Presto',trident:'Trident',other:'Other'},enginePrefixes:{webkit:'AppleWebKit/',gecko:'Gecko/',presto:'Presto/',trident:'Trident/'},styleDashPrefixes:{WebKit:'-webkit-',Gecko:'-moz-',Trident:'-ms-',Presto:'-o-',Other:''},stylePrefixes:{WebKit:'Webkit',Gecko:'Moz',Trident:'ms',Presto:'O',Other:''},propertyPrefixes:{WebKit:'webkit',Gecko:'moz',Trident:'ms',Presto:'o',Other:''},is:function(a){return !!this.is[a]},name:null,version:null,engineName:null,engineVersion:null,setFlag:function(b,a,c){if(a===undefined){a=!0}this.is[b]=a;this.is[b.toLowerCase()]=a;if(c){Ext['is'+b]=a}return this},getStyleDashPrefix:function(){return this.styleDashPrefixes[this.engineName]},getStylePrefix:function(){return this.stylePrefixes[this.engineName]},getVendorProperyName:function(b){var a=this.propertyPrefixes[this.engineName];if(a.length>0){return a+Ext.String.capitalize(b)}return b},getPreferredTranslationMethod:function(a){if(typeof a==='object'&&'translationMethod' in a&&a.translationMethod!=='auto'){return a.translationMethod}else {return 'csstransform'}}};(function(a){Ext.browser=new Ext.env.Browser(a,!0);Ext.userAgent=a.toLowerCase();Ext.SSL_SECURE_URL=Ext.isSecure&&Ext.isIE?"javascript:''":'about:blank'})(Ext.global.navigator.userAgent);Ext.env.OS=function(j,k,b){var n=this,g=Ext.Boot.osNames,h=Ext.Boot.osPrefixes,a,c='',m=n.is,d,l,f,i,e;b=b||Ext.browser;for(d in h){if(h.hasOwnProperty(d)){l=h[d];f=j.match(new RegExp('(?:'+l+')([^\\s;]+)'));if(f){a=g[d];e=f[1];if(e&&e==='HTC_'){c=new Ext.Version('2.3')}else {if(e&&e==='Silk/'){c=new Ext.Version('2.3')}else {c=new Ext.Version(f[f.length-1])}}break}}}if(!a){a=g[(j.toLowerCase().match(/mac|win|linux/)||['other'])[0]];c=new Ext.Version('')}this.name=a;this.version=c;if(k){this.setFlag(k.replace(/ simulator$/i,''))}this.setFlag(a);if(c){this.setFlag(a+(c.getMajor()||''));this.setFlag(a+c.getShortVersion())}for(d in g){if(g.hasOwnProperty(d)){i=g[d];if(!m.hasOwnProperty(a)){this.setFlag(i,a===i)}}}if(this.name==='iOS'&&window.screen.height===568){this.setFlag('iPhone5')}if(b.is.Safari||b.is.Silk){if(this.is.Android2||this.is.Android3||b.version.shortVersion===501){b.setFlag('AndroidStock')}if(this.is.Android4){b.setFlag('AndroidStock');b.setFlag('AndroidStock4')}}};Ext.env.OS.prototype={constructor:Ext.env.OS,is:function(a){return !!this[a]},name:null,version:null,setFlag:function(b,a){if(a===undefined){a=!0}if(this.flags){this.flags[b]=a}this.is[b]=a;this.is[b.toLowerCase()]=a;return this}};(function(){var h=Ext.global.navigator,i=h.userAgent,e=Ext.env.OS,f=Ext.is||(Ext.is={}),a,c,b;e.prototype.flags=f;Ext.os=a=new e(i,h.platform);c=a.name;Ext['is'+c]=!0;Ext.isMac=f.Mac=f.MacOS;var d=window.location.search.match(/deviceType=(Tablet|Phone)/),g=window.deviceType;if(d&&d[1]){b=d[1]}else {if(g==='iPhone'){b='Phone'}else {if(g==='iPad'){b='Tablet'}else {if(!a.is.Android&&!a.is.iOS&&!a.is.WindowsPhone&&/Windows|Linux|MacOS/.test(c)){b='Desktop';Ext.browser.is.WebView=!!Ext.browser.is.Ripple}else {if(a.is.iPad||a.is.RIMTablet||a.is.Android3||Ext.browser.is.Silk||a.is.Android&&i.search(/mobile/i)===-1){b='Tablet'}else {b='Phone'}}}}}a.setFlag(b,!0);a.deviceType=b;delete e.prototype.flags})();Ext.feature={has:function(a){return !!this.has[a]},testElements:{},getTestElement:function(a,b){if(a===undefined){a='div'}else {if(typeof a!=='string'){return a}}if(b){return document.createElement(a)}if(!this.testElements[a]){this.testElements[a]=document.createElement(a)}return this.testElements[a]},isStyleSupported:function(a,d){var b=this.getTestElement(d).style,c=Ext.String.capitalize(a);if(typeof b[a]!=='undefined'||typeof b[Ext.browser.getStylePrefix(a)+c]!=='undefined'){return !0}return !1},isStyleSupportedWithoutPrefix:function(b,c){var a=this.getTestElement(c).style;if(typeof a[b]!=='undefined'){return !0}return !1},isEventSupported:function(e,d){if(d===undefined){d=window}var a=this.getTestElement(d),b='on'+e.toLowerCase(),c=b in a;if(!c){if(a.setAttribute&&a.removeAttribute){a.setAttribute(b,'');c=typeof a[b]==='function';if(typeof a[b]!=='undefined'){a[b]=undefined}a.removeAttribute(b)}}return c},getStyle:function(a,c){var b=a.ownerDocument.defaultView,d=b?b.getComputedStyle(a,null):a.currentStyle;return (d||a.style)[c]},getSupportedPropertyName:function(c,a){var b=Ext.browser.getVendorProperyName(a);if(b in c){return b}else {if(a in c){return a}}return null},detect:function(h){var c=this,g=document,m=c.toRun||c.tests,i=m.length,f=g.createElement('div'),k=[],j=Ext.supports,n=c.has,a,e,b,l,d;f.innerHTML='
';if(h){g.body.appendChild(f)}l=c.preDetected[Ext.browser.identity]||[];while(i--){b=m[i];d=l[i];a=b.name;e=b.names;if(d===undefined){if(!h&&b.ready){k.push(b);continue}d=b.fn.call(c,g,f)}if(a){j[a]=n[a]=d}else {if(e){while(e.length){a=e.pop();j[a]=n[a]=d}}}}if(h){g.body.removeChild(f)}c.toRun=k},report:function(){var b=[],c=this.tests.length,a;for(a=0;a
';b=a.childNodes.length===1;a.innerHTML='';return b}},{name:'touchScroll',fn:function(){var a=0;if(Ext.os.is.Desktop&&(navigator.maxTouchPoints||navigator.msMaxTouchPoints)){a=1}else {if(Ext.supports.Touch){a=2}}return a}},{name:'Touch',fn:function(){var a=navigator.msMaxTouchPoints||navigator.maxTouchPoints;if(Ext.browser.is.Chrome&&Ext.browser.version.isLessThanOrEqual(39)){return Ext.supports.TouchEvents&&a!==1||a>1}else {return Ext.supports.TouchEvents||a>0}}},{name:'TouchEvents',fn:function(){return this.isEventSupported('touchend')}},{name:'PointerEvents',fn:function(){return navigator.pointerEnabled}},{name:'MSPointerEvents',fn:function(){return navigator.msPointerEnabled}},{name:'Orientation',fn:function(){return 'orientation' in window&&this.isEventSupported('orientationchange')}},{name:'OrientationChange',fn:function(){return this.isEventSupported('orientationchange')}},{name:'DeviceMotion',fn:function(){return this.isEventSupported('devicemotion')}},{names:['Geolocation','GeoLocation'],fn:function(){return 'geolocation' in window.navigator}},{name:'SqlDatabase',fn:function(){return 'openDatabase' in window}},{name:'WebSockets',fn:function(){return 'WebSocket' in window}},{name:'Range',fn:function(){return !!document.createRange}},{name:'CreateContextualFragment',fn:function(){var a=!!document.createRange?document.createRange():!1;return a&&!!a.createContextualFragment}},{name:'History',fn:function(){return 'history' in window&&'pushState' in window.history}},{name:'Css3dTransforms',fn:function(){return this.has('CssTransforms')&&this.isStyleSupported('perspective')}},{name:'CssTransforms',fn:function(){return this.isStyleSupported('transform')}},{name:'CssTransformNoPrefix',fn:function(){return this.isStyleSupportedWithoutPrefix('transform')}},{name:'CssAnimations',fn:function(){return this.isStyleSupported('animationName')}},{names:['CssTransitions','Transitions'],fn:function(){return this.isStyleSupported('transitionProperty')}},{names:['Audio','AudioTag'],fn:function(){return !!this.getTestElement('audio').canPlayType}},{name:'Video',fn:function(){return !!this.getTestElement('video').canPlayType}},{name:'LocalStorage',fn:function(){try{if('localStorage' in window&&window['localStorage']!==null){localStorage.setItem('sencha-localstorage-test','test success');localStorage.removeItem('sencha-localstorage-test');return !0}}catch(b){}return !1}},{name:'XHR2',fn:function(){return window.ProgressEvent&&window.FormData&&window.XMLHttpRequest&&'withCredentials' in new XMLHttpRequest()}},{name:'XHRUploadProgress',fn:function(){if(window.XMLHttpRequest&&!Ext.browser.is.AndroidStock){var a=new XMLHttpRequest();return a&&'upload' in a&&'onprogress' in a.upload}return !1}},{name:'NumericInputPlaceHolder',fn:function(){return !(Ext.browser.is.AndroidStock4&&Ext.os.version.getMinor()<2)}},{name:'matchesSelector',fn:function(){var a=document.documentElement,d='matches',e='webkitMatchesSelector',b='msMatchesSelector',c='mozMatchesSelector';return a[d]?d:a[e]?e:a[b]?b:a[c]?c:null}},{name:'RightMargin',ready:!0,fn:function(c,b){var a=c.defaultView;return !(a&&a.getComputedStyle(b.firstChild.firstChild,null).marginRight!=='0px')}},{name:'DisplayChangeInputSelectionBug',fn:function(){var a=Ext.webKitVersion;return 0a';b=a.firstChild;a.innerHTML='
b
';return b.innerHTML!=='a'}},{name:'IncludePaddingInWidthCalculation',ready:!0,fn:function(b,a){return a.childNodes[1].firstChild.offsetWidth===210}},{name:'IncludePaddingInHeightCalculation',ready:!0,fn:function(b,a){return a.childNodes[1].firstChild.offsetHeight===210}},{name:'TextAreaMaxLength',fn:function(a){return 'maxlength' in a.createElement('textarea')}},{name:'GetPositionPercentage',ready:!0,fn:function(b,a){return Ext.feature.getStyle(a.childNodes[2],'left')==='10%'}},{name:'PercentageHeightOverflowBug',ready:!0,fn:function(d){var c=!1,b,a;if(Ext.getScrollbarSize().height){a=this.getTestElement();b=a.style;b.height='50px';b.width='50px';b.overflow='auto';b.position='absolute';a.innerHTML=['
','
','
'].join('');d.body.appendChild(a);if(a.firstChild.offsetHeight===50){c=!0}d.body.removeChild(a)}return c}},{name:'xOriginBug',ready:!0,fn:function(e,b){b.innerHTML='
';var a=document.getElementById('b1').getBoundingClientRect(),c=document.getElementById('b2').getBoundingClientRect(),d=document.getElementById('b3').getBoundingClientRect();return c.left!==a.left&&d.right!==a.right}},{name:'ScrollWidthInlinePaddingBug',ready:!0,fn:function(c){var d=!1,a,b;b=c.createElement('div');a=b.style;a.height='50px';a.width='50px';a.padding='10px';a.overflow='hidden';a.position='absolute';b.innerHTML='';c.body.appendChild(b);if(b.scrollWidth===70){d=!0}c.body.removeChild(b);return d}},{name:'rtlVertScrollbarOnRight',ready:!0,fn:function(d,c){c.innerHTML='
';var a=c.firstChild,b=a.firstChild;return b.offsetLeft+b.offsetWidth!==a.offsetLeft+a.offsetWidth}},{name:'rtlVertScrollbarOverflowBug',ready:!0,fn:function(c,b){b.innerHTML='
';var a=b.firstChild;return a.clientHeight===a.offsetHeight}},{identity:'defineProperty',fn:function(){if(Ext.isIE8m){Ext.Object.defineProperty=Ext.emptyFn;return !1}return !0}},{identify:'nativeXhr',fn:function(){if(typeof XMLHttpRequest!=='undefined'){return !0}XMLHttpRequest=function(){try{return new ActiveXObject('MSXML2.XMLHTTP.3.0')}catch(b){return null}};return !1}},{name:'SpecialKeyDownRepeat',fn:function(){return Ext.isWebKit?parseInt(navigator.userAgent.match(/AppleWebKit\/(\d+)/)[1],10)>=525:!(Ext.isGecko&&!Ext.isWindows||Ext.isOpera&&Ext.operaVersion<12)}},{name:'EmulatedMouseOver',fn:function(){return Ext.os.is.iOS}},{name:'Hashchange',fn:function(){var a=document.documentMode;return 'onhashchange' in window&&(a===undefined||a>7)}},{name:'FixedTableWidthBug',ready:!0,fn:function(){if(Ext.isIE8){return !1}var a=document.createElement('div'),b=document.createElement('div'),c;a.setAttribute('style','display:table;table-layout:fixed;');b.setAttribute('style','display:table-cell;min-width:50px;');a.appendChild(b);document.body.appendChild(a);a.offsetWidth;a.style.width='25px';c=a.offsetWidth;document.body.removeChild(a);return c===50}},{name:'FocusinFocusoutEvents',fn:function(){return !Ext.isGecko}},{name:'AsyncFocusEvents',fn:function(){return Ext.asyncFocus=!!Ext.isIE}},{name:'accessibility',ready:!0,fn:function(f){var g=f.body,b,c,a,e,d;function getColor(a){var c=[],e=0,g,b;if(a.indexOf('rgb(')!==-1){c=a.replace('rgb(','').replace(')','').split(', ')}else {if(a.indexOf('#')!==-1){g=a.length===7?/^#(\S\S)(\S\S)(\S\S)$/:/^#(\S)(\S)(\S)$/;b=a.match(g);if(b){c=['0x'+b[1],'0x'+b[2],'0x'+b[3]]}}}for(var d=0;d0};Ext.supports.HighContrastMode=!e.BackgroundImages;g.removeChild(b);b=c=null;return e}},0]};Ext.feature.tests.pop();Ext.supports={};Ext.feature.detect();Ext.env.Ready={blocks:(location.search||'').indexOf('ext-pauseReadyFire')>0?1:0,bound:0,delay:1,firing:!1,generation:0,listeners:[],nextId:0,sortGeneration:0,state:0,timer:null,bind:function(){var a=Ext.env.Ready,b=document;if(!a.bound){if(b.readyState==='complete'){a.onReadyEvent({type:b.readyState||'body'})}else {a.bound=1;if(Ext.browser.is.PhoneGap&&!Ext.os.is.Desktop){a.bound=2;b.addEventListener('deviceready',a.onReadyEvent,!1)}b.addEventListener('DOMContentLoaded',a.onReadyEvent,!1);window.addEventListener('load',a.onReadyEvent,!1)}}},block:function(){++this.blocks;Ext.isReady=!1},fireReady:function(){var a=Ext.env.Ready;if(!a.state){Ext._readyTime=Ext.ticks();Ext.isDomReady=!0;a.state=1;Ext.feature.detect(!0);if(!a.delay){a.handleReady()}else {if(navigator.standalone){a.timer=Ext.defer(function(){a.timer=null;a.handleReadySoon()},1)}else {a.handleReadySoon()}}}},handleReady:function(){var a=this;if(a.state===1){a.state=2;Ext._beforeReadyTime=Ext.ticks();a.invokeAll();Ext._afterReadyTime=Ext.ticks()}},handleReadySoon:function(b){var a=this;if(!a.timer){a.timer=Ext.defer(function(){a.timer=null;a.handleReady()},b||a.delay)}},invoke:function(a){var b=a.delay;if(b){Ext.defer(a.fn,b,a.scope)}else {if(Ext.elevateFunction){Ext.elevateFunction(a.fn,a.scope)}else {a.fn.call(a.scope)}}},invokeAll:function(){if(Ext.elevateFunction){Ext.elevateFunction(this.doInvokeAll,this)}else {this.doInvokeAll()}},doInvokeAll:function(){var a=this,b=a.listeners,c;if(!a.blocks){Ext.isReady=!0}a.firing=!0;while(b.length){if(a.sortGeneration!==a.generation){a.sortGeneration=a.generation;b.sort(a.sortFn)}c=b.pop();if(a.blocks&&!c.dom){b.push(c);break}a.invoke(c)}a.firing=!1},makeListener:function(d,c,b){var a={fn:d,id:++this.nextId,scope:c,dom:!1,priority:0};if(b){Ext.apply(a,b)}a.phase=a.dom?0:1;return a},on:function(e,d,c){var a=Ext.env.Ready,b=a.makeListener(e,d,c);if(a.state===2&&!a.firing&&(b.dom||!a.blocks)){a.invoke(b)}else {a.listeners.push(b);++a.generation;if(!a.bound){a.bind()}}},onReadyEvent:function(b){var a=Ext.env.Ready;if(Ext.elevateFunction){Ext.elevateFunction(a.doReadyEvent,a,arguments)}else {a.doReadyEvent(b)}},doReadyEvent:function(b){var a=this;if(a.bound>0){a.unbind();a.bound=-1}if(!a.state){a.fireReady()}},sortFn:function(a,b){return -(a.phase-b.phase||b.priority-a.priority||a.id-b.id)},unblock:function(){var a=this;if(a.blocks){if(!--a.blocks){if(a.state===2&&!a.firing){a.invokeAll()}}}},unbind:function(){var a=this,b=document;if(a.bound>1){b.removeEventListener('deviceready',a.onReadyEvent,!1)}b.removeEventListener('DOMContentLoaded',a.onReadyEvent,!1);window.removeEventListener('load',a.onReadyEvent,!1)}};(function(){var a=Ext.env.Ready;if(Ext.isIE9m){Ext.apply(a,{scrollTimer:null,readyStatesRe:/complete/i,pollScroll:function(){var b=!0;try{document.documentElement.doScroll('left')}catch(c){b=!1}if(b&&document.body){a.onReadyEvent({type:'doScroll'})}else {a.scrollTimer=Ext.defer(a.pollScroll,20)}return b},bind:function(){if(a.bound){return}var b=document,c;try{c=window.frameElement===undefined}catch(d){}if(!c||!b.documentElement.doScroll){a.pollScroll=Ext.emptyFn}else {if(a.pollScroll()){return}}if(b.readyState==='complete'){a.onReadyEvent({type:'already '+(b.readyState||'body')})}else {b.attachEvent('onreadystatechange',a.onReadyStateChange);window.attachEvent('onload',a.onReadyEvent);a.bound=1}},unbind:function(){document.detachEvent('onreadystatechange',a.onReadyStateChange);window.detachEvent('onload',a.onReadyEvent);if(Ext.isNumber(a.scrollTimer)){clearTimeout(a.scrollTimer);a.scrollTimer=null}},onReadyStateChange:function(){var b=document.readyState;if(a.readyStatesRe.test(b)){a.onReadyEvent({type:b})}}})}Ext.onDocumentReady=function(e,d,b){var c={dom:!0};if(b){Ext.apply(c,b)}a.on(e,d,c)};Ext.onReady=function(d,c,b){a.on(d,c,b)};Ext.onInternalReady=function(d,c,b){a.on(d,c,Ext.apply({priority:1000},b))};a.bind()})();Ext.Loader=new function(){var a=this,b=Ext.ClassManager,i=Ext.Boot,o=Ext.Class,c=Ext.env.Ready,k=Ext.Function.alias,h=['extend','mixins','requires'],j={},m=[],f=[],g=[],l={},d={},e={enabled:!0,scriptChainDelay:!1,disableCaching:!0,disableCachingParam:'_dc',paths:b.paths,preserveScripts:!0,scriptCharset:undefined},n={disableCaching:!0,disableCachingParam:!0,preserveScripts:!0,scriptChainDelay:'loadDelay'};Ext.apply(a,{isInHistory:j,isLoading:!1,history:m,config:e,readyListeners:f,optionalRequires:g,requiresMap:l,hasFileLoadError:!1,scriptsLoading:0,syncModeEnabled:!1,missingQueue:d,init:function(){var k=document.getElementsByTagName('script'),m=k[k.length-1].src,n=m.substring(0,m.lastIndexOf('/')+1),l=Ext._classPathMetadata,h=Ext.Microloader,g=Ext.manifest,d,i,j,e,f;if(!b.getPath('Ext')){b.setPath('Ext',n+'src')}if(l){Ext._classPathMetadata=null;a.addClassPathMappings(l)}if(g){d=g.loadOrder;i=Ext.Boot.baseUrl;if(d&&g.bootRelative){for(j=d.length,e=0;e1?'es':'')+': '+g.join(', '))}if(l.length){a.loadScripts({url:l,_classNames:g})}else {a.checkReady()}}else {if(c){c.call(k)}a.checkReady()}if(a.syncModeEnabled){if(m===1){return b.get(h[0])}}return a},makeLoadCallback:function(a,c){return function(){var e=[],d=a.length;while(d-->0){e[d]=b.get(a[d])}return c.apply(this,e)}},onLoadFailure:function(){var b=this,c=b.onError;a.hasFileLoadError=!0;--a.scriptsLoading;if(c){c.call(b.userScope,b)}a.checkReady()},onLoadSuccess:function(){var b=this,c=b.onLoad;--a.scriptsLoading;if(c){c.call(b.userScope,b)}a.checkReady()},onReady:function(g,e,h,d){if(h){c.on(g,e,d)}else {var b=c.makeListener(g,e,d);if(a.isLoading){f.push(b)}else {c.invoke(b)}}},addUsedClasses:function(b){var c,d,e;if(b){b=typeof b==='string'?[b]:b;for(d=0,e=b.length;d0){a.loadScripts({url:b,sequential:!0})}}}if(h.uses){b=h.uses;a.addUsedClasses(b)}});b.onCreated(a.historyPush);a.init()}();Ext._endTime=Ext.ticks();if(Ext._beforereadyhandler){Ext._beforereadyhandler()}Ext.cmd.derive('Ext.Mixin',Ext.Base,function(a){return {statics:{addHook:function(e,c,d,h){var g=Ext.isFunction(e),b=function(){var b=arguments,i=g?e:h[e],f=this.callParent(b);i.apply(this,b);return f},f=c.hasOwnProperty(d)&&c[d];if(g){e.$previous=Ext.emptyFn}b.$name=d;b.$owner=c.self;if(f){b.$previous=f.$previous;f.$previous=b}else {c[d]=b}}},onClassExtended:function(k,c){var b=c.mixinConfig,d=c.xhooks,j=k.superclass,i=c.onClassMixedIn,h,f,g,e;if(d){delete c.xhooks;(b||(c.mixinConfig=b={})).on=d}if(b){h=j.mixinConfig;if(h){c.mixinConfig=b=Ext.merge({},h,b)}c.mixinId=b.id;f=b.before;g=b.after;d=b.on;e=b.extended}if(f||g||d||e){c.onClassMixedIn=function(b){var h=this.prototype,l=b.prototype,j;if(f){Ext.Object.each(f,function(e,d){b.addMember(e,function(){if(h[d].apply(this,arguments)!==!1){return this.callParent(arguments)}})})}if(g){Ext.Object.each(g,function(e,d){b.addMember(e,function(){var f=this.callParent(arguments);h[d].apply(this,arguments);return f})})}if(d){for(j in d){a.addHook(d[j],l,j,h)}}if(e){b.onExtended(function(){var d=Ext.Array.slice(arguments,0);d.unshift(b);return e.apply(this,d)},this)}if(i){i.apply(this,arguments)}}}}}},0,0,0,0,0,0,[Ext,'Mixin'],0);Ext.util=Ext.util||{};Ext.util.DelayedTask=function(e,c,d,b,g){var a=this,f,h=function(){var f=Ext.GlobalEvents;clearInterval(a.id);a.id=null;e.apply(c,d||[]);if(g!==!1&&f.hasListeners.idle){f.fireEvent('idle')}};b=typeof b==='boolean'?b:!0;a.id=null;a.delay=function(i,l,j,k){if(b){a.cancel()}if(typeof i==='number'){f=i}e=l||e;c=j||c;d=k||d;if(!a.id){a.id=Ext.interval(h,f)}};a.cancel=function(){if(a.id){clearInterval(a.id);a.id=null}}};Ext.cmd.derive('Ext.util.Event',Ext.Base,function(){var d=Array.prototype.slice,c=Ext.Array.insert,b=Ext.Array.toArray,a={};return {isEvent:!0,suspended:0,noOptions:{},constructor:function(a,b){this.name=b;this.observable=a;this.listeners=[]},addListener:function(r,q,g,t,s){var a=this,p=!1,l=a.observable,o=a.name,d,m,i,h,f,k,j,b,e,n;if(a.findListener(r,q)===-1){m=a.createListener(r,q,g,t,s);if(a.firing){a.listeners=a.listeners.slice(0)}d=a.listeners;b=j=d.length;i=g&&g.priority;f=a._highestNegativePriorityIndex;k=f!==undefined;if(i){h=i<0;if(!h||k){for(e=h?f:0;e0},fireDelegated:function(a,b){this.firingObservable=a;return this.fire.apply(this,b)},fire:function(){var e=this,r=e.listeners,t=r.length,n=e.observable,i=n.isElement,w=n.isComponent,v=e.firingObservable,b,o,f,k,c,j,u,h,l,p,g,m,a,s,q;if(!e.suspended&&t>0){e.firing=!0;c=arguments.length?d.call(arguments,0):[];u=c.length;if(i){a=c[0]}for(k=0;k4?b:e;b=e;for(e in b){if(b.hasOwnProperty(e)){g=b[e];if(!h.$eventOptions[e]){f.addManagedListener(h,e,g.fn||g,g.scope||b.scope||i,g.fn?g:k,!0)}}}if(b&&b.destroyable){return new a(f,h,b)}}else {if(j!==d){h.doAddListener(e,j,i,b,null,f,f);if(!l&&b&&b.destroyable){return new a(f,h,e,j,i)}}}},removeManagedListener:function(h,a,k,j){var e=this,b,d,g,i,f;if(typeof a!=='string'){b=a;for(a in b){if(b.hasOwnProperty(a)){d=b[a];if(!h.$eventOptions[a]){e.removeManagedListener(h,a,d.fn||d,d.scope||b.scope||j)}}}}else {g=e.managedListeners?e.managedListeners.slice():[];a=Ext.canonicalEventName(a);for(f=0,i=g.length;f0,d=this.events;if(!b&&a&&d){a=d[a];if(a&&a.isEvent){return a.isSuspended()}}return b},suspendEvents:function(a){++this.eventsSuspended;if(a&&!this.eventQueue){this.eventQueue=[]}},suspendEvent:function(){var e=this,f=e.events,g=arguments.length,d,b,a;for(d=0;d0){i.push(g)}d--;if(d===0){f.resolve(i)}return g};m=function(d){h--;if(h===0){f.reject(new Error('Too few Promises were resolved.'))}return d};for(g=j=0,n=e.length;j0){b.type=a.substring(0,e);b.defaultType=a.substring(e+1)}if(f){delete d.factoryConfig;Ext.apply(b,f)}g=Ext.Factory.define(b.type,b);if(c.create===Ext.Base.create){c.create=g}}},0,0,0,0,0,0,[Ext.mixin,'Factoryable'],0);Ext.cmd.derive('Ext.data.request.Base',Ext.Base,{factoryConfig:{type:'request',defaultType:'ajax'},result:null,success:null,timer:null,constructor:function(a){var b=this;Ext.apply(b,a.options||{},a.ownerConfig);b.id=++Ext.data.Connection.requestId;b.owner=a.owner;b.options=a.options;b.requestOptions=a.requestOptions},start:function(){var a=this,b=a.getTimeout();if(b&&a.async){a.timer=Ext.defer(a.onTimeout,b,a)}},abort:function(){var a=this;a.clearTimer();if(!a.timedout){a.aborted=!0}a.abort=Ext.emptyFn},createDeferred:function(){return this.deferred=new Ext.Deferred()},getDeferred:function(){return this.deferred||this.createDeferred()},getPromise:function(){return this.getDeferred().promise},then:function(){var a=this.getPromise();return a.then.apply(a,arguments)},onComplete:function(){var a=this,b=a.deferred,c=a.result;a.clearTimer();if(b){if(a.success){b.resolve(c)}else {b.reject(c)}}},onTimeout:function(){var a=this;a.timedout=!0;a.timer=null;a.abort(!0)},getTimeout:function(){return this.timeout},clearTimer:function(){var a=this.timer;if(a){clearTimeout(a);this.timer=null}},destroy:function(){var a=this;a.abort();a.owner=a.options=a.requestOptions=a.result=null;a.callParent()},privates:{createException:function(){var a=this,b;b={request:a,requestId:a.id,status:a.aborted?-1:0,statusText:a.aborted?'transaction aborted':'communication failure',getResponseHeader:a._getHeader,getAllResponseHeaders:a._getHeaders};if(a.aborted){b.aborted=!0}if(a.timedout){b.timedout=!0}return b},_getHeader:function(b){var a=this.headers;return a&&a[b.toLowerCase()]},_getHeaders:function(){return this.headers}}},1,0,0,0,0,[[Ext.mixin.Factoryable.prototype.mixinId||Ext.mixin.Factoryable.$className,Ext.mixin.Factoryable]],[Ext.data.request,'Base'],0);Ext.cmd.derive('Ext.data.flash.BinaryXhr',Ext.Base,{statics:{flashPluginActivated:function(){Ext.data.flash.BinaryXhr.flashPluginActive=!0;Ext.data.flash.BinaryXhr.flashPlugin=document.getElementById('ext-flash-polyfill');Ext.GlobalEvents.fireEvent('flashready')},flashPluginActive:!1,flashPluginInjected:!1,connectionIndex:1,liveConnections:{},flashPlugin:null,onFlashStateChange:function(b,c,d){var a;a=this.liveConnections[Number(b)];if(a){a.onFlashStateChange(c,d)}},registerConnection:function(b){var a=this.connectionIndex;this.conectionIndex=this.connectionIndex+1;this.liveConnections[a]=b;return a},injectFlashPlugin:function(){var c=this,b,a;c.flashPolyfillEl=Ext.getBody().appendChild({id:'ext-flash-polyfill',cn:[{tag:'p',html:'To view this page ensure that Adobe Flash Player version 11.1.0 or greater is installed.'},{tag:'a',href:'http://www.adobe.com/go/getflashplayer',cn:[{tag:'img',src:window.location.protocol+'//www.adobe.com/images/shared/download_buttons/get_flash_player.gif',alt:'Get Adobe Flash player'}]}]});b=[Ext.Loader.getPath('Ext.data.Connection'),'../../../plugins/flash/swfobject.js'].join('/');a='/plugins/flash/FlashPlugin.swf';if(Ext.flashPluginPath){a=Ext.flashPluginPath}Ext.Loader.loadScript({url:b,onLoad:function(){var d='11.4.0';var e='playerProductInstall.swf';var f={};var b={};b.quality='high';b.bgcolor='#ffffff';b.allowscriptaccess='sameDomain';b.allowfullscreen='true';var c={};c.id='ext-flash-polyfill';c.name='polyfill';c.align='middle';swfobject.embedSWF(a,'ext-flash-polyfill','0','0',d,e,f,b,c)},onError:function(){},scope:c});Ext.data.flash.BinaryXhr.flashPluginInjected=!0}},readyState:0,status:0,statusText:'',responseBytes:null,javascriptId:null,constructor:function(b){if(!Ext.data.flash.BinaryXhr.flashPluginInjected){Ext.data.flash.BinaryXhr.injectFlashPlugin()}var a=this;Ext.apply(a,b);a.requestHeaders={}},abort:function(){var a=this;if(a.readyState==4){return}a.aborted=!0;if(!Ext.data.flash.BinaryXhr.flashPluginActive){Ext.GlobalEvents.removeListener('flashready',a.onFlashReady,a);return}Ext.data.flash.BinaryXhr.flashPlugin.abortRequest(a.javascriptId);delete Ext.data.flash.BinaryXhr.liveConnections[a.javascriptId]},getAllResponseHeaders:function(){var a=[];Ext.Object.each(this.responseHeaders,function(c,b){a.push(c+': '+b)});return a.join('\r\n')},getResponseHeader:function(b){var a=this.responseHeaders;return a&&a[b]||null},open:function(c,f,d,e,b){var a=this;a.method=c;a.url=f;a.async=d!==!1;a.user=e;a.password=b},overrideMimeType:function(a){this.mimeType=a},send:function(b){var a=this;a.body=b;if(!Ext.data.flash.BinaryXhr.flashPluginActive){Ext.GlobalEvents.addListener('flashready',a.onFlashReady,a)}else {this.onFlashReady()}},onFlashReady:function(){var a=this,b,c;a.javascriptId=Ext.data.flash.BinaryXhr.registerConnection(a);b={method:a.method,url:a.url,user:a.user,password:a.password,mimeType:a.mimeType,requestHeaders:a.requestHeaders,body:a.body,javascriptId:a.javascriptId};c=Ext.data.flash.BinaryXhr.flashPlugin.postBinary(b)},setReadyState:function(b){var a=this;if(a.readyState!=b){a.readyState=b;a.onreadystatechange()}},setRequestHeader:function(a,b){this.requestHeaders[a]=b},onreadystatechange:Ext.emptyFn,parseData:function(a){var b=this;this.status=a.status||0;b.responseHeaders={};if(b.mimeType){b.responseHeaders['content-type']=b.mimeType}if(a.reason=='complete'){this.responseBytes=a.data;b.responseHeaders['content-length']=a.data.length}else {if(a.reason=='error'||a.reason=='securityError'){this.statusText=a.text;b.responseHeaders['content-length']=0}}},onFlashStateChange:function(b,c){var a=this;if(b==4){a.parseData(c);delete Ext.data.flash.BinaryXhr.liveConnections[a.javascriptId]}a.setReadyState(b)}},1,0,0,0,0,0,[Ext.data.flash,'BinaryXhr'],0);Ext.cmd.derive('Ext.data.request.Ajax',Ext.data.request.Base,{statics:{parseStatus:function(a){a=a==1223?204:a;var c=a>=200&&a<300||a==304,b=!1;if(!c){switch(a){case 12002:case 12029:case 12030:case 12031:case 12152:case 13030:b=!0;break;}}return {success:c,isException:b}}},start:function(f){var a=this,e=a.options,c=a.requestOptions,d=a.isXdr,b,g;b=a.xhr=a.openRequest(e,c,a.async,a.username,a.password);if(!d){g=a.setupHeaders(b,e,c.data,c.params)}if(a.async){if(!d){b.onreadystatechange=Ext.Function.bind(a.onStateChange,a)}}if(d){a.processXdrRequest(a,b)}Ext.data.request.Base.prototype.start.call(this,f);b.send(f);if(!a.async){return a.onComplete()}return a},abort:function(c){var a=this,b=a.xhr;if(c||a.isLoading()){try{b.onreadystatechange=null}catch(d){b.onreadystatechange=Ext.emptyFn}b.abort();Ext.data.request.Base.prototype.abort.call(this,c);a.onComplete();a.cleanup()}},cleanup:function(){this.xhr=null;delete this.xhr},isLoading:function(){var c=this,a=c.xhr,b=a&&a.readyState,d=Ext.data.flash&&Ext.data.flash.BinaryXhr;if(!a||c.aborted||c.timedout){return !1}if(d&&a instanceof d){return b!==4}return b!==0&&b!==4},openRequest:function(d,b,f,e,g){var c=this,a=c.newRequest(d);if(e){a.open(b.method,b.url,f,e,g)}else {if(c.isXdr){a.open(b.method,b.url)}else {a.open(b.method,b.url,f)}}if(d.binary||c.binary){if(window.Uint8Array){a.responseType='arraybuffer'}else {if(a.overrideMimeType){a.overrideMimeType('text/plain; charset=x-user-defined')}}}if(d.withCredentials||c.withCredentials){a.withCredentials=!0}return a},newRequest:function(c){var a=this,b;if(c.binaryData){if(window.Uint8Array){b=a.getXhrInstance()}else {b=new Ext.data.flash.BinaryXhr()}}else {if(a.cors&&Ext.isIE9m){b=a.getXdrInstance();a.isXdr=!0}else {b=a.getXhrInstance();a.isXdr=!1}}return b},setupHeaders:function(m,f,j,l){var d=this,a=Ext.apply({},f.headers||{},d.defaultHeaders),e=d.defaultPostHeader,h=f.jsonData,i=f.xmlData,b='Content-Type',k=d.useDefaultXhrHeader,c,g;if(!a.hasOwnProperty(b)&&(j||l)){if(j){if(f.rawData){e='text/plain'}else {if(i&&Ext.isDefined(i)){e='text/xml'}else {if(h&&Ext.isDefined(h)){e='application/json'}}}}a[b]=e}if(k&&!a['X-Requested-With']){a['X-Requested-With']=d.defaultXhrHeader}if(a[b]===undefined||a[b]===null){delete a[b]}try{for(c in a){if(a.hasOwnProperty(c)){g=a[c];m.setRequestHeader(c,g)}}}catch(n){d.owner.fireEvent('exception',c,g)}return a},getXdrInstance:function(){var a;if(Ext.ieVersion>=8){a=new XDomainRequest()}else {Ext.raise({msg:'Your browser does not support CORS'})}return a},getXhrInstance:function(){var c=[function(){return new XMLHttpRequest()},function(){return new ActiveXObject('MSXML2.XMLHTTP.3.0')},function(){return new ActiveXObject('MSXML2.XMLHTTP')},function(){return new ActiveXObject('Microsoft.XMLHTTP')}],b=0,d=c.length,a;for(;b=0){j=e.substr(0,c).toLowerCase();if(e.charAt(c+1)==' '){++c}f[j]=e.substr(c+1)}}b={request:d,requestId:d.id,status:a.status,statusText:a.statusText,getResponseHeader:function(b){return f[b.toLowerCase()]},getAllResponseHeaders:function(){return f}};if(h){d.processXdrResponse(b,a)}if(d.binary){b.responseBytes=d.getByteArray(a)}else {b.responseText=a.responseText;b.responseXML=a.responseXML}return b},destroy:function(){this.xhr=null;Ext.data.request.Base.prototype.destroy.call(this)},privates:{getByteArray:function(b){var e=b.response,g=b.responseBody,h=Ext.data.flash&&Ext.data.flash.BinaryXhr,a,d,f,c;if(b instanceof h){a=b.responseBytes}else {if(window.Uint8Array){a=e?new Uint8Array(e):[]}else {if(Ext.isIE9p){try{a=(new VBArray(g)).toArray()}catch(i){a=[]}}else {if(Ext.isIE){if(!this.self.vbScriptInjected){this.injectVBScript()}getIEByteArray(b.responseBody,a=[])}else {a=[];d=b.responseText;f=d.length;for(c=0;c=500){this.run()}},run:function(){var a=this;if(!a.isRunning){return}var b=a.runningQueue,d=Ext.now(),c,e;a.lastRunTime=d;a.frameStartTime=d;b.push.apply(b,a.queue);for(c=0,e=b.length;c0){b=a.shift();this.invoke(b);this.processIdleQueue()}},processTaskQueue:function(){if(!this.hasOwnProperty('taskQueueTimer')){this.taskQueueTimer=Ext.defer(this.processTaskQueueItem,15,this)}},processTaskQueueItem:function(){delete this.taskQueueTimer;var a=this.taskQueue,b;if(a.length>0){b=a.shift();this.invoke(b);this.processTaskQueue()}}},1,0,0,0,0,0,[Ext,'AnimationQueue'],0);Ext.cmd.derive('Ext.ComponentManager',Ext.Base,{alternateClassName:'Ext.ComponentMgr',singleton:!0,count:0,typeName:'xtype',constructor:function(b){var a=this;Ext.apply(a,b||{});a.all={};a.references={};a.onAvailableCallbacks={}},create:function(a,b){if(typeof a==='string'){return Ext.widget(a)}if(a.isComponent){return a}if('xclass' in a){return Ext.create(a.xclass,a)}return Ext.widget(a.xtype||b,a)},get:function(a){return this.all[a]},register:function(b){var a=this,e=a.all,d=b.getId(),c=a.onAvailableCallbacks;e[d]=b;if(b.getReference&&b.getReference()){a.references[d]=b}++a.count;if(!a.hasFocusListener){Ext.on('focus',a.onGlobalFocus,a);a.hasFocusListener=!0}c=c&&c[d];if(c&&c.length){a.notifyAvailable(b)}},unregister:function(b){var a=b.getId();if(b.getReference&&b.getReference()){this.references[a]=null;delete this.references[a]}this.all[a]=null;delete this.all[a];this.count--},markReferencesDirty:function(){this.referencesDirty=!0},fixReferences:function(){var c=this,a=c.references,b;if(c.referencesDirty){for(b in a){if(a.hasOwnProperty(b)){a[b].fixReference()}}c.referencesDirty=!1}},onAvailable:function(a,f,d){var g=this,b=g.onAvailableCallbacks,e=g.all,c;if(a in e){c=e[a];f.call(d||c,c)}else {if(a){if(!Ext.isArray(b[a])){b[a]=[]}b[a].push(function(b){f.call(d||b,b)})}}},notifyAvailable:function(a){var b=this.onAvailableCallbacks[a&&a.getId()]||[];while(b.length){b.shift()(a)}},each:function(b,a){return Ext.Object.each(this.all,b,a)},getCount:function(){return this.count},getAll:function(){return Ext.Object.getValues(this.all)},getActiveComponent:function(){return Ext.Component.fromElement(Ext.dom.Element.getActiveElement())},onGlobalFocus:function(d){var h=this,g=d.toElement,f=d.fromElement,c=Ext.Component.fromElement(g),b=Ext.Component.fromElement(f),e,a;if(c===b){return}e=h.getCommonAncestor(b,c);if(b&&!(b.destroyed||b.destroying)){if(b.handleBlurEvent){b.handleBlurEvent(d)}for(a=b;a&&a!==e;a=a.getRefOwner()){if(!(a.destroyed||a.destroying)){a.onFocusLeave({event:d.event,type:'focusleave',target:f,relatedTarget:g,fromComponent:b,toComponent:c})}}}if(c&&!c.destroyed){if(c.handleFocusEvent){c.handleFocusEvent(d)}for(a=c;a&&a!==e;a=a.getRefOwner()){a.onFocusEnter({event:d.event,type:'focusenter',relatedTarget:f,target:g,fromComponent:b,toComponent:c})}}},getCommonAncestor:function(a,b){if(a===b){return a}while(a&&!(a.isAncestor(b)||a===b)){a=a.getRefOwner()}return a},privates:{clearAll:function(){this.all={};this.references={};this.onAvailableCallbacks={}},fromElement:function(i,b,e){var a=Ext.getDom(i),h=this.all,g=0,f,d,c;if(typeof b!=='number'){f=Ext.getDom(b);b=Number.MAX_VALUE}while(a&&a.nodeType===1&&g0){for(;a.first&&b;b--){a.removeAtKey(a.first.key)}}},destroy:function(){this.first=this.last=null;Ext.util.HashMap.prototype.destroy.call(this)}},0,0,0,0,0,0,[Ext.util,'LruCache'],0);Ext.cmd.derive('Ext.ComponentQuery',Ext.Base,{singleton:!0},0,0,0,0,0,0,[Ext,'ComponentQuery'],function(){var a=this,f=Ext.util.Operators,r=/(\d*)n\+?(\d*)/,q=/\D/,c=/^(\s)+/,b=/\\(.)/g,j=new Ext.util.LruCache({maxSize:100}),m=['var r = [],','i = 0,','it = items,','l = it.length,','c;','for (; i < l; i++) {','c = it[i];','if (c.{0}) {','r.push(c);','}','}','return r;'].join(''),d=function(b,a){return a.method.apply(this,[b].concat(a.args))},e=function(d,g){var b=[],c=0,e=d.length,a,f=g!=='>';for(;c\^])\s?|\s|$)/,o=/^(#)?((?:\\\.|[\w\-])+|\*)(?:\((true|false)\))?/,k=[{re:/^\.((?:\\\.|[\w\-])+)(?:\((true|false)\))?/,method:g,argTransform:function(a){if(a[1]!==undefined){a[1]=a[1].replace(b,'$1')}return a.slice(1)}},{re:/^(?:\[((?:[@?$])?[\w\-]*)\s*(?:([\^$*~%!\/]?=)\s*(['"])?((?:\\\]|.)*?)\3)?(?!\\)\])/,method:l,argTransform:function(c){var g=c[0],f=c[1],e=c[2],a=c[4],d;if(a!==undefined){a=a.replace(b,'$1')}if(e==='/='){d=j.get(a);if(d){a=d}else {a=j.add(a,new RegExp(a))}}return [f,e,a]}},{re:/^#((?:\\\.|[\w\-])+)/,method:i},{re:/^\:([\w\-]+)(?:\(((?:\{[^\}]+\})|(?:(?!\{)[^\s>\/]*?(?!\})))\))?/,method:n,argTransform:function(a){if(a[2]!==undefined){a[2]=a[2].replace(b,'$1')}return a.slice(1)}},{re:/^(?:\{([^\}]+)\})/,method:m}];a.Query=Ext.extend(Object,{constructor:function(a){a=a||{};Ext.apply(this,a)},execute:function(f){var c=this.operations,b=[],e,a,d;for(a=0,d=c.length;a=0;--c){g=l[c];b=g.mode;if(b){if(b==='^'){a=e(a,' ')}else {if(b==='>'){i=[];for(f=0,k=a.length;f1}});Ext.apply(a,{cache:new Ext.util.LruCache({maxSize:100}),pseudos:{not:function(d,f){var c=0,g=d.length,e=[],h=-1,b;for(;c0){b.push(a[0])}return b},last:function(a){var b=a.length,c=[];if(b>0){c.push(a[b-1])}return c},focusable:function(d){var e=d.length,c=[],b=0,a;for(;b=c.left&&(t=='t'&&v=='b'||t=='b'&&v=='t');o=f=c.top&&(s=='r'&&u=='l'||s=='l'&&u=='r');if(e+k>a.right){if(o){e=c.left-k;o=!1}else {e=a.right-k}}if(ea.bottom){if(p){f=c.top-j;p=!1}else {f=a.bottom-j}}if(fa.right){e=!0;d[0]=a.right-b.right}if(b.left+d[0]a.bottom){e=!0;d[1]=a.bottom-b.bottom}if(b.top+d[1]=b.x&&a.right<=b.right&&a.y>=b.y&&a.bottom<=b.bottom},intersect:function(a){var b=this,f=Math.max(b.y,a.y),e=Math.min(b.right,a.right),c=Math.min(b.bottom,a.bottom),d=Math.max(b.x,a.x);if(c>f&&e>d){return new this.self(f,e,c,d)}else {return !1}},union:function(a){var b=this,f=Math.min(b.y,a.y),e=Math.max(b.right,a.right),c=Math.max(b.bottom,a.bottom),d=Math.min(b.x,a.x);return new this.self(f,e,c,d)},constrainTo:function(b){var a=this,c=Ext.Number.constrain;a.top=a.y=c(a.top,b.y,b.bottom);a.bottom=c(a.bottom,b.y,b.bottom);a.left=a.x=c(a.left,b.x,b.right);a.right=c(a.right,b.x,b.right);return a},adjust:function(e,c,b,d){var a=this;a.top=a.y+=e;a.left=a.x+=d;a.right+=c;a.bottom+=b;return a},getOutOfBoundOffset:function(b,a){if(!Ext.isObject(b)){if(b=='x'){return this.getOutOfBoundOffsetX(a)}else {return this.getOutOfBoundOffsetY(a)}}else {a=b;var c=new Ext.util.Offset();c.x=this.getOutOfBoundOffsetX(a.x);c.y=this.getOutOfBoundOffsetY(a.y);return c}},getOutOfBoundOffsetX:function(a){if(a<=this.x){return this.x-a}else {if(a>=this.right){return this.right-a}}return 0},getOutOfBoundOffsetY:function(a){if(a<=this.y){return this.y-a}else {if(a>=this.bottom){return this.bottom-a}}return 0},isOutOfBound:function(b,a){if(!Ext.isObject(b)){if(b=='x'){return this.isOutOfBoundX(a)}else {return this.isOutOfBoundY(a)}}else {a=b;return this.isOutOfBoundX(a.x)||this.isOutOfBoundY(a.y)}},isOutOfBoundX:function(a){return athis.right},isOutOfBoundY:function(a){return athis.bottom},restrict:function(d,a,b){if(Ext.isObject(d)){var c;b=a;a=d;if(a.copy){c=a.copy()}else {c={x:a.x,y:a.y}}c.x=this.restrictX(a.x,b);c.y=this.restrictY(a.y,b);return c}else {if(d=='x'){return this.restrictX(a,b)}else {return this.restrictY(a,b)}}},restrictX:function(a,b){if(!b){b=1}if(a<=this.x){a-=(a-this.x)*b}else {if(a>=this.right){a-=(a-this.right)*b}}return a},restrictY:function(a,b){if(!b){b=1}if(a<=this.y){a-=(a-this.y)*b}else {if(a>=this.bottom){a-=(a-this.bottom)*b}}return a},getSize:function(){return {width:this.right-this.x,height:this.bottom-this.y}},copy:function(){return new this.self(this.y,this.right,this.bottom,this.x)},copyFrom:function(b){var a=this;a.top=a.y=a[1]=b.y;a.right=b.right;a.bottom=b.bottom;a.left=a.x=a[0]=b.x;return this},toString:function(){return 'Region['+this.top+','+this.right+','+this.bottom+','+this.left+']'},translateBy:function(b,c){if(arguments.length==1){c=b.y;b=b.x}var a=this;a.top=a.y+=c;a.right+=b;a.bottom+=c;a.left=a.x+=b;return a},round:function(){var a=this;a.top=a.y=Math.round(a.y);a.right=Math.round(a.right);a.bottom=Math.round(a.bottom);a.left=a.x=Math.round(a.x);return a},equals:function(a){return this.top===a.top&&this.right===a.right&&this.bottom===a.bottom&&this.left===a.left}},3,0,0,0,0,0,[Ext.util,'Region'],0);Ext.cmd.derive('Ext.util.Point',Ext.util.Region,{radianToDegreeConstant:180/Math.PI,origin:{x:0,y:0},statics:{fromEvent:function(b){var a=b.changedTouches,c=a&&a.length>0?a[0]:b;return this.fromTouch(c)},fromTouch:function(a){return new this(a.pageX,a.pageY)},from:function(a){if(!a){return new this(0,0)}if(!(a instanceof this)){return new this(a.x,a.y)}return a}},constructor:function(a,b){if(a==null){a=0}if(b==null){b=0}Ext.util.Region.prototype.constructor.call(this,b,a,b,a)},clone:function(){return new this.self(this.x,this.y)},copy:function(){return this.clone.apply(this,arguments)},copyFrom:function(a){this.x=a.x;this.y=a.y;return this},toString:function(){return 'Point['+this.x+','+this.y+']'},equals:function(a){return this.x===a.x&&this.y===a.y},isCloseTo:function(b,a){if(typeof a=='number'){return this.getDistanceTo(b)<=a}var e=b.x,f=b.y,c=a.x,d=a.y;return this.x<=e+c&&this.x>=e-c&&this.y<=f+d&&this.y>=f-d},isWithin:function(){return this.isCloseTo.apply(this,arguments)},isContainedBy:function(a){if(!(a instanceof Ext.util.Region)){a=Ext.get(a.el||a).getRegion()}return a.contains(this)},roundedEquals:function(a){if(!a||typeof a!=='object'){a=this.origin}return Math.round(this.x)===Math.round(a.x)&&Math.round(this.y)===Math.round(a.y)},getDistanceTo:function(a){if(!a||typeof a!=='object'){a=this.origin}var b=this.x-a.x,c=this.y-a.y;return Math.sqrt(b*b+c*c)},getAngleTo:function(a){if(!a||typeof a!=='object'){a=this.origin}var b=this.x-a.x,c=this.y-a.y;return Math.atan2(c,b)*this.radianToDegreeConstant}},3,0,0,0,0,0,[Ext.util,'Point'],function(){this.prototype.translate=this.prototype.translateBy});Ext.cmd.derive('Ext.event.Event',Ext.Base,{alternateClassName:'Ext.EventObjectImpl',isStopped:!1,defaultPrevented:!1,isEvent:!0,statics:{resolveTextNode:function(a){return a&&a.nodeType===3?a.parentNode:a},pointerEvents:{pointerdown:1,pointermove:1,pointerup:1,pointercancel:1,pointerover:1,pointerout:1,pointerenter:1,pointerleave:1,MSPointerDown:1,MSPointerMove:1,MSPointerUp:1,MSPointerOver:1,MSPointerOut:1,MSPointerCancel:1,MSPointerEnter:1,MSPointerLeave:1},mouseEvents:{mousedown:1,mousemove:1,mouseup:1,mouseover:1,mouseout:1,mouseenter:1,mouseleave:1},clickEvents:{click:1,dblclick:1},touchEvents:{touchstart:1,touchmove:1,touchend:1,touchcancel:1},focusEvents:{focus:1,blur:1,focusin:1,focusout:1,focusenter:1,focusleave:1},pointerTypes:{2:'touch',3:'pen',4:'mouse',touch:'touch',pen:'pen',mouse:'mouse'}},constructor:function(b){var a=this,c=a.self,h=a.self.resolveTextNode,i=b.changedTouches,g=i?i[0]:b,d=b.type,e,f;a.pageX=g.pageX;a.pageY=g.pageY;a.target=a.delegatedTarget=h(b.target);f=b.relatedTarget;if(f){a.relatedTarget=h(f)}a.browserEvent=a.event=b;a.type=d;a.button=b.button||0;a.shiftKey=b.shiftKey;a.ctrlKey=b.ctrlKey||b.metaKey||!1;a.altKey=b.altKey;a.charCode=b.charCode;a.keyCode=b.keyCode;a.buttons=b.buttons;if(a.button===0&&a.buttons===0){a.buttons=1}if(c.forwardTab!==undefined&&c.focusEvents[d]){a.forwardTab=c.forwardTab}if(c.mouseEvents[d]||c.clickEvents[d]){e='mouse'}else {if(c.pointerEvents[d]){e=c.pointerTypes[b.pointerType]}else {if(c.touchEvents[d]){e='touch'}}}if(e){a.pointerType=e}a.timeStamp=a.time=+(b.timeStamp||new Date())},chain:function(b){var a=Ext.Object.chain(this);a.parentEvent=this;return Ext.apply(a,b)},correctWheelDelta:function(a){var c=this.WHEEL_SCALE,b=Math.round(a/c);if(!b&&a){b=a<0?-1:1}return b},getCharCode:function(){return this.charCode||this.keyCode},getKey:function(){return this.keyCode||this.charCode},getKeyName:function(){return this.keyCodes[this.keyCode]},getPoint:function(){var a=this.getXY();return new Ext.util.Point(a[0],a[1])},getRelatedTarget:function(d,e,c){var a=this.relatedTarget,b=null;if(a){if(d){b=Ext.fly(a).findParent(d,e,c)}else {b=c?Ext.get(a):a}}return b},getTarget:function(b,c,a){return b?Ext.fly(this.target).findParent(b,c,a):a?Ext.get(this.target):this.target},getTime:function(){return this.time},getWheelDelta:function(){var a=this.getWheelDeltas();return a.y},getWheelDeltas:function(){var d=this,a=d.browserEvent,c=0,b=0;if(Ext.isDefined(a.wheelDeltaX)){c=a.wheelDeltaX;b=a.wheelDeltaY}else {if(a.wheelDelta){b=a.wheelDelta}else {if(a.detail){b=-a.detail;if(b>100){b=3}else {if(b<-100){b=-3}}if(Ext.isDefined(a.axis)&&a.axis===a.HORIZONTAL_AXIS){c=b;b=0}}}}return {x:d.correctWheelDelta(c),y:d.correctWheelDelta(b)}},getX:function(){return this.getXY()[0]},getXY:function(){var d=this,c=d.xy;if(!c){c=d.xy=[d.pageX,d.pageY];var g=c[0],e,f,a,b;if(!g&&g!==0){e=d.browserEvent;f=document;a=f.documentElement;b=f.body;c[0]=e.clientX+(a&&a.scrollLeft||b&&b.scrollLeft||0)-(a&&a.clientLeft||b&&b.clientLeft||0);c[1]=e.clientY+(a&&a.scrollTop||b&&b.scrollTop||0)-(a&&a.clientTop||b&&b.clientTop||0)}}return c},getY:function(){return this.getXY()[1]},hasModifier:function(){var a=this;return !!(a.ctrlKey||a.altKey||a.shiftKey||a.metaKey)},isNavKeyPress:function(c){var a=this,b=a.keyCode,d=a.type==='keypress';return (!d||Ext.isGecko)&&b>=33&&b<=40||!c&&(b===a.RETURN||b===a.TAB||b===a.ESC)},isSpecialKey:function(){var b=this,a=b.keyCode,d=Ext.isGecko,c=b.type==='keypress';return d&&c&&b.charCode===0||this.isNavKeyPress()||a===b.BACKSPACE||a===b.ENTER||a>=16&&a<=20||(!c||d)&&a>=44&&a<=46},makeUnpreventable:function(){this.browserEvent.preventDefault=Ext.emptyFn},preventDefault:function(){var a=this,b=a.parentEvent;a.defaultPrevented=!0;if(b){b.defaultPrevented=!0}a.browserEvent.preventDefault();return a},setCurrentTarget:function(a){this.currentTarget=this.delegatedTarget=a},stopEvent:function(){return this.preventDefault().stopPropagation()},stopPropagation:function(){var a=this,b=a.browserEvent,c=a.parentEvent;a.isStopped=!0;if(c){c.isStopped=!0}if(!b.stopPropagation){b.cancelBubble=!0;return a}b.stopPropagation();return a},within:function(b,d,c){var a;if(b){a=d?this.getRelatedTarget():this.getTarget()}return a?Ext.fly(b).contains(a)||!!(c&&a===Ext.getDom(b)):!1},deprecated:{'4.0':{methods:{getPageX:'getX',getPageY:'getY'}}}},1,0,0,0,0,0,[Ext.event,'Event',Ext,'EventObjectImpl'],function(f){var b=f.prototype,a={BACKSPACE:8,TAB:9,NUM_CENTER:12,ENTER:13,RETURN:13,SHIFT:16,CTRL:17,ALT:18,PAUSE:19,CAPS_LOCK:20,ESC:27,SPACE:32,PAGE_UP:33,PAGE_DOWN:34,END:35,HOME:36,LEFT:37,UP:38,RIGHT:39,DOWN:40,PRINT_SCREEN:44,INSERT:45,DELETE:46,ZERO:48,ONE:49,TWO:50,THREE:51,FOUR:52,FIVE:53,SIX:54,SEVEN:55,EIGHT:56,NINE:57,A:65,B:66,C:67,D:68,E:69,F:70,G:71,H:72,I:73,J:74,K:75,L:76,M:77,N:78,O:79,P:80,Q:81,R:82,S:83,T:84,U:85,V:86,W:87,X:88,Y:89,Z:90,CONTEXT_MENU:93,NUM_ZERO:96,NUM_ONE:97,NUM_TWO:98,NUM_THREE:99,NUM_FOUR:100,NUM_FIVE:101,NUM_SIX:102,NUM_SEVEN:103,NUM_EIGHT:104,NUM_NINE:105,NUM_MULTIPLY:106,NUM_PLUS:107,NUM_MINUS:109,NUM_PERIOD:110,NUM_DIVISION:111,F1:112,F2:113,F3:114,F4:115,F5:116,F6:117,F7:118,F8:119,F9:120,F10:121,F11:122,F12:123,WHEEL_SCALE:function(){var a;if(Ext.isGecko){a=3}else {if(Ext.isMac){if(Ext.isSafari&&Ext.webKitVersion>=532){a=120}else {a=12}a*=3}else {a=120}}return a}()},d={},c,e;Ext.apply(f,a);Ext.apply(b,a);delete a.WHEEL_SCALE;delete a.RETURN;for(c in a){e=a[c];d[e]=c}b.keyCodes=d;b.getTrueXY=b.getXY});Ext.define('Ext.overrides.event.Event',{override:'Ext.event.Event',mousedownEvents:{mousedown:1,pointerdown:1,touchstart:1},injectEvent:function(){var a,b={},c;if(!Ext.isIE9m&&document.createEvent){a={createHtmlEvent:function(e,d,c,b){var a=e.createEvent('HTMLEvents');a.initEvent(d,c,b);return a},createMouseEvent:function(d,n,h,f,m,b,c,i,k,g,j,l,e){var a=d.createEvent('MouseEvents'),o=d.defaultView||window;if(a.initMouseEvent){a.initMouseEvent(n,h,f,o,m,b,c,b,c,i,k,g,j,l,e)}else {a=d.createEvent('UIEvents');a.initEvent(n,h,f);a.view=o;a.detail=m;a.screenX=b;a.screenY=c;a.clientX=b;a.clientY=c;a.ctrlKey=i;a.altKey=k;a.metaKey=j;a.shiftKey=g;a.button=l;a.relatedTarget=e}return a},createUIEvent:function(b,f,d,c,e){var a=b.createEvent('UIEvents'),g=b.defaultView||window;a.initUIEvent(f,d,c,g,e);return a},fireEvent:function(a,c,b){a.dispatchEvent(b)}}}else {if(document.createEventObject){c={0:1,1:4,2:2};a={createHtmlEvent:function(d,e,c,b){var a=d.createEventObject();a.bubbles=c;a.cancelable=b;return a},createMouseEvent:function(n,o,i,g,m,b,d,j,l,h,k,e,f){var a=n.createEventObject();a.bubbles=i;a.cancelable=g;a.detail=m;a.screenX=b;a.screenY=d;a.clientX=b;a.clientY=d;a.ctrlKey=j;a.altKey=l;a.shiftKey=h;a.metaKey=k;a.button=c[e]||e;a.relatedTarget=f;return a},createUIEvent:function(d,f,c,b,e){var a=d.createEventObject();a.bubbles=c;a.cancelable=b;return a},fireEvent:function(a,c,b){a.fireEvent('on'+c,b)}}}}Ext.Object.each({load:[!1,!1],unload:[!1,!1],select:[!0,!1],change:[!0,!1],submit:[!0,!0],reset:[!0,!1],resize:[!0,!1],scroll:[!0,!1]},function(c,d){var f=d[0],e=d[1];b[c]=function(b,h){var g=a.createHtmlEvent(c,f,e);a.fireEvent(b,c,g)}});function createMouseEventDispatcher(b,d){var c=b!=='mousemove';return function(f,e){var g=e.getXY(),h=a.createMouseEvent(f.ownerDocument,b,!0,c,d,g[0],g[1],e.ctrlKey,e.altKey,e.shiftKey,e.metaKey,e.button,e.relatedTarget);a.fireEvent(f,b,h)}}Ext.each(['click','dblclick','mousedown','mouseup','mouseover','mousemove','mouseout'],function(a){b[a]=createMouseEventDispatcher(a,1)});Ext.Object.each({focusin:[!0,!1],focusout:[!0,!1],activate:[!0,!0],focus:[!1,!1],blur:[!1,!1]},function(c,d){var f=d[0],e=d[1];b[c]=function(b,h){var g=a.createUIEvent(b.ownerDocument,c,f,e,1);a.fireEvent(b,c,g)}});if(!a){b={};a={}}function cannotInject(b,a){}return function(a){var c=this,d=b[c.type]||cannotInject,e=a?a.dom||a:c.getTarget();d(e,c)}}(),preventDefault:function(){var c=this,a=c.browserEvent,e=c.parentEvent,d,b;if(typeof a.type!=='unknown'){c.defaultPrevented=!0;if(e){e.defaultPrevented=!0}if(a.preventDefault){a.preventDefault()}else {if(a.type==='mousedown'){b=a.target;d=b.getAttribute('unselectable');if(d!=='on'){b.setAttribute('unselectable','on');Ext.defer(function(){b.setAttribute('unselectable',d)},1)}}a.returnValue=!1;if(a.ctrlKey||a.keyCode>111&&a.keyCode<124){a.keyCode=-1}}}return c},stopPropagation:function(){var a=this,b=a.browserEvent;if(typeof b.type!=='unknown'){if(a.mousedownEvents[a.type]){Ext.GlobalEvents.fireMouseDown(a)}arguments.callee.$previous.call(this)}return a},deprecated:{'5.0':{methods:{clone:function(){return new this.self(this.browserEvent,this)}}}}},function(){var c=this,d,a=function(a){if(a.keyCode===9){c.forwardTab=!a.shiftKey}},b=function(a){if(a.keyCode===9){delete c.forwardTab}};if(Ext.isIE9m){d={0:0,1:0,4:1,2:2};c.override({statics:{enableIEAsync:function(b){var a,c={};for(a in b){c[a]=b[a]}return c}},constructor:function(a,f,e,c){var b=this;b.callParent([a,f,e,c]);b.button=d[a.button];if(a.type==='contextmenu'){b.button=2}b.toElement=a.toElement;b.fromElement=a.fromElement},mouseLeaveRe:/(mouseout|mouseleave)/,mouseEnterRe:/(mouseover|mouseenter)/,enableIEAsync:function(a){this.browserEvent=this.self.enableIEAsync(a)},getRelatedTarget:function(f,d,e){var a=this,c,b;if(!a.relatedTarget){c=a.type;if(a.mouseLeaveRe.test(c)){b=a.toElement}else {if(a.mouseEnterRe.test(c)){b=a.fromElement}}if(b){a.relatedTarget=a.self.resolveTextNode(b)}}return a.callParent([f,d,e])}});document.attachEvent('onkeydown',a);document.attachEvent('onkeyup',b);window.attachEvent('onunload',function(){document.detachEvent('onkeydown',a);document.detachEvent('onkeyup',b)})}else {if(document.addEventListener){document.addEventListener('keydown',a,!0);document.addEventListener('keyup',b,!0)}}});Ext.cmd.derive('Ext.event.publisher.Dom',Ext.event.publisher.Publisher,{type:'dom',handledDomEvents:[],reEnterCount:0,captureEvents:{animationstart:1,animationend:1,resize:1,focus:1,blur:1,scroll:1},directEvents:{mouseenter:1,mouseleave:1,pointerenter:1,pointerleave:1,MSPointerEnter:1,MSPointerLeave:1,load:1,unload:1,beforeunload:1,error:1,DOMContentLoaded:1,DOMFrameContentLoaded:1,hashchange:1},blockedPointerEvents:{pointerover:1,pointerout:1,pointerenter:1,pointerleave:1,MSPointerOver:1,MSPointerOut:1,MSPointerEnter:1,MSPointerLeave:1},blockedCompatibilityMouseEvents:{mouseenter:1,mouseleave:1},constructor:function(){var a=this;a.bubbleSubscribers={};a.captureSubscribers={};a.directSubscribers={};a.directCaptureSubscribers={};a.delegatedListeners={};a.initHandlers();Ext.onInternalReady(a.onReady,a);Ext.event.publisher.Publisher.prototype.constructor.call(this)},registerEvents:function(){var b=this,e=Ext.event.publisher.Publisher.publishersByEvent,d=b.handledDomEvents,f=d.length,c=0,a;for(;cb?1:a1){e=[];for(d=0;d0){b.invokeRecognizers('onTouchMove',a)}}},onTouchEnd:function(b){var a=this;if(!a.isStarted){return}a.updateTouches(b,!0);a.invokeRecognizers(a.isCancelEvent[b.type]?'onTouchCancel':'onTouchEnd',b);if(!a.activeTouches.length){a.isStarted=!1;a.invokeRecognizers('onEnd',b);if(Ext.enableGarbageCollector){Ext.dom.GarbageCollector.resume()}}},onTargetTouchMove:function(a){if(Ext.elevateFunction){Ext.elevateFunction(this.doTargetTouchMove,this,[a])}else {this.doTargetTouchMove(a)}},doTargetTouchMove:function(a){if(!Ext.getBody().contains(a.target)){this.onTouchMove(new Ext.event.Event(a))}},onTargetTouchEnd:function(a){if(Ext.elevateFunction){Ext.elevateFunction(this.doTargetTouchEnd,this,[a])}else {this.doTargetTouchEnd(a)}},doTargetTouchEnd:function(c){var b=this,a=c.target;a.removeEventListener('touchmove',b.onTargetTouchMove);a.removeEventListener('touchend',b.onTargetTouchEnd);a.removeEventListener('touchcancel',b.onTargetTouchEnd);if(!Ext.getBody().contains(a)){b.onTouchEnd(new Ext.event.Event(c))}},updateAsync:function(a){this.handlers=a?this._asyncHandlers:this._handlers},reset:function(){var a=this,d=a.recognizers,e=d.length,b,c;a.activeTouchesMap={};a.activeTouches=[];a.changedTouches=[];a.isStarted=!1;for(b=0;b=500){this.run()}},run:function(){this.pending=!1;var i=this.readQueue,h=this.writeQueue,c=null,d;if(this.mode){d=i;if(h.length>0){c=!1}}else {d=h;if(i.length>0){c=!0}}var g=d.slice(),f,j,b,a,e;d.length=0;for(f=0,j=g.length;f2){a.apply(e,b[2])}else {a.call(e)}}g.length=0;if(c!==null){this.request(c)}}},1,0,0,0,0,0,[Ext,'TaskQueue'],0);Ext.cmd.derive('Ext.util.sizemonitor.Abstract',Ext.Base,{config:{element:null,callback:Ext.emptyFn,scope:null,args:[]},width:0,height:0,contentWidth:0,contentHeight:0,constructor:function(a){this.refresh=Ext.Function.bind(this.refresh,this);this.info={width:0,height:0,contentWidth:0,contentHeight:0,flag:0};this.initElement();this.initConfig(a);this.bindListeners(!0)},bindListeners:Ext.emptyFn,applyElement:function(a){if(a){return Ext.get(a)}},updateElement:function(a){a.append(this.detectorsContainer);a.addCls('x-size-monitored')},applyArgs:function(a){return a.concat([this.info])},refreshMonitors:Ext.emptyFn,forceRefresh:function(){Ext.TaskQueue.requestRead('refresh',this)},getContentBounds:function(){return this.detectorsContainer.getBoundingClientRect()},getContentWidth:function(){return this.detectorsContainer.offsetWidth},getContentHeight:function(){return this.detectorsContainer.offsetHeight},refreshSize:function(){var b=this.getElement();if(!b||b.destroyed){return !1}var h=b.getWidth(),g=b.getHeight(),d=this.getContentWidth(),c=this.getContentHeight(),j=this.contentWidth,i=this.contentHeight,a=this.info,f=!1,e;this.width=h;this.height=g;this.contentWidth=d;this.contentHeight=c;e=(j!==d?1:0)+(i!==c?2:0);if(e>0){a.width=h;a.height=g;a.contentWidth=d;a.contentHeight=c;a.flag=e;f=!0;this.getCallback().apply(this.getScope(),this.getArgs())}return f},refresh:function(a){if(this.refreshSize()||a){Ext.TaskQueue.requestWrite('refreshMonitors',this)}},destroy:function(){var a=this,b=a.getElement();a.bindListeners(!1);if(b&&!b.destroyed){b.removeCls('x-size-monitored')}delete a._element;a.callParent()}},1,0,0,0,0,[[Ext.mixin.Templatable.prototype.mixinId||Ext.mixin.Templatable.$className,Ext.mixin.Templatable]],[Ext.util.sizemonitor,'Abstract'],0);Ext.cmd.derive('Ext.util.sizemonitor.Scroll',Ext.util.sizemonitor.Abstract,{getElementConfig:function(){return {reference:'detectorsContainer',classList:['x-size-monitors','scroll'],children:[{reference:'expandMonitor',className:'expand'},{reference:'shrinkMonitor',className:'shrink'}]}},constructor:function(a){this.onScroll=Ext.Function.bind(this.onScroll,this);Ext.util.sizemonitor.Abstract.prototype.constructor.apply(this,arguments)},bindListeners:function(b){var a=b?'addEventListener':'removeEventListener';this.expandMonitor[a]('scroll',this.onScroll,!0);this.shrinkMonitor[a]('scroll',this.onScroll,!0)},forceRefresh:function(){Ext.TaskQueue.requestRead('refresh',this,[!0])},onScroll:function(){Ext.TaskQueue.requestRead('refresh',this)},refreshMonitors:function(){var a=this.expandMonitor,b=this.shrinkMonitor,c=1000000;if(a&&!a.destroyed){a.scrollLeft=c;a.scrollTop=c}if(b&&!b.destroyed){b.scrollLeft=c;b.scrollTop=c}}},1,0,0,0,0,0,[Ext.util.sizemonitor,'Scroll'],0);Ext.cmd.derive('Ext.util.sizemonitor.OverflowChange',Ext.util.sizemonitor.Abstract,{constructor:function(a){this.onExpand=Ext.Function.bind(this.onExpand,this);this.onShrink=Ext.Function.bind(this.onShrink,this);Ext.util.sizemonitor.Abstract.prototype.constructor.apply(this,arguments)},getElementConfig:function(){return {reference:'detectorsContainer',classList:['x-size-monitors','overflowchanged'],children:[{reference:'expandMonitor',className:'expand',children:[{reference:'expandHelper'}]},{reference:'shrinkMonitor',className:'shrink',children:[{reference:'shrinkHelper'}]}]}},bindListeners:function(b){var a=b?'addEventListener':'removeEventListener';this.expandMonitor[a](Ext.browser.is.Firefox?'underflow':'overflowchanged',this.onExpand,!0);this.shrinkMonitor[a](Ext.browser.is.Firefox?'overflow':'overflowchanged',this.onShrink,!0)},onExpand:function(a){if(Ext.browser.is.Webkit&&a.horizontalOverflow&&a.verticalOverflow){return}Ext.TaskQueue.requestRead('refresh',this)},onShrink:function(a){if(Ext.browser.is.Webkit&&!a.horizontalOverflow&&!a.verticalOverflow){return}Ext.TaskQueue.requestRead('refresh',this)},refreshMonitors:function(){if(this.destroyed){return}var b=this.expandHelper,c=this.shrinkHelper,d=this.getContentBounds(),f=d.width,e=d.height,a;if(b&&!b.destroyed){a=b.style;a.width=f+1+'px';a.height=e+1+'px'}if(c&&!c.destroyed){a=c.style;a.width=f+'px';a.height=e+'px'}Ext.TaskQueue.requestRead('refresh',this)}},1,0,0,0,0,0,[Ext.util.sizemonitor,'OverflowChange'],0);Ext.cmd.derive('Ext.util.SizeMonitor',Ext.Base,{constructor:function(b){var a=Ext.util.sizemonitor;if(Ext.browser.is.Firefox){return new a.OverflowChange(b)}else {return new a.Scroll(b)}}},1,0,0,0,0,0,[Ext.util,'SizeMonitor'],0);Ext.cmd.derive('Ext.event.publisher.ElementSize',Ext.event.publisher.Publisher,{type:'size',handledEvents:['resize'],constructor:function(){this.monitors={};this.subscribers={};Ext.event.publisher.Publisher.prototype.constructor.apply(this,arguments)},subscribe:function(b){var a=b.id,c=this.subscribers,d=this.monitors;if(c[a]){++c[a]}else {c[a]=1;d[a]=new Ext.util.SizeMonitor({element:b,callback:this.onElementResize,scope:this,args:[b]})}b.on('painted','forceRefresh',d[a]);return !0},unsubscribe:function(e){var a=e.id,c=this.subscribers,d=this.monitors,b;if(c[a]&&!--c[a]){delete c[a];b=d[a];e.un('painted','forceRefresh',b);b.destroy();delete d[a]}},onElementResize:function(a,b){Ext.TaskQueue.requestRead('fire',this,[a,'resize',[a,b]])}},1,0,0,0,0,0,[Ext.event.publisher,'ElementSize'],function(a){a.instance=new a()});Ext.cmd.derive('Ext.util.paintmonitor.Abstract',Ext.Base,{config:{element:null,callback:Ext.emptyFn,scope:null,args:[]},eventName:'',monitorClass:'',constructor:function(a){this.onElementPainted=Ext.Function.bind(this.onElementPainted,this);this.initConfig(a)},bindListeners:function(a){this.monitorElement[a?'addEventListener':'removeEventListener'](this.eventName,this.onElementPainted,!0)},applyElement:function(a){if(a){return Ext.get(a)}},updateElement:function(a){this.monitorElement=Ext.Element.create({classList:['x-paint-monitor',this.monitorClass]},!0);a.appendChild(this.monitorElement);a.addCls('x-paint-monitored');this.bindListeners(!0)},onElementPainted:function(){},destroy:function(){var a=this,c=a.monitorElement,d=c.parentNode,b=a.getElement();a.bindListeners(!1);delete a.monitorElement;if(b&&!b.destroyed){b.removeCls('x-paint-monitored');delete a._element}if(d){d.removeChild(c)}a.callParent()}},1,0,0,0,0,0,[Ext.util.paintmonitor,'Abstract'],0);Ext.cmd.derive('Ext.util.paintmonitor.CssAnimation',Ext.util.paintmonitor.Abstract,{eventName:Ext.browser.is.WebKit?'webkitAnimationEnd':'animationend',monitorClass:'cssanimation',onElementPainted:function(a){if(a.animationName==='x-paint-monitor-helper'){this.getCallback().apply(this.getScope(),this.getArgs())}}},0,0,0,0,0,0,[Ext.util.paintmonitor,'CssAnimation'],0);Ext.cmd.derive('Ext.util.PaintMonitor',Ext.Base,{constructor:function(a){return new Ext.util.paintmonitor.CssAnimation(a)}},1,0,0,0,0,0,[Ext.util,'PaintMonitor'],0);Ext.cmd.derive('Ext.event.publisher.ElementPaint',Ext.event.publisher.Publisher,{type:'paint',handledEvents:['painted'],constructor:function(){this.monitors={};this.subscribers={};Ext.event.publisher.Publisher.prototype.constructor.apply(this,arguments)},subscribe:function(d){var b=this,a=d.id,c=b.subscribers;if(c[a]){++c[a]}else {c[a]=1;b.monitors[a]=new Ext.util.PaintMonitor({element:d,callback:b.onElementPainted,scope:b,args:[d]})}},unsubscribe:function(d){var a=d.id,b=this.subscribers,c=this.monitors;if(b[a]&&!--b[a]){delete b[a];c[a].destroy();delete c[a]}},onElementPainted:function(a){Ext.TaskQueue.requestRead('fire',this,[a,'painted',[a]])}},1,0,0,0,0,0,[Ext.event.publisher,'ElementPaint'],function(a){a.instance=new a()});Ext.cmd.derive('Ext.dom.Element',Ext.Base,function(a){var h=window,b=document,F='ext-window',D='ext-document',w='width',H='height',ac='min-width',_='min-height',ab='max-width',$='max-height',S='top',P='right',ag='bottom',R='left',aa='visibility',M='hidden',G='display',x='none',O='z-index',u='position',ad='relative',N='static',i='-',T=/\w/g,k=/\s+/,V=/[\s]+/,Y=/^(?:transparent|(?:rgba[(](?:\s*\d+\s*[,]){3}\s*0\s*[)]))$/i,U=/table-row|table-.*-group/,Q=/top/i,d={t:'border-top-width',r:'border-right-width',b:'border-bottom-width',l:'border-left-width'},f={t:'padding-top',r:'padding-right',b:'padding-bottom',l:'padding-left'},v={t:'margin-top',r:'margin-right',b:'margin-bottom',l:'margin-left'},Z=[f.l,f.r,f.t,f.b],B=[d.l,d.r,d.t,d.b],ae=/\d+$/,I=/\d+(px|em|%|en|ex|pt|in|cm|mm|pc)$/i,C='px',af=/(-[a-z])/gi,J=/([a-z0-9\-]+)\s*:\s*([^;\s]+(?:\s*[^;\s]+)*);?/gi,t=/^\d+(?:\.\d*)?px$/i,A={},y='originalDisplay',X=function(c,b){return b.charAt(1).toUpperCase()},E=function(d,e){var c,b,f;if(d.nodeType===1){d._extData=null;if(e){c=d.childNodes;for(b=0,f=c.length;bh.innerWidth?'portrait':'landscape'},getViewportHeight:function(){var c=a._viewportHeight;if(Ext.isIE9m){return b.documentElement.clientHeight}return c!=null?c:h.innerHeight},getViewportWidth:function(){var c=a._viewportWidth;if(Ext.isIE9m){return b.documentElement.clientWidth}return c!=null?c:h.innerWidth},getViewSize:function(){return {width:a.getViewportWidth(),height:a.getViewportHeight()}},normalize:function(b){return A[b]||(A[b]=b.replace(af,X))},_onWindowFocusChange:function(b){if(Ext.fly(b.target).is(a.editableSelector)){z=new Date();L=b.type==='focusin'||b.type==='pointerup'}},_onWindowResize:function(){var c=window.innerWidth,b=window.innerHeight,g=new Date(),f=1000,d,e;d=c-a._windowWidth;e=b-a._windowHeight;a._windowWidth=c;a._windowHeight=b;if(g-z=a.minKeyboardHeight){l=!1;K=new Date()}if(l){return}a._viewportWidth=c;a._viewportHeight=b},parseBox:function(c){c=c||0;var e=typeof c,b,d;if(e==='number'){return {top:c,right:c,bottom:c,left:c}}else {if(e!=='string'){return c}}b=c.split(' ');d=b.length;if(d===1){b[1]=b[2]=b[3]=b[0]}else {if(d===2){b[2]=b[0];b[3]=b[1]}else {if(d===3){b[3]=b[1]}}}return {top:parseFloat(b[0])||0,right:parseFloat(b[1])||0,bottom:parseFloat(b[2])||0,left:parseFloat(b[3])||0}},parseStyles:function(c){var d={},b;if(c){J.lastIndex=0;while(b=J.exec(c)){d[b[1]]=b[2]||''}}return d},select:function(d,c,e){return Ext.fly(e||b).select(d,c)},query:function(c,d,e){return Ext.fly(e||b).query(c,d)},unitizeBox:function(b,d){var c=this;b=c.parseBox(b);return c.addUnits(b.top,d)+' '+c.addUnits(b.right,d)+' '+c.addUnits(b.bottom,d)+' '+c.addUnits(b.left,d)},serializeForm:function(l){var m=l.elements||(b.forms[l]||Ext.getDom(l)).elements,n=!1,f=encodeURIComponent,g='',q=m.length,c,h,d,k,o,i,j,p,e;for(i=0;i0||b.scrollLeft!==0){e.push(b);g.push(c.attach(b).getScroll())}}return function(){var d,b,f;for(b=0,f=e.length;b '+d,!!c)},clone:function(c,d){var b=this.dom.cloneNode(c);if(Ext.supports.CloneNodeCopiesExpando){E(b,c)}return d?b:Ext.get(b)},constrainScrollLeft:function(c){var b=this.dom;return Math.max(Math.min(c,b.scrollWidth-b.clientWidth),0)},constrainScrollTop:function(c){var b=this.dom;return Math.max(Math.min(c,b.scrollHeight-b.clientHeight),0)},createChild:function(b,c,d){b=b||{tag:'div'};if(c){return Ext.DomHelper.insertBefore(c,b,d!==!0)}else {return Ext.DomHelper.append(this.dom,b,d!==!0)}},contains:function(b){if(!b){return !1}var d=this,c=Ext.getDom(b);return c===d.dom||d.isAncestor(c)},destroy:function(){var c=this,b=c.dom;if(b&&b.parentNode){b.parentNode.removeChild(b)}c.collect();if(!c.isFly){c.callParent()}},detach:function(){var b=this.dom;if(b&&b.parentNode&&b.tagName!=='BODY'){b.parentNode.removeChild(b)}return this},disableShadow:function(){var b=this.shadow;if(b){b.hide();b.disabled=!0}},disableShim:function(){var b=this.shim;if(b){b.hide();b.disabled=!0}},disableTouchContextMenu:function(){this._contextMenuListenerRemover=this.on({MSHoldVisual:function(b){b.preventDefault()},destroyable:!0,delegated:!1})},disableTouchScroll:function(){this.addCls(W);this.on({touchmove:function(b){b.preventDefault()},translate:!1})},doReplaceWith:function(c){var b=this.dom;b.parentNode.replaceChild(Ext.getDom(c),b)},doScrollIntoView:function(b,o,d,m,l,n){c=c||new Ext.dom.Fly();var e=this,k=e.dom,i=c.attach(b)[l](),j=b.scrollTop,h=e.getScrollIntoViewXY(b,i,j),f=h.x,g=h.y;if(m){if(d){d=Ext.apply({listeners:{afteranimate:function(){c.attach(k).highlight()}}},d)}else {c.attach(k).highlight()}}if(g!==j){c.attach(b).scrollTo('top',g,d)}if(o!==!1&&f!==i){c.attach(b)[n]('left',f,d)}return e},down:function(c,b){return this.selectNode(c,!!b)},enableShadow:function(f,e){var c=this,b=c.shadow||(c.shadow=new Ext.dom.Shadow(Ext.apply({target:c},f))),d=c.shim;if(d){d.offsets=b.outerOffsets;d.shadow=b;b.shim=d}if(e===!0||e!==!1&&c.isVisible()){b.show()}else {b.hide()}b.disabled=!1},enableShim:function(f,e){var c=this,b=c.shim||(c.shim=new Ext.dom.Shim(Ext.apply({target:c},f))),d=c.shadow;if(d){b.offsets=d.outerOffsets;b.shadow=d;d.shim=b}if(e===!0||e!==!1&&c.isVisible()){b.show()}else {b.hide()}b.disabled=!1},findParent:function(g,d,h){var i=this,c=i.dom,e=b.documentElement,f=0;if(d||d===0){if(typeof d!=='number'){e=Ext.getDom(d);d=Number.MAX_VALUE}}else {d=50}while(c&&c.nodeType===1&&f0&&d<0.5){b++}}}if(e){b-=c.getBorderWidth('tb')+c.getPadding('tb')}return b<0?0:b},getHtml:function(){return this.dom?this.dom.innerHTML:''},getLeft:function(b){return b?this.getLocalX():this.getX()},getLocalX:function(){var d=this,c,b=d.getStyle('left');if(!b||b==='auto'){b=0}else {if(t.test(b)){b=parseFloat(b)}else {b=d.getX();c=d.dom.offsetParent;if(c){b-=Ext.fly(c).getX()}}}return b},getLocalXY:function(){var e=this,d,f=e.getStyle(['left','top']),b=f.left,c=f.top;if(!b||b==='auto'){b=0}else {if(t.test(b)){b=parseFloat(b)}else {b=e.getX();d=e.dom.offsetParent;if(d){b-=Ext.fly(d).getX()}}}if(!c||c==='auto'){c=0}else {if(t.test(c)){c=parseFloat(c)}else {c=e.getY();d=e.dom.offsetParent;if(d){c-=Ext.fly(d).getY()}}}return [b,c]},getLocalY:function(){var d=this,c,b=d.getStyle('top');if(!b||b==='auto'){b=0}else {if(t.test(b)){b=parseFloat(b)}else {b=d.getY();c=d.dom.offsetParent;if(c){b-=Ext.fly(c).getY()}}}return b},getMargin:function(){var c={t:'top',l:'left',r:'right',b:'bottom'},b=['margin-top','margin-left','margin-right','margin-bottom'];return function(g){var h=this,e,f,d;if(!g){e=h.getStyle(b);d={};if(e&&typeof e==='object'){d={};for(f in v){d[f]=d[c[f]]=parseFloat(e[v[f]])||0}}}else {d=h.addStyles(g,v)}return d}}(),getPadding:function(b){return this.addStyles(b,f)},getParent:function(){return Ext.get(this.dom.parentNode)},getRight:function(b){return (b?this.getLocalX():this.getX())+this.getWidth()},getScroll:function(){var h=this,d=h.dom,g=b.documentElement,e,f,c=document.body;if(d===b||d===c){e=g.scrollLeft||(c?c.scrollLeft:0);f=g.scrollTop||(c?c.scrollTop:0)}else {e=d.scrollLeft;f=d.scrollTop}return {left:e,top:f}},getScrollIntoViewXY:function(r,b,c){var p=this.dom,h=Ext.getDom(r),j=this.getOffsetsTo(h),o=p.offsetWidth,m=p.offsetHeight,f=j[0]+b,g=j[1]+c,l=g+m,n=f+o,d=h.clientHeight,e=h.clientWidth,i=b,k=c,q=k+d,s=i+e;if(m>d||gq){c=l-d}}if(o>e||fs){b=n-e}}return {x:b,y:c}},getScrollLeft:function(){var c=this.dom;if(c===b||c===document.body){return this.getScroll().left}else {return c.scrollLeft}},getScrollTop:function(){var c=this.dom;if(c===b||c===document.body){return this.getScroll().top}else {return c.scrollTop}},getSize:function(b){return {width:this.getWidth(b),height:this.getHeight(b)}},getStyle:function(n,i){var k=this,e=k.dom,m=typeof n!=='string',p=k.styleHooks,b=n,j=b,q=1,h,o,f,d,g,c,l;if(m){f={};b=j[0];l=0;if(!(q=j.length)){return f}}if(!e||e.documentElement){return f||''}h=e.style;if(i){c=h}else {c=e.ownerDocument.defaultView.getComputedStyle(e,null);if(!c){i=!0;c=h}}do{d=p[b];if(!d){p[b]=d={name:a.normalize(b)}}if(d.get){g=d.get(e,k,i,c)}else {o=d.name;g=c[o]}if(!m){return g}f[b]=g;b=j[++l]}while(l0&&e<0.5){b++}}}if(h){b-=c.getBorderWidth('lr')+c.getPadding('lr')}return b<0?0:b},getX:function(){return this.getXY()[0]},getXY:function(){var h=Math.round,e=this.dom,f=0,g=0,c,d;if(e!==b&&e!==b.body){try{c=e.getBoundingClientRect()}catch(ah){c={left:0,top:0}}f=h(c.left);g=h(c.top);d=Ext.getDoc().getScroll();f+=d.left;g+=d.top}return [f,g]},getY:function(){return this.getXY()[1]},getZIndex:function(){return parseInt(this.getStyle('z-index'),10)},hasCls:function(c){var b=this.getData();if(!b.isSynchronized){this.synchronize()}return b.classMap.hasOwnProperty(c)},hide:function(){this.setVisible(!1);return this},insertAfter:function(b){b=Ext.getDom(b);b.parentNode.insertBefore(this.dom,b.nextSibling);return this},insertBefore:function(b){b=Ext.getDom(b);b.parentNode.insertBefore(this.dom,b);return this},insertFirst:function(b,c){b=b||{};if(b.nodeType||b.dom||typeof b==='string'){b=Ext.getDom(b);this.dom.insertBefore(b,this.dom.firstChild);return !c?Ext.get(b):b}else {return this.createChild(b,this.dom.firstChild,c)}},insertHtml:function(d,e,c){var b=Ext.DomHelper.insertHtml(d,this.dom,e);return c?Ext.get(b):b},insertSibling:function(b,k,f){var d=this,j=Ext.DomHelper,h=(k||'before').toLowerCase()==='after',c,g,i,e;if(Ext.isIterable(b)){i=b.length;g=Ext.fly(document.createDocumentFragment());if(Ext.isArray(b)){for(e=0;eb.clientHeight||b.scrollWidth>b.clientWidth},isStyle:function(b,c){return this.getStyle(b)===c},isVisible:function(d){var b=this.dom,c;if(!b){return !1}if(!s){s=new Ext.dom.Fly()}for(c=b.ownerDocument.documentElement;b!==c;b=b.parentNode){if(!b||b.nodeType===11||s.attach(b).isStyle(aa,M)||s.isStyle(G,x)){return !1}if(!d){break}}return !0},last:function(c,b){return this.matchNode('previousSibling','lastChild',c,b)},maskIframes:function(){var b=document.getElementsByTagName('iframe');Ext.each(b,function(c){var b=Ext.fly(c.parentNode),d=b.mask();d.setStyle('background-color','transparent')})},matchNode:function(g,f,c,e){var d=this.dom,b;if(!d){return null}b=d[f];while(b){if(b.nodeType===1&&(!c||Ext.fly(b,'_matchNode').is(c))){return !e?Ext.get(b):b}b=b[g]}return null},next:function(c,b){return this.matchNode('nextSibling','nextSibling',c,b)},parent:function(c,b){return this.matchNode('parentNode','parentNode',c,b)},position:function(c,d,e,f){var b=this;if(b.dom.tagName!=='BODY'){if(!c&&b.isStyle(u,N)){b.setStyle(u,ad)}else {if(c){b.setStyle(u,c)}}if(d){b.setStyle(O,d)}if(e||f){b.setXY([e||!1,f||!1])}}},prev:function(c,b){return this.matchNode('previousSibling','previousSibling',c,b)},query:function(b,e,j){var i=this.dom,g,l,k,h,f,c,d;if(!i){return null}e=e!==!1;b=b.split(',');if(!j){g=[]}for(c=0,l=b.length;c0){b=i.className.split(V);for(c=0,j=b.length;c=':function(b){var a=this._filterValue;return this.getCandidateValue(b,a)>=a},'>':function(b){var a=this._filterValue;return this.getCandidateValue(b,a)>a},'!=':function(a){var b=this,c=b._filterValue;a=b.getCandidateValue(a,c);if(b.isDateValue&&a instanceof Date){a=a.getTime();c=b.dateValue}return a!=c},'!==':function(a){var b=this,c=b._filterValue;a=b.getCandidateValue(a,c,!0);if(b.isDateValue&&a instanceof Date){a=a.getTime();c=b.dateValue}return a!==c},'in':function(b){var a=this._filterValue;return Ext.Array.contains(a,this.getCandidateValue(b,a))},notin:function(b){var a=this._filterValue;return !Ext.Array.contains(a,this.getCandidateValue(b,a))},like:function(b){var a=this._filterValue;return a&&this.getCandidateValue(b,a).toLowerCase().indexOf(a.toLowerCase())>-1}};a['==']=a['='];a.gt=a['>'];a.ge=a['>='];a.lt=a['<'];a.le=a['<='];a.eq=a['='];a.ne=a['!=']});Ext.cmd.derive('Ext.util.Observable',Ext.mixin.Observable,{$applyConfigs:!0},0,0,0,0,0,0,[Ext.util,'Observable'],function(a){var b=Ext.mixin.Observable;a.releaseCapture=b.releaseCapture;a.capture=b.capture;a.captureArgs=b.captureArgs;a.observe=a.observeClass=b.observe});Ext.cmd.derive('Ext.util.AbstractMixedCollection',Ext.Base,{isMixedCollection:!0,generation:0,indexGeneration:0,constructor:function(b,c){var a=this;if(arguments.length===1&&Ext.isObject(b)){a.initialConfig=b;Ext.apply(a,b)}else {a.allowFunctions=b===!0;if(c){a.getKey=c}a.initialConfig={allowFunctions:a.allowFunctions,getKey:a.getKey}}a.items=[];a.map={};a.keys=[];a.indexMap={};a.length=0;a.mixins.observable.constructor.call(a)},destroy:function(){var a=this;a.items=a.map=a.keys=a.indexMap=null;a.callParent()},allowFunctions:!1,add:function(b,d){var c=this.length,a;if(arguments.length===1){a=this.insert(c,b)}else {a=this.insert(c,b,d)}return a},getKey:function(a){return a.id},replace:function(b,c){var a=this,d,e;if(arguments.length==1){c=arguments[0];b=a.getKey(c)}d=a.map[b];if(typeof b=='undefined'||b===null||typeof d=='undefined'){return a.add(b,c)}a.generation++;e=a.indexOfKey(b);a.items[e]=c;a.map[b]=c;if(a.hasListeners.replace){a.fireEvent('replace',b,d,c)}return c},reorder:function(e){var b=this,f=b.items,a=0,h=f.length,c=[],g=[],d;b.suspendEvents();for(d in e){c[e[d]]=f[d]}for(a=0;a-1){g=e[b];delete e[b];delete f[b];e[c]=g;f[c]=d;a.keys[d]=c;a.indexGeneration=++a.generation}},addAll:function(a){var c=this,b;if(arguments.length>1||Ext.isArray(a)){c.insert(c.length,arguments.length>1?arguments:a)}else {for(b in a){if(a.hasOwnProperty(b)){if(c.allowFunctions||typeof a[b]!='function'){c.add(b,a[b])}}}}},each:function(f,e){var c=Ext.Array.push([],this.items),a=0,d=c.length,b;for(;a2){a=this.doInsert(c,[b],[d])}else {a=this.doInsert(c,[b])}a=a[0]}return a},doInsert:function(f,e,d){var b=this,c,i,a,g=e.length,j=g,o=b.hasListeners.add,k,h={},l,n,m;if(d!=null){b.useLinearSearch=!0}else {d=e;e=new Array(g);for(a=0;a=0;--c){a.remove(b[c])}}else {while(a.length){a.removeAt(0)}}}else {a.length=a.items.length=a.keys.length=0;a.map={};a.indexMap={};a.generation++;a.indexGeneration=a.generation}},removeAt:function(b){var a=this,d,c;if(b=0){a.length--;d=a.items[b];Ext.Array.erase(a.items,b,1);c=a.keys[b];if(typeof c!='undefined'){delete a.map[c]}Ext.Array.erase(a.keys,b,1);if(a.hasListeners.remove){a.fireEvent('remove',d,c)}a.generation++;return d}return !1},removeRange:function(c,b){var a=this,i,f,d,e,g,h;if(c=0){if(!b){b=1}e=Math.min(c+b,a.length);b=e-c;h=e===a.length;g=h&&a.indexGeneration===a.generation;for(d=c;d=0;a--){if(c[a]==null){b.removeAt(a)}}}else {return b.removeAt(b.indexOfKey(d))}},getCount:function(){return this.length},indexOf:function(b){var a=this,c;if(b!=null){if(!a.useLinearSearch&&(c=a.getKey(b))){return this.indexOfKey(c)}return Ext.Array.indexOf(a.items,b)}return -1},indexOfKey:function(a){if(!this.map.hasOwnProperty(a)){return -1}if(this.indexGeneration!==this.generation){this.rebuildIndexMap()}return this.indexMap[a]},rebuildIndexMap:function(){var b=this,d=b.indexMap={},c=b.keys,e=c.length,a;for(a=0;aa){e=!0;g=b;b=a;a=g}if(b<0){b=0}if(a==null||a>=d){a=d-1}c=f.slice(b,a+1);if(e&&c.length){c.reverse()}return c},filter:function(a,e,d,c){var b=[];if(Ext.isString(a)){b.push(new Ext.util.Filter({property:a,value:e,anyMatch:d,caseSensitive:c}))}else {if(Ext.isArray(a)||a instanceof Ext.util.Filter){b=b.concat(a)}}return this.filterBy(Ext.util.Filter.createFilterFn(b))},filterBy:function(h,g){var a=this,c=new a.self(a.initialConfig),e=a.keys,d=a.items,f=d.length,b;c.getKey=a.getKey;for(b=0;bb?1:a0){c.removeRange(b.multiSortLimit,g)};break;case 'prepend':c.insert(0,a);break;case 'append':c.addAll(a);break;case undefined:case null:case 'replace':c.clear();c.addAll(a);break;default:}}if(h!==!1){b.fireEvent('beforesort',b,a);b.onBeforeSort(a);if(b.getSorterCount()){b.doSort(b.generateComparator())}}return a},getSorterCount:function(){return this.getSorters().items.length},generateComparator:function(){var a=this.getSorters().getRange();return a.length?this.createComparator(a):this.emptyComparator},emptyComparator:function(){return 0},onBeforeSort:Ext.emptyFn,decodeSorters:function(b){if(!Ext.isArray(b)){if(b===undefined){b=[]}else {b=[b]}}var g=b.length,f=Ext.util.Sorter,e=this.getModel?this.getModel():this.model,d,a,c;for(c=0;c>1;c=d(h,f[a]);if(c>=0){b=a+1}else {if(c<0){e=a-1}}}return b},reorder:function(a){Ext.util.AbstractMixedCollection.prototype.reorder.call(this,a);this.fireEvent('sort',this)},sortByKey:function(a,b){this._sort('key',a,b||function(e,f){var c=String(e).toUpperCase(),d=String(f).toUpperCase();return c>d?1:cf){k=f}}}if(c){b.tasks=c}b.firing=!1;if(b.tasks.length){b.startTimer(k-g,Ext.Date.now())}if(j!==!1&&l.hasListeners.idle){l.fireEvent('idle')}},startTimer:function(b,e){var a=this,d=e+b,c=a.timerId;if(c&&a.nextExpires-d>a.interval){clearTimeout(c);c=null}if(!c){if(b=a.duration,b,c;if(h){d=a.duration;e=!0}b=this.collectTargetData(a,d,f,e);if(f){a.target.setAttr(b.anims[a.id].attributes,!0);g.collectTargetData(a,a.duration,f,e);a.paused=!0;b=a.target.target;if(a.target.isComposite){b=a.target.target.last()}c={};c[Ext.supports.CSS3TransitionEnd]=a.lastFrame;c.scope=a;c.single=!0;b.on(c)}return b},jumpToEnd:function(d){var a=this,b,c;if(!a.targetArr){a.targetArr={};c=!0}b=a.runAnim(d,!0);a.applyAnimAttrs(b,b.anims[d.id]);if(c){a.targetArr=null}},collectTargetData:function(a,d,f,e){var c=a.target.getId(),b=this.targetArr[c];if(!b){b=this.targetArr[c]={id:c,el:a.target,anims:{}}}b.anims[a.id]={id:a.id,anim:a,elapsed:d,isLastFrame:e,attributes:[{duration:a.duration,easing:f&&a.reverse?a.easingFn.reverse().toCSS3():a.easing,attrs:a.runAnim(d)}]};return b},applyAnimAttrs:function(c,a){var b=a.anim;if(a.attributes&&b.isRunning()){c.el.setAttr(a.attributes,!1,a.isLastFrame);if(a.isLastFrame){b.lastFrame()}}},applyPendingAttrs:function(){var c=this.targetArr,b,d,a,f,e;for(d in c){if(c.hasOwnProperty(d)){b=c[d];for(e in b.anims){if(b.anims.hasOwnProperty(e)){a=b.anims[e];f=a.anim;if(a.attributes&&f.isRunning()){b.el.setAttr(a.attributes,!1,a.isLastFrame);if(a.isLastFrame){f.lastFrame()}}}}}}}},1,0,0,0,0,[['queue',Ext.fx.Queue]],[Ext.fx,'Manager'],0);Ext.cmd.derive('Ext.fx.Animator',Ext.Base,{isAnimator:!0,duration:250,delay:0,delayStart:0,dynamic:!1,easing:'ease',running:!1,paused:!1,damper:1,iterations:1,currentIteration:0,keyframeStep:0,animKeyFramesRE:/^(from|to|\d+%?)$/,constructor:function(b){var a=this;b=Ext.apply(a,b||{});a.config=b;a.id=Ext.id(null,'ext-animator-');a.mixins.observable.constructor.call(a,b);a.timeline=[];a.createTimeline(a.keyframes);if(a.target){a.applyAnimator(a.target);Ext.fx.Manager.addAnim(a)}},sorter:function(a,b){return a.pct-b.pct},createTimeline:function(e){var d=this,b=[],k=d.to||{},g=d.duration,h,j,c,i,a,f;for(a in e){if(e.hasOwnProperty(a)&&d.animKeyFramesRE.test(a)){f={attrs:Ext.apply(e[a],k)};if(a==='from'){a=0}else {if(a==='to'){a=100}}f.pct=parseInt(a,10);b.push(f)}}Ext.Array.sort(b,d.sorter);i=b.length;for(c=0;c0},isRunning:function(){return !1}},1,0,0,0,0,[['observable',Ext.util.Observable]],[Ext.fx,'Animator'],0);Ext.cmd.derive('Ext.fx.CubicBezier',Ext.Base,{singleton:!0,cubicBezierAtTime:function(l,d,e,i,j,h){var a=3*d,b=3*(i-d)-a,f=1-a-b,c=3*e,g=3*(j-e)-c,k=1-c-g;function sampleCurveX(c){return ((f*c+b)*c+a)*c}function solve(f,b){var a=solveCurveX(f,b);return ((k*a+g)*a+c)*a}function solveCurveX(n,q){var g,k,c,m,o,p;for(c=n,p=0;p<8;p++){m=sampleCurveX(c)-n;if(Math.abs(m)k){return k}while(gm){g=c}else {k=c}c=(k-g)/2+g}return c}return solve(l,1/(200*h))},cubicBezier:function(b,d,c,e){var a=function(a){return Ext.fx.CubicBezier.cubicBezierAtTime(a,b,d,c,e,1)};a.toCSS3=function(){return 'cubic-bezier('+[b,d,c,e].join(',')+')'};a.reverse=function(){return Ext.fx.CubicBezier.cubicBezier(1-c,1-e,1-b,1-d)};return a}},0,0,0,0,0,0,[Ext.fx,'CubicBezier'],0);Ext.cmd.derive('Ext.fx.Easing',Ext.Base,function(){var b=Math,g=b.PI,a=b.pow,f=b.sin,e=b.sqrt,d=b.abs,c=1.70158;return {singleton:!0,linear:Ext.identityFn,ease:function(k){var c=0.07813-k/2,f=e(0.0066+c*c),g=f-c,i=a(d(g),1/3)*(g<0?-1:1),h=-f-c,j=a(d(h),1/3)*(h<0?-1:1),b=i+j+0.25;return a(1-b,2)*3*b*0.1+(1-b)*3*b*b+b*b*b},easeIn:function(b){return a(b,1.7)},easeOut:function(b){return a(b,0.48)},easeInOut:function(k){var c=0.48-k/1.04,f=e(0.1734+c*c),g=f-c,i=a(d(g),1/3)*(g<0?-1:1),h=-f-c,j=a(d(h),1/3)*(h<0?-1:1),b=i+j+0.5;return (1-b)*3*b*b+b*b*b},backIn:function(a){return a*a*((c+1)*a-c)},backOut:function(a){a=a-1;return a*a*((c+1)*a+c)+1},elasticIn:function(b){if(b===0||b===1){return b}var c=0.3,d=c/4;return a(2,-10*b)*f((b-d)*(2*g)/c)+1},elasticOut:function(a){return 1-Ext.fx.Easing.elasticIn(1-a)},bounceIn:function(a){return 1-Ext.fx.Easing.bounceOut(1-a)},bounceOut:function(a){var d=7.5625,b=2.75,c;if(a<1/b){c=d*a*a}else {if(a<2/b){a-=1.5/b;c=d*a*a+0.75}else {if(a<2.5/b){a-=2.25/b;c=d*a*a+0.9375}else {a-=2.625/b;c=d*a*a+0.984375}}}return c}}},0,0,0,0,0,0,[Ext.fx,'Easing'],function(c){var b=c.self,a=b.prototype;b.addMembers({'back-in':a.backIn,'back-out':a.backOut,'ease-in':a.easeIn,'ease-out':a.easeOut,'elastic-in':a.elasticIn,'elastic-out':a.elasticOut,'bounce-in':a.bounceIn,'bounce-out':a.bounceOut,'ease-in-out':a.easeInOut})});Ext.cmd.derive('Ext.fx.DrawPath',Ext.Base,{singleton:!0,pathToStringRE:/,?([achlmqrstvxz]),?/gi,pathCommandRE:/([achlmqstvz])[\s,]*((-?\d*\.?\d*(?:e[-+]?\d+)?\s*,?\s*)+)/ig,pathValuesRE:/(-?\d*\.?\d*(?:e[-+]?\d+)?)\s*,?\s*/ig,stopsRE:/^(\d+%?)$/,radian:Math.PI/180,is:function(b,a){a=String(a).toLowerCase();return a=='object'&&b===Object(b)||a=='undefined'&&typeof b==a||a=='null'&&b===null||a=='array'&&Array.isArray&&Array.isArray(b)||Object.prototype.toString.call(b).toLowerCase().slice(8,-1)==a},path2string:function(){return this.join(',').replace(Ext.fx.DrawPath.pathToStringRE,'$1')},pathToString:function(a){return a.join(',').replace(Ext.fx.DrawPath.pathToStringRE,'$1')},parsePathString:function(c){if(!c){return null}var d={a:7,c:6,h:1,l:2,m:2,q:4,s:4,t:2,v:1,z:0},a=[],b=this;if(b.is(c,'array')&&b.is(c[0],'array')){a=b.pathClone(c)}if(!a.length){String(c).replace(b.pathCommandRE,function(i,g,h){var e=[],f=g.toLowerCase();h.replace(b.pathValuesRE,function(b,a){if(a){e.push(+a)}});if(f=='m'&&e.length>2){a.push([g].concat(Ext.Array.splice(e,0,2)));f='l';g=g=='m'?'l':'L'}while(e.length>=d[f]){a.push([g].concat(Ext.Array.splice(e,0,d[f])));if(!d[f]){break}}})}a.toString=b.path2string;return a},pathClone:function(a){var d=[],c,f,b,e;if(!this.is(a,'array')||!this.is(a&&a[0],'array')){a=this.parsePathString(a)}for(b=0,e=a.length;b7){a[d].shift();var e=a[d];while(e.length){Ext.Array.splice(a,d++,0,['C'].concat(Ext.Array.splice(e,0,6)))}Ext.Array.erase(a,d,1);j=Math.max(c.length,b.length||0)}},m=function(d,f,e,g,a){if(d&&f&&d[a][0]=='M'&&f[a][0]!='M'){Ext.Array.splice(f,a,0,['M',g.x,g.y]);e.bx=0;e.by=0;e.x=d[a][1];e.y=d[a][2];j=Math.max(c.length,b.length||0)}},a,j,g,f,i,h;for(a=0,j=Math.max(c.length,b.length||0);a1){u=N(u);d=u*d;c=u*c}x=d*d;y=c*c;I=(X==v?-1:1)*N(R((x*y-x*j*j-y*i*i)/(x*j*j+y*i*i)));q=I*d*j/c+(m+e)/2;r=I*-c*i/d+(n+f)/2;b=M(((n-r)/c).toFixed(7));a=M(((f-r)/c).toFixed(7));b=ma){b=b-k*2}if(!v&&a>b){a=a-k*2}}else {b=o[0];a=o[1];q=o[2];r=o[3]}z=a-b;if(R(z)>Q){L=a;O=e;P=f;a=b+Q*(v&&a>b?1:-1);e=q+d*B(a);f=r+c*C(a);g=s.arc2curve(e,f,d,c,K,0,v,O,P,[a,L,q,r])}z=a-b;S=B(b);V=C(b);T=B(a);W=C(a);J=p.tan(z/4);D=4/3*d*J;E=4/3*c*J;F=[m,n];l=[m+D*V,n-E*S];G=[e+D*W,f-E*T];H=[e,f];l[0]=2*F[0]-l[0];l[1]=2*F[1]-l[1];if(o){return [l,G,H].concat(g)}else {g=[l,G,H].concat(g).join().split(',');A=[];U=g.length;for(h=0;h=d){b=d;f=!0}if(a.reverse){b=d-b}for(c in e){if(e.hasOwnProperty(c)){h=e[c];g=f?1:k(b/d);i[c]=j[c].set(h,g)}}a.frameCount++;return i},lastFrame:function(){var a=this,c=a.iterations,b=a.currentIteration;b++;if(b0},isRunning:function(){return this.paused===!1&&this.running===!0&&this.isAnimator!==!0}},1,0,0,0,0,[['observable',Ext.util.Observable]],[Ext.fx,'Anim'],0);Ext.enableFx=!0;Ext.cmd.derive('Ext.util.Animate',Ext.Base,{mixinId:'animate',isAnimate:!0,animate:function(b){var a=this;if(Ext.fx.Manager.hasFxBlock(a.id)){return a}Ext.fx.Manager.queueFx(new Ext.fx.Anim(a.anim(b)));return this},anim:function(a){if(!Ext.isObject(a)){return a?{}:!1}var b=this;if(a.stopAnimation){b.stopAnimation()}Ext.applyIf(a,Ext.fx.Manager.getFxDefaults(b.id));return Ext.apply({target:b,paused:!0},a)},getAnimationProps:function(){var b=this,a=b.layout;return a&&a.animate?a.animate:{}},stopFx:Ext.Function.alias(Ext.util.Animate,'stopAnimation'),stopAnimation:function(){Ext.fx.Manager.stopAnimation(this.id);return this},syncFx:function(){Ext.fx.Manager.setFxDefaults(this.id,{concurrent:!0});return this},sequenceFx:function(){Ext.fx.Manager.setFxDefaults(this.id,{concurrent:!1});return this},hasActiveFx:Ext.Function.alias(Ext.util.Animate,'getActiveAnimation'),getActiveAnimation:function(){return Ext.fx.Manager.getActiveAnimation(this.id)}},0,0,0,0,0,0,[Ext.util,'Animate'],0);Ext.cmd.derive('Ext.dom.Fly',Ext.dom.Element,{alternateClassName:'Ext.dom.Element.Fly',validNodeTypes:{1:1,9:1,11:1},isFly:!0,constructor:function(a){this.dom=a;this.el=this},attach:function(b){var a=this;if(!b){return a.detach()}a.dom=b;if(!Ext.cache[b.id]){a.getData().isSynchronized=!1}return a},detach:function(){this.dom=null},addListener:null,removeListener:null},1,0,0,0,0,0,[Ext.dom,'Fly',Ext.dom.Element,'Fly'],function(b){var a={};b.cache=a;Ext.fly=function(c,e){var d=null,h=Ext.fly,f,g;e=e||h.caller&&h.caller.$name||'_global';c=Ext.getDom(c);if(c){f=c.nodeType;if(b.prototype.validNodeTypes[f]||!f&&c.window==c){d=Ext.cache[c.id];if(!d||d.dom!==c){d=a[e]||(a[e]=new b());d.dom=c;g=d.getData(!0);if(g){g.isSynchronized=!1}}}}return d}});Ext.cmd.derive('Ext.dom.CompositeElementLite',Ext.Base,{alternateClassName:['Ext.CompositeElementLite'],isComposite:!0,isLite:!0,statics:{importElementMethods:function(){var b=Ext.dom.Element,a=this.prototype;Ext.Object.each(b.prototype,function(b,c){if(typeof c==='function'&&!a[b]){a[b]=function(){return this.invoke(b,arguments)}}})}},constructor:function(a,b){if(b){this.elements=a||[]}else {this.elements=[];this.add(a)}},getElement:function(b){var a=this._fly||(this._fly=new Ext.dom.Fly());return a.attach(b)},transformElement:function(a){return Ext.getDom(a)},getCount:function(){return this.elements.length},add:function(a,e){var d=this.elements,b,c;if(!a){return this}if(typeof a=='string'){a=Ext.fly(e||document).query(a)}else {if(a.isComposite){a=a.elements}else {if(!Ext.isIterable(a)){a=[a]}}}for(b=0,c=a.length;b-1){a=Ext.getDom(a);if(e){b=this.elements[c];b.parentNode.insertBefore(a,b);Ext.removeNode(b)}Ext.Array.splice(this.elements,c,1,a)}return this},clear:function(c){var d=this,b=d.elements,a=b.length-1;if(c){for(;a>=0;a--){Ext.removeNode(b[a])}}this.elements=[]},addElements:function(a,d){if(!a){return this}if(typeof a==='string'){a=Ext.dom.Element.selectorFunction(a,d)}var e=this.elements,c=a.length,b;for(b=0;b','','','',''].join(''),O=/(?:]*)?>)((\n|\r|.)*?)(?:<\/script>)/ig,J=/(?:)((\n|\r|.)*?)(?:<\/script>)/ig,G=/\ssrc=([\'\"])(.*?)\1/i,v=/\S/,E=/\stype=([\'\"])(.*?)\1/i,I=/^-ms-/,B=/(-[a-z])/gi,L=function(b,a){return a.charAt(1).toUpperCase()},r='x-masked',k='x-masked-relative',m='x-mask-msg',D=/^body/i,l={},u=function(d){var c=d.getData(),b=c[q];if(b===undefined){c[q]=b=a.VISIBILITY}return b},f=b.createRange?b.createRange():null,z={INPUT:!0,TEXTAREA:!0};if(Ext.isIE8){var p=b.createElement('div'),c=[],M=Ext.Function.createBuffered(function(){var b=c.length,a;for(a=0;a"+Ext.String.format(y,a)+''));b.selectNode('.'+a+'-mc').appendChild(this.dom);return b},clean:function(g){var c=this,d=c.dom,e=c.getData(),a=d.firstChild,f=-1,b;if(e.isCleaned&&g!==!0){return c}while(a){b=a.nextSibling;if(a.nodeType===3){if(!v.test(a.nodeValue)){d.removeChild(a)}else {if(b&&b.nodeType===3){a.appendData(Ext.String.trim(b.data));d.removeChild(b);b=a.nextSibling;a.nodeIndex=++f}}}else {Ext.fly(a,'_clean').clean();a.nodeIndex=++f}a=b}e.isCleaned=!0;return c},empty:f?function(){var a=this.dom;if(a.firstChild){f.setStartBefore(a.firstChild);f.setEndAfter(a.lastChild);f.deleteContents()}}:function(){var a=this.dom;while(a.lastChild){a.removeChild(a.lastChild)}},clearListeners:function(){this.removeAnchor();arguments.callee.$previous.call(this)},clearPositioning:function(a){a=a||'';return this.setStyle({left:a,right:a,top:a,bottom:a,'z-index':'',position:'static'})},createProxy:function(b,e,f){b=typeof b==='object'?b:{tag:'div',role:'presentation',cls:b};var d=this,c=e?Ext.DomHelper.append(e,b,!0):Ext.DomHelper.insertBefore(d.dom,b,!0);c.setVisibilityMode(a.DISPLAY);c.hide();if(f&&d.setBox&&d.getBox){c.setBox(d.getBox())}return c},clearOpacity:function(){return this.setOpacity('')},clip:function(){var a=this,c=a.getData(),b;if(!c[g]){c[g]=!0;b=a.getStyle([j,h,i]);c[n]={o:b[j],x:b[h],y:b[i]};a.setStyle(j,e);a.setStyle(h,e);a.setStyle(i,e)}return a},destroy:function(){var b=this,a=b.dom,f=b.getData(),e,d;if(a&&b.isAnimate){b.stopAnimation()}arguments.callee.$previous.call(this);if(a&&Ext.isIE8&&a.window!=a&&a.nodeType!==9&&a.tagName!=='BODY'&&a.tagName!=='HTML'){c[c.length]=a;M()}if(f){e=f.maskEl;d=f.maskMsg;if(e){e.destroy()}if(d){d.destroy()}}},enableDisplayMode:function(c){var b=this;b.setVisibilityMode(a.DISPLAY);if(c!==undefined){b.getData()[K]=c}return b},fadeIn:function(c){var a=this,b=a.dom;a.animate(Ext.apply({},c,{opacity:1,internalListeners:{beforeanimate:function(d){var a=Ext.fly(b,'_anim');if(a.isStyle('display','none')){a.setDisplayed('')}else {a.show()}}}}));return this},fadeOut:function(a){var b=this,c=b.dom;a=Ext.apply({opacity:0,internalListeners:{afteranimate:function(d){if(c&&d.to.opacity===0){var b=Ext.fly(c,'_anim');if(a.useDisplay){b.setDisplayed(!1)}else {b.hide()}}}}},a);b.animate(a);return b},fixDisplay:function(){var a=this;if(a.isStyle(d,s)){a.setStyle(o,e);a.setStyle(d,a._getDisplay());if(a.isStyle(d,s)){a.setStyle(d,'block')}}},frame:function(b,c,a){var d=this,f=d.dom,e;b=b||'#C3DAF9';c=c||1;a=a||{};e=function(){var g=Ext.fly(f,'_anim'),i=this,d,e,h;g.show();d=g.getBox();e=Ext.getBody().createChild({role:'presentation',id:g.dom.id+'-anim-proxy',style:{position:'absolute','pointer-events':'none','z-index':35000,border:'0px solid '+b}});h=new Ext.fx.Anim({target:e,duration:a.duration||1000,iterations:c,from:{top:d.y,left:d.x,borderWidth:0,opacity:1,height:d.height,width:d.width},to:{top:d.y-20,left:d.x-20,borderWidth:10,opacity:0,height:d.height+40,width:d.width+40}});h.on('afteranimate',function(){e.destroy();i.end()})};d.animate({duration:Math.max(a.duration,500)*2||2000,listeners:{beforeanimate:{fn:e}},callback:a.callback,scope:a.scope});return d},getColor:function(h,f,c){var a=this.getStyle(h),b=c||c===''?c:'#',d,g,e=0;if(!a||/transparent|inherit/.test(a)){return f}if(/^r/.test(a)){a=a.slice(4,a.length-1).split(',');g=a.length;for(;e5?b.toLowerCase():f},getLoader:function(){var c=this,b=c.getData(),a=b.loader;if(!a){b.loader=a=new Ext.ElementLoader({target:c})}return a},getPositioning:function(c){var a=this.getStyle(['left','top','position','z-index']),b=this.dom;if(c){if(a.left==='auto'){a.left=b.offsetLeft+'px'}if(a.top==='auto'){a.top=b.offsetTop+'px'}}return a},ghost:function(a,e){var b=this,d=b.dom,c;a=a||'b';c=function(){var h=Ext.fly(d,'_anim'),g=h.getWidth(),f=h.getHeight(),c=h.getXY(),i=h.getPositioning(),b={opacity:0};switch(a){case 't':b.y=c[1]-f;break;case 'l':b.x=c[0]-g;break;case 'r':b.x=c[0]+g;break;case 'b':b.y=c[1]+f;break;case 'tl':b.x=c[0]-g;b.y=c[1]-f;break;case 'bl':b.x=c[0]-g;b.y=c[1]+f;break;case 'br':b.x=c[0]+g;b.y=c[1]+f;break;case 'tr':b.x=c[0]+g;b.y=c[1]-f;break;}this.to=b;this.on('afteranimate',function(){var b=Ext.fly(d,'_anim');if(b){b.hide();b.clearOpacity();b.setPositioning(i)}})};b.animate(Ext.applyIf(e||{},{duration:500,easing:'ease-out',listeners:{beforeanimate:c}}));return b},hide:function(a){if(typeof a==='string'){this.setVisible(!1,a);return this}this.setVisible(!1,this.anim(a));return this},highlight:function(k,b){var g=this,e=g.dom,j={},i,h,c,d,a,f;b=b||{};d=b.listeners||{};c=b.attr||'backgroundColor';j[c]=k||'ffff9c';if(!b.to){h={};h[c]=b.endColor||g.getColor(c,'ffffff','')}else {h=b.to}b.listeners=Ext.apply(Ext.apply({},d),{beforeanimate:function(){i=e.style[c];var g=Ext.fly(e,'_anim');g.clearOpacity();g.show();a=d.beforeanimate;if(a){f=a.fn||a;return f.apply(a.scope||d.scope||t,arguments)}},afteranimate:function(){if(e){e.style[c]=i}a=d.afteranimate;if(a){f=a.fn||a;f.apply(a.scope||d.scope||t,arguments)}}});g.animate(Ext.apply({},b,{duration:1000,easing:'ease-in',from:j,to:h}));return g},hover:function(d,e,c,b){var a=this;a.on('mouseenter',d,c||a.dom,b);a.on('mouseleave',e,c||a.dom,b);return a},initDD:function(c,b,a){var d=new Ext.dd.DD(Ext.id(this.dom),c,b);return Ext.apply(d,a)},initDDProxy:function(c,b,a){var d=new Ext.dd.DDProxy(Ext.id(this.dom),c,b);return Ext.apply(d,a)},initDDTarget:function(c,b,a){var d=new Ext.dd.DDTarget(Ext.id(this.dom),c,b);return Ext.apply(d,a)},isFocusable:function(){var a=this.dom,b=!1,c;if(a&&!a.disabled){c=a.nodeName;b=!!Ext.Element.naturallyFocusableTags[c]||(c==='A'||c==='LINK')&&!!a.href||a.getAttribute('tabIndex')!=null||a.contentEditable==='true';if(Ext.isIE8&&c==='INPUT'&&a.type==='hidden'){b=!1}b=b&&this.isVisible(!0)}return b},isInputField:function(){var a=this.dom,b=a.contentEditable;if(z[a.tagName]&&a.type!=='button'||(b===''||b==='true')){return !0}return !1},isTabbable:function(f){var c=this.dom,a=!1,e,d,b;if(c&&!c.disabled){e=c.nodeName;b=c.getAttribute('tabIndex');d=b!=null;b-=0;if(e==='A'||e==='LINK'){if(c.href){a=d&&b<0?!1:!0}else {if(c.contentEditable==='true'){a=!d||d&&b>=0?!0:!1}else {a=d&&b>=0?!0:!1}}}else {if(c.contentEditable==='true'||Ext.Element.naturallyTabbableTags[e]){a=d&&b<0?!1:!0}else {if(d&&b>=0){a=!0}}}if(Ext.isIE8&&e==='INPUT'&&c.type==='hidden'){a=!1}a=a&&(f||(!this.component||this.component.isVisible(!0))&&this.isVisible(!0))}return a},isMasked:function(g){var b=this,f=b.getData(),e=f.maskEl,d=f.maskMsg,c=!1,a;if(e&&e.isVisible()){if(d){d.center(b)}c=!0}else {if(g){a=b.findParentNode();if(a){return Ext.fly(a).isMasked(g)}}}return c},load:function(a){this.getLoader().load(a);return this},mask:function(h,f,i){var c=this,d=c.dom,g=c.getData(),a=g.maskEl,e;if(!(D.test(d.tagName)&&c.getStyle('position')==='static')){c.addCls(k)}if(a){a.destroy()}a=Ext.DomHelper.append(d,{role:'presentation',cls:'x-mask x-border-box',children:{role:'presentation',cls:f?m+' '+f:m,cn:{tag:'div',role:'presentation',cls:'x-mask-msg-inner',cn:{tag:'div',role:'presentation',cls:'x-mask-msg-text',html:h||''}}}},!0);e=Ext.get(a.dom.firstChild);g.maskEl=a;c.addCls(r);a.setDisplayed(!0);if(typeof h==='string'){e.setDisplayed(!0);e.center(c)}else {e.setDisplayed(!1)}if(d===b.body){a.addCls('x-mask-fixed')}c.saveTabbableState({skipSelf:d===b.body});if(Ext.isIE9m&&d!==b.body&&c.isStyle('height','auto')){a.setSize(undefined,i||c.getHeight())}return a},monitorMouseLeave:function(e,d,f){var c=this,b,a={mouseleave:function(a){if(Ext.isIE9m){a.enableIEAsync()}b=Ext.defer(d,e,f||c,[a])},mouseenter:function(){clearTimeout(b)}};c.on(a);return a},puff:function(a){var c=this,e=c.dom,d,b=c.getBox(),f=c.getStyle(['width','height','left','right','top','bottom','position','z-index','font-size','opacity'],!0);a=Ext.applyIf(a||{},{easing:'ease-out',duration:500,useDisplay:!1});d=function(){var c=Ext.fly(e,'_anim');c.clearOpacity();c.show();this.to={width:b.width*2,height:b.height*2,x:b.x-b.width/2,y:b.y-b.height/2,opacity:0,fontSize:'200%'};this.on('afteranimate',function(){var b=Ext.fly(e,'_anim');if(b){if(a.useDisplay){b.setDisplayed(!1)}else {b.hide()}b.setStyle(f);Ext.callback(a.callback,a.scope)}})};c.animate({duration:a.duration,easing:a.easing,listeners:{beforeanimate:{fn:d}}});return c},selectable:function(){var b=this;b.dom.unselectable='';b.removeCls(a.unselectableCls);b.addCls(a.selectableCls);return b},setCapture:function(){var a=this.dom;if(Ext.isIE9m&&a.setCapture){a.setCapture()}},setHeight:function(c,a){var b=this;if(!a||!b.anim){arguments.callee.$previous.apply(this,arguments)}else {if(!Ext.isObject(a)){a={}}b.animate(Ext.applyIf({to:{height:c}},a))}return b},setHorizontal:function(){var a=this,b=a.verticalCls;delete a.vertical;if(b){delete a.verticalCls;a.removeCls(b)}delete a.setWidth;delete a.setHeight;if(!Ext.isIE8){delete a.getWidth;delete a.getHeight}delete a.styleHooks},updateText:function(d){var e=this,c,a;if(c){a=c.firstChild;if(!a||(a.nodeType!==3||a.nextSibling)){a=b.createTextNode();e.empty();c.appendChild(a)}if(d){a.data=d}}},setHtml:function(c,i,g,d){var a=this,f,e,h;if(!a.dom){return a}c=c||'';e=a.dom;if(i!==!0){e.innerHTML=c;Ext.callback(g,a);return a}f=Ext.id();c+='';h=Ext.interval(function(){var o,e,l,k,j,n,m;if(!(n=b.getElementById(f))){return !1}clearInterval(h);Ext.removeNode(n);o=Ext.getHead().dom;while(e=O.exec(c)){l=e[1];k=l?l.match(G):!1;if(k&&k[2]){m=b.createElement('script');m.src=k[2];j=l.match(E);if(j&&j[2]){m.type=j[2]}o.appendChild(m)}else {if(e[2]&&e[2].length>0){if(d){Ext.functionFactory(e[2]).call(d)}else {Ext.globalEval(e[2])}}}}Ext.callback(g,d||a)},20);e.innerHTML=c.replace(J,'');return a},setOpacity:function(c,b){var a=this;if(!a.dom){return a}if(!b||!a.anim){a.setStyle('opacity',c)}else {if(typeof b!='object'){b={duration:350,easing:'ease-in'}}a.animate(Ext.applyIf({to:{opacity:c}},b))}return a},setPositioning:function(a){return this.setStyle(a)},setVertical:function(e,d){var b=this,c=a.prototype;b.vertical=!0;if(d){b.addCls(b.verticalCls=d)}b.setWidth=c.setHeight;b.setHeight=c.setWidth;if(!Ext.isIE8){b.getWidth=c.getHeight;b.getHeight=c.getWidth}b.styleHooks=e===270?c.verticalStyleHooks270:c.verticalStyleHooks90},setSize:function(c,e,d){var b=this;if(Ext.isObject(c)){d=e;e=c.height;c=c.width}if(!d||!b.anim){b.dom.style.width=a.addUnits(c);b.dom.style.height=a.addUnits(e);if(b.shadow||b.shim){b.syncUnderlays()}}else {if(d===!0){d={}}b.animate(Ext.applyIf({to:{width:c,height:e}},d))}return b},setVisible:function(f,g){var b=this,h=b.dom,c=u(b);if(typeof g==='string'){switch(g){case d:c=a.DISPLAY;break;case o:c=a.VISIBILITY;break;case A:c=a.OFFSETS;break;case H:c=a.CLIP;break;}b.setVisibilityMode(c);g=!1}if(!g||!b.anim){if(c===a.DISPLAY){return b.setDisplayed(f)}else {if(c===a.OFFSETS){b[f?'removeCls':'addCls'](N)}else {if(c===a.CLIP){b[f?'removeCls':'addCls'](w)}else {if(c===a.VISIBILITY){b.fixDisplay();h.style.visibility=f?'':e}}}}}else {if(f){b.setOpacity(0.01);b.setVisible(!0)}if(!Ext.isObject(g)){g={duration:350,easing:'ease-in'}}b.animate(Ext.applyIf({callback:function(){if(!f){Ext.fly(h).setVisible(!1).setOpacity(1)}},to:{opacity:f?1:0}},g))}b.getData()[x]=f;if(b.shadow||b.shim){b.setUnderlaysVisible(f)}return b},setWidth:function(c,a){var b=this;if(!a||!b.anim){arguments.callee.$previous.apply(this,arguments)}else {if(!Ext.isObject(a)){a={}}b.animate(Ext.applyIf({to:{width:c}},a))}return b},setX:function(b,a){return this.setXY([b,this.getY()],a)},setXY:function(b,a){var c=this;if(!a||!c.anim){arguments.callee.$previous.call(this,b)}else {if(!Ext.isObject(a)){a={}}c.animate(Ext.applyIf({to:{x:b[0],y:b[1]}},a))}return this},setY:function(b,a){return this.setXY([this.getX(),b],a)},show:function(a){if(typeof a==='string'){this.setVisible(!0,a);return this}this.setVisible(!0,this.anim(a));return this},slideIn:function(a,c,d){var b=this,g=b.dom,h=g.style,j,e,f,i;a=a||'t';c=c||{};j=function(){var p=this,o=c.listeners,m=Ext.fly(g,'_anim'),j,n,l,k;if(!d){m.fixDisplay()}j=m.getBox();if((a=='t'||a=='b')&&j.height===0){j.height=g.scrollHeight}else {if((a=='l'||a=='r')&&j.width===0){j.width=g.scrollWidth}}n=m.getStyle(['width','height','left','right','top','bottom','position','z-index'],!0);m.setSize(j.width,j.height);if(c.preserveScroll){f=m.cacheScrollValues()}k=m.wrap({role:'presentation',id:Ext.id()+'-anim-wrap-for-'+m.dom.id,style:{visibility:d?'visible':'hidden'}});i=k.dom.parentNode;k.setPositioning(m.getPositioning());if(k.isStyle('position','static')){k.position('relative')}m.clearPositioning('auto');k.clip();if(f){f()}m.setStyle({visibility:'',position:'absolute'});if(d){k.setSize(j.width,j.height)}switch(a){case 't':l={from:{width:j.width+'px',height:'0px'},to:{width:j.width+'px',height:j.height+'px'}};h.bottom='0px';break;case 'l':l={from:{width:'0px',height:j.height+'px'},to:{width:j.width+'px',height:j.height+'px'}};b.anchorAnimX(a);break;case 'r':l={from:{x:j.x+j.width,width:'0px',height:j.height+'px'},to:{x:j.x,width:j.width+'px',height:j.height+'px'}};b.anchorAnimX(a);break;case 'b':l={from:{y:j.y+j.height,width:j.width+'px',height:'0px'},to:{y:j.y,width:j.width+'px',height:j.height+'px'}};break;case 'tl':l={from:{x:j.x,y:j.y,width:'0px',height:'0px'},to:{width:j.width+'px',height:j.height+'px'}};h.bottom='0px';b.anchorAnimX('l');break;case 'bl':l={from:{y:j.y+j.height,width:'0px',height:'0px'},to:{y:j.y,width:j.width+'px',height:j.height+'px'}};b.anchorAnimX('l');break;case 'br':l={from:{x:j.x+j.width,y:j.y+j.height,width:'0px',height:'0px'},to:{x:j.x,y:j.y,width:j.width+'px',height:j.height+'px'}};b.anchorAnimX('r');break;case 'tr':l={from:{x:j.x+j.width,width:'0px',height:'0px'},to:{x:j.x,width:j.width+'px',height:j.height+'px'}};h.bottom='0px';b.anchorAnimX('r');break;}k.show();e=Ext.apply({},c);delete e.listeners;e=new Ext.fx.Anim(Ext.applyIf(e,{target:k,duration:500,easing:'ease-out',from:d?l.to:l.from,to:d?l.from:l.to}));e.on('afteranimate',function(){var b=Ext.fly(g,'_anim');b.setStyle(n);if(d){if(c.useDisplay){b.setDisplayed(!1)}else {b.hide()}}if(k.dom){if(k.dom.parentNode){k.dom.parentNode.insertBefore(b.dom,k.dom)}else {i.appendChild(b.dom)}k.destroy()}if(f){f()}p.end()});if(o){e.on(o)}};b.animate({duration:c.duration?Math.max(c.duration,500)*2:1000,listeners:{beforeanimate:j}});return b},slideOut:function(a,b){return this.slideIn(a,b,!0)},swallowEvent:function(a,f){var b=this,c,d,e=function(b){b.stopPropagation();if(f){b.preventDefault()}};if(Ext.isArray(a)){d=a.length;for(c=0;c0){a.setAttribute(e,++f)}else {if(a.hasAttribute('tabIndex')){a.setAttribute(g,a.getAttribute('tabIndex'))}else {a.setAttribute(g,'none')}a.setAttribute('tabIndex','-1');a.setAttribute(e,'1')}}return c},restoreTabbableState:function(k,j){var g=this.dom,c=Ext.Element.tabbableSavedCounterAttribute,e=Ext.Element.tabbableSavedValueAttribute,b=[],h,f,b,a,d,i;if(!g){return this}if(!j){b=Ext.Array.from(g.querySelectorAll('['+c+']'))}if(!k){b.unshift(g)}for(d=0,i=b.length;d1){a.setAttribute(c,--f);continue}h=a.getAttribute(e);if(h==='none'){a.removeAttribute('tabIndex')}else {a.setAttribute('tabIndex',h)}a.removeAttribute(e);a.removeAttribute(c)}return b}},deprecated:{'4.0':{methods:{pause:function(b){var a=this;Ext.fx.Manager.setFxDefaults(a.id,{delay:b});return a},scale:function(c,a,b){this.animate(Ext.apply({},b,{width:c,height:a}));return this},shift:function(a){this.animate(a);return this}}},'4.2':{methods:{moveTo:function(b,c,a){return this.setXY([b,c],a)},setBounds:function(d,e,c,b,a){return this.setBox({x:d,y:e,width:c,height:b},a)},setLeftTop:function(d,e){var b=this,c=b.dom.style;c.left=a.addUnits(d);c.top=a.addUnits(e);if(b.shadow||b.shim){b.syncUnderlays()}return b},setLocation:function(b,c,a){return this.setXY([b,c],a)}}},'5.0':{methods:{getAttributeNS:function(a,b){return this.getAttribute(b,a)},getCenterXY:function(){return this.getAlignToXY(b,'c-c')},getComputedHeight:function(){return Math.max(this.dom.offsetHeight,this.dom.clientHeight)||parseFloat(this.getStyle(C))||0},getComputedWidth:function(){return Math.max(this.dom.offsetWidth,this.dom.clientWidth)||parseFloat(this.getStyle(F))||0},getStyleSize:function(){var d=this,e=this.dom,h=e===b||e===b.body,c,g,f;if(h){return {width:a.getViewportWidth(),height:a.getViewportHeight()}}c=d.getStyle(['height','width'],!0);if(c.width&&c.width!=='auto'){g=parseFloat(c.width)}if(c.height&&c.height!=='auto'){f=parseFloat(c.height)}return {width:g||d.getWidth(!0),height:f||d.getHeight(!0)}},isBorderBox:function(){return !0},isDisplayed:function(){return !this.isStyle('display','none')},focusable:'isFocusable'}}}}}(),function(){var g=Ext.dom.Element,a=g.prototype,t=!Ext.isIE8,f=document,q=f.defaultView,p=/alpha\(opacity=(.*)\)/i,w=/^\s+|\s+$/g,d=a.styleHooks,e=Ext.supports,c,b,l,m,i,j,n;a._init(g);delete a._init;Ext.plainTableCls='x-table-plain';Ext.plainListCls='x-list-plain';if(Ext.CompositeElementLite){Ext.CompositeElementLite.importElementMethods()}if(!e.Opacity&&Ext.isIE){Ext.apply(d.opacity,{get:function(d){var c=d.style.filter,b,a;if(c.match){b=c.match(p);if(b){a=parseFloat(b[1]);if(!isNaN(a)){return a?a/100:0}}}return 1},set:function(d,a){var b=d.style,c=b.filter.replace(p,'').replace(w,'');b.zoom=1;if(typeof a==='number'&&a>=0&&a<1){a*=100;b.filter=c+(c.length?' ':'')+'alpha(opacity='+a+')'}else {b.filter=c}}})}if(!e.matchesSelector){var r=/^([a-z]+|\*)?(?:\.([a-z][a-z\-_0-9]*))?$/i,v=/\-/g,h,s=function(a,c){var b=new RegExp('(?:^|\\s+)'+c.replace(v,'\\-')+'(?:\\s+|$)');if(a&&a!=='*'){a=a.toUpperCase();return function(d){return d.tagName===a&&b.test(d.className)}}return function(d){return b.test(d.className)}},u=function(a){a=a.toUpperCase();return function(b){return b.tagName===a}},k={};a.matcherCache=k;a.is=function(a){if(!a){return !0}var b=this.dom,g,e,d,c,j,l,i;if(b.nodeType!==1){return !1}if(!(d=Ext.isFunction(a)?a:k[a])){if(!(e=a.match(r))){c=b.parentNode;if(!c){j=!0;c=h||(h=f.createDocumentFragment());h.appendChild(b)}l=Ext.Array.indexOf(Ext.fly(c,'_is').query(a),b)!==-1;if(j){h.removeChild(b)}return l}i=e[1];g=e[2];k[a]=d=g?s(i,g):u(i)}return d(b)}}if(!q||!q.getComputedStyle){a.getStyle=function(o,p){var j=this,e=j.dom,n=typeof o!=='string',a=o,i=a,r=1,m=p,l=j.styleHooks,q,h,d,c,f,b,k;if(n){d={};a=i[0];k=0;if(!(r=i.length)){return d}}if(!e||e.documentElement){return d||''}h=e.style;if(p){b=h}else {b=e.currentStyle;if(!b){m=!0;b=h}}do{c=l[a];if(!c){l[a]=c={name:g.normalize(a)}}if(c.get){f=c.get(e,j,m,b)}else {q=c.name;f=b[q]}if(!n){return f}d[a]=f;a=i[++k]}while(k=9)){a.getAttribute=function(a,c){var d=this.dom,b;if(c){b=typeof d[c+':'+a];if(b!=='undefined'&&b!=='unknown'){return d[c+':'+a]||null}return null}if(a==='for'){a='htmlFor'}return d[a]||null}}Ext.onInternalReady(function(){var o=/^(?:transparent|(?:rgba[(](?:\s*\d+\s*[,]){3}\s*0\s*[)]))$/i,h=[],p=a.setWidth,n=a.setHeight,m=a.setSize,q=/^\d+(?:\.\d*)?px$/i,i,l,k,j;if(e.FixedTableWidthBug){d.width={name:'width',set:function(c,e,f){var a=c.style,b=f._needsTableWidthFix,d=a.display;if(b){a.display='none'}a.width=e;if(b){c.scrollWidth;a.display=d}}};a.setWidth=function(g,b){var a=this,e=a.dom,c=e.style,d=a._needsTableWidthFix,f=c.display;if(d&&!b){c.display='none'}p.call(a,g,b);if(d&&!b){e.scrollWidth;c.display=f}return a};a.setSize=function(h,g,b){var a=this,e=a.dom,c=e.style,d=a._needsTableWidthFix,f=c.display;if(d&&!b){c.display='none'}m.call(a,h,g,b);if(d&&!b){e.scrollWidth;c.display=f}return a}}if(Ext.isIE8){d.height={name:'height',set:function(f,b,e){var a=e.component,d,c;if(a&&a._syncFrameHeight&&e===a.el){c=a.frameBody.dom.style;if(q.test(b)){d=a.getFrameInfo();if(d){c.height=parseInt(b,10)-d.height+'px'}}else {if(!b||b==='auto'){c.height=''}}}f.style.height=b}};a.setHeight=function(b,e){var a=this.component,d,c;if(a&&a._syncFrameHeight&&this===a.el){c=a.frameBody.dom.style;if(!b||b==='auto'){c.height=''}else {d=a.getFrameInfo();if(d){c.height=b-d.height+'px'}}}return n.call(this,b,e)};a.setSize=function(f,b,e){var a=this.component,d,c;if(a&&a._syncFrameHeight&&this===a.el){c=a.frameBody.dom.style;if(!b||b==='auto'){c.height=''}else {d=a.getFrameInfo();if(d){c.height=b-d.height+'px'}}}return m.call(this,f,b,e)}}Ext.getDoc().on('selectstart',function(h,a){var e=g.selectableCls,d=g.unselectableCls,b=a&&a.tagName;b=b&&b.toLowerCase();if(b==='input'||b==='textarea'){return}while(a&&a.nodeType===1&&a!==f.documentElement){var c=Ext.fly(a);if(c.hasCls(e)){return}if(c.hasCls(d)){h.stopEvent();return}a=a.parentNode}});function fixTransparent(d,e,c,b){var a=b[this.name]||'';return o.test(a)?'transparent':a}function makeSelectionRestoreFn(a,b,c){return function(){a.selectionStart=b;a.selectionEnd=c}}function getRightMarginFixCleaner(i){var h=e.DisplayChangeInputSelectionBug,f=e.DisplayChangeTextAreaSelectionBug,a,d,b,c;if(h||f){a=g.getActiveElement();d=a&&a.tagName;if(f&&d==='TEXTAREA'||h&&d==='INPUT'&&a.type==='text'){if(Ext.fly(i).isAncestor(a)){b=a.selectionStart;c=a.selectionEnd;if(Ext.isNumber(b)&&Ext.isNumber(c)){return makeSelectionRestoreFn(a,b,c)}}}}return Ext.emptyFn}function fixRightMargin(c,g,f,e){var b=e.marginRight,a,d;if(b!=='0px'){a=c.style;d=a.display;a.display='inline-block';b=(f?e:c.ownerDocument.defaultView.getComputedStyle(c,null)).marginRight;a.display=d}return b}function fixRightMarginAndInputFocus(b,h,g,f){var c=f.marginRight,a,d,e;if(c!=='0px'){a=b.style;d=getRightMarginFixCleaner(b);e=a.display;a.display='inline-block';c=(g?f:b.ownerDocument.defaultView.getComputedStyle(b,'')).marginRight;a.display=e;d()}return c}if(!e.RightMargin){d.marginRight=d['margin-right']={name:'marginRight',get:e.DisplayChangeInputSelectionBug||e.DisplayChangeTextAreaSelectionBug?fixRightMarginAndInputFocus:fixRightMargin}}if(!e.TransparentColor){i=['background-color','border-color','color','outline-color'];for(l=i.length;l--;){k=i[l];j=g.normalize(k);d[k]=d[j]={name:j,get:fixTransparent}}}a.verticalStyleHooks90=c=Ext.Object.chain(d);a.verticalStyleHooks270=b=Ext.Object.chain(d);c.width=d.height||{name:'height'};c.height=d.width||{name:'width'};c['margin-top']={name:'marginLeft'};c['margin-right']={name:'marginTop'};c['margin-bottom']={name:'marginRight'};c['margin-left']={name:'marginBottom'};c['padding-top']={name:'paddingLeft'};c['padding-right']={name:'paddingTop'};c['padding-bottom']={name:'paddingRight'};c['padding-left']={name:'paddingBottom'};c['border-top']={name:'borderLeft'};c['border-right']={name:'borderTop'};c['border-bottom']={name:'borderRight'};c['border-left']={name:'borderBottom'};b.width=d.height||{name:'height'};b.height=d.width||{name:'width'};b['margin-top']={name:'marginRight'};b['margin-right']={name:'marginBottom'};b['margin-bottom']={name:'marginLeft'};b['margin-left']={name:'marginTop'};b['padding-top']={name:'paddingRight'};b['padding-right']={name:'paddingBottom'};b['padding-bottom']={name:'paddingLeft'};b['padding-left']={name:'paddingTop'};b['border-top']={name:'borderRight'};b['border-right']={name:'borderBottom'};b['border-bottom']={name:'borderLeft'};b['border-left']={name:'borderTop'};if(!Ext.scopeCss){h.push('x-body')}if(e.Touch){h.push('x-touch')}if(Ext.isIE&&Ext.isIE9m){h.push('x-ie','x-ie9m');h.push('x-ie8p');if(Ext.isIE8){h.push('x-ie8')}else {h.push('x-ie9','x-ie9p')}if(Ext.isIE8m){h.push('x-ie8m')}}if(Ext.isIE10){h.push('x-ie10')}if(Ext.isIE10p){h.push('x-ie10p')}if(Ext.isIE11){h.push('x-ie11')}if(Ext.isGecko){h.push('x-gecko')}if(Ext.isOpera){h.push('x-opera')}if(Ext.isOpera12m){h.push('x-opera12m')}if(Ext.isWebKit){h.push('x-webkit')}if(Ext.isSafari){h.push('x-safari')}if(Ext.isChrome){h.push('x-chrome')}if(Ext.isMac){h.push('x-mac')}if(Ext.isLinux){h.push('x-linux')}if(!e.CSS3BorderRadius){h.push('x-nbr')}if(!e.CSS3LinearGradient){h.push('x-nlg')}if(e.Touch){h.push('x-touch')}Ext.getBody().addCls(h)},null,{priority:1500})});Ext.cmd.derive('Ext.GlobalEvents',Ext.mixin.Observable,{alternateClassName:'Ext.globalEvents',observableType:'global',singleton:!0,resizeBuffer:100,idleEventMask:{mousemove:1,touchmove:1,pointermove:1,MSPointerMove:1,unload:1},constructor:function(){var a=this;a.callParent();Ext.onInternalReady(function(){a.attachListeners()})},attachListeners:function(){Ext.get(window).on('resize',this.fireResize,this,{buffer:this.resizeBuffer});Ext.getDoc().on('mousedown',this.fireMouseDown,this)},fireMouseDown:function(a){this.fireEvent('mousedown',a)},fireResize:function(){var a=this,d=Ext.Element,c=d.getViewportWidth(),b=d.getViewportHeight();if(a.curHeight!==b||a.curWidth!==c){a.curHeight=b;a.curWidth=c;a.fireEvent('resize',c,b)}}},1,0,0,0,0,0,[Ext,'GlobalEvents',Ext,'globalEvents'],function(a){Ext.on=function(){return a.addListener.apply(a,arguments)};Ext.un=function(){return a.removeListener.apply(a,arguments)}});Ext.define('Ext.overrides.GlobalEvents',{override:'Ext.GlobalEvents',deprecated:{5:{methods:{addListener:function(a,d,i,f,h,g,e){var c,b;if(a==='ready'){b=d}else {if(typeof a!=='string'){for(c in a){if(c==='ready'){b=a[c]}}}}if(b){Ext.onReady(b)}this.callParent([a,d,i,f,h,g,e])}}}}});Ext.USE_NATIVE_JSON=!1;Ext.JSON=new function(){var me=this,hasNative=window.JSON&&JSON.toString()==='[object JSON]',useHasOwn=!!{}.hasOwnProperty,pad=function(a){return a<10?'0'+a:a},doDecode=function(json){return eval('('+json+')')},doEncode=function(a,b){if(a===null||a===undefined){return 'null'}else {if(Ext.isDate(a)){return me.encodeDate(a)}else {if(Ext.isString(a)){if(Ext.isMSDate(a)){return me.encodeMSDate(a)}else {return me.encodeString(a)}}else {if(typeof a==='number'){return isFinite(a)?String(a):'null'}else {if(Ext.isBoolean(a)){return String(a)}else {if(a.toJSON){return a.toJSON()}else {if(Ext.isArray(a)){return encodeArray(a,b)}else {if(Ext.isObject(a)){return encodeObject(a,b)}else {if(typeof a==='function'){return 'null'}}}}}}}}}return 'undefined'},m={'\b':'\\b','\t':'\\t','\n':'\\n','\f':'\\f','\r':'\\r','"':'\\"','\\':'\\\\','\v':'\\u000b'},charToReplace=/[\\\"\x00-\x1f\x7f-\uffff]/g,encodeString=function(a){return '"'+a.replace(charToReplace,function(b){var c=m[b];return typeof c==='string'?c:'\\u'+('0000'+b.charCodeAt(0).toString(16)).slice(-4)})+'"'},encodeMSDate=function(a){return '"'+a+'"'},encodeArrayPretty=function(e,d){var f=e.length,c=d+' ',g=','+c,a=['[',c],b;for(b=0;b0}}return c},onBindNotify:function(b,c,a){a.syncing=a.syncing+1||1;this[a._config.names.set](b);--a.syncing},removeBindings:function(){var c=this,a,d,b;if(!c.destroying){a=c.getBind();if(a&&typeof a!=='string'){for(d in a){b=a[d];b.destroy();b._config=b.getTemplateScope=null}}}c.setBind(null)},updateSession:function(a){var b=this.getInherited();if(a){b.session=a}else {delete b.session}},updateViewModel:function(a){var c=this.getInherited(),b=this.getController();if(a){c.viewModel=a;a.setView(this);if(b){b.initViewModel(a)}}else {delete c.viewModel}}}},0,0,0,0,0,0,[Ext.mixin,'Bindable'],0);Ext.cmd.derive('Ext.mixin.ComponentDelegation',Ext.Mixin,{mixinConfig:{id:'componentDelegation'},privates:{addDelegatedListener:function(c,k,j,a,d,i,h){var b=this,e,g,f;d=d||a.order;if(d){f=a&&a.priority;if(!f){a=a?Ext.Object.chain(a):{};a.priority=b.$orderToPriority[d]}}e=b.$delegatedEvents||(b.$delegatedEvents={});g=e[c]||(e[c]=new Ext.util.Event(b,c));if(g.addListener(k,j,a,i,h)){b.$hasDelegatedListeners._incr_(c)}},clearDelegatedListeners:function(){var e=this,a=e.$delegatedEvents,b,c,d;if(a){for(b in a){c=a[b];d=c.listeners.length;c.clearListeners();e.$hasDelegatedListeners._decr_(b,d);delete a[b]}}},doFireDelegatedEvent:function(f,g){var e=this,d=!0,a,b,c;if(e.$hasDelegatedListeners[f]){a=e.getRefOwner();while(a){b=a.$delegatedEvents;if(b){c=b[f];if(c){d=c.fireDelegated(e,g);if(d===!1){break}}}a=a.getRefOwner()}}return d},removeDelegatedListener:function(c,f,e){var d=this,b=d.$delegatedEvents,a;if(b){a=b[c];if(a&&a.removeListener(f,e)){d.$hasDelegatedListeners._decr_(c);if(a.listeners.length===0){delete b[c]}}}}},onClassMixedIn:function(a){function HasListeners(){}a.prototype.HasListeners=a.HasListeners=HasListeners;HasListeners.prototype=a.hasListeners=new Ext.mixin.ComponentDelegation.HasDelegatedListeners()}},0,0,0,0,0,0,[Ext.mixin,'ComponentDelegation'],function(a){function HasDelegatedListeners(){}a.HasDelegatedListeners=HasDelegatedListeners;HasDelegatedListeners.prototype=a.prototype.$hasDelegatedListeners=new Ext.mixin.Observable.HasListeners()});Ext.cmd.derive('Ext.Widget',Ext.Evented,{isWidget:!0,element:{reference:'element'},observableType:'component',cachedConfig:{style:null},config:{userCls:null},eventedConfig:{width:null,height:null},template:[],constructor:function(c){var a=this,b;a.initId(c);a.initElement();a.mixins.observable.constructor.call(a,c);Ext.ComponentManager.register(a);b=a.getController();if(b){b.init(a)}},afterCachedConfig:function(){var c=this,j=c.self.prototype,f=c.referenceList,i=c.renderElement,d,h,a,b,g,e;j.renderTemplate=d=document.createDocumentFragment();d.appendChild(i.clone(!0,!0));e=d.querySelectorAll('[id]');for(a=0,b=e.length;a]+>/gi,stripScriptsRe:/(?:)((\n|\r|.)*?)(?:<\/script>)/ig,nl2brRe:/\r?\n/g,hashRe:/#+$/,allHashes:/^#+$/,formatPattern:/[\d,\.#]+/,formatCleanRe:/[^\d\.#]/g,I18NFormatCleanRe:null,formatFns:{},constructor:function(){a=this},undef:function(a){return a!==undefined?a:''},defaultValue:function(a,b){return a!==undefined&&a!==''?a:b},substr:'ab'.substr(-1)!='b'?function(d,a,c){var b=String(d);return a<0?b.substr(Math.max(b.length+a,0),c):b.substr(a,c)}:function(c,b,a){return String(c).substr(b,a)},lowercase:function(a){return String(a).toLowerCase()},uppercase:function(a){return String(a).toUpperCase()},usMoney:function(b){return a.currency(b,'$',2)},currency:function(b,f,c,h){var d='',e=',0',g=0;b=b-0;if(b<0){b=-b;d='-'}c=Ext.isDefined(c)?c:a.currencyPrecision;e+=c>0?'.':'';for(;gb){a=a.substring(a.length-b)}}while(a.length2){}else {if(e.length===2){d=e[1].length;f=e[1].match(a.hashRe);if(f){m=f[0].length;l='trailingZeroes=new RegExp(Ext.String.escapeRegex(utilFormat.decimalSeparator) + "*0{0,'+m+'}$")'}}}b=['var utilFormat=Ext.util.Format,extNumber=Ext.Number,neg,absVal,fnum,parts'+(h?',thousandSeparator,thousands=[],j,n,i':'')+(i?',formatString="'+c+'",formatPattern=/[\\d,\\.#]+/':'')+',trailingZeroes;return function(v){if(typeof v!=="number"&&isNaN(v=extNumber.from(v,NaN)))return"";neg=v<0;','absVal=Math.abs(v);','fnum=Ext.Number.toFixed(absVal, '+d+');',l,';'];if(h){if(d){b[b.length]='parts=fnum.split(".");';b[b.length]='fnum=parts[0];'}b[b.length]='if(absVal>=1000) {';b[b.length]='thousandSeparator=utilFormat.thousandSeparator;thousands.length=0;j=fnum.length;n=fnum.length%3||3;for(i=0;i')},capitalize:Ext.String.capitalize,uncapitalize:Ext.String.uncapitalize,ellipsis:Ext.String.ellipsis,escape:Ext.String.escape,escapeRegex:Ext.String.escapeRegex,htmlDecode:Ext.String.htmlDecode,htmlEncode:Ext.String.htmlEncode,leftPad:Ext.String.leftPad,toggle:Ext.String.toggle,trim:Ext.String.trim,parseBox:function(b){b=b||0;if(typeof b==='number'){return {top:b,right:b,bottom:b,left:b}}var a=b.split(' '),c=a.length;if(c===1){a[1]=a[2]=a[3]=a[0]}else {if(c===2){a[2]=a[0];a[3]=a[1]}else {if(c===3){a[3]=a[1]}}}return {top:parseInt(a[0],10)||0,right:parseInt(a[1],10)||0,bottom:parseInt(a[2],10)||0,left:parseInt(a[3],10)||0}}}},1,0,0,0,0,0,[Ext.util,'Format'],0);Ext.cmd.derive('Ext.Template',Ext.Base,{inheritableStatics:{from:function(a,b){a=Ext.getDom(a);return new this(a.value||a.innerHTML,b||'')}},useEval:Ext.isGecko,constructor:function(g){var d=this,c=arguments,f=[],e,b=c.length,a;d.initialConfig={};if(b===1&&Ext.isArray(g)){c=g;b=c.length}if(b>1){for(e=0;e]*)\>)|(?:<\/tpl>)/g,actionsRe:/\s*(elif|elseif|if|for|foreach|exec|switch|case|eval|between)\s*\=\s*(?:(?:"([^"]*)")|(?:'([^']*)'))\s*/g,propRe:/prop=(?:(?:"([^"]*)")|(?:'([^']*)'))/,defaultRe:/^\s*default\s*$/,elseRe:/^\s*else\s*$/},1,0,0,0,0,0,[Ext.util,'XTemplateParser'],0);Ext.cmd.derive('Ext.util.XTemplateCompiler',Ext.util.XTemplateParser,{useEval:Ext.isGecko,useIndex:Ext.isIE8m,useFormat:!0,propNameRe:/^[\w\d\$]*$/,compile:function(c){var a=this,b=a.generate(c);return a.useEval?a.evalTpl(b):(new Function('Ext',b))(Ext)},generate:function(d){var a=this,b='var fm=Ext.util.Format,ts=Object.prototype.toString;',c;a.maxLevel=0;a.body=['var c0=values, a0='+a.createArrayTest(0)+', p0=parent, n0=xcount, i0=xindex, k0, v;\n'];if(a.definitions){if(typeof a.definitions==='string'){a.definitions=[a.definitions,b]}else {a.definitions.push(b)}}else {a.definitions=[b]}a.switches=[];a.parse(d);a.definitions.push((a.useEval?'$=':'return')+' function ('+a.fnArgs+') {',a.body.join(''),'}');c=a.definitions.join('\n');a.definitions.length=a.body.length=a.switches.length=0;delete a.definitions;delete a.body;delete a.switches;return c},doText:function(a){var b=this,c=b.body;a=a.replace(b.aposRe,"\\'").replace(b.newLineRe,'\\n');if(b.useIndex){c.push("out[out.length]='",a,"'\n")}else {c.push("out.push('",a,"')\n")}},doExpr:function(b){var a=this.body;a.push('if ((v='+b+') != null) out');if(this.useIndex){a.push("[out.length]=v+''\n")}else {a.push(".push(v+'')\n")}},doTag:function(b){var a=this.parseTag(b);if(a){this.doExpr(a)}else {this.doText('{'+b+'}')}},doElse:function(){this.body.push('} else {\n')},doEval:function(a){this.body.push(a,'\n')},doIf:function(b,c){var a=this;if(b==='.'){a.body.push('if (values) {\n')}else {if(a.propNameRe.test(b)){a.body.push('if (',a.parseTag(b),') {\n')}else {a.body.push('if (',a.addFn(b),a.callFn,') {\n')}}if(c.exec){a.doExec(c.exec)}},doElseIf:function(b,c){var a=this;if(b==='.'){a.body.push('else if (values) {\n')}else {if(a.propNameRe.test(b)){a.body.push('} else if (',a.parseTag(b),') {\n')}else {a.body.push('} else if (',a.addFn(b),a.callFn,') {\n')}}if(c.exec){a.doExec(c.exec)}},doSwitch:function(b){var a=this,c;if(b==='.'||b==='#'){c=b==='.'?'values':'xindex';a.body.push('switch (',c,') {\n')}else {if(a.propNameRe.test(b)){a.body.push('switch (',a.parseTag(b),') {\n')}else {a.body.push('switch (',a.addFn(b),a.callFn,') {\n')}}a.switches.push(0)},doCase:function(e){var a=this,c=Ext.isArray(e)?e:[e],d=a.switches.length-1,f,b;if(a.switches[d]){a.body.push('break;\n')}else {a.switches[d]++}for(b=0,d=c.length;b1){ out.push("',d.between,'"); } \n')}},doForEach:function(c,d){var b=this,f,a=b.level,e=a-1,g;if(c==='.'){f='values'}else {if(b.propNameRe.test(c)){f=b.parseTag(c)}else {f=b.addFn(c)+b.callFn}}if(b.maxLevel1){ out.push("',d.between,'"); } \n')}},createArrayTest:'isArray' in Array?function(a){return 'Array.isArray(c'+a+')'}:function(a){return 'ts.call(c'+a+')==="[object Array]"'},doExec:function(d,e){var a=this,c='f'+a.definitions.length,b=a.guards[a.strict?0:1];a.definitions.push('function '+c+'('+a.fnArgs+') {',b.doTry,' var $v = values; with($v) {',' '+d,' }',b.doCatch,'}');a.body.push(c+a.callFn+'\n')},guards:[{doTry:'',doCatch:''},{doTry:'try { ',doCatch:' } catch(e) {\n}'}],addFn:function(c){var a=this,b='f'+a.definitions.length,d=a.guards[a.strict?0:1];if(c==='.'){a.definitions.push('function '+b+'('+a.fnArgs+') {',' return values','}')}else {if(c==='..'){a.definitions.push('function '+b+'('+a.fnArgs+') {',' return parent','}')}else {a.definitions.push('function '+b+'('+a.fnArgs+') {',d.doTry,' var $v = values; with($v) {',' return('+c+')',' }',d.doCatch,'}')}}return b},parseTag:function(h){var e=this,f=e.tagRe.exec(h),a,c,d,g,b;if(!f){return null}a=f[1];c=f[2];d=f[3];g=f[4];if(a=='.'){if(!e.validTypes){e.definitions.push('var validTypes={string:1,number:1,boolean:1};');e.validTypes=!0}b='validTypes[typeof values] || ts.call(values) === "[object Date]" ? values : ""'}else {if(a=='#'){b='xindex'}else {if(a=='$'){b='xkey'}else {if(a.substr(0,7)=='parent.'){b=a}else {if(isNaN(a)&&a.indexOf('-')==-1&&a.indexOf('.')!=-1){b='values.'+a}else {b="values['"+a+"']"}}}}}if(g){b='('+b+g+')'}if(c&&e.useFormat){d=d?','+d:'';if(c.substr(0,5)!='this.'){c='fm.'+c+'('}else {c+='('}}else {return b}return c+b+d+')'},evalTpl:function($){eval($);return $},newLineRe:/\r\n|\r|\n/g,aposRe:/[']/g,intRe:/^\s*(\d+)\s*$/,tagRe:/^([\w-\.\#\$]+)(?:\:([\w\.]*)(?:\((.*?)?\))?)?(\s?[\+\-\*\/]\s?[\d\.\+\-\*\/\(\)]+)?$/},0,0,0,0,0,0,[Ext.util,'XTemplateCompiler'],function(){var a=this.prototype;a.fnArgs='out,values,parent,xindex,xcount,xkey';a.callFn='.call(this,'+a.fnArgs+')'});Ext.cmd.derive('Ext.XTemplate',Ext.Template,{isXTemplate:!0,emptyObj:{},fn:null,strict:!1,apply:function(b,a,d,c){return this.applyOut(b,[],a,d,c).join('')},applyOut:function(g,d,f,c,b){var a=this,e;if(!a.fn){e=new Ext.util.XTemplateCompiler({useFormat:a.disableFormats!==!0,definitions:a.definitions,strict:a.strict});a.fn=e.compile(a.html)}c=c||1;b=b||1;if(a.strict){a.fn(d,g,f||a.emptyObj,c,b)}else {try{a.fn(d,g,f||a.emptyObj,c,b)}catch(h){}}return d},compile:function(){return this},statics:{getTpl:function(c,d){var b=c[d],a;if(b&&!b.isTemplate){b=Ext.ClassManager.dynInstantiate('Ext.XTemplate',b);if(c.hasOwnProperty(d)){a=c}else {for(a=c.self.prototype;a&&!a.hasOwnProperty(d);a=a.superclass){}}a[d]=b;b.owner=a}return b||null}}},0,0,0,0,0,0,[Ext,'XTemplate'],0);Ext.cmd.derive('Ext.app.EventDomain',Ext.Base,{statics:{instances:{}},isEventDomain:!0,isInstance:!1,constructor:function(){var a=this;if(!a.isInstance){Ext.app.EventDomain.instances[a.type]=a}a.bus={};a.monitoredClasses=[]},dispatch:function(l,h,m){h=Ext.canonicalEventName(h);var j=this,n=j.bus,b=n[h],c,a,i,g,e,k,d,f;if(!b){return !0}for(c in b){if(b.hasOwnProperty(c)&&j.match(l,c,j.controller)){a=b[c];for(i in a){if(a.hasOwnProperty(i)){g=a[i];if(g.controller.isActive()){e=g.list;k=e.length;for(d=0;da.clientWidth}}if(e==='scroll'){h=!0}else {if(e){h=a.scrollHeight>a.clientHeight}}if(g){i=f.height}if(h){j=f.width}}}return {width:j,height:i}},getPosition:function(){return this.position},updateDirectionLock:Ext.emptyFn,updateDisabled:Ext.emptyFn,updateIndicators:Ext.emptyFn,updateMaxPosition:Ext.emptyFn,updateMaxUserPosition:Ext.emptyFn,updateMinPosition:Ext.emptyFn,updateMinUserPosition:Ext.emptyFn,updateMomenumEasing:Ext.emptyFn,updateX:Ext.emptyFn,updateY:Ext.emptyFn,onPartnerScrollStart:Ext.emptyFn,onPartnerScrollEnd:Ext.emptyFn,refresh:function(){this.fireEvent('refresh',this);return this},removePartner:function(c){var b=this._partners,a=c._partners;if(b){delete b[c.getId()]}if(a){delete a[this.getId()]}},scrollBy:function(a,b,c){var d=this.getPosition();if(a){if(a.length){c=b;b=a[1];a=a[0]}else {if(typeof a!=='number'){c=b;b=a.y;a=a.x}}}a=typeof a==='number'?a+d.x:null;b=typeof b==='number'?b+d.y:null;return this.doScrollTo(a,b,c)},scrollIntoView:function(d,i,h,e){var a=this,c=a.getPosition(),b,f,g,j=a.getElement();if(d){b=Ext.fly(d).getScrollIntoViewXY(j,c.x,c.y);f=i===!1?c.x:b.x;g=b.y;if(e){a.on({scrollend:'doHighlight',scope:a,single:!0,args:[d,e]})}a.doScrollTo(f,g,h)}},isInView:function(d){var f=this,c={x:!1,y:!1},b,e=f.getElement(),a;if(d&&e.contains(d)){a=e.getRegion();b=Ext.fly(d).getRegion();c.x=b.right>a.left&&b.lefta.top&&b.top0){b-=1}if(c>0){c-=1}e.setSpacerXY({x:b,y:c});d.show()}}},deprecated:{5:{methods:{getScroller:function(){return this}}},'5.1.0':{methods:{scrollToTop:function(a){return this.scrollTo(0,0,a)},scrollToEnd:function(a){return this.scrollTo(Infinity,Infinity,a)}}}},privates:{getSpacer:function(){var b=this,a=b._spacer,c;if(!a){c=b.getElement();a=b._spacer=c.createChild({cls:b._spacerCls,role:'presentation'});a.setVisibilityMode(2);c.position()}return a},applySpacerXY:function(a,b){if(b&&a.x===b.x&&a.y===b.y){a=undefined}return a},updateSpacerXY:function(a){this.getSpacer().setLocalXY(a.x,a.y)},convertX:function(a){return a},doHighlight:function(b,a){if(a!==!0){Ext.fly(b).highlight(a)}else {Ext.fly(b).highlight()}},fireScrollStart:function(b,c){var a=this,d=a.component;a.invokePartners('onPartnerScrollStart',b,c);if(a.hasListeners.scrollstart){a.fireEvent('scrollstart',a,b,c)}if(d&&d.onScrollStart){d.onScrollStart(b,c)}Ext.GlobalEvents.fireEvent('scrollstart',a,b,c)},fireScroll:function(b,c){var a=this,d=a.component;a.invokePartners('onPartnerScroll',b,c);if(a.hasListeners.scroll){a.fireEvent('scroll',a,b,c)}if(d&&d.onScrollMove){d.onScrollMove(b,c)}Ext.GlobalEvents.fireEvent('scroll',a,b,c)},fireScrollEnd:function(b,c){var a=this,d=a.component;a.invokePartners('onPartnerScrollEnd',b,c);if(a.hasListeners.scrollend){a.fireEvent('scrollend',a,b,c)}if(d&&d.onScrollEnd){d.onScrollEnd(b,c)}Ext.GlobalEvents.fireEvent('scrollend',a,b,c)},initXStyle:function(){var b=this.getElement(),a=this.getX();if(b&&b.dom){if(!a){a='hidden'}else {if(a===!0){a='auto'}}b.setStyle('overflow-x',a)}},initYStyle:function(){var b=this.getElement(),a=this.getY();if(b&&b.dom){if(!a){a='hidden'}else {if(a===!0){a='auto'}}b.setStyle('overflow-y',a)}},invokePartners:function(d,g,h){var b=this,c=b._partners,a,e,f=d==='onPartnerScrollEnd';if(!b.suspendSync&!b.isReflecting){for(e in c){a=c[e].scroller;a.isReflecting=!0;a[d](b,g,h);if(f){a.isReflecting=!1}}}},clearReflecting:function(){this.isReflecting=!1},suspendPartnerSync:function(){this.suspendSync=(this.suspendSync||0)+1},resumePartnerSync:function(){if(this.suspendSync){this.suspendSync--}},updateDomScrollPosition:function(){var a=this,d=a.getElement(),b,c=a.position;if(d&&!d.destroyed){b=a.getElementScroll(d);c.x=b.left;c.y=b.top}a.positionDirty=!1;return c},getElementScroll:function(a){return a.getScroll()},onDomScroll:function(){var a=this,b,d,e,c;if(a.isTouchScroller&&Ext.supports.touchScroll===2){c=a.getElement().dom;c.scrollTop=c.scrollLeft=0;return}b=a.updateDomScrollPosition();d=b.x;e=b.y;if(!a.isScrolling){a.isScrolling=Ext.isScrolling=!0;a.fireScrollStart(d,e)}a.fireScroll(d,e);a.onDomScrollEnd()},onDomScrollEnd:function(){var a=this,b=a.getPosition(),c=b.x,d=b.y;a.isScrolling=Ext.isScrolling=!1;a.trackingScrollLeft=c;a.trackingScrollTop=d;a.fireScrollEnd(c,d)},onPartnerScroll:function(d,b,c){var a=d._partners[this.getId()].axis;if(a){if(a==='x'){c=null}else {if(a==='y'){b=null}}}this.doScrollTo(b,c,!1,!0)},restoreState:function(){var a=this,c=a.getElement(),b;if(c){b=c.dom;if(a.trackingScrollTop!==undefined){b.scrollTop=a.trackingScrollTop;b.scrollLeft=a.trackingScrollLeft}}}}},1,0,0,0,['scroller.scroller'],[[Ext.mixin.Factoryable.prototype.mixinId||Ext.mixin.Factoryable.$className,Ext.mixin.Factoryable]],[Ext.scroll,'Scroller'],0);Ext.cmd.derive('Ext.fx.easing.Abstract',Ext.Base,{config:{startTime:0,startValue:0},isEasing:!0,isEnded:!1,constructor:function(a){this.initConfig(a);return this},applyStartTime:function(a){if(!a){a=Ext.Date.now()}return a},updateStartTime:function(a){this.reset()},reset:function(){this.isEnded=!1},getValue:Ext.emptyFn},1,0,0,0,0,0,[Ext.fx.easing,'Abstract'],0);Ext.cmd.derive('Ext.fx.easing.Momentum',Ext.fx.easing.Abstract,{config:{acceleration:30,friction:0,startVelocity:0},alpha:0,updateFriction:function(b){var a=Math.log(1-b/10);this.theta=a;this.alpha=a/this.getAcceleration()},updateStartVelocity:function(a){this.velocity=a*this.getAcceleration()},updateAcceleration:function(a){this.velocity=this.getStartVelocity()*a;this.alpha=this.theta/a},getValue:function(){return this.getStartValue()-this.velocity*(1-this.getFrictionFactor())/this.theta},getFrictionFactor:function(){var a=Ext.Date.now()-this.getStartTime();return Math.exp(a*this.alpha)},getVelocity:function(){return this.getFrictionFactor()*this.velocity}},0,0,0,0,0,0,[Ext.fx.easing,'Momentum'],0);Ext.cmd.derive('Ext.fx.easing.Bounce',Ext.fx.easing.Abstract,{config:{springTension:0.3,acceleration:30,startVelocity:0},getValue:function(){var b=Ext.Date.now()-this.getStartTime(),a=b/this.getAcceleration(),c=a*Math.pow(Math.E,-this.getSpringTension()*a);return this.getStartValue()+this.getStartVelocity()*c}},0,0,0,0,0,0,[Ext.fx.easing,'Bounce'],0);Ext.cmd.derive('Ext.fx.easing.BoundMomentum',Ext.fx.easing.Abstract,{config:{momentum:null,bounce:null,minMomentumValue:0,maxMomentumValue:0,minVelocity:0.01,startVelocity:0},applyMomentum:function(b,a){return Ext.factory(b,Ext.fx.easing.Momentum,a)},applyBounce:function(b,a){return Ext.factory(b,Ext.fx.easing.Bounce,a)},updateStartTime:function(a){this.getMomentum().setStartTime(a);Ext.fx.easing.Abstract.prototype.updateStartTime.apply(this,arguments)},updateStartVelocity:function(a){this.getMomentum().setStartVelocity(a)},updateStartValue:function(a){this.getMomentum().setStartValue(a)},reset:function(){this.lastValue=null;this.isBouncingBack=!1;this.isOutOfBound=!1;return Ext.fx.easing.Abstract.prototype.reset.apply(this,arguments)},getValue:function(){var d=this.getMomentum(),j=this.getBounce(),f=d.getStartVelocity(),b=f>0?1:-1,i=this.getMinMomentumValue(),h=this.getMaxMomentumValue(),g=b==1?h:i,c=this.lastValue,a,e;if(f===0){return this.getStartValue()}if(!this.isOutOfBound){a=d.getValue();e=d.getVelocity();if(Math.abs(e)=i&&a<=h){return a}this.isOutOfBound=!0;j.setStartTime(Ext.Date.now()).setStartVelocity(e).setStartValue(g)}a=j.getValue();if(!this.isEnded){if(!this.isBouncingBack){if(c!==null){if(b==1&&ac){this.isBouncingBack=!0}}}else {if(Math.round(a)==g){this.isEnded=!0}}}this.lastValue=a;return a}},0,0,0,0,0,0,[Ext.fx.easing,'BoundMomentum'],0);Ext.cmd.derive('Ext.fx.easing.Linear',Ext.fx.easing.Abstract,{config:{duration:0,endValue:0},updateStartValue:function(a){this.distance=this.getEndValue()-a},updateEndValue:function(a){this.distance=a-this.getStartValue()},getValue:function(){var a=Ext.Date.now()-this.getStartTime(),b=this.getDuration();if(a>b){this.isEnded=!0;return this.getEndValue()}else {return this.getStartValue()+a/b*this.distance}}},0,0,0,0,['easing.linear'],0,[Ext.fx.easing,'Linear'],0);Ext.cmd.derive('Ext.fx.easing.EaseOut',Ext.fx.easing.Linear,{config:{exponent:4,duration:1500},getValue:function(){var a=Ext.Date.now()-this.getStartTime(),b=this.getDuration(),d=this.getStartValue(),f=this.getEndValue(),e=this.distance,i=a/b,h=1-i,g=1-Math.pow(h,this.getExponent()),c=d+g*e;if(a>=b){this.isEnded=!0;return f}return c}},0,0,0,0,['easing.ease-out'],0,[Ext.fx.easing,'EaseOut'],0);Ext.cmd.derive('Ext.util.translatable.Abstract',Ext.Evented,{config:{useWrapper:null,easing:null,easingX:null,easingY:null},x:0,y:0,activeEasingX:null,activeEasingY:null,isAnimating:!1,isTranslatable:!0,constructor:function(a){this.mixins.observable.constructor.call(this,a);this.position={x:0,y:0}},factoryEasing:function(a){return Ext.factory(a,Ext.fx.easing.Linear,null,'easing')},applyEasing:function(a){if(!this.getEasingX()){this.setEasingX(this.factoryEasing(a))}if(!this.getEasingY()){this.setEasingY(this.factoryEasing(a))}},applyEasingX:function(a){return this.factoryEasing(a)},applyEasingY:function(a){return this.factoryEasing(a)},doTranslate:Ext.emptyFn,translate:function(a,b,c){if(c){return this.translateAnimated(a,b,c)}if(this.isAnimating){this.stopAnimation()}if(!isNaN(a)&&typeof a=='number'){this.x=a}if(!isNaN(b)&&typeof b=='number'){this.y=b}this.doTranslate(a,b)},translateAxis:function(e,a,d){var b,c;if(e=='x'){b=a}else {c=a}return this.translate(b,c,d)},getPosition:function(){var b=this,a=b.position;a.x=-b.x;a.y=-b.y;return a},animate:function(a,b){this.activeEasingX=a;this.activeEasingY=b;this.isAnimating=!0;this.lastX=null;this.lastY=null;Ext.AnimationQueue.start(this.doAnimationFrame,this);this.fireEvent('animationstart',this,this.x,this.y);return this},translateAnimated:function(g,h,a){var b=this;if(!Ext.isObject(a)){a={}}if(b.isAnimating){b.stopAnimation()}b.callback=a.callback;b.callbackScope=a.scope;var f=Ext.Date.now(),e=a.easing,c=typeof g=='number'?a.easingX||e||b.getEasingX()||!0:null,d=typeof h=='number'?a.easingY||e||b.getEasingY()||!0:null;if(c){c=b.factoryEasing(c);c.setStartTime(f);c.setStartValue(b.x);c.setEndValue(g);if('duration' in a){c.setDuration(a.duration)}}if(d){d=b.factoryEasing(d);d.setStartTime(f);d.setStartValue(b.y);d.setEndValue(h);if('duration' in a){d.setDuration(a.duration)}}return b.animate(c,d)},doAnimationFrame:function(){var a=this,d=a.activeEasingX,e=a.activeEasingY,f=Date.now(),b,c;if(!a.isAnimating){return}a.lastRun=f;if(d===null&&e===null){a.stopAnimation();return}if(d!==null){a.x=b=Math.round(d.getValue());if(d.isEnded){a.activeEasingX=null;a.fireEvent('axisanimationend',a,'x',b)}}else {b=a.x}if(e!==null){a.y=c=Math.round(e.getValue());if(e.isEnded){a.activeEasingY=null;a.fireEvent('axisanimationend',a,'y',c)}}else {c=a.y}if(a.lastX!==b||a.lastY!==c){a.doTranslate(b,c);a.lastX=b;a.lastY=c}a.fireEvent('animationframe',a,b,c)},stopAnimation:function(){var a=this;if(!a.isAnimating){return}a.activeEasingX=null;a.activeEasingY=null;a.isAnimating=!1;Ext.AnimationQueue.stop(a.doAnimationFrame,a);a.fireEvent('animationend',a,a.x,a.y);if(a.callback){a.callback.call(a.callbackScope);a.callback=null}},refresh:function(){this.translate(this.x,this.y)},destroy:function(){if(this.isAnimating){this.stopAnimation()}Ext.Evented.prototype.destroy.call(this)}},1,0,0,0,0,0,[Ext.util.translatable,'Abstract'],0);Ext.cmd.derive('Ext.util.translatable.Dom',Ext.util.translatable.Abstract,{config:{element:null},applyElement:function(a){if(!a){return}return Ext.get(a)},updateElement:function(){this.refresh()}},0,0,0,0,0,0,[Ext.util.translatable,'Dom'],0);Ext.cmd.derive('Ext.util.translatable.CssTransform',Ext.util.translatable.Dom,{doTranslate:function(b,c){var a=this.getElement();if(!this.destroyed&&!a.destroyed){a.translate(b,c)}},destroy:function(){var a=this.getElement();if(a&&!a.destroyed){a.dom.style.webkitTransform=null}Ext.util.translatable.Dom.prototype.destroy.call(this)}},0,0,0,0,0,0,[Ext.util.translatable,'CssTransform'],0);Ext.cmd.derive('Ext.util.translatable.ScrollPosition',Ext.util.translatable.Dom,{type:'scrollposition',config:{useWrapper:!0},getWrapper:function(){var a=this.wrapper,c=this.getElement(),b;if(!a){b=c.getParent();if(!b){return null}if(b.hasCls('x-translatable-hboxfix')){b=b.getParent()}if(this.getUseWrapper()){a=c.wrap()}else {a=b}c.addCls('x-translatable');a.addCls('x-translatable-container');this.wrapper=a;a.on('painted',function(){if(!this.isAnimating){this.refresh()}},this);this.refresh()}return a},doTranslate:function(c,d){var b=this.getWrapper(),a;if(b){a=b.dom;if(typeof c=='number'){a.scrollLeft=500000-c}if(typeof d=='number'){a.scrollTop=500000-d}}},destroy:function(){var a=this,c=a.getElement(),b=a.wrapper;if(b){if(!c.destroyed){if(a.getUseWrapper()){b.doReplaceWith(c)}c.removeCls('x-translatable')}if(!b.destroyed){b.removeCls('x-translatable-container');b.un('painted','refresh',a)}delete a.wrapper;delete a._element}Ext.util.translatable.Dom.prototype.destroy.call(this)}},0,0,0,0,0,0,[Ext.util.translatable,'ScrollPosition'],0);Ext.cmd.derive('Ext.util.translatable.ScrollParent',Ext.util.translatable.Dom,{isScrollParent:!0,applyElement:function(b){var a=Ext.get(b);if(a){this.parent=a.parent()}return a},doTranslate:function(b,c){var a=this.parent;a.setScrollLeft(Math.round(-b));a.setScrollTop(Math.round(-c))},getPosition:function(){var c=this,a=c.position,b=c.parent;a.x=b.getScrollLeft();a.y=b.getScrollTop();return a}},0,0,0,0,0,0,[Ext.util.translatable,'ScrollParent'],0);Ext.cmd.derive('Ext.util.translatable.CssPosition',Ext.util.translatable.Dom,{doTranslate:function(b,c){var a=this.getElement().dom.style;if(typeof b=='number'){a.left=b+'px'}if(typeof c=='number'){a.top=c+'px'}},destroy:function(){var a=this.getElement().dom.style;a.left=null;a.top=null;Ext.util.translatable.Dom.prototype.destroy.call(this)}},0,0,0,0,0,0,[Ext.util.translatable,'CssPosition'],0);Ext.cmd.derive('Ext.util.Translatable',Ext.Base,{constructor:function(a){var b=Ext.util.translatable;switch(Ext.browser.getPreferredTranslationMethod(a)){case 'scrollposition':return new b.ScrollPosition(a);case 'scrollparent':return new b.ScrollParent(a);case 'csstransform':return new b.CssTransform(a);case 'cssposition':return new b.CssPosition(a);}}},1,0,0,0,0,0,[Ext.util,'Translatable'],0);Ext.cmd.derive('Ext.scroll.Indicator',Ext.Widget,{config:{axis:null,hideAnimation:!0,hideDelay:0,scroller:null,minLength:24},defaultHideAnimation:{to:{opacity:0},duration:300},names:{x:{side:'l',getSize:'getHeight',setLength:'setWidth',translate:'translateX'},y:{side:'t',getSize:'getWidth',setLength:'setHeight',translate:'translateY'}},oppositeAxis:{x:'y',y:'x'},cls:'x-scroll-indicator',applyHideAnimation:function(a){if(a){a=Ext.mergeIf({onEnd:this.onHideAnimationEnd,scope:this},this.defaultHideAnimation,a)}return a},constructor:function(c){var a=this,b;Ext.Widget.prototype.constructor.call(this,c);b=a.getAxis();a.names=a.names[b];a.element.addCls(a.cls+' '+a.cls+'-'+b)},hide:function(){var a=this,b=a.getHideDelay();if(b){a._hideTimer=Ext.defer(a.doHide,b,a)}else {a.doHide()}},setValue:function(c){var a=this,o=a.element,l=a.names,m=a.getAxis(),k=a.getScroller(),f=k.getMaxUserPosition()[m],g=k.getElementSize()[m],b=a.length,j=a.getMinLength(),e=b,i=g-b-a.sizeAdjust,h=Math.round,n=Math.max,d;if(c<0){e=h(n(b+b*c/g,j));d=0}else {if(c>f){e=h(n(b-b*(c-f)/g,j));d=i+b-e}else {d=h(c/f*i)}}a[l.translate](d);o[l.setLength](e)},show:function(){var a=this,b=a.element,c=b.getActiveAnimation();if(c){c.end()}if(!a._inDom){a.getScroller().getElement().appendChild(b);a._inDom=!0;if(!a.size){a.cacheStyles()}}a.refreshLength();clearTimeout(a._hideTimer);b.setStyle('opacity','')},privates:{cacheStyles:function(){var a=this,c=a.element,b=a.names;a.size=c[b.getSize]();a.margin=c.getMargin(b.side)},doHide:function(){var a=this.getHideAnimation(),b=this.element;if(a){b.animate(a)}else {b.setStyle('opacity',0)}},hasOpposite:function(){return this.getScroller().isAxisEnabled(this.oppositeAxis[this.getAxis()])},onHideAnimationEnd:function(){this.element.setStyle('opacity','0')},refreshLength:function(){var a=this,i=a.names,g=a.getAxis(),e=a.getScroller(),h=e.getSize()[g],c=e.getElementSize()[g],j=c/h,b=a.margin*2,d=a.hasOpposite()?b+a.size:b,f=Math.max(Math.round((c-d)*j),a.getMinLength());a.sizeAdjust=d;a.length=f;a.element[i.setLength](f)},translateX:function(a){this.element.translate(a)},translateY:function(a){this.element.translate(0,a)}}},1,['scrollindicator'],['widget','scrollindicator'],{'widget':!0,'scrollindicator':!0},['widget.scrollindicator'],0,[Ext.scroll,'Indicator'],0);Ext.cmd.derive('Ext.scroll.TouchScroller',Ext.scroll.Scroller,{isTouchScroller:!0,config:{autoRefresh:!0,bounceEasing:{duration:400},elementSize:undefined,indicators:!0,fps:'auto',maxAbsoluteVelocity:6,momentumEasing:{momentum:{acceleration:30,friction:0.5},bounce:{acceleration:30,springTension:0.3},minVelocity:1},outOfBoundRestrictFactor:0.5,innerElement:null,size:undefined,slotSnapEasing:{duration:150},slotSnapOffset:{x:0,y:0},startMomentumResetTime:300,translatable:{translationMethod:'auto',useWrapper:!1}},cls:'x-scroll-container',scrollerCls:'x-scroll-scroller',dragStartTime:0,dragEndTime:0,isDragging:!1,isAnimating:!1,isMouseEvent:{mousedown:1,mousemove:1,mouseup:1},listenerMap:{touchstart:'onTouchStart',touchmove:'onTouchMove',dragstart:'onDragStart',drag:'onDrag',dragend:'onDragEnd'},refreshCounter:0,constructor:function(c){var a=this,b='onEvent';a.elementListeners={touchstart:b,touchmove:b,dragstart:b,drag:b,dragend:b,scope:a};a.minPosition={x:0,y:0};a.startPosition={x:0,y:0};a.velocity={x:0,y:0};a.isAxisEnabledFlags={x:!1,y:!1};a.flickStartPosition={x:0,y:0};a.flickStartTime={x:0,y:0};a.lastDragPosition={x:0,y:0};a.dragDirection={x:0,y:0};Ext.scroll.Scroller.prototype.constructor.call(this,c);a.refreshAxes();a.scheduleRefresh={idle:a.doRefresh,scope:a,single:!0,destroyable:!0}},applyBounceEasing:function(b){var a=Ext.fx.easing.EaseOut;return {x:Ext.factory(b,a),y:Ext.factory(b,a)}},applyElementSize:function(b){var e=this.getElement(),a,c,d;if(!e){return null}a=e.dom;if(!a){return}if(b==null){c=a.clientWidth;d=a.clientHeight}else {c=b.x;d=b.y}return {x:c,y:d}},applyIndicators:function(b,a){var g=this,c,d,e,f;if(b){if(b===!0){c=d={}}else {e=b.x;f=b.y;if(e||f){c=e==null||e===!0?{}:e;d=e==null||f===!0?{}:f}else {c=d=b}}if(a){if(c){a.x.setConfig(c)}else {a.x.destroy();a.x=null}if(d){a.y.setConfig(d)}else {a.y.destroy();a.y=null}b=a}else {b={x:null,y:null};if(c){b.x=new Ext.scroll.Indicator(Ext.applyIf({axis:'x',scroller:g},c))}if(d){b.y=new Ext.scroll.Indicator(Ext.applyIf({axis:'y',scroller:g},d))}}}else {if(a){if(a.x){a.x.destroy()}if(a.y){a.y.destroy()}a.x=a.y=null}}return b},applyMomentumEasing:function(b){var a=Ext.fx.easing.BoundMomentum;return {x:Ext.factory(b,a),y:Ext.factory(b,a)}},applyInnerElement:function(a){if(a&&!a.isElement){a=Ext.get(a)}return a},applyMaxPosition:function(a,c){if(c&&a.x===c.x&&a.y===c.y){return}var d=this.getTranslatable(),b;if(d.isAnimating){b=d.activeEasingY;if(b&&b.getStartVelocity&&b.getStartVelocity()<0&&a.yi){d=i}}if(l){c=a.convertX(c);d=a.convertX(d)}if(d!==null){f=a.getBounceEasing()[b];f.setConfig({startTime:j,startValue:-c,endValue:-d});return f}if(e===0){return null}if(e<-g){e=-g}else {if(e>g){e=g}}f=a.getMomentumEasing()[b];h={startTime:j,startValue:-c,startVelocity:e*1.5,minMomentumValue:-i,maxMomentumValue:0};if(l){a.convertEasingConfig(h)}f.setConfig(h);return f},getSnapPosition:function(d){var e=this,c=e.getSlotSnapSize()[d],f=null,b,h,g,a;if(c!==0&&e.isAxisEnabled(d)){b=e.position[d];h=e.getSlotSnapOffset()[d];g=e.getMaxUserPosition()[d];a=Math.floor((b-h)%c);if(a!==0){if(b!==g){if(Math.abs(a)>c/2){f=Math.min(g,b+(a>0?c-a:a-c))}else {f=b-a}}else {f=b-a}}}return f},hideIndicators:function(){var d=this,a=d.getIndicators(),b,c;if(a){if(d.isAxisEnabled('x')){b=a.x;if(b){b.hide()}}if(d.isAxisEnabled('y')){c=a.y;if(c){c.hide()}}}},isAxisEnabled:function(a){this.getX();this.getY();return this.isAxisEnabledFlags[a]},onAnimationEnd:function(){this.snapToBoundary();this.onScrollEnd()},onAnimationFrame:function(d,b,c){var a=this.position;a.x=this.convertX(-b);a.y=-c;this.onScroll()},onAxisDrag:function(a,k){if(k&&this.isAxisEnabled(a)){var b=this,o=b.flickStartPosition,g=b.flickStartTime,f=b.lastDragPosition,d=b.dragDirection,r=b.position[a],q=b.getMinUserPosition()[a],e=b.getMaxUserPosition()[a],p=b.startPosition[a],l=f[a],c=p-k,i=d[a],h=b.getOutOfBoundRestrictFactor(),n=b.getStartMomentumResetTime(),m=Ext.Date.now(),j;if(ce){j=c-e;c=e+j*h}}if(c>l){d[a]=1}else {if(cn){o[a]=r;g[a]=m}f[a]=c;return !0}},onDomScroll:function(){var c=this,b,a;if(c.getTranslatable().isScrollParent){b=c.getElement().dom;a=c.position;a.x=b.scrollLeft;a.y=b.scrollTop}Ext.scroll.Scroller.prototype.onDomScroll.call(this)},onDrag:function(c){var a=this,b=a.lastDragPosition;if(!a.isDragging){return}if(a.onAxisDrag('x',a.convertX(c.deltaX))|a.onAxisDrag('y',c.deltaY)){a.doScrollTo(b.x,b.y)}},onDragEnd:function(d){var a=this,b,c;if(!a.isDragging){return}a.dragEndTime=Ext.Date.now();a.onDrag(d);a.isDragging=!1;b=a.getAnimationEasing('x',d);c=a.getAnimationEasing('y',d);if(b||c){a.getTranslatable().animate(b,c)}else {a.onScrollEnd()}},onDragStart:function(d){var a=this,b=a.getDirection(),m=d.absDeltaX,n=d.absDeltaY,o=a.getDirectionLock(),l=a.startPosition,g=a.flickStartPosition,j=a.flickStartTime,h=a.lastDragPosition,i=a.position,k=a.dragDirection,e=i.x,f=i.y,c=Ext.Date.now();if(o&&b!=='both'){if(b==='horizontal'&&m>n||b==='vertical'&&n>m){d.stopPropagation()}else {return}}h.x=e;h.y=f;g.x=e;g.y=f;l.x=e;l.y=f;j.x=c;j.y=c;k.x=0;k.y=0;a.dragStartTime=c;a.isDragging=!0;if(!a.isScrolling){a.onScrollStart()}},onElementResize:function(b,a){this.refresh(!0,{elementSize:{x:a.contentWidth,y:a.contentHeight},size:this.getAutoRefresh()?null:this.getSize()})},onElementScroll:function(b,a){a.scrollTop=a.scrollLeft=0},onEvent:function(b){var a=this,c=b.browserEvent;if((!a.self.isTouching||a.isTouching)&&(!a.getTranslatable().isScrollParent||!a.isMouseEvent[c.type]&&c.pointerType!=='mouse')&&(a.getY()||a.getX())){a[a.listenerMap[b.type]](b)}},onInnerElementResize:function(b,a){this.refresh(!0,{size:{x:a.width,y:a.height}})},onMouseWheel:function(j){var a=this,g=j.getWheelDeltas(),c=-g.x,d=-g.y,b=a.position,e=a.getMaxUserPosition(),f=a.getMinUserPosition(),h=Math.max,i=Math.min,k=h(i(b.x+c,e.x),f.x),l=h(i(b.y+d,e.y),f.y);c=k-b.x;d=l-b.y;if(!c&&!d){return}j.stopEvent();a.onScrollStart();a.scrollBy(c,d);a.onScroll();a.onScrollEnd()},onPartnerScrollEnd:function(b,c){var a=this;if(!a.getTranslatable().isScrollParent){a.fireScrollEnd(b,c)}Ext.scroll.Scroller.prototype.onPartnerScrollEnd.call(this,b,c);a.isScrolling=!1;a.hideIndicators()},onPartnerScrollStart:function(b,c){var a=this;a.isScrolling=!0;if(!a.getTranslatable().isScrollParent){a.fireScrollStart(b,c)}a.showIndicators()},onScroll:function(){var a=this,e=a.position,f=e.x,g=e.y,b=a.getIndicators(),c,d;if(b){if(a.isAxisEnabled('x')){c=b.x;if(c){c.setValue(f)}}if(a.isAxisEnabled('y')){d=b.y;if(d){d.setValue(g)}}}a.fireScroll(f,g)},onScrollEnd:function(){var a=this,b=a.position;if(a.isScrolling&&!a.isTouching&&!a.snapToSlot()){a.hideIndicators();a.isScrolling=Ext.isScrolling=!1;a.fireScrollEnd(b.x,b.y)}},onScrollStart:function(){var a=this,b=a.position;if(!a.isScrolling){a.showIndicators();a.isScrolling=Ext.isScrolling=!0;a.fireScrollStart(b.x,b.y)}},onTouchEnd:function(){var a=this;a.isTouching=a.self.isTouching=!1;if(!a.isDragging&&a.snapToSlot()){a.onScrollStart()}},onTouchMove:function(a){a.preventDefault()},onTouchStart:function(){var a=this;a.isTouching=a.self.isTouching=!0;Ext.getDoc().on({touchend:'onTouchEnd',scope:a,single:!0});a.stopAnimation()},refreshAxes:function(){var a=this,b=a.isAxisEnabledFlags,k=a.getSize(),h=a.getElementSize(),e=a.getIndicators(),f,g,c,d,i,j;if(!k||!h){return}f=Math.max(0,k.x-h.x);g=Math.max(0,k.y-h.y);c=a.getX();d=a.getY();a.setMaxPosition({x:f,y:g});if(c===!0||c==='auto'){b.x=!!f}else {if(c===!1){b.x=!1;i=e&&e.x;if(i){i.hide()}}else {if(c==='scroll'){b.x=!0}}}if(d===!0||d==='auto'){b.y=!!g}else {if(d===!1){b.y=!1;j=e&&e.y;if(j){j.hide()}}else {if(d==='scroll'){b.y=!0}}}a.setMaxUserPosition({x:b.x?f:0,y:b.y?g:0});if(Ext.supports.touchScroll===1){a.initXStyle();a.initYStyle()}},showIndicators:function(){var d=this,a=d.getIndicators(),b,c;if(a){if(d.isAxisEnabled('x')){b=a.x;if(b){b.show()}}if(d.isAxisEnabled('y')){c=a.y;if(c){c.show()}}}},snapToBoundary:function(){var a=this,d=a.getPosition();if(a.isConfiguring||!(d.x||d.y)){return}var f=a.getMinUserPosition(),e=a.getMaxUserPosition(),i=f.x,j=f.y,g=e.x,h=e.y,b=Math.round(d.x),c=Math.round(d.y);if(bg){b=g}}if(ch){c=h}}a.doScrollTo(b,c)},snapToSlot:function(){var a=this,c=a.getSnapPosition('x'),d=a.getSnapPosition('y'),b=a.getSlotSnapEasing();if(c!==null||d!==null){a.doScrollTo(c,d,{easingX:b.x,easingY:b.y});return !0}return !1},stopAnimation:function(){this.getTranslatable().stopAnimation()},toggleResizeListeners:function(e){var c=this,f=c.getElement(),b,a,d;if(f){d=c.getInnerElement();if(e){b=a='on'}else {if(e===null){b='on';a='un'}else {b=a='un'}}f[b]('resize','onElementResize',c);d[a]('resize','onInnerElementResize',c)}},unwrapContent:function(){var a=this.getInnerElement().dom,c=this.getElement().dom,b;while(b=a.firstChild){c.insertBefore(b,a)}},wrapContent:function(d){var a=document.createElement('div'),c=d.dom,b;while(b=c.lastChild){a.insertBefore(b,a.firstChild)}c.appendChild(a);this.setInnerElement(a);this._isWrapped=!0;return this.getInnerElement()}}},1,0,0,0,['scroller.touch'],0,[Ext.scroll,'TouchScroller'],0);Ext.cmd.derive('Ext.scroll.DomScroller',Ext.scroll.Scroller,{isDomScroller:!0,getMaxPosition:function(){var b=this.getElement(),c=0,d=0,a;if(b&&!b.destroyed){a=b.dom;c=a.scrollWidth-a.clientWidth;d=a.scrollHeight-a.clientHeight}return {x:c,y:d}},getMaxUserPosition:function(){var c=this,b=c.getElement(),d=0,e=0,a;if(b&&!b.destroyed){a=b.dom;if(c.getX()){d=a.scrollWidth-a.clientWidth}if(c.getY()){e=a.scrollHeight-a.clientHeight}}return {x:d,y:e}},getPosition:function(){var a=this;if(a.positionDirty){a.updateDomScrollPosition()}return a.position},getSize:function(){var a=this.getElement(),b,c;if(a&&!a.destroyed){c=a.dom;b={x:c.scrollWidth,y:c.scrollHeight}}else {b={x:0,y:0}}return b},updateElement:function(b,a){this.initXStyle();this.initYStyle()},updateX:function(a){this.initXStyle()},updateY:function(a){this.initYStyle()},privates:{doScrollTo:function(a,b,j){var e=this,d=e.getElement(),f,c,i,g,h,k;if(d&&!d.destroyed){c=d.dom;g=a===Infinity;h=b===Infinity;if(g||h){f=e.getMaxPosition();if(g){a=f.x}if(h){b=f.y}}a=e.convertX(a);if(j){i={};if(b!=null){i.scrollTop=b}if(a!=null){i.scrollLeft=a}d.animate(Ext.mergeIf({to:{scrollTop:b,scrollLeft:a}},j))}else {if(b!=null){c.scrollTop=b}if(a!=null){c.scrollLeft=a;if(Ext.isIE8){k=c.scrollLeft;c.scrollLeft=a}}}e.positionDirty=!0}},getElementScroll:function(a){return a.getScroll()},stopAnimation:function(){var a=this.getElement().getActiveAnimation();if(a){a.end()}}}},0,0,0,0,['scroller.dom'],0,[Ext.scroll,'DomScroller'],function(a){Ext.onDocumentReady(function(){a.document=new a({x:!0,y:!0,element:document.body})})});Ext.cmd.derive('Ext.util.Floating',Ext.Base,{mixinId:'floating',focusOnToFront:!0,shadow:'sides',animateShadow:!1,constrain:!1,config:{activeCounter:0,alwaysOnTop:!1},preventDefaultAlign:!1,_visModeMap:{visibility:1,display:2,offsets:3},constructor:function(){var a=this,e=a.el,d=a.shadow,c,b;if(d){b={mode:d===!0?'sides':d};c=a.shadowOffset;if(c){b.offset=c}b.animate=a.animateShadow;b.fixed=a.fixed;e.enableShadow(b,!1)}if(a.shim||Ext.useShims){e.enableShim({fixed:a.fixed},!1)}e.setVisibilityMode(a._visModeMap[a.hideMode]);a.el.on({mousedown:a.onMouseDown,scope:a,capture:!0});a.registerWithOwnerCt();a.initHierarchyEvents()},alignTo:function(b,d,f,e){var a=this,c;Ext.un('scroll',a.onAlignToScroll,a);if(b.isComponent){c=b.el}else {if(b.nodeType){c=Ext.fly(b)}else {c=b}}if(!c.contains(a.el)){Ext.on('scroll',a.onAlignToScroll,a)}a._lastAlignTarget=b;a._lastAlignToPos=d;a.mixins.positionable.alignTo.call(a,c,d,f,e)},initFloatConstrain:function(){var a=this,b=a.floatParent;if((a.constrain||a.constrainHeader)&&!a.constrainTo){a.constrainTo=b?b.getTargetEl():a.container}},initHierarchyEvents:function(){var b=this,a=this.syncHidden;if(!b.hasHierarchyEventListeners){b.mon(Ext.GlobalEvents,{hide:a,collapse:a,show:a,expand:a,added:a,scope:b});b.hasHierarchyEventListeners=!0}},registerWithOwnerCt:function(){var a=this,c=a.ownerCt,b=a.zIndexParent;if(b){b.unregisterFloatingItem(a)}b=a.zIndexParent=a.up('[floating]');a.floatParent=c||b;a.initFloatConstrain();delete a.ownerCt;if(b){b.registerFloatingItem(a)}else {Ext.WindowManager.register(a)}},onMouseDown:function(g){var b=this,f=b.focusTask,c=g.pointerType==='touch',a,d,e;if(b.floating&&(!f||!f.id)){a=g.target;d=b.el.dom;while(!c&&a&&a!==d){if(Ext.fly(a).isFocusable()){c=!0}a=a.parentNode}e=Ext.WindowManager.getActive()===b&&(a===d||c);if(!e){b.toFront(c)}}},onBeforeFloatLayout:function(){this.el.preventSync=!0},onAfterFloatLayout:function(){var a=this.el;if(a.shadow||a.shim){a.setUnderlaysVisible(!0);a.syncUnderlays()}},syncHidden:function(){var a=this,d=a.hidden||!a.rendered,c=a.hierarchicallyHidden=a.isHierarchicallyHidden(),b=a.pendingShow;if(d!==c){if(c){a.hide();a.pendingShow=!0}else {if(b){delete a.pendingShow;if(b.length){a.show.apply(a,b)}else {a.show()}}}}},setZIndex:function(a){var b=this;b.el.setZIndex(a);a+=10;if(b.floatingDescendants){a=Math.floor(b.floatingDescendants.setBase(a)/100)*100+10000}return a},doConstrain:function(c){var a=this,b=a.calculateConstrainedPosition(c,null,!0);if(b){a.setPosition(b)}},updateActiveCounter:function(b){var a=this.zIndexParent;if(a&&this.bringParentToFront!==!1){a.setActiveCounter(++Ext.ZIndexManager.activeCounter)}a=this.zIndexManager;if(a){a.onComponentUpdate(this)}},updateAlwaysOnTop:function(b){var a=this.zIndexManager;if(a){a.onComponentUpdate(this)}},toFront:function(b){var a=this;if(a.zIndexManager.bringToFront(a,b||!a.focusOnToFront)){if(a.hasListeners.tofront){a.fireEvent('tofront',a,a.el.getZIndex())}}return a},setActive:function(d,c){var a=this,b;if(d){if(a.el.shadow&&!a.maximized){a.el.enableShadow(null,!0)}if(c){b=Ext.ComponentManager.getActiveComponent();if(!b||!b.up(a)){a.focus()}}a.fireEvent('activate',a)}else {a.fireEvent('deactivate',a)}},toBack:function(){this.zIndexManager.sendToBack(this);return this},center:function(){var a=this,b;if(a.isVisible()){b=a.getAlignToXY(a.container,'c-c');a.setPagePosition(b)}else {a.needsCenter=!0}return a},onFloatShow:function(){if(this.needsCenter){this.center()}delete this.needsCenter;if(this.toFrontOnShow){this.toFront()}},fitContainer:function(f){var d=this,c=d.floatParent,a=c?c.getTargetEl():d.container,b=a.getViewSize(),e=c||a.dom!==document.body?[0,0]:a.getXY();b.x=e[0];b.y=e[1];d.setBox(b,f)},privates:{onFloatDestroy:function(){this.clearAlignEl()},clearAlignEl:function(){var a=this;if(a._lastAlignTarget){Ext.un('scroll',a.onAlignToScroll,a);a._lastAlignPos=a._lastAlignTarget=null}},onAlignToScroll:function(e){var b=this,a=b._lastAlignTarget,f=a.isFloating,c,d;if(a){if(a.isComponent){c=a.destroyed;a=a.el}else {if(a.nodeType){a=Ext.fly(a)}d=a.dom;c=!d||Ext.isGarbage(d)}if(c){b.clearAlignEl()}else {if((e.getElement().contains(a)||f)&&!e.getElement().contains(b.el)){b.alignTo(a,b._lastAlignToPos)}}}}}},1,0,0,0,0,0,[Ext.util,'Floating'],0);Ext.cmd.derive('Ext.util.ElementContainer',Ext.Base,{mixinId:'elementCt',config:{childEls:{$value:{},cached:!0,lazy:!0,merge:function(d,f,g,e){var c=f?Ext.Object.chain(f):{},b,a;if(d instanceof Array){for(b=d.length;b--;){a=d[b];if(!e||!(a in c)){if(typeof a==='string'){c[a]={name:a,itemId:a}}else {c[a.name]=a}}}}else {if(d){if(d.constructor===Object){for(b in d){if(!e||!(b in c)){a=d[b];if(a===!0){c[b]={itemId:b}}else {if(typeof a==='string'){c[b]={itemId:a}}else {c[b]=a;if(!('itemId' in a)){a.itemId=b}}}c[b].name=b}}}else {if(!e||!(d in c)){c[d]={name:d,itemId:d}}}}}return c}}},destroy:function(){var c=this,d=c.getChildEls(),a,b;for(b in d){a=c[b];if(a){if(a.destroy){a.component=null;a.destroy()}c[b]=null}}},privates:{addChildEl:function(a){var c=this,b=c.getChildEls();if(!c.hasOwnProperty('childEls')){c.childEls=b=Ext.Object.chain(b)}if(typeof a==='string'){a={name:a,itemId:a}}b[a.name]=a},afterClassMixedIn:function(a){var c=a.prototype,b=c.childEls;if(b){delete c.childEls;a.getConfigurator().add({childEls:b})}},attachChildEls:function(h,n){var i=this,k=i.getChildEls(),e=n||i,m=e.id+'-',l=!e.frame,f,g,b,j,c,a,d;for(f in k){b=k[f];if(l&&b.frame){continue}c=b.select;if(c){a=h.select(c,!0)}else {if(!(c=b.selectNode)){if(!(d=b.id)){d=m+b.itemId;a=Ext.cache[d]}else {a=Ext.cache[d]||h.getById(d)}}else {a=h.selectNode(c,!1)}}if(a){if(a.isElement){a.component=e}else {if(a.isComposite&&!a.isLite){g=a.elements;for(j=g.length;j--;){g[j].component=e}}}}i[f]=a||null}}}},0,0,0,0,0,0,[Ext.util,'ElementContainer'],0);Ext.cmd.derive('Ext.util.Renderable',Ext.Base,{mixinId:'renderable',frameCls:'x-frame',frameIdRegex:/[\-]frame\d+[TMB][LCR]$/,frameElNames:['TL','TC','TR','ML','MC','MR','BL','BC','BR','Table'],frameTpl:['{%this.renderDockedItems(out,values,0);%}','','
{parent.baseCls}-{parent.ui}-{.}-tl{frameElCls}" role="presentation">','
{parent.baseCls}-{parent.ui}-{.}-tr{frameElCls}" role="presentation">','
{parent.baseCls}-{parent.ui}-{.}-tc{frameElCls}" role="presentation">
','
','
','
','
{parent.baseCls}-{parent.ui}-{.}-ml{frameElCls}" role="presentation">','
{parent.baseCls}-{parent.ui}-{.}-mr{frameElCls}" role="presentation">','
{parent.baseCls}-{parent.ui}-{.}-mc{frameElCls}" role="presentation">','{%this.applyRenderTpl(out, values)%}','
','
','
','','
{parent.baseCls}-{parent.ui}-{.}-bl{frameElCls}" role="presentation">','
{parent.baseCls}-{parent.ui}-{.}-br{frameElCls}" role="presentation">','
{parent.baseCls}-{parent.ui}-{.}-bc{frameElCls}" role="presentation">
','
','
','
','{%this.renderDockedItems(out,values,1);%}'],frameTableTpl:['{%this.renderDockedItems(out,values,0);%}','','','','','','','','','','','','','','','','','','','','','','{%this.renderDockedItems(out,values,1);%}'],_renderState:0,ariaEl:'el',_layerCls:'x-layer',_fixedLayerCls:'x-fixed-layer',ariaStaticRoles:{presentation:!0,article:!0,definition:!0,directory:!0,document:!0,img:!0,heading:!0,math:!0,note:!0,banner:!0,complementary:!0,contentinfo:!0,navigation:!0,search:!0,'undefined':!0,'null':!0},statics:{makeRenderSetter:function(c,b){var a=c.name;return function(g){var d=this,f=d.renderConfigs||(d.renderConfigs={}),e=f[b];if(d._renderState>=b){(c.setter||c.getSetter()).call(d,g)}else {if(!e){f[b]=e={}}if(!(a in e)){e[a]=d[a]}d[a]=g}return d}},processRenderConfig:function(g,e,c){var h=this.prototype,j=this.getConfigurator(),k=Ext.util.Renderable,l=k.makeRenderSetter,d=g[e],b,a,i,f;for(i in d){a=Ext.Config.get(i);if(!h[f=a.names.set]){b=a.renderSetter||(a.renderSetter={});h[f]=b[c]||(b[c]=l(a,c))}}delete g[e];j.add(d)}},onClassMixedIn:function(a){var e=a.override,c=this.processRenderConfig,d=function(b){if(b.beforeRenderConfig){this.processRenderConfig(b,'beforeRenderConfig',1)}if(b.renderConfig){this.processRenderConfig(b,'renderConfig',3)}e.call(this,b)},b=function(e,b){e.override=d;e.processRenderConfig=c;if(b.beforeRenderConfig){e.processRenderConfig(b,'beforeRenderConfig',1)}if(b.renderConfig){e.processRenderConfig(b,'renderConfig',3)}};b(a,a.prototype);a.onExtended(b)},afterRender:function(){var a=this,c={},i=a.protoEl,g=a.el,d,b,h,f,e;a.finishRenderChildren();a._renderState=4;if(a.contentEl){h='x-';f=h+'hidden-';e=a.contentEl=Ext.get(a.contentEl);e.component=a;e.removeCls([h+'hidden',f+'display',f+'offsets']);a.getContentTarget().appendChild(e.dom)}i.writeTo(c);b=c.removed;if(b){g.removeCls(b)}b=c.cls;if(b.length){g.addCls(b)}b=c.style;if(c.style){g.setStyle(b)}a.protoEl=null;if(!a.ownerCt&&!a.skipLayout){a.updateLayout()}if(!(a.x&&a.y)&&(a.pageX||a.pageY)){a.setPagePosition(a.pageX,a.pageY)}if(a.disableOnRender){a.onDisable()}d=a.controller;if(d&&d.afterRender){d.afterRender(a)}},afterFirstLayout:function(l,k){var a=this,g=a.x,h=a.y,j=a.defaultAlign,i=a.alignOffset,f,d,e,b,c;if(!a.ownerLayout){d=g!==undefined;e=h!==undefined}if(a.floating&&!a.preventDefaultAlign&&(!d||!e)){if(a.floatParent){b=a.floatParent.getTargetEl().getViewRegion();c=a.el.getAlignToXY(a.alignTarget||a.floatParent.getTargetEl(),j,i);b.x=c[0]-b.x;b.y=c[1]-b.y}else {c=a.el.getAlignToXY(a.alignTarget||a.container,j,i);b=a.el.translateXY(c[0],c[1])}g=d?g:b.x;h=e?h:b.y;d=e=!0}if(d||e){a.setPosition(g,h)}a.onBoxReady(l,k);f=a.controller;if(f&&f.boxReady){f.boxReady(a)}},beforeRender:function(){var a=this,d=a.floating,e=a.getComponentLayout(),b=a.userCls,c;a._renderState=1;a.ariaUsesMainElement=a.ariaEl==='el';c=a.controller;if(c&&c.beforeRender){c.beforeRender(a)}a.initBindable();if(a.renderConfigs){a.flushRenderConfigs()}if(a.reference){a.publishState()}if(b){a.addCls(b)}if(d){a.addCls(a.fixed?a._fixedLayerCls:a._layerCls);b=d.cls;if(b){a.addCls(b)}}a.frame=a.frame||a.alwaysFramed;if(!e.initialized){e.initLayout()}a.initOverflow();a.setUI(a.ui)},doApplyRenderTpl:function(d,a){var c=a.$comp,b;if(!c.rendered){b=c.initRenderTpl();b.applyOut(a.renderData,d)}},getElConfig:function(){var a=this,e=a.autoEl,c=a.getFrameInfo(),b={tag:'div',tpl:c?a.initFramingTpl(c.table):a.initRenderTpl()},g=a.layoutTargetCls,d=a.protoEl,f=a.ariaRole,h;a.initStyles(d);if(g&&!c){d.addCls(g)}d.writeTo(b);d.flush();if(e){if(Ext.isString(e)){b.tag=e}else {Ext.apply(b,e)}}if(f&&a.ariaUsesMainElement){b.role=f;if(!a.ariaStaticRoles[f]){b['aria-hidden']=!!a.hidden;b['aria-disabled']=!!a.disabled;if(a.ariaLabel&&!a.ariaLabelledBy){b['aria-label']=a.ariaLabel}if(a.collapsible){b['aria-expanded']=!a.collapsed}if(a.ariaRenderAttributes){Ext.apply(b,a.ariaRenderAttributes)}if(a.config.ariaAttributes){Ext.apply(b,a.getAriaAttributes())}}}b.id=a.id;if(b.tpl){if(c){b.tplData=h=a.getFrameRenderData();h.renderData=a.initRenderData()}else {b.tplData=a.initRenderData()}}a.ariaRenderAttributes=null;return b},getInsertPosition:function(a){if(a!==undefined){if(Ext.isNumber(a)){a=this.container.dom.childNodes[a]}else {a=Ext.getDom(a)}}return a},getRenderTree:function(){var a=this,b=null;if(!a.hasListeners.beforerender||a.fireEvent('beforerender',a)!==!1){a._renderState=1;a.beforeRender();a.rendering=!0;a._renderState=2;b=a.getElConfig();if(a.el){b.id=a.$pid=Ext.id(null,a.el.identifiablePrefix)}}return b},initRenderData:function(){var a=this,c=a.ariaRole,d,b;d=Ext.apply({$comp:a,id:a.id,ui:a.ui,uiCls:a.uiCls,baseCls:a.baseCls,componentCls:a.componentCls,frame:a.frame,renderScroller:a.touchScroll,scrollerCls:a.scrollerCls,childElCls:''},a.renderData);if(c&&!a.ariaUsesMainElement){b={role:c};if(!a.ariaStaticRoles[c]){b['aria-hidden']=!!a.hidden;b['aria-disabled']=!!a.disabled;if(a.ariaLabel&&!a.ariaLabelledBy){b['aria-label']=a.ariaLabel}if(a.collapsible){b['aria-expanded']=!a.collapsed}if(a.ariaRenderAttributes){Ext.apply(b,a.ariaRenderAttributes)}if(a.config.ariaAttributes){Ext.apply(b,a.getAriaAttributes())}}d.ariaAttributes=b}return d},onRender:function(i,h){var a=this,e=a.x,f=a.y,b=null,g=a.el,d,c;a.applyRenderSelectors();a.rendering=null;a.rendered=!0;a._renderState=3;if(a.renderConfigs){a.flushRenderConfigs()}if(e!=null){b={x:e}}if(f!=null){(b=b||{}).y=f}if(!a.getFrameInfo()){d=a.width;c=a.height;if(typeof d==='number'){b=b||{};b.width=d}if(typeof c==='number'){b=b||{};b.height=c}}if(a.touchScroll===1){a.getOverflowEl().disableTouchScroll()}a.lastBox=g.lastBox=b},render:function(c,g){var a=this,b=a.el,f=a.ownerLayout,h,d,e;if(b&&!b.isElement){a.wrapPrimaryEl(b);b=a.el}if(!a.skipLayout){Ext.suspendLayouts()}c=a.initContainer(c);e=a.getInsertPosition(g);if(!b){d=a.getRenderTree();if(f&&f.transformItemRenderTree){d=f.transformItemRenderTree(d)}if(d){if(e){b=Ext.DomHelper.insertBefore(e,d)}else {b=Ext.DomHelper.append(c,d)}a.wrapPrimaryEl(b);a.cacheRefEls(b)}}else {if(!a.hasListeners.beforerender||a.fireEvent('beforerender',a)!==!1){a.beforeRender();a.needsRenderTpl=a.rendering=!0;a._renderState=2;a.initStyles(b);if(a.allowDomMove!==!1){if(e){c.dom.insertBefore(b.dom,e)}else {c.dom.appendChild(b.dom)}}}else {h=!0}}if(b&&!h){a.finishRender(g)}if(!a.skipLayout){Ext.resumeLayouts(!a.hidden&&!c.isDetachedBody)}},ensureAttachedToBody:function(c){var a=this,b;while(a.ownerCt){a=a.ownerCt}if(a.container.isDetachedBody){a.container=b=Ext.getBody();b.appendChild(a.el.dom);if(c){a.updateLayout()}if(typeof a.x==='number'||typeof a.y==='number'){a.setPosition(a.x,a.y)}}},privates:{applyRenderSelectors:function(){var a=this,b=a.renderSelectors,e=a.el,d,c;a.attachChildEls(e);a.ariaEl=a[a.ariaEl]||a.el;if(b){for(c in b){d=b[c];if(d){a[c]=e.selectNode(d,!1)}}}},cacheRefEls:function(a){a=a||this.el;var e=Ext.cache,h=Ext.dom.Element,f=a.isElement?a.dom:a,d=f.querySelectorAll('[data-ref]'),g=d.length,c,b;for(b=0;b','
','','{%this.renderContent(out,values)%}','
'],resizeHandles:'all',shrinkWrap:2,toFrontOnShow:!0,synthetic:!1,tplWriteMode:'overwrite',ui:'default',uiCls:[],userCls:null,weight:null,allowDomMove:!0,autoGenId:!1,borderBoxCls:'x-border-box',componentLayoutCounter:0,contentPaddingProperty:'padding',deferLayouts:!1,frameSize:null,horizontalPosProp:'left',isComponent:!0,_isLayoutRoot:!1,layoutSuspendCount:0,liquidLayout:!1,maskOnDisable:!0,offsetsCls:'x-hidden-offsets',rendered:!1,rootCls:'x-body',scrollerCls:'x-scroll-scroller',scrollerSelector:'.x-scroll-scroller',_scrollFlags:{auto:{auto:{overflowX:'auto',overflowY:'auto',x:!0,y:!0,both:!0},'false':{overflowX:'auto',overflowY:'hidden',x:!0,y:!1,both:!1},scroll:{overflowX:'auto',overflowY:'scroll',x:!0,y:!0,both:!0}},'false':{auto:{overflowX:'hidden',overflowY:'auto',x:!1,y:!0,both:!1},'false':{overflowX:'hidden',overflowY:'hidden',x:!1,y:!1,both:!1},scroll:{overflowX:'hidden',overflowY:'scroll',x:!1,y:!0,both:!1}},scroll:{auto:{overflowX:'scroll',overflowY:'auto',x:!0,y:!0,both:!0},'false':{overflowX:'scroll',overflowY:'hidden',x:!0,y:!1,both:!1},scroll:{overflowX:'scroll',overflowY:'scroll',x:!0,y:!0,both:!0}},none:{overflowX:'',overflowY:'',x:!1,y:!1,both:!1}},_scrollableCfg:{x:{x:!0,y:!1},y:{x:!1,y:!0},horizontal:{x:!0,y:!1},vertical:{x:!1,y:!0},both:{x:!0,y:!0},'true':{x:!0,y:!0}},validIdRe:Ext.validIdRe,constructor:function(b){var a=this,e,j,i,h,g,c,d,f;b=b||{};if(b.initialConfig){if(b.isAction){a.baseAction=b}b=b.initialConfig}else {if(b.tagName||b.dom||Ext.isString(b)){b={applyTo:b,id:b.id||b}}}a.initialConfig=b;a.getId();a.protoEl=new Ext.util.ProtoElement();a.initConfig(b);if(a.scrollable==null){g=a.autoScroll;if(g){f=!!g}else {c=a.overflowX;d=a.overflowY;if(c||d){f={x:c&&c!=='hidden'?c:!1,y:d&&d!=='hidden'?d:!1}}}if(f){a.setScrollable(f)}}i=a.xhooks;if(i){delete a.xhooks;Ext.override(a,i)}a.mixins.elementCt.constructor.call(a);a.setupProtoEl();if(a.cls){a.initialCls=a.cls;a.protoEl.addCls(a.cls)}if(a.style){a.initialStyle=a.style;a.protoEl.setStyle(a.style)}a.renderData=a.renderData||{};a.initComponent();if(!a.preventRegister){Ext.ComponentManager.register(a)}a.mixins.state.constructor.call(a);a.addStateEvents('resize');h=a.getController();if(h){h.init(a)}if(a.plugins){for(e=0,j=a.plugins.length;eh){o=j;f=!0}if(e&&k>i){p=k;f=!0}if(d||e){g=a.el.getStyle('overflow');if(g!=='hidden'){a.el.setStyle('overflow','hidden')}}if(f){r=!Ext.isNumber(a.width);q=!Ext.isNumber(a.height);a.setSize(p,o);a.el.setSize(i,h);if(r){delete a.width}if(q){delete a.height}}if(e){c.width=k}if(d){c.height=j}}n=a.constrain;l=a.constrainHeader;if(n||l){a.constrain=a.constrainHeader=!1;m=b.callback;b.callback=function(){a.constrain=n;a.constrainHeader=l;if(m){m.call(b.scope||a,arguments)}if(g!=='hidden'){a.el.setStyle('overflow',g)}}}return a.mixins.animate.animate.apply(a,arguments)},applyScrollable:function(a,c){var b=this,f=b.rendered,e,d;if(a){if(a===!0||typeof a==='string'){e=b._scrollableCfg[a];a=e}if(c){c.setConfig(a);a=c}else {a=Ext.Object.chain(a);if(f){a.element=b.getOverflowEl();d=b.getScrollerEl();if(d){a.innerElement=d}}a.autoRefresh=!1;if(Ext.supports.touchScroll===1){a.translatable={translationMethod:'scrollparent'};a.indicators=!1}a=Ext.scroll.Scroller.create(a);a.component=b}}else {if(c){c.setConfig({x:!1,y:!1});c.destroy();a=null}}if(b.rendered&&!b.destroying&&!b.destroyed){if(a){b.getOverflowStyle()}else {b.scrollFlags=b._scrollFlags.none}b.updateLayout()}return a},beforeComponentLayout:function(){return !0},beforeDestroy:Ext.emptyFn,beforeLayout:function(){if(this.floating){this.onBeforeFloatLayout()}},beforeSetPosition:function(a,b,f){var d=this,c=null,e,g,h,i;if(a){if(Ext.isNumber(e=a[0])){f=b;b=a[1];a=e}else {if((e=a.x)!==undefined){f=b;b=a.y;a=e}}}if(d.constrain||d.constrainHeader){c=d.calculateConstrainedPosition(null,[a,b],!0);if(c){a=c[0];b=c[1]}}g=a!==undefined;h=b!==undefined;if(g||h){d.x=a;d.y=b;i=d.adjustPosition(a,b);c={x:i.x,y:i.y,anim:f,hasX:g,hasY:h}}return c},beforeShow:Ext.emptyFn,bubble:function(d,b,c){var a=this;while(a){if(d.apply(b||a,c||[a])===!1){break}a=a.getBubbleTarget()}return this},clearListeners:function(){var a=this;a.mixins.observable.clearListeners.call(a);a.mixins.componentDelegation.clearDelegatedListeners.call(a)},cloneConfig:function(a){a=a||{};var d=a.id||Ext.id(),c=Ext.applyIf(a,this.initialConfig),b;c.id=d;b=Ext.getClass(this);return new b(c)},destroy:function(){var a=this,d=a.renderSelectors,f=a.getConfig('viewModel',!0),g=a.getConfig('session',!0),b,c,e;if(!a.hasListeners.beforedestroy||a.fireEvent('beforedestroy',a)!==!1){a.isDestroying=a.destroying=!0;c=a.floatParent||a.ownerCt;if(a.floating){delete a.floatParent;if(a.zIndexManager){a.zIndexManager.unregister(a);a.zIndexManager=null}}a.removeBindings();a.beforeDestroy();a.destroyBindable();if(c&&c.remove){c.remove(a,!1)}a.stopAnimation();a.onDestroy();Ext.destroy(a.plugins);if(a.rendered){Ext.Component.cancelLayout(a,!0)}a.componentLayout=null;if(a.hasListeners.destroy){a.fireEvent('destroy',a)}if(!a.preventRegister){Ext.ComponentManager.unregister(a)}a.mixins.state.destroy.call(a);if(a.floating){a.onFloatDestroy()}a.clearListeners();if(a.rendered){if(!a.preserveElOnDestroy){a.el.destroy()}a.el.component=null;a.mixins.elementCt.destroy.call(a);if(d){for(b in d){if(d.hasOwnProperty(b)){e=a[b];if(e){delete a[b];e.destroy()}}}}a.data=a.el=a.frameBody=a.rendered=a.afterRenderEvents=null;a.tpl=a.renderTpl=a.renderData=null;a.focusableContainer=a.container=a.scrollable=null}a.isDestroying=a.destroying=!1;a.callParent()}},disable:function(e,d){var a=this,b=a.focusableContainer,c=a.getInherited();if(!d){c.disabled=!0;a.savedDisabled=!0}if(a.maskOnDisable){c.disableMask=!0}if(!a.disabled){if(b){b.beforeFocusableChildDisable(a)}a.addCls(a.disabledCls);if(a.rendered){a.onDisable()}else {a.disableOnRender=!0}a.disabled=!0;if(e!==!0){a.fireEvent('disable',a)}if(b){b.onFocusableChildDisable(a)}}return a},doFireEvent:function(c,d,e){var a=this,b=a.mixins.observable.doFireEvent.call(a,c,d,e);if(b!==!1){b=a.mixins.componentDelegation.doFireDelegatedEvent.call(a,c,d)}return b},enable:function(e,c){var a=this,b=a.focusableContainer,d=a.getInherited();if(!c){delete a.getInherited().disabled;a.savedDisabled=!1}if(a.maskOnDisable){delete d.disableMask}if(a.disabled){if(!(c&&d.hasOwnProperty('disabled'))){if(b){b.beforeFocusableChildEnable(a)}a.disableOnRender=!1;a.removeCls(a.disabledCls);if(a.rendered){a.onEnable()}a.disabled=!1;if(e!==!0){a.fireEvent('enable',a)}if(b){b.onFocusableChildEnable(a)}}}return a},findParentBy:function(b){var a;for(a=this.getRefOwner();a&&!b(a,this);a=a.getRefOwner()){}return a||null},findParentByType:function(a){return Ext.isFunction(a)?this.findParentBy(function(b){return b.constructor===a}):this.up(a)},findPlugin:function(c){var a,b=this.plugins,d=b&&b.length;for(a=0;a-1;e--){b=g[e];if(b.query){a=b.query(c);a=a[a.length-1];if(a){return a}}if(b.is(c)){return b}}return f.previousNode(c,!0)}return null},previousSibling:function(c){var e=this.ownerCt,b,a,d;if(e){b=e.items;a=b.indexOf(this);if(a!==-1){if(c){for(--a;a>=0;a--){if((d=b.getAt(a)).is(c)){return d}}}else {if(a){return b.getAt(--a)}}}}return null},registerFloatingItem:function(b){var a=this;if(!a.floatingDescendants){a.floatingDescendants=new Ext.ZIndexManager(a)}a.floatingDescendants.register(b)},removeCls:function(c){var a=this,b=a.rendered?a.el:a.protoEl;b.removeCls.apply(b,arguments);return a},removeClsWithUI:function(a,k){var b=this,d=[],e=0,g=Ext.Array,i=g.remove,j=b.uiCls=g.clone(b.uiCls),f=b.activeUI,h,c;if(typeof a==='string'){a=a.indexOf(' ')<0?[a]:Ext.String.splitWords(a)}h=a.length;for(e=0;e1){arguments[0]=null;a.pendingShow=arguments}else {a.pendingShow=!0}}else {if(b&&a.isVisible()){if(a.floating){a.onFloatShow()}}else {if(a.fireEvent('beforeshow',a)!==!1){a.hidden=!1;delete this.getInherited().hidden;Ext.suspendLayouts();if(!b&&(a.autoRender||a.floating)){a.doAutoRender();b=a.rendered}if(b){a.beforeShow();Ext.resumeLayouts();a.onShow.apply(a,arguments);a.afterShow.apply(a,arguments)}else {Ext.resumeLayouts(!0)}}else {a.onShowVeto()}}}return a},showAt:function(b,c,d){var a=this;if(!a.rendered&&(a.autoRender||a.floating)){a.x=b;a.y=c;return a.show()}if(a.floating){a.setPosition(b,c,d)}else {a.setPagePosition(b,c,d)}return a.show()},showBy:function(b,d,c){var a=this;if(a.floating&&b){a.alignTarget=b;if(d){a.defaultAlign=d}if(c){a.alignOffset=c}a.show();if(!a.hidden){a.alignTo(b,d||a.defaultAlign,c||a.alignOffset)}}return a},suspendLayouts:function(){var a=this;if(!a.rendered){return}if(++a.layoutSuspendCount===1){a.suspendLayout=!0}},unitizeBox:function(a){return Ext.Element.unitizeBox(a)},unmask:function(){(this.getMaskTarget()||this.el).unmask();this.setMasked(!1)},unregisterFloatingItem:function(b){var a=this;if(a.floatingDescendants){a.floatingDescendants.unregister(b)}},up:function(c,b){var a=this.getRefOwner(),f=typeof b==='string',g=typeof b==='number',e=b&&b.isComponent,d=0;if(c){for(;a;a=a.getRefOwner()){d++;if(c.isComponent){if(a===c){return a}}else {if(Ext.ComponentQuery.is(a,c)){return a}}if(f&&a.is(b)){return}if(g&&d===b){return}if(e&&a===b){return}}}return a},update:function(b,i,k,j){var a=this,h=a.tpl&&!Ext.isString(b),g=a.getScrollable(),f=a.focusableContainer,e,c,d;if(h){a.data=b&&b.isEntity?b.getData(!0):b}else {a.html=Ext.isObject(b)?Ext.DomHelper.markup(b):b}if(a.rendered){e=a.getSizeModel();c=e.width.shrinkWrap||e.height.shrinkWrap;if(a.isContainer){d=a.layout.getRenderTarget();c=c||a.items.items.length>0}else {d=a.touchScroll?a.getScrollerEl():a.getTargetEl()}if(h){a.tpl[a.tplWriteMode](d,a.data||{})}else {d.setHtml(a.html,i,k,j||a)}if(c){a.updateLayout()}if(g){g.refresh(!0)}if(f){f.onFocusableChildUpdate(a)}}},setHtml:function(c,a,b){this.update(c,a,null,b)},applyData:function(a){this.update(a)},updateBox:function(a){this.setSize(a.width,a.height);this.setPagePosition(a.x,a.y);return this},_asLayoutRoot:{isRoot:!0},_notAsLayoutRoot:{isRoot:!1},updateLayout:function(b){var a=this,e,d=a.lastBox,c=b&&b.isRoot;if(d){d.invalid=!0}if(!a.rendered||a.layoutSuspendCount||a.suspendLayout){return}if(a.hidden){Ext.Component.cancelLayout(a)}else {if(typeof c!=='boolean'){c=a.isLayoutRoot()}}if(c||!a.ownerLayout||!a.ownerLayout.onContentChange(a)){if(!a.isLayoutSuspended()){e=b&&b.hasOwnProperty('defer')?b.defer:a.deferLayouts;Ext.Component.updateLayout(a,e)}}},updateMaxHeight:function(b,a){this.changeConstraint(b,a,'min','max-height','height')},updateMaxWidth:function(b,a){this.changeConstraint(b,a,'min','max-width','width')},updateMinHeight:function(b,a){this.changeConstraint(b,a,'max','min-height','height')},updateMinWidth:function(b,a){this.changeConstraint(b,a,'max','min-width','width')},getAnchorToXY:function(d,a,c,b){return d.getAnchorXY(a,c,b)},getBorderPadding:function(){return this.el.getBorderPadding()},getLocalX:function(){return this.el.getLocalX()},getLocalXY:function(){return this.el.getLocalXY()},getLocalY:function(){return this.el.getLocalY()},getX:function(){return this.el.getX()},getXY:function(){return this.el.getXY()},getY:function(){return this.el.getY()},setLocalX:function(a){this.el.setLocalX(a)},setLocalXY:function(a,b){this.el.setLocalXY(a,b)},setLocalY:function(a){this.el.setLocalY(a)},setX:function(b,a){this.el.setX(b,a)},setXY:function(b,a){this.el.setXY(b,a)},setY:function(b,a){this.el.setY(b,a)},privates:{addOverCls:function(){var a=this;if(!a.disabled){a.el.addCls(a.overCls)}},addUIToElement:function(){var a=this,d=a.baseCls+'-'+a.ui,e,c,f,b;a.addCls(d);if(a.rendered&&a.frame&&!Ext.supports.CSS3BorderRadius){d+='-';e=a.getChildEls();for(c in e){b=e[c].frame;if(b&&b!==!0){f=a[c];if(f){f.addCls(d+b)}}}}},changeConstraint:function(b,g,f,c,d){var a=this,e=a[d];if(b!=null&&typeof e==='number'){a[d]=Math[f](e,b)}if(a.liquidLayout){if(b!=null){a.setStyle(c,b+'px')}else {if(g){a.setStyle(c,'')}}}if(a.rendered){a.updateLayout()}},constructPlugin:function(a){var b=this;if(typeof a==='string'){a=Ext.PluginManager.create({},a,b)}else {a=Ext.PluginManager.create(a,null,b)}return a},constructPlugins:function(){var d=this,a=d.plugins,c,b,e;if(a){c=[];c.processed=!0;if(!Ext.isArray(a)){a=[a]}for(b=0,e=a.length;b=0){h=m[c].splitterDelta;if(e.getAt(d+h)!==b){e.remove(b);d=e.indexOf(a);if(h>0){++d}e.insert(d,b)}}}if(j){if(l){a.expand(!1)}i.remove(j);a.placeholder=null;if(l){a.collapse(null,!1)}}i.updateLayout();Ext.resumeLayouts(!0);a.fireEventArgs('changeregion',[a,g])}else {a.region=c}}return g},setWeight:function(b){var a=this,e=a.getOwningBorderContainer(),d=a.placeholder,c=a.weight;if(b!==c){if(a.fireEventArgs('beforechangeweight',[a,b])!==!1){a.weight=b;if(d){d.weight=b}if(e){e.updateLayout()}a.fireEventArgs('changeweight',[a,c])}}return c}},function(b){var a=b.prototype;a.setBorderRegion=a.setRegion;a.setRegionWeight=a.setWeight});Ext.define('Ext.theme.neptune.Component',{override:'Ext.Component',initComponent:function(){arguments.callee.$previous.call(this);if(this.dock&&this.border===undefined){this.border=!1}},privates:{initStyles:function(){var a=this,b=a.hasOwnProperty('border'),c=a.border;if(a.dock){a.border=null}arguments.callee.$previous.apply(this,arguments);if(b){a.border=c}else {delete a.border}}}},function(){Ext.namespace('Ext.theme.is').Neptune=!0;Ext.theme.name='Neptune'});Ext.define('Ext.theme.crisp.Component',{override:'Ext.Component'},function(){Ext.namespace('Ext.theme.is').Crisp=!0;Ext.theme.name='Crisp'});Ext.define('Ext.overrides.app.domain.Component',{override:'Ext.app.domain.Component'},function(a){a.monitor(Ext.Component)});Ext.cmd.derive('Ext.app.EventBus',Ext.Base,{singleton:!0,constructor:function(){var a=this,b=Ext.app.EventDomain.instances;a.callParent();a.domains=b;a.bus=b.component.bus},control:function(b,a){return this.domains.component.listen(b,a)},listen:function(b,c){var d=this.domains,a;for(a in b){if(b.hasOwnProperty(a)){d[a].listen(b[a],c)}}},unlisten:function(c){var a=Ext.app.EventDomain.instances,b;for(b in a){a[b].unlisten(c)}}},1,0,0,0,0,0,[Ext.app,'EventBus'],0);Ext.cmd.derive('Ext.app.domain.Global',Ext.app.EventDomain,{singleton:!0,type:'global',constructor:function(){var a=this;a.callParent();a.monitor(Ext.GlobalEvents)},listen:function(b,a){this.callParent([{global:b},a])},match:Ext.returnTrue},1,0,0,0,0,0,[Ext.app.domain,'Global'],0);Ext.cmd.derive('Ext.app.BaseController',Ext.Base,{isController:!0,config:{id:null,control:null,listen:null,routes:null,before:null},constructor:function(b){var a=this;Ext.apply(a,b);delete a.control;delete a.listen;a.eventbus=Ext.app.EventBus;a.mixins.observable.constructor.call(a,b);a.ensureId()},applyListen:function(a){if(Ext.isObject(a)){a=Ext.clone(a)}return a},applyControl:function(a){if(Ext.isObject(a)){a=Ext.clone(a)}return a},updateControl:function(a){this.ensureId();if(a){this.control(a)}},updateListen:function(a){this.ensureId();if(a){this.listen(a)}},updateRoutes:function(b){if(b){var e=this,f=e.getBefore()||{},g=Ext.app.route.Router,c,a,d;for(c in b){a=b[c];if(Ext.isString(a)){a={action:a}}d=a.action;if(!a.before){a.before=f[d]}g.connect(c,a,e)}}},isActive:function(){return !0},control:function(b,c,f){var e=this,d=f,a;if(Ext.isString(b)){a={};a[b]=c}else {a=b;d=c}e.eventbus.control(a,d||e)},listen:function(b,a){this.eventbus.listen(b,a||this)},destroy:function(){var a=this,b=a.eventbus;Ext.app.route.Router.disconnectAll(a);if(b){b.unlisten(a);a.eventbus=null}a.callParent()},redirectTo:function(a,c){if(a.isModel){a=a.toUrl()}if(!c){var b=Ext.util.History.getToken();if(b===a){return !1}}else {Ext.app.route.Router.onStateChange(a)}Ext.util.History.add(a);return !0}},1,0,0,0,0,[[Ext.mixin.Observable.prototype.mixinId||Ext.mixin.Observable.$className,Ext.mixin.Observable]],[Ext.app,'BaseController'],0);Ext.cmd.derive('Ext.app.Util',Ext.Base,{},0,0,0,0,0,0,[Ext.app,'Util'],function(){Ext.apply(Ext.app,{namespaces:{Ext:{}},addNamespaces:function(a){var d=Ext.app.namespaces,b,c;if(!Ext.isArray(a)){a=[a]}for(b=0,c=a.length;bb.length&&a+'.'===d.substring(0,a.length+1)){b=a}}return b===''?undefined:b},setupPaths:function(e,b,c){var a=Ext.manifest,d;if(e&&b!==null){a=a&&a.paths;if(!a||b!==undefined){Ext.Loader.setPath(e,b===undefined?'app':b)}}if(c){for(d in c){if(c.hasOwnProperty(d)){Ext.Loader.setPath(d,c[d])}}}}});Ext.getNamespace=Ext.app.getNamespace});Ext.cmd.derive('Ext.util.CollectionKey',Ext.Base,{isCollectionKey:!0,observerPriority:-200,config:{collection:null,keyFn:null,property:null,rootProperty:null,unique:!0},generation:0,map:null,mapRebuilds:0,constructor:function(a){this.initConfig(a)},get:function(a){var b=this.map||this.getMap();return b[a]||null},clear:function(){this.map=null},getRootProperty:function(){var b=this,a=(arguments.callee.$previous||Ext.Base.prototype.getRootProperty).call(this);return a!==null?a:b.getCollection().getRootProperty()},indexOf:function(i,b){var j=this.map||this.getMap(),c=j[i],e=this.getCollection(),h=e.length,d,a,f,g;if(!c){return -1}if(b===undefined){b=-1}if(c instanceof Array){f=c;a=h;for(g=f.length;g-->0;){d=e.indexOf(f[g]);if(db){a=d}}if(a===h){return -1}}else {a=e.indexOf(c)}return a>b?a:-1},updateKey:function(e,d){var f=this,c=f.map,a,b;if(c){a=c[d];if(a instanceof Array){b=Ext.Array.indexOf(a,e);if(b>=0){if(a.length>2){a.splice(b,1)}else {c[d]=a[1-b]}}}else {if(a){delete c[d]}}f.add([e])}},onCollectionAdd:function(b,a){if(this.map){this.add(a.items)}},onCollectionItemChange:function(a,b){this.map=null},onCollectionRefresh:function(){this.map=null},onCollectionRemove:function(g,h){var a=this,f=a.map,d=h.items,c=d.length,b,i,e;if(f){if(a.getUnique()&&cb?1:a0&&a.getAutoSort(),r=a.getSource(),q=0,g=!1,o=!1,e,l,k,m,b,d;if(r&&!r.updating){r.itemChanged(c,p,f,u)}else {l=a.getKey(c);if(s){b=a.indexOfKey(j?f:l);o=b<0;g=a.isItemFiltered(c);n=o!==g}if(n){if(g){q=[c];d=-1}else {m=[c];d=a.length}}else {if(v&&!g){if(!s){b=a.indexOfKey(j?f:l)}k=a.getSortFn();if(b!==-1){if(b&&k(i[b-1],i[b])>0){h=-1;d=Ext.Array.binarySearch(i,c,0,b,k)}else {if(b0){h=1;d=Ext.Array.binarySearch(i,c,b+1,k)}}if(h){m=[c]}}}}e={item:c,key:l,index:d,filterChanged:n,keyChanged:j,indexChanged:!!h,filtered:g,oldIndex:b,newIndex:d,wasFiltered:o,meta:u};if(j){e.oldKey=f}if(p){e.modified=p}a.beginUpdate();a.notify('beforeitemchange',[e]);if(j){a.updateKey(c,f)}if(m||q){a.splice(d,q,m)}if(h>0){e.newIndex--}else {if(h<0){e.oldIndex++}}a.notify(g?'filtereditemchange':'itemchange',[e]);a.endUpdate()}},remove:function(d){var a=this,c=a.decodeRemoveItems(arguments,0),b=a.length;a.splice(0,c);return b-a.length},removeAll:function(){var a=this,b=a.length;if(a.generation&&b){a.splice(0,b)}return a},removeAt:function(j,f){var a=this,e=a.length,i=Ext.Number,g=i.clipIndices(e,[j,f===undefined?1:f],i.Clip.COUNT),c=g[0],d=g[1]-c,h=d===1&&a.getAt(c),b;a.splice(c,d);b=a.length-e;return h&&b?h:b},removeByKey:function(b){var a=this.getByKey(b);if(!a||!this.remove(a)){return !1}return a},replace:function(a){var b=this.indexOf(a);if(b===-1){this.add(a)}else {this.insert(b,a)}},splice:function(K,E,L){var b=this,D=b.sorted&&b.getAutoSort(),F=b.map,o=b.items,r=b.length,n=E instanceof Array?b.decodeRemoveItems(E):null,G=!n,J=Ext.Number,I=J.clipIndices(r,[K,G?E:0],J.Clip.COUNT),m=I[0],v=I[1],x=v-m,p=b.decodeItems(arguments,2),h=p?p.length:0,c,A,C,d=m,k=b.indices||(h||n?b.getIndices():null),e=null,i=x?[m]:null,l=null,t=b.getSource(),j,B,z,a,u,g,w,f,s,q,y,H,v;if(t&&!t.updating){if(G){n=[];for(a=0;a1){if(!c.$cloned){p=c=c.slice(0)}b.sortData(c)}}for(a=0;a0;){f=b.getKey(n[a]);if((g=k[f])!==undefined){(i||(i=[])).push(g)}}if(!e&&!i){return b}b.beginUpdate();if(i){j=null;z=[];C={};if(i.length>1){i.sort(Ext.Array.numericSortFn)}for(a=0,q=i.length;aj.at+B.length){z.push(j={at:g,items:B=[],keys:s=[],map:C,next:j,replacement:e});if(e){e.replaced=j}}B.push(C[f]=u);s.push(f);if(g1&&g===m){--x;i[a--]=++m}}if(e){e.at=d}for(w=z.length;w-->0;){j=z[w];a=j.at;q=j.items.length;if(a+q1&&r){b.spliceMerge(c,l)}else {if(D){if(h>1){d=0;b.indices=k=null}else {d=H.findInsertionIndex(e.items[0],o,b.getSortFn())}}if(d===r){v=d;for(a=c.length-1;a>=0;--a){o[v+a]=c[a]}k=b.indices;if(k){for(a=0;a-1){c=e[b];a=this.indexOf(c);if(a>-1){return a+1}--b}return 0},onCollectionAdd:function(l,i){var a=this,j=i.atItem,d=i.items,h=a.requestedIndex,c,b,e,f,g,k;if(!a.sorted){if(h!==undefined){b=h}else {if(j){b=a.indexOf(j);if(b===-1){b=a.findInsertIndex(d[0])}else {++b}}else {b=0}}}if(a.getAutoFilter()&&a.filtered){for(f=0,k=d.length;fc)){c=a}}return [c,b]},count:function(a){return a.length},extremes:function(k,j,l,i,f){var e=null,d=null,c,b,g,h,a;for(c=j;ch)){h=a;d=b}}return [d,e]},max:function(c,b,e,a,d){var f=this._aggregators.bounds.call(this,c,b,e,a,d);return f[1]},maxItem:function(c,b,e,a,d){var f=this._aggregators.extremes.call(this,c,b,e,a,d);return f[1]},min:function(c,b,e,a,d){var f=this._aggregators.bounds.call(this,c,b,e,a,d);return f[0]},minItem:function(c,b,e,a,d){var f=this._aggregators.extremes.call(this,c,b,e,a,d);return f[0]},sum:function(g,f,h,e,c){for(var a,d=0,b=f;b1){Ext.Array.sort(a,b.prioritySortFn)}},prioritySortFn:function(a,b){var c=a.observerPriority||0,d=b.observerPriority||0;return c-d},applyExtraKeys:function(e,g){var d=this,f=g||{},b,c,a;for(c in e){a=e[c];if(!a.isCollectionKey){b={collection:d};if(Ext.isString(a)){b.property=a}else {b=Ext.apply(b,a)}a=new Ext.util.CollectionKey(b)}else {a.setCollection(d)}f[c]=d[c]=a;a.name=c}return f},applyGrouper:function(a){if(a){a=this.getSorters().decodeSorter(a,'Ext.util.Grouper')}return a},decodeItems:function(e,d){var g=this,a=d===undefined?e:e[d],b,f,c;if(!a||!a.$cloned){b=e.length>d+1||!Ext.isIterable(a);if(b){a=Ext.Array.slice(e,d);if(a.length===1&&a[0]===undefined){a.length=0}}f=g.getDecoder();if(f){if(!b){a=a.slice(0);b=!0}for(c=a.length;c-->0;){if((a[c]=f.call(g,a[c]))===!1){a.splice(c,1)}}}if(b){a.$cloned=!0}}return a},getIndices:function(){var a=this,c=a.indices,d=a.items,f=d.length,b,e;if(!c){a.indices=c={};++a.indexRebuilds;for(b=0;b0;if(d||c){b.filtered=c;b.onFilterChange(a)}},getSortFn:function(){return this._sortFn||this.createSortFn()},getSorters:function(b){var a=this._sorters;if(!a&&b!==!1){a=new Ext.util.SorterCollection();this.setSorters(a)}return a},onSortChange:function(){if(this.sorted){this.sortItems()}},sort:function(c,b,d){var a=this.getSorters();a.addSort.apply(a,arguments);return this},sortData:function(a){Ext.Array.sort(a,this.getSortFn());return a},sortItems:function(b){var a=this;if(a.sorted){b=a.getSortFn()}a.indices=null;a.notify('beforesort',[a.getSorters(!1)]);if(a.length){Ext.Array.sort(a.items,b)}a.notify('sort')},sortBy:function(a){return this.sortItems(a)},findInsertionIndex:function(c,b,a){if(!b){b=this.items}if(!a){a=this.getSortFn()}return Ext.Array.binarySearch(b,c,a)},applySorters:function(a,b){if(a==null||a&&a.isSorterCollection){return a}if(a){if(!b){b=this.getSorters()}b.splice(0,b.length,a)}return b},createSortFn:function(){var d=this,b=d.getGrouper(),c=d.getSorters(!1),a=c?c.getSortFn():null;if(!b){return a}return function(d,e){var c=b.sort(d,e);if(!c&&a){c=a(d,e)}return c}},updateGrouper:function(c){var a=this,b=a.getGroups(),e=a.getSorters(),d;a.onSorterChange();a.grouped=!!c;if(c){if(a.getTrackGroups()){if(!b){b=new Ext.util.GroupCollection({itemRoot:a.getRootProperty()});b.$groupable=a;a.setGroups(b)}b.setGrouper(c);d=!0}}else {if(b){a.removeObserver(b);b.destroy()}a.setGroups(null)}if(!e.updating){a.onEndUpdateSorters(e)}if(d){b.onCollectionRefresh(a)}},updateSorters:function(b,c){var a=this;if(c){c.un('endupdate','onEndUpdateSorters',a)}if(b){b.on({endupdate:'onEndUpdateSorters',scope:a,priority:a.$endUpdatePriority});b.$sortable=a}a.onSorterChange();a.onEndUpdateSorters(b)},onSorterChange:function(){this._sortFn=null},onEndUpdateSorters:function(b){var a=this,d=a.sorted,c=a.grouped&&a.getAutoGroup()||b&&b.length>0;if(d||c){a.sorted=!!c;a.onSortChange(b)}},removeObserver:function(b){var a=this.observers;if(a){Ext.Array.remove(a,b)}},spliceMerge:function(i,q){var f=this,r=f.map,k=i.length,g=0,n=f.items,m=n.length,h=[],c=0,a=[],p=f.getSortFn(),l,j,d,b,o,e;f.items=a;for(e=0;e1){h[c-2].next=h[c-1]}for(;e1){h[c-2].next=h[c-1]}a.push(b);for(j=e+1;j=0){break}a.push(b);l.push(b)}}for(;g0)}e=j.createAssociationStore(i,f,b,h);e.$source=q;if(!b&&(j.autoLoad||a)){n=!0}f[m]=e}if(a){if(n||e.isLoading()){e.on('load',function(h,i,e,g){d=[h,g];c=c||a.scope||f;if(e){Ext.callback(a.success,c,d)}else {Ext.callback(a.failure,c,d)}d.push(e);Ext.callback(a,c,d);Ext.callback(a.callback,c,d)},null,{single:!0})}else {d=[e,null];c=c||a.scope||f;Ext.callback(a.success,c,d);d.push(!0);Ext.callback(a,c,d);Ext.callback(a.callback,c,d)}}if(n&&!e.isLoading()){e.load()}return e},getAssociatedItem:function(b){var a=this.isMany?this.getStoreName():this.getInstanceName();return b[a]||null},onDrop:Ext.emptyFn,getReaderRoot:function(){var a=this;return a.associationKey||(a.associationKey=a.association.schema.getNamer().readerRoot(a.role))},getReader:function(){var b=this,a=b.reader,d=b.cls,c=!b.associationKey,e=this.getReaderRoot();if(a&&!a.isReader){if(Ext.isString(a)){a={type:a}}Ext.applyIf(a,{model:d,rootProperty:e,useSimpleAccessors:c,type:b.defaultReaderType});a=b.reader=Ext.createByAlias('reader.'+a.type,a)}return a},getInstanceName:function(){var a=this;return a.instanceName||(a.instanceName=a.association.schema.getNamer().instanceName(a.role))},getOldInstanceName:function(){return this.oldInstanceName||(this.oldInstanceName='$old'+this.getInstanceName())},getStoreName:function(){var a=this;return a.storeName||(a.storeName=a.association.schema.getNamer().storeName(a.role))},constructReader:function(h){var b=this,a=b.getReader(),e=b.cls,g=!b.associationKey,f=b.getReaderRoot(),c,d;if(!a){d=e.getProxy();if(d){c=d.getReader();a=new c.self();a.copyFrom(c);a.setRootProperty(f)}else {a=new h.self({model:e,useSimpleAccessors:g,rootProperty:f})}b.reader=a}return a},read:function(f,e,d,c){var a=this.constructReader(d),b=a.getRoot(e);if(b){return a.readRecords(b,c,this._internalReadOptions)}},getCallbackOptions:function(a,c,b){if(typeof a==='function'){a={callback:a,scope:c||b}}else {if(a){a=Ext.apply({},a);a.scope=c||a.scope||b}}return a},doGetFK:function(d,b,f){var i=this,l=i.cls,j=i.association.getFieldName(),h=i.getInstanceName(),a=d[h],m=b&&b.reload,e=a!==undefined&&!m,k=d.session,c,g;if(!e){if(k){c=d.get(j);if(c||c===0){e=k.peekRecord(l,c,!0)&&!m;a=k.getRecord(l,c,!1)}else {e=!0;d[h]=a=null}}else {if(j){c=d.get(j);if(!c&&c!==0){e=!0;d[h]=a=null}else {if(!a){a=l.createWithId(c)}}}else {e=!0}}}else {if(a){e=!a.isLoading()}}if(e){if(b){g=[a,null];f=f||b.scope||d;Ext.callback(b.success,f,g);g.push(!0);Ext.callback(b,f,g);Ext.callback(b.callback,f,g)}}else {d[h]=a;b=i.getCallbackOptions(b,f,d);a.load(b)}return a},doSetFK:function(a,c,e,l){var f=this,i=f.association.getFieldName(),h=f.getInstanceName(),b=a[h],d=f.inverse,j=d.setterName,m=a.session,k,g;if(c&&c.isEntity){if(b!==c){g=f.getOldInstanceName();a[g]=b;a[h]=c;if(b&&b.isEntity){b[d.getInstanceName()]=undefined}if(i){a.set(i,c.getId())}delete a[g];if(j){c[j](a)}}}else {k=a.changingKey&&!d.isMany||a.set(i,c);if(k&&b&&b.isEntity&&!b.isEqual(b.getId(),c)){a[h]=undefined;if(!d.isMany){b[d.getInstanceName()]=undefined}}}if(e){if(Ext.isFunction(e)){e={callback:e,scope:l||a}}return a.save(e)}}},1,0,0,0,0,0,[Ext.data.schema,'Role'],0);Ext.cmd.derive('Ext.data.schema.Association',Ext.Base,{isOneToOne:!1,isManyToOne:!1,isManyToMany:!1,owner:null,field:null,constructor:function(d){var a=this,c,b;Ext.apply(a,d);a.left=c=new a.Left(a,a.left);a.right=b=new a.Right(a,a.right);c.inverse=b;b.inverse=c},hasField:function(){return !!this.field},getFieldName:function(){var a=this.field;return a?a.name:''}},1,0,0,0,0,0,[Ext.data.schema,'Association'],0);Ext.cmd.derive('Ext.data.schema.OneToOne',Ext.data.schema.Association,{isOneToOne:!0,isToOne:!0,kind:'one-to-one',Left:Ext.define(null,{extend:'Ext.data.schema.Role',onDrop:function(a,c){var b=this.getAssociatedItem(a);a[this.getInstanceName()]=null;if(b){b[this.inverse.getInstanceName()]=null}},createGetter:function(){var a=this;return function(){return a.doGet(this)}},createSetter:function(){var a=this;return function(b){return a.doSet(this,b)}},doGet:function(a){var c=this.getInstanceName(),b=a[c],d=a.session;if(!b&&d){}return b||null},doSet:function(a,b){var d=this.getInstanceName(),e=a[d],c=this.inverse.setterName;if(e!==b){a[d]=b;if(c){b[c](a)}}return e},read:function(a,g,f,e){var c=this,d=c.callParent([a,g,f,e]),b;if(d){b=d[0];if(b){b[c.inverse.getInstanceName()]=a;a[c.getInstanceName()]=b;delete a.data[c.role]}}}}),Right:Ext.define(null,{extend:'Ext.data.schema.Role',left:!1,side:'right',createGetter:function(){var a=this;return function(b,c){return a.doGetFK(this,b,c)}},createSetter:function(){var a=this;return function(d,b,c){return a.doSetFK(this,d,b,c)}},onDrop:function(c,f){var b=this,e=b.association.field,a=b.getAssociatedItem(c),d;if(b.inverse.owner){if(f){d=c.get(e.name);if(d||d===0){a=f.getEntry(b.cls,d).record;if(a){a.drop()}}}else {if(a){a.drop()}}}if(e){c.set(e.name,null)}c[b.getInstanceName()]=null;if(a){a[b.inverse.getInstanceName()]=null}},onValueChange:function(b,f,c){var a=this,e=b[a.getOldInstanceName()]||a.getAssociatedItem(b),h=c||c===0,d=a.getInstanceName(),g=a.cls;b.changingKey=!0;a.doSetFK(b,c);if(!h){b[d]=null}else {if(f&&g){b[d]=f.peekRecord(g,c)||undefined}}if(a.inverse.owner&&e){a.association.schema.queueKeyCheck(e,a)}b.changingKey=!1},checkKeyForDrop:function(a){var b=this.inverse.getAssociatedItem(a);if(!b){a.drop()}},read:function(a,o,n,m){var f=this,l=f.callParent([a,o,n,m]),b,d,g,c,k,h,j,i,e;if(l){b=l[0];d=f.association.field;if(d){g=d.name}c=a.session;e=a.data;if(b){if(c){k=c.getRefs(b,this.inverse,!0);i=k&&k[a.id]||e[g]===undefined}else {i=!0}if(i){if(d){j=e[g];h=b.id;if(j!==h){e[g]=h;if(c){c.updateReference(a,d,h,j)}}}b[f.inverse.getInstanceName()]=a;a[f.getInstanceName()]=b}delete e[f.role]}}}})},0,0,0,0,0,0,[Ext.data.schema,'OneToOne'],0);Ext.cmd.derive('Ext.data.schema.ManyToOne',Ext.data.schema.Association,{isManyToOne:!0,isToOne:!0,kind:'many-to-one',Left:Ext.define(null,{extend:'Ext.data.schema.Role',isMany:!0,onDrop:function(d,f){var b=this,e=b.getAssociatedItem(d),a,g,c,i,h;if(e){a=e.removeAll();if(a&&b.inverse.owner){for(c=0,g=a.length;c0){a=c[h];e=!a.isEqual(l,a.get(i));b=f?null:d;if(e!==f){a.changingKey=!0;a[k](b);a.changingKey=!1}else {a[j]=b}}}}),Right:Ext.define(null,{extend:'Ext.data.schema.Role',left:!1,side:'right',onDrop:function(a,c){var b=this.association.field;if(b){a.set(b.name,null)}a[this.getInstanceName()]=null},createGetter:function(){var a=this;return function(b,c){return a.doGetFK(this,b,c)}},createSetter:function(){var a=this;return function(b,c,d){return a.doSetFK(this,b,c,d)}},checkMembership:function(c,b){var d=this.association.field,a;a=this.getSessionStore(c,b.get(d.name));if(a&&!a.contains(b)){a.add(b)}},onValueChange:function(b,f,d,l){var c=this,j=c.getInstanceName(),m=c.cls,i,g,a,h,n,e,k;if(!b.changingKey){i=d||d===0;if(!i){b[j]=null}if(f){a=c.getSessionStore(f,l);if(a){a.remove(b)}if(i){a=c.getSessionStore(f,d);if(a&&!a.isLoading()){a.add(b)}if(m){k=f.peekRecord(m,d)}b[j]=k||undefined}}else {g=b.joined;if(g){for(h=0,n=g.length;h=0){a.remove([b])}}else {if(b<0){d=a.getSession().getEntry(this.type,e);c=d&&d.record;if(c){a.add(c)}}}a.matrixUpdate=0}},adoptAssociated:function(e,d){var a=this.getAssociatedItem(e),c,b,f;if(a){a.setSession(d);this.onStoreCreate(a,d,e.getId());c=a.getData().items;for(b=0,f=c.length;b1){a[b]=this.apply('capitalize',a[b])}return a.join('')},getterName:function(a){var b=a.role;if(a&&a.isMany){return b}return 'get'+this.apply('capitalize',b)},inverseFieldRole:function(e,f,c,d){var a=this,b=a.apply(f?'uniRole':'multiRole',e),g=a.apply('pluralize',c),h=a.apply('undotted,pluralize',d);if(g.toLowerCase()!==h.toLowerCase()){b=c+a.apply('capitalize',b)}return b},manyToMany:function(c,e,d){var b=this,a=b.apply('undotted,capitalize,singularize',e)+b.apply('undotted,capitalize,pluralize',d);if(c){a=b.apply('capitalize',c+a)}return a},manyToOne:function(d,b,a,c){return this.apply('capitalize,singularize',a)+this.apply('capitalize',b)},matrixRole:function(a,c){var b=this.apply(a?'multiRole,capitalize':'multiRole',c);return a?a+b:b},oneToOne:function(d,b,a,c){return this.apply('undotted,capitalize,singularize',a)+this.apply('capitalize',b)},setterName:function(a){return 'set'+this.apply('capitalize',a.role)},endsWithIdRe:/(?:(_id)|[^A-Z](Id))$/,cache:{},apply:function(b,c){var e=this,h=e.cache,i=h[c]||(h[c]={}),a=i[b],d,g,f;if(!a){if(b.indexOf(',')<0){a=e[b](c)}else {g=(f=b.split(',')).length;a=c;for(d=0;d=Math.max(a,b)},find:function(g,h,d,e,b,c){var a=!e,f=!!(a&&c);return this.getData().findIndex(g,h,d,a,f,!b)},findRecord:function(){var a=this,b=a.find.apply(a,arguments);return b!==-1?a.getAt(b):null},findExact:function(a,c,b){return this.getData().findIndexBy(function(d){return d.isEqual(d.get(a),c)},this,b)},findBy:function(c,a,b){return this.getData().findIndexBy(c,a,b)},getAt:function(a){return this.getData().getAt(a)||null},getRange:function(d,b,a){var c=this.getData().getRange(d,Ext.isNumber(b)?b+1:b);if(a&&a.callback){a.callback.call(a.scope||this,c,d,b,a)}return c},getFilters:function(b){var a=(arguments.callee.$previous||Ext.Base.prototype.getFilters).call(this);if(!a&&b!==!1){this.setFilters([]);a=(arguments.callee.$previous||Ext.Base.prototype.getFilters).call(this)}return a},applyFilters:function(c,a){var b;if(!a){a=this.createFiltersCollection();b=!0}a.add(c);if(b){this.onRemoteFilterSet(a,this.getRemoteFilter())}return a},getSorters:function(b){var a=(arguments.callee.$previous||Ext.Base.prototype.getSorters).call(this);if(!a&&b!==!1){this.setSorters([]);a=(arguments.callee.$previous||Ext.Base.prototype.getSorters).call(this)}return a},applySorters:function(c,a){var b;if(!a){a=this.createSortersCollection();b=!0}a.add(c);if(b){this.onRemoteSortSet(a,this.getRemoteSort())}return a},filter:function(a,c,b){if(Ext.isString(a)){a={property:a,value:c}}this.suppressNextFilter=!!b;this.getFilters().add(a);this.suppressNextFilter=!1},removeFilter:function(a,d){var b=this,c=b.getFilters();b.suppressNextFilter=!!d;if(a instanceof Ext.util.Filter){c.remove(a)}else {c.removeByKey(a)}b.suppressNextFilter=!1},updateRemoteSort:function(a){this.onRemoteSortSet(this.getSorters(!1),a)},updateRemoteFilter:function(a){this.onRemoteFilterSet(this.getFilters(!1),a)},addFilter:function(b,a){this.suppressNextFilter=!!a;this.getFilters().add(b);this.suppressNextFilter=!1},filterBy:function(b,a){this.getFilters().add({filterFn:b,scope:a||this})},clearFilter:function(c){var b=this,a=b.getFilters(!1);if(!a||a.getCount()===0){return}b.suppressNextFilter=!!c;a.removeAll();b.suppressNextFilter=!1},isFiltered:function(){return this.getFilters().getCount()>0},isSorted:function(){var a=this.getSorters(!1);return !!(a&&a.length>0)||this.isGrouped()},addFieldTransform:function(b){if(b.getTransform()){return}var e=b.getProperty(),d=this.getModel(),c,a;if(d){c=d.getField(e);a=c?c.getSortType():null}if(a&&a!==Ext.identityFn){b.setTransform(a)}},beginUpdate:function(){if(!this.updating++){this.fireEvent('beginupdate')}},endUpdate:function(){if(this.updating&&!--this.updating){this.fireEvent('endupdate');this.onEndUpdate()}},getState:function(){var c=this,e=[],g=c.getFilters(),f=c.getGrouper(),a,d,b;c.getSorters().each(function(a){e[e.length]=a.getState();d=!0});if(c.statefulFilters&&c.saveStatefulFilters){d=!0;a=[];g.each(function(b){a[a.length]=b.getState()})}if(f){d=!0}if(d){b={};if(e.length){b.sorters=e}if(a){b.filters=a}if(f){b.grouper=f.getState()}}return b},applyState:function(b){var a=this,e=b.sorters,c=b.filters,d=b.grouper;if(e){a.getSorters().replaceAll(e)}if(c){a.saveStatefulFilters=!0;a.getFilters().replaceAll(c)}if(d){a.setGrouper(d)}},hasPendingLoad:Ext.emptyFn,isLoaded:Ext.emptyFn,isLoading:Ext.emptyFn,destroy:function(){var a=this;if(a.getStoreId()){Ext.data.StoreManager.unregister(a)}a.callParent();a.onDestroy()},sort:function(c,b,d){var a=this;if(arguments.length===0){if(a.getRemoteSort()){a.load()}else {a.forceLocalSort()}}else {a.getSorters().addSort(c,b,d)}},onBeforeCollectionSort:function(b,a){if(a){this.fireEvent('beforesort',this,a.getRange())}},onSorterEndUpdate:function(){var a=this,b;b=a.getSorters(!1);if(a.settingGroups||!b){return}b=b.getRange();if(b.length){if(a.getRemoteSort()){a.load({callback:function(){a.fireEvent('sort',a,b)}})}else {a.fireEvent('datachanged',a);a.fireEvent('refresh',a);a.fireEvent('sort',a,b)}}else {a.fireEvent('sort',a,b)}},onFilterEndUpdate:function(){var a=this,b=a.suppressNextFilter;if(a.getRemoteFilter()){a.currentPage=1;if(!b){a.load()}}else {if(!b){a.fireEvent('datachanged',a);a.fireEvent('refresh',a)}}if(a.trackStateChanges){a.saveStatefulFilters=!0}a.fireEvent('filterchange',a,a.getFilters().getRange())},updateGroupField:function(a){if(a){this.setGrouper({property:a,direction:this.getGroupDir()})}else {this.setGrouper(null)}},getGrouper:function(){return this.getData().getGrouper()},group:function(b,d){var a=this,c=a.getSorters(!1),e=b||c&&c.length;if(b&&typeof b==='string'){b={property:b,direction:d||a.getGroupDir()}}a.settingGroups=!0;a.getData().setGrouper(b);delete a.settingGroups;if(e){if(a.getRemoteSort()){a.load({scope:a,callback:a.fireGroupChange})}else {a.fireEvent('datachanged',a);a.fireEvent('refresh',a);a.fireGroupChange()}}else {a.fireGroupChange()}},fireGroupChange:function(){if(!this.destroyed){this.fireEvent('groupchange',this,this.getGrouper())}},clearGrouping:function(){this.group(null)},getGroupField:function(){var a=this.getGrouper(),b='';if(a){b=a.getProperty()}return b},isGrouped:function(){return !!this.getGrouper()},applyGrouper:function(a){this.group(a);return this.getData().getGrouper()},getGroups:function(){return this.getData().getGroups()},onEndUpdate:Ext.emptyFn,privates:{loadsSynchronously:Ext.privateFn,onRemoteFilterSet:function(a,b){if(a){a[b?'on':'un']('endupdate',this.onFilterEndUpdate,this)}},onRemoteSortSet:function(c,b){var a=this;if(c){c[b?'on':'un']('endupdate',a.onSorterEndUpdate,a);a.getData()[b?'un':'on']('beforesort',a.onBeforeCollectionSort,a)}}},deprecated:{5:{methods:{destroyStore:function(){this.destroy()}}}}},1,0,0,0,0,[[Ext.mixin.Observable.prototype.mixinId||Ext.mixin.Observable.$className,Ext.mixin.Observable],[Ext.mixin.Factoryable.prototype.mixinId||Ext.mixin.Factoryable.$className,Ext.mixin.Factoryable]],[Ext.data,'AbstractStore'],0);Ext.cmd.derive('Ext.data.Error',Ext.Base,{isError:!0,$configPrefixed:!1,config:{field:null,message:''},constructor:function(a){this.initConfig(a);this.msg=this.message}},1,0,0,0,0,0,[Ext.data,'Error'],0);Ext.cmd.derive('Ext.data.ErrorCollection',Ext.util.MixedCollection,{alternateClassName:'Ext.data.Errors',init:function(d){var b=this,h=d.fields,k=d.data,g,a,l,c,i,f,j,e;for(c=0,i=h.length;c]+>/gi,asText:function(a){return a!=null?String(a).replace(this.stripTagsRe,''):'\x00'},asUCText:function(a){return a!=null?String(a).toUpperCase().replace(this.stripTagsRe,''):'\x00'},asUCString:function(a){return a!=null?String(a).toUpperCase():'\x00'},asDate:function(a){if(!a){return 0}if(Ext.isDate(a)){return a.getTime()}return Date.parse(String(a))},asFloat:function(b){var a=parseFloat(String(b).replace(this.stripCommasRe,''));return isNaN(a)?0:a},asInt:function(b){var a=parseInt(String(b).replace(this.stripCommasRe,''),10);return isNaN(a)?0:a}},0,0,0,0,0,0,[Ext.data,'SortTypes'],0);Ext.cmd.derive('Ext.data.validator.Validator',Ext.Base,{isValidator:!0,type:'base',statics:{all:{},register:function(a,c){var b=this.all;b[a.toUpperCase()]=b[a.toLowerCase()]=b[a]=c.prototype}},onClassExtended:function(b,a){if(a.type){Ext.data.validator.Validator.register(a.type,b)}},constructor:function(a){if(typeof a==='function'){this.fnOnly=!0;this.validate=a}else {this.initConfig(a)}},validate:function(){return !0},clone:function(){var a=this;if(a.fnOnly){return new Ext.data.validator.Validator(a.validate)}return new a.self(a.getCurrentConfig())}},1,0,0,0,['data.validator.base'],[[Ext.mixin.Factoryable.prototype.mixinId||Ext.mixin.Factoryable.$className,Ext.mixin.Factoryable]],[Ext.data.validator,'Validator'],function(){this.register(this.prototype.type,this)});Ext.cmd.derive('Ext.data.field.Field',Ext.Base,{alternateClassName:'Ext.data.Field',aliasPrefix:'data.field.',type:'auto',factoryConfig:{defaultProperty:'name'},isDataField:!0,isField:!0,allowBlank:!0,allowNull:!1,critical:!1,defaultInvalidMessage:'This field is invalid',defaultValue:undefined,definedBy:null,depends:null,dependents:null,mapping:null,name:null,ordinal:undefined,persist:null,reference:null,unique:!1,rank:null,stripRe:/[\$,%]/g,calculated:!1,evil:!1,identifier:!1,onClassExtended:function(f,d){var b=d.sortType,c=f.prototype,e=c.validators,a=d.validators;if(b&&Ext.isString(b)){c.sortType=Ext.data.SortTypes[b]}if(a){if(!Ext.isArray(a)){a=[a]}delete d.validators;if(e){a=e.concat(a)}c.validators=a}},argumentNamesRe:/^function\s*\(\s*([^,\)\s]+)/,calculateRe:/[^\.a-z0-9_]([a-z_][a-z_0-9]*)\.([a-z_][a-z_0-9]*)/gi,constructor:function(d){var a=this,n=a.calculateRe,c,l,f,h,b,j,e,m,k,i,g;if(d){if(Ext.isString(d)){a.name=d}else {g=d.validators;if(g){delete d.validators;a.instanceValidators=g}Ext.apply(a,d)}}if(!a.allowNull){a.allowNull=!!a.reference}c=a.calculate;b=a.depends;if(c){a.convert=a.doCalculate;if(!b){if(!(b=c.$depends)){j={};k=c.toString();c.$depends=b=[];e=a.argumentNamesRe.exec(k);m=e?e[1]:'data';while(e=n.exec(k)){if(m===e[1]&&!j[i=e[2]]){j[i]=1;b.push(i)}}}a.depends=b}}f=a.defaultValue;if(a.convert){a.calculated=l=a.convert.length>1;a.evil=l&&!b}if(a.persist===null){a.persist=!c}h=a.sortType;if(!a.sortType){a.sortType=Ext.data.SortTypes.none}else {if(Ext.isString(h)){a.sortType=Ext.data.SortTypes[h]}}if(b&&typeof b==='string'){a.depends=[b]}a.cloneDefaultValue=f!==undefined&&(Ext.isDate(f)||Ext.isArray(f)||Ext.isObject(f))},setModelValidators:function(a){this._validators=null;this.modelValidators=a},compileValidators:function(){var a=this;a._validators=[];a.constructValidators(a.validators);a.constructValidators(a.modelValidators);a.constructValidators(a.instanceValidators)},constructValidators:function(a){if(a){if(!(a instanceof Array)){a=[a]}var d=a.length,e=this._validators,c,b;for(c=0;c0){(u=p[v]).dirty=!0;d=d?Math.min(d,u.rank):u.rank}if(!b||b.persist){if(f&&f.hasOwnProperty(c)){if(!y||o.isEqual(f[c],h)){delete f[c];a.dirty=-1}}else {if(y){if(!f){a.modified=f={}}a.dirty=!0;f[c]=j}}}if(c===a.idField.name){D=!0;z=j;s=h}}if(!d){break}b=l[d-1];b.dirty=!1;if(n){delete g[i]}else {g=a._singleProp;n=!0}i=b.name;g[i]=t[i];C=!0;for(;d0;){d=(b=g[i]).name;if(!(d in f)){c=h[d];if(j&&b.serialize){c=b.serialize(c,a)}f[d]=c}}}if(n){a.getAssociatedData(f,e)}return f},getTransientFields:function(){var a=this.self,b=a.transientFields;if(!b){a.rankFields();b=a.transientFields}return b},isLoading:function(){return !!this.loadOperation},abort:function(){var a=this.loadOperation;if(a){a.abort()}},load:function(a){a=Ext.apply({},a);var b=this,d=a.scope||b,g=b.getProxy(),f=a.callback,c=b.loadOperation,h=b.getId(),e;if(c){e=c.extraCalls;if(!e){e=c.extraCalls=[]}e.push(a);return c}a.id=h;a.recordCreator=function(e,f,c){var d=b.session;if(c){c.recordCreator=d?d.recordCreator:null}b.set(e,b._commitOptions);return b};a.internalCallback=function(e){var h=e.wasSuccessful()&&e.getRecords().length>0,l=b.loadOperation,i=l.extraCalls,c=[b,e],j=[b,e,h],g,k;b.loadOperation=null;if(h){Ext.callback(a.success,d,c)}else {Ext.callback(a.failure,d,c)}Ext.callback(f,d,j);if(i){for(g=0,k=i.length;g0;){b=i[a];if(b in e){delete e[b];delete j[b]}}for(a=0,h=f.length;a=a.getTotal()){a.setConfig({success:!1,records:[],total:0})}else {a.setRecords(Ext.Array.slice(d,e,e+i))}}b.setCompleted()}},clear:Ext.emptyFn},0,0,0,0,['proxy.memory'],0,[Ext.data.proxy,'Memory',Ext.data,'MemoryProxy'],0);Ext.cmd.derive('Ext.data.ProxyStore',Ext.data.AbstractStore,{config:{model:undefined,fields:null,proxy:undefined,autoLoad:undefined,autoSync:!1,batchUpdateMode:'operation',sortOnLoad:!0,trackRemoved:!0,asynchronousLoad:undefined},onClassExtended:function(e,d,b){var c=d.model,a;if(typeof c==='string'){a=b.onBeforeCreated;b.onBeforeCreated=function(){var g=this,f=arguments;Ext.require(c,function(){a.apply(g,f)})}}},implicitModel:'Ext.data.Model',autoSyncSuspended:0,constructor:function(b){var a=this;a.removed=[];Ext.data.AbstractStore.prototype.constructor.apply(this,arguments);if(a.getAsynchronousLoad()===!1){a.flushLoad()}},applyAsynchronousLoad:function(a){if(a==null){a=!this.loadsSynchronously()}return a},updateAutoLoad:function(a){this.getData();if(a){this.load(Ext.isObject(a)?a:undefined)}},getTotalCount:function(){return this.totalCount||0},applyFields:function(a){if(a){this.createImplicitModel(a)}},applyModel:function(a){if(a){a=Ext.data.schema.Schema.lookupEntity(a)}else {this.getFields();a=this.getModel()||this.createImplicitModel()}return a},applyProxy:function(a){var b=this.getModel();if(a!==null){if(a){if(a.isProxy){a.setModel(b)}else {if(Ext.isString(a)){a={type:a,model:b}}else {if(!a.model){a=Ext.apply({model:b},a)}}a=Ext.createByAlias('proxy.'+a.type,a);a.autoCreated=!0}}else {if(b){a=b.getProxy()}}if(!a){a=Ext.createByAlias('proxy.memory');a.autoCreated=!0}}return a},applyState:function(b){var a=this;Ext.data.AbstractStore.prototype.applyState.call(this,b);if(a.getAutoLoad()||a.isLoaded()){a.load()}},updateProxy:function(b,a){this.proxyListeners=Ext.destroy(this.proxyListeners)},updateTrackRemoved:function(a){this.cleanRemoved();this.removed=a?[]:null},onMetaChange:function(b,a){this.fireEvent('metachange',this,a)},create:function(f,a){var b=this,e=b.getModel(),d=new e(f),c;a=Ext.apply({},a);if(!a.records){a.records=[d]}a.internalScope=b;a.internalCallback=b.onProxyWrite;c=b.createOperation('create',a);return c.execute()},read:function(){return this.load.apply(this,arguments)},update:function(a){var b=this,c;a=Ext.apply({},a);if(!a.records){a.records=b.getUpdatedRecords()}a.internalScope=b;a.internalCallback=b.onProxyWrite;c=b.createOperation('update',a);return c.execute()},onProxyWrite:function(a){var b=this,c=a.wasSuccessful(),d=a.getRecords();switch(a.getAction()){case 'create':b.onCreateRecords(d,a,c);break;case 'update':b.onUpdateRecords(d,a,c);break;case 'destroy':b.onDestroyRecords(d,a,c);break;}if(c){b.fireEvent('write',b,a);b.fireEvent('datachanged',b)}},onCreateRecords:Ext.emptyFn,onUpdateRecords:Ext.emptyFn,onDestroyRecords:function(c,b,a){if(a){this.cleanRemoved()}},erase:function(a){var b=this,c;a=Ext.apply({},a);if(!a.records){a.records=b.getRemovedRecords()}a.internalScope=b;a.internalCallback=b.onProxyWrite;c=b.createOperation('destroy',a);return c.execute()},onBatchOperationComplete:function(b,a){return this.onProxyWrite(a)},onBatchComplete:function(e,f){var a=this,c=e.operations,d=c.length,b;if(a.batchUpdateMode!=='operation'){a.suspendEvents();for(b=0;b0){b.create=f;c=!0}if(g.length>0){b.update=g;c=!0}if(e.length>0){b.destroy=e;c=!0}if(c&&a.fireEvent('beforesync',b)!==!1){a.isSyncing=!0;d=d||{};a.proxy.batch(Ext.apply(d,{operations:b,listeners:a.getBatchListeners()}))}return a},getBatchListeners:function(){var a=this,b={scope:a,exception:a.onBatchException,complete:a.onBatchComplete};if(a.batchUpdateMode==='operation'){b.operationcomplete=a.onBatchOperationComplete}return b},save:function(){return this.sync.apply(this,arguments)},load:function(b){var a=this;if(typeof b==='function'){b={callback:b}}else {b=b?Ext.Object.chain(b):{}}a.pendingLoadOptions=b;if(a.getAsynchronousLoad()){if(!a.loadTimer){a.loadTimer=Ext.asap(a.flushLoad,a)}}else {a.flushLoad()}return a},flushLoad:function(){var a=this,c=a.pendingLoadOptions,b;a.clearLoadTask();if(!c){return}a.setLoadOptions(c);if(a.getRemoteSort()&&c.sorters){a.fireEvent('beforesort',a,c.sorters)}b=Ext.apply({internalScope:a,internalCallback:a.onProxyLoad,scope:a},c);a.lastOptions=b;b=a.createOperation('read',b);if(a.fireEvent('beforeload',a,b)!==!1){a.onBeforeLoad(b);a.loading=!0;b.execute()}},reload:function(a){var b=Ext.apply({},a,this.lastOptions);return this.load(b)},onEndUpdate:function(){var a=this;if(a.needsSync&&a.autoSync&&!a.autoSyncSuspended){a.sync()}},afterReject:function(b){var a=this;if(a.contains(b)){a.onUpdate(b,Ext.data.Model.REJECT,null);a.fireEvent('update',a,b,Ext.data.Model.REJECT,null)}},afterCommit:function(c,a){var b=this;if(!a){a=null}if(b.contains(c)){b.onUpdate(c,Ext.data.Model.COMMIT,a);b.fireEvent('update',b,c,Ext.data.Model.COMMIT,a)}},afterErase:function(a){this.onErase(a)},onErase:Ext.emptyFn,onUpdate:Ext.emptyFn,onDestroy:function(){var a=this,b=a.getProxy();a.clearLoadTask();a.getData().destroy();a.data=null;a.setProxy(null);if(b.autoCreated){b.destroy()}a.setModel(null)},hasPendingLoad:function(){return !!this.pendingLoadOptions||this.isLoading()},isLoading:function(){return !!this.loading},isLoaded:function(){return this.loadCount>0},suspendAutoSync:function(){++this.autoSyncSuspended},resumeAutoSync:function(b){var a=this;if(a.autoSyncSuspended&&!--a.autoSyncSuspended){if(b){a.sync()}}},removeAll:Ext.emptyFn,clearData:Ext.emptyFn,privates:{getRawRemovedRecords:function(){return this.removed},onExtraParamsChanged:function(){},clearLoadTask:function(){Ext.asapCancel(this.loadTimer);this.pendingLoadOptions=this.loadTimer=null},cleanRemoved:function(){var a=this.getRawRemovedRecords(),c,b;if(a){for(b=0,c=a.length;b-1},each:function(f,e){var c=this.data.items,d=c.length,b,a;for(a=0;a0){if(u){f=0;if(d.length>1&&h){f=1}b[i]=d[f].getProperty();b[t]=d[f].getDirection()}else {b[i]=a.encodeSorters(d)}}if(l&&j&&j.length>0){b[l]=a.encodeFilters(j)}return b},buildUrl:function(c){var b=this,a=b.getUrl(c);if(b.getNoCache()){a=Ext.urlAppend(a,Ext.String.format('{0}={1}',b.getCacheString(),Ext.Date.now()))}return a},getUrl:function(a){var b;if(a){b=a.getUrl()||this.getApi()[a.getAction()]}return b?b:(arguments.callee.$previous||Ext.data.proxy.Proxy.prototype.getUrl).call(this)},doRequest:function(a){},afterRequest:Ext.emptyFn,destroy:function(){Ext.data.proxy.Proxy.prototype.destroy.call(this);Ext.destroy(this.getReader(),this.getWriter());this.reader=this.writer=null}},0,0,0,0,['proxy.server'],0,[Ext.data.proxy,'Server',Ext.data,'ServerProxy'],0);Ext.cmd.derive('Ext.data.proxy.Ajax',Ext.data.proxy.Server,{alternateClassName:['Ext.data.HttpProxy','Ext.data.AjaxProxy'],isAjaxProxy:!0,defaultActionMethods:{create:'POST',read:'GET',update:'POST',destroy:'POST'},config:{binary:!1,headers:undefined,paramsAsJson:!1,withCredentials:!1,useDefaultXhrHeader:!0,username:null,password:null,actionMethods:{create:'POST',read:'GET',update:'POST',destroy:'POST'}},doRequest:function(e){var a=this,g=a.getWriter(),b=a.buildRequest(e),f=a.getMethod(b),c,d;if(g&&e.allowWrite()){b=g.write(b)}b.setConfig({binary:a.getBinary(),headers:a.getHeaders(),timeout:a.getTimeout(),scope:a,callback:a.createRequestCallback(b,e),method:f,useDefaultXhrHeader:a.getUseDefaultXhrHeader(),disableCaching:!1});if(f.toUpperCase()!=='GET'&&a.getParamsAsJson()){d=b.getParams();if(d){c=b.getJsonData();if(c){c=Ext.Object.merge({},c,d)}else {c=d}b.setJsonData(c);b.setParams(undefined)}}if(a.getWithCredentials()){b.setWithCredentials(!0);b.setUsername(a.getUsername());b.setPassword(a.getPassword())}return a.sendRequest(b)},sendRequest:function(a){a.setRawRequest(Ext.Ajax.request(a.getCurrentConfig()));this.lastRequest=a;return a},abort:function(a){a=a||this.lastRequest;if(a){Ext.Ajax.abort(a.getRawRequest())}},getMethod:function(d){var a=this.getActionMethods(),b=d.getAction(),c;if(a){c=a[b]}return c||this.defaultActionMethods[b]},createRequestCallback:function(b,c){var a=this;return function(f,e,d){if(b===a.lastRequest){a.lastRequest=null}a.processResponse(e,c,b,d)}},destroy:function(){this.lastRequest=null;Ext.data.proxy.Server.prototype.destroy.call(this)}},0,0,0,0,['proxy.ajax'],0,[Ext.data.proxy,'Ajax',Ext.data,'HttpProxy',Ext.data,'AjaxProxy'],0);Ext.cmd.derive('Ext.data.reader.Json',Ext.data.reader.Reader,{alternateClassName:'Ext.data.JsonReader',config:{record:null,metaProperty:'metaData',useSimpleAccessors:!1,preserveRawData:!1},updateRootProperty:function(){this.forceBuildExtractors()},updateMetaProperty:function(){this.forceBuildExtractors()},readRecords:function(a,e,d){var b=this,c;if(b.getMeta){c=b.getMeta(a);if(c){b.onMetaChange(c)}}else {if(a.metaData){b.onMetaChange(a.metaData)}}return Ext.data.reader.Reader.prototype.readRecords.call(this,a,e,d)},getResponseData:function(b){var a;try{return Ext.decode(b.responseText)}catch(c){a=this.createReadError(c.message);Ext.Logger.warn('Unable to parse the JSON returned by the server');this.fireEvent('exception',this,b,a);return a}},buildExtractors:function(){var a=this,b,c;if(Ext.data.reader.Reader.prototype.buildExtractors.apply(this,arguments)){b=a.getMetaProperty();c=a.getRootProperty();if(c){a.getRoot=a.getAccessor(c)}else {a.getRoot=Ext.identityFn}if(b){a.getMeta=a.getAccessor(b)}}},extractData:function(a,f){var e=this.getRecord(),d=[],c,b;if(e){c=a.length;if(!c&&Ext.isObject(a)){c=1;a=[a]}for(b=0;b1||e&&!g){b+=d}else {if(k){i=!1;if(l){++e}else {if(g){--e;i=!0}}if(b){if(i){b='['+b+']'}else {b='.'+b}j+=b;m.push(''+j);b=''}}}}f=m.join(' && ');f=Ext.functionFactory('raw','return '+f)}return f}}(),createFieldAccessor:function(b){var e=this,a=b.mapping,c=a||a===0,d=c?a:b.name;if(c){if(typeof d==='function'){return function(a){return b.mapping(a,e)}}else {return e.createAccessor(d)}}},getAccessorKey:function(b){var a=this.getUseSimpleAccessors()?'simple':'';return this.$className+a+b},privates:{copyFrom:function(a){Ext.data.reader.Reader.prototype.copyFrom.call(this,a);this.getRoot=a.getRoot}}},0,0,0,0,['reader.json'],0,[Ext.data.reader,'Json',Ext.data,'JsonReader'],0);Ext.cmd.derive('Ext.data.writer.Json',Ext.data.writer.Writer,{alternateClassName:'Ext.data.JsonWriter',config:{rootProperty:undefined,encode:!1,allowSingle:!0,expandData:!1},getExpandedData:function(f){var h=f.length,g=0,a,c,b,d,e,i=function(c,b){var a={};a[c]=b;return a};for(;g0){e=a[c];for(;d>0;d--){e=i(b[d],e)}a[b[0]]=a[b[0]]||{};Ext.Object.merge(a[b[0]],e);delete a[c]}}}}return f},writeRecords:function(b,a){var c=this,e=c.getRootProperty(),d,g,f;if(c.getExpandData()){a=c.getExpandedData(a)}if(c.getAllowSingle()&&a.length===1){a=a[0];g=!0}f=this.getTransform();if(f){a=f(a,b)}if(c.getEncode()){if(e){b.setParam(e,Ext.encode(a))}else {}}else {if(g||a&&a.length){d=b.getJsonData()||{};if(e){d[e]=a}else {d=a}b.setJsonData(d)}}return b}},0,0,0,0,['writer.json'],0,[Ext.data.writer,'Json',Ext.data,'JsonWriter'],0);Ext.cmd.derive('Ext.util.Group',Ext.util.Collection,{config:{groupKey:null},$endUpdatePriority:2001},0,0,0,0,0,0,[Ext.util,'Group'],0);Ext.cmd.derive('Ext.util.SorterCollection',Ext.util.Collection,{isSorterCollection:!0,$sortable:null,sortFn:null,config:{sorterOptionsFn:null,sorterOptionsScope:null},constructor:function(b){var a=this;a.sortFn=Ext.util.Sorter.createComparator(a);Ext.util.Collection.prototype.constructor.call(this,b);a.setDecoder(a.decodeSorter)},addSort:function(b,c,d){var a=this,f,j,k,g,h,i,e;if(!b){a.beginUpdate();a.endUpdate()}else {g=a.getOptions();if(b instanceof Array){e=b;d=c;c=null}else {if(Ext.isString(b)){if(!(i=a.get(b))){e=[{property:b,direction:c||g.getDefaultSortDirection()}]}else {e=[i]}}else {if(Ext.isFunction(b)){e=[{sorterFn:b,direction:c||g.getDefaultSortDirection()}]}else {e=[b];d=c;c=null}}}d=a._sortModes[d||'replace'];h=a.getAt(0);f=a.length;j=d.append?f:0;a.beginUpdate();a.splice(j,d.replace?f:0,e);if(d.multi){f=a.length;k=g.getMultiSortLimit();if(f>k){a.removeAt(k,f)}}if(i&&c){i.setDirection(c)}else {if(j===0&&h&&h===a.getAt(0)){h.toggle()}}a.endUpdate()}},clear:function(){this.beginUpdate();Ext.util.Collection.prototype.clear.call(this);this.endUpdate(this.items)},getSortFn:function(){return this.sortFn},getByProperty:function(d){var c=this.items,e=c.length,a,b;for(a=0;ad+1||!Ext.isIterable(b)){b=Ext.Array.slice(e,d)}var j=k.items,l=b.length,c=[],f,g,i,a,h;for(f=0;f0;){g=j[i];if(g.getSorterFn()===a){c.push(g)}}}}}}b=c;b.$cloned=!0}return b},getOptions:function(){return this.$sortable||this}},1,0,0,0,0,0,[Ext.util,'SorterCollection'],0);Ext.cmd.derive('Ext.util.FilterCollection',Ext.util.Collection,{isFilterCollection:!0,$filterable:null,filterFn:null,constructor:function(b){var a=this;a.filterFn=Ext.util.Filter.createFilterFn(a);Ext.util.Collection.prototype.constructor.call(this,b);a.setDecoder(a.decodeFilter)},filterData:function(a){return this.filtered?Ext.Array.filter(a,this.filterFn):a},getFilterFn:function(){return this.filterFn},isItemFiltered:function(a){return !this.filterFn(a)},decodeFilter:function(b){var d=this.getOptions(),c=d.getRootProperty(),a;if(b.isFilter){if(!b.getRoot()){b.setRoot(c)}}else {a={root:c};if(Ext.isFunction(b)){a.filterFn=b}else {a=Ext.apply(a,b);if(a.fn){a.filterFn=a.fn;delete a.fn}if(Ext.util.Filter.isInvalid(a)){return !1}}b=new Ext.util.Filter(a)}return b},decodeRemoveItems:function(f,e){var p=this,b=e===undefined?f:f[e];if(!b.$cloned){if(f.length>e+1||!Ext.isIterable(b)){b=Ext.Array.slice(f,e)}var k=p.items,o=b.length,h=[],a,g,l,n,m,c,d,j,i;for(g=0;g0;){c=k[j];d=!1;if(m){d=c.getProperty()===a}else {if(l){d=c.getFilterFn()===a}else {if(n){d=c.getProperty()===a.property&&c.getValue()===a.value}}}if(d){h.push(c)}}}}b=h;b.$cloned=!0}return b},getOptions:function(){return this.$filterable||this}},1,0,0,0,0,0,[Ext.util,'FilterCollection'],0);Ext.cmd.derive('Ext.util.GroupCollection',Ext.util.Collection,{isGroupCollection:!0,config:{grouper:null,itemRoot:null},observerPriority:-100,onCollectionAdd:function(b,a){this.addItemsToGroups(b,a.items)},onCollectionBeforeItemChange:function(b,a){this.changeDetails=a},onCollectionBeginUpdate:function(){this.beginUpdate()},onCollectionEndUpdate:function(){this.endUpdate()},onCollectionItemChange:function(b,a){var c=a.item;if(!a.indexChanged){this.syncItemGrouping(b,c,b.getKey(c),a.oldKey,a.oldIndex)}this.changeDetails=null},onCollectionRefresh:function(a){this.removeAll();this.addItemsToGroups(a,a.items)},onCollectionRemove:function(k,j){var d=this,g=d.changeDetails,b,h,a,e,i,c,f;if(g){f=g.item;a=d.findGroupForItem(f);b=[];if(a){b.push({group:a,items:[f]})}}else {b=d.groupItems(k,j.items,!1)}for(e=0,i=b.length;e0&&i.getSorters().getCount()===0){k=i.indexOf(a.items[0]);if(o-1){b=[c];d=1}else {d=0}}else {b=[];for(g=0,d=c.length;g=0;a--){d=c[a];d.reject();if(!g){b.insert(d.removedFrom||0,d)}}if(g){h.setAutoSort(i);b.add(c)}c.length=0}b.endUpdate();Ext.resumeLayouts(!0)},onDestroy:function(){var a=this,c=a.loadTask,d=a.getData(),b=d.getSource();a.clearData();Ext.data.ProxyStore.prototype.onDestroy.call(this);a.setSession(null);a.observers=null;if(c){c.cancel();a.loadTask=null}if(b){b.destroy()}},privates:{fetch:function(a){a=Ext.apply({},a);this.setLoadOptions(a);var b=this.createOperation('read',a);b.execute()},onBeforeLoad:function(a){this.callObservers('BeforeLoad',[a])},onRemoteFilterSet:function(a,b){if(a){this.getData().setFilters(b?null:a)}Ext.data.ProxyStore.prototype.onRemoteFilterSet.call(this,a,b)},onRemoteSortSet:function(b,a){var c=this.getData();if(b){c.setSorters(a?null:b)}c.setAutoGroup(!a);Ext.data.ProxyStore.prototype.onRemoteSortSet.call(this,b,a)},isMoving:function(a,f){var c=this.moveMap,b=0,e,d;if(c){if(a){if(Ext.isArray(a)){for(d=0,e=a.length;d-1}}}return b}},1,0,0,0,0,0,[Ext.app.domain,'Store'],0);Ext.cmd.derive('Ext.app.route.Queue',Ext.Base,{queue:null,token:null,constructor:function(a){Ext.apply(this,a);this.queue=new Ext.util.MixedCollection()},queueAction:function(a,b){this.queue.add({route:a,args:b})},clearQueue:function(){this.queue.removeAll()},runQueue:function(){var c=this.queue,a=c.removeAt(0),b;if(a){b=a&&a.route;b.execute(this.token,a.args,this.onActionExecute,this)}},onActionExecute:function(a){if(a){this.clearQueue()}else {this.runQueue()}}},1,0,0,0,0,0,[Ext.app.route,'Queue'],0);Ext.cmd.derive('Ext.app.route.Route',Ext.Base,{action:null,conditions:null,controller:null,allowInactive:!1,url:null,before:null,caseInsensitive:!1,matcherRegex:null,paramMatchingRegex:null,paramsInMatchString:null,constructor:function(c){var a=this,b;Ext.apply(a,c,{conditions:{}});b=a.url;a.paramMatchingRegex=new RegExp(/:([0-9A-Za-z\_]*)/g);a.paramsInMatchString=b.match(a.paramMatchingRegex)||[];a.matcherRegex=a.createMatcherRegex(b)},recognize:function(b){var a=this,d=a.controller,e,c;if((a.allowInactive||d.isActive())&&a.recognizes(b)){e=a.matchesFor(b);c=b.match(a.matcherRegex);c.shift();return Ext.applyIf(e,{controller:d,action:a.action,historyUrl:b,args:c})}return !1},recognizes:function(a){return this.matcherRegex.test(a)},execute:function(h,d,f,g){var e=d.args||[],a=this.before,c=this.controller,b=this.createCallback(d,f,g);if(a){e.push(b);if(Ext.isString(a)){a=this.before=c[a]}if(a){a.apply(c,e)}}else {b.resume()}},matchesFor:function(f){var b={},d=this.paramsInMatchString,c=f.match(this.matcherRegex),a=0,e=d.length;c.shift();for(;a0){c=a.substring(0,d);b=a.substring(d+1)+'.'+c}else {if(a.indexOf('.')>0&&(Ext.ClassManager.isCreated(a)||this.hasRegisteredPrefix(a))){b=a}else {if(f){b=f+'.'+g+'.'+(e?e+'.'+a:a);c=a}else {b=a}}}return {absoluteName:b,shortName:c}},hasRegisteredPrefix:function(a){var c=Ext.ClassManager,b=c.getPrefix(a);return b&&b!==a}},models:null,views:null,stores:null,controllers:null,config:{application:null,refs:null,active:!0,moduleClassName:null},onClassExtended:function(d,c,a){var b=a.onBeforeCreated;a.onBeforeCreated=function(j,i){var g=Ext.app.Controller,h=[],e,f;f=j.prototype;e=g.resolveNamespace(j,i);if(e){f.$namespace=e}g.processDependencies(f,h,e,'model',i.models);g.processDependencies(f,h,e,'view',i.views);g.processDependencies(f,h,e,'store',i.stores);g.processDependencies(f,h,e,'controller',i.controllers);Ext.require(h,Ext.Function.pass(b,arguments,this))}},constructor:function(a){this.initAutoGetters();Ext.app.BaseController.prototype.constructor.apply(this,arguments)},normalizeRefs:function(a){var c=this,b=[];if(a){if(Ext.isObject(a)){Ext.Object.each(a,function(d,c){if(Ext.isString(c)){c={selector:c}}c.ref=d;b.push(c)})}else {if(Ext.isArray(a)){b=Ext.Array.merge(b,a)}}}a=c.refs;if(a){c.refs=null;a=c.normalizeRefs(a);if(a){b=Ext.Array.merge(b,a)}}return b},getRefMap:function(){var e=this,a=e._refMap,b,d,f,c;if(!a){b=e.getRefs();a=e._refMap={};if(b){for(c=0,f=b.length;c0){d=c[b];a.map[a.getKey(d)]=b}++a.generation}}},1,0,0,0,0,0,[Ext.util,'Bag'],0);Ext.cmd.derive('Ext.util.Scheduler',Ext.Base,{busyCounter:0,lastBusyCounter:0,destroyed:!1,firing:null,notifyIndex:-1,nextId:0,orderedItems:null,passes:0,scheduledCount:0,validIdRe:null,config:{cycleLimit:5,preSort:null,tickDelay:5},suspendOnNotify:!0,constructor:function(a){this.mixins.observable.constructor.call(this,a);this.items=new Ext.util.Bag()},destroy:function(){var a=this,b=a.timer;if(b){window.clearTimeout(b);a.timer=null}a.items.destroy();a.items=a.orderedItems=null;a.callParent()},add:function(c){var a=this,b=a.items;if(b===a.firing){a.items=b=b.clone()}c.id=c.id||++a.nextId;c.scheduler=a;b.add(c);if(!a.sortMap){a.orderedItems=null}},remove:function(c){var a=this,b=a.items;if(a.destroyed){return}if(b===a.firing){a.items=b=b.clone()}if(c.scheduled){a.unscheduleItem(c);c.scheduled=!1}b.remove(c);a.orderedItems=null},sort:function(){var a=this,b=a.items,f={},e=a.getPreSort(),c,d;a.orderedItems=[];a.sortMap=f;if(e){b.sort(e)}b=b.items;for(c=0;c0;){c[d].stub=b}}return b},isDescendantOf:function(b){for(var a=this;a=a.parent;){if(a===b){return !0}}return !1},onSchedule:function(){for(var c,e,b,a,d=this.parent;d;d=d.parent){a=d.bindings;if(a){for(c=0,e=a.length;c '+a.binding.getFullName()+')')},getDataObject:function(){var a=this.binding;return a&&a.getDataObject()},getRawValue:function(){var a=this.binding;return a&&a.getRawValue()},getValue:function(){var a=this.binding;return a&&a.getValue()},getTargetStub:function(){var a=this.binding;return a&&a.stub},isLoading:function(){var a=this.binding;return a?a.isLoading():!1},link:function(c,b){var a=this,d=a.binding;if(d){d.destroy()}b=a.target=b||a.owner;a.linkDescriptor=c;a.binding=b.bind(c,a.onChange,a);a.binding.deep=!0},onChange:function(){this.invalidate(!0)},react:function(){var a=this,b=a.owner.linkData;b[a.name]=a.getValue();Ext.app.bind.Stub.prototype.react.call(this)},privates:{collect:function(){var c=this,b=Ext.app.bind.Stub.prototype.collect.call(this),a=c.binding?1:0;return b+a},sort:function(){var a=this.binding;if(a){this.scheduler.sortItem(a)}}}},0,0,0,0,0,0,[Ext.app.bind,'LinkStub'],0);Ext.cmd.derive('Ext.app.bind.RootStub',Ext.app.bind.AbstractStub,{isRootStub:!0,depth:0,createRootChild:function(a,j){var e=this,d=e.owner,i=d.getData(),g=e.children,c=g&&g[a],f=c?null:e,h,b;if(j||i.hasOwnProperty(a)||!(h=d.getParent())){b=new Ext.app.bind.Stub(d,a,f)}else {b=new Ext.app.bind.LinkStub(d,a,c?null:f);b.link('{'+a+'}',h)}if(c){c.graft(b)}return b},createStubChild:function(a){return this.createRootChild(a,!0)},descend:function(a,g){var f=this,d=f.children,b=g||0,e=a[b++],c=d&&d[e]||f.createRootChild(e);if(b0;){if(a[b].isLoading()){return !0}}return !1},isBindingStatic:function(a){return a.isTemplateBinding&&a.isStatic},isStatic:function(){var b=this.bindings,d=b.length,a,c;for(a=0;a-1}}}}return b}},1,0,0,0,0,0,[Ext.app.domain,'Controller'],0);Ext.cmd.derive('Ext.data.PageMap',Ext.util.LruCache,{config:{store:null,pageSize:0,rootProperty:''},clear:function(b){var a=this;a.pageMapGeneration=(a.pageMapGeneration||0)+1;a.indexMap={};Ext.util.LruCache.prototype.clear.call(this,b)},forEach:function(k,f){var d=this,b=Ext.Object.getKeys(d.map),h=b.length,j=d.getPageSize(),a,c,e,g,i;for(a=0;ad},hasPage:function(a){return !!this.get(a)},peekPage:function(a){return this.map[a]},getAt:function(a){return this.getRange(a,a+1)[0]},getRange:function(l,f){f--;if(!this.hasRange(l,f)){Ext.raise('PageMap asked for range which it does not have')}var c=this,k=Ext.Array,e=c.getPageSize(),g=c.getPageFromRecordIndex(l),h=c.getPageFromRecordIndex(f),m=(g-1)*e,n=h*e-1,a=g,j=[],d,i,b;for(;a<=h;a++){if(a===g){d=l-m;b=d>0}else {d=0;b=!1}if(a===h){i=e-(n-f);b=b||i=g){b=g-1;c=Math.max(b-h,0)}if(a.rangeCached(c,Math.min(b,a.totalCount))){a.loading=!1;f.un('pageadd',e);l=f.getRange(c,b+1);a.fireEvent('load',a,l,!0);a.fireEvent('refresh',a)}};h=Math.ceil((a.getLeadingBufferZone()+a.getTrailingBufferZone())/2);if(a.lastRequestStart&&a.preserveScrollOnReload){c=a.lastRequestStart;b=a.lastRequestEnd;i=a.getTotalCount()}else {c=d.start||0;b=c+(d.count||a.getPageSize())-1}f.clear(!0);delete a.totalCount;c=Math.max(c-h,0);b=Math.min(b+h,i);j=a.getPageFromRecordIndex(c);k=a.getPageFromRecordIndex(b);a.loading=!0;d.waitForReload=e;f.on('pageadd',e);for(g=j;g<=k;g++){a.prefetchPage(g,d)}},filter:function(){Ext.data.ProxyStore.prototype.filter.apply(this,arguments)},filterBy:function(b,a){},loadData:function(b,a){},loadPage:function(c,a){var b=this;a=a||{};a.page=b.currentPage=c;a.start=(c-1)*b.getPageSize();a.limit=b.getViewSize()||b.getDefaultViewSize();a.loadCallback=a.callback;a.callback=null;return b.loadToPrefetch(a)},clearData:function(c){var b=this,a=b.getData();if(a){a.clear()}},getCount:function(){return this.totalCount||0},getRange:function(c,b,f){var a=this,k=a.totalCount-1,m=a.lastRequestStart,l=[],h=a.getData(),g,d,e,i,j;f=Ext.apply({prefetchStart:c,prefetchEnd:b},f);b=b>=a.totalCount?k:b;d=c===0?0:c-1;e=b===k?b:b+1;a.lastRequestStart=c;a.lastRequestEnd=b;if(a.rangeCached(d,e)){a.onRangeAvailable(f);l=h.getRange(c,b+1)}else {a.fireEvent('cachemiss',a,c,b);i=a.getPageFromRecordIndex(d);j=a.getPageFromRecordIndex(e);g=function(l,k,m){if(k>=i&&k<=j&&a.rangeCached(d,e)){a.fireEvent('cachefilled',a,c,b);h.un('pageadd',g);a.onRangeAvailable(f)}};h.on('pageadd',g);a.prefetchRange(c,b)}a.primeCache(c,b,c-1},indexOf:function(a){return this.getData().indexOf(a)},indexOfId:function(a){return this.indexOf(this.getById(a))},group:function(b,d){var a=this,c;if(b&&typeof b==='string'){c=a.grouper;if(!c){a.grouper=new Ext.util.Grouper({property:b,direction:d||'ASC',root:'data'})}else {if(d===undefined){c.toggle()}else {c.setDirection(d)}}}else {a.grouper=b?a.getSorters().decodeSorter(b,'Ext.util.Grouper'):null}a.getData().clear();a.loadPage(1,{callback:function(){a.fireEvent('groupchange',a,a.getGrouper())}})},getPageFromRecordIndex:function(a){return Math.floor(a/this.getPageSize())+1},calculatePageCacheSize:function(c){var a=this,b=a.getPurgePageCount();return b?Math.max(a.getData().getMaxSize()||0,Math.ceil((c+a.getTrailingBufferZone()+a.getLeadingBufferZone())/a.getPageSize())*2+b):0},loadToPrefetch:function(b){var a=this,f=b,h,d,i,e=b.start,k=b.start+b.limit-1,m=a.getViewSize()||b.limit,c=Math.min(k,b.start+m-1),p=a.getPageFromRecordIndex(Math.max(e-a.getTrailingBufferZone(),0)),q=a.getPageFromRecordIndex(k+a.getLeadingBufferZone()),g=a.getData(),j=function(){d=d||[];if(b.loadCallback){b.loadCallback.call(b.scope||a,d,o,!0)}if(b.callback){b.callback.call(b.scope||a,d,e||0,k||0,b)}},n=function(){a.fireEvent('datachanged',a);a.fireEvent('refresh',a);a.fireEvent('load',a,d,!0)},l=function(){if(a.rangeCached(e,c)){a.loading=!1;d=g.getRange(e,c+1);g.un('pageadd',l);if(a.hasListeners.guaranteedrange){a.guaranteeRange(e,c,b.callback,b.scope)}j();n()}},o;g.setMaxSize(a.calculatePageCacheSize(m));if(a.fireEvent('beforeload',a,b)!==!1){delete a.totalCount;a.loading=!0;if(b.callback){f=Ext.apply({},b);delete f.callback}a.on('prefetch',function(m,e,d,k){o=k;if(d){if(i=a.getTotalCount()){g.on('pageadd',l);c=Math.min(c,i-1);q=a.getPageFromRecordIndex(Math.min(c+a.getLeadingBufferZone(),i-1));for(h=p+1;h<=q;++h){a.prefetchPage(h,f)}}else {j();n()}}else {a.loading=!1;j();a.fireEvent('load',a,e,!1)}},null,{single:!0});a.prefetchPage(p,f)}},prefetch:function(b){var a=this,c=a.getPageSize(),d=a.getData(),e,f;if(c){if(a.lastPageSize&&c!=a.lastPageSize){Ext.raise('pageSize cannot be dynamically altered')}if(!d.getPageSize()){d.setPageSize(c)}}else {a.pageSize=d.setPageSize(c=b.limit)}a.lastPageSize=c;if(!b.page){b.page=a.getPageFromRecordIndex(b.start);b.start=(b.page-1)*c;b.limit=Math.ceil(b.limit/c)*c}f=a.pageRequests[b.page];if(!f||f.getOperation().pageMapGeneration!==d.pageMapGeneration){b=Ext.apply({action:'read',filters:a.getFilters().items,sorters:a.getSorters().items,grouper:a.getGrouper(),internalCallback:a.onProxyPrefetch,internalScope:a},b);e=a.createOperation('read',b);e.pageMapGeneration=d.pageMapGeneration;if(a.fireEvent('beforeprefetch',a,e)!==!1){a.pageRequests[b.page]=e.execute();if(a.getProxy().isSynchronous){delete a.pageRequests[b.page]}}}return a},onPageMapClear:function(){var a=this,e=a.wasLoading,d=a.pageRequests,b=a.getData(),c;b.clearListeners();b.on('clear',a.onPageMapClear,a);a.relayEvents(b,['beforepageremove','pageadd','pageremove']);a.loading=!0;a.totalCount=0;for(c in d){if(d.hasOwnProperty(c)){d[c].getOperation().abort()}}a.fireEvent('clear',a);a.loading=e},prefetchPage:function(d,e){var a=this,b=a.getPageSize(),f=(d-1)*b,c=a.totalCount;if(c!==undefined&&a.data.getCount()===c){return}a.prefetch(Ext.applyIf({page:d,start:f,limit:b},e))},onProxyPrefetch:function(b){if(this.destroyed){return}var a=this,g=b.getResultSet(),e=b.getRecords(),d=b.wasSuccessful(),i=b.getPage(),c=b.waitForReload,k=a.totalCount,h=a.pageRequests,j,f;if(b.pageMapGeneration===a.getData().pageMapGeneration){if(g){a.totalCount=g.getTotal();if(a.totalCount!==k){a.fireEvent('totalcountchange',a.totalCount)}}if(i!==undefined){delete a.pageRequests[i]}a.loading=!1;a.fireEvent('prefetch',a,e,d,b);if(d){if(a.totalCount===0){if(c){for(j in h){f=h[j].getOperation();if(f.waitForReload===c){delete f.waitForReload}}a.getData().un('pageadd',c);a.fireEvent('load',a,[],!0);a.fireEvent('refresh',a)}}else {a.cachePage(e,b.getPage())}}Ext.callback(b.getCallback(),b.getScope()||a,[e,b,d])}},cachePage:function(b,d){var a=this,e=b.length,c;if(!Ext.isDefined(a.totalCount)){a.totalCount=b.length;a.fireEvent('totalcountchange',a.totalCount)}for(c=0;cf-1?f-1:a.prefetchEnd,d;b=Math.max(0,b);d=c.getData().getRange(e,b+1);if(a.fireEvent!==!1){c.fireEvent('guaranteedrange',d,e,b,a)}if(a.callback){a.callback.call(a.scope||c,d,e,b,a)}},guaranteeRange:function(d,e,b,c,a){a=Ext.apply({callback:b,scope:c},a);this.getRange(d,e+1,a)},prefetchRange:function(c,d){var a=this,e,f,b,g=a.getData();if(!a.rangeCached(c,d)){e=a.getPageFromRecordIndex(c);f=a.getPageFromRecordIndex(d);g.setMaxSize(a.calculatePageCacheSize(d-c+1));for(b=e;b<=f;b++){if(!a.pageCached(b)){a.prefetchPage(b)}}}},primeCache:function(a,b,g){var c=this,f=c.getLeadingBufferZone(),e=c.getTrailingBufferZone(),h=c.getPageSize(),d=c.totalCount;if(g===-1){a=Math.max(a-f,0);b=Math.min(b+e,d-1)}else {if(g===1){a=Math.max(Math.min(a-e,d-h),0);b=Math.min(b+f,d-1)}else {a=Math.min(Math.max(Math.floor(a-(f+e)/2),0),d-c.pageSize);b=Math.min(Math.max(Math.ceil(b+(f+e)/2),0),d-1)}}c.prefetchRange(a,b)},sort:function(b,a,c){if(arguments.length===0){this.clearAndLoad()}else {this.getSorters().addSort(b,a,c)}},onSorterEndUpdate:function(){var a=this,b=a.getSorters().getRange();if(b.length){a.fireEvent('beforesort',a,b);a.clearAndLoad({callback:function(){a.fireEvent('sort',a,b)}})}else {a.fireEvent('sort',a,b)}},clearAndLoad:function(a){this.getData().clear();this.loadPage(1,a)},privates:{isLast:function(a){return this.indexOf(a)===this.getTotalCount()-1},isMoving:function(){return !1}}},0,0,0,0,['store.buffered'],0,[Ext.data,'BufferedStore'],0);Ext.cmd.derive('Ext.data.NodeInterface',Ext.Base,{statics:{decorate:function(f){var a=Ext.data.schema.Schema.lookupEntity(f),e=a.prototype,c,b,d;if(!a.prototype.isObservable){a.mixin(Ext.mixin.Observable.prototype.mixinId,Ext.mixin.Observable)}if(e.isNode){return}c=e.idProperty;b=a.getField(c);d=b.type;a.override(this.getPrototypeBody());a.addFields([{name:'parentId',type:d,defaultValue:null,allowNull:b.allowNull},{name:'index',type:'int',defaultValue:-1,persist:!1,convert:null},{name:'depth',type:'int',defaultValue:0,persist:!1,convert:null},{name:'expanded',type:'bool',defaultValue:!1,persist:!1,convert:null},{name:'expandable',type:'bool',defaultValue:!0,persist:!1,convert:null},{name:'checked',type:'auto',defaultValue:null,persist:!1,convert:null},{name:'leaf',type:'bool',defaultValue:!1},{name:'cls',type:'string',defaultValue:'',persist:!1,convert:null},{name:'iconCls',type:'string',defaultValue:'',persist:!1,convert:null},{name:'icon',type:'string',defaultValue:'',persist:!1,convert:null},{name:'root',type:'boolean',defaultValue:!1,persist:!1,convert:null},{name:'isLast',type:'boolean',defaultValue:!1,persist:!1,convert:null},{name:'isFirst',type:'boolean',defaultValue:!1,persist:!1,convert:null},{name:'allowDrop',type:'boolean',defaultValue:!0,persist:!1,convert:null},{name:'allowDrag',type:'boolean',defaultValue:!0,persist:!1,convert:null},{name:'loaded',type:'boolean',defaultValue:!1,persist:!1,convert:null},{name:'loading',type:'boolean',defaultValue:!1,persist:!1,convert:null},{name:'href',type:'string',defaultValue:'',persist:!1,convert:null},{name:'hrefTarget',type:'string',defaultValue:'',persist:!1,convert:null},{name:'qtip',type:'string',defaultValue:'',persist:!1,convert:null},{name:'qtitle',type:'string',defaultValue:'',persist:!1,convert:null},{name:'qshowDelay',type:'int',defaultValue:0,persist:!1,convert:null},{name:'children',type:'auto',defaultValue:null,persist:!1,convert:null},{name:'visible',type:'boolean',defaultValue:!0,persist:!1},{name:'text',type:'string',persist:!1}])},getPrototypeBody:function(){var a={idchanged:!0,append:!0,remove:!0,move:!0,insert:!0,beforeappend:!0,beforeremove:!0,beforemove:!0,beforeinsert:!0,expand:!0,collapse:!0,beforeexpand:!0,beforecollapse:!0,sort:!0},b={silent:!0};return {isNode:!0,firstChild:null,lastChild:null,parentNode:null,previousSibling:null,nextSibling:null,constructor:function(){var a=this;a.mixins.observable.constructor.call(a);a.callParent(arguments);a.childNodes=[];return a},createNode:function(a){var b=this,j=b.childType,h,f,g,c,d,e,i=b.self;if(!a.isModel){if(j){i=b.schema.getEntity(j)}else {h=b.getTreeStore();f=h&&h.getProxy().getReader();g=b.getProxy();c=g?g.getReader():null;d=!f||c&&c.initialConfig.typeProperty?c:f;if(d){e=d.getTypeProperty();if(e){i=d.getChildType(b.schema,a,e)}}}a=new i(a)}if(!a.childNodes){a.firstChild=a.lastChild=a.parentNode=a.previousSibling=a.nextSibling=null;a.childNodes=[]}return a},isLeaf:function(){return this.get('leaf')===!0},setFirstChild:function(a){this.firstChild=a},setLastChild:function(a){this.lastChild=a},updateInfo:function(o,k){var a=this,i=a.data,r=i.depth,m={},n=a.childNodes,q=n.length,s=a.phantom,t=a.fields,c=a.modified||(a.modified={}),b,e,j,d,p,l=k.parentId,g,h,f;for(b in k){j=t[a.fieldOrdinals[b]];e=k[b];h=j&&j.persist;d=i[b];g=h&&b==='index'&&d!==-1&&(l&&l!==c.parentId);if(!g&&a.isEqual(d,e)){continue}i[b]=e;if(h){if(!g&&c.hasOwnProperty(b)){if(a.isEqual(c[b],e)){delete c[b];a.dirty=!1;for(p in c){if(c.hasOwnProperty(p)){a.dirty=!0;break}}}}else {a.dirty=!0;c[b]=d}}}if(o){a.commit();a.phantom=s}if(a.data.depth!==r){m={depth:a.data.depth+1};for(f=0;f0},isExpandable:function(){var a=this;if(a.get('expandable')){return !(a.isLeaf()||a.isLoaded()&&!a.phantom&&!a.hasChildNodes())}return !1},triggerUIUpdate:function(){this.callJoined('afterEdit',[])},appendChild:function(b,h,l){var a=this,j,m,c,e,f,k={isLast:!0,parentId:a.getId(),depth:(a.data.depth||0)+1},i,d=a.getTreeStore(),g=d&&d.bulkUpdate;Ext.suspendLayouts();if(Ext.isArray(b)){m=b.length;i=new Array(m);a.callTreeStore('beginFill');for(j=0;j0){if(!e){e=c.getTreeStore().getSortFn()}Ext.Array.sort(a,e);c.setFirstChild(a[0]);c.setLastChild(a[g-1]);for(b=0;b0){d.children=c=[];for(a=0;a1&&!a.getRemoteSort()&&a.getFolderSort()||j.length,e,h,c,d;if(a.needsLocalFilter()){d=a.getFilters().getFilterFn();b[0].set('visible',d(b[0]))}for(c=1;c')}else {b.push('>');if(c=a.tpl){c.applyOut(a.tplData,b)}if(c=a.html){b.push(c)}if(c=a.cn||a.children){e.generateMarkup(c,b)}h=e.closeTags;b.push(h[f]||(h[f]=''))}}}return b},generateStyles:function(c,d,f){var e=d||[],a,b;for(a in c){if(c.hasOwnProperty(a)){b=c[a];a=this.decamelizeName(a);if(f&&Ext.String.hasHtmlCharacters(b)){b=Ext.String.htmlEncode(b)}e.push(a,':',b,';')}}return d||e.join('')},markup:function(a){if(typeof a==='string'){return a}var b=this.generateMarkup(a,[]);return b.join('')},applyStyles:function(b,a){Ext.fly(b).applyStyles(a)},createContextualFragment:function(e){var d=this.detachedDiv,b=document.createDocumentFragment(),c,a;d.innerHTML=e;a=d.childNodes;c=a.length;while(c--){b.appendChild(a[0])}return b},createDom:function(e,f){var c=this,d=c.markup(e),b=c.detachedDiv,a;b.innerHTML=d;a=b.firstChild;return Ext.supports.ChildContentClearedWhenSettingInnerHTML?a.cloneNode(!0):a},insertHtml:function(g,f,j){var o=this,l,k,n,m,i;g=g.toLowerCase();if(f.insertAdjacentHTML){if(o.ieInsertHtml){i=o.ieInsertHtml(g,f,j);if(i){return i}}l=h[g];if(l){f.insertAdjacentHTML(l[0],j);return f[l[1]]}}else {if(f.nodeType===3){g=g===b?a:g;g=g===c?d:g}k=Ext.supports.CreateContextualFragment?f.ownerDocument.createRange():undefined;m='setStart'+(this.endRe.test(g)?'After':'Before');if(e[g]){if(k){k[m](f);i=k.createContextualFragment(j)}else {i=this.createContextualFragment(j)}f.parentNode.insertBefore(i,g===a?f:f.nextSibling);return f[(g===a?'previous':'next')+'Sibling']}else {n=(g===b?'first':'last')+'Child';if(f.firstChild){if(k){try{k[m](f[n]);i=k.createContextualFragment(j)}catch(p){i=this.createContextualFragment(j)}}else {i=this.createContextualFragment(j)}if(g===b){f.insertBefore(i,f.firstChild)}else {f.appendChild(i)}}else {f.innerHTML=j}return f[n]}}},insertBefore:function(c,d,b){return this.doInsert(c,d,b,a)},insertAfter:function(b,c,a){return this.doInsert(b,c,a,d)},insertFirst:function(c,d,a){return this.doInsert(c,d,a,b)},append:function(b,d,a){return this.doInsert(b,d,a,c)},overwrite:function(b,c,e){var d=this,a;b=Ext.getDom(b);c=d.markup(c);if(d.ieOverwrite){a=d.ieOverwrite(b,c)}if(!a){b.innerHTML=c;a=b.firstChild}return e?Ext.get(a):a},doInsert:function(f,j,k,g){var i=this,h;f=f.dom||Ext.getDom(f);if('innerHTML' in f){h=i.insertHtml(g,f,i.markup(j))}else {h=i.createDom(j,null);if(f.nodeType===3){g=g===b?a:g;g=g===c?d:g}if(e[g]){f.parentNode.insertBefore(h,g===a?f:f.nextSibling)}else {if(f.firstChild&&g===b){f.insertBefore(h,f.firstChild)}else {f.appendChild(h)}}}return k?Ext.get(h):h},createTemplate:function(b){var a=this.markup(b);return new Ext.Template(a)},createHtml:function(a){return this.markup(a)}}},0,0,0,0,0,0,[Ext.dom,'Helper',Ext,'DomHelper',Ext.core,'DomHelper'],0);Ext.define('Ext.overrides.dom.Helper',function(){var a=/^(?:table|thead|tbody|tr|td)$/i,f=/td|tr|tbody|thead/i,e='',d='
',c=e+'',b=''+d,h=c+'',g=''+b;return {override:'Ext.dom.Helper',ieInsertHtml:function(d,b,e){var c=null;if(Ext.isIE9m&&a.test(b.tagName)){c=this.insertIntoTable(b.tagName.toLowerCase(),d,b,e)}return c},ieOverwrite:function(b,c){if(Ext.isIE9m&&a.test(b.tagName)){while(b.firstChild){b.removeChild(b.firstChild)}if(c){return this.insertHtml('afterbegin',b,c)}}},ieTable:function(g,f,e,d){var h=-1,a=this.detachedDiv,b,c;a.innerHTML=[f,e,d].join('');while(++ha.interval){a.collect()}a.timerId=Ext.interval(a.collect,a.interval)}},1,0,0,0,0,0,[Ext.dom,'GarbageCollector'],0);Ext.cmd.derive('Ext.event.gesture.Recognizer',Ext.Base,{priority:0,handledEvents:[],config:{onRecognized:Ext.emptyFn,callbackScope:null},constructor:function(a){this.initConfig(a);Ext.event.publisher.Gesture.instance.registerRecognizer(this)},onStart:Ext.emptyFn,onEnd:Ext.emptyFn,onTouchStart:Ext.emptyFn,onTouchMove:Ext.emptyFn,onTouchEnd:Ext.emptyFn,onTouchCancel:Ext.emptyFn,fail:function(){return !1},fire:function(){this.getOnRecognized().apply(this.getCallbackScope(),arguments)},reset:Ext.emptyFn},1,0,0,0,0,[[Ext.mixin.Identifiable.prototype.mixinId||Ext.mixin.Identifiable.$className,Ext.mixin.Identifiable]],[Ext.event.gesture,'Recognizer'],0);Ext.cmd.derive('Ext.event.gesture.SingleTouch',Ext.event.gesture.Recognizer,{inheritableStatics:{NOT_SINGLE_TOUCH:'Not Single Touch',TOUCH_MOVED:'Touch Moved',EVENT_CANCELED:'Event Canceled'},onTouchStart:function(a){if(a.touches.length>1){return this.fail(this.self.NOT_SINGLE_TOUCH)}},onTouchCancel:function(){return !1}},0,0,0,0,0,0,[Ext.event.gesture,'SingleTouch'],0);Ext.cmd.derive('Ext.event.gesture.DoubleTap',Ext.event.gesture.SingleTouch,{priority:300,inheritableStatics:{DIFFERENT_TARGET:'Different Target'},config:{moveDistance:8,tapDistance:24,maxDuration:300},handledEvents:['singletap','doubletap'],singleTapTimer:null,startTime:0,lastTapTime:0,onTouchStart:function(c){var a=this,b;if(Ext.event.gesture.SingleTouch.prototype.onTouchStart.apply(this,arguments)===!1){return !1}b=a.lastStartPoint=c.changedTouches[0].point;a.startPoint=a.startPoint||b;a.startTime=c.time;clearTimeout(a.singleTapTimer)},onTouchMove:function(c){var a=this,b=c.changedTouches[0].point;if(Math.abs(b.getDistanceTo(a.lastStartPoint))>=a.getMoveDistance()){a.startPoint=null;return a.fail(a.self.TOUCH_MOVED)}},onTouchEnd:function(b){var a=this,f=a.getMaxDuration(),d=b.time,g=b.target,e=a.lastTapTime,h=a.lastTarget,i=b.changedTouches[0].point,c;a.lastTapTime=d;a.lastTarget=g;if(e){c=d-e;if(c<=f&&Math.abs(i.getDistanceTo(a.startPoint))<=a.getTapDistance()){if(g!==h){return a.fail(a.self.DIFFERENT_TARGET)}a.lastTarget=null;a.lastTapTime=0;a.fire('doubletap',b,{touch:b.changedTouches[0],duration:c});a.startPoint=null;return}}if(d-a.startTime>f){a.fireSingleTap(b)}else {a.setSingleTapTimer(b)}},setSingleTapTimer:function(b){var a=this;a.singleTapTimer=Ext.defer(function(){a.fireSingleTap(b)},a.getMaxDuration())},fireSingleTap:function(b,a){this.fire('singletap',b,{touch:a});this.startPoint=null},reset:function(){var a=this;a.startTime=a.lastTapTime=0;a.lastStartPoint=a.startPoint=a.singleTapTimer=null}},0,0,0,0,0,0,[Ext.event.gesture,'DoubleTap'],function(a){var b=Ext.manifest.gestures;a.instance=new a(b&&b.doubleTap)});Ext.cmd.derive('Ext.event.gesture.Drag',Ext.event.gesture.SingleTouch,{priority:100,isStarted:!1,startPoint:null,previousPoint:null,lastPoint:null,handledEvents:['dragstart','drag','dragend','dragcancel'],config:{minDistance:8},constructor:function(){Ext.event.gesture.SingleTouch.prototype.constructor.apply(this,arguments);this.initInfo()},initInfo:function(){this.info={touch:null,previous:{x:0,y:0},x:0,y:0,delta:{x:0,y:0},absDelta:{x:0,y:0},flick:{velocity:{x:0,y:0}},direction:{x:0,y:0},time:0,previousTime:{x:0,y:0}}},onTouchStart:function(a){if(Ext.event.gesture.SingleTouch.prototype.onTouchStart.apply(this,arguments)===!1){if(this.isStarted&&this.lastMoveEvent!==null){this.lastMoveEvent.isStopped=!1;this.onTouchEnd(this.lastMoveEvent)}return !1}this.startTime=a.time;this.startPoint=a.changedTouches[0].point},tryDragStart:function(a){var f=this.startPoint,b=a.changedTouches[0],c=b.point,e=this.getMinDistance(),d=this.info;if(Math.abs(c.getDistanceTo(f))>=e){this.isStarted=!0;this.previousPoint=this.lastPoint=c;this.resetInfo('x',a,b);this.resetInfo('y',a,b);d.time=a.time;this.fire('dragstart',a,d)}},onTouchMove:function(a){if(!this.isStarted){this.tryDragStart(a)}if(!this.isStarted){return}var b=a.changedTouches[0],c=b.point;if(this.lastPoint){this.previousPoint=this.lastPoint}this.lastPoint=c;this.lastMoveEvent=a;this.updateInfo('x',a,b);this.updateInfo('y',a,b);this.info.time=a.time;this.fire('drag',a,this.info)},onAxisDragEnd:function(b,a){var c=a.time-a.previousTime[b];if(c>0){a.flick.velocity[b]=(a[b]-a.previous[b])/c}},resetInfo:function(b,h,g){var f=this.lastPoint[b],d=this.startPoint[b],e=f-d,c=b.toUpperCase(),a=this.info;a.touch=g;a.delta[b]=e;a.absDelta[b]=Math.abs(e);a.previousTime[b]=this.startTime;a.previous[b]=d;a[b]=f;a.direction[b]=0;a['start'+c]=this.startPoint[b];a['previous'+c]=a.previous[b];a['page'+c]=a[b];a['delta'+c]=a.delta[b];a['absDelta'+c]=a.absDelta[b];a['previousDelta'+c]=0;a.startTime=this.startTime},updateInfo:function(b,l,k){var e=this,d=e.lastPoint[b],g=e.previousPoint[b],f=e.startPoint[b],i=d-f,a=e.info,h=a.direction,c=b.toUpperCase(),j=a.previous[b];a.touch=k;a.delta[b]=i;a.absDelta[b]=Math.abs(i);if(d!==j&&d!==a[b]){a.previous[b]=a[b];a.previousTime[b]=a.time}a[b]=d;if(d>g){h[b]=1}else {if(dthis.getMaxDuration()){return this.fail(this.self.MAX_DURATION_EXCEEDED)}if(this.isHorizontal&&d>this.getMaxOffset()){this.isHorizontal=!1}if(this.isVertical&&c>this.getMaxOffset()){this.isVertical=!1}if(!this.isVertical||!this.isHorizontal){if(this.isHorizontal&&cj){this.isVertical=!1}if(this.isHorizontal&&i>j){this.isHorizontal=!1}if(this.isVertical&&this.isHorizontal){if(i>h){this.isHorizontal=!1}else {this.isVertical=!1}}if(this.isHorizontal){a=f<0?'left':'right';b=f}else {if(this.isVertical){a=g<0?'up':'down';b=g}}a=this.direction||(this.direction=a);if(a==='up'){b=g*-1}else {if(a==='left'){b=f*-1}}this.distance=b;if(!b){return this.fail(this.self.DISTANCE_NOT_ENOUGH)}if(!this.started){if(a==='right'&&this.startX>d){return this.fail(this.self.NOT_NEAR_EDGE)}else {if(a==='down'&&this.startY>d){return this.fail(this.self.NOT_NEAR_EDGE)}else {if(a==='left'&&o-this.startX>d){return this.fail(this.self.NOT_NEAR_EDGE)}else {if(a==='up'&&n-this.startY>d){return this.fail(this.self.NOT_NEAR_EDGE)}}}}this.started=!0;this.startTime=c.time;this.fire('edgeswipestart',c,{touch:e,direction:a,distance:b,duration:k})}else {this.fire('edgeswipe',c,{touch:e,direction:a,distance:b,duration:k})}},onTouchEnd:function(a){var b;if(this.onTouchMove(a)!==!1){b=a.time-this.startTime;this.fire('edgeswipeend',a,{touch:a.changedTouches[0],direction:this.direction,distance:this.distance,duration:b})}},onTouchCancel:function(a){this.fire('edgeswipecancel',a,{touch:a.changedTouches[0]});return !1},reset:function(){var a=this;a.started=a.direction=a.isHorizontal=a.isVertical=a.startX=a.startY=a.startTime=a.distance=null}},0,0,0,0,0,0,[Ext.event.gesture,'EdgeSwipe'],function(a){var b=Ext.manifest.gestures;a.instance=new a(b&&b.edgeSwipe)});Ext.cmd.derive('Ext.event.gesture.LongPress',Ext.event.gesture.SingleTouch,{priority:400,inheritableStatics:{DURATION_NOT_ENOUGH:'Duration Not Enough'},config:{moveDistance:8,minDuration:1000},handledEvents:['longpress','taphold'],fireLongPress:function(a){this.fire('longpress',a,{touch:a.changedTouches[0],duration:this.getMinDuration()});this.isLongPress=!0},onTouchStart:function(a){if(Ext.event.gesture.SingleTouch.prototype.onTouchStart.apply(this,arguments)===!1){return !1}this.startPoint=a.changedTouches[0].point;this.isLongPress=!1;this.setLongPressTimer(a)},setLongPressTimer:function(b){var a=this;a.timer=Ext.defer(function(){a.fireLongPress(b)},a.getMinDuration())},onTouchMove:function(b){var a=b.changedTouches[0].point;if(Math.abs(a.getDistanceTo(this.startPoint))>=this.getMoveDistance()){return this.fail(this.self.TOUCH_MOVED)}},onTouchEnd:function(){if(!this.isLongPress){return this.fail(this.self.DURATION_NOT_ENOUGH)}},fail:function(){clearTimeout(this.timer);return Ext.event.gesture.SingleTouch.prototype.fail.apply(this,arguments)},reset:function(){this.isLongPress=this.startPoint=null},fire:function(b){if(b==='longpress'){var a=Array.prototype.slice.call(arguments);a[0]='taphold';this.fire.apply(this,a)}return Ext.event.gesture.SingleTouch.prototype.fire.apply(this,arguments)}},0,0,0,0,0,0,[Ext.event.gesture,'LongPress'],function(a){var b=Ext.manifest.gestures;a.instance=new a(b&&b.longPress)});Ext.cmd.derive('Ext.event.gesture.MultiTouch',Ext.event.gesture.Recognizer,{requiredTouchesCount:2,isTracking:!1,isStarted:!1,onTouchStart:function(a){var b=this.requiredTouchesCount,d=a.touches,c=d.length;if(c===b){this.start(a)}else {if(c>b){this.end(a)}}},onTouchEnd:function(a){this.end(a)},onTouchCancel:function(a){this.end(a,!0);return !1},start:function(){if(!this.isTracking){this.isTracking=!0;this.isStarted=!1}},end:function(b,a){if(this.isTracking){this.isTracking=!1;if(this.isStarted){this.isStarted=!1;this[a?'fireCancel':'fireEnd'](b)}}},reset:function(){this.isTracking=this.isStarted=!1}},0,0,0,0,0,0,[Ext.event.gesture,'MultiTouch'],0);Ext.cmd.derive('Ext.event.gesture.Pinch',Ext.event.gesture.MultiTouch,{priority:600,handledEvents:['pinchstart','pinch','pinchend','pinchcancel'],startDistance:0,lastTouches:null,onTouchMove:function(c){if(!this.isTracking){return}var b=c.touches,e,d,a;e=b[0].point;d=b[1].point;a=e.getDistanceTo(d);if(a===0){return}if(!this.isStarted){this.isStarted=!0;this.startDistance=a;this.fire('pinchstart',c,{touches:b,distance:a,scale:1})}else {this.fire('pinch',c,{touches:b,distance:a,scale:a/this.startDistance})}},fireEnd:function(a){this.fire('pinchend',a)},fireCancel:function(a){this.fire('pinchcancel',a)},fail:function(){return Ext.event.gesture.MultiTouch.prototype.fail.apply(this,arguments)},reset:function(){this.lastTouches=null;this.startDistance=0;Ext.event.gesture.MultiTouch.prototype.reset.call(this)}},0,0,0,0,0,0,[Ext.event.gesture,'Pinch'],function(b){var a=Ext.manifest.gestures;b.instance=new b(a&&a.pinch)});Ext.cmd.derive('Ext.event.gesture.Rotate',Ext.event.gesture.MultiTouch,{priority:700,handledEvents:['rotatestart','rotate','rotateend','rotatecancel'],startAngle:0,lastTouches:null,lastAngle:null,onTouchMove:function(g){if(!this.isTracking){return}var b=g.touches,c=this.lastAngle,i,h,a,e,d,f;i=b[0].point;h=b[1].point;a=i.getAngleTo(h);if(c!==null){f=Math.abs(c-a);e=a+360;d=a-360;if(Math.abs(e-c)=this.getMoveDistance()){this.fire('tapcancel',b,{touch:a});return this.fail(this.self.TOUCH_MOVED)}},onTouchEnd:function(a){this.fire('tap',a,{touch:a.changedTouches[0]})},onTouchCancel:function(a){this.fire('tapcancel',a,{touch:a.changedTouches[0]});return !1},reset:function(){this.startPoint=null}},0,0,0,0,0,0,[Ext.event.gesture,'Tap'],function(b){var a=Ext.manifest.gestures;b.instance=new b(a&&a.tap)});Ext.cmd.derive('Ext.event.publisher.Focus',Ext.event.publisher.Dom,{type:'focus',handledEvents:['focusenter','focusleave','focusmove'],handledDomEvents:['focusin','focusout'],doDelegatedEvent:function(a,c){var d=this,b;a=Ext.event.publisher.Dom.prototype.doDelegatedEvent.call(this,a,!1);if(a){if(a.type==='focusout'){if(a.relatedTarget==null){d.processFocusIn(a,a.target,document.body,c)}}else {b=a.relatedTarget;d.processFocusIn(a,b==null||!b.tagName?document.body:b,a.target,c)}}},processFocusIn:function(i,d,e,l){var c=this,h,a,b=[],f,g,j,k;j=Ext.fly(d);k=Ext.fly(e);if(j&&j.isFocusSuspended()||k&&k.isFocusSuspended()){return}for(a=d,h=Ext.dom.Element.getCommonAncestor(e,d,!0);a&&a!==h;a=a.parentNode){b.push(a)}if(b.length){f=c.createSyntheticEvent('focusleave',i,d,e);c.publish('focusleave',b,f);if(f.isStopped){return}}b.length=0;for(a=e;a!==h;a=a.parentNode){b.push(a)}g=c.createSyntheticEvent('focusenter',i,e,d);if(b.length){c.publish('focusenter',b,g);if(g.isStopped){return}}b=c.getPropagatingTargets(h);if(b.length){f=c.createSyntheticEvent('focusmove',i,e,d);c.publish('focusmove',b,f);if(f.isStopped){return}}if(l){c.afterEvent(i)}Ext.GlobalEvents.fireEvent('focus',{event:g,toElement:e,fromElement:d})},createSyntheticEvent:function(d,c,e,b){var a=new Ext.event.Event(c);a.type=d;a.relatedTarget=b;a.target=e;return a}},0,0,0,0,0,0,[Ext.event.publisher,'Focus'],function(a){var b;a.instance=new a();if(!Ext.supports.FocusinFocusoutEvents){this.override({handledDomEvents:['focus','blur'],doDelegatedEvent:function(c,e){var d=this;c=d.callSuper([c,!1]);if(c){clearTimeout(b);b=0;if(c.type==='blur'){var f=c.target===window?document.body:c.target;b=setTimeout(function(){b=0;d.processFocusIn(c,f,document.body,e);a.previousActiveElement=null},0);if(c.target===window||c.target===document){a.previousActiveElement=null}else {a.previousActiveElement=c.target}}else {d.processFocusIn(c,a.previousActiveElement||document.body,c.target===window?document.body:c.target,e)}}}})}});Ext.cmd.derive('Ext.fx.State',Ext.Base,{isAnimatable:{'background-color':!0,'background-image':!0,'background-position':!0,'border-bottom-color':!0,'border-bottom-width':!0,'border-color':!0,'border-left-color':!0,'border-left-width':!0,'border-right-color':!0,'border-right-width':!0,'border-spacing':!0,'border-top-color':!0,'border-top-width':!0,'border-width':!0,'bottom':!0,'color':!0,'crop':!0,'font-size':!0,'font-weight':!0,'height':!0,'left':!0,'letter-spacing':!0,'line-height':!0,'margin-bottom':!0,'margin-left':!0,'margin-right':!0,'margin-top':!0,'max-height':!0,'max-width':!0,'min-height':!0,'min-width':!0,'opacity':!0,'outline-color':!0,'outline-offset':!0,'outline-width':!0,'padding-bottom':!0,'padding-left':!0,'padding-right':!0,'padding-top':!0,'right':!0,'text-indent':!0,'text-shadow':!0,'top':!0,'vertical-align':!0,'visibility':!0,'width':!0,'word-spacing':!0,'z-index':!0,'zoom':!0,'transform':!0},constructor:function(a){this.data={};this.set(a)},setConfig:function(a){this.set(a);return this},setRaw:function(a){this.data=a;return this},clear:function(){return this.setRaw({})},setTransform:function(d,a){var g=this.data,e=Ext.isArray(a),b=g.transform,c,f;if(!b){b=g.transform={translateX:0,translateY:0,translateZ:0,scaleX:1,scaleY:1,scaleZ:1,rotate:0,rotateX:0,rotateY:0,rotateZ:0,skewX:0,skewY:0}}if(typeof d=='string'){switch(d){case 'translate':if(e){c=a.length;if(c==0){break}b.translateX=a[0];if(c==1){break}b.translateY=a[1];if(c==2){break}b.translateZ=a[2]}else {b.translateX=a};break;case 'rotate':if(e){c=a.length;if(c==0){break}b.rotateX=a[0];if(c==1){break}b.rotateY=a[1];if(c==2){break}b.rotateZ=a[2]}else {b.rotate=a};break;case 'scale':if(e){c=a.length;if(c==0){break}b.scaleX=a[0];if(c==1){break}b.scaleY=a[1];if(c==2){break}b.scaleZ=a[2]}else {b.scaleX=a;b.scaleY=a};break;case 'skew':if(e){c=a.length;if(c==0){break}b.skewX=a[0];if(c==1){break}b.skewY=a[1]}else {b.skewX=a};break;default:b[d]=a;}}else {for(f in d){if(d.hasOwnProperty(f)){a=d[f];this.setTransform(f,a)}}}},set:function(b,a){var d=this.data,c;if(typeof b!='string'){for(c in b){a=b[c];if(c==='transform'){this.setTransform(a)}else {d[c]=a}}}else {if(b==='transform'){this.setTransform(a)}else {d[b]=a}}return this},unset:function(b){var a=this.data;if(a.hasOwnProperty(b)){delete a[b]}return this},getData:function(){return this.data}},1,0,0,0,0,0,[Ext.fx,'State'],0);Ext.cmd.derive('Ext.fx.animation.Abstract',Ext.Evented,{isAnimation:!0,config:{name:'',element:null,before:null,from:{},to:{},after:null,states:{},duration:300,easing:'linear',iteration:1,direction:'normal',delay:0,onBeforeStart:null,callback:null,onEnd:null,onBeforeEnd:null,scope:null,reverse:null,preserveEndState:!1,replacePrevious:!0},STATE_FROM:'0%',STATE_TO:'100%',DIRECTION_UP:'up',DIRECTION_DOWN:'down',DIRECTION_LEFT:'left',DIRECTION_RIGHT:'right',stateNameRegex:/^(?:[\d\.]+)%$/,constructor:function(){this.states={};Ext.Evented.prototype.constructor.apply(this,arguments);return this},applyElement:function(a){return Ext.get(a)},applyBefore:function(a,b){if(a){return Ext.factory(a,Ext.fx.State,b)}},applyAfter:function(a,b){if(a){return Ext.factory(a,Ext.fx.State,b)}},setFrom:function(a){return this.setState(this.STATE_FROM,a)},setTo:function(a){return this.setState(this.STATE_TO,a)},getFrom:function(){return this.getState(this.STATE_FROM)},getTo:function(){return this.getState(this.STATE_TO)},setStates:function(b){var c=this.stateNameRegex,a;for(a in b){if(c.test(a)){this.setState(a,b[a])}}return this},getStates:function(){return this.states},updateCallback:function(a){if(a){this.setOnEnd(a)}},end:function(){this.stop()},stop:function(){this.fireEvent('stop',this)},destroy:function(){this.stop();Ext.Evented.prototype.destroy.call(this)},setState:function(c,d){var b=this.getStates(),a;a=Ext.factory(d,Ext.fx.State,b[c]);if(a){b[c]=a}return this},getState:function(a){return this.getStates()[a]},getData:function(){var a=this,b=a.getStates(),d={},e=a.getBefore(),f=a.getAfter(),k=b[a.STATE_FROM],l=b[a.STATE_TO],i=k.getData(),j=l.getData(),h,c,g;for(c in b){if(b.hasOwnProperty(c)){g=b[c];h=g.getData();d[c]=h}}return {before:e?e.getData():{},after:f?f.getData():{},states:d,from:i,to:j,duration:a.getDuration(),iteration:a.getIteration(),direction:a.getDirection(),easing:a.getEasing(),delay:a.getDelay(),onEnd:a.getOnEnd(),onBeforeEnd:a.getOnBeforeEnd(),onBeforeStart:a.getOnBeforeStart(),scope:a.getScope(),preserveEndState:a.getPreserveEndState(),replacePrevious:a.getReplacePrevious()}}},1,0,0,0,0,0,[Ext.fx.animation,'Abstract'],0);Ext.cmd.derive('Ext.fx.animation.Slide',Ext.fx.animation.Abstract,{alternateClassName:'Ext.fx.animation.SlideIn',config:{direction:'left',out:!1,offset:0,easing:'auto',containerBox:'auto',elementBox:'auto',isElementBoxFit:!0,useCssTransform:!0},reverseDirectionMap:{up:'down',down:'up',left:'right',right:'left'},applyEasing:function(a){if(a==='auto'){return 'ease-'+(this.getOut()?'in':'out')}return a},getContainerBox:function(){var a=this._containerBox;if(a==='auto'){a=this.getElement().getParent().getBox()}return a},getElementBox:function(){var a=this._elementBox;if(this.getIsElementBoxFit()){return this.getContainerBox()}if(a==='auto'){a=this.getElement().getBox()}return a},getData:function(){var o=this.getElementBox(),b=this.getContainerBox(),a=o?o:b,j=this.getFrom(),m=this.getTo(),d=this.getOut(),c=this.getOffset(),g=this.getDirection(),n=this.getUseCssTransform(),p=this.getReverse(),e=0,f=0,h,i,k,l;if(p){g=this.reverseDirectionMap[g]}switch(g){case this.DIRECTION_UP:if(d){f=b.top-a.top-a.height-c}else {f=b.bottom-a.bottom+a.height+c};break;case this.DIRECTION_DOWN:if(d){f=b.bottom-a.bottom+a.height+c}else {f=b.top-a.height-a.top-c};break;case this.DIRECTION_RIGHT:if(d){e=b.right-a.right+a.width+c}else {e=b.left-a.left-a.width-c};break;case this.DIRECTION_LEFT:if(d){e=b.left-a.left-a.width-c}else {e=b.right-a.right+a.width+c};break;}h=d?0:e;i=d?0:f;if(n){j.setTransform({translateX:h,translateY:i})}else {j.set('left',h);j.set('top',i)}k=d?e:0;l=d?f:0;if(n){m.setTransform({translateX:k,translateY:l})}else {m.set('left',k);m.set('top',l)}return Ext.fx.animation.Abstract.prototype.getData.apply(this,arguments)}},0,0,0,0,['animation.slide','animation.slideIn'],0,[Ext.fx.animation,'Slide',Ext.fx.animation,'SlideIn'],0);Ext.cmd.derive('Ext.fx.animation.SlideOut',Ext.fx.animation.Slide,{config:{out:!0}},0,0,0,0,['animation.slideOut'],0,[Ext.fx.animation,'SlideOut'],0);Ext.cmd.derive('Ext.fx.animation.Fade',Ext.fx.animation.Abstract,{alternateClassName:'Ext.fx.animation.FadeIn',config:{out:!1,before:{display:null,opacity:0},after:{opacity:null},reverse:null},updateOut:function(c){var b=this.getTo(),a=this.getFrom();if(c){a.set('opacity',1);b.set('opacity',0)}else {a.set('opacity',0);b.set('opacity',1)}}},0,0,0,0,['animation.fade','animation.fadeIn'],0,[Ext.fx.animation,'Fade',Ext.fx.animation,'FadeIn'],0);Ext.cmd.derive('Ext.fx.animation.FadeOut',Ext.fx.animation.Fade,{config:{out:!0,before:{}}},0,0,0,0,['animation.fadeOut'],0,[Ext.fx.animation,'FadeOut'],0);Ext.cmd.derive('Ext.fx.animation.Flip',Ext.fx.animation.Abstract,{config:{easing:'ease-in',direction:'right',half:!1,out:null},getData:function(){var c=this,k=c.getFrom(),m=c.getTo(),j=c.getDirection(),b=c.getOut(),l=c.getHalf(),a=l?90:180,h=1,i=1,d=0,e=0,f=0,g=0;if(b){i=0.8}else {h=0.8}switch(j){case this.DIRECTION_UP:if(b){f=a}else {d=-a};break;case this.DIRECTION_DOWN:if(b){f=-a}else {d=a};break;case this.DIRECTION_RIGHT:if(b){g=a}else {e=-a};break;case this.DIRECTION_LEFT:if(b){g=-a}else {e=a};break;}k.setTransform({rotateX:d,rotateY:e,scale:h});m.setTransform({rotateX:f,rotateY:g,scale:i});return Ext.fx.animation.Abstract.prototype.getData.call(this)}},0,0,0,0,['animation.flip'],0,[Ext.fx.animation,'Flip'],0);Ext.cmd.derive('Ext.fx.animation.Pop',Ext.fx.animation.Abstract,{alternateClassName:'Ext.fx.animation.PopIn',config:{out:!1,before:{display:null,opacity:0},after:{opacity:null}},getData:function(){var b=this.getTo(),a=this.getFrom(),c=this.getOut();if(c){a.set('opacity',1);a.setTransform({scale:1});b.set('opacity',0);b.setTransform({scale:0})}else {a.set('opacity',0);a.setTransform({scale:0});b.set('opacity',1);b.setTransform({scale:1})}return Ext.fx.animation.Abstract.prototype.getData.apply(this,arguments)}},0,0,0,0,['animation.pop','animation.popIn'],0,[Ext.fx.animation,'Pop',Ext.fx.animation,'PopIn'],0);Ext.cmd.derive('Ext.fx.animation.PopOut',Ext.fx.animation.Pop,{config:{out:!0,before:{}}},0,0,0,0,['animation.popOut'],0,[Ext.fx.animation,'PopOut'],0);Ext.cmd.derive('Ext.fx.Animation',Ext.Base,{constructor:function(a){var c=Ext.fx.animation.Abstract,b;if(typeof a=='string'){b=a;a={}}else {if(a&&a.type){b=a.type}}if(b){c=Ext.ClassManager.getByAlias('animation.'+b)}return Ext.factory(a,c)}},1,0,0,0,0,0,[Ext.fx,'Animation'],0);Ext.cmd.derive('Ext.fx.runner.Css',Ext.Evented,{prefixedProperties:{'transform':!0,'transform-origin':!0,'perspective':!0,'transform-style':!0,'transition':!0,'transition-property':!0,'transition-duration':!0,'transition-timing-function':!0,'transition-delay':!0,'animation':!0,'animation-name':!0,'animation-duration':!0,'animation-iteration-count':!0,'animation-direction':!0,'animation-timing-function':!0,'animation-delay':!0},lengthProperties:{'top':!0,'right':!0,'bottom':!0,'left':!0,'width':!0,'height':!0,'max-height':!0,'max-width':!0,'min-height':!0,'min-width':!0,'margin-bottom':!0,'margin-left':!0,'margin-right':!0,'margin-top':!0,'padding-bottom':!0,'padding-left':!0,'padding-right':!0,'padding-top':!0,'border-bottom-width':!0,'border-left-width':!0,'border-right-width':!0,'border-spacing':!0,'border-top-width':!0,'border-width':!0,'outline-width':!0,'letter-spacing':!0,'line-height':!0,'text-indent':!0,'word-spacing':!0,'font-size':!0,'translate':!0,'translateX':!0,'translateY':!0,'translateZ':!0,'translate3d':!0},durationProperties:{'transition-duration':!0,'transition-delay':!0,'animation-duration':!0,'animation-delay':!0},angleProperties:{rotate:!0,rotateX:!0,rotateY:!0,rotateZ:!0,skew:!0,skewX:!0,skewY:!0},lengthUnitRegex:/([a-z%]*)$/,DEFAULT_UNIT_LENGTH:'px',DEFAULT_UNIT_ANGLE:'deg',DEFAULT_UNIT_DURATION:'ms',formattedNameCache:{},transformMethods3d:['translateX','translateY','translateZ','rotate','rotateX','rotateY','rotateZ','skewX','skewY','scaleX','scaleY','scaleZ'],transformMethodsNo3d:['translateX','translateY','rotate','skewX','skewY','scaleX','scaleY'],constructor:function(){var a=this;a.transformMethods=Ext.feature.has.Css3dTransforms?a.transformMethods3d:a.transformMethodsNo3d;a.vendorPrefix=Ext.browser.getStyleDashPrefix();a.ruleStylesCache={};Ext.Evented.prototype.constructor.call(this)},getStyleSheet:function(){var c=this.styleSheet,a,b;if(!c){a=document.createElement('style');a.type='text/css';(document.head||document.getElementsByTagName('head')[0]).appendChild(a);b=document.styleSheets;this.styleSheet=c=b[b.length-1]}return c},applyRules:function(j){var i=this.getStyleSheet(),h=this.ruleStylesCache,k=i.cssRules,d,g,b,c,f,a,e;for(d in j){g=j[d];b=h[d];if(b===undefined){f=k.length;i.insertRule(d+'{}',f);b=h[d]=k.item(f).style}c=b.$cache;if(!c){c=b.$cache={}}for(a in g){e=this.formatValue(g[a],a);a=this.formatName(a);if(c[a]!==e){c[a]=e;if(e===null){b.removeProperty(a)}else {b.setProperty(a,e,'important')}}}}return this},applyStyles:function(f){var c,e,d,b,a,g;for(c in f){if(f.hasOwnProperty(c)){e=document.getElementById(c);if(!e){continue}d=e.style;b=f[c];for(a in b){if(b.hasOwnProperty(a)){g=this.formatValue(b[a],a);a=this.formatName(a);if(g===null){d.removeProperty(a)}else {d.setProperty(a,g,'important')}}}}}return this},formatName:function(b){var c=this.formattedNameCache,a=c[b];if(!a){if((Ext.os.is.Tizen||!Ext.feature.has.CssTransformNoPrefix)&&this.prefixedProperties[b]){a=this.vendorPrefix+b}else {a=b}c[b]=a}return a},formatValue:function(a,c){var j=typeof a,i=this.DEFAULT_UNIT_LENGTH,g,d,b,f,h,e,k;if(a===null){return ''}if(j=='string'){if(this.lengthProperties[c]){k=a.match(this.lengthUnitRegex)[1];if(k.length>0){}else {return a+i}}return a}else {if(j=='number'){if(a==0){return '0'}if(this.lengthProperties[c]){return a+i}if(this.angleProperties[c]){return a+this.DEFAULT_UNIT_ANGLE}if(this.durationProperties[c]){return a+this.DEFAULT_UNIT_DURATION}}else {if(c==='transform'){g=this.transformMethods;h=[];for(b=0,f=g.length;b0?e.join(', '):'none'}}}}return a}},1,0,0,0,0,0,[Ext.fx.runner,'Css'],0);Ext.cmd.derive('Ext.fx.runner.CssTransition',Ext.fx.runner.Css,{alternateClassName:'Ext.Animator',singleton:!0,listenersAttached:!1,constructor:function(){this.runningAnimationsData={};return this.callParent(arguments)},attachListeners:function(){this.listenersAttached=!0;Ext.getWin().on('transitionend','onTransitionEnd',this)},onTransitionEnd:function(c){var a=c.target,b=a.id;if(b&&this.runningAnimationsData.hasOwnProperty(b)){this.refreshRunningAnimationsData(Ext.get(a),[c.browserEvent.propertyName])}},onAnimationEnd:function(d,a,b,c,n){var l=d.getId(),j=this.runningAnimationsData[l],k={},h={},g,f,e,m,i;b.un('stop','onAnimationStop',this);if(j){g=j.nameMap}k[l]=h;if(a.onBeforeEnd){a.onBeforeEnd.call(a.scope||this,d,c)}b.fireEvent('animationbeforeend',b,d,c);this.fireEvent('animationbeforeend',this,b,d,c);if(n||!c&&!a.preserveEndState){f=a.toPropertyNames;for(e=0,m=f.length;e0},refreshRunningAnimationsData:function(i,m,f,g){var s=i.getId(),r=this.runningAnimationsData,e=r[s];if(!e){return}var o=e.nameMap,n=e.nameList,c=e.sessions,h,j,p,d,b,a,k,q,l=!1;f=Boolean(f);g=Boolean(g);if(!c){return this}h=c.length;if(h===0){return this}if(g){e.nameMap={};n.length=0;for(b=0;b');b.close();this.testElement=c=b.createElement('div');c.style.setProperty('position','absolute','important');b.body.appendChild(c);this.testElementComputedStyle=window.getComputedStyle(c)}return c},getCssStyleValue:function(b,a){var c=this.getTestElement(),e=this.testElementComputedStyle,d=c.style;d.setProperty(b,a);if(Ext.browser.is.Firefox){c.offsetHeight}a=e.getPropertyValue(b);d.removeProperty(b);return a},run:function(t){var a=this,H=a.lengthProperties,E={},j={},d={},i,f,m,k,F,g,e,u,v,s,r,w,x,G,c,o,y,C,h,b,l,D,n,z,q,p,A,B;if(!a.listenersAttached){a.attachListeners()}t=Ext.Array.from(t);for(w=0,G=t.length;w0){a.refreshRunningAnimationsData(i,Ext.Array.merge(g,e),!0,d.replacePrevious)}q=s.nameMap;p=s.nameList;y={};for(x=0;x0){g=Ext.Array.difference(p,g);e=Ext.Array.merge(g,e);r['transition-property']=g}E[f]=r;j[f]=Ext.apply({},k);j[f]['transition-property']=e;j[f]['transition-duration']=d.duration;j[f]['transition-timing-function']=d.easing;j[f]['transition-delay']=d.delay;c.startTime=Date.now()}v=a.$className;a.applyStyles(E);u=function(b){if(b.data===v&&b.source===window){window.removeEventListener('message',u,!1);a.applyStyles(j)}};if(window.requestAnimationFrame){window.requestAnimationFrame(function(){window.addEventListener('message',u,!1);window.postMessage(v,'*')})}else {Ext.defer(function(){window.addEventListener('message',u,!1);window.postMessage(v,'*')},1)}},onAnimationStop:function(h){var c=this.runningAnimationsData,e,f,d,b,g,a;for(e in c){if(c.hasOwnProperty(e)){f=c[e];d=f.sessions;for(b=0,g=d.length;b'){this.isParentReference=!0;a=a.substring(0,b)}return a}}},0,0,0,0,0,0,[Ext.mixin,'Container'],0);Ext.cmd.derive('Ext.mixin.Responsive',Ext.Mixin,function(a){return {mixinConfig:{id:'responsive',after:{destroy:'destroy'}},config:{responsiveConfig:{$value:undefined,merge:function(c,d,g,f){if(!c){return d}var e=d?Ext.Object.chain(d):{},b;for(b in c){if(!f||!(b in e)){e[b]={fn:null,config:c[b]}}}return e}},responsiveFormulas:{$value:0,merge:function(c,d,e,b){return this.mergeNew(c,d,e,b)}}},destroy:function(){a.unregister(this);this.callParent()},privates:{statics:{active:!1,all:{},context:Ext.Object.chain(Ext.platformTags),count:0,nextId:0,activate:function(){a.active=!0;a.updateContext();Ext.on('resize',a.onResize,a)},deactivate:function(){a.active=!1;Ext.un('resize',a.onResize,a)},notify:function(){var b=a.all,e=a.context,d=Ext.GlobalEvents,f=a.timer,c;if(f){a.timer=null;Ext.Function.cancelAnimationFrame(f)}a.updateContext();Ext.suspendLayouts();d.fireEvent('beforeresponsiveupdate',e);for(c in b){b[c].setupResponsiveContext()}d.fireEvent('beginresponsiveupdate',e);for(c in b){b[c].updateResponsiveState()}d.fireEvent('responsiveupdate',e);Ext.resumeLayouts(!0)},onResize:function(){if(!a.timer){a.timer=Ext.Function.requestAnimationFrame(a.onTimer)}},onTimer:function(){a.timer=null;a.notify()},processConfig:function(c,d,b){var g=d&&d[b],f=c.config,h,e;if(g){e=c.getConfigurator();h=e.configs[b];f[b]=h.merge(g,f[b],c)}},register:function(b){var c=b.$responsiveId;if(!c){b.$responsiveId=c=++a.nextId;a.all[c]=b;if(++a.count===1){a.activate()}}},unregister:function(b){var c=b.$responsiveId;if(c in a.all){b.$responsiveId=null;delete a.all[c];if(--a.count===0){a.deactivate()}}},updateContext:function(){var e=Ext.Element,d=e.getViewportWidth(),c=e.getViewportHeight(),b=a.context;b.width=d;b.height=c;b.tall=d','',' ({childCount} children)','','',' ({depth} deep)','','',', {type}: {[this.time(values.sum)]} msec (','avg={[this.time(values.sum / parent.count)]}',')','',''].join(''),{time:function(a){return Math.round(a*100)/100}})}var a=this.getData(b);a.name=this.name;a.pure.type='Pure';a.total.type='Total';a.times=[a.pure,a.total];return c.apply(a)},getData:function(b){var a=this;return {count:a.count,childCount:a.childCount,depth:a.maxDepth,pure:setToJSON(a.count,a.childCount,b,a.pure),total:setToJSON(a.count,a.childCount,b,a.total)}},enter:function(){var c=this,d={accum:c,leave:leaveFrame,childTime:0,parent:b};++c.depth;if(c.maxDepth0){d=a==='this'?this:typeof a==='string'?this[a]:typeof a==='number'?arguments[a]:null;if(d){f=d.id}if(f!=null){console.log(b+' for '+f+': '+c+'ms')}else {console.log(b+' for unknown: '+c+'ms')}if(console.trace){console.trace()}}return h}}(b,d[b])}Ext.override(f,c)}}}}},1,0,0,0,0,0,[Ext.perf,'Monitor',Ext,'Perf'],0);Ext.cmd.derive('Ext.plugin.Abstract',Ext.Base,{alternateClassName:'Ext.AbstractPlugin',isPlugin:!0,constructor:function(a){if(a){this.pluginConfig=a;this.initConfig(a)}},clonePlugin:function(a){return new this.self(Ext.apply({},a,this.pluginConfig))},setCmp:function(a){this.cmp=a},getCmp:function(){return this.cmp},init:Ext.emptyFn,destroy:function(){this.cmp=this.pluginConfig=null;this.callParent()},onClassExtended:function(c,b,d){var a=b.alias;if(a&&!b.ptype){if(Ext.isArray(a)){a=a[0]}c.prototype.ptype=a.split('plugin.')[1]}},resolveListenerScope:function(b){var a=this,d=a.getCmp(),c;if(d){c=d.resolveSatelliteListenerScope(a,b)}return c||a.mixins.observable.resolveListenerScope.call(a,b)}},1,0,0,0,0,0,[Ext.plugin,'Abstract',Ext,'AbstractPlugin'],0);Ext.define('Ext.overrides.plugin.Abstract',{override:'Ext.plugin.Abstract',$configStrict:!1,$configPrefixed:!1,disabled:!1,getState:null,applyState:null,enable:function(){this.disabled=!1},disable:function(){this.disabled=!0}});Ext.cmd.derive('Ext.util.ItemCollection',Ext.util.MixedCollection,{alternateClassName:'Ext.ItemCollection',getKey:function(a){return a.getItemId&&a.getItemId()},has:function(a){return this.map.hasOwnProperty(a.getId())}},0,0,0,0,0,0,[Ext.util,'ItemCollection',Ext,'ItemCollection'],0);Ext.cmd.derive('Ext.util.TaskManager',Ext.util.TaskRunner,{alternateClassName:['Ext.TaskManager'],singleton:!0},0,0,0,0,0,0,[Ext.util,'TaskManager',Ext,'TaskManager'],0);Ext.cmd.derive('Ext.util.TextMetrics',Ext.Base,{statics:{shared:null,measure:function(d,e,c){var b=this,a=b.shared;if(!a){a=b.shared=new b(d,c)}a.bind(d);a.setFixedWidth(c||'auto');return a.getSize(e)},destroy:function(){var a=this;Ext.destroy(a.shared);a.shared=null}},constructor:function(c,b){var d=this,a=Ext.getBody().createChild({role:'presentation',cls:'x-textmetrics'});a.setVisibilityMode(1);d.measure=a;if(c){d.bind(c)}a.position('absolute');a.setLocalXY(-1000,-1000);a.hide();if(b){a.setWidth(b)}},getSize:function(c){var a=this.measure,b;a.setHtml(c);b=a.getSize();a.setHtml('');return b},bind:function(b){var a=this;a.el=Ext.get(b);a.measure.setStyle(a.el.getStyle(['font-size','font-style','font-weight','font-family','line-height','text-transform','letter-spacing','word-break']))},setFixedWidth:function(a){this.measure.setWidth(a)},getWidth:function(a){this.measure.dom.style.width='auto';return this.getSize(a).width},getHeight:function(a){return this.getSize(a).height},destroy:function(){var a=this;a.el=a.measure=Ext.destroy(a.measure);a.callParent()}},1,0,0,0,0,0,[Ext.util,'TextMetrics'],function(){Ext.Element.override({getTextWidth:function(a,c,b){return Ext.Number.constrain(Ext.util.TextMetrics.measure(this.dom,Ext.valueFrom(a,this.dom.innerHTML,!0)).width,c||0,b||1000000)}})});Ext.define(null,{override:'Ext.event.publisher.Focus',compatibility:Ext.isIE10m,doDelegatedEvent:function(a,d){var c=document.body,b=Ext.synchronouslyFocusing;if(b&&(a.type==='focusout'&&a.srcElement===b&&a.toElement===c||a.type==='focusin'&&a.srcElement===c&&a.fromElement===b&&a.toElement===null)){return}return this.callParent([a,d])}});Ext.define(null,{override:'Ext.scroll.DomScroller',compatibility:Ext.isIE8,privates:{doScrollTo:function(a,b,j){var c=this,f=c.getElement(),e,d,i,g,h;if(f&&!f.destroyed){d=this.getElement().dom;g=a===Infinity;h=b===Infinity;if(g||h){e=c.getMaxPosition();if(g){a=e.x}if(h){b=e.y}}a=c.convertX(a);if(j){i={};if(b!=null){i.scrollTop=b}if(a!=null){i.scrollLeft=a}f.animate(Ext.mergeIf({to:{scrollTop:b,scrollLeft:a}},j))}else {if(a!=null&&b!=null){c.deferDomScroll=!0}if(b!=null){d.scrollTop=b}if(a!=null){d.scrollLeft=a}if(c.deferDomScroll){c.deferDomScroll=!1;+d.scrollLeft;d.scrollLeft=a}}c.positionDirty=!0}},onDomScroll:function(){var a=this;if(a.deferDomScroll){return}a.callParent()}}});Ext.cmd.derive('Ext.ElementLoader',Ext.Base,{statics:{Renderer:{Html:function(c,b,a){c.getTarget().setHtml(b.responseText,a.scripts===!0,a.rendererScope);return !0}}},url:null,params:null,baseParams:null,autoLoad:!1,target:null,loadMask:!1,ajaxOptions:null,scripts:!1,isLoader:!0,constructor:function(c){var a=this,b;a.mixins.observable.constructor.call(a,c);a.setTarget(a.target);if(a.autoLoad){b=a.autoLoad;if(b===!0){b=null}a.load(b)}},setTarget:function(a){var b=this;a=Ext.get(a);if(b.target&&b.target!==a){b.abort()}b.target=a},getTarget:function(){return this.target||null},abort:function(){var a=this.active;if(a!==undefined){Ext.Ajax.abort(a.request);if(a.mask){this.removeMask()}delete this.active}},removeMask:function(){this.target.unmask()},addMask:function(a){this.target.mask(a===!0?null:a)},load:function(b){b=Ext.apply({},b);var a=this,d=Ext.isDefined(b.loadMask)?b.loadMask:a.loadMask,c=Ext.apply({},b.params),e=Ext.apply({},b.ajaxOptions),f=b.callback||a.callback,g=b.scope||a.scope||a;Ext.applyIf(e,a.ajaxOptions);Ext.applyIf(b,e);Ext.applyIf(c,a.params);Ext.apply(c,a.baseParams);Ext.applyIf(b,{url:a.url});Ext.apply(b,{scope:a,params:c,callback:a.onComplete});if(a.fireEvent('beforeload',a,b)===!1){return}if(d){a.addMask(d)}a.active={options:b,mask:d,scope:g,callback:f,success:b.success||a.success,failure:b.failure||a.failure,renderer:b.renderer||a.renderer,scripts:Ext.isDefined(b.scripts)?b.scripts:a.scripts};a.active.request=Ext.Ajax.request(b);a.setOptions(a.active,b)},setOptions:function(b,a){b.rendererScope=a.rendererScope||this.rendererScope||this},onComplete:function(d,e,c){var a=this,b=a.active,g,f;if(b){f=b.scope;g=b.rendererScope;if(e){e=a.getRenderer(b.renderer).call(g,a,c,b)!==!1}if(e){Ext.callback(b.success,f,[a,c,d]);a.fireEvent('load',a,c,d)}else {Ext.callback(b.failure,f,[a,c,d]);a.fireEvent('exception',a,c,d)}Ext.callback(b.callback,f,[a,e,c,d]);if(b.mask){a.removeMask()}}delete a.active},getRenderer:function(a){if(Ext.isFunction(a)){return a}return this.statics().Renderer.Html},startAutoRefresh:function(b,c){var a=this;a.stopAutoRefresh();a.autoRefresh=Ext.interval(function(){a.load(c)},b)},stopAutoRefresh:function(){clearInterval(this.autoRefresh);delete this.autoRefresh},isAutoRefreshing:function(){return Ext.isDefined(this.autoRefresh)},destroy:function(){var a=this;a.stopAutoRefresh();delete a.target;a.abort();a.callParent()}},1,0,0,0,0,[[Ext.util.Observable.prototype.mixinId||Ext.util.Observable.$className,Ext.util.Observable]],[Ext,'ElementLoader'],0);Ext.cmd.derive('Ext.ComponentLoader',Ext.ElementLoader,{statics:{Renderer:{Data:function(c,b,d){var a=!0;try{c.getTarget().update(Ext.decode(b.responseText))}catch(e){a=!1}return a},Component:function(f,d,e){var b=!0,a=f.getTarget(),c=[];try{c=Ext.decode(d.responseText)}catch(g){b=!1}if(b){a.suspendLayouts();if(e.removeAll){a.removeAll()}a.add(c);a.resumeLayouts(!0)}return b}}},target:null,loadOnRender:!1,loadMask:!1,renderer:'html',setTarget:function(b){var a=this;if(Ext.isString(b)){b=Ext.getCmp(b)}if(a.target&&a.target!==b){a.abort()}a.target=b;if(b&&a.loadOnRender){if(b.rendered){a.doLoadOnRender()}else {a.mon(b,'render',a.doLoadOnRender,a)}}},doLoadOnRender:function(){var a=this.loadOnRender;this.load(Ext.isObject(a)?a:null)},removeMask:function(){this.target.setLoading(!1)},addMask:function(a){this.target.setLoading(a)},setOptions:function(b,a){b.removeAll=Ext.isDefined(a.removeAll)?a.removeAll:this.removeAll;b.rendererScope=a.rendererScope||this.rendererScope||this.target},getRenderer:function(a){if(Ext.isFunction(a)){return a}var b=this.statics().Renderer;switch(a){case 'component':return b.Component;case 'data':return b.Data;default:return Ext.ElementLoader.Renderer.Html;}}},0,0,0,0,0,0,[Ext,'ComponentLoader'],0);Ext.cmd.derive('Ext.layout.SizeModel',Ext.Base,{constructor:function(e){var a=this,b=a.self,d=b.sizeModelsArray,c;Ext.apply(a,e);a[c=a.name]=!0;a.fixed=!(a.auto=a.natural||a.shrinkWrap);d[a.ordinal=d.length]=b[c]=b.sizeModels[c]=a},statics:{sizeModelsArray:[],sizeModels:{}},calculated:!1,configured:!1,constrainedMax:!1,constrainedMin:!1,natural:!1,shrinkWrap:!1,calculatedFromConfigured:!1,calculatedFromNatural:!1,calculatedFromShrinkWrap:!1,names:null},1,0,0,0,0,0,[Ext.layout,'SizeModel'],function(){var a=this,d=a.sizeModelsArray,b,c,f,g,e;new a({name:'calculated'});new a({name:'configured',names:{width:'width',height:'height'}});new a({name:'natural'});new a({name:'shrinkWrap'});new a({name:'calculatedFromConfigured',configured:!0,calculatedFrom:!0,names:{width:'width',height:'height'}});new a({name:'calculatedFromNatural',natural:!0,calculatedFrom:!0});new a({name:'calculatedFromShrinkWrap',shrinkWrap:!0,calculatedFrom:!0});new a({name:'constrainedMax',configured:!0,constrained:!0,names:{width:'maxWidth',height:'maxHeight'}});new a({name:'constrainedMin',configured:!0,constrained:!0,names:{width:'minWidth',height:'minHeight'}});new a({name:'constrainedDock',configured:!0,constrained:!0,constrainedByMin:!0,names:{width:'dockConstrainedWidth',height:'dockConstrainedHeight'}});for(b=0,f=d.length;b-1&&e','
role="presentation"','class="{innerCtCls}">','{%this.renderBody(out,values)%}','
',''],beginLayout:function(a){Ext.layout.container.Container.prototype.beginLayout.apply(this,arguments);this.initContextItems(a)},beforeLayoutCycle:function(d){var a=this.owner,c=a.inheritedState,b=a.inheritedStateInner;if(!c||c.invalid){c=a.getInherited();b=a.inheritedStateInner}if(d.widthModel.shrinkWrap){b.inShrinkWrapTable=!0}else {delete b.inShrinkWrapTable}},beginLayoutCycle:function(e){var a=this,g=a.outerCt,l=a.lastOuterCtWidth||'',k=a.lastOuterCtHeight||'',j=a.lastOuterCtTableLayout||'',i=e.state,f,d,c,b,h;Ext.layout.container.Container.prototype.beginLayoutCycle.apply(this,arguments);d=c=b='';if(!e.widthModel.shrinkWrap){d='100%';h=a.owner.inheritedStateInner;f=a.getOverflowXStyle(e);b=h.inShrinkWrapTable||f==='auto'||f==='scroll'?'':'fixed'}if(!e.heightModel.shrinkWrap&&!Ext.supports.PercentageHeightOverflowBug){c='100%'}if(d!==l||a.hasOuterCtPxWidth){g.setStyle('width',d);a.lastOuterCtWidth=d;a.hasOuterCtPxWidth=!1}if(b!==j){g.setStyle('table-layout',b);a.lastOuterCtTableLayout=b}if(c!==k||a.hasOuterCtPxHeight){g.setStyle('height',c);a.lastOuterCtHeight=c;a.hasOuterCtPxHeight=!1}if(a.hasInnerCtPxHeight){a.innerCt.setStyle('height','');a.hasInnerCtPxHeight=!1}i.overflowAdjust=i.overflowAdjust||a.lastOverflowAdjust},calculate:function(b){var a=this,d=b.state,c=a.getContainerSize(b,!0),e=d.calculatedItems||(d.calculatedItems=a.calculateItems?a.calculateItems(b,c):!0);a.setCtSizeIfNeeded(b,c);if(e&&b.hasDomProp('containerChildrenSizeDone')){a.calculateContentSize(b);if(c.gotAll){if(a.manageOverflow&&!b.state.secondPass&&!a.reserveScrollbar){a.calculateOverflow(b,c)}return}}a.done=!1},calculateContentSize:function(a){var b=this,f=(a.widthModel.shrinkWrap?1:0)|(a.heightModel.shrinkWrap?2:0),d=f&1||undefined,c=f&2||undefined,e=0,g=a.props;if(d){if(isNaN(g.contentWidth)){++e}else {d=undefined}}if(c){if(isNaN(g.contentHeight)){++e}else {c=undefined}}if(e){if(d&&!a.setContentWidth(b.measureContentWidth(a))){b.done=!1}if(c&&!a.setContentHeight(b.measureContentHeight(a))){b.done=!1}}},calculateOverflow:function(d){var c=this,g,f,e,a,h,i,b;h=c.getOverflowXStyle(d)==='auto';i=c.getOverflowYStyle(d)==='auto';if(h||i){e=Ext.getScrollbarSize();b=d.overflowContext.el.dom;a=0;if(b.scrollWidth>b.clientWidth){a|=1}if(b.scrollHeight>b.clientHeight){a|=2}g=i&&a&2?e.width:0;f=h&&a&1?e.height:0;if(g!==c.lastOverflowAdjust.width||f!==c.lastOverflowAdjust.height){c.done=!1;d.invalidate({state:{overflowAdjust:{width:g,height:f},overflowState:a,secondPass:!0}})}}},completeLayout:function(a){this.lastOverflowAdjust=a.state.overflowAdjust},doRenderBody:function(b,a){var c=a.$layout,d=Ext.XTemplate,e=c.beforeBodyTpl,f=c.afterBodyTpl;if(e){d.getTpl(c,'beforeBodyTpl').applyOut(a,b)}this.renderItems(b,a);this.renderContent(b,a);if(f){d.getTpl(c,'afterBodyTpl').applyOut(a,b)}},doRenderPadding:function(d,b){var e=b.$layout,a=b.$layout.owner,c=a[a.contentPaddingProperty];if(e.managePadding&&c){d.push('padding:',a.unitizeBox(c))}},finishedLayout:function(b){var a=this.innerCt;Ext.layout.container.Container.prototype.finishedLayout.apply(this,arguments);if(Ext.isIE8){a.repaint()}if(Ext.isOpera){a.setStyle('position','relative');a.dom.scrollWidth;a.setStyle('position','')}},getContainerSize:function(c,d){var b=Ext.layout.container.Container.prototype.getContainerSize.apply(this,arguments),a=c.state.overflowAdjust;if(a){b.width-=a.width;b.height-=a.height}return b},getRenderData:function(){var b=this,a=Ext.layout.container.Container.prototype.getRenderData.call(this);a.innerCtCls=b.innerCtCls;a.outerCtCls=b.outerCtCls;return a},getRenderTarget:function(){return this.innerCt},getElementTarget:function(){return this.innerCt},getOverflowXStyle:function(a){return a.overflowXStyle||(a.overflowXStyle=this.owner.scrollFlags.overflowX||a.overflowContext.getStyle('overflow-x'))},getOverflowYStyle:function(a){return a.overflowYStyle||(a.overflowYStyle=this.owner.scrollFlags.overflowY||a.overflowContext.getStyle('overflow-y'))},initContextItems:function(a){var b=this,d=a.target,c=b.owner.getOverflowEl();a.outerCtContext=a.getEl('outerCt',b);a.innerCtContext=a.getEl('innerCt',b);a.overflowContext=c===a.el?a:a.getEl(c);if(d[d.contentPaddingProperty]!==undefined){a.paddingContext=a.innerCtContext}},initLayout:function(){var a=this,b=Ext.getScrollbarSize().width,c=a.owner;Ext.layout.container.Container.prototype.initLayout.call(this);if(b&&a.manageOverflow&&!a.hasOwnProperty('lastOverflowAdjust')){if(c.scrollable||a.reserveScrollbar){a.lastOverflowAdjust={width:b,height:0}}}},measureContentHeight:function(b){var a=this.outerCt.getHeight(),c=b.target;if(this.managePadding&&c[c.contentPaddingProperty]===undefined){a+=b.targetContext.getPaddingInfo().height}return a},measureContentWidth:function(f){var a,b,e,c,d;if(this.chromeCellMeasureBug){a=this.innerCt.dom;b=a.style;e=b.display;if(e==='table-cell'){b.display='';a.offsetWidth;b.display=e}}if(Ext.isSafari){a=this.outerCt.dom;b=a.style;b.display='table-cell';a.offsetWidth;a.style.display=''}c=this.outerCt.getWidth();d=f.target;if(this.managePadding&&d[d.contentPaddingProperty]===undefined){c+=f.targetContext.getPaddingInfo().width}return c},setCtSizeIfNeeded:function(a,h){var c=this,b=h.height,k=a.paddingContext.getPaddingInfo(),g=c.getTarget(),f=c.getOverflowXStyle(a),j=f==='auto'||f==='scroll',i=Ext.getScrollbarSize(),e,d;if(b&&!a.heightModel.shrinkWrap){if(Ext.supports.PercentageHeightOverflowBug){e=!0}if(Ext.isIE8){d=!0}if((e||d)&&j&&g.dom.scrollWidth>g.dom.clientWidth){b=Math.max(b-i.height,0)}if(e){a.outerCtContext.setProp('height',b+k.height);c.hasOuterCtPxHeight=!0}if(d){a.innerCtContext.setProp('height',b);c.hasInnerCtPxHeight=!0}}},setupRenderTpl:function(a){Ext.layout.container.Container.prototype.setupRenderTpl.apply(this,arguments);a.renderPadding=this.doRenderPadding},getContentTarget:function(){return this.innerCt},getScrollerEl:function(){return this.outerCt}},0,0,0,0,['layout.auto','layout.autocontainer'],0,[Ext.layout.container,'Auto'],function(){this.prototype.chromeCellMeasureBug=Ext.isChrome&&Ext.chromeVersion>=26});Ext.cmd.derive('Ext.ZIndexManager',Ext.Base,{alternateClassName:'Ext.WindowGroup',statics:{zBase:9000,activeCounter:0},constructor:function(b){var a=this;a.id=Ext.id(null,'zindex-mgr-');a.zIndexStack=new Ext.util.Collection({sorters:{sorterFn:function(c,d){var a=(c.alwaysOnTop||0)-(d.alwaysOnTop||0);if(!a){a=c.getActiveCounter()-d.getActiveCounter()}return a}},filters:{filterFn:function(a){return a.isVisible()}}});a.zIndexStack.addObserver(a);a.front=null;a.globalListeners=Ext.GlobalEvents.on({beforehide:a.onComponentShowHide,show:a.onComponentShowHide,scope:a,destroyable:!0});if(b){if(b.isContainer){b.on('resize',a.onContainerResize,a);a.zseed=Ext.Number.from(a.rendered?b.getEl().getStyle('zIndex'):undefined,a.getNextZSeed());a.targetEl=b.getTargetEl();a.container=b}else {Ext.on('resize',a.onContainerResize,a);a.zseed=a.getNextZSeed();a.targetEl=Ext.get(b)}}else {a.zseed=a.getNextZSeed();Ext.onInternalReady(function(){Ext.on('resize',a.onContainerResize,a);a.targetEl=Ext.getBody()})}},getId:function(){return this.id},getNextZSeed:function(){return Ext.ZIndexManager.zBase+=10000},setBase:function(a){this.zseed=a;return this.onCollectionSort()},onCollectionSort:function(){var d=this,b=d.front,k=b&&b.containsFocus,g=d.zseed,i=d.zIndexStack.getRange(),j=i.length,e,c,f,a,h=!1;for(e=0;e0;){a=c[b];if(a.isComponent&&e.call(d||a,a)===!1){return}}},destroy:function(){var a=this,c=a.zIndexStack.getRange(),d=c.length,b;for(b=0;b1){b.refresh()}if(a.hasListeners.afterlayout){a.fireEvent('afterlayout',a,c)}},beforeDestroy:function(){var a=this,d=a.items,c=a.floatingItems,b;if(d){while(b=d.first()){a.doRemove(b,!0)}}if(c){while(b=c.first()){a.doRemove(b,!0)}}Ext.destroy(a.layout);Ext.Component.prototype.beforeDestroy.call(this)},destroy:function(){var a=this;Ext.Component.prototype.destroy.call(this);if(a.items){a.items.destroy()}if(a.floatingItems){a.floatingItems.destroy()}a.refs=a.items=a.floatingItems=a.layout=null},beforeRender:function(){var a=this,c=a.getLayout(),b;a.preventChildDisable=!0;Ext.Component.prototype.beforeRender.call(this);a.preventChildDisable=!1;if(!c.initialized){c.initLayout()}b=c.targetCls;if(b){a.applyTargetCls(b)}},cascade:function(f,e,d){var a=this,h=a.items?a.items.items:[],j=h.length,g=0,b,c=d?d.concat(a):[a],i=c.length-1;if(f.apply(e||a,c)!==!1){for(;g','
','
{msg}
','
',''],maskOnDisable:!1,skipLayout:!0,constructor:function(c){var a=this,b;if(arguments.length===2){b=a.target=c;c=arguments[1]}else {b=c.target}Ext.Component.prototype.constructor.call(this,c);if(b.isComponent){a.ownerCt=b;a.hidden=!0;a.renderTo=a.getMaskTarget();a.external=a.renderTo===Ext.getBody();a.bindComponent(b)}else {b=Ext.get(b);a.isElement=!0;a.renderTo=a.target}a.render(a.renderTo);if(a.store){a.bindStore(a.store,!0)}},initRenderData:function(){var a=Ext.Component.prototype.initRenderData.apply(this,arguments);a.msg=this.msg||'';return a},onRender:function(){Ext.Component.prototype.onRender.apply(this,arguments);this.maskEl=this.el},bindComponent:function(b){var a=this,c={scope:this,resize:a.sizeMask};if(a.external){c.added=a.onComponentAdded;c.removed=a.onComponentRemoved;if(b.floating){c.move=a.sizeMask;a.activeOwner=b}else {if(b.ownerCt){a.onComponentAdded(b.ownerCt)}}}a.mon(b,c);if(a.external){a.mon(Ext.GlobalEvents,{show:a.onContainerShow,hide:a.onContainerHide,expand:a.onContainerExpand,collapse:a.onContainerCollapse,scope:a})}},onComponentAdded:function(b){var a=this;delete a.activeOwner;a.floatParent=b;if(!b.floating){b=b.up('[floating]')}if(b){a.activeOwner=b;a.mon(b,'move',a.sizeMask,a);a.mon(b,'tofront',a.onOwnerToFront,a)}else {a.preventBringToFront=!0}b=a.floatParent.ownerCt;if(a.rendered&&a.isVisible()&&b){a.floatOwner=b;a.mon(b,'afterlayout',a.sizeMask,a,{single:!0})}},onComponentRemoved:function(d){var a=this,b=a.activeOwner,c=a.floatOwner;if(b){a.mun(b,'move',a.sizeMask,a);a.mun(b,'tofront',a.onOwnerToFront,a)}if(c){a.mun(c,'afterlayout',a.sizeMask,a)}delete a.activeOwner;delete a.floatOwner},afterRender:function(){var a=this;Ext.Component.prototype.afterRender.apply(this,arguments);if(Ext.isIE){a.el.on('mousedown',a.onMouseDown,a)}this.el.skipGarbageCollection=!0},onMouseDown:function(b){var a=this.el;if(b.within(a)){b.preventDefault();a.focus()}},onOwnerToFront:function(b,a){this.el.setStyle('zIndex',a+1)},onContainerShow:function(a){if(!this.isHierarchicallyHidden()){this.onComponentShow()}},onContainerHide:function(a){if(this.isHierarchicallyHidden()){this.onComponentHide()}},onContainerExpand:function(a){if(!this.isHierarchicallyHidden()){this.onComponentShow()}},onContainerCollapse:function(a){if(this.isHierarchicallyHidden()){this.onComponentHide()}},onComponentHide:function(){var a=this;if(a.rendered&&a.isVisible()){a.hide();a.showNext=!0}},onComponentShow:function(){if(this.showNext){this.show()}delete this.showNext},sizeMask:function(){var a=this,b=a.activeOwner||a.target,c=a.external?a.getOwner().el:a.getMaskTarget();if(a.rendered&&a.isVisible()){if(a.external){if(!a.isElement&&b.floating){a.onOwnerToFront(b,b.el.getZIndex())}a.el.setSize(c.getSize()).alignTo(c,'tl-tl')}a.msgWrapEl.center(a.el)}},bindStore:function(a,c){var b=this;Ext.destroy(b.proxyListeners);b.mixins.storeholder.bindStore.apply(b,arguments);a=b.store;if(a){while(a.getSource){a=a.getSource()}if(!a.loadsSynchronously()){b.proxyListeners=a.getProxy().on({exception:b.onLoad,scope:b,destroyable:!0})}if(a.isLoading()){b.onBeforeLoad()}}},getStoreListeners:function(d){var c=this.onLoad,b=this.onBeforeLoad,a={cachemiss:b,cachefilled:{fn:c,buffer:100}};if(!d.loadsSynchronously()){a.beforeload=b;a.load=c}return a},onDisable:function(){Ext.Component.prototype.onDisable.apply(this,arguments);if(this.loading){this.onLoad()}},getOwner:function(){return this.ownerCt||this.ownerCmp||this.floatParent},getMaskTarget:function(){var a=this.getOwner();if(this.isElement){return this.target}return this.useTargetEl?a.getTargetEl():a.getMaskTarget()||Ext.getBody()},onBeforeLoad:function(){var b=this,a=b.getOwner(),c;if(!b.disabled){b.loading=!0;if(a.componentLayoutCounter){b.maybeShow()}else {c=a.afterComponentLayout;a.afterComponentLayout=function(){a.afterComponentLayout=c;c.apply(a,arguments);b.maybeShow()}}}},maybeShow:function(){var a=this,b=a.getOwner();if(!b.isVisible(!0)){a.showNext=!0}else {if(a.loading&&b.rendered){a.show()}}},hide:function(){var b=this,a=b.ownerCt;if(b.isElement){a.unmask();b.fireEvent('hide',this);return}if(a){a.enableTabbing();a.setMasked(!1)}delete b.showNext;return Ext.Component.prototype.hide.apply(this,arguments)},show:function(){var a=this;if(a.isElement){a.ownerCt.mask(this.useMsg?this.msg:'',this.msgCls);a.fireEvent('show',this);return}return Ext.Component.prototype.show.apply(this,arguments)},afterShow:function(){var a=this,b=a.ownerCt;a.loading=!0;Ext.Component.prototype.afterShow.apply(this,arguments);b.disableTabbing();b.setMasked(!0);a.el.restoreTabbableState();a.syncMaskState()},syncMaskState:function(){var a=this,c=a.ownerCt,b=a.el;if(a.isVisible()){if(a.hasOwnProperty('msgWrapCls')){b.dom.className=a.msgWrapCls}if(a.useMsg){a.msgTextEl.setHtml(a.msg)}else {a.msgEl.hide()}if(a.shim||Ext.useShims){b.enableShim(null,!0)}else {b.disableShim()}if(c.el.contains(Ext.Element.getActiveElement())){a.focus()}a.sizeMask()}},onLoad:function(){this.loading=!1;this.hide()},beforeDestroy:function(){this.ownerCt=null;this.bindStore(null);Ext.Component.prototype.beforeDestroy.call(this)},onDestroy:function(){var a=this;if(a.isElement){a.ownerCt.unmask()}Ext.Component.prototype.onDestroy.call(this)}},1,['loadmask'],['component','box','loadmask'],{'component':!0,'box':!0,'loadmask':!0},['widget.loadmask'],[[Ext.util.StoreHolder.prototype.mixinId||Ext.util.StoreHolder.$className,Ext.util.StoreHolder]],[Ext,'LoadMask'],0);Ext.cmd.derive('Ext.layout.component.Component',Ext.layout.Layout,{type:'component',isComponentLayout:!0,nullBox:{},usesContentHeight:!0,usesContentWidth:!0,usesHeight:!0,usesWidth:!0,widthCache:{},heightCache:{},beginLayoutCycle:function(a,j){var c=this,f=c.owner,p=a.ownerCtContext,g=a.heightModel,h=a.widthModel,o=f.el.dom===document.body,e=f.lastBox||c.nullBox,d=f.el.lastBox||c.nullBox,m=!o,k=a.isTopLevel,i,b,n,l;Ext.layout.Layout.prototype.beginLayoutCycle.call(this,a,j);if(j){if(c.usesContentWidth){++a.consumersContentWidth}if(c.usesContentHeight){++a.consumersContentHeight}if(c.usesWidth){++a.consumersWidth}if(c.usesHeight){++a.consumersHeight}if(p&&!p.hasRawContent){i=f.ownerLayout;if(i){if(i.usesWidth){++a.consumersWidth}if(i.usesHeight){++a.consumersHeight}}}}if(h.configured){n=f[h.names.width];if(k&&h.calculatedFrom){n=e.width}if(!o){m=c.setWidthInDom||(j?n!==d.width:h.constrained)}a.setWidth(n,m)}else {if(k){if(h.calculated){b=e.width;a.setWidth(b,b!==d.width)}b=e.x;a.setProp('x',b,b!==d.x)}}if(g.configured){l=f[g.names.height];if(k&&g.calculatedFrom){l=e.height}if(!o){m=j?l!==d.height:g.constrained}a.setHeight(l,m)}else {if(k){if(g.calculated){b=e.height;a.setHeight(b,b!==d.height)}b=e.y;a.setProp('y',b,b!==d.y)}}},finishedLayout:function(c){var h=this,e=c.children,g=h.owner,i,d,f,a,b;if(e){i=e.length;for(d=0;d','
{text}
','',''],componentLayout:'progressbar',ariaRole:'progressbar',initRenderData:function(){var a=this,b=a.value||0;return Ext.apply(Ext.Component.prototype.initRenderData.call(this),{internalText:!a.hasOwnProperty('textEl'),text:a.text||' ',percentage:b*100})},onRender:function(){var a=this;Ext.Component.prototype.onRender.apply(this,arguments);if(a.textEl){a.textEl=Ext.get(a.textEl);a.updateText(a.text)}else {a.textEl=a.el.select('.'+a.baseCls+'-text')}},updateValue:function(a){this.updateProgress(a,Math.round(a*100)+'%')},updateProgress:function(b,c,d){b=b||0;var a=this,f=a.value,e=a.getTextTpl();a.value=b||(b=0);if(c!=null){a.updateText(c)}else {if(e){a.updateText(e.apply({value:b,percent:b*100}))}}if(a.rendered&&!a.destroyed){if(d===!0||d!==!1&&a.animate){a.bar.stopAnimation();a.bar.animate(Ext.apply({from:{width:f*100+'%'},to:{width:b*100+'%'}},a.animate))}else {a.bar.setStyle('width',b*100+'%')}}a.fireEvent('update',a,b,c);return a},updateText:function(b){var a=this;a.text=b;if(a.rendered){a.textEl.setHtml(a.text)}return a},applyText:function(a){this.updateText(a)},getText:function(){return this.text},wait:function(a){var b=this,c;if(!b.waitTimer){c=b;a=a||{};b.updateText(a.text);b.waitTimer=Ext.TaskManager.start({run:function(d){var c=a.increment||10;d-=1;b.updateProgress(((d+c)%c+1)*(100/c)*0.01,null,a.animate)},interval:a.interval||1000,duration:a.duration,onStop:function(){if(a.fn){a.fn.apply(a.scope||b)}b.reset()},scope:c})}return b},isWaiting:function(){return this.waitTimer!==null},reset:function(b){var a=this;a.updateProgress(0);a.clearTimer();if(b===!0){a.hide()}return a},clearTimer:function(){var a=this;if(a.waitTimer){a.waitTimer.onStop=null;Ext.TaskManager.stop(a.waitTimer);a.waitTimer=null}},onDestroy:function(){var a=this,b=a.bar;a.clearTimer();if(a.rendered){if(a.textEl.isComposite){a.textEl.clear()}Ext.destroyMembers(a,'textEl','progressBar');if(b&&a.animate){b.stopAnimation()}}Ext.Component.prototype.onDestroy.call(this)}},0,['progressbar'],['component','box','progressbar'],{'component':!0,'box':!0,'progressbar':!0},['widget.progressbar'],[[Ext.ProgressBase.prototype.mixinId||Ext.ProgressBase.$className,Ext.ProgressBase]],[Ext,'ProgressBar'],0);Ext.cmd.derive('Ext.dom.ButtonElement',Ext.dom.Element,{setSize:function(b,a,e){var d=this,c=d.component;Ext.dom.Element.prototype.setSize.call(this,b,a,e);c.btnWrap.setStyle('table-layout',!b||b==='auto'?'':'fixed');c.btnEl.setStyle('height',!a||a==='auto'?'':'auto');return d},setStyle:function(a,c){var f=this,e=f.component,d,b;Ext.dom.Element.prototype.setStyle.call(this,a,c);if(a){if(a==='width'||typeof a!=='string'&&'width' in a){d=c||a.width;e.btnWrap.setStyle('table-layout',!d||d==='auto'?'':'fixed')}if(a==='height'||typeof a!=='string'&&'height' in a){b=c||a.height;e.btnEl.setStyle('height',!b||b==='auto'?'':'auto')}}return f},setHeight:function(a,b){Ext.dom.Element.prototype.setHeight.call(this,a,b);this.component.btnEl.setStyle('height',!a||a==='auto'?'':'auto');return this},setWidth:function(a,b){Ext.dom.Element.prototype.setWidth.call(this,a,b);this.component.btnWrap.setStyle('table-layout',!a||a==='auto'?'':'fixed');return this}},0,0,0,0,0,0,[Ext.dom,'ButtonElement'],0);Ext.cmd.derive('Ext.button.Manager',Ext.Base,{singleton:!0,alternateClassName:'Ext.ButtonToggleManager',groups:{},pressedButton:null,init:function(){var a=this;if(!a.initialized){Ext.getDoc().on({mouseup:a.onDocumentMouseUp,scope:a});a.initialized=!0}},onButtonMousedown:function(b,c){var a=this.pressedButton;if(a){a.onMouseUp(c)}this.pressedButton=b},onDocumentMouseUp:function(b){var a=this.pressedButton;if(a){a.onMouseUp(b);this.pressedButton=null}},toggleGroup:function(c,e){if(e){var b=this.groups[c.toggleGroup],d=b.length,a;for(a=0;a{[values.$comp.renderIcon(values)]}{text}{[values.$comp.renderIcon(values)]}{[values.$comp.getAfterMarkup ? values.$comp.getAfterMarkup(values) : ""]} {closeText} tabindex="{tabIndex}" {$}="{.}">{arrowElText}',iconTpl:'background-image:url({iconUrl});font-family:{glyphFontFamily};">&#{glyph};',scale:'small',allowedScales:['small','medium','large'],arrowAlign:'right',arrowCls:'arrow',maskOnDisable:!1,shrinkWrap:3,frame:!0,autoEl:{tag:'a',hidefocus:'on',unselectable:'on'},hasFrameTable:function(){return this.href&&this.frameTable},frameTableListener:function(){if(!this.disabled){this.doNavigate()}},doNavigate:function(){if(this.hrefTarget==='_blank'){window.open(this.getHref(),this.hrefTarget)}else {location.href=this.getHref()}},_triggerRegion:{},initComponent:function(){var a=this;a.addCls('x-unselectable');Ext.Component.prototype.initComponent.call(this);if(a.menu){a.split=!0;a.setMenu(a.menu,!1,!0)}if(a.url){a.href=a.url}a.configuredWithPreventDefault=a.hasOwnProperty('preventDefault');if(a.href&&!a.configuredWithPreventDefault){a.preventDefault=!1}if(Ext.isString(a.toggleGroup)&&a.toggleGroup!==''){a.enableToggle=!0}if(a.html&&!a.text){a.text=a.html;delete a.html}},getElConfig:function(){var a=this,b=Ext.Component.prototype.getElConfig.call(this),d=a.getHref(),c=a.hrefTarget;if(b.tag==='a'){if(!a.disabled){b.tabIndex=a.tabIndex}if(d){if(!a.disabled){b.href=d;if(c){b.target=c}}}}if(!a.ariaStaticRoles[a.ariaRole]){if(a.menu&&!a.isSplitButton){b['aria-haspopup']=!0}if(a.enableToggle){b['aria-pressed']=!!a.pressed}}return b},beforeRender:function(){Ext.Component.prototype.beforeRender.call(this);if(this.pressed){this.addCls(this._pressedCls)}},initRenderData:function(){return Ext.apply(Ext.Component.prototype.initRenderData.call(this),this.getTemplateArgs())},getMenu:function(){return this.menu||null},setMenu:function(b,g,h){var a=this,e=a.menu,d=a.isSplitButton?a.arrowEl&&a.arrowEl.dom:a.ariaEl.dom,f,c;if(e&&!h){if(g!==!1&&a.destroyMenu){e.destroy()}e.ownerCmp=null}if(b){f=b.isMenu;b=Ext.menu.Manager.get(b,{ownerCmp:a});b.setOwnerCmp(a,f);b.menuClickBuffer=250;a.mon(b,{scope:a,show:a.onMenuShow,hide:a.onMenuHide});if(!e&&a.getArrowVisible()){a.split=!0;if(a.rendered){a._addSplitCls();a.updateLayout()}}a.menu=b;if(d){d.setAttribute('aria-haspopup',!0);d.setAttribute('aria-owns',b.id)}else {c=a.isSplitButton?a.ariaArrowElAttributes||(a.ariaArrowElAttributes={}):a.ariaRenderAttributes||(a.ariaRenderAttributes={});c['aria-haspopup']=!0;c['aria-owns']=b.id}}else {if(a.rendered){d.removeAttribute('aria-haspopup');d.removeAttribute('aria-owns');a._removeSplitCls();a.updateLayout()}else {c=a.isSplitButton?a.ariaArrowElAttributes:a.ariaRenderAttributes;if(c){delete c['aria-haspopup'];delete c['aria-owns']}}a.split=!1;a.menu=null}},onRender:function(){var a=this,d,c,b;Ext.Component.prototype.onRender.apply(this,arguments);c=a.el;if(a.tooltip){a.setTooltip(a.tooltip,!0)}if(a.handleMouseEvents){b={scope:a,mouseover:a.onMouseOver,mouseout:a.onMouseOut,mousedown:a.onMouseDown};if(a.split){b.mousemove=a.onMouseMove}}else {b={scope:a}}if(Ext.supports.Touch){b.touchstart=a.onTouchStart}if(a.repeat){a.mon(new Ext.util.ClickRepeater(c,Ext.isObject(a.repeat)?a.repeat:{}),'click',a.onRepeatClick,a)}else {if(b[a.clickEvent]){d=!0}else {b[a.clickEvent]=a.onClick}}a.mon(c,b);if(a.hasFrameTable()){a.mon(a.frameTable,'click',a.frameTableListener,a)}if(d){a.mon(c,a.clickEvent,a.onClick,a)}Ext.button.Manager.register(a)},onFocusLeave:function(a){Ext.Component.prototype.onFocusLeave.call(this,a);if(this.menu){this.menu.hide()}},getTemplateArgs:function(){var a=this,i=a._btnCls,j=a._baseIconCls,d=a.getIconAlign(),b=a.glyph,f=Ext._glyphFontFamily,e=a.text,h=a._hasIcon(),g=a._hasIconCls,c;if(typeof b==='string'){c=b.split('@');b=c[0];f=c[1]}return {split:a.isSplitButton,innerCls:a._innerCls,splitCls:a.getArrowVisible()?a.getSplitCls():'',iconUrl:a.icon,iconCls:a.iconCls,glyph:b,glyphCls:b?a._glyphCls:'',glyphFontFamily:f,text:e||' ',closeText:a.closeText,textCls:e?a._textCls:'',noTextCls:e?'':a._noTextCls,hasIconCls:h?g:'',btnWrapCls:a._btnWrapCls,btnWrapStyle:a.width?'table-layout:fixed;':'',btnElStyle:a.height?'height:auto;':'',btnCls:i,baseIconCls:j,iconBeforeText:d==='left'||d==='top',iconAlignCls:h?g+'-'+d:'',textAlignCls:i+'-'+a.getTextAlign(),arrowElCls:a._arrowElCls,tabIndex:a.tabIndex}},renderIcon:function(a){return this.getTpl('iconTpl').apply(a)},setHref:function(c){var a=this,d=a.hrefTarget,b;a.href=c;if(!a.configuredWithPreventDefault){a.preventDefault=!c}if(a.rendered){b=a.el.dom;if(!c||a.disabled){b.removeAttribute('href');b.removeAttribute('hrefTarget')}else {b.href=a.getHref();if(d){b.target=d}}}},getHref:function(){var a=this,b=a.href;return b?Ext.urlAppend(b,Ext.Object.toQueryString(Ext.apply({},a.params,a.baseParams))):!1},setParams:function(c){var a=this,b;a.params=c;if(a.rendered){b=a.el.dom;if(a.disabled){b.removeAttribute('href')}else {b.href=a.getHref()||''}}},getSplitCls:function(){var a=this;return a.split?a.baseCls+'-'+a.arrowCls+' '+(a.baseCls+'-'+a.arrowCls+'-'+a.arrowAlign):''},setIcon:function(b){b=b||'';var a=this,d=a.btnIconEl,c=a.icon||'';a.icon=b;if(b!==c){if(d){d.setStyle('background-image',b?'url('+b+')':'');a._syncHasIconCls();if(a.didIconStateChange(c,b)){a.updateLayout()}}a.fireEvent('iconchange',a,c,b)}return a},setIconCls:function(b){b=b||'';var a=this,d=a.btnIconEl,c=a.iconCls||'';a.iconCls=b;if(c!==b){if(d){d.removeCls(c);d.addCls(b);a._syncHasIconCls();if(a.didIconStateChange(c,b)){a.updateLayout()}}a.fireEvent('iconchange',a,c,b)}return a},setGlyph:function(b){b=b||0;var a=this,c=a.btnIconEl,f=a.glyph,g=a._glyphCls,d,e;a.glyph=b;if(c){if(typeof b==='string'){e=b.split('@');b=e[0];d=e[1]||Ext._glyphFontFamily}if(!b){c.dom.innerHTML='';c.removeCls(g)}else {if(f!==b){c.dom.innerHTML='&#'+b+';';c.addCls(g)}}if(d){c.setStyle('font-family',d)}a._syncHasIconCls();if(a.didIconStateChange(f,b)){a.updateLayout()}}a.fireEvent('glyphchange',a,a.glyph,f);return a},setTooltip:function(b,c){var a=this;if(a.rendered){if(!c||!b){a.clearTip()}if(b){if(Ext.quickTipsActive&&Ext.isObject(b)){Ext.tip.QuickTipManager.register(Ext.apply({target:a.el.id},b));a.tooltip=b}else {a.el.dom.setAttribute(a.getTipAttr(),b)}}}else {a.tooltip=b}return a},updateIconAlign:function(e,f){var b=this,a,d,c;if(b.rendered){a=b.btnEl;d=b.btnIconEl;c=b._hasIconCls;if(f){a.removeCls(c+'-'+f)}a.addCls(c+'-'+e);if(e==='top'||e==='left'){a.insertFirst(d)}else {a.appendChild(d)}b.updateLayout()}},updateTextAlign:function(e,d){var a=this,c=a.btnEl,b=a._btnCls;if(a.rendered){c.removeCls(b+'-'+d);c.addCls(b+'-'+e)}},getTipAttr:function(){return this.tooltipType==='qtip'?'data-qtip':'title'},getRefItems:function(c){var b=this.menu,a;if(b){a=b.getRefItems(c);a.unshift(b)}return a||[]},clearTip:function(){var a=this,b=a.el;if(Ext.quickTipsActive&&Ext.isObject(a.tooltip)){Ext.tip.QuickTipManager.unregister(b)}else {b.dom.removeAttribute(a.getTipAttr())}},beforeDestroy:function(){var a=this;if(a.rendered){a.clearTip()}Ext.destroy(a.repeater);Ext.Component.prototype.beforeDestroy.call(this)},onDestroy:function(){var a=this,b=a.menu;if(a.rendered){Ext.destroy(a.keyMap);delete a.keyMap}if(b&&a.destroyMenu){a.menu=Ext.destroy(b)}Ext.button.Manager.unregister(a);Ext.Component.prototype.onDestroy.call(this)},setHandler:function(a,b){this.handler=a;if(arguments.length>1){this.scope=b}return this},updateText:function(b,c){b=b==null?'':String(b);c=c||'';var a=this,e=a.btnInnerEl,d=a.btnEl;if(a.rendered){e.setHtml(b||' ');d[b?'addCls':'removeCls'](a._textCls);d[b?'removeCls':'addCls'](a._noTextCls);a.updateLayout()}a.fireEvent('textchange',a,c,b)},didIconStateChange:function(c,b){var a=Ext.isEmpty(b);return Ext.isEmpty(c)?!a:a},click:function(a){return this.onClick(a)},setPressed:function(a){return this.toggle(a!==!1)},toggle:function(b,d){var a=this,c=a.ariaEl.dom;b=b===undefined?!a.pressed:!!b;if(a.fireEvent('beforetoggle',a,b)!==!1){if(b!==a.pressed){a[b?'addCls':'removeCls'](a._pressedCls);a.pressed=b;if(c){c.setAttribute('aria-pressed',b)}if(!d){a.fireEvent('toggle',a,b);Ext.callback(a.toggleHandler,a.scope,[a,b],0,a);if(a.reference&&a.publishState){a.publishState('pressed',b)}}}}return a},maybeShowMenu:function(a){if(this.menu){this.showMenu(a)}},showMenu:function(c){var a=this,b=a.menu,d=!c||c.pointerType;if(b&&a.rendered){if(a.tooltip&&Ext.quickTipsActive&&a.getTipAttr()!=='title'){Ext.tip.QuickTipManager.getQuickTip().cancelShow(a.el)}if(b.isVisible()){if(d){b.hide()}else {b.focus()}}else {if(!c||a.showEmptyMenu||b.items.getCount()>0){b.autoFocus=!d;b.showBy(a.el,a.menuAlign)}}}return a},hideMenu:function(){if(this.hasVisibleMenu()){this.menu.hide()}return this},hasVisibleMenu:function(){var a=this.menu;return a&&a.rendered&&a.isVisible()},onRepeatClick:function(b,a){this.onClick(a)},onTouchStart:function(a){this.doPreventDefault(a)},onEnterKey:function(a){this.onClick(a);a.stopEvent();return !1},onClick:function(b){var a=this;a.doPreventDefault(b);if(b.type!=='keydown'&&b.button){return}if(!a.disabled){a.doToggle();a.maybeShowMenu(b);a.fireHandler(b)}},doPreventDefault:function(a){if(a&&(this.preventDefault||this.disabled&&this.getHref())){a.preventDefault()}},fireHandler:function(b){var a=this;if(a.fireEvent('click',a,b)!==!1&&!a.destroyed){Ext.callback(a.handler,a.scope,[a,b],0,a)}},doToggle:function(){var a=this;if(a.enableToggle&&(a.allowDepress!==!1||!a.pressed)){a.toggle()}},onMouseOver:function(b){var a=this;if(!a.disabled&&!b.within(a.el,!0,!0)){a.onMouseEnter(b)}},onMouseOut:function(b){var a=this;if(!b.within(a.el,!0,!0)){if(a.overMenuTrigger){a.onMenuTriggerOut(b)}a.onMouseLeave(b)}},onMouseMove:function(b){var a=this,c=a.overMenuTrigger;if(a.split){if(a.isWithinTrigger(b)){if(!c){a.onMenuTriggerOver(b)}}else {if(c){a.onMenuTriggerOut(b)}}}},isWithinTrigger:function(d){var a=this,e=a.el,c,b;c=a.arrowAlign==='right'?d.getX()-a.getX():d.getY()-e.getY();b=a.getTriggerRegion();return c>b.begin&&c{iconMarkup}
role="{textElRole}">{text}
{iconMarkup}',iconTpl:'',_textAlignClasses:{left:'x-title-align-left',center:'x-title-align-center',right:'x-title-align-right'},_iconAlignClasses:{top:'x-title-icon-top',right:'x-title-icon-right',bottom:'x-title-icon-bottom',left:'x-title-icon-left'},_rotationClasses:{0:'x-title-rotate-none',1:'x-title-rotate-right',2:'x-title-rotate-left'},_rotationAngles:{1:90,2:270},baseCls:'x-title',_titleSuffix:'-title',_glyphCls:'x-title-glyph',_iconWrapCls:'x-title-icon-wrap',_baseIconCls:'x-title-icon',_itemCls:'x-title-item',_textCls:'x-title-text',afterComponentLayout:function(){var b=this,c=b.getRotation(),a,d,e;if(c&&!Ext.isIE8){e=b.el;a=b.lastBox;d=a.x;e.setStyle(b._getVerticalAdjustDirection(),d+(c===1?a.width:-a.height)+'px')}Ext.Component.prototype.afterComponentLayout.call(this)},onRender:function(){var a=this,b=a.getRotation(),c=a.el;Ext.Component.prototype.onRender.call(this);if(b){c.setVertical(a._rotationAngles[b])}if(Ext.supports.FixedTableWidthBug){c._needsTableWidthFix=!0}},applyText:function(a){if(!a){a=' '}return a},beforeRender:function(){var a=this;Ext.Component.prototype.beforeRender.call(this);a.addCls(a._rotationClasses[a.getRotation()]);a.addCls(a._textAlignClasses[a.getTextAlign()])},getIconMarkup:function(){return this.getTpl('iconTpl').apply(this.getIconRenderData())},getIconRenderData:function(){var a=this,g=a.getIcon(),f=a.getIconCls(),b=a.getGlyph(),d=Ext._glyphFontFamily,e=a.getIconAlign(),c;if(typeof b==='string'){c=b.split('@');b=c[0];d=c[1]}return {id:a.id,ui:a.ui,itemCls:a._itemCls,iconUrl:g,iconCls:f,iconWrapCls:a._iconWrapCls,baseIconCls:a._baseIconCls,iconAlignCls:a._iconAlignClasses[e],glyph:b,glyphCls:b?a._glyphCls:'',glyphFontFamily:d}},initRenderData:function(){var a=this,c,b;b=Ext.apply({text:a.getText(),textElRole:a.textElRole,id:a.id,ui:a.ui,itemCls:a._itemCls,textCls:a._textCls,iconMarkup:null,iconBeforeTitle:null},Ext.Component.prototype.initRenderData.call(this));if(a._hasIcon()){c=a.getIconAlign();b.iconMarkup=a.getIconMarkup();b.iconBeforeTitle=c==='top'||c==='left'}return b},onAdded:function(a,f,e){var d=this,c=d._titleSuffix,b=a.baseCls;d.addCls([b+c,b+c+'-'+a.ui]);Ext.Component.prototype.onAdded.call(this,a,f,e)},updateGlyph:function(a,g){a=a||0;var b=this,f=b._glyphCls,c,d,e;b.glyph=a;if(b.rendered){b._syncIconVisibility();c=b.iconEl;if(typeof a==='string'){e=a.split('@');a=e[0];d=e[1]||Ext._glyphFontFamily}if(!a){c.dom.innerHTML='';c.removeCls(f)}else {if(g!==a){c.dom.innerHTML='&#'+a+';';c.addCls(f)}}if(d){c.setStyle('font-family',d)}if(b._didIconStateChange(g,a)){b.updateLayout()}}},updateIcon:function(a,c){a=a||'';var b=this,d;if(b.rendered&&a!==c){b._syncIconVisibility();d=b.iconEl;d.setStyle('background-image',a?'url('+a+')':'');if(b._didIconStateChange(c,a)){b.updateLayout()}}},updateIconAlign:function(d,f){var a=this,b=a.iconWrapEl,e,c;if(a.iconWrapEl){e=a.el;c=a._iconAlignClasses;if(f){b.removeCls(c[f])}b.addCls(c[d]);if(d==='top'||d==='left'){e.insertFirst(b)}else {e.appendChild(b)}a.updateLayout()}},updateIconCls:function(a,c){a=a||'';var b=this,d;if(b.rendered&&c!==a){b._syncIconVisibility();d=b.iconEl;if(c){d.removeCls(c)}d.addCls(a);if(b._didIconStateChange(c,a)){b.updateLayout()}}},updateRotation:function(d,e){var a=this,b,c;if(a.rendered){b=a.el;c=a._rotationClasses;a.removeCls(c[e]);a.addCls(c[d]);b.setHorizontal();if(d){b.setVertical(a._rotationAngles[d])}b.setStyle({right:'',left:'',top:'',height:'',width:''});a.lastBox=null;a.updateLayout()}},updateText:function(a){if(this.rendered){this.textEl.setHtml(a);this.updateLayout()}},updateTextAlign:function(d,c){var a=this,b=a._textAlignClasses;if(a.rendered){if(c){a.removeCls(b[c])}a.addCls(b[d]);a.updateLayout()}},privates:{_getVerticalAdjustDirection:function(){return 'left'},_didIconStateChange:function(c,b){var a=Ext.isEmpty(b);return Ext.isEmpty(c)?!a:a},_hasIcon:function(){return !!(this.getIcon()||this.getIconCls()||this.getGlyph())},_syncIconVisibility:function(){var a=this,f=a.el,e=a._hasIcon(),b=a.iconWrapEl,d,c;if(e&&!b){c=a.iconAlign;d=c==='left'||c==='top';f.dom.insertAdjacentHTML(d?'afterbegin':'beforeend',a.getIconMarkup());b=a.iconWrapEl=f[d?'first':'last']();a.iconEl=b.first()}if(b){b.setDisplayed(e)}}}},0,['title'],['component','box','title'],{'component':!0,'box':!0,'title':!0},['widget.title'],0,[Ext.panel,'Title'],0);Ext.cmd.derive('Ext.panel.Tool',Ext.Component,{isTool:!0,baseCls:'x-tool',disabledCls:'x-tool-disabled',toolPressedCls:'x-tool-pressed',toolOverCls:'x-tool-over',childEls:['toolEl'],renderTpl:[''],toolOwner:null,tooltipType:'qtip',stopEvent:!0,ariaRole:'button',focusable:!0,tabIndex:0,keyHandlers:{SPACE:'onClick',ENTER:'onClick'},cacheHeight:!0,cacheWidth:!0,initComponent:function(){var a=this;a.type=a.type||a.id;Ext.applyIf(a.renderData,{baseCls:a.baseCls,type:a.type});a.tooltip=a.tooltip||a.qtip;Ext.Component.prototype.initComponent.call(this)},afterRender:function(){var a=this,b;Ext.Component.prototype.afterRender.apply(this,arguments);a.el.on({click:a.onClick,mousedown:a.onMouseDown,mouseover:a.onMouseOver,mouseout:a.onMouseOut,scope:a});b=a.tooltip;if(b){a.setTooltip(b)}},tipAttrs:{qtip:'data-qtip'},setTooltip:function(b,d){var a=this,g=a.tooltip,f=a.tooltipType,h=a.id,e=a.el,c;if(g&&Ext.quickTipsActive&&Ext.isObject(g)){Ext.tip.QuickTipManager.unregister(h)}a.tooltip=b;if(d){a.tooltipType=d}if(b){if(Ext.quickTipsActive&&Ext.isObject(b)){Ext.tip.QuickTipManager.register(Ext.apply({target:h},b))}else {if(e){if(d&&f&&d!==f){c=a.tipAttrs[f]||'title';e.dom.removeAttribute(c)}c=a.tipAttrs[d||f]||'title';e.dom.setAttribute(c,b)}}if(c!=='title'&&a.ariaRole&&a.ariaRole!=='presentation'){if(e){e.dom.setAttribute('aria-label',b)}else {a.ariaRenderAttributes=a.ariaRenderAttributes||{};a.ariaRenderAttributes['aria-label']=b}}}},setType:function(b){var a=this,c=a.type;a.type=b;if(a.rendered){if(c){a.toolEl.removeCls(a.baseCls+'-'+c)}a.toolEl.addCls(a.baseCls+'-'+b)}else {a.renderData.type=b}return a},onDestroy:function(){var a=this,b=a.keyMap;a.setTooltip(null);delete a.toolOwner;Ext.Component.prototype.onDestroy.call(this)},privates:{onClick:function(b,c){var a=this;if(a.disabled){return !1}if(b.type!=='keydown'){a.el.removeCls(a.toolPressedCls+' '+a.toolOverCls)}if(a.stopEvent!==!1){b.stopEvent()}if(a.handler){Ext.callback(a.handler,a.scope,[b,c,a.ownerCt,a],0,a)}else {if(a.callback){Ext.callback(a.callback,a.scope,[a.toolOwner||a.ownerCt,a,b],0,a)}}a.fireEvent('click',a,b,a.toolOwner||a.ownerCt);return !0},onMouseDown:function(a){a.preventDefault();if(this.disabled){return !1}this.el.addCls(this.toolPressedCls)},onMouseOver:function(){if(this.disabled){return !1}this.el.addCls(this.toolOverCls)},onMouseOut:function(){this.el.removeCls(this.toolOverCls)}}},0,['tool'],['component','box','tool'],{'component':!0,'box':!0,'tool':!0},['widget.tool'],0,[Ext.panel,'Tool'],0);Ext.cmd.derive('Ext.util.KeyMap',Ext.Base,{alternateClassName:'Ext.KeyMap',eventName:'keydown',constructor:function(b){var a=this;if(arguments.length!==1||typeof b==='string'||b.dom||b.tagName||b===document||b.isComponent){a.legacyConstructor.apply(a,arguments);return}Ext.apply(a,b);a.bindings=[];if(!a.target.isComponent){a.target=Ext.get(a.target)}if(a.binding){a.addBinding(a.binding)}else {if(b.key){a.addBinding(b)}}a.enable()},legacyConstructor:function(d,b,c){var a=this;Ext.apply(a,{target:Ext.get(d),eventName:c||a.eventName,bindings:[]});if(b){a.addBinding(b)}a.enable()},addBinding:function(b){var a=this,e=b.key,c,d;if(a.processing){a.bindings=a.bindings.slice(0)}if(Ext.isArray(b)){for(c=0,d=b.length;c=i){return a}}}if(!g){return}a=c.findNextFocusableChild({beforeRender:h,items:b,step:!0});if(a){c.activateFocusable(a)}return a},clearFocusables:function(){var d=this,c=d.getFocusables(),e=c.length,a,b;for(b=0;b0?d0?d+b:e-1;for(;;a+=b){if(d<0&&(a>=e||a<0)){return null}else {if(a>=e){a=-1;continue}else {if(a<0){a=e;continue}else {if(a===d){return null}}}}c=g[a];if(!c||!c.focusable||c.disabled){continue}if(i||c.isFocusable&&c.isFocusable()){return c}}return null},getFocusableContainerEl:function(){return this.el},onFocusableChildAdd:function(a){if(this.enableFocusableContainer){return this.doFocusableChildAdd(a)}},activateFocusableContainerEl:function(a){a=a||this.getFocusableContainerEl();if(a){a.set({tabIndex:this.activeChildTabIndex})}},deactivateFocusableContainerEl:function(a){a=a||this.getFocusableContainerEl();if(a){a.set({tabIndex:undefined})}},isFocusableContainerActive:function(){var e=this,d=!1,c,b,a;c=e.getFocusableContainerEl();if(c&&c.isTabbable&&c.isTabbable()){d=!0}else {b=e.lastFocusedChild;a=b&&b.getFocusEl&&b.getFocusEl();if(a&&a.isTabbable&&a.isTabbable()){d=!0}}return d},doFocusableChildAdd:function(a){if(a.focusable){a.focusableContainer=this}},onFocusableChildRemove:function(a){if(this.enableFocusableContainer){return this.doFocusableChildRemove(a)}a.focusableContainer=null},doFocusableChildRemove:function(a){if(a===this.lastFocusedChild){this.lastFocusedChild=null;this.activateFocusableContainerEl()}},onFocusableContainerMousedown:function(c,b){var a=Ext.Component.fromElement(b);this.mousedownTimestamp=a===this?Ext.Date.now():0;if(a===this){c.preventDefault()}},onFocusEnter:function(f){var a=this,d=f.toComponent,c=a.mousedownTimestamp,e=50,b;if(!a.enableFocusableContainer){return null}a.mousedownTimestamp=0;if(d===a){if(!c||Ext.Date.now()-c>e){b=a.initDefaultFocusable();if(b){a.deactivateFocusableContainerEl();b.focus()}}}else {a.deactivateFocusableContainerEl()}return d},onFocusLeave:function(c){var a=this,b=a.lastFocusedChild;if(!a.enableFocusableContainer){return}if(!a.destroyed&&!a.destroying){a.clearFocusables();if(b&&!b.disabled){a.activateFocusable(b)}else {a.activateFocusableContainerEl()}}},beforeFocusableChildBlur:Ext.privateFn,afterFocusableChildBlur:Ext.privateFn,beforeFocusableChildFocus:function(b){var a=this;if(!a.enableFocusableContainer){return}a.clearFocusables();a.activateFocusable(b);if(b.needArrowKeys){a.guardFocusableChild(b)}},guardFocusableChild:function(c){var b=this,d=b.activeChildTabIndex,a;a=b.findNextFocusableChild({child:c,step:-1});if(a){a.setTabIndex(d)}a=b.findNextFocusableChild({child:c,step:1});if(a){a.setTabIndex(d)}},afterFocusableChildFocus:function(a){if(!this.enableFocusableContainer){return}this.lastFocusedChild=a},beforeFocusableChildEnable:Ext.privateFn,onFocusableChildEnable:function(b){var a=this;if(!a.enableFocusableContainer){return}if(b!==a.lastFocusedChild){a.deactivateFocusable(b);if(!a.isFocusableContainerActive()){a.activateFocusableContainerEl()}}},beforeFocusableChildDisable:function(c){var a=this,b;if(!a.enableFocusableContainer||a.destroying||a.destroyed){return}if(c.hasFocus){b=a.findNextFocusableChild({child:c})||c.findFocusTarget();if(b){b.focus()}}},onFocusableChildDisable:function(d){var a=this,c=a.lastFocusedChild,b;if(!a.enableFocusableContainer||a.destroying||a.destroyed){return}if(d===c){a.activateFocusableContainerEl()}b=a.findNextFocusableChild({step:1});if(!b){a.deactivateFocusableContainerEl()}},onFocusableChildShow:Ext.privateFn,onFocusableChildHide:Ext.privateFn,onFocusableChildMasked:Ext.privateFn,onFocusableChildDestroy:Ext.privateFn,onFocusableChildUpdate:Ext.privateFn}},0,0,0,0,0,0,[Ext.util,'FocusableContainer'],0);Ext.cmd.derive('Ext.panel.Header',Ext.panel.Bar,{isHeader:!0,defaultType:'tool',indicateDrag:!1,weight:-1,shrinkWrap:3,iconAlign:'left',titleAlign:'left',titlePosition:0,titleRotation:'default',autoEl:{role:'presentation'},beforeRenderConfig:{glyph:null,icon:null,iconCls:null,iconAlign:null,title:{$value:{xtype:'title',flex:1},merge:function(a,b){if(typeof a!=='object'){a={text:a}}return Ext.merge(b?Ext.Object.chain(b):{},a)}},titleAlign:null,titlePosition:null,titleRotation:null},headerCls:'x-header',initComponent:function(){var a=this,b=a.items,d=a.itemPosition,c=[a.headerCls];a.tools=a.tools||[];a.items=b=b?b.slice():[];if(d!==undefined){a._userItems=b.slice();a.items=b=[]}a.indicateDragCls=a.headerCls+'-draggable';if(a.indicateDrag){c.push(a.indicateDragCls)}a.addCls(c);a.syncNoBorderCls();a.enableFocusableContainer=!a.isAccordionHeader&&a.tools.length>0;if(a.enableFocusableContainer){a.ariaRole='toolbar'}Ext.Array.push(b,a.tools);a.tools.length=0;Ext.panel.Bar.prototype.initComponent.call(this);a.on({dblclick:a.onDblClick,click:a.onClick,element:'el',scope:a})},addTool:function(b){var a=this;a.add(Ext.ComponentManager.create(b,'tool'));if(!a.isAccordionHeader&&a.tools.length>0&&!a.enableFocusableContainer){a.enableFocusableContainer=!0;a.ariaRole='toolbar';if(a.rendered){a.ariaEl.dom.setAttribute('role','toolbar');a.initFocusableContainer(!0)}}},afterLayout:function(){var a=this,e,b,c,d;if(a.vertical){b=a.frameTR;if(b){e=a.frameBR;c=a.frameTL;d=a.getWidth()-b.getPadding('r')-(c?c.getPadding('l'):a.el.getBorderWidth('l'))+'px';e.setStyle('background-position-x',d);b.setStyle('background-position-x',d)}}Ext.panel.Bar.prototype.afterLayout.call(this)},applyTitle:function(a,d){var b=this,c,e;a=a||'';c=typeof a==='string';if(c){a={text:a}}if(d){Ext.suspendLayouts();d.setConfig(a);Ext.resumeLayouts(!0);a=d}else {if(c){a.xtype='title'}a.ui=b.ui;e='rotation' in a;a.id=b.id+'-title';if(b.isAccordionHeader){a.ariaRole='tab';a.textElRole=null;a.focusable=!0}a=Ext.create(a);if(!e&&b.vertical&&b.titleRotation==='default'){a.rotation=1}}return a},applyTitlePosition:function(b){var a=this.items.getCount();if(this._titleInItems){--a}return Math.max(Math.min(b,a),0)},beforeLayout:function(){Ext.panel.Bar.prototype.beforeLayout.call(this);this.syncBeforeAfterTitleClasses()},beforeRender:function(){var a=this,b=a.itemPosition;a.protoEl.unselectable();Ext.panel.Bar.prototype.beforeRender.call(this);if(b!==undefined){a.insert(b,a._userItems)}},getTools:function(){return this.tools.slice()},onAdd:function(a,c){var b=this.tools;Ext.panel.Bar.prototype.onAdd.call(this,a,c);if(a.isTool){b.push(a);b[a.type]=a}},onAdded:function(a,c,b){this.syncNoBorderCls();Ext.panel.Bar.prototype.onAdded.call(this,a,c,b)},onRemoved:function(a,c,b){this.syncNoBorderCls();Ext.panel.Bar.prototype.onRemoved.call(this,a,c,b)},setDock:function(e){var a=this,c=a.getTitle(),b=a.getTitleRotation(),d=c.getRotation();Ext.suspendLayouts();Ext.panel.Bar.prototype.setDock.call(this,e);if(b==='default'){b=a.vertical?1:0;if(b!==d){c.setRotation(b)}if(a.rendered){a.resetItemMargins()}}Ext.resumeLayouts(!0)},updateGlyph:function(a){this.getTitle().setGlyph(a)},updateIcon:function(a){this.getTitle().setIcon(a)},updateIconAlign:function(a,b){this.getTitle().setIconAlign(a)},updateIconCls:function(a){this.getTitle().setIconCls(a)},updateTitle:function(a,b){if(!b){this.insert(this.getTitlePosition(),a);this._titleInItems=!0}this.titleCmp=a},updateTitleAlign:function(a,b){this.getTitle().setTextAlign(a)},updateTitlePosition:function(a){this.insert(a,this.getTitle())},updateTitleRotation:function(a){if(a==='default'){a=this.vertical?1:0}this.getTitle().setRotation(a)},privates:{fireClickEvent:function(c,a){var b='.'+Ext.panel.Tool.prototype.baseCls;if(!a.getTarget(b)){this.fireEvent(c,this,a)}},getFramingInfoCls:function(){var a=this,c=Ext.panel.Bar.prototype.getFramingInfoCls.call(this),b=a.ownerCt;if(!a.expanding&&b&&(b.collapsed||a.isCollapsedExpander)){c+='-'+b.collapsedCls}return c+'-'+a.dock},onClick:function(a){this.fireClickEvent('click',a)},onDblClick:function(a){this.fireClickEvent('dblclick',a)},onFocusableContainerMousedown:function(c,b){var a=Ext.Component.fromElement(b);if(a===this){c.preventDefault()}else {this.mixins.focusablecontainer.onFocusableContainerMousedown.apply(this,arguments)}},syncBeforeAfterTitleClasses:function(l){var c=this,j=c.items,i=j.items,h=c.getTitlePosition(),k=i.length,g=j.generation,f=c.syncBeforeAfterGen,e,d,b,a;if(!l&&f===g){return}c.syncBeforeAfterGen=g;for(b=0;bh){if(f){a.removeCls(d)}a.addCls(e)}}}},syncNoBorderCls:function(){var a=this,b=this.ownerCt,c=a.headerCls+'-noborder';if(b?b.border===!1&&!b.frame:a.border===!1){a.addCls(c)}else {a.removeCls(c)}}}},0,['header'],['component','box','container','header'],{'component':!0,'box':!0,'container':!0,'header':!0},['widget.header'],[[Ext.util.FocusableContainer.prototype.mixinId||Ext.util.FocusableContainer.$className,Ext.util.FocusableContainer]],[Ext.panel,'Header'],0);Ext.cmd.derive('Ext.layout.container.boxOverflow.None',Ext.Base,{alternateClassName:'Ext.layout.boxOverflow.None',factoryConfig:{defaultType:'none'},isBoxOverflowHandler:!0,$configPrefixed:!1,$configStrict:!1,constructor:function(a){this.initConfig(a)},handleOverflow:Ext.emptyFn,clearOverflow:Ext.emptyFn,beginLayout:Ext.emptyFn,beginLayoutCycle:Ext.emptyFn,calculate:function(b){var c=this,d=b.state.boxPlan,a;if(d&&d.tooNarrow){a=c.handleOverflow(b);if(a){if(a.reservedSpace){c.layout.publishInnerCtSize(b,a.reservedSpace)}}}else {c.clearOverflow()}},completeLayout:Ext.emptyFn,finishedLayout:function(e){var b=this,d=b.layout.owner,c,a;if(d.hasListeners.overflowchange){c=d.query('>[hidden]');a=c.length;if(a!==b.lastHiddenCount){d.fireEvent('overflowchange',b.lastHiddenCount,a,c);b.lastHiddenCount=a}}},onRemove:Ext.emptyFn,getItem:function(a){return this.layout.owner.getComponent(a)},getOwnerType:function(b){var a;if(b.isToolbar){a='toolbar'}else {if(b.isTabBar){a='tab-bar'}else {if(b.isMenu){a='menu'}else {if(b.isBreadcrumb){a='breadcrumb'}else {a=b.getXType()}}}}return a},getPrefixConfig:Ext.emptyFn,getSuffixConfig:Ext.emptyFn,getOverflowCls:function(){return ''},setVertical:function(){var b=this,a=b.layout,c=a.innerCt;c.removeCls(b.getOverflowCls(a.oppositeDirection));c.addCls(b.getOverflowCls(a.direction))}},1,0,0,0,['box.overflow.None','box.overflow.none'],[[Ext.mixin.Factoryable.prototype.mixinId||Ext.mixin.Factoryable.$className,Ext.mixin.Factoryable]],[Ext.layout.container.boxOverflow,'None',Ext.layout.boxOverflow,'None'],0);Ext.cmd.derive('Ext.layout.container.boxOverflow.Scroller',Ext.layout.container.boxOverflow.None,{alternateClassName:'Ext.layout.boxOverflow.Scroller',animateScroll:!1,scrollIncrement:20,wheelIncrement:10,scrollRepeatInterval:60,scrollDuration:400,scrollerCls:'x-box-scroller',beforeSuffix:'-before-scroller',afterSuffix:'-after-scroller',constructor:function(b){var a=this;a.mixins.observable.constructor.call(a,b);a.scrollPosition=0;a.scrollSize=0},getPrefixConfig:function(){return {role:'presentation',id:this.layout.owner.id+this.beforeSuffix,cls:this.createScrollerCls('beforeX'),style:'display:none'}},getSuffixConfig:function(){return {role:'presentation',id:this.layout.owner.id+this.afterSuffix,cls:this.createScrollerCls('afterX'),style:'display:none'}},createScrollerCls:function(g){var c=this,d=c.layout,b=d.owner,e=c.getOwnerType(b),a=c.scrollerCls,f=a+' '+a+'-'+d.names[g]+' '+a+'-'+e+' '+a+'-'+e+'-'+b.ui;if(b.plain){f+=' '+a+'-plain'}return f},getOverflowCls:function(a){return this.scrollerCls+'-body-'+a},beginLayout:function(a){a.innerCtScrollPos=this.getScrollPosition();Ext.layout.container.boxOverflow.None.prototype.beginLayout.apply(this,arguments)},finishedLayout:function(a){var b=this,f=a.state.boxPlan,e=b.layout,d=e.names,g=Math.min(b.getMaxScrollPosition(),a.innerCtScrollPos),c;if(f&&f.tooNarrow){c=a.childItems[a.childItems.length-1].props;b.scrollSize=c[d.x]+c[d.width];b.updateScrollButtons();e.innerCt[d.setScrollLeft](g)}Ext.layout.container.boxOverflow.None.prototype.finishedLayout.call(this,a)},handleOverflow:function(i){var a=this,d=a.layout.names,h=d.getWidth,f=d.parallelMargins,g,e,b,c;a.showScrollers();b=a.getBeforeScroller();c=a.getAfterScroller();g=b[h]()+c[h]()+b.getMargin(f)+c.getMargin(f);e=i.targetContext.getPaddingInfo()[d.width];return {reservedSpace:Math.max(g-e,0)}},getBeforeScroller:function(){var a=this;return a._beforeScroller||(a._beforeScroller=a.createScroller(a.beforeSuffix,'beforeRepeater','scrollLeft'))},getAfterScroller:function(){var a=this;return a._afterScroller||(a._afterScroller=a.createScroller(a.afterSuffix,'afterRepeater','scrollRight'))},createScroller:function(g,f,e){var b=this,d=b.layout.owner,c=b.scrollerCls,a;a=d.el.getById(d.id+g);a.addClsOnOver(c+'-hover');a.addClsOnClick(c+'-pressed');a.setVisibilityMode(Ext.Element.DISPLAY);b[f]=new Ext.util.ClickRepeater(a,{interval:b.scrollRepeatInterval,handler:e,scope:b});return a},createWheelListener:function(){var a=this;a.wheelListener=a.layout.innerCt.on('mousewheel',a.onMouseWheel,a,{destroyable:!0})},onMouseWheel:function(a){a.stopEvent();this.scrollBy(this.getWheelDelta(a)*this.wheelIncrement*-1,!1)},getWheelDelta:function(a){return a.getWheelDelta()},clearOverflow:function(){this.hideScrollers()},showScrollers:function(){var a=this;if(!a.wheelListener){a.createWheelListener()}a.getBeforeScroller().show();a.getAfterScroller().show();a.layout.owner.addClsWithUI(a.layout.direction==='vertical'?'vertical-scroller':'scroller')},hideScrollers:function(){var a=this,b=a.getBeforeScroller(),c=a.getAfterScroller();if(b){b.hide();c.hide();a.layout.owner.removeClsWithUI(a.layout.direction==='vertical'?'vertical-scroller':'scroller')}},destroy:function(){Ext.destroyMembers(this,'beforeRepeater','afterRepeater','_beforeScroller','_afterScroller','wheelListener');this.callParent()},scrollBy:function(b,a){this.scrollTo(this.getScrollPosition()+b,a)},getScrollAnim:function(){return {duration:this.scrollDuration,callback:this.updateScrollButtons,scope:this}},updateScrollButtons:function(){var a=this,c=a.getBeforeScroller(),d=a.getAfterScroller(),b;if(!c||!d){return}b=a.scrollerCls+'-disabled';c[a.atExtremeBefore()?'addCls':'removeCls'](b);d[a.atExtremeAfter()?'addCls':'removeCls'](b);a.scrolling=!1},scrollLeft:function(){this.scrollBy(-this.scrollIncrement,!1)},scrollRight:function(){this.scrollBy(this.scrollIncrement,!1)},getScrollPosition:function(){var b=this,c=b.layout,a;if(isNaN(b.scrollPosition)){a=c.innerCt[c.names.getScrollLeft]()}else {a=b.scrollPosition}return a},getMaxScrollPosition:function(){var c=this,b=c.layout,a=c.scrollSize-b.innerCt.lastBox[b.names.width];return a<0?0:a},atExtremeBefore:function(){return !this.getScrollPosition()},atExtremeAfter:function(){return this.getScrollPosition()>=this.getMaxScrollPosition()},setVertical:function(){var c=this,d=c.getBeforeScroller(),e=c.getAfterScroller(),b=c.layout.names,a=c.scrollerCls;d.removeCls(a+'-'+b.beforeY);e.removeCls(a+'-'+b.afterY);d.addCls(a+'-'+b.beforeX);e.addCls(a+'-'+b.afterX);Ext.layout.container.boxOverflow.None.prototype.setVertical.call(this)},scrollTo:function(g,b){var a=this,d=a.layout,e=d.names,f=a.getScrollPosition(),c=Ext.Number.constrain(g,0,a.getMaxScrollPosition());if(c!==f&&!a.scrolling){a.scrollPosition=NaN;if(b===undefined){b=a.animateScroll}d.innerCt[e.scrollTo](e.beforeScrollX,c,b?a.getScrollAnim():!1);if(b){a.scrolling=!0}else {a.updateScrollButtons()}a.fireEvent('scroll',a,c,b?a.getScrollAnim():!1)}},scrollToItem:function(a,i){var c=this,e=c.layout,h=e.owner,f=e.names,j=e.innerCt,d,g,b;a=c.getItem(a);if(a!==undefined){if(a===h.items.first()){b=0}else {if(a===h.items.last()){b=c.getMaxScrollPosition()}else {d=c.getItemVisibility(a);if(!d.fullyVisible){g=a.getBox(!1,!0);b=g[f.x];if(d.hiddenEnd){b-=j[f.getWidth]()-g[f.width]}}}}if(b!==undefined){c.scrollTo(b,i)}}},getItemVisibility:function(i){var d=this,h=d.getItem(i).getBox(!0,!0),g=d.layout,c=g.names,b=h[c.x],f=b+h[c.width],a=d.getScrollPosition(),e=a+g.innerCt[c.getWidth]();return {hiddenStart:be,fullyVisible:b>=a&&f<=e}}},1,0,0,0,['box.overflow.Scroller','box.overflow.scroller'],[['observable',Ext.mixin.Observable]],[Ext.layout.container.boxOverflow,'Scroller',Ext.layout.boxOverflow,'Scroller'],0);Ext.cmd.derive('Ext.dd.DragDropManager',Ext.Base,{singleton:!0,alternateClassName:['Ext.dd.DragDropMgr','Ext.dd.DDM'],ids:{},handleIds:{},dragCurrent:null,dragOvers:{},deltaX:0,deltaY:0,preventDefault:!0,stopPropagation:!0,initialized:!1,locked:!1,init:function(){this.initialized=!0},POINT:0,INTERSECT:1,mode:0,notifyOccluded:!1,dragCls:'x-dd-drag-current',_execOnAll:function(f,g){var c=this.ids,d,e,b,a;for(d in c){if(c.hasOwnProperty(d)){a=c[d];for(e in a){if(a.hasOwnProperty(e)){b=a[e];if(!this.isTypeOfDD(b)){continue}b[f].apply(b,g)}}}}},addListeners:function(){var a=this;a.init();Ext.getDoc().on({mouseup:a.handleMouseUp,mousemove:{fn:a.handleMouseMove,capture:!1},dragstart:a.preventDrag,drag:a.preventDrag,dragend:a.preventDrag,capture:!0,scope:a});Ext.getWin().on({unload:a._onUnload,resize:a._onResize,scope:a})},preventDrag:function(a){if(this.isMouseDown){a.stopPropagation()}},_onResize:function(a){this._execOnAll('resetConstraints',[])},lock:function(){this.locked=!0},unlock:function(){this.locked=!1},isLocked:function(){return this.locked},locationCache:{},useCache:!0,clickPixelThresh:8,dragThreshMet:!1,clickTimeout:null,startX:0,startY:0,regDragDrop:function(b,a){if(!this.initialized){this.init()}if(!this.ids[a]){this.ids[a]={}}this.ids[a][b.id]=b},removeDDFromGroup:function(c,a){if(!this.ids[a]){this.ids[a]={}}var b=this.ids[a];if(b&&b[c.id]){delete b[c.id]}},_remove:function(b,f){var a=this,d=a.ids,e=b.groups,c;if(a.clearingAll){return}if(a.dragCurrent===b){a.dragCurrent=null}for(c in e){if(e.hasOwnProperty(c)){if(f){delete d[c]}else {if(d[c]){delete d[c][b.id]}}}}delete a.handleIds[b.id];delete a.locationCache[b.id]},regHandle:function(a,b){if(!this.handleIds[a]){this.handleIds[a]={}}this.handleIds[a][b]=b},isDragDrop:function(a){return this.getDDById(a)?!0:!1},getRelated:function(f,e){var b=[],c,d,a;for(c in f.groups){for(d in this.ids[c]){a=this.ids[c][d];if(!this.isTypeOfDD(a)){continue}if(!e||a.isTarget){b[b.length]=a}}}return b},isLegalTarget:function(e,d){var b=this.getRelated(e,!0),a,c;for(a=0,c=b.length;aa.clickPixelThresh||e>a.clickPixelThresh){a.startDrag(a.startX,a.startY)}}if(a.dragThreshMet){c.b4Drag(b);c.onDrag(b);if(!c.moveOnly){a.fireEvents(b,!1)}}a.stopEvent(b);return !0},fireEvents:function(e,t){var d=this,s=Ext.supports.Touch,c=d.dragCurrent,l=d.currentPoint,v=l.x,w=l.y,j=[],r=[],h=[],i=[],g=[],k=[],u=s?document.documentElement.clientWidth/window.innerWidth:1,p,b,o,q,a,f,n,m;if(!c||c.isLocked()){return}m=!(c.deltaX<0||c.deltaY<0);if(s||!d.notifyOccluded&&(!Ext.supports.CSSPointerEvents||Ext.isIE10m||Ext.isOpera)&&m){p=c.getDragEl();if(m){p.style.visibility='hidden'}e.target=document.elementFromPoint(v/u,w/u);if(m){p.style.visibility='visible'}}for(a in d.dragOvers){b=d.dragOvers[a];delete d.dragOvers[a];if(!d.isTypeOfDD(b)||b.destroyed){continue}if(d.notifyOccluded){if(!this.isOverTarget(l,b,d.mode)){h.push(b)}}else {if(!e.within(b.getEl())){h.push(b)}}r[a]=!0}for(n in c.groups){if('string'!==typeof n){continue}for(a in d.ids[n]){b=d.ids[n][a];if(d.isTypeOfDD(b)&&(o=b.getEl())&&b.isTarget&&!b.isLocked()&&Ext.fly(o).isVisible(!0)&&(b!==c||c.ignoreSelf===!1)){if(d.notifyOccluded){if((b.zIndex=d.getZIndex(o))!==-1){q=!0}j.push(b)}else {if(e.within(b.getEl())){j.push(b);break}}}}}if(q){Ext.Array.sort(j,d.byZIndex)}for(a=0,f=j.length;a','',''],isSplitter:!0,baseCls:'x-splitter',collapsedClsInternal:'x-splitter-collapsed',canResize:!0,collapsible:null,collapseOnDblClick:!0,defaultSplitMin:40,defaultSplitMax:1000,collapseTarget:'next',horizontal:!1,vertical:!1,size:5,tracker:null,ariaRole:'separator',focusable:!0,tabIndex:0,getTrackerConfig:function(){return Ext.apply({xclass:'Ext.resizer.SplitterTracker',el:this.el,splitter:this},this.tracker)},beforeRender:function(){var a=this,c=a.getCollapseTarget(),b=a.collapsible,d;Ext.Component.prototype.beforeRender.call(this);if(c.collapsed){a.addCls(a.collapsedClsInternal)}if(!a.canResize){a.addCls(a.baseCls+'-noresize')}Ext.applyIf(a.renderData,{collapseDir:a.getCollapseDirection(),collapsible:b!==null?b:c.collapsible});a.ariaRenderAttributes=a.ariaRenderAttributes||{};a.ariaRenderAttributes['aria-orientation']=a.orientation;a.protoEl.unselectable()},onRender:function(){var a=this,b;Ext.Component.prototype.onRender.apply(this,arguments);if(a.performCollapse!==!1){if(a.renderData.collapsible){a.mon(a.collapseEl,'click',a.toggleTargetCmp,a)}if(a.collapseOnDblClick){a.mon(a.el,'dblclick',a.toggleTargetCmp,a)}}a.getCollapseTarget().on({collapse:a.onTargetCollapse,expand:a.onTargetExpand,beforeexpand:a.onBeforeTargetExpand,beforecollapse:a.onBeforeTargetCollapse,scope:a});if(a.canResize){a.tracker=Ext.create(a.getTrackerConfig());a.relayEvents(a.tracker,['beforedragstart','dragstart','dragend'])}b=a.collapseEl;if(b){b.lastCollapseDirCls=a.collapseDirProps[a.collapseDirection].cls}},getCollapseDirection:function(){var b=this,a=b.collapseDirection,c,f,d,e;if(!a){c=b.collapseTarget;if(c.isComponent){a=c.collapseDirection}if(!a){e=b.ownerCt.layout.type;if(c.isComponent){d=b.ownerCt.items;f=Number(d.indexOf(c)===d.indexOf(b)-1)<<1|Number(e==='hbox')}else {f=Number(b.collapseTarget==='prev')<<1|Number(e==='hbox')}a=['bottom','right','top','left'][f]}b.collapseDirection=a}b.setOrientation(a==='top'||a==='bottom'?'horizontal':'vertical');return a},getCollapseTarget:function(){var a=this;return a.collapseTarget.isComponent?a.collapseTarget:a.collapseTarget==='prev'?a.previousSibling():a.nextSibling()},setCollapseEl:function(b){var a=this.collapseEl;if(a){a.setDisplayed(b)}},onBeforeTargetExpand:function(a){this.setCollapseEl('none')},onBeforeTargetCollapse:function(){this.setCollapseEl('none')},onTargetCollapse:function(b){var a=this;if(b===a.getCollapseTarget()&&b[a.orientation==='vertical'?'collapsedHorizontal':'collapsedVertical']()){a.el.addCls(a.collapsedClsInternal+' '+(a.collapsedCls||''))}a.setCollapseEl('')},onTargetExpand:function(b){var a=this;a.el.removeCls(a.collapsedClsInternal+' '+(a.collapsedCls||''));a.setCollapseEl('')},collapseDirProps:{top:{cls:'x-layout-split-top'},right:{cls:'x-layout-split-right'},bottom:{cls:'x-layout-split-bottom'},left:{cls:'x-layout-split-left'}},orientationProps:{horizontal:{opposite:'vertical',fixedAxis:'height',stretchedAxis:'width'},vertical:{opposite:'horizontal',fixedAxis:'width',stretchedAxis:'height'}},applyCollapseDirection:function(){var c=this,a=c.collapseEl,d=c.collapseDirProps[c.collapseDirection],b;if(a){b=a.lastCollapseDirCls;if(b){a.removeCls(b)}a.addCls(a.lastCollapseDirCls=d.cls)}},applyOrientation:function(){var a=this,e=a.orientation,b=a.orientationProps[e],f=a.size,d=b.fixedAxis,c=b.stretchedAxis,g=a.baseCls+'-';a[e]=!0;a[b.opposite]=!1;if(!a.hasOwnProperty(d)||a[d]==='100%'){a[d]=f}if(!a.hasOwnProperty(c)||a[c]===f){a[c]='100%'}a.removeCls(g+b.opposite);a.addCls(g+e)},setOrientation:function(b){var a=this;if(a.orientation!==b){a.orientation=b;a.applyOrientation()}},updateOrientation:function(){delete this.collapseDirection;this.getCollapseDirection();this.applyCollapseDirection()},toggleTargetCmp:function(d,e){var a=this.getCollapseTarget(),c=a.placeholder,b;if(Ext.isFunction(a.expand)&&Ext.isFunction(a.collapse)){if(c&&!c.hidden){b=!0}else {b=!a.hidden}if(b){if(a.collapsed){a.expand()}else {if(a.collapseDirection){a.collapse()}else {a.collapse(this.renderData.collapseDir)}}}}},setSize:function(){var a=this;Ext.Component.prototype.setSize.apply(this,arguments);if(Ext.isIE&&a.el){a.el.repaint()}},beforeDestroy:function(){Ext.destroy(this.tracker);Ext.Component.prototype.beforeDestroy.call(this)}},0,['splitter'],['component','box','splitter'],{'component':!0,'box':!0,'splitter':!0},['widget.splitter'],0,[Ext.resizer,'Splitter'],0);Ext.define('Ext.theme.neptune.resizer.Splitter',{override:'Ext.resizer.Splitter',size:8});Ext.cmd.derive('Ext.layout.container.Box',Ext.layout.container.Container,{alternateClassName:'Ext.layout.BoxLayout',type:'box',config:{align:'begin',constrainAlign:!1,enableSplitters:!0,overflowHandler:{$value:null,merge:function(a,b){if(typeof a==='string'){a={type:a}}return Ext.merge(b?Ext.Object.chain(b):{},a)}},padding:0,pack:'start',stretchMaxPartner:undefined,vertical:!1,alignRoundingMethod:'round'},itemCls:'x-box-item',targetCls:'x-box-layout-ct',targetElCls:'x-box-target',innerCls:'x-box-inner',manageMargins:!0,createsInnerCt:!0,childEls:['innerCt','targetEl'],renderTpl:['{%var oc,l=values.$comp.layout,oh=l.overflowHandler;if (oh && oh.getPrefixConfig!==Ext.emptyFn) {if(oc=oh.getPrefixConfig())dh.generateMarkup(oc, out)}%}{%if (oh && oh.getSuffixConfig!==Ext.emptyFn) {if(oc=oh.getSuffixConfig())dh.generateMarkup(oc, out)}%}',{disableFormats:!0,definitions:'var dh=Ext.DomHelper;'}],constructor:function(c){var a=this,b;Ext.layout.container.Container.prototype.constructor.apply(this,arguments);a.setVertical(a.vertical);a.flexSortFn=a.flexSort.bind(a);b=typeof a.padding;if(b==='string'||b==='number'){a.padding=Ext.util.Format.parseBox(a.padding);a.padding.height=a.padding.top+a.padding.bottom;a.padding.width=a.padding.left+a.padding.right}},_beginRe:/^(?:begin|left|top)$/,_centerRe:/^(?:center|middle)$/,_endRe:/^(?:end|right|bottom)$/,_percentageRe:/^\s*(\d+(?:\.\d*)?)\s*[%]\s*$/,getItemSizePolicy:function(h,b){var a=this,f=a.sizePolicy,g=a.align,p=h.flex,c=g,o=a.names,e=o.height,m=o.width,q=h[m],n=h[e],d=a._percentageRe,i=d.test(q),l=g==='stretch',j=g==='stretchmax',k=a.constrainAlign;if(!b&&(l||p||i||k&&!j)){b=a.owner.getSizeModel()}if(l){if(!d.test(n)&&b[e].shrinkWrap){c='stretchmax'}}else {if(!j){if(d.test(n)){c='stretch'}else {if(k&&!b[e].shrinkWrap){c='stretchmax'}else {c=''}}}}if(p||i){if(!b[m].shrinkWrap){f=f.flex}}return f[c]},flexSort:function(o,p){var k=this.names.maxWidth,l=this.names.minWidth,j=Infinity,c=o.target,d=p.target,m=c.flex,n=d.flex,a=0,g,i,f,h,e,b;f=c[k]||j;h=d[k]||j;g=c[l]||0;i=d[l]||0;e=isFinite(g)||isFinite(i);b=isFinite(f)||isFinite(h);if(e||b){if(b){a=f-h}if(a===0&&e){a=i-g}if(a===0){if(b){a=n-m}else {a=m-n}}}return a},isItemBoxParent:function(a){return !0},isItemShrinkWrap:function(a){return !0},roundFlex:function(a){return Math.floor(a)},beginCollapse:function(a){var b=this;if(b.direction==='vertical'&&a.collapsedVertical()){a.collapseMemento.capture(['flex']);delete a.flex}else {if(b.direction==='horizontal'&&a.collapsedHorizontal()){a.collapseMemento.capture(['flex']);delete a.flex}}},beginExpand:function(a){a.collapseMemento.restore(['flex'])},beginLayout:function(a){var c=this,f=c.owner,b=f.stretchMaxPartner,h=c.innerCt.dom.style,i=c.names,g=c.overflowHandler,e=f.getScrollable(),d;a.boxNames=i;if(g){g.beginLayout(a)}if(typeof b==='string'){b=Ext.getCmp(b)||f.query(b)[0]}a.stretchMaxPartner=b&&a.context.getCmp(b);Ext.layout.container.Container.prototype.beginLayout.apply(this,arguments);a.innerCtContext=a.getEl('innerCt',c);a.targetElContext=a.getEl('targetEl',c);if(e){a.ownerScrollable=e;d=e.getPosition();if(d.x||d.y){a.scrollRestore=d}}h.width=h.height=''},beginLayoutCycle:function(a,l){var c=this,i=a.state,g=a.ownerScrollable,b=c.align,e=a.boxNames,d=c.pack,k=c._centerRe,j=c.overflowHandler,m=a.state.canScroll,h,f;if(j){j.beginLayoutCycle(a,l)}Ext.layout.container.Container.prototype.beginLayoutCycle.apply(this,arguments);a.parallelSizeModel=h=a[e.widthModel];a.perpendicularSizeModel=f=a[e.heightModel];a.boxOptions={align:b={stretch:b==='stretch',stretchmax:b==='stretchmax',center:k.test(b),bottom:c._endRe.test(b)},pack:d={center:k.test(d),end:d==='end'}};if(g){if(!m){i.canScroll={parallel:!h.shrinkWrap&&g[e.getX](),perpendicular:!f.shrinkWrap&&g[e.getY]()}}if(!i.actualScroll){i.actualScroll={parallel:!1,perpendicular:!1}}}if(b.stretch&&f.shrinkWrap){b.stretchmax=!0;b.stretch=!1}b.nostretch=!(b.stretch||b.stretchmax);if(h.shrinkWrap){d.center=d.end=!1}c.cacheFlexes(a);c.targetEl.setWidth(20000)},cacheFlexes:function(a){var u=this,d=a.boxNames,x=d.widthModel,w=d.heightModel,z=a.boxOptions.align.nostretch,s=0,r=a.childItems,v=r.length,h=[],t=0,g=0,o=0,p=d.minWidth,y=d.minHeight,q=u._percentageRe,n=0,m=0,b,c,l,f,i,j,k,e;while(v--){c=r[v];b=c.target;j=c[x];if(j.calculated){c.flex=l=b.flex;if(l){s+=l;h.push(c);t+=b[p]||0}else {f=q.exec(b[d.width]);c.percentageParallel=parseFloat(f[1])/100;++n}}if(j.configured){k=b[d.width]}else {k=b[p]||0}o+=k;i=c[w];if(z&&i.calculated){f=q.exec(b[d.height]);c.percentagePerpendicular=parseFloat(f[1])/100;++m}if(i.configured){e=b[d.height]}else {e=b[y]||0}if(e>g){g=e}}a.flexedItems=h;a.flexedMinWidth=t;a.smallestWidth=o;a.smallestHeight=g;a.totalFlex=s;a.percentageWidths=n;a.percentageHeights=m;Ext.Array.sort(h,u.flexSortFn)},calculate:function(b){var c=this,f=b.boxNames,a=b.state,h=a.actualScroll,g=a.needsScroll,e=a.canScroll,d=a.boxPlan||(a.boxPlan={}),i=c.overflowHandler;d.targetSize=c.getContainerSize(b);if(e&&!g){a.needsScroll=g={parallel:e.parallel&&d.targetSize[f.width]j){a.invalidate({before:K,after:L,layout:l,childHeight:j,names:d});c.state.parallelDone=!1}if(isNaN(b=o(b,g+i,a.target[d.minHeight]||0))){return !1}}}if(v){b+=q;c[d.hasOverflowX]=!0;c.target.componentLayout[d.setHeightInDom]=!0;c[d.invalidateScrollX]=Ext.isIE8}p=c.stretchMaxPartner;if(p){c.setProp('maxChildHeight',b);w=p.childItems;if(w&&w.length){b=o(b,p.getProp('maxChildHeight'));if(isNaN(b)){return !1}}}c[d.setContentHeight](b+l.padding[e]+c.targetContext.getPaddingInfo()[e]);if(v){b-=q}if(b>y[e]&&H&&H.perpendicular){C.actualScroll.perpendicular=!0}t.maxSize=b;if(O){f=b}else {if(B||A||D){if(I){f=h?b:j}else {f=h?b:o(j,b)}f-=c.innerCtContext.getBorderInfo()[e]}}for(k=0;k0){n=u+Math[l.alignRoundingMethod](s/2)}}else {if(A){n=o(0,f-n-a.props[e])}}}a.setProp(M,n)}return !0},onBeforeConstrainInvalidateChild:function(b,c){var a=c.names.heightModel;if(!b[a].constrainedMin){b[a]=Ext.layout.SizeModel.calculated}},onAfterConstrainInvalidateChild:function(a,c){var b=c.names;a.setProp(b.beforeY,0);if(a[b.heightModel].calculated){a[b.setHeight](c.childHeight)}},calculateStretchMax:function(k,c,o){var f=this,h=c.height,l=c.width,g=k.childItems,n=g.length,m=o.maxSize,i=f.onBeforeStretchMaxInvalidateChild,j=f.onAfterStretchMaxInvalidateChild,a,b,d,e;for(d=0;d':{xtype:'tbfill',height:0}},1:{'->':{xtype:'tbfill',width:0}}}},initComponent:function(){var a=this,b=a.layout,c=a.vertical;if(c===undefined){a.vertical=c=a.dock==='right'||a.dock==='left'}a.layout=b=Ext.applyIf(Ext.isString(b)?{type:b}:b||{},{type:c?'vbox':'hbox',align:c?'stretchmax':'middle'});if(a.overflowHandler){b.overflowHandler=a.overflowHandler}else {if(a.enableOverflow){b.overflowHandler='menu'}}if(c){a.addClsWithUI('vertical')}if(a.ui==='footer'){a.ignoreBorderManagement=!0}Ext.container.Container.prototype.initComponent.call(this)},getRefItems:function(d){var c=this,b=Ext.container.Container.prototype.getRefItems.apply(this,arguments),e=c.layout,a;if(d&&(c.enableOverflow||c.overflowHandler==='menu')){a=e.overflowHandler;if(a&&a.menu){b=b.concat(a.menu.getRefItems(d))}}return b},lookupComponent:function(a){var d=arguments,b,c;if(typeof a==='string'){c=Ext.toolbar.Toolbar;b=c.shortcutsHV[this.vertical?1:0][a]||c.shortcuts[a];if(typeof b==='string'){a={xtype:b}}else {if(b){a=Ext.apply({},b)}else {a={xtype:'tbtext',text:a}}}this.applyDefaults(a);d=[a]}return Ext.container.Container.prototype.lookupComponent.apply(this,d)},onBeforeAdd:function(a){var b=this,d=b.ui==='footer',c=d?b.defaultFooterButtonUI:b.defaultButtonUI;if(a.isSegmentedButton){if(a.getDefaultUI()==='default'&&!a.config.hasOwnProperty('defaultUI')){a.setDefaultUI(c)}}else {if(a.ui==='default'&&!a.hasOwnProperty('ui')){if(a.isButton){a.ui=c}else {if(a.isFormField){a.ui=d?b.defaultFooterFieldUI:b.defaultFieldUI}}}}if(a instanceof Ext.toolbar.Separator){a.setUI(b.vertical?'vertical':'horizontal')}Ext.container.Container.prototype.onBeforeAdd.apply(this,arguments)},onAdd:function(a){if(a.needArrowKeys&&this.enableFocusableContainer){this.enableFocusableContainer=!1}Ext.container.Container.prototype.onAdd.apply(this,arguments);this.trackMenu(a)},onRemove:function(a){Ext.container.Container.prototype.onRemove.apply(this,arguments);this.trackMenu(a,!0)},privates:{applyDefaults:function(a){if(!Ext.isString(a)){a=Ext.container.Container.prototype.applyDefaults.apply(this,arguments)}return a},trackMenu:function(b,c){var a=this;if(a.trackMenus&&b.menu){b[c?'un':'on']({mouseover:a.onButtonOver,menushow:a.onButtonMenuShow,menuhide:a.onButtonMenuHide,scope:a})}},getChildItemsToDisable:function(){return this.items.getRange()},onButtonOver:function(a,c){var b=this.activeMenuBtn;if(b&&b!==a){b.hideMenu();a.focus();a.showMenu(c);this.activeMenuBtn=a}},onButtonMenuShow:function(a){this.activeMenuBtn=a},onButtonMenuHide:function(a){this.activeMenuBtn=null}}},0,['toolbar'],['component','box','container','toolbar'],{'component':!0,'box':!0,'container':!0,'toolbar':!0},['widget.toolbar'],[[Ext.util.FocusableContainer.prototype.mixinId||Ext.util.FocusableContainer.$className,Ext.util.FocusableContainer]],[Ext.toolbar,'Toolbar',Ext,'Toolbar'],0);Ext.define('Ext.theme.neptune.toolbar.Toolbar',{override:'Ext.toolbar.Toolbar',usePlainButtons:!1,border:!1});Ext.cmd.derive('Ext.dd.DragDrop',Ext.Base,{constructor:function(a,c,b){if(a){this.init(a,c,b)}},id:null,config:null,dragElId:null,handleElId:null,invalidHandleTypes:null,invalidHandleIds:null,invalidHandleClasses:null,startPageX:0,startPageY:0,groups:null,locked:!1,lock:function(){this.locked=!0},moveOnly:!1,unlock:function(){this.locked=!1},isTarget:!0,padding:null,_domRef:null,__ygDragDrop:!0,constrainX:!1,constrainY:!1,minX:0,maxX:0,minY:0,maxY:0,maintainOffset:!1,xTicks:null,yTicks:null,primaryButtonOnly:!0,available:!1,hasOuterHandles:!1,triggerEvent:'mousedown',b4StartDrag:function(a,b){},startDrag:function(a,b){},b4Drag:function(a){},onDrag:function(a){},onDragEnter:function(b,a){},b4DragOver:function(a){},onDragOver:function(b,a){},b4DragOut:function(a){},onDragOut:function(b,a){},b4DragDrop:function(a){},onDragDrop:function(b,a){},onInvalidDrop:function(a){},b4EndDrag:function(a){},endDrag:function(a){},b4MouseDown:function(a){},onMouseDown:function(a){},onMouseUp:function(a){},onAvailable:function(){},defaultPadding:{left:0,right:0,top:0,bottom:0},constrainTo:function(j,a,k){if(Ext.isNumber(a)){a={left:a,right:a,top:a,bottom:a}}a=a||this.defaultPadding;var c=Ext.get(this.getEl()).getBox(),e=Ext.get(j),i=e.getScroll(),b,d=e.dom,h,g,f;if(d===document.body){b={x:i.left,y:i.top,width:Ext.Element.getViewportWidth(),height:Ext.Element.getViewportHeight()}}else {h=e.getXY();b={x:h[0],y:h[1],width:d.clientWidth,height:d.clientHeight}}g=c.y-b.y;f=c.x-b.x;this.resetConstraints();this.setXConstraint(f-(a.left||0),b.width-f-c.width-(a.right||0),this.xTickSize);this.setYConstraint(g-(a.top||0),b.height-g-c.height-(a.bottom||0),this.yTickSize)},getEl:function(){if(!this._domRef){this._domRef=Ext.getDom(this.id)}return this._domRef},getDragEl:function(){return Ext.getDom(this.dragElId)},init:function(b,d,c){var a=this;a.el=a.el||Ext.get(b);a.initTarget(b,d,c);Ext.get(a.id).on(a.triggerEvent,a.handleMouseDown,a)},initTarget:function(a,b,c){this.config=c||{};this.DDMInstance=Ext.dd.DragDropManager;this.groups={};if(typeof a!=='string'){a=Ext.id(a)}this.id=a;this.addToGroup(b?b:'default');this.handleElId=a;this.setDragElId(a);this.invalidHandleTypes={A:'A'};this.invalidHandleIds={};this.invalidHandleClasses=[];this.applyConfig();this.handleOnAvailable()},applyConfig:function(){this.padding=this.config.padding||[0,0,0,0];this.isTarget=this.config.isTarget!==!1;this.maintainOffset=this.config.maintainOffset;this.primaryButtonOnly=this.config.primaryButtonOnly!==!1},handleOnAvailable:function(){this.available=!0;this.resetConstraints();this.onAvailable()},setPadding:function(a,b,c,d){if(!b&&0!==b){this.padding=[a,a,a,a]}else {if(!c&&0!==c){this.padding=[a,b,a,b]}else {this.padding=[a,b,c,d]}}},setInitPosition:function(e,f){var d=this.getEl(),b,c,a;if(!this.DDMInstance.verifyEl(d)){return}b=e||0;c=f||0;a=Ext.fly(d).getXY();this.initPageX=a[0]-b;this.initPageY=a[1]-c;this.lastPageX=a[0];this.lastPageY=a[1];this.setStartPosition(a)},setStartPosition:function(b){var a=b||Ext.fly(this.getEl()).getXY();this.deltaSetXY=null;this.startPageX=a[0];this.startPageY=a[1]},addToGroup:function(a){this.groups[a]=!0;this.DDMInstance.regDragDrop(this,a)},removeFromGroup:function(a){if(this.groups[a]){delete this.groups[a]}this.DDMInstance.removeDDFromGroup(this,a)},setDragElId:function(a){this.dragElId=a},setHandleElId:function(a){if(typeof a!=='string'){a=Ext.id(a)}this.handleElId=a;this.DDMInstance.regHandle(this.id,a)},setOuterHandleElId:function(a){if(typeof a!=='string'){a=Ext.id(a)}Ext.get(a).on(this.triggerEvent,this.handleMouseDown,this);this.setHandleElId(a);this.hasOuterHandles=!0},unreg:function(){var a=this,b;if(a._domRef){b=Ext.fly(a.id);if(b){b.un(a.triggerEvent,a.handleMouseDown,a)}}a._domRef=null;a.DDMInstance._remove(a,a.autoGroup)},destroy:function(){this.unreg();this.callParent()},isLocked:function(){return this.DDMInstance.isLocked()||this.locked},handleMouseDown:function(b,c){var a=this;if(a.primaryButtonOnly&&b.button||a.isLocked()){return}a.DDMInstance.refreshCache(a.groups);if(a.hasOuterHandles||a.DDMInstance.isOverTarget(b.getPoint(),a)){if(a.clickValidator(b)){a.setStartPosition();a.b4MouseDown(b);a.onMouseDown(b);a.DDMInstance.handleMouseDown(b,a);a.DDMInstance.stopEvent(b)}}},clickValidator:function(b){var a=b.getTarget();return this.isValidHandleChild(a)&&(this.id===this.handleElId||this.DDMInstance.handleWasClicked(a,this.id))},addInvalidHandleType:function(b){var a=b.toUpperCase();this.invalidHandleTypes[a]=a},addInvalidHandleId:function(a){if(typeof a!=='string'){a=Ext.id(a)}this.invalidHandleIds[a]=a},addInvalidHandleClass:function(a){this.invalidHandleClasses.push(a)},removeInvalidHandleType:function(a){var b=a.toUpperCase();delete this.invalidHandleTypes[b]},removeInvalidHandleId:function(a){if(typeof a!=='string'){a=Ext.id(a)}delete this.invalidHandleIds[a]},removeInvalidHandleClass:function(c){var b=this.invalidHandleClasses,d=b.length,a;for(a=0;a=this.minX;a=a-c){if(!b[a]){this.xTicks[this.xTicks.length]=a;b[a]=!0}}for(a=this.initPageX;a<=this.maxX;a=a+c){if(!b[a]){this.xTicks[this.xTicks.length]=a;b[a]=!0}}Ext.Array.sort(this.xTicks,this.DDMInstance.numericSort)},setYTicks:function(d,c){this.yTicks=[];this.yTickSize=c;var b={},a;for(a=this.initPageY;a>=this.minY;a=a-c){if(!b[a]){this.yTicks[this.yTicks.length]=a;b[a]=!0}}for(a=this.initPageY;a<=this.maxY;a=a+c){if(!b[a]){this.yTicks[this.yTicks.length]=a;b[a]=!0}}Ext.Array.sort(this.yTicks,this.DDMInstance.numericSort)},setXConstraint:function(c,b,a){this.leftConstraint=c;this.rightConstraint=b;this.minX=this.initPageX-c;this.maxX=this.initPageX+b;if(a){this.setXTicks(this.initPageX,a)}this.constrainX=!0},clearConstraints:function(){this.constrainX=!1;this.constrainY=!1;this.clearTicks()},clearTicks:function(){this.xTicks=null;this.yTicks=null;this.xTickSize=0;this.yTickSize=0},setYConstraint:function(c,b,a){this.topConstraint=c;this.bottomConstraint=b;this.minY=this.initPageY-c;this.maxY=this.initPageY+b;if(a){this.setYTicks(this.initPageY,a)}this.constrainY=!0},resetConstraints:function(){if(this.initPageX||this.initPageX===0){var a=this.maintainOffset?this.lastPageX-this.initPageX:0,b=this.maintainOffset?this.lastPageY-this.initPageY:0;this.setInitPosition(a,b)}else {this.setInitPosition()}if(this.constrainX){this.setXConstraint(this.leftConstraint,this.rightConstraint,this.xTickSize)}if(this.constrainY){this.setYConstraint(this.topConstraint,this.bottomConstraint,this.yTickSize)}},getTick:function(d,a){if(!a){return d}else {if(a[0]>=d){return a[0]}else {var b,g,c,e,f;for(b=0,g=a.length;b=d){e=d-a[b];f=a[c]-d;return f>e?a[b]:a[c]}}return a[a.length-1]}}},toString:function(){return 'DragDrop '+this.id}},3,0,0,0,0,0,[Ext.dd,'DragDrop'],0);Ext.cmd.derive('Ext.dd.DD',Ext.dd.DragDrop,{constructor:function(a,c,b){if(a){this.init(a,c,b)}},scroll:!0,autoOffset:function(a,b){var c=a-this.startPageX,d=b-this.startPageY;this.setDelta(c,d)},setDelta:function(a,b){this.deltaX=a;this.deltaY=b},setDragElPos:function(a,b){var c=this.getDragEl();this.alignElWithMouse(c,a,b)},alignElWithMouse:function(d,j,k){var a=this.getTargetCoord(j,k),c=d.dom?d:Ext.fly(d,'_dd'),e=c.getSize(),i=Ext.Element,b,g,f,h;if(!this.deltaSetXY){b=this.cachedViewportSize={width:i.getDocumentWidth(),height:i.getDocumentHeight()};g=[Math.max(0,Math.min(a.x,b.width-e.width)),Math.max(0,Math.min(a.y,b.height-e.height))];c.setXY(g);f=this.getLocalX(c);h=c.getLocalY();this.deltaSetXY=[f-a.x,h-a.y]}else {b=this.cachedViewportSize;this.setLocalXY(c,Math.max(0,Math.min(a.x+this.deltaSetXY[0],b.width-e.width)),Math.max(0,Math.min(a.y+this.deltaSetXY[1],b.height-e.height)))}this.cachePosition(a.x,a.y);this.autoScroll(a.x,a.y,d.offsetHeight,d.offsetWidth);return a},cachePosition:function(b,c){if(b){this.lastPageX=b;this.lastPageY=c}else {var a=Ext.fly(this.getEl()).getXY();this.lastPageX=a[0];this.lastPageY=a[1]}},autoScroll:function(e,f,m,n){if(this.scroll){var g=Ext.Element.getViewportHeight(),h=Ext.Element.getViewportWidth(),b=this.DDMInstance.getScrollTop(),a=this.DDMInstance.getScrollLeft(),l=m+f,j=n+e,k=g+b-f-this.deltaY,i=h+a-e-this.deltaX,d=40,c=document.all?80:30;if(l>g&&k0&&f-bh&&i0&&e-athis.maxX){a=this.maxX}}if(this.constrainY){if(bthis.maxY){b=this.maxY}}a=this.getTick(a,this.xTicks);b=this.getTick(b,this.yTicks);return {x:a,y:b}},applyConfig:function(){Ext.dd.DragDrop.prototype.applyConfig.call(this);this.scroll=this.config.scroll!==!1},b4MouseDown:function(b){var a=b.getXY();this.autoOffset(a[0],a[1])},b4Drag:function(b){var a=b.getXY();this.setDragElPos(a[0],a[1])},toString:function(){return 'DD '+this.id},getLocalX:function(a){return a.getLocalX()},setLocalXY:function(a,b,c){a.setLocalXY(b,c)}},3,0,0,0,0,0,[Ext.dd,'DD'],0);Ext.cmd.derive('Ext.dd.DDProxy',Ext.dd.DD,{statics:{dragElId:'ygddfdiv'},constructor:function(a,c,b){if(a){this.init(a,c,b);this.initFrame()}},resizeFrame:!0,centerFrame:!1,createFrame:function(){var d=this,c=document.body,a,b;if(!c||!c.firstChild){Ext.defer(function(){d.createFrame()},50);return}a=this.getDragEl();if(!a){a=document.createElement('div');a.id=this.dragElId;a.setAttribute('role','presentation');b=a.style;b.position='absolute';b.visibility='hidden';b.cursor='move';b.border='2px solid #aaa';b.zIndex=999;c.insertBefore(a,c.firstChild)}},initFrame:function(){this.createFrame()},applyConfig:function(){Ext.dd.DD.prototype.applyConfig.call(this);this.resizeFrame=this.config.resizeFrame!==!1;this.centerFrame=this.config.centerFrame;this.setDragElId(this.config.dragElId||Ext.dd.DDProxy.dragElId)},showFrame:function(d,e){var a=this,b=a.getDragEl(),c=b.style;a._resizeProxy();if(a.centerFrame){a.setDelta(Math.round(parseInt(c.width,10)/2),Math.round(parseInt(c.height,10)/2))}a.setDragElPos(d,e);Ext.fly(b).show()},_resizeProxy:function(){if(this.resizeFrame){var a=this.getEl();Ext.fly(this.getDragEl()).setSize(a.offsetWidth,a.offsetHeight)}},b4MouseDown:function(d){var a=d.getXY(),b=a[0],c=a[1];this.autoOffset(b,c);this.setDragElPos(b,c)},b4StartDrag:function(a,b){this.showFrame(a,b)},b4EndDrag:function(a){Ext.fly(this.getDragEl()).hide()},endDrag:function(c){var b=this.getEl(),a=this.getDragEl();a.style.visibility='';this.beforeMove();b.style.visibility='hidden';Ext.dd.DDM.moveToEl(b,a);a.style.visibility='hidden';b.style.visibility='';this.afterDrag()},beforeMove:function(){},afterDrag:function(){},toString:function(){return 'DDProxy '+this.id}},3,0,0,0,0,0,[Ext.dd,'DDProxy'],0);Ext.cmd.derive('Ext.dd.StatusProxy',Ext.Component,{animRepair:!1,childEls:['ghost'],renderTpl:[''],repairCls:'x-dd-drag-repair',ariaRole:'presentation',skipLayout:!0,constructor:function(a){var b=this;a=a||{};Ext.apply(b,{hideMode:'visibility',hidden:!0,floating:!0,id:b.id||Ext.id(),cls:'x-dd-drag-proxy '+this.dropNotAllowed,shadow:a.shadow||!1,renderTo:Ext.getDetachedBody()});Ext.Component.prototype.constructor.apply(this,arguments);this.dropStatus=this.dropNotAllowed},dropAllowed:'x-dd-drop-ok',dropNotAllowed:'x-dd-drop-nodrop',setStatus:function(a){a=a||this.dropNotAllowed;if(this.dropStatus!==a){this.el.replaceCls(this.dropStatus,a);this.dropStatus=a}},reset:function(c){var a=this,b='x-dd-drag-proxy ';a.el.replaceCls(b+a.dropAllowed,b+a.dropNotAllowed);a.dropStatus=a.dropNotAllowed;if(c){a.ghost.setHtml('')}},update:function(a){if(typeof a==='string'){this.ghost.setHtml(a)}else {this.ghost.setHtml('');a.style.margin='0';this.ghost.dom.appendChild(a)}var b=this.ghost.dom.firstChild;if(b){Ext.fly(b).setStyle('float','none')}},getGhost:function(){return this.ghost},hide:function(a){Ext.Component.prototype.hide.call(this);if(a){this.reset(!0)}},stop:function(){if(this.anim&&this.anim.isAnimated&&this.anim.isAnimated()){this.anim.stop()}},sync:function(){this.el.syncUnderlays()},repair:function(b,c,d){var a=this;a.callback=c;a.scope=d;if(b&&a.animRepair!==!1){a.el.addCls(a.repairCls);a.el.setUnderlaysVisible(!1);a.anim=a.el.animate({duration:a.repairDuration||500,easing:'ease-out',to:{x:b[0],y:b[1]},stopAnimation:!0,callback:a.afterRepair,scope:a})}else {a.afterRepair()}},afterRepair:function(){var a=this;a.hide(!0);a.el.removeCls(a.repairCls);if(typeof a.callback==='function'){a.callback.call(a.scope||a)}delete a.callback;delete a.scope}},1,0,['component','box'],{'component':!0,'box':!0},0,0,[Ext.dd,'StatusProxy'],0);Ext.cmd.derive('Ext.dd.DragSource',Ext.dd.DDProxy,{dropAllowed:'x-dd-drop-ok',dropNotAllowed:'x-dd-drop-nodrop',animRepair:!0,repairHighlightColor:'c3daf9',constructor:function(b,a){this.el=Ext.get(b);if(!this.dragData){this.dragData={}}Ext.apply(this,a);if(!this.proxy){this.proxy=new Ext.dd.StatusProxy({id:this.el.id+'-drag-status-proxy',animRepair:this.animRepair})}Ext.dd.DDProxy.prototype.constructor.call(this,this.el.dom,this.ddGroup||this.group,{dragElId:this.proxy.id,resizeFrame:!1,isTarget:!1,scroll:this.scroll===!0});this.dragging=!1},getDragData:function(a){return this.dragData},onDragEnter:function(c,b){var a=Ext.dd.DragDropManager.getDDById(b),d;this.cachedTarget=a;if(this.beforeDragEnter(a,c,b)!==!1){if(a.isNotifyTarget){d=a.notifyEnter(this,c,this.dragData);this.proxy.setStatus(d)}else {this.proxy.setStatus(this.dropAllowed)}if(this.afterDragEnter){this.afterDragEnter(a,c,b)}}},beforeDragEnter:function(a,c,b){return !0},onDragOver:function(c,b){var a=this.cachedTarget||Ext.dd.DragDropManager.getDDById(b),d;if(this.beforeDragOver(a,c,b)!==!1){if(a.isNotifyTarget){d=a.notifyOver(this,c,this.dragData);this.proxy.setStatus(d)}if(this.afterDragOver){this.afterDragOver(a,c,b)}}},beforeDragOver:function(a,c,b){return !0},onDragOut:function(c,b){var a=this.cachedTarget||Ext.dd.DragDropManager.getDDById(b);if(this.beforeDragOut(a,c,b)!==!1){if(a.isNotifyTarget){a.notifyOut(this,c,this.dragData)}this.proxy.reset();if(this.afterDragOut){this.afterDragOut(a,c,b)}}this.cachedTarget=null},beforeDragOut:function(a,c,b){return !0},onDragDrop:function(c,b){var a=this.cachedTarget||Ext.dd.DragDropManager.getDDById(b);if(this.beforeDragDrop(a,c,b)!==!1){if(a.isNotifyTarget){if(a.notifyDrop(this,c,this.dragData)!==!1){this.onValidDrop(a,c,b)}else {this.onInvalidDrop(a,c,b)}}else {this.onValidDrop(a,c,b)}if(this.afterDragDrop){this.afterDragDrop(a,c,b)}}delete this.cachedTarget},beforeDragDrop:function(a,c,b){return !0},onValidDrop:function(a,c,b){this.hideProxy();if(this.afterValidDrop){this.afterValidDrop(a,c,b)}},getRepairXY:function(b,a){return this.el.getXY()},onInvalidDrop:function(c,b,d){var a=this;if(!b){b=c;c=null;d=b.getTarget().id}if(a.beforeInvalidDrop(c,b,d)!==!1){if(a.cachedTarget){if(a.cachedTarget.isNotifyTarget){a.cachedTarget.notifyOut(a,b,a.dragData)}a.cacheTarget=null}a.proxy.repair(a.getRepairXY(b,a.dragData),a.afterRepair,a);if(a.afterInvalidDrop){a.afterInvalidDrop(b,d)}}},afterRepair:function(){var a=this;if(Ext.enableFx){a.el.highlight(a.repairHighlightColor)}a.dragging=!1},beforeInvalidDrop:function(a,c,b){return !0},handleMouseDown:function(b){if(this.dragging){return}var a=this.getDragData(b);if(a&&this.onBeforeDrag(a,b)!==!1){this.dragData=a;this.proxy.stop();Ext.dd.DDProxy.prototype.handleMouseDown.apply(this,arguments)}},onBeforeDrag:function(a,b){return !0},onStartDrag:Ext.emptyFn,alignElWithMouse:function(){this.proxy.ensureAttachedToBody(!0);return Ext.dd.DDProxy.prototype.alignElWithMouse.apply(this,arguments)},startDrag:function(a,b){this.proxy.reset();this.proxy.hidden=!1;this.dragging=!0;this.proxy.update('');this.onInitDrag(a,b);this.proxy.show()},onInitDrag:function(b,c){var a=this.el.dom.cloneNode(!0);a.id=Ext.id();this.proxy.update(a);this.onStartDrag(b,c);return !0},getProxy:function(){return this.proxy},hideProxy:function(){this.proxy.hide();this.proxy.reset(!0);this.dragging=!1},triggerCacheRefresh:function(){Ext.dd.DDM.refreshCache(this.groups)},b4EndDrag:function(a){},endDrag:function(a){this.onEndDrag(this.dragData,a)},onEndDrag:function(a,b){},autoOffset:function(a,b){this.setDelta(-12,-20)},destroy:function(){Ext.dd.DDProxy.prototype.destroy.call(this);Ext.destroy(this.proxy)}},1,0,0,0,0,0,[Ext.dd,'DragSource'],0);Ext.cmd.derive('Ext.panel.Proxy',Ext.Base,{alternateClassName:'Ext.dd.PanelProxy',moveOnDrag:!0,constructor:function(c,b){var a=this;a.panel=c;a.id=a.panel.id+'-ddproxy';Ext.apply(a,b)},insertProxy:!0,setStatus:Ext.emptyFn,reset:Ext.emptyFn,update:Ext.emptyFn,stop:Ext.emptyFn,sync:Ext.emptyFn,getEl:function(){return this.ghost.el},getGhost:function(){return this.ghost},getProxy:function(){return this.proxy},hide:function(){var a=this;if(a.ghost){if(a.proxy){a.proxy.destroy();delete a.proxy}a.panel.unghost(null,a.moveOnDrag);delete a.ghost}},show:function(){var a=this,b;if(!a.ghost){b=a.panel.getSize();a.panel.el.setVisibilityMode(Ext.Element.DISPLAY);a.ghost=a.panel.ghost();if(a.insertProxy){a.proxy=a.panel.el.insertSibling({role:'presentation',cls:'x-panel-dd-spacer'});a.proxy.setSize(b)}}},repair:function(c,a,b){this.hide();Ext.callback(a,b||this)},moveProxy:function(a,b){if(this.proxy){a.insertBefore(this.proxy.dom,b)}}},1,0,0,0,0,0,[Ext.panel,'Proxy',Ext.dd,'PanelProxy'],0);Ext.cmd.derive('Ext.panel.DD',Ext.dd.DragSource,{constructor:function(b,c){var a=this;a.panel=b;a.dragData={panel:b};a.panelProxy=new Ext.panel.Proxy(b,c);a.proxy=a.panelProxy.proxy;Ext.dd.DragSource.prototype.constructor.call(this,b.el,c);a.setupEl(b)},setupEl:function(c){var a=this,b=c.header,d=c.body;if(b){a.setHandleElId(b.id);d=b.el}if(d){d.setStyle('cursor','move');a.scroll=!1}else {c.on('boxready',a.setupEl,a,{single:!0})}},showFrame:Ext.emptyFn,startDrag:Ext.emptyFn,b4StartDrag:function(a,b){this.panelProxy.show()},b4MouseDown:function(b){var a=b.getXY(),c=a[0],d=a[1];this.autoOffset(c,d)},onInitDrag:function(a,b){this.onStartDrag(a,b);return !0},createFrame:Ext.emptyFn,getDragEl:function(b){var a=this.panelProxy.ghost;if(a){return a.el.dom}},endDrag:function(a){this.panelProxy.hide();this.panel.saveState()},autoOffset:function(a,b){a-=this.startPageX;b-=this.startPageY;this.setDelta(a,b)},onInvalidDrop:function(d,b,c){var a=this;if(a.beforeInvalidDrop(d,b,c)!==!1){if(a.cachedTarget){if(a.cachedTarget.isNotifyTarget){a.cachedTarget.notifyOut(a,b,a.dragData)}a.cacheTarget=null}if(a.afterInvalidDrop){a.afterInvalidDrop(b,c)}}}},1,0,0,0,0,0,[Ext.panel,'DD'],0);Ext.cmd.derive('Ext.layout.component.Dock',Ext.layout.component.Component,{alternateClassName:'Ext.layout.component.AbstractDock',type:'dock',horzAxisProps:{name:'horz',oppositeName:'vert',dockBegin:'left',dockEnd:'right',horizontal:!0,marginBegin:'margin-left',maxSize:'maxWidth',minSize:'minWidth',pos:'x',setSize:'setWidth',shrinkWrapDock:'shrinkWrapDockWidth',size:'width',sizeModel:'widthModel'},vertAxisProps:{name:'vert',oppositeName:'horz',dockBegin:'top',dockEnd:'bottom',horizontal:!1,marginBegin:'margin-top',maxSize:'maxHeight',minSize:'minHeight',pos:'y',setSize:'setHeight',shrinkWrapDock:'shrinkWrapDockHeight',size:'height',sizeModel:'heightModel'},initializedBorders:-1,horizontalCollapsePolicy:{width:!0,x:!0},verticalCollapsePolicy:{height:!0,y:!0},finishRender:function(){var a=this,b,c;Ext.layout.component.Component.prototype.finishRender.call(this);b=a.getRenderTarget();c=a.getDockedItems();a.finishRenderItems(b,c)},isItemBoxParent:function(a){return !0},isItemShrinkWrap:function(a){return !0},noBorderClasses:['x-docked-noborder-top','x-docked-noborder-right','x-docked-noborder-bottom','x-docked-noborder-left'],noBorderClassesSides:{top:'x-docked-noborder-top',right:'x-docked-noborder-right',bottom:'x-docked-noborder-bottom',left:'x-docked-noborder-left'},borderWidthProps:{top:'border-top-width',right:'border-right-width',bottom:'border-bottom-width',left:'border-left-width'},_itemCls:'x-docked',handleItemBorders:function(){var c=this,b=c.owner,a,l,k=c.lastDockedItems,j=c.borders,m=b.dockedItems.generation,i=c.noBorderClassesSides,n=c.borderWidthProps,f,h,d,g,e,o=c.collapsed;if(c.initializedBorders===m||b.border&&!b.manageBodyBorders||b.collapsed&&b.collapseMode==='mini'){return}c.initializedBorders=m;c.collapsed=!1;c.lastDockedItems=l=c.getLayoutItems();c.collapsed=o;a={top:[],right:[],bottom:[],left:[]};for(f=0,h=l.length;fj){b=i.constrainedMax;m=j}else {if(hj){c=i.constrainedMax;l=j}else {if(h',addDocked:function(c,d){var b=this,k=b.rendered,f=0,g=b.dockedItems,i=g.getCount(),e,h,a,j;c=b.prepareItems(c);j=c.length;if(k){Ext.suspendLayouts()}if(d===undefined){d=i}else {d=Math.min(d,i)}for(;f','
','{headingText}','
','','{% this.renderDockedItems(out,values,0); %}','
{bodyCls}',' {baseCls}-body-{ui}',' {parent.baseCls}-body-{parent.ui}-{.}','{childElCls}"','',' {$}="{.}"','',' role="presentation"','',' style="{bodyStyle}">','{%this.renderContainer(out,values);%}','
','{% this.renderDockedItems(out,values,1); %}'],headerPosition:'top',iconAlign:'left',titleAlign:'left',titleRotation:'default',beforeRenderConfig:{glyph:null,headerPosition:null,icon:null,iconAlign:null,iconCls:null,title:null,titleAlign:null,titleRotation:null},animCollapse:Ext.enableFx,border:!0,closable:!1,closeAction:'destroy',closeToolText:'Close panel',collapsed:!1,collapsedCls:'collapsed',collapseFirst:!0,collapsible:undefined,collapseToolText:'Collapse panel',expandToolText:'Expand panel',constrain:!1,constrainHeader:!1,dockedItems:null,tbar:null,bbar:null,fbar:null,lbar:null,rbar:null,buttons:null,floatable:!0,frame:!1,frameHeader:!0,hideCollapseTool:!1,manageHeight:!0,maskElement:'el',minButtonWidth:75,preventHeader:!1,shrinkWrapDock:!1,titleCollapse:undefined,baseCls:'x-panel',bodyPosProps:{x:'x',y:'y'},componentLayout:'dock',contentPaddingProperty:'bodyPadding',emptyArray:[],isPanel:!0,defaultBindProperty:'title',addBodyCls:function(c){var a=this,b=a.rendered?a.body:a.getProtoBody();b.addCls(c);return a},addTool:function(b){if(!Ext.isArray(b)){b=[b]}var c=this,a=c.header,g=b.length,f=c.tools,e,d;if(!a||!a.isHeader){a=null;if(!f){c.tools=f=[]}}for(e=0;e=e||c[b]>0){if(b>=e){b=0;f=0;h++;for(a=0;a0){c[a]--}}}else {b++}}i.push({rowIdx:h,cellIdx:f});for(a=g.colspan||1;a;--a){c[b]=g.rowspan||1;++b}++f}return i},getRenderTree:function(){var a=this,h=a.getLayoutItems(),i=[],m=Ext.apply({tag:'table',id:a.owner.id+'-table','data-ref':'table',role:'presentation',cls:a.tableCls,cellspacing:0,cellpadding:0,cn:{tag:'tbody',id:a.owner.id+'-tbody','data-ref':'tbody',role:'presentation',cn:i}},a.tableAttrs),k=a.tdAttrs,d,n=h.length,b,f,c,g,j,e,l;l=a.calculateCells(h);for(d=0;d0){--this.disabled}},handleAdd:function(b,a){if(!this.disabled){if(a.is(this.selector)){this.onItemAdd(a.ownerCt,a)}if(a.isQueryable){this.onContainerAdd(a)}}},onItemAdd:function(e,b){var a=this,d=a.items,c=a.addHandler;if(!a.disabled){if(c){c.call(a.scope||b,b)}if(d){d.add(b)}}},onItemRemove:function(e,b){var a=this,d=a.items,c=a.removeHandler;if(!a.disabled){if(c){c.call(a.scope||b,b)}if(d){d.remove(b)}}},onContainerAdd:function(c,i){var a=this,d,e,h=a.handleAdd,g=a.handleRemove,b,f;if(c.isContainer){c.on('add',h,a);c.on('dockedadd',h,a);c.on('remove',g,a);c.on('dockedremove',g,a)}if(i!==!0){d=c.query(a.selector);for(b=0,e=d.length;bcontainer');for(b=0,e=d.length;ba.tolerance){a.triggerStart(b)}else {return}}if(a.fireEvent('mousemove',a,b)===!1){a.onMouseUp(b)}else {a.onDrag(b);a.fireEvent('drag',a,b)}},onMouseUp:function(b){var a=this;a.mouseIsDown=!1;if(a.mouseIsOut){a.mouseIsOut=!1;a.onMouseOut(b)}if(a.preventDefault!==!1){b.preventDefault()}if(Ext.isIE&&document.releaseCapture){document.releaseCapture()}a.fireEvent('mouseup',a,b);a.endDrag(b)},endDrag:function(b){var a=this,c=a.active;Ext.getDoc().un({mousemove:a.onMouseMove,mouseup:a.onMouseUp,selectstart:a.stopSelect,capture:!0,scope:a});a.clearStart();a.active=!1;if(c){a.dragEnded=!0;a.onEnd(b);a.fireEvent('dragend',a,b)}a._constrainRegion=null},triggerStart:function(b){var a=this;a.clearStart();a.active=!0;a.onStart(b);a.fireEvent('dragstart',a,b)},clearStart:function(){var a=this.timer;if(a){clearTimeout(a);this.timer=null}},stopSelect:function(a){a.stopEvent();return !1},onBeforeStart:function(a){},onStart:function(a){},onDrag:function(a){},onEnd:function(a){},getDragTarget:function(){return this.dragTarget},getDragCt:function(){return this.el},getConstrainRegion:function(){var a=this;if(a.constrainTo){if(a.constrainTo instanceof Ext.util.Region){return a.constrainTo}if(!a._constrainRegion){a._constrainRegion=Ext.fly(a.constrainTo).getViewRegion()}}else {if(!a._constrainRegion){a._constrainRegion=a.getDragCt().getViewRegion()}}return a._constrainRegion},getXY:function(a){return a?this.constrainModes[a](this,this.lastXY):this.lastXY},getOffset:function(c){var a=this.getXY(c),b=this.startXY;return [a[0]-b[0],a[1]-b[1]]},onDragStart:function(a){a.stopPropagation()},constrainModes:{point:function(d,b){var a=d.dragRegion,c=d.getConstrainRegion();if(!c){return b}a.x=a.left=a[0]=a.right=b[0];a.y=a.top=a[1]=a.bottom=b[1];a.constrainTo(c);return [a.left,a.top]},dragTarget:function(e,c){var f=e.startXY,a=e.startRegion.copy(),b=e.getConstrainRegion(),d;if(!b){return c}a.translateBy(c[0]-f[0],c[1]-f[1]);if(a.right>b.right){c[0]+=d=b.right-a.right;a.left+=d}if(a.leftb.bottom){c[1]+=d=b.bottom-a.bottom;a.top+=d}if(a.top[flex]'),o=j.length,h=n==='vertical',i=0,d=h?'width':'height',m=0,g,a;for(;i',tabGuardIndex:0},tabGuardPositionAttribute:'data-tabguardposition',privates:{initTabGuards:function(){var a=this,f=a.tabGuardPositionAttribute,c=a.tabGuardBeforeEl,d=a.tabGuardAfterEl,e=a.tabGuardIndex,b;if(!a.rendered||!a.tabGuard){return}b=a.el.findTabbableElements({skipSelf:!0});if(b[0]&&b[0].hasAttribute(f)){b.shift()}if(b.length&&b[b.length-1].hasAttribute(f)){b.pop()}if(b.length){c.dom.setAttribute('tabIndex',e);c.on('focusenter',a.onTabGuardFocusEnter,a);d.dom.setAttribute('tabIndex',e);d.on('focusenter',a.onTabGuardFocusEnter,a)}else {c.dom.removeAttribute('tabIndex');c.un('focusenter',a.onTabGuardFocusEnter,a);d.dom.removeAttribute('tabIndex');d.un('focusenter',a.onTabGuardFocusEnter,a)}},onTabGuardFocusEnter:function(j,i){var h=this,e=h.el,g=h.tabGuardPositionAttribute,f=i.getAttribute(g),d=j.relatedTarget,a,c,b;if(!d.hasAttribute(g)&&d!==e.dom&&e.contains(d)){c=f==='before'?!1:!0}else {c=f==='before'?!0:!1}a=e.findTabbableElements({skipSelf:!0});a.shift();a.pop();b=c?a[0]:a[a.length-1];if(b){b.focus()}}}},0,0,0,0,0,0,[Ext.util,'FocusTrap'],0);Ext.cmd.derive('Ext.window.Window',Ext.panel.Panel,{alternateClassName:'Ext.Window',baseCls:'x-window',resizable:!0,draggable:!0,constrain:!1,constrainHeader:!1,plain:!1,minimizable:!1,maximizable:!1,minHeight:50,minWidth:50,expandOnShow:!0,collapsible:!1,closable:!0,hidden:!0,autoRender:!0,hideMode:'offsets',floating:!0,itemCls:'x-window-item',overlapHeader:!0,ignoreHeaderBorderManagement:!0,alwaysFramed:!0,isRootCfg:{isRoot:!0},isWindow:!0,ariaRole:'dialog',initComponent:function(){var a=this;a.frame=!1;Ext.panel.Panel.prototype.initComponent.call(this);if(a.plain){a.addClsWithUI('plain')}a.addStateEvents(['maximize','restore','resize','dragend'])},getElConfig:function(){var b=this,a;a=Ext.panel.Panel.prototype.getElConfig.call(this);a.tabIndex=-1;return a},getFocusEl:function(){return this.getDefaultFocus()||this.el},getState:function(){var a=this,e=Ext.panel.Panel.prototype.getState.call(this)||{},c=!!a.maximized,d=a.ghostBox,b;e.maximized=c;if(c){b=a.restorePos}else {if(d){b=[d.x,d.y]}else {b=a.getPosition()}}Ext.apply(e,{size:c?a.restoreSize:a.getSize(),pos:b});return e},applyState:function(a){var b=this;if(a){b.maximized=a.maximized;if(b.maximized){b.hasSavedRestore=!0;b.restoreSize=a.size;b.restorePos=a.pos}else {Ext.apply(b,{width:a.size.width,height:a.size.height,x:a.pos[0],y:a.pos[1]})}}},onRender:function(c,b){var a=this;Ext.panel.Panel.prototype.onRender.apply(this,arguments);if(a.header){a.header.on({scope:a,click:a.onHeaderClick})}if(a.maximizable){a.header.on({scope:a,dblclick:a.toggleMaximize})}},afterRender:function(){var a=this,c=a.header,b;if(a.maximized){a.maximized=!1;a.maximize();if(c){c.removeCls(c.indicateDragCls)}}Ext.panel.Panel.prototype.afterRender.call(this);if(a.closable){b=a.getKeyMap();b.on(27,a.onEsc,a)}else {b=a.keyMap}if(b&&a.hidden){b.disable()}},onEsc:function(b,a){a.stopEvent();this.close()},beforeDestroy:function(){var a=this;if(a.rendered){Ext.un('resize',a.onWindowResize,a);delete a.animateTarget;a.hide();Ext.destroy(a.keyMap)}Ext.panel.Panel.prototype.beforeDestroy.call(this)},addTools:function(){var a=this,b=[];Ext.panel.Panel.prototype.addTools.call(this);if(a.minimizable){b.push({type:'minimize',handler:'minimize',scope:a})}if(a.maximizable){b.push({type:a.maximized?'restore':'maximize',handler:'toggleMaximize',scope:a})}if(b.length){a.addTool(b)}},onShow:function(){var a=this;Ext.panel.Panel.prototype.onShow.apply(this,arguments);if(a.expandOnShow){a.expand(!1)}a.syncMonitorWindowResize();if(a.keyMap){a.keyMap.enable()}},doClose:function(){var a=this;if(a.hidden){a.fireEvent('close',a);if(a.closeAction==='destroy'){a.destroy()}}else {a.hide(a.animateTarget,a.doClose,a)}},afterHide:function(){var a=this;a.syncMonitorWindowResize();if(a.keyMap){a.keyMap.disable()}Ext.panel.Panel.prototype.afterHide.apply(this,arguments)},onWindowResize:function(){var a=this,b;if(!a.destroyed){if(a.maximized){a.fitContainer()}else {b=a.getSizeModel();if(b.width.natural||b.height.natural){a.updateLayout()}a.doConstrain()}}},minimize:function(){this.fireEvent('minimize',this);return this},resumeHeaderLayout:function(a){this.header.resumeLayouts(a?this.isRootCfg:null)},afterCollapse:function(){var a=this,b=a.header,c=a.tools;if(b&&a.maximizable){b.suspendLayouts();c.maximize.hide();this.resumeHeaderLayout(!0)}if(a.resizer){a.resizer.disable()}Ext.panel.Panel.prototype.afterCollapse.apply(this,arguments)},afterExpand:function(){var a=this,c=a.header,d=a.tools,b;if(c){c.suspendLayouts();if(a.maximizable){d.maximize.show();b=!0}this.resumeHeaderLayout(b)}if(a.resizer){a.resizer.enable()}Ext.panel.Panel.prototype.afterExpand.apply(this,arguments)},maximize:function(c){var a=this,b=a.header,f=a.tools,g=a.width,e=a.height,h,d;if(!a.maximized){a.expand(!1);if(!a.hasSavedRestore){h=a.restoreSize={width:g?g:null,height:e?e:null};a.restorePos=a.getPosition()}if(b){b.suspendLayouts();if(f.maximize){f.maximize.setType('restore')}if(a.collapseTool){a.collapseTool.hide();d=!0}a.resumeHeaderLayout(d)}a.el.disableShadow();if(a.dd){a.dd.disable();if(b){b.removeCls(b.indicateDragCls)}}if(a.resizer){a.resizer.disable()}a.el.addCls('x-window-maximized');a.container.addCls('x-window-maximized-ct');a.syncMonitorWindowResize();a.fitContainer(c=c||!!a.animateTarget?{callback:function(){a.maximized=!0;a.fireEvent('maximize',a)}}:null);if(!c){a.maximized=!0;a.fireEvent('maximize',a)}}return a},restore:function(c){var a=this,f=a.tools,b=a.header,d=a.restoreSize,e;if(a.maximized){a.hasSavedRestore=null;a.removeCls('x-window-maximized');if(b){b.suspendLayouts();if(f.maximize){f.maximize.setType('maximize')}if(a.collapseTool){a.collapseTool.show();e=!0}a.resumeHeaderLayout(e)}d.x=a.restorePos[0];d.y=a.restorePos[1];a.setBox(d,c=c||!!a.animateTarget?{callback:function(){a.el.enableShadow(null,!0);a.maximized=!1;a.fireEvent('restore',a)}}:null);a.restorePos=a.restoreSize=null;if(a.dd){a.dd.enable();if(b){b.addCls(b.indicateDragCls)}}if(a.resizer){a.resizer.enable()}a.container.removeCls('x-window-maximized-ct');a.syncMonitorWindowResize();if(!c){a.el.enableShadow(null,!0);a.maximized=!1;a.fireEvent('restore',a)}}return a},syncMonitorWindowResize:function(){var a=this,b=a._monitoringResize,d=a.monitorResize||a.constrain||a.constrainHeader||a.maximized,c=a.hidden||a.destroying||a.destroyed;if(d&&!c){if(!b){Ext.on('resize',a.onWindowResize,a,{buffer:1});a._monitoringResize=!0}}else {if(b){Ext.un('resize',a.onWindowResize,a);a._monitoringResize=!1}}},toggleMaximize:function(){return this[this.maximized?'restore':'maximize']()},createGhost:function(){var a=Ext.panel.Panel.prototype.createGhost.apply(this,arguments);a.xtype='window';a.focusOnToFront=!1;return a},getDefaultFocus:function(){var d=this,b,a=d.defaultFocus,c;if(a!==undefined){if(Ext.isNumber(a)){b=d.query('button')[a]}else {if(Ext.isString(a)){c=a;if(Ext.validIdRe.test(c)){b=d.down(Ext.makeIdSelector(c))}if(!b){b=d.down(c)}}else {if(a.focus){b=a}}}}return b},privates:{initDraggable:function(){this.initSimpleDraggable()},onHeaderClick:function(b,c){var a;if(b.el.contains(c.getTarget())){a=this.getDefaultFocus();if(a){a.focus()}}},initResizable:function(){Ext.panel.Panel.prototype.initResizable.apply(this,arguments);if(this.maximized){this.resizer.disable()}}}},0,['window'],['component','box','container','panel','window'],{'component':!0,'box':!0,'container':!0,'panel':!0,'window':!0},['widget.window'],[[Ext.util.FocusTrap.prototype.mixinId||Ext.util.FocusTrap.$className,Ext.util.FocusTrap]],[Ext.window,'Window',Ext,'Window'],0);Ext.cmd.derive('Ext.form.Labelable',Ext.Mixin,{isLabelable:!0,mixinConfig:{id:'labelable',on:{beforeRender:'beforeLabelRender',onRender:'onLabelRender'}},config:{childEls:['labelEl','bodyEl','errorEl','errorWrapEl','ariaErrorEl']},labelableRenderTpl:['{beforeLabelTpl}','','{afterLabelTpl}','','','
','','
','
',{disableFormats:!0}],activeErrorsTpl:undefined,htmlActiveErrorsTpl:['','
    ','
  • {.}
  • ','
','
'],plaintextActiveErrorsTpl:['','\n{.}',''],isFieldLabelable:!0,formItemCls:'x-form-item',labelCls:'x-form-item-label',topLabelCls:'x-form-item-label-top',rightLabelCls:'x-form-item-label-right',labelInnerCls:'x-form-item-label-inner',topLabelSideErrorCls:'x-form-item-label-top-side-error',errorMsgCls:'x-form-error-msg',errorWrapCls:'x-form-error-wrap',errorWrapSideCls:'x-form-error-wrap-side',errorWrapUnderCls:'x-form-error-wrap-under',errorWrapUnderSideLabelCls:'x-form-error-wrap-under-side-label',baseBodyCls:'x-form-item-body',invalidIconCls:'x-form-invalid-icon',invalidUnderCls:'x-form-invalid-under',noLabelCls:'x-form-item-no-label',fieldBodyCls:'',invalidCls:'x-form-invalid',fieldLabel:undefined,labelAlign:'left',labelWidth:100,labelPad:5,labelSeparator:':',hideLabel:!1,hideEmptyLabel:!0,preventMark:!1,autoFitErrors:!0,msgTarget:'qtip',msgTargets:{qtip:1,title:1,under:1,side:1,none:1},noWrap:!0,labelableInsertions:['beforeBodyEl','afterBodyEl','beforeLabelTpl','afterLabelTpl','beforeSubTpl','afterSubTpl','beforeLabelTextTpl','afterLabelTextTpl','labelAttrTpl'],statics:{initTip:function(){var b=this.tip,a,c;if(b){return}a={id:'ext-form-error-tip',ui:'form-invalid'};if(Ext.supports.Touch){a.dismissDelay=0;a.anchor='top';a.showDelay=0;a.listeners={beforeshow:function(){this.minWidth=Ext.fly(this.anchorTarget).getWidth()}}}b=this.tip=Ext.create('Ext.tip.QuickTip',a);c=Ext.apply({},b.tagConfig);c.attribute='errorqtip';b.setTagConfig(c)},destroyTip:function(){this.tip=Ext.destroy(this.tip)}},initLabelable:function(){var a=this,b=a.padding;if(b){a.padding=undefined;a.extraMargins=Ext.Element.parseBox(b)}if(Ext.isIE8){a.restoreDisplay=Ext.Function.createDelayed(a.doRestoreDisplay,0,a)}if(!a.activeErrorsTpl){if(a.msgTarget==='title'){a.activeErrorsTpl=a.plaintextActiveErrorsTpl}else {a.activeErrorsTpl=a.htmlActiveErrorsTpl}}a.addCls([a.formItemCls,a.formItemCls+'-'+a.ui]);a.lastActiveError='';a.enableBubble('errorchange')},trimLabelSeparator:function(){var b=this,c=b.labelSeparator,a=b.fieldLabel||'',d=a.substr(a.length-1);return d===c?a.slice(0,-1):a},getFieldLabel:function(){return this.trimLabelSeparator()},setFieldLabel:function(b){b=b||'';var a=this,f=a.labelSeparator,h=a.labelEl,c=a.errorWrapEl,g=a.labelAlign!=='top',e=a.noLabelCls,d=a.errorWrapUnderSideLabelCls;a.fieldLabel=b;if(a.rendered){if(Ext.isEmpty(b)&&a.hideEmptyLabel){a.addCls(e);if(g&&c){c.removeCls(d)}}else {if(f){b=a.trimLabelSeparator()+f}h.dom.firstChild.innerHTML=b;a.removeCls(e);if(g&&c){c.addCls(d)}}a.updateLayout()}},setHideLabel:function(b){var a=this;if(b!==a.hideLabel){a.hideLabel=b;if(a.rendered){a[b?'addCls':'removeCls'](a.noLabelCls);a.updateLayout()}}},setHideEmptyLabel:function(b){var a=this,c;if(b!==a.hideEmptyLabel){a.hideEmptyLabel=b;if(a.rendered&&!a.hideLabel){c=b&&!a.getFieldLabel();a[c?'addCls':'removeCls'](a.noLabelCls);a.updateLayout()}}},getInsertionRenderData:function(c,d){var e=d.length,b,a;while(e--){b=d[e];a=this[b];if(a){if(typeof a!=='string'){if(!a.isTemplate){a=Ext.XTemplate.getTpl(this,b)}a=a.apply(c)}}c[b]=a||''}return c},getLabelableRenderData:function(){var a=this,l=a.labelAlign,o=l==='top',r=l==='right',c=a.msgTarget==='side',h=a.msgTarget==='under',q=a.errorMsgCls,b=a.labelPad,m=a.labelWidth,d=a.labelClsExtra||'',j=c?a.errorWrapSideCls:a.errorWrapUnderCls,g='',f='',p=a.hasVisibleLabel(),k=a.autoFitErrors,e=a.defaultBodyWidth,n,i;if(o){d+=' '+a.topLabelCls;if(b){f='padding-bottom:'+b+'px;'}if(c&&!k){d+=' '+a.topLabelSideErrorCls}}else {if(r){d+=' '+a.rightLabelCls}if(b){g+=a.getHorizontalPaddingStyle()+b+'px;'}g+='width:'+(m+(b?b:0))+'px;';f='width:'+m+'px'}if(p){if(!o&&h){j+=' '+a.errorWrapUnderSideLabelCls}}if(e){n='min-width:'+e+'px;max-width:'+e+'px;'}i={id:a.id,inputId:a.getInputId(),labelCls:a.labelCls,labelClsExtra:d,labelStyle:g+(a.labelStyle||''),labelInnerStyle:f,labelInnerCls:a.labelInnerCls,unselectableCls:Ext.Element.unselectableCls,bodyStyle:n,baseBodyCls:a.baseBodyCls,fieldBodyCls:a.fieldBodyCls,extraFieldBodyCls:a.extraFieldBodyCls,errorWrapCls:a.errorWrapCls,errorWrapExtraCls:j,renderError:c||h,invalidMsgCls:c?a.invalidIconCls:h?a.invalidUnderCls:'',errorMsgCls:q,growCls:a.grow?a.growCls:'',tipAnchorTarget:a.id+'-inputEl',errorWrapStyle:c&&!k?'visibility:hidden':'display:none',fieldLabel:a.getFieldLabel(),labelSeparator:a.labelSeparator};a.getInsertionRenderData(i,a.labelableInsertions);return i},getHorizontalPaddingStyle:function(){return 'padding-right:'},beforeLabelRender:function(){var a=this;a.setFieldDefaults(a.getInherited().fieldDefaults);if(a.ownerLayout){a.addCls('x-'+a.ownerLayout.type+'-form-item')}if(!a.hasVisibleLabel()){a.addCls(a.noLabelCls)}},onLabelRender:function(){var a=this,f={},e=Ext.Element,d=a.errorWrapEl,c,b;if(d){d.setVisibilityMode(a.msgTarget==='side'&&!a.autoFitErrors?e.VISIBILITY:e.DISPLAY)}if(a.extraMargins){c=a.el.getMargin();for(b in c){if(c.hasOwnProperty(b)){f['margin-'+b]=c[b]+a.extraMargins[b]+'px'}}a.el.setStyle(f)}},hasVisibleLabel:function(){if(this.hideLabel){return !1}return !(this.hideEmptyLabel&&!this.getFieldLabel())},getSubTplMarkup:function(){return ''},getInputId:function(){return ''},getActiveError:function(){return this.activeError||''},hasActiveError:function(){return !!this.getActiveError()},setActiveError:function(a){this.setActiveErrors(a)},getActiveErrors:function(){return this.activeErrors||[]},setActiveErrors:function(c){var a=this,h=a.errorWrapEl,b=a.msgTarget,g=b==='side',i=b==='qtip',e,d,j,f;c=Ext.Array.from(c);j=a.getTpl('activeErrorsTpl');a.activeErrors=c;d=a.activeError=j.apply({fieldLabel:a.fieldLabel,errors:c,listCls:'x-list-plain'});a.renderActiveError();if(a.rendered){e=a.getActionEl();if(g){a.errorEl.dom.setAttribute('data-errorqtip',d)}else {if(i){e.dom.setAttribute('data-errorqtip',d)}else {if(b==='title'){e.dom.setAttribute('title',d)}}}if(b!=='title'){a.ariaErrorEl.dom.innerHTML=c.join('. ');e.dom.setAttribute('aria-describedby',a.ariaErrorEl.id)}if(g||i){Ext.form.Labelable.initTip()}if(!a.msgTargets[b]){f=Ext.get(b);if(f){f.dom.innerHTML=d}}}if(h){h.setVisible(c.length>0);if(g&&a.autoFitErrors){a.labelEl.addCls(a.topLabelSideErrorCls)}a.updateLayout()}},unsetActiveError:function(){var a=this,e=a.errorWrapEl,b=a.msgTarget,f=a.restoreDisplay,c,d;if(a.hasActiveError()){delete a.activeError;delete a.activeErrors;a.renderActiveError();if(a.rendered){c=a.getActionEl();if(b==='qtip'){c.dom.removeAttribute('data-errorqtip')}else {if(b==='title'){c.dom.removeAttribute('title')}}if(b!=='title'){a.ariaErrorEl.dom.innerHTML='';c.dom.removeAttribute('aria-describedby')}if(!a.msgTargets[b]){d=Ext.get(b);if(d){d.dom.innerHTML=''}}if(e){e.hide();if(b==='side'&&a.autoFitErrors){a.labelEl.removeCls(a.topLabelSideErrorCls)}a.updateLayout();if(f){a.el.dom.style.display='block';a.restoreDisplay()}}}}},doRestoreDisplay:function(){var a=this.el;if(a&&a.dom){a.dom.style.display=''}},renderActiveError:function(){var a=this,b=a.getActiveError(),c=!!b;if(b!==a.lastActiveError){a.lastActiveError=b;a.fireEvent('errorchange',a,b)}if(a.rendered&&!a.destroyed&&!a.preventMark){a.toggleInvalidCls(c);if(a.errorEl){a.errorEl.dom.innerHTML=b}}},toggleInvalidCls:function(a){this.el[a?'addCls':'removeCls'](this.invalidCls)},setFieldDefaults:function(b){var a;for(a in b){if(!this.hasOwnProperty(a)){this[a]=b[a]}}}},0,0,0,0,0,0,[Ext.form,'Labelable'],function(){if(Ext.supports.Touch){this.prototype.msgTarget='side'}});Ext.cmd.derive('Ext.form.field.Field',Ext.Base,{mixinId:'field',isFormField:!0,config:{validation:null,validationField:null},disabled:!1,submitValue:!0,validateOnChange:!0,valuePublishEvent:'change',suspendCheckChange:0,dirty:!1,initField:function(){var a=this,b=a.valuePublishEvent,d,c;a.initValue();if(Ext.isString(b)){a.on(b,a.publishValue,a)}else {for(c=0,d=b.length;c name="{name}"',' value="{[Ext.util.Format.htmlEncode(values.value)]}"',' placeholder="{placeholder}"','{%if (values.maxLength !== undefined){%} maxlength="{maxLength}"{%}%}',' readonly="readonly"',' disabled="disabled"',' tabindex="{tabIdx}"',' style="{fieldStyle}"',' {$}="{.}"',' class="{fieldCls} {typeCls} {typeCls}-{ui} {editableCls} {inputCls}" autocomplete="off"/>',{disableFormats:!0}],defaultBindProperty:'value',autoEl:{role:'presentation'},subTplInsertions:['inputAttrTpl'],childEls:['inputEl'],inputType:'text',isTextInput:!0,invalidText:'The value in this field is invalid',fieldCls:'x-form-field',focusCls:'form-focus',dirtyCls:'x-form-dirty',checkChangeEvents:Ext.isIE&&(!document.documentMode||document.documentMode<=9)?['change','propertychange','keyup']:['change','input','textInput','keyup','dragdrop'],ignoreChangeRe:/data\-errorqtip|style\.|className/,checkChangeBuffer:50,liquidLayout:!0,readOnly:!1,readOnlyCls:'x-form-readonly',validateOnBlur:!0,hasFocus:!1,baseCls:'x-field',fieldBodyCls:'x-field-body',maskOnDisable:!1,stretchInputElFixed:!0,ariaEl:'inputEl',initComponent:function(){var a=this;Ext.Component.prototype.initComponent.call(this);a.subTplData=a.subTplData||{};a.initLabelable();a.initField();a.initDefaultName();if(a.readOnly){a.addCls(a.readOnlyCls)}a.addCls('x-form-type-'+a.inputType)},initDefaultName:function(){var a=this;if(!a.name){a.name=a.getInputId()}},getInputId:function(){return this.inputId||(this.inputId=this.id+'-inputEl')},getSubTplData:function(f){var a=this,e=a.inputType,d=a.getInputId(),b,c;b=Ext.apply({ui:a.ui,id:d,cmpId:a.id,name:a.name||d,disabled:a.disabled,readOnly:a.readOnly,value:a.getRawValue(),type:e,fieldCls:a.fieldCls,fieldStyle:a.getFieldStyle(),childElCls:f.childElCls,tabIdx:a.tabIndex,inputCls:a.inputCls,typeCls:'x-form-'+(a.isTextInput?'text':e)},a.subTplData);if(a.ariaRole){c={role:a.ariaRole,'aria-hidden':!!a.hidden,'aria-disabled':!!a.disabled,'aria-readonly':!!a.readOnly,'aria-invalid':!1};if(a.ariaLabel){c['aria-label']=a.ariaLabel}if(a.format&&a.formatText&&!b.title){c.title=Ext.String.formatEncode(a.formatText,a.format)}b.inputElAriaAttributes=Ext.apply(c,a.getAriaAttributes())}a.getInsertionRenderData(b,a.subTplInsertions);return b},getSubTplMarkup:function(f){var b=this,c=b.getSubTplData(f),e=b.getTpl('preSubTpl'),d=b.getTpl('postSubTpl'),a='';if(e){a+=e.apply(c)}a+=b.getTpl('fieldSubTpl').apply(c);if(d){a+=d.apply(c)}return a},initRenderData:function(){return Ext.applyIf(Ext.Component.prototype.initRenderData.call(this),this.getLabelableRenderData())},setFieldStyle:function(b){var c=this,a=c.inputEl;if(a){a.applyStyles(b)}c.fieldStyle=b},getFieldStyle:function(){var a=this.fieldStyle;return Ext.isObject(a)?Ext.DomHelper.generateStyles(a,null,!0):a||''},onRender:function(){this.callParent(arguments);this.mixins.labelable.self.initTip();this.renderActiveError()},onFocusLeave:function(a){Ext.Component.prototype.onFocusLeave.call(this,a);this.completeEdit()},completeEdit:Ext.emptyFn,isFileUpload:function(){return this.inputType==='file'},getSubmitData:function(){var a=this,b=null,c;if(!a.disabled&&a.submitValue){c=a.getSubmitValue();if(c!==null){b={};b[a.getName()]=c}}return b},getSubmitValue:function(){return this.processRawValue(this.getRawValue())},getRawValue:function(){var a=this,b=a.inputEl?a.inputEl.getValue():Ext.valueFrom(a.rawValue,'');a.rawValue=b;return b},setRawValue:function(b){var a=this,c=a.rawValue;if(!a.transformRawValue.$nullFn){b=a.transformRawValue(b)}b=Ext.valueFrom(b,'');if(c===undefined||c!==b||a.valueContainsPlaceholder){a.rawValue=b;if(a.inputEl){a.bindChangeEvents(!1);a.inputEl.dom.value=b;a.bindChangeEvents(!0)}if(a.rendered&&a.reference){a.publishState('rawValue',b)}}return b},transformRawValue:Ext.identityFn,valueToRaw:function(a){return ''+Ext.valueFrom(a,'')},rawToValue:Ext.identityFn,processRawValue:Ext.identityFn,getValue:function(){var a=this,b=a.rawToValue(a.processRawValue(a.getRawValue()));a.value=b;return b},setValue:function(b){var a=this;a.setRawValue(a.valueToRaw(b));return a.mixins.field.setValue.call(a,b)},onBoxReady:function(){var a=this;Ext.Component.prototype.onBoxReady.apply(this,arguments);if(a.setReadOnlyOnBoxReady){a.setReadOnly(a.readOnly)}},onDisable:function(){var a=this,b=a.inputEl;Ext.Component.prototype.onDisable.call(this);if(b){b.dom.disabled=!0;if(a.hasActiveError()){a.clearInvalid();a.hadErrorOnDisable=!0}}if(a.wasValid===!1){a.checkValidityChange(!0)}},onEnable:function(){var a=this,b=a.inputEl,d=a.preventMark,c;Ext.Component.prototype.onEnable.call(this);if(b){b.dom.disabled=!1}if(a.wasValid!==undefined){a.forceValidation=!0;a.preventMark=!a.hadErrorOnDisable;c=a.isValid();a.forceValidation=!1;a.preventMark=d;a.checkValidityChange(c)}delete a.hadErrorOnDisable},setReadOnly:function(b){var a=this,c=a.inputEl,d=a.readOnly;b=!!b;a[b?'addCls':'removeCls'](a.readOnlyCls);a.readOnly=b;if(c){c.dom.readOnly=b;a.ariaEl.dom.setAttribute('aria-readonly',b)}else {if(a.rendering){a.setReadOnlyOnBoxReady=!0}}if(b!==d){a.fireEvent('writeablechange',a,b)}},fireKey:function(a){if(a.isSpecialKey()){this.fireEvent('specialkey',this,a)}},initEvents:function(){var a=this,d=a.inputEl,f=a.onFieldMutation,e=a.checkChangeEvents,g=e.length,c,b;if(d){a.mon(d,Ext.supports.SpecialKeyDownRepeat?'keydown':'keypress',a.fireKey,a);for(c=0;c style="{triggerStyle}">','{[values.$trigger.renderBody(values)]}',''],statics:{weightComparator:function(a,b){return a.weight-b.weight}},constructor:function(c){var a=this,b;Ext.apply(a,c);if(a.compat4Mode){b=a.cls;a.focusCls=[a.focusCls,b+'-focus'];a.overCls=[a.overCls,b+'-over'];a.clickCls=[a.clickCls,b+'-click']}},afterFieldRender:function(){this.initEvents()},destroy:function(){var a=this;a.clickRepeater=a.el=Ext.destroy(a.clickRepeater,a.el);a.callParent()},getBodyRenderData:Ext.emptyFn,getEl:function(){return this.el||null},getStateEl:function(){return this.el},hide:function(){var b=this,a=b.el;b.hidden=!0;if(a){a.hide()}},initEvents:function(){var a=this,b=a.isFieldEnabled,c=a.getStateEl(),d=a.el;c.addClsOnOver(a.overCls,b,a);c.addClsOnClick(a.clickCls,b,a);if(a.repeatClick){a.clickRepeater=new Ext.util.ClickRepeater(d,{preventDefault:!0,handler:a.onClick,listeners:{mousedown:a.onClickRepeaterMouseDown,scope:a},scope:a})}else {a.field.mon(d,{click:a.onClick,mousedown:a.onMouseDown,scope:a})}},isFieldEnabled:function(){return !this.field.disabled},isVisible:function(){var a=this,c=a.field,b=!1;if(a.hidden||!c||!a.rendered||a.destroyed){b=!0}return !b},onClick:function(){var a=this,c=arguments,e=a.clickRepeater?c[1]:c[0],d=a.handler,b=a.field;if(d&&!b.readOnly&&a.isFieldEnabled()){Ext.callback(a.handler,a.scope,[b,a,e],0,b)}},resolveListenerScope:function(a){return this.field.resolveSatelliteListenerScope(this,a)},onMouseDown:function(a){if(a.pointerType!=='touch'&&!this.field.owns(Ext.Element.getActiveElement())){this.field.inputEl.focus()}if(this.preventMouseDown){a.preventDefault()}},onClickRepeaterMouseDown:function(b,a){if(!a.parentEvent||a.parentEvent.type==='mousedown'){this.field.inputEl.focus()}a.preventDefault()},onFieldBlur:function(){this.getStateEl().removeCls(this.focusCls)},onFieldFocus:function(){this.getStateEl().addCls(this.focusCls)},onFieldRender:function(){var a=this,b=a.el=a.field.triggerWrap.selectNode('#'+a.domId,!1);b.setVisibilityMode(Ext.Element.DISPLAY);a.rendered=!0},renderBody:function(b){var a=this,c=a.bodyTpl;Ext.apply(b,a.getBodyRenderData());return c?Ext.XTemplate.getTpl(a,'bodyTpl').apply(b):''},renderTrigger:function(b){var a=this,d=a.width,c=a.hidden?'display:none;':'';if(d){c+='width:'+d}return Ext.XTemplate.getTpl(a,'renderTpl').apply({$trigger:a,fieldData:b,ui:b.ui,childElCls:b.childElCls,triggerId:a.domId=a.field.id+'-trigger-'+a.id,cls:a.cls,triggerStyle:c,extraCls:a.extraCls,baseCls:a.baseCls})},setHidden:function(a){if(a!==this.hidden){this[a?'hide':'show']()}},setVisible:function(a){this.setHidden(!a)},show:function(){var b=this,a=b.el;b.hidden=!1;if(a){a.show()}}},1,0,0,0,['trigger.trigger'],[[Ext.mixin.Factoryable.prototype.mixinId||Ext.mixin.Factoryable.$className,Ext.mixin.Factoryable]],[Ext.form.trigger,'Trigger'],0);Ext.cmd.derive('Ext.form.field.Text',Ext.form.field.Base,{alternateClassName:['Ext.form.TextField','Ext.form.Text'],config:{hideTrigger:!1,triggers:undefined},renderConfig:{editable:!0},growMin:30,growMax:800,growAppend:'W',allowBlank:!0,validateBlank:!1,allowOnlyWhitespace:!0,minLength:0,maxLength:Number.MAX_VALUE,minLengthText:'The minimum length for this field is {0}',maxLengthText:'The maximum length for this field is {0}',blankText:'This field is required',regexText:'',emptyText:'',emptyCls:'x-form-empty-field',requiredCls:'x-form-required-field',valueContainsPlaceholder:!1,ariaRole:'textbox',repeatTriggerClick:!1,triggerWrapCls:'x-form-trigger-wrap',triggerWrapFocusCls:'x-form-trigger-wrap-focus',triggerWrapInvalidCls:'x-form-trigger-wrap-invalid',fieldBodyCls:'x-form-text-field-body',inputWrapCls:'x-form-text-wrap',inputWrapFocusCls:'x-form-text-wrap-focus',inputWrapInvalidCls:'x-form-text-wrap-invalid',growCls:'x-form-text-grow',needArrowKeys:!0,squashMouseUp:{mouseup:function(){},translate:!1,single:!0,preventDefault:!0},childEls:['triggerWrap','inputWrap'],preSubTpl:[''],initComponent:function(){var a=this,b=a.emptyCls;if(a.allowOnlyWhitespace===!1){a.allowBlank=!1}if(a.size){a.defaultBodyWidth=a.size*6.5+20}if(!a.onTrigger1Click){a.onTrigger1Click=a.onTriggerClick}Ext.form.field.Base.prototype.initComponent.call(this);if(a.readOnly){a.setReadOnly(a.readOnly)}a.fieldFocusCls=a.baseCls+'-focus';a.emptyUICls=b+' '+b+'-'+a.ui;a.addStateEvents('change')},initEvents:function(){var a=this,b=a.inputEl;Ext.form.field.Base.prototype.initEvents.call(this);if(a.selectOnFocus||a.emptyText){a.mon(b,'mousedown',a.onMouseDown,a)}if(a.maskRe||a.vtype&&a.disableKeyFilter!==!0&&(a.maskRe=Ext.form.field.VTypes[a.vtype+'Mask'])){a.mon(b,'keypress',a.filterKeys,a)}if(a.enableKeyEvents){a.mon(b,{scope:a,keyup:a.onKeyUp,keydown:a.onKeyDown,keypress:a.onKeyPress})}},isEqual:function(a,b){return this.isEqualAsString(a,b)},onChange:function(a,b){Ext.form.field.Base.prototype.onChange.apply(this,arguments);this.autoSize()},getSubTplData:function(h){var a=this,c=a.getRawValue(),g=a.emptyText&&c.length<1,b=a.maxLength,e,f,d;if(a.enforceMaxLength){if(b===Number.MAX_VALUE){b=undefined}}else {b=undefined}if(g){if(Ext.supports.Placeholder){e=a.emptyText}else {c=a.emptyText;a.valueContainsPlaceholder=!0}}f=Ext.apply(Ext.form.field.Base.prototype.getSubTplData.call(this,h),{triggerWrapCls:a.triggerWrapCls,inputWrapCls:a.inputWrapCls,triggers:a.orderedTriggers,maxLength:b,readOnly:!a.editable||a.readOnly,placeholder:e,value:c,fieldCls:a.fieldCls+(g&&(e||c)?' '+a.emptyUICls:'')+(a.allowBlank?'':' '+a.requiredCls)});d=f.inputElAriaAttributes;if(d){d['aria-required']=!a.allowBlank}return f},onRender:function(){var a=this,b=a.getTriggers(),c=[],d,e;if(Ext.supports.FixedTableWidthBug){a.el._needsTableWidthFix=!0}(arguments.callee.$previous||Ext.form.field.Base.prototype.onRender).call(this);if(b){this.invokeTriggers('onFieldRender');for(d in b){c.push(b[d].el)}e=a.triggerEl=a.triggerCell=new Ext.CompositeElement(c,!0)}a.inputCell=a.inputWrap},afterRender:function(){var a=this;a.autoSize();Ext.form.field.Base.prototype.afterRender.call(this);a.invokeTriggers('afterFieldRender')},onMouseDown:function(){if(!this.hasFocus){Ext.getDoc().on(this.squashMouseUp)}},applyTriggers:function(c){var a=this,j=a.getHideTrigger(),k=a.readOnly,f=a.orderedTriggers=[],i=a.repeatTriggerClick,e,b,h,g,d;if(!c){c={};if(a.triggerCls&&!a.trigger1Cls){a.trigger1Cls=a.triggerCls}for(d=1;g=a['trigger'+d+'Cls'];d++){c['trigger'+d]={cls:g,extraCls:'x-trigger-index-'+d,handler:'onTrigger'+d+'Click',compat4Mode:!0,scope:a}}}for(e in c){if(c.hasOwnProperty(e)){b=c[e];b.field=a;b.id=e;if(k&&b.hideOnReadOnly!==!1||j&&b.hidden!==!1){b.hidden=!0}if(i&&b.repeatClick!==!1){b.repeatClick=!0}h=c[e]=Ext.form.trigger.Trigger.create(b);f.push(h)}}Ext.Array.sort(f,Ext.form.trigger.Trigger.weightComparator);return c},invokeTriggers:function(d,e){var f=this,a=f.getTriggers(),c,b;if(a){for(c in a){if(a.hasOwnProperty(c)){b=a[c];b[d].apply(b,e||[])}}}},getTrigger:function(a){return this.getTriggers()[a]},updateHideTrigger:function(a){this.invokeTriggers(a?'hide':'show')},updateEditable:function(a,b){this.setReadOnlyAttr(!a||this.readOnly)},setReadOnly:function(a){var b=this,d=b.getTriggers(),f=b.getHideTrigger(),c,e;a=!!a;Ext.form.field.Base.prototype.setReadOnly.call(this,a);if(b.rendered){b.setReadOnlyAttr(a||!b.editable)}if(d){for(e in d){c=d[e];if(c.hideOnReadOnly===!0||c.hideOnReadOnly!==!1&&!f){c.setVisible(!a)}}}},setReadOnlyAttr:function(c){var b=this,a='readonly',d=b.inputEl.dom;if(c){d.setAttribute(a,a)}else {d.removeAttribute(a)}if(b.ariaRole){b.ariaEl.dom.setAttribute('aria-readonly',!!c)}},processRawValue:function(c){var e=this,a=e.stripCharsRe,d,b;if(a){if(!a.global){d='g';d+=a.ignoreCase?'i':'';d+=a.multiline?'m':'';a=new RegExp(a.source,d)}b=c.replace(a,'');if(b!==c){e.setRawValue(b);c=b}}return c},onDisable:function(){Ext.form.field.Base.prototype.onDisable.call(this);if(Ext.isIE){this.inputEl.dom.unselectable='on'}},onEnable:function(){Ext.form.field.Base.prototype.onEnable.call(this);if(Ext.isIE){this.inputEl.dom.unselectable=''}},onKeyDown:function(a){this.fireEvent('keydown',this,a)},onKeyUp:function(a){this.fireEvent('keyup',this,a)},onKeyPress:function(a){this.fireEvent('keypress',this,a)},reset:function(){Ext.form.field.Base.prototype.reset.call(this);this.applyEmptyText()},applyEmptyText:function(){var a=this,b=a.emptyText,c;if(a.rendered&&b){c=a.getRawValue().length<1&&!a.hasFocus;if(Ext.supports.Placeholder){a.inputEl.dom.placeholder=b}else {if(c){a.setRawValue(b);a.valueContainsPlaceholder=!0}}if(c){a.inputEl.addCls(a.emptyUICls)}else {a.inputEl.removeCls(a.emptyUICls)}a.autoSize()}},getEmptyText:function(){return this.emptyText},setEmptyText:function(e){var a=this,c=a.inputEl,b=c&&c.dom,d=e||'';if(e){a.emptyText=d;a.applyEmptyText()}else {if(b){if(Ext.supports.Placeholder){b.removeAttribute('placeholder')}else {if(b.value!==a.getRawValue()){b.value='';c.removeCls(a.emptyUICls)}}a.valueContainsPlaceholder=!1}}a.emptyText=d;return a},afterFirstLayout:function(){Ext.form.field.Base.prototype.afterFirstLayout.call(this);if(Ext.isIE&&this.disabled){var a=this.inputEl;if(a){a.dom.unselectable='on'}}},toggleInvalidCls:function(b){var a=b?'addCls':'removeCls';Ext.form.field.Base.prototype.toggleInvalidCls.call(this);this.triggerWrap[a](this.triggerWrapInvalidCls);this.inputWrap[a](this.inputWrapInvalidCls)},beforeFocus:function(){var a=this,b=a.inputEl,c=a.emptyText,d;Ext.form.field.Base.prototype.beforeFocus.apply(this,arguments);if(c&&!Ext.supports.Placeholder&&(b.dom.value===a.emptyText&&a.valueContainsPlaceholder)){a.setRawValue('');d=!0;b.removeCls(a.emptyUICls);a.valueContainsPlaceholder=!1}else {if(Ext.supports.Placeholder){b.removeCls(a.emptyUICls)}}},onFocus:function(b){var a=this;Ext.form.field.Base.prototype.onFocus.apply(this,arguments);if(a.selectOnFocus){a.inputEl.dom.select()}if(a.emptyText){a.autoSize()}a.addCls(a.fieldFocusCls);a.triggerWrap.addCls(a.triggerWrapFocusCls);a.inputWrap.addCls(a.inputWrapFocusCls);a.invokeTriggers('onFieldFocus',[b])},onBlur:function(b){var a=this;Ext.form.field.Base.prototype.onBlur.apply(this,arguments);a.removeCls(a.fieldFocusCls);a.triggerWrap.removeCls(a.triggerWrapFocusCls);a.inputWrap.removeCls(a.inputWrapFocusCls);a.invokeTriggers('onFieldBlur',[b])},completeEdit:function(a){Ext.form.field.Base.prototype.completeEdit.call(this,a);this.applyEmptyText()},filterKeys:function(a){if(a.ctrlKey&&!a.altKey||a.isSpecialKey()){return}var b=String.fromCharCode(a.getCharCode());if(!this.maskRe.test(b)){a.stopEvent()}},getState:function(){return this.addPropertyToState(Ext.form.field.Base.prototype.getState.call(this),'value')},applyState:function(a){Ext.form.field.Base.prototype.applyState.apply(this,arguments);if(a.hasOwnProperty('value')){this.setValue(a.value)}},getRawValue:function(){var b=this,a=Ext.form.field.Base.prototype.getRawValue.call(this);if(a===b.emptyText&&b.valueContainsPlaceholder){a=''}return a},setValue:function(c){var a=this,b=a.inputEl;if(b&&a.emptyText&&!Ext.isEmpty(c)){b.removeCls(a.emptyUICls);a.valueContainsPlaceholder=!1}Ext.form.field.Base.prototype.setValue.apply(this,arguments);a.applyEmptyText();return a},getErrors:function(b){b=arguments.length?b==null?'':b:this.processRawValue(this.getRawValue());var a=this,c=Ext.form.field.Base.prototype.getErrors.call(this,b),f=a.validator,d=a.vtype,j=Ext.form.field.VTypes,k=a.regex,i=Ext.String.format,e,h,g;if(Ext.isFunction(f)){e=f.call(a,b);if(e!==!0){c.push(e)}}h=a.allowOnlyWhitespace?b:Ext.String.trim(b);if(h.length<1||b===a.emptyText&&a.valueContainsPlaceholder){if(!a.allowBlank){c.push(a.blankText)}if(!a.validateBlank){return c}g=!0}if(!g&&b.lengtha.maxLength){c.push(i(a.maxLengthText,a.maxLength))}if(d){if(!j[d](b,a)){c.push(a.vtypeText||j[d+'Text'])}}if(k&&!k.test(b)){c.push(a.regexText||a.invalidText)}return c},selectText:function(a,b){var f=this,g=f.getRawValue(),c=g.length,e=f.inputEl.dom,d;if(c>0){a=a===undefined?0:Math.min(a,c);b=b===undefined?c:Math.min(b,c);if(e.setSelectionRange){e.setSelectionRange(a,b)}else {if(e.createTextRange){d=e.createTextRange();d.moveStart('character',a);d.moveEnd('character',b-c);d.select()}}}},getGrowWidth:function(){return this.inputEl.dom.value},autoSize:function(){var a=this,d,f,c,g,b,e;if(a.grow&&a.rendered&&a.getSizeModel().width.auto){g=a.inputEl;d=a.getTriggers();c=0;e=Ext.util.Format.htmlEncode(a.getGrowWidth()||(a.hasFocus?'':a.emptyText)||'');e+=a.growAppend;for(f in d){c+=d[f].el.getWidth()}b=g.getTextWidth(e)+c+a.inputWrap.getBorderWidth('lr')+a.triggerWrap.getBorderWidth('lr');b=Math.min(Math.max(b,a.growMin),a.growMax);a.bodyEl.setWidth(b);a.updateLayout();a.fireEvent('autosize',a,b)}},onDestroy:function(){var a=this;a.invokeTriggers('destroy');Ext.destroy(a.triggerRepeater);Ext.form.field.Base.prototype.onDestroy.call(this)},onTriggerClick:Ext.emptyFn,privates:{getTdType:function(){return 'textfield'}},deprecated:{5:{methods:{getTriggerWidth:function(){var a=this.getTriggers(),c=0,b;if(a&&this.rendered){for(b in a){if(a.hasOwnProperty(b)){c+=a[b].el.getWidth()}}}return c}}}}},0,['textfield'],['component','box','field','textfield'],{'component':!0,'box':!0,'field':!0,'textfield':!0},['widget.textfield'],0,[Ext.form.field,'Text',Ext.form,'TextField',Ext.form,'Text'],0);Ext.cmd.derive('Ext.form.field.TextArea',Ext.form.field.Text,{alternateClassName:'Ext.form.TextArea',fieldSubTpl:['',{disableFormats:!0}],growMin:60,growMax:1000,growAppend:'\n-',enterIsSpecial:!1,preventScrollbars:!1,returnRe:/\r/g,inputCls:'x-form-textarea',extraFieldBodyCls:'x-form-textarea-body',ariaAttributes:{'aria-multiline':!0},getSubTplData:function(d){var a=this,c=a.getFieldStyle(),b=Ext.form.field.Text.prototype.getSubTplData.apply(this,arguments);if(a.grow){if(a.preventScrollbars){b.fieldStyle=(c||'')+';overflow:hidden;height:'+a.growMin+'px'}}return b},afterRender:function(){var a=this;Ext.form.field.Text.prototype.afterRender.apply(this,arguments);a.needsMaxCheck=a.enforceMaxLength&&a.maxLength!==Number.MAX_VALUE&&!Ext.supports.TextAreaMaxLength;if(a.needsMaxCheck){a.inputEl.on('paste',a.onPaste,a)}},transformRawValue:function(a){return this.stripReturns(a)},getValue:function(){return this.stripReturns(Ext.form.field.Text.prototype.getValue.call(this))},valueToRaw:function(a){a=this.stripReturns(a);return Ext.form.field.Text.prototype.valueToRaw.call(this,a)},stripReturns:function(a){if(a&&typeof a==='string'){a=a.replace(this.returnRe,'')}return a},onPaste:function(){var a=this;if(!a.pasteTask){a.pasteTask=new Ext.util.DelayedTask(a.pasteCheck,a)}a.pasteTask.delay(1)},pasteCheck:function(){var b=this,a=b.getValue(),c=b.maxLength;if(a.length>c){a=a.substr(0,c);b.setValue(a)}},fireKey:function(a){var b=this,c=a.getKey(),d;if(a.isSpecialKey()&&(b.enterIsSpecial||(c!==a.ENTER||a.hasModifier()))){b.fireEvent('specialkey',b,a)}if(b.needsMaxCheck&&c!==a.BACKSPACE&&c!==a.DELETE&&!a.isNavKeyPress()&&!b.isCutCopyPasteSelectAll(a,c)){d=b.getValue();if(d.length>=b.maxLength){a.stopEvent()}}},isCutCopyPasteSelectAll:function(a,b){if(a.ctrlKey){return b===a.A||b===a.C||b===a.V||b===a.X}return !1},autoSize:function(){var a=this,b,c,e,d;if(a.grow&&a.rendered&&a.getSizeModel().height.auto){b=a.inputEl;e=b.getWidth(!0);d=Ext.util.Format.htmlEncode(b.dom.value)||' ';d+=a.growAppend;d=d.replace(/\n/g,'
');c=Ext.util.TextMetrics.measure(b,d,e).height+b.getPadding('tb')+a.inputWrap.getBorderWidth('tb')+a.triggerWrap.getBorderWidth('tb');c=Math.min(Math.max(c,a.growMin),a.growMax);a.bodyEl.setHeight(c);a.updateLayout();a.fireEvent('autosize',a,c)}},beforeDestroy:function(){var a=this.pasteTask;if(a){a.cancel();this.pasteTask=null}Ext.form.field.Text.prototype.beforeDestroy.call(this)}},0,['textarea','textareafield'],['component','box','field','textfield','textareafield','textarea'],{'component':!0,'box':!0,'field':!0,'textfield':!0,'textareafield':!0,'textarea':!0},['widget.textarea','widget.textareafield'],0,[Ext.form.field,'TextArea',Ext.form,'TextArea'],0);Ext.cmd.derive('Ext.window.MessageBox',Ext.window.Window,{OK:1,YES:2,NO:4,CANCEL:8,OKCANCEL:9,YESNO:6,YESNOCANCEL:14,INFO:'x-message-box-info',WARNING:'x-message-box-warning',QUESTION:'x-message-box-question',ERROR:'x-message-box-error',hideMode:'offsets',closeAction:'hide',resizable:!1,scrollable:!0,title:' ',defaultMinWidth:250,defaultMaxWidth:600,defaultMinHeight:110,defaultMaxHeight:500,minWidth:null,maxWidth:null,minHeight:null,maxHeight:null,constrain:!0,cls:['x-message-box','x-hidden-offsets'],layout:{type:'vbox',align:'stretch'},shrinkWrapDock:!0,defaultTextHeight:75,minProgressWidth:250,minPromptWidth:250,buttonText:{ok:'OK',yes:'Yes',no:'No',cancel:'Cancel'},buttonIds:['ok','yes','no','cancel'],titleText:{confirm:'Confirm',prompt:'Prompt',wait:'Loading...',alert:'Attention'},baseIconCls:'x-message-box-icon',ariaRole:'alertdialog',makeButton:function(b){var a=this.buttonIds[b];return new Ext.button.Button({handler:this.btnCallback,itemId:a,scope:this,text:this.buttonText[a],minWidth:75})},btnCallback:function(e,b){var a=this,d,c;if(b&&b.type==='keydown'&&!b.isSpecialKey()){b.getTarget(null,null,!0).on({keyup:function(c){a.btnCallback(e,c)},single:!0});return}if(a.cfg.prompt||a.cfg.multiline){if(a.cfg.multiline){c=a.textArea}else {c=a.textField}d=c.getValue();c.reset()}a.hide();a.userCallback(e.itemId,d,a.cfg)},hide:function(){var a=this,b=a.cfg?a.cfg.cls:'';a.progressBar.reset();if(b){a.removeCls(b)}Ext.window.Window.prototype.hide.apply(this,arguments)},constructor:function(b){var a=this;Ext.window.Window.prototype.constructor.apply(this,arguments);a.minWidth=a.defaultMinWidth=a.minWidth||a.defaultMinWidth;a.maxWidth=a.defaultMaxWidth=a.maxWidth||a.defaultMaxWidth;a.minHeight=a.defaultMinHeight=a.minHeight||a.defaultMinHeight;a.maxHeight=a.defaultMaxHeight=a.maxHeight||a.defaultMaxHeight},initComponent:function(e){var a=this,b=a.id,d,c;a.title=a.title||' ';a.iconCls=a.iconCls||'';a.topContainer=new Ext.container.Container({layout:'hbox',padding:10,style:{overflow:'hidden'},items:[a.iconComponent=new Ext.Component({cls:a.baseIconCls}),a.promptContainer=new Ext.container.Container({flex:1,layout:{type:'vbox',align:'stretch'},items:[a.msg=new Ext.Component({id:b+'-msg',cls:a.baseCls+'-text'}),a.textField=new Ext.form.field.Text({id:b+'-textfield',enableKeyEvents:!0,listeners:{keydown:a.onPromptKey,scope:a}}),a.textArea=new Ext.form.field.TextArea({id:b+'-textarea',height:75})]})]});a.progressBar=new Ext.ProgressBar({id:b+'-progressbar',margin:'0 10 10 10'});a.items=[a.topContainer,a.progressBar];a.msgButtons=[];for(d=0;d<4;d++){c=a.makeButton(d);a.msgButtons[c.itemId]=c;a.msgButtons.push(c)}a.bottomTb=new Ext.toolbar.Toolbar({id:b+'-toolbar',ui:'footer',dock:'bottom',layout:{pack:'center'},items:[a.msgButtons[0],a.msgButtons[1],a.msgButtons[2],a.msgButtons[3]]});a.dockedItems=[a.bottomTb];a.on('close',a.onClose,a);Ext.window.Window.prototype.initComponent.call(this)},onClose:function(){var a=this.header.child('[type=close]');if(a){a.itemId='cancel';this.btnCallback(a);delete a.itemId}},onPromptKey:function(c,b){var a=this;if(b.keyCode===b.RETURN||b.keyCode===10){if(a.msgButtons.ok.isVisible()){a.msgButtons.ok.handler.call(a,a.msgButtons.ok)}else {if(a.msgButtons.yes.isVisible()){a.msgButtons.yes.handler.call(a,a.msgButtons.yes)}}}},reconfigure:function(b){var a=this,j=0,q=!0,t=a.buttonText,g=a.resizer,c=a.header,r=c&&!c.isHeader,s=b&&(b.message||b.msg),i,n,m,e,d,f,o,k,l,h,p;a.updateButtonText();a.cfg=b=b||{};h=b.wait;if(b.width){n=b.width}if(b.height){m=b.height}a.minWidth=b.minWidth||a.defaultMinWidth;a.maxWidth=b.maxWidth||a.defaultMaxWidth;a.minHeight=b.minHeight||a.defaultMinHeight;a.maxHeight=b.maxHeight||a.defaultMaxHeight;if(g){i=g.resizeTracker;g.minWidth=i.minWidth=a.minWidth;g.maxWidth=i.maxWidth=a.maxWidth;g.minHeight=i.minHeight=a.minHeight;g.maxHeight=i.maxHeight=a.maxHeight}delete a.defaultFocus;if(b.defaultFocus){a.defaultFocus=b.defaultFocus}a.animateTarget=b.animateTarget||undefined;a.modal=b.modal!==!1;a.setTitle(b.title||r&&c.title||a.title);a.setIconCls(b.iconCls||r&&c.iconCls||a.iconCls);if(Ext.isObject(b.buttons)){a.buttonText=b.buttons;j=0}else {a.buttonText=b.buttonText||a.buttonText;j=Ext.isNumber(b.buttons)?b.buttons:0}j=j|a.updateButtonText();a.buttonText=t;Ext.suspendLayouts();a.width=a.height=null;if(n||m){if(n){a.setWidth(n)}if(m){a.setHeight(m)}}a.hidden=!1;if(!a.rendered){a.render(Ext.getBody())}a.closable=b.closable!==!1&&!h;c=a.header;if(c){p=c.child('[type=close]');if(p){p.setVisible(a.closable)}if(!b.title&&!a.closable&&!b.iconCls){c.hide()}else {c.show()}}a.liveDrag=!b.proxyDrag;a.userCallback=Ext.Function.bindCallback(b.callback||b.fn||Ext.emptyFn,b.scope||Ext.global);a.setIcon(b.icon);o=a.msg;if(s){o.setHtml(s);o.show()}else {o.hide()}d=a.textArea;f=a.textField;if(b.prompt||b.multiline){a.multiline=b.multiline;if(b.multiline){d.setValue(b.value);d.setHeight(b.defaultTextHeight||a.defaultTextHeight);d.show();f.hide();a.defaultFocus=d}else {f.setValue(b.value);d.hide();f.show();a.defaultFocus=f}}else {d.hide();f.hide()}k=a.progressBar;if(b.progress||h){k.show();a.updateProgress(0,b.progressText);if(h){k.wait(h===!0?b.waitConfig:h)}}else {k.hide()}l=a.msgButtons;for(e=0;e<4;e++){if(j&Math.pow(2,e)){if(!a.defaultFocus){a.defaultFocus=l[e]}l[e].show();q=!1}else {l[e].hide()}}if(q){a.bottomTb.hide()}else {a.bottomTb.show()}Ext.resumeLayouts(!0)},updateButtonText:function(){var b=this,c=b.buttonText,e=0,a,d;for(a in c){if(c.hasOwnProperty(a)){d=b.msgButtons[a];if(d){if(b.cfg&&b.cfg.buttonText){e=e|Math.pow(2,Ext.Array.indexOf(b.buttonIds,a))}if(d.text!==c[a]){d.setText(c[a])}}}}return e},show:function(b){var a=this,c;b=b||{};if(Ext.Component.layoutSuspendCount){Ext.on({resumelayouts:function(){a.show(b)},single:!0});return a}a.reconfigure(b);if(b.cls){a.addCls(b.cls)}c=a.query('textfield:not([hidden]),textarea:not([hidden]),button:not([hidden])');a.preventFocusOnActivate=!c.length;a.hidden=!0;Ext.window.Window.prototype.show.call(this);return a},onShow:function(){Ext.window.Window.prototype.onShow.apply(this,arguments);this.center()},updateText:function(a){this.msg.setHtml(a)},setIcon:function(e,d,c){var b=this,a=b.iconComponent,f=b.messageIconCls;if(f){a.removeCls(f)}if(e){a.show();if(d||c){a.setSize(d||a.getWidth(),c||a.getHeight())}a.addCls('x-dlg-icon');a.addCls(b.messageIconCls=e)}else {a.removeCls('x-dlg-icon');a.hide()}return b},updateProgress:function(c,b,a){this.progressBar.updateProgress(c,b);if(a){this.updateText(a)}return this},onEsc:function(){if(this.closable!==!1){Ext.window.Window.prototype.onEsc.apply(this,arguments)}},confirm:function(a,b,d,c){if(Ext.isString(a)){a={title:a,icon:this.QUESTION,message:b,buttons:this.YESNO,callback:d,scope:c}}return this.show(a)},prompt:function(a,c,f,d,b,e){if(Ext.isString(a)){a={prompt:!0,title:a,minWidth:this.minPromptWidth,message:c,buttons:this.OKCANCEL,callback:f,scope:d,multiline:b,value:e}}return this.show(a)},wait:function(a,c,b){if(Ext.isString(a)){a={title:c,message:a,closable:!1,wait:!0,modal:!0,minWidth:this.minProgressWidth,waitConfig:b}}return this.show(a)},alert:function(a,b,d,c){if(Ext.isString(a)){a={title:a,message:b,buttons:this.OK,fn:d,scope:c,minWidth:this.minWidth}}return this.show(a)},progress:function(a,c,b){if(Ext.isString(a)){a={title:a,message:c,progress:!0,progressText:b}}return this.show(a)}},1,['messagebox'],['component','box','container','panel','window','messagebox'],{'component':!0,'box':!0,'container':!0,'panel':!0,'window':!0,'messagebox':!0},['widget.messagebox'],0,[Ext.window,'MessageBox'],function(a){Ext.onInternalReady(function(){Ext.MessageBox=Ext.Msg=new a()})});Ext.cmd.derive('Ext.form.Basic',Ext.util.Observable,{alternateClassName:'Ext.form.BasicForm',taskDelay:10,constructor:function(c,d){var a=this,b;a.owner=c;a.fieldMonitors={validitychange:a.checkValidityDelay,enable:a.checkValidityDelay,disable:a.checkValidityDelay,dirtychange:a.checkDirtyDelay,errorchange:a.checkErrorDelay,scope:a};a.checkValidityTask=new Ext.util.DelayedTask(a.checkValidity,a);a.checkDirtyTask=new Ext.util.DelayedTask(a.checkDirty,a);a.checkErrorTask=new Ext.util.DelayedTask(a.checkError,a);a.monitor=new Ext.container.Monitor({selector:'[isFormField]:not([excludeForm])',scope:a,addHandler:a.onFieldAdd,removeHandler:a.onFieldRemove,invalidateHandler:a.onMonitorInvalidate});a.monitor.bind(c);Ext.apply(a,d);if(Ext.isString(a.paramOrder)){a.paramOrder=a.paramOrder.split(/[\s,|]/)}b=a.reader;if(b&&!b.isReader){if(typeof b==='string'){b={type:b}}a.reader=Ext.createByAlias('reader.'+b.type,b)}b=a.errorReader;if(b&&!b.isReader){if(typeof b==='string'){b={type:b}}a.errorReader=Ext.createByAlias('reader.'+b.type,b)}Ext.util.Observable.prototype.constructor.call(this)},initialize:function(){this.initialized=!0;this.onValidityChange(!this.hasInvalidField())},timeout:30,paramsAsHash:!1,waitTitle:'Please Wait...',trackResetOnLoad:!1,wasDirty:!1,destroy:function(){var a=this,b=a.monitor;if(b){b.unbind();a.monitor=null}a.clearListeners();a.checkValidityTask.cancel();a.checkDirtyTask.cancel();a.checkErrorTask.cancel();a.checkValidityTask=a.checkDirtyTask=a.checkErrorTask=null;Ext.util.Observable.prototype.destroy.call(this)},onFieldAdd:function(a){a.on(this.fieldMonitors);this.onMonitorInvalidate()},onFieldRemove:function(a){a.un(this.fieldMonitors);this.onMonitorInvalidate()},onMonitorInvalidate:function(){if(this.initialized){this.checkValidityDelay()}},getFields:function(){return this.monitor.getItems()},getBoundItems:function(){var a=this._boundItems;if(!a||a.getCount()===0){a=this._boundItems=new Ext.util.MixedCollection();a.addAll(this.owner.query('[formBind]'))}return a},hasInvalidField:function(){return !!this.getFields().findBy(function(a){var c=a.preventMark,b;a.preventMark=!0;b=a.isValid();a.preventMark=c;return !b})},isValid:function(){var b=this,a;Ext.suspendLayouts();a=b.getFields().filterBy(function(a){return !a.validate()});Ext.resumeLayouts(!0);return a.length<1},checkValidity:function(){var a=this,b;if(a.destroyed){return}b=!a.hasInvalidField();if(b!==a.wasValid){a.onValidityChange(b);a.fireEvent('validitychange',a,b);a.wasValid=b}},checkValidityDelay:function(){var a=this.taskDelay;if(a){this.checkValidityTask.delay(a)}else {this.checkValidity()}},checkError:function(){this.fireEvent('errorchange',this)},checkErrorDelay:function(){var a=this.taskDelay;if(a){this.checkErrorTask.delay(a)}else {this.checkError()}},onValidityChange:function(e){var d=this.getBoundItems(),b,a,f,c;if(d){b=d.items;f=b.length;for(a=0;a',' {$}="{.}"','',' role="presentation"','','>','{%this.renderContainer(out,values)%}',''],initComponent:function(){var a=this;a.initLabelable();a.initFieldAncestor();Ext.container.Container.prototype.initComponent.call(this);a.initMonitor()},onAdd:function(b){var a=this;if(b.isLabelable&&Ext.isGecko&&Ext.firefoxVersion<37&&a.layout.type==='absolute'&&!a.hideLabel&&a.labelAlign!=='top'){b.x+=a.labelWidth+a.labelPad}Ext.container.Container.prototype.onAdd.apply(this,arguments);if(b.isLabelable&&a.combineLabels){b.oldHideLabel=b.hideLabel;b.hideLabel=!0}a.updateLabel()},onRemove:function(a,c){var b=this;Ext.container.Container.prototype.onRemove.apply(this,arguments);if(!c){if(a.isLabelable&&b.combineLabels){a.hideLabel=a.oldHideLabel}b.updateLabel()}},initRenderData:function(){var b=this,a=Ext.container.Container.prototype.initRenderData.call(this);a.containerElCls=b.containerElCls;a=Ext.applyIf(a,b.getLabelableRenderData());a.tipAnchorTarget=b.id+'-containerEl';return a},getFieldLabel:function(){var a=this.fieldLabel||'';if(!a&&this.combineLabels){a=Ext.Array.map(this.query('[isFieldLabelable]'),function(a){return a.getFieldLabel()}).join(this.labelConnector)}return a},getSubTplData:function(){var a=this.initRenderData();Ext.apply(a,this.subTplData);return a},getSubTplMarkup:function(d){var b=this,a=b.getTpl('fieldSubTpl'),c;if(!a.renderContent){b.setupRenderTpl(a)}c=a.apply(b.getSubTplData(d));return c},updateLabel:function(){var a=this,b=a.labelEl;if(b){a.setFieldLabel(a.getFieldLabel())}},onFieldErrorChange:function(){if(this.combineErrors){var a=this,d=a.getActiveError(),c=Ext.Array.filter(a.query('[isFormField]'),function(a){return a.hasActiveError()}),b=a.getCombinedErrors(c);if(b){a.setActiveErrors(b)}else {a.unsetActiveError()}if(d!==a.getActiveError()){a.updateLayout()}}},getCombinedErrors:function(f){var g=[],b,j=f.length,d,c,a,i,h,e;for(b=0;b','','{beforeBoxLabelTpl}','','{afterBoxLabelTpl}','',' tabindex="{tabIdx}"',' disabled="disabled"',' style="{fieldStyle}"',' class="{checkboxCls} {clipCls}" autocomplete="off" hidefocus="true" ',' {$}="{.}"','/>','','','{beforeBoxLabelTpl}','','{afterBoxLabelTpl}','','',{disableFormats:!0,compiled:!0}],publishes:{checked:1},subTplInsertions:['beforeBoxLabelTpl','afterBoxLabelTpl','beforeBoxLabelTextTpl','afterBoxLabelTextTpl','boxLabelAttrTpl','inputAttrTpl'],isCheckbox:!0,focusCls:'form-checkbox-focus',fieldBodyCls:'x-form-cb-wrap',checked:!1,checkedCls:'x-form-cb-checked',boxLabelCls:'x-form-cb-label',boxLabelAlign:'after',afterLabelCls:'x-form-cb-after',wrapInnerCls:'x-form-cb-wrap-inner',noBoxLabelCls:'x-form-cb-no-box-label',inputValue:'on',checkChangeEvents:[],inputType:'checkbox',isTextInput:!1,ariaRole:'checkbox',onRe:/^on$/i,inputCls:'x-form-cb',_checkboxCls:'x-form-cb-input',_clipCls:'x-hidden-clip',initComponent:function(){var a=this,b=a.value;if(b!==undefined){a.checked=a.isChecked(b,a.inputValue)}Ext.form.field.Base.prototype.initComponent.call(this);a.getManager().add(a)},initDefaultName:Ext.emptyFn,initValue:function(){var a=this,b=!!a.checked;a.originalValue=a.lastValue=b;a.setValue(b)},getElConfig:function(){var a=this;if(a.isChecked(a.rawValue,a.inputValue)){a.addCls(a.checkedCls)}return Ext.form.field.Base.prototype.getElConfig.call(this)},getSubTplData:function(g){var a=this,f=a.boxLabel,e=a.boxLabelAlign,d=e==='before',c,b;c=Ext.apply(Ext.form.field.Base.prototype.getSubTplData.call(this,g),{clipCls:a._clipCls,checkboxCls:a._checkboxCls,disabled:a.readOnly||a.disabled,wrapInnerCls:a.wrapInnerCls,boxLabel:f,boxLabelCls:a.boxLabelCls,boxLabelAlign:e,labelAlignedBefore:d,afterLabelCls:d?a.afterLabelCls:'',noBoxLabelCls:!f?a.noBoxLabelCls:'',inputName:a.name||a.id});b=c.inputElAriaAttributes;if(b){b['aria-checked']=!!a.checked;b['aria-labelledby']=a.id+'-boxLabelEl'}return c},initEvents:function(){var a=this;Ext.form.field.Base.prototype.initEvents.call(this);a.inputEl.on({click:'onBoxClick',scope:a,translate:!1});a.displayEl.on({click:'onBoxClick',mousedown:'_onDisplayElMouseDown',scope:a})},setBoxLabel:function(b){var a=this;a.boxLabel=b;if(a.rendered){a.boxLabelEl.setHtml(b);a.boxLabelEl[b?'removeCls':'addCls'](a.noBoxLabelCls);a.updateLayout()}},onBoxClick:function(){var a=this;if(!a.disabled&&!a.readOnly){a.setValue(!a.checked)}},getRawValue:function(){return this.checked},getValue:function(){return this.checked},getSubmitValue:function(){var a=this.uncheckedValue,b=Ext.isDefined(a)?a:null;return this.checked?this.inputValue:b},isChecked:function(a,b){return a===!0||a==='true'||a==='1'||a===1||((Ext.isString(a)||Ext.isNumber(a))&&b?a==b:this.onRe.test(a))},setRawValue:function(e){var a=this,d=a.inputEl,c=a.displayEl,b=a.isChecked(e,a.inputValue);if(d){a[b?'addCls':'removeCls'](a.checkedCls);if(a.ariaRole){a.ariaEl.dom.setAttribute('aria-checked',b)}}if(Ext.isIE8&&c&&b!==a.lastValue){c.repaint()}a.checked=a.rawValue=b;if(!a.duringSetValue){a.lastValue=b}return b},setValue:function(e){var a=this,c,b,f,d;if(Ext.isArray(e)){c=a.getManager().getByName(a.name,a.getFormId()).items;f=c.length;for(b=0;b style="{bodyStyle}">','{%this.renderContainer(out,values);%}',''],stateEvents:['collapse','expand'],maskOnDisable:!1,beforeDestroy:function(){var b=this,a=b.legend;if(a){delete a.ownerCt;a.destroy();b.legend=null}Ext.container.Container.prototype.beforeDestroy.call(this)},initComponent:function(){var a=this,b=a.baseCls;if(a.ariaRole&&!a.ariaLabel){a.ariaLabel=Ext.String.formatEncode(a.descriptionText,a.title||'')}a.ariaRenderAttributes=a.ariaRenderAttributes||{};a.ariaRenderAttributes['aria-expanded']=!a.collapsed;a.initFieldAncestor();Ext.container.Container.prototype.initComponent.call(this);a.layout.managePadding=a.layout.manageOverflow=!1;if(a.collapsed){a.addCls(b+'-collapsed');a.collapse()}if(a.title||a.checkboxToggle||a.collapsible){a.addTitleClasses();a.legend=a.createLegendCt()}a.initMonitor()},initRenderData:function(){var b=this,a=Ext.container.Container.prototype.initRenderData.call(this);a.bodyTargetCls=b.bodyTargetCls;b.protoBody.writeTo(a);delete b.protoBody;return a},getState:function(){var a=Ext.container.Container.prototype.getState.call(this);a=this.addPropertyToState(a,'collapsed');return a},afterCollapse:Ext.emptyFn,afterExpand:Ext.emptyFn,collapsedHorizontal:function(){return !0},collapsedVertical:function(){return !0},createLegendCt:function(){var a=this,c=[],d={baseCls:a.baseCls+'-header',layout:'container',ui:a.ui,id:a.id+'-legend',autoEl:'legend',ariaRole:null,items:c,ownerCt:a,shrinkWrap:!0,ownerLayout:a.componentLayout},b;if(a.checkboxToggle){c.push(a.createCheckboxCmp())}else {if(a.collapsible){c.push(a.createToggleCmp())}}c.push(a.createTitleCmp());b=new Ext.container.Container(d);b.collapseImmune=!0;b.getInherited().collapseImmune=!0;return b},createTitleCmp:function(){var a=this,b={html:a.title,ui:a.ui,cls:a.baseCls+'-header-text',id:a.id+'-legendTitle',ariaRole:'presentation'};if(a.collapsible&&a.toggleOnTitleClick){b.listeners={click:{element:'el',scope:a,fn:a.toggle}};b.cls+=' '+a.baseCls+'-header-text-collapsible'}a.titleCmp=new Ext.Component(b);return a.titleCmp},createCheckboxCmp:function(){var a=this,d='-checkbox',b=a.baseCls+'-header'+d,c;b+=' '+b+'-'+a.ui;a.checkboxCmp=c=new Ext.form.field.Checkbox({hideEmptyLabel:!0,name:a.checkboxName||a.id+d,cls:b,id:a.id+'-legendChk',ui:a.checkboxUI,checked:!a.collapsed,msgTarget:'none',listeners:{change:a.onCheckChange,scope:a},ariaLabel:a.expandText});return c},createToggleCmp:function(){var a=this,b;a.toggleCmp=b=new Ext.panel.Tool({cacheHeight:!1,cls:a.baseCls+'-header-tool-'+a.ui,type:'toggle',handler:a.toggle,id:a.id+'-legendToggle',scope:a,ariaRole:'checkbox',ariaLabel:a.expandText,ariaRenderAttributes:{'aria-checked':!a.collapsed}});return b},doRenderLegend:function(d,c){var e=c.$comp,a=e.legend,b;if(a){a.ownerLayout.configureItem(a);b=a.getRenderTree();Ext.DomHelper.generateMarkup(b,d)}},getCollapsed:function(){return this.collapsed?'top':!1},getCollapsedDockedItems:function(){var a=this.legend;return a?[a]:[]},setTitle:function(c){var a=this,b=a.legend;a.title=c;a.ariaLabel=Ext.String.formatEncode(a.descriptionText,c||'');if(a.rendered){if(!b){a.legend=b=a.createLegendCt();a.addTitleClasses();b.ownerLayout.configureItem(b);b.render(a.el,0)}a.titleCmp.update(c);a.ariaEl.dom.setAttribute('aria-label',a.ariaLabel)}else {if(b){a.titleCmp.update(c)}else {a.addTitleClasses();a.legend=a.createLegendCt()}}return a},addTitleClasses:function(){var a=this,c=a.title,b=a.baseCls;if(c){a.addCls(b+'-with-title')}if(c||a.checkboxToggle||a.collapsible){a.addCls(b+'-with-legend')}},expand:function(){return this.setExpanded(!0)},collapse:function(){return this.setExpanded(!1)},setExpanded:function(b){var a=this,d=a.checkboxCmp,c=a.toggleCmp,e=b?'expand':'collapse';if(!a.rendered||a.fireEvent('before'+e,a)!==!1){b=!!b;if(d){d.setValue(b)}else {if(c&&c.ariaEl.dom){c.ariaEl.dom.setAttribute('aria-checked',b)}}if(b){a.removeCls(a.baseCls+'-collapsed')}else {a.addCls(a.baseCls+'-collapsed')}if(a.ariaEl.dom){a.ariaEl.dom.setAttribute('aria-expanded',!!b)}a.collapsed=!b;if(b){delete a.getInherited().collapsed}else {a.getInherited().collapsed=!0}if(a.rendered){a.updateLayout({isRoot:!1});a.fireEvent(e,a)}}return a},getRefItems:function(c){var a=Ext.container.Container.prototype.getRefItems.apply(this,arguments),b=this.legend;if(b){a.unshift(b);if(c){a.unshift.apply(a,b.getRefItems(!0))}}return a},toggle:function(){this.setExpanded(!!this.collapsed)},privates:{applyTargetCls:function(a){this.bodyTargetCls=a},finishRender:function(){var a=this.legend;Ext.container.Container.prototype.finishRender.call(this);if(a){a.finishRender()}},getProtoBody:function(){var b=this,a=b.protoBody;if(!a){b.protoBody=a=new Ext.util.ProtoElement({styleProp:'bodyStyle',styleIsText:!0})}return a},getDefaultContentTarget:function(){return this.body},getTargetEl:function(){return this.body||this.frameBody||this.el},initPadding:function(d){var b=this,e=b.getProtoBody(),a=b.padding,c;if(a!==undefined){if(Ext.isIE8){a=b.parseBox(a);c=Ext.Element.parseBox(0);c.top=a.top;a.top=0;e.setStyle('padding',b.unitizeBox(c))}d.setStyle('padding',b.unitizeBox(a))}},onCheckChange:function(b,a){this.setExpanded(a)},setupRenderTpl:function(a){Ext.container.Container.prototype.setupRenderTpl.apply(this,arguments);a.renderLegend=this.doRenderLegend}}},0,['fieldset'],['component','box','container','fieldset'],{'component':!0,'box':!0,'container':!0,'fieldset':!0},['widget.fieldset'],[['fieldAncestor',Ext.form.FieldAncestor]],[Ext.form,'FieldSet'],0);Ext.cmd.derive('Ext.form.Label',Ext.Component,{autoEl:'label',maskOnDisable:!1,getElConfig:function(){var a=this;a.html=a.text?Ext.util.Format.htmlEncode(a.text):a.html||'';return Ext.apply(Ext.Component.prototype.getElConfig.call(this),{htmlFor:a.forId||''})},setText:function(c,b){var a=this;b=b!==!1;if(b){a.text=c;delete a.html}else {a.html=c;delete a.text}if(a.rendered){a.el.dom.innerHTML=b!==!1?Ext.util.Format.htmlEncode(c):c;a.updateLayout()}return a}},0,['label'],['component','box','label'],{'component':!0,'box':!0,'label':!0},['widget.label'],0,[Ext.form,'Label'],0);Ext.cmd.derive('Ext.form.Panel',Ext.panel.Panel,{alternateClassName:['Ext.FormPanel','Ext.form.FormPanel'],layout:'anchor',bodyAriaRole:'form',basicFormConfigs:['api','baseParams','errorReader','jsonSubmit','method','paramOrder','paramsAsHash','reader','standardSubmit','timeout','trackResetOnLoad','url','waitMsgTarget','waitTitle'],initComponent:function(){var a=this;if(a.frame){a.border=!1}a.initFieldAncestor();Ext.panel.Panel.prototype.initComponent.call(this);a.relayEvents(a.form,['beforeaction','actionfailed','actioncomplete','validitychange','dirtychange']);if(a.pollForChanges){a.startPolling(a.pollInterval||500)}},initItems:function(){Ext.panel.Panel.prototype.initItems.call(this);this.initMonitor();this.form=this.createForm()},afterFirstLayout:function(){Ext.panel.Panel.prototype.afterFirstLayout.apply(this,arguments);this.form.initialize()},createForm:function(){var d={},c=this.basicFormConfigs,e=c.length,b=0,a;for(;b150){delete a.lastDownArrow}if(!a.isExpanded){b.stopEvent();a.onTriggerClick();a.lastDownArrow=b.time}else {if(!b.isStopped&&b.time-a.lastDownArrow<150){delete a.lastDownArrow}}},expand:function(){var a=this,d,c,b,e;if(a.rendered&&!a.isExpanded&&!a.destroyed){d=a.bodyEl;b=a.getPicker();e=Ext.getDoc();b.setMaxHeight(b.initialConfig.maxHeight);if(a.matchFieldWidth){b.setWidth(a.bodyEl.getWidth())}b.show();a.isExpanded=!0;a.alignPicker();d.addCls(a.openCls);if(a.ariaRole){c=a.ariaEl.dom;c.setAttribute('aria-owns',b.listEl?b.listEl.id:b.el.id);c.setAttribute('aria-expanded',!0)}a.touchListeners=e.on({translate:!1,touchstart:a.collapseIf,scope:a,delegated:!1,destroyable:!0});a.scrollListeners=Ext.on({scroll:a.onGlobalScroll,scope:a,destroyable:!0});Ext.on('resize',a.alignPicker,a,{buffer:1});a.fireEvent('expand',a);a.onExpand()}},onExpand:Ext.emptyFn,alignPicker:function(){if(!this.destroyed){var a=this.getPicker();if(a.isVisible()&&a.isFloating()){this.doAlign()}}},doAlign:function(){var a=this,c=a.picker,d='-above',b;a.picker.alignTo(a.triggerWrap,a.pickerAlign,a.pickerOffset);b=c.el.getY()=g){a.deselectRange(j,g-1)}else {if(h!==c){a.selectRange(h,c,f)}}}a.lastSelected=c}else {if(e){if(!f){a.doSelect(c,!1)}}else {a.selectWithEvent(c,b)}}}};break;case 'SIMPLE':if(e===b.A&&f){a.selected.beginUpdate();a.selectRange(0,a.store.getCount()-1);a.selected.endUpdate()}else {if(k){a.doDeselect(c)}else {a.doSelect(c,!0)}};break;case 'SINGLE':if(!f){if(i){a.doSelect(c,!1)}else {if(m||!e){a.selectWithEvent(c,b)}}};}if(!b.shiftKey&&!a.destroyed&&a.isSelected(c)){a.selectionStart=c;a.selectionStartIdx=g}},selectRange:function(d,f,m){var b=this,i=b.store,l=b.selected.items,h,a,g,e,c,j,k;if(b.isLocked()){return}h=b.normalizeRowRange(d,f);d=h[0];f=h[1];e=[];for(a=d;a<=f;a++){if(!b.isSelected(i.getAt(a))){e.push(i.getAt(a))}}if(!m){c=[];b.suspendChanges();for(a=0,g=l.length;af){c.push(k)}}for(a=0,g=c.length;a0)}}}},deselectRange:function(d,e){var a=this,h=a.store,g,c,b,f;if(a.isLocked()){return}g=a.normalizeRowRange(d,e);d=g[0];e=g[1];b=[];for(c=d;c<=e;c++){f=h.getAt(c);if(a.isSelected(f)){b.push(f)}}if(b.length){a.doDeselect(b)}},normalizeRowRange:function(a,b){var c=this.store,d;if(!Ext.isNumber(a)){a=c.indexOf(a)}a=Math.max(0,a);if(!Ext.isNumber(b)){b=c.indexOf(b)}b=Math.min(b,c.getCount()-1);if(a>b){d=b;b=a;a=d}return [a,b]},select:function(a,c,b){if(Ext.isDefined(a)&&!(Ext.isArray(a)&&!a.length)){this.doSelect(a,c,b)}},deselect:function(b,a){this.doDeselect(b,a)},doSelect:function(a,e,d){var b=this,c;if(b.locked||a==null){return}if(typeof a==='number'){c=b.store.getAt(a);if(!c){return}a=[c]}if(b.selectionMode==='SINGLE'){if(a.isModel){a=[a]}if(a.length){b.doSingleSelect(a[0],d)}}else {b.doMultiSelect(a,e,d)}},doMultiSelect:function(b,k,d){var a=this,g=a.selected,h=!1,e,f,j,c,i;if(a.locked){return}b=!Ext.isArray(b)?[b]:b;j=b.length;if(!k&&g.getCount()>0){e=a.deselectDuringSelect(b,d);if(a.destroyed){return}if(e[0]){a.maybeFireSelectionChange(e[1]>0&&!d);return}else {h=e[1]>0}}i=function(){if(!g.getCount()){a.selectionStart=c}g.add(c);h=!0};for(f=0;f0&&!f);return d===g},doSingleSelect:function(b,c){var a=this,e=!1,d=a.selected,f;if(a.locked){return}if(a.isSelected(b)){return}f=function(){if(d.getCount()){a.suspendChanges();var f=a.deselectDuringSelect([b],c);if(a.destroyed){return}a.resumeChanges();if(f[0]){return !1}}a.lastSelected=b;if(!d.getCount()){a.selectionStart=b}d.add(b);e=!0};a.onSelectChange(b,!0,c,f);if(e&&!a.destroyed){a.maybeFireSelectionChange(!c)}},maybeFireSelectionChange:function(b){var a=this;if(b&&!a.suspendChange){a.fireEvent('selectionchange',a,a.getSelection())}},getLastSelected:function(){return this.lastSelected},getSelection:function(){return this.selected.getRange()},getSelectionMode:function(){return this.selectionMode},setSelectionMode:function(a){a=a?a.toUpperCase():'SINGLE';this.selectionMode=this.modes[a]?a:'SINGLE'},isLocked:function(){return this.locked},setLocked:function(a){this.locked=!!a},isRangeSelected:function(b,c){var e=this,f=e.store,a,d;d=e.normalizeRowRange(b,c);b=d[0];c=d[1];for(a=b;a<=c;a++){if(!e.isSelected(f.getAt(a))){return !1}}return !0},isSelected:function(a){a=Ext.isNumber(a)?this.store.getAt(a):a;return this.selected.contains(a)},hasSelection:function(){var a=this.getSelected();return !!(a&&a.getCount())},refresh:function(){var a=this,l=a.store,e=[],c=[],k=a.getSelection(),m=k.length,b=a.getSelected(),h,j,d,g,i,f;if(!l||!(b.isCollection||b.isRows)||!b.getCount()){return}d=l.getData();if(d.getSource){j=d.getSource();if(j){d=j}}a.refreshing=!0;b.beginUpdate();a.suspendChanges();for(f=0;f0);if(i){a.fireEvent('lastselectedchanged',a,a.getSelection(),a.lastSelected)}},pruneRemovedOnRefresh:function(){return this.pruneRemoved},onStoreLoad:Ext.emptyFn,onSelectChange:function(d,e,b,f){var a=this,c=e?'select':'deselect';if((b||a.fireEvent('before'+c,a,d))!==!1&&f()!==!1){if(!b){a.fireEvent(c,a,d)}}},onEditorKey:Ext.emptyFn,beforeViewRender:function(a){Ext.Array.include(this.views||(this.views=[]),a)},onHeaderClick:Ext.emptyFn,resolveListenerScope:function(a){var c=this.view,b;if(c){b=c.resolveSatelliteListenerScope(this,a)}return b||Ext.mixin.Observable.prototype.resolveListenerScope.call(this,a)},bindComponent:Ext.emptyFn,privates:{onBeforeNavigate:Ext.privateFn,selectWithEventMulti:function(b,l,e){var a=this,g=l.shiftKey,c=l.ctrlKey,j=g?a.getSelectionStart():null,i=a.getSelection(),k=i.length,f,d,h;if(g&&j){a.selectRange(j,b,c)}else {if(c&&e){if(a.allowDeselect){a.doDeselect(b,!1)}}else {if(c){a.doSelect(b,!0,!1)}else {if(e&&!g&&!c&&k>1){if(a.allowDeselect){f=[];for(d=0;dthis.view.all.getCount()-1){a=0}this.setPosition(a,b)},onKeyRight:function(b){var a=this.recordIndex+1;if(a>this.view.all.getCount()-1){a=0}this.setPosition(a,b)},onKeyLeft:function(b){var a=this.recordIndex-1;if(a<0){a=this.view.all.getCount()-1}this.setPosition(a,b)},onKeyPageDown:Ext.emptyFn,onKeyPageUp:Ext.emptyFn,onKeyHome:function(a){this.setPosition(0,a)},onKeyEnd:function(a){this.setPosition(this.view.all.getCount()-1,a)},onKeySpace:function(a){this.fireNavigateEvent(a)},onKeyEnter:function(a){a.stopEvent();a.view.fireEvent('itemclick',a.view,a.record,a.item,a.recordIndex,a)},onSelectAllKeyPress:function(a){this.fireNavigateEvent(a)},fireNavigateEvent:function(b){var a=this;a.fireEvent('navigate',{navigationModel:a,keyEvent:b,previousRecordIndex:a.previousRecordIndex,previousRecord:a.previousRecord,previousItem:a.previousItem,recordIndex:a.recordIndex,record:a.record,item:a.item})},destroy:function(){var a=this;a.setStore(null);Ext.destroy(a.viewListeners,a.keyNav);a.keyNav=a.viewListeners=a.dataSource=a.lastFocused=null;a.callParent()}},1,0,0,0,['view.navigation.default'],[[Ext.util.Observable.prototype.mixinId||Ext.util.Observable.$className,Ext.util.Observable],[Ext.mixin.Factoryable.prototype.mixinId||Ext.mixin.Factoryable.$className,Ext.mixin.Factoryable],[Ext.util.StoreHolder.prototype.mixinId||Ext.util.StoreHolder.$className,Ext.util.StoreHolder]],[Ext.view,'NavigationModel'],0);Ext.cmd.derive('Ext.view.AbstractView',Ext.Component,{inheritableStatics:{getRecord:function(a){return this.getBoundView(a).getRecord(a)},getBoundView:function(a){return Ext.getCmp(a.getAttribute('data-boundView'))}},defaultBindProperty:'store',renderBuffer:document.createElement('div'),statics:{updateDelay:200,queueRecordChange:function(n,o,d,m,f){var a=this,g=a.changeQueue||(a.changeQueue={}),i=d.internalId,h,b,l,e,c,j,k;h=g[i]||(g[i]={operation:m,record:d,data:{},views:[]});b=h.data;Ext.Array.include(h.views,n);if(f&&(l=f.length)){for(e=0;e
{1}
',a.itemCls,b,a.itemAriaRole);a.tpl=new Ext.XTemplate(b,c)}Ext.Component.prototype.initComponent.call(this);a.tpl=a.getTpl('tpl');if(a.overItemCls){a.trackOver=!0}a.addCmpEvents();d=a.store=Ext.data.StoreManager.lookup(a.store||'ext-empty-store');if(!a.dataSource){a.dataSource=d}a.bindStore(d,!0);a.getNavigationModel().bindComponent(this);if(!a.all){a.all=new Ext.CompositeElementLite()}a.scrollState={top:0,left:0};a.savedTabIndexAttribute='data-savedtabindex-'+a.id},getElConfig:function(){var a=this.mixins.renderable.getElConfig.call(this);if(this.focusable){a.tabIndex=0}return a},onRender:function(){var a=this.loadMask;Ext.Component.prototype.onRender.apply(this,arguments);if(a){this.createMask(a)}},beforeLayout:function(){var a=this;Ext.Component.prototype.beforeLayout.apply(this,arguments);if(a.refreshNeeded&&!a.pendingRefresh){if(a.refreshCounter){a.refresh()}else {a.doFirstRefresh(a.dataSource)}}},onMaskBeforeShow:function(){var a=this,b=a.loadingHeight;if(b&&b>a.getHeight()){a.hasLoadingHeight=!0;a.oldMinHeight=a.minHeight;a.minHeight=b;a.updateLayout()}},onMaskHide:function(){var a=this;if(!a.destroying&&a.hasLoadingHeight){a.minHeight=a.oldMinHeight;a.updateLayout();delete a.hasLoadingHeight}},beforeRender:function(){Ext.Component.prototype.beforeRender.apply(this,arguments);this.getSelectionModel().beforeViewRender(this)},afterRender:function(){Ext.Component.prototype.afterRender.apply(this,arguments);if(this.focusable){this.focusEl=this.el}},getRefItems:function(){var a=this.loadMask,b=[];if(a&&a.isComponent){b.push(a)}return b},getSelection:function(){return this.getSelectionModel().getSelection()},updateSelection:function(c){var a=this,b;if(!a.ignoreNextSelection){a.ignoreNextSelection=!0;b=a.getSelectionModel();if(c){b.select(c)}else {b.deselectAll()}a.ignoreNextSelection=!1}},updateBindSelection:function(d,c){var a=this,b=null;if(!a.ignoreNextSelection){a.ignoreNextSelection=!0;if(c.length){b=d.getLastSelected();a.hasHadSelection=!0}if(a.hasHadSelection){a.setSelection(b)}a.ignoreNextSelection=!1}},applySelectionModel:function(b,e){var a=this,g=a.grid,c,f,d;if(e){e.un({scope:a,selectionchange:a.updateBindSelection,lastselectedchanged:a.updateBindSelection,select:a.ariaSelect,deselect:a.ariaDeselect});Ext.destroy(a.selModelRelayer);b=Ext.Factory.selection(b)}else {if(b&&b.isSelectionModel){b.locked=a.disableSelection}else {if(a.simpleSelect){c='SIMPLE'}else {if(a.multiSelect){c='MULTI'}else {c='SINGLE'}}if(typeof b==='string'){b={type:b}}b=Ext.Factory.selection(Ext.apply({allowDeselect:a.allowDeselect||a.multiSelect,mode:c,locked:a.disableSelection},b))}}if(b.mode!=='SINGLE'){d=(g||a).ariaEl.dom;if(d){d.setAttribute('aria-multiselectable',!0)}else {if(!g){f=a.ariaRenderAttributes||(a.ariaRenderAttributes={});f['aria-multiselectable']=!0}}}a.selModelRelayer=a.relayEvents(b,['selectionchange','beforeselect','beforedeselect','select','deselect','focuschange']);b.on({scope:a,lastselectedchanged:a.updateBindSelection,selectionchange:a.updateBindSelection,select:a.ariaSelect,deselect:a.ariaDeselect});return b},updateSelectionModel:function(a){this.selModel=a},applyNavigationModel:function(a){return Ext.Factory.viewNavigation(a)},onFocusEnter:function(d){var a=this,b=a.getNavigationModel(),c;a.toggleChildrenTabbability(!1);if(!a.itemFocused&&a.all.getCount()){c=b.getLastFocused();b.setPosition(c||0,d.event,null,!c);a.itemFocused=b.getPosition()!=null}if(a.itemFocused){this.el.dom.setAttribute('tabIndex','-1')}Ext.Component.prototype.onFocusEnter.call(this,d)},onFocusLeave:function(b){var a=this;if(a.itemFocused&&!a.refreshing){a.getNavigationModel().setPosition(null,b.event,null,!0);a.itemFocused=!1;a.el.dom.setAttribute('tabIndex',0)}Ext.Component.prototype.onFocusLeave.call(this,b)},ariaSelect:function(c,b){var a=this.getNode(b);if(a){a.setAttribute('aria-selected',!0)}},ariaDeselect:function(c,b){var a=this.getNode(b);if(a){a.removeAttribute('aria-selected')}},onRemoved:function(a){Ext.Component.prototype.onRemoved.call(this,a);if(!a){this.onFocusLeave({})}},refresh:function(){var a=this,c=a.all,i=c.getCount(),g=a.refreshCounter,e,k,f,j=a.getSelectionModel(),h,d=g&&c.getCount()&&a.preserveScrollOnRefresh&&a.getScrollable(),b;if(!a.rendered||a.destroyed){return}if(!a.hasListeners.beforerefresh||a.fireEvent('beforerefresh',a)!==!1){a.refreshing=!0;h=a.saveFocusState();e=a.getTargetEl();f=a.getViewRange();k=e.dom;if(d){b=d.getPosition();if(!(b.x||b.y)){b=null}}if(g){a.clearViewEl();a.refreshCounter++}else {a.refreshCounter=1}a.tpl.append(e,a.collectData(f,c.startIndex||0));if(f.length<1){a.addEmptyText();c.clear()}else {a.collectNodes(e.dom);a.updateIndexes(0)}h();if(a.refreshSelmodelOnRefresh!==!1){j.refresh()}a.refreshNeeded=!1;a.refreshSize(c.getCount()!==i);a.fireEvent('refresh',a,f);if(d){d.scrollTo(b)}if(!a.viewReady){a.viewReady=!0;a.fireEvent('viewready',a)}a.refreshing=!1;a.refreshScroll();a.cleanupData()}},addEmptyText:function(){var a=this,b=a.getStore();if(a.emptyText&&!b.isLoading()&&(!a.deferEmptyText||a.refreshCounter>1||b.isLoaded())){a.emptyEl=Ext.core.DomHelper.insertHtml('beforeEnd',a.getTargetEl().dom,a.emptyText)}},getViewRange:function(){return this.dataSource.getRange()},refreshSize:function(d){var a=this,b=a.getSizeModel(),c=a.getScrollable();if(b.height.shrinkWrap||b.width.shrinkWrap||d){a.updateLayout()}else {if(a.touchScroll&&!a.bufferedRenderer){if(c){c.refresh()}else {a.on({boxready:a.refreshScroll,scope:a,single:!0})}}}},afterFirstLayout:function(d,c){var a=this,b=a.getScrollable();if(b){b.on({scroll:a.onViewScroll,scrollend:a.onViewScrollEnd,scope:a,onFrame:!!Ext.global.requestAnimationFrame})}Ext.Component.prototype.afterFirstLayout.call(this,d,c)},clearViewEl:function(){var a=this,c=a.getTargetEl(),b=a.getNodeContainer()===c;a.clearEmptyEl();a.all.clear(!b);if(b){c.dom.innerHTML=''}},clearEmptyEl:function(){var a=this.emptyEl;if(a){Ext.removeNode(a)}this.emptyEl=null},onViewScroll:function(c,a,b){this.fireEvent('scroll',this,a,b)},onViewScrollEnd:function(c,a,b){this.fireEvent('scrollend',this,a,b)},saveScrollState:function(){var a=this,b=a.scrollState;if(a.rendered){b.left=a.getScrollX();b.top=a.getScrollY()}},restoreScrollState:function(){var a=this,b=a.scrollState;if(a.rendered){a.setScrollX(b.left);a.setScrollY(b.top)}},prepareData:function(c,f,e){var a,b,d;if(e){a=e.getAssociatedData();for(b in a){if(a.hasOwnProperty(b)){if(!d){c=Ext.Object.chain(c);d=!0}c[b]=a[b]}}}return c},collectData:function(c,e){var d=[],a=0,f=c.length,b;for(;a-1){if(a.getNode(b)){d=a.bufferRender([b],c).children[0];a.all.replaceElement(c,d,!0);a.updateIndexes(c,c);e.onUpdate(b);a.refreshSizePending=!0;if(e.isSelected(b)){a.onItemSelect(b)}if(a.hasListeners.itemupdate){a.fireEvent('itemupdate',b,c,d)}return d}}}},onReplace:function(o,b,e,d){var a=this,c=a.all,n=a.getSelectionModel(),j=b,h,m,g,f,l,k,i;if(a.rendered){h=a.bufferRender(d,b,!0);g=h.fragment;f=h.children;m=c.item(b);if(m){c.item(b).insertSibling(g,'before',!0)}else {a.appendNodes(g)}c.insert(b,f);if(e.length){i=a.saveFocusState()}b+=d.length;k=b+e.length-1;l=c.removeRange(b,k,!0);if(a.refreshSelmodelOnRefresh!==!1){n.refresh()}a.updateIndexes(b);if(a.hasListeners.itemremove){a.fireEvent('itemremove',e,j,l,a)}if(a.hasListeners.itemadd){a.fireEvent('itemadd',d,j,f)}i();a.refreshSize()}},onAdd:function(f,d,b){var a=this,c,e=a.getSelectionModel();if(a.rendered){if(a.all.getCount()===0){a.refresh();c=a.all.slice()}else {c=a.doAdd(d,b);if(a.refreshSelmodelOnRefresh!==!1){e.refresh()}a.updateIndexes(b);a.refreshSizePending=!0}if(a.hasListeners.itemadd){a.fireEvent('itemadd',d,b,c)}}},appendNodes:function(a){var b=this.all,c=b.getCount();if(this.nodeContainerSelector){this.getNodeContainer().appendChild(a)}else {b.item(c-1).insertSibling(a,'after')}},doAdd:function(j,b){var d=this,g=d.bufferRender(j,b,!0),f=g.fragment,c=g.children,a=d.all,h=a.getCount(),e=a.startIndex||0,i=a.endIndex||h-1;if(h===0||b>i){d.appendNodes(f)}else {if(b<=e){a.item(e).insertSibling(f,'before',!0)}else {a.item(b).insertSibling(c,'before',!0)}}a.insert(b,c);return c},onRemove:function(l,d,b){var a=this,i=a.all,g=a.hasListeners.itemremove,e,c,k,f,h,j;if(i.getCount()){if(a.dataSource.getCount()===0){if(g){a.fireEvent('itemremove',d,b,a.getNodes(b,b+d.length-1))}a.refresh()}else {j=a.saveFocusState();if(g){f=[]}for(c=d.length-1;c>=0;--c){k=d[c];e=b+c;if(f){h=i.item(e);f[c]=h?h.dom:undefined}if(i.item(e)){a.doRemove(k,e)}}if(g){a.fireEvent('itemremove',d,b,f,a)}j();a.updateIndexes(b)}a.refreshSizePending=!0}},doRemove:function(b,a){this.all.removeElement(a,!0)},saveFocusState:function(){var a=this,e=a.dataSource||a.store,c=a.getNavigationModel(),b=c.recordIndex,d=c.record;if(a.el.contains(Ext.Element.getActiveElement())){a.el.dom.focus();return function(){if(e.getCount()){b=Math.min(b,a.all.getCount()-1);c.setPosition(e.contains(d)?d:b,null,null,!0)}}}return Ext.emptyFn},refreshNode:function(a){if(Ext.isNumber(a)){a=this.store.getAt(a)}this.onUpdate(this.dataSource,a)},updateIndexes:function(d,b){var e=this.all.elements,c,f=this.getViewRange(),a,g=this.id;d=d||0;b=b||(b===0?0:e.length-1);for(a=d;a<=b;a++){c=e[a];c.setAttribute('data-recordIndex',a);c.setAttribute('data-recordId',f[a].internalId);c.setAttribute('data-boundView',g)}},bindStore:function(b,e){var a=this,c=a.getSelectionModel(),d=a.getNavigationModel();c.bindStore(b);c.bindComponent(b?a:null);a.mixins.storeholder.bindStore.apply(a,arguments);d.setStore(b);if(b&&a.componentLayoutCounter){a.doFirstRefresh(b,!e)}},doFirstRefresh:function(b,c){var a=this;if(a.deferInitialRefresh&&!c){Ext.defer(a.doFirstRefresh,1,a,[b,!0])}else {if(b&&!b.isLoading()){a.refresh()}}},onUnbindStore:function(a){this.setMaskBind(null);if(this.dataSource===a){this.dataSource=null}},onBindStore:function(c,b){var a=this;if(a.store.isBufferedStore){a.store.preserveScrollOnReload=a.preserveScrollOnReload}if(b&&b.isBufferedStore){delete b.preserveScrollOnReload}a.setMaskBind(c);if(!a.dataSource){a.dataSource=c}},setMaskBind:function(b){var a=this.loadMask;if(this.rendered&&a&&b&&!a.bindStore){a=this.createMask()}if(a&&a.bindStore){a.bindStore(b)}},getStoreListeners:function(){var a=this;return {refresh:a.onDataRefresh,replace:a.onReplace,add:a.onAdd,remove:a.onRemove,update:a.onUpdate,clear:a.onDataRefresh,beginupdate:a.onBeginUpdate,endupdate:a.onEndUpdate}},onBeginUpdate:function(){++this.updateSuspendCounter;Ext.suspendLayouts()},onEndUpdate:function(){var a=this;if(a.updateSuspendCounter){--a.updateSuspendCounter}Ext.resumeLayouts(!0);if(a.refreshSizePending){a.refreshSize(!0);a.refreshSizePending=!1}},onDataRefresh:function(b){var a=this,c=a.preserveScrollOnRefresh;if(b.loadCount>a.lastRefreshLoadCount){a.preserveScrollOnRefresh=a.preserveScrollOnReLoad}a.refreshView();a.preserveScrollOnRefresh=c;a.lastRefreshLoadCount=b.loadCount},refreshView:function(){var a=this,b=a.blockRefresh||!a.rendered||a.up('[collapsed],[isCollapsingOrExpanding],[hidden]');if(b){a.refreshNeeded=!0}else {if(a.bufferedRenderer){a.bufferedRenderer.refreshView()}else {a.refresh()}}},findItemByChild:function(a){return Ext.fly(a).findParent(this.getItemSelector(),this.getTargetEl())},findTargetByEvent:function(a){return a.getTarget(this.getItemSelector(),this.getTargetEl())},getSelectedNodes:function(){var c=[],b=this.getSelectionModel().getSelection(),d=b.length,a=0;for(;aa.bottom){d=b.bottom-a.bottom}}if(b.lefta.right){c=b.right-a.right}}if(c||d){g.scrollBy(c,d,!1)}e.set({tabIndex:-1});e.focus()}},privates:{repaintBorder:function(b){var a=this.getNode(b);if(a){a.className=a.className}}}},0,['dataview'],['component','box','dataview'],{'component':!0,'box':!0,'dataview':!0},['widget.dataview'],0,[Ext.view,'View',Ext,'DataView'],0);Ext.cmd.derive('Ext.view.BoundListKeyNav',Ext.view.NavigationModel,{navigateOnSpace:!0,initKeyNav:function(c){var a=this,b=c.pickerField;if(!a.keyNav){Ext.view.NavigationModel.prototype.initKeyNav.call(this,c);a.keyNav.map.addBinding({key:Ext.event.Event.ESC,fn:a.onKeyEsc,scope:a})}if(!b){return}if(!b.rendered){b.on('render',Ext.Function.bind(a.initKeyNav,a,[c],0),a,{single:!0});return}a.fieldKeyNav=new Ext.util.KeyNav({disabled:!0,target:b.inputEl,forceKeyDown:!0,up:a.onKeyUp,down:a.onKeyDown,right:a.onKeyRight,left:a.onKeyLeft,pageDown:a.onKeyPageDown,pageUp:a.onKeyPageUp,home:a.onKeyHome,end:a.onKeyEnd,tab:a.onKeyTab,space:a.onKeySpace,enter:a.onKeyEnter,A:{ctrl:!0,handler:a.onSelectAllKeyPress},priority:1001,scope:a})},processViewEvent:function(b,c,e,d,a){if(a.within(b.listWrap)){return a}if(a.getKey()===a.ESC){if(Ext.fly(a.target).isInputField()){a.target=a.target.parentNode}return a}},enable:function(){this.fieldKeyNav.enable();Ext.view.NavigationModel.prototype.enable.call(this)},disable:function(){this.fieldKeyNav.disable();Ext.view.NavigationModel.prototype.disable.call(this)},onItemMouseDown:function(e,b,d,c,a){Ext.view.NavigationModel.prototype.onItemMouseDown.call(this,e,b,d,c,a);a.preventDefault()},onKeyUp:function(g){var d=this,a=d.view,f=a.all,c=a.highlightedItem,b=c?a.indexOf(c):-1,e=b>0?b-1:f.getCount()-1;d.setPosition(e);g.preventDefault()},onKeyDown:function(g){var d=this,a=d.view,f=a.all,c=a.highlightedItem,b=c?a.indexOf(c):-1,e=b
',destroy:function(){var a=this;if(a.spinnerEl){a.spinnerEl.destroy();a.spinnerEl=a.upEl=a.downEl=null}Ext.form.trigger.Trigger.prototype.destroy.call(this)},getBodyRenderData:function(){var a=this;return {vertical:a.vertical,upDisabledCls:a.upEnabled?'':a.spinnerUpCls+'-disabled',downDisabledCls:a.downEnabled?'':a.spinnerDownCls+'-disabled',spinnerCls:a.spinnerCls,spinnerUpCls:a.spinnerUpCls,spinnerDownCls:a.spinnerDownCls}},getStateEl:function(){return this.spinnerEl},onClick:function(){var a=this,d=arguments,c=a.clickRepeater?d[1]:d[0],b=a.field;if(!b.readOnly&&!b.disabled){if(a.upEl.contains(c.target)){Ext.callback(a.upHandler,a.scope,[b,a,c],0,b)}else {if(a.downEl.contains(c.target)){Ext.callback(a.downHandler,a.scope,[b,a,c],0,b)}}}b.inputEl.focus()},onFieldRender:function(){var a=this,d=a.vertical,c,b;Ext.form.trigger.Trigger.prototype.onFieldRender.call(this);c=a.spinnerEl=a.el.select('.'+a.spinnerCls,!0);b=c.elements;a.upEl=d?b[0]:b[1];a.downEl=d?b[1]:b[0]},setUpEnabled:function(a){this.upEl[a?'removeCls':'addCls'](this.spinnerUpCls+'-disabled')},setDownEnabled:function(a){this.downEl[a?'removeCls':'addCls'](this.spinnerDownCls+'-disabled')}},0,0,0,0,['trigger.spinner'],0,[Ext.form.trigger,'Spinner'],0);Ext.cmd.derive('Ext.form.field.Spinner',Ext.form.field.Text,{alternateClassName:'Ext.form.Spinner',config:{triggers:{spinner:{type:'spinner',upHandler:'onSpinnerUpClick',downHandler:'onSpinnerDownClick',scope:'this'}}},spinUpEnabled:!0,spinDownEnabled:!0,keyNavEnabled:!0,mouseWheelEnabled:!0,repeatTriggerClick:!0,onSpinUp:Ext.emptyFn,onSpinDown:Ext.emptyFn,ariaRole:'spinbutton',applyTriggers:function(b){var c=this,a=b.spinner;a.upEnabled=c.spinUpEnabled;a.downEnabled=c.spinDownEnabled;return Ext.form.field.Text.prototype.applyTriggers.call(this,b)},onRender:function(){var a=this,b=a.getTrigger('spinner');(arguments.callee.$previous||Ext.form.field.Text.prototype.onRender).call(this);if(a.keyNavEnabled){a.spinnerKeyNav=new Ext.util.KeyNav(a.inputEl,{scope:a,up:a.spinUp,down:a.spinDown})}if(a.mouseWheelEnabled){a.mon(a.bodyEl,'mousewheel',a.onMouseWheel,a)}a.spinUpEl=b.upEl;a.spinDownEl=b.downEl},onSpinnerUpClick:function(){this.spinUp()},onSpinnerDownClick:function(){this.spinDown()},spinUp:function(){var a=this;if(a.spinUpEnabled&&!a.disabled){a.fireEvent('spin',a,'up');a.fireEvent('spinup',a);a.onSpinUp()}},spinDown:function(){var a=this;if(a.spinDownEnabled&&!a.disabled){a.fireEvent('spin',a,'down');a.fireEvent('spindown',a);a.onSpinDown()}},setSpinUpEnabled:function(b){var a=this,c=a.spinUpEnabled;a.spinUpEnabled=b;if(c!==b&&a.rendered){a.getTrigger('spinner').setUpEnabled(b)}},setSpinDownEnabled:function(b){var a=this,c=a.spinDownEnabled;a.spinDownEnabled=b;if(c!==b&&a.rendered){a.getTrigger('spinner').setDownEnabled(b)}},onMouseWheel:function(c){var b=this,a;if(b.hasFocus){a=c.getWheelDelta();if(a>0){b.spinUp()}else {if(a<0){b.spinDown()}}c.stopEvent()}},onDestroy:function(){Ext.destroyMembers(this,'spinnerKeyNav');Ext.form.field.Text.prototype.onDestroy.call(this)}},0,['spinnerfield'],['component','box','field','textfield','spinnerfield'],{'component':!0,'box':!0,'field':!0,'textfield':!0,'spinnerfield':!0},['widget.spinnerfield'],0,[Ext.form.field,'Spinner',Ext.form,'Spinner'],0);Ext.cmd.derive('Ext.form.field.Number',Ext.form.field.Spinner,{alternateClassName:['Ext.form.NumberField','Ext.form.Number'],allowExponential:!0,allowDecimals:!0,decimalSeparator:null,submitLocaleSeparator:!0,decimalPrecision:2,minValue:Number.NEGATIVE_INFINITY,maxValue:Number.MAX_VALUE,step:1,minText:'The minimum value for this field is {0}',maxText:'The maximum value for this field is {0}',nanText:'{0} is not a valid number',negativeText:'The value cannot be negative',baseChars:'0123456789',autoStripChars:!1,initComponent:function(){var a=this;if(a.decimalSeparator===null){a.decimalSeparator=Ext.util.Format.decimalSeparator}Ext.form.field.Spinner.prototype.initComponent.call(this);a.setMinValue(a.minValue);a.setMaxValue(a.maxValue)},getSubTplData:function(g){var f=this,e=f.minValue,d=f.maxValue,c,a,b;c=Ext.form.field.Spinner.prototype.getSubTplData.call(this,g);a=c.inputElAriaAttributes;if(a){if(e>Number.NEGATIVE_INFINITY){a['aria-valuemin']=e}if(d=e&&b<=d){a['aria-valuenow']=b}}return c},setValue:function(d){var a=this,c,b;if(a.hasFocus){c=a.getBind();b=c&&c.value;if(b&&b.syncing&&d===a.value){return a}}return Ext.form.field.Spinner.prototype.setValue.call(this,d)},getErrors:function(b){b=arguments.length>0?b:this.processRawValue(this.getRawValue());var a=this,c=Ext.form.field.Spinner.prototype.getErrors.call(this,b),e=Ext.String.format,d;if(b.length<1){return c}b=String(b).replace(a.decimalSeparator,'.');if(isNaN(b)){c.push(e(a.nanText,b))}d=a.parseValue(b);if(a.minValue===0&&d<0){c.push(this.negativeText)}else {if(da.maxValue){c.push(e(a.maxText,a.maxValue))}return c},rawToValue:function(b){var a=this.fixPrecision(this.parseValue(b));if(a===null){a=b||null}return a},valueToRaw:function(a){var b=this,c=b.decimalSeparator;a=b.parseValue(a);a=b.fixPrecision(a);a=Ext.isNumber(a)?a:parseFloat(String(a).replace(c,'.'));a=isNaN(a)?'':String(a).replace('.',c);return a},getSubmitValue:function(){var b=this,a=Ext.form.field.Spinner.prototype.getSubmitValue.call(this);if(!b.submitLocaleSeparator){a=a.replace(b.decimalSeparator,'.')}return a},onChange:function(a){var b=this.ariaEl.dom;this.toggleSpinners();Ext.form.field.Spinner.prototype.onChange.apply(this,arguments);if(b){if(Ext.isNumber(a)&&isFinite(a)){b.setAttribute('aria-valuenow',a)}else {b.removeAttribute('aria-valuenow')}}},toggleSpinners:function(){var a=this,c=a.getValue(),d=c===null,b;if(a.spinUpEnabled||a.spinUpDisabledByToggle){b=d||ca.minValue;a.setSpinDownEnabled(b,!0)}},setMinValue:function(e){var a=this,c=a.ariaEl.dom,d,b,c;a.minValue=d=Ext.Number.from(e,Number.NEGATIVE_INFINITY);a.toggleSpinners();if(c){if(d>Number.NEGATIVE_INFINITY){c.setAttribute('aria-valuemin',d)}else {c.removeAttribute('aria-valuemin')}}if(a.disableKeyFilter!==!0){b=a.baseChars+'';if(a.allowExponential){b+=a.decimalSeparator+'e+-'}else {if(a.allowDecimals){b+=a.decimalSeparator}if(a.minValue<0){b+='-'}}b=Ext.String.escapeRegex(b);a.maskRe=new RegExp('['+b+']');if(a.autoStripChars){a.stripCharsRe=new RegExp('[^'+b+']','gi')}}},setMaxValue:function(c){var b=this.ariaEl.dom,a;this.maxValue=a=Ext.Number.from(c,Number.MAX_VALUE);if(b){if(aa.maxLength){return}}a.setValue(b)}},0,['numberfield'],['component','box','field','textfield','spinnerfield','numberfield'],{'component':!0,'box':!0,'field':!0,'textfield':!0,'spinnerfield':!0,'numberfield':!0},['widget.numberfield'],0,[Ext.form.field,'Number',Ext.form,'NumberField',Ext.form,'Number'],0);Ext.cmd.derive('Ext.toolbar.Paging',Ext.toolbar.Toolbar,{alternateClassName:'Ext.PagingToolbar',displayInfo:!1,prependButtons:!1,displayMsg:'Displaying {0} - {1} of {2}',emptyMsg:'No data to display',beforePageText:'Page',afterPageText:'of {0}',firstText:'First Page',prevText:'Previous Page',nextText:'Next Page',lastText:'Last Page',refreshText:'Refresh',inputItemWidth:30,emptyPageData:{total:0,currentPage:0,pageCount:0,toRecord:0,fromRecord:0},defaultBindProperty:'store',getPagingItems:function(){var a=this,b={scope:a,blur:a.onPagingBlur};b[Ext.supports.SpecialKeyDownRepeat?'keydown':'keypress']=a.onPagingKeyDown;return [{itemId:'first',tooltip:a.firstText,overflowText:a.firstText,iconCls:'x-tbar-page-first',disabled:!0,handler:a.moveFirst,scope:a},{itemId:'prev',tooltip:a.prevText,overflowText:a.prevText,iconCls:'x-tbar-page-prev',disabled:!0,handler:a.movePrevious,scope:a},'-',a.beforePageText,{xtype:'numberfield',itemId:'inputItem',name:'inputItem',cls:'x-tbar-page-number',allowDecimals:!1,minValue:1,hideTrigger:!0,enableKeyEvents:!0,keyNavEnabled:!1,selectOnFocus:!0,submitValue:!1,isFormField:!1,width:a.inputItemWidth,margin:'-1 2 3 2',listeners:b},{xtype:'tbtext',itemId:'afterTextItem',html:Ext.String.format(a.afterPageText,1)},'-',{itemId:'next',tooltip:a.nextText,overflowText:a.nextText,iconCls:'x-tbar-page-next',disabled:!0,handler:a.moveNext,scope:a},{itemId:'last',tooltip:a.lastText,overflowText:a.lastText,iconCls:'x-tbar-page-last',disabled:!0,handler:a.moveLast,scope:a},'-',{itemId:'refresh',tooltip:a.refreshText,overflowText:a.refreshText,iconCls:'x-tbar-loading',disabled:a.store.isLoading(),handler:a.doRefresh,scope:a}]},initComponent:function(){var a=this,c=a.items||a.buttons||[],b;a.bindStore(a.store||'ext-empty-store',!0);b=a.getPagingItems();if(a.prependButtons){a.items=c.concat(b)}else {a.items=b.concat(c)}delete a.buttons;if(a.displayInfo){a.items.push('->');a.items.push({xtype:'tbtext',itemId:'displayItem'})}Ext.toolbar.Toolbar.prototype.initComponent.call(this)},beforeRender:function(){Ext.toolbar.Toolbar.prototype.beforeRender.apply(this,arguments);this.updateBarInfo()},updateBarInfo:function(){var a=this;if(!a.store.isLoading()){a.calledInternal=!0;a.onLoad();a.calledInternal=!1}},updateInfo:function(){var a=this,d=a.child('#displayItem'),f=a.store,b=a.getPageData(),e,c;if(d){e=f.getCount();if(e===0){c=a.emptyMsg}else {c=Ext.String.format(a.displayMsg,b.fromRecord,b.toRecord,b.total)}d.setText(c)}},onLoad:function(){var a=this,f,c,b,g,h,d,e;h=a.store.getCount();d=h===0;if(!d){f=a.getPageData();c=f.currentPage;b=f.pageCount;if(c>b){if(b>0){a.store.loadPage(b)}else {a.getInputItem().reset()}return}g=Ext.String.format(a.afterPageText,isNaN(b)?1:b)}else {c=0;b=0;g=Ext.String.format(a.afterPageText,0)}Ext.suspendLayouts();e=a.child('#afterTextItem');if(e){e.update(g)}e=a.getInputItem();if(e){e.setDisabled(d).setValue(c)}a.setChildDisabled('#first',c===1||d);a.setChildDisabled('#prev',c===1||d);a.setChildDisabled('#next',c===b||d);a.setChildDisabled('#last',c===b||d);a.setChildDisabled('#refresh',!1);a.updateInfo();Ext.resumeLayouts(!0);if(!a.calledInternal){a.fireEvent('change',a,f||a.emptyPageData)}},setChildDisabled:function(c,b){var a=this.child(c);if(a){a.setDisabled(b)}},getPageData:function(){var a=this.store,b=a.getTotalCount();return {total:b,currentPage:a.currentPage,pageCount:Math.ceil(b/a.pageSize),fromRecord:(a.currentPage-1)*a.pageSize+1,toRecord:Math.min(a.currentPage*a.pageSize,b)}},onLoadError:function(){this.setChildDisabled('#refresh',!1)},getInputItem:function(){return this.child('#inputItem')},readPageFromInput:function(d){var a=this.getInputItem(),b=!1,c;if(a){c=a.getValue();b=parseInt(c,10);if(!c||isNaN(b)){a.setValue(d.currentPage);return !1}}return b},onPagingBlur:function(c){var a=this.getInputItem(),b;if(a){b=this.getPageData().currentPage;a.setValue(b)}},onPagingKeyDown:function(a,b){this.processKeyEvent(a,b)},processKeyEvent:function(g,b){var e=this,c=b.getKey(),d=e.getPageData(),f=b.shiftKey?10:1,a;if(c===b.RETURN){b.stopEvent();a=e.readPageFromInput(d);if(a!==!1){a=Math.min(Math.max(1,a),d.pageCount);if(a!==d.currentPage&&e.fireEvent('beforechange',e,a)!==!1){e.store.loadPage(a)}}}else {if(c===b.HOME||c===b.END){b.stopEvent();a=c===b.HOME?1:d.pageCount;g.setValue(a)}else {if(c===b.UP||c===b.PAGE_UP||c===b.DOWN||c===b.PAGE_DOWN){b.stopEvent();a=e.readPageFromInput(d);if(a){if(c===b.DOWN||c===b.PAGE_DOWN){f*=-1}a+=f;if(a>=1&&a<=d.pageCount){g.setValue(a)}}}}}},beforeLoad:function(){this.setChildDisabled('#refresh',!0)},moveFirst:function(){if(this.fireEvent('beforechange',this,1)!==!1){this.store.loadPage(1);return !0}return !1},movePrevious:function(){var a=this,b=a.store,c=b.currentPage-1;if(c>0){if(a.fireEvent('beforechange',a,c)!==!1){b.previousPage();return !0}}return !1},moveNext:function(){var a=this,b=a.store,d=a.getPageData().pageCount,c=b.currentPage+1;if(c<=d){if(a.fireEvent('beforechange',a,c)!==!1){b.nextPage();return !0}}return !1},moveLast:function(){var a=this,b=a.getPageData().pageCount;if(a.fireEvent('beforechange',a,b)!==!1){a.store.loadPage(b);return !0}return !1},doRefresh:function(){var a=this,c=a.store,b=c.currentPage;if(a.fireEvent('beforechange',a,b)!==!1){c.loadPage(b);return !0}return !1},getStoreListeners:function(){return {beforeload:this.beforeLoad,load:this.onLoad,exception:this.onLoadError}},onBindStore:function(){if(this.rendered){this.updateBarInfo()}},onDestroy:function(){this.bindStore(null);Ext.toolbar.Toolbar.prototype.onDestroy.call(this)}},0,['pagingtoolbar'],['component','box','container','toolbar','pagingtoolbar'],{'component':!0,'box':!0,'container':!0,'toolbar':!0,'pagingtoolbar':!0},['widget.pagingtoolbar'],[[Ext.util.StoreHolder.prototype.mixinId||Ext.util.StoreHolder.$className,Ext.util.StoreHolder]],[Ext.toolbar,'Paging',Ext,'PagingToolbar'],0);Ext.define('Ext.theme.neptune.toolbar.Paging',{override:'Ext.toolbar.Paging',defaultButtonUI:'plain-toolbar',inputItemWidth:40});Ext.cmd.derive('Ext.view.BoundList',Ext.view.View,{alternateClassName:'Ext.BoundList',pageSize:0,baseCls:'x-boundlist',itemCls:'x-boundlist-item',listItemCls:'',shadow:!1,trackOver:!0,preserveScrollOnRefresh:!0,enableInitialSelection:!1,refreshSelmodelOnRefresh:!0,componentLayout:'boundlist',navigationModel:'boundlist',scrollable:!0,ariaEl:'listEl',tabIndex:-1,childEls:['listWrap','listEl'],renderTpl:['
','
    {$}="{.}"','>','
','
','{%','var pagingToolbar=values.$comp.pagingToolbar;','if (pagingToolbar) {','Ext.DomHelper.generateMarkup(pagingToolbar.getRenderTree(), out);','}','%}',{disableFormats:!0}],focusOnToFront:!1,initComponent:function(){var a=this,b=a.baseCls,c=a.itemCls;a.selectedItemCls=b+'-selected';if(a.trackOver){a.overItemCls=b+'-item-over'}a.itemSelector='.'+c;a.scrollerSelector='ul.x-list-plain';if(a.floating){a.addCls(b+'-floating')}if(!a.tpl){a.tpl=new Ext.XTemplate('','
  • '+a.getInnerTpl(a.displayField)+'
  • ','
    ')}else {if(!a.tpl.isTemplate){a.tpl=new Ext.XTemplate(a.tpl)}}if(a.pageSize){a.pagingToolbar=a.createPagingToolbar()}Ext.view.View.prototype.initComponent.call(this)},getRefOwner:function(){return this.pickerField||Ext.view.View.prototype.getRefOwner.call(this)},getRefItems:function(){var b=Ext.view.View.prototype.getRefItems.call(this),a=this.pagingToolbar;if(a){b.push(a)}return b},createPagingToolbar:function(){return Ext.widget('pagingtoolbar',{id:this.id+'-paging-toolbar',pageSize:this.pageSize,store:this.dataSource,border:!1,ownerCt:this,ownerLayout:this.getComponentLayout()})},getNodeContainer:function(){return this.listEl},refresh:function(){var b=this,a=b.tpl;a.field=b.pickerField;a.store=b.store;Ext.view.View.prototype.refresh.call(this);a.field=a.store=null},bindStore:function(c,b){var a=this.pagingToolbar;Ext.view.View.prototype.bindStore.apply(this,arguments);if(a){a.bindStore(c,b)}},getInnerTpl:function(a){return '{'+a+'}'},onShow:function(){var a=this.pickerField;Ext.view.View.prototype.onShow.call(this);if(a&&a.rendered&&!a.hasFocus){a.focus()}},afterComponentLayout:function(e,d,c,b){var a=this.pickerField;Ext.view.View.prototype.afterComponentLayout.call(this,e,d,c,b);if(a&&a.alignPicker){a.alignPicker()}},onItemClick:function(e){var d=this,b=d.pickerField,c,a;if(!b){return}c=b.valueField;a=d.getSelectionModel().getSelection();if(!b.multiSelect&&a.length){a=a[0];if(a&&b.isEqual(e.get(c),a.get(c))&&b.collapse){b.collapse()}}},onContainerClick:function(b){var a=this.pagingToolbar;if(a&&a.rendered&&b.within(a.el)){return !1}},onDestroy:function(){Ext.view.View.prototype.onDestroy.call(this);Ext.destroyMembers(this,'pagingToolbar','listWrap','listEl')},privates:{getTargetEl:function(){return this.listEl},getOverflowEl:function(){return this.listWrap},finishRenderChildren:function(){var a=this.pagingToolbar;Ext.view.View.prototype.finishRenderChildren.apply(this,arguments);if(a){a.finishRender()}}}},0,['boundlist'],['component','box','dataview','boundlist'],{'component':!0,'box':!0,'dataview':!0,'boundlist':!0},['widget.boundlist'],[[Ext.mixin.Queryable.prototype.mixinId||Ext.mixin.Queryable.$className,Ext.mixin.Queryable]],[Ext.view,'BoundList',Ext,'BoundList'],0);Ext.cmd.derive('Ext.form.field.ComboBox',Ext.form.field.Picker,{alternateClassName:'Ext.form.ComboBox',config:{filters:null,selection:null,valueNotFoundText:null,displayTpl:!1,delimiter:', ',displayField:'text'},publishes:['selection'],twoWayBindable:['selection'],triggerCls:'x-form-arrow-trigger',hiddenName:'',collapseOnSelect:!1,hiddenDataCls:'x-hidden-display x-form-data-hidden',ariaRole:'combobox',childEls:{'hiddenDataEl':!0},filtered:!1,afterRender:function(){var a=this;Ext.form.field.Picker.prototype.afterRender.apply(this,arguments);a.setHiddenValue(a.value)},multiSelect:!1,triggerAction:'all',allQuery:'',queryParam:'query',queryMode:'remote',queryCaching:!0,autoLoadOnValue:!1,pageSize:0,anyMatch:!1,caseSensitive:!1,autoSelect:!0,typeAhead:!1,typeAheadDelay:250,selectOnTab:!0,forceSelection:!1,growToLongestValue:!0,clearFilterOnBlur:!0,defaultListConfig:{loadingHeight:70,minWidth:70,maxHeight:300,shadow:'sides'},transformInPlace:!0,clearValueOnEmpty:!0,getGrowWidth:function(){var a=this,i=a.inputEl.dom.value,h,e,g,c,b,f,d;if(a.growToLongestValue){h=a.displayField;e=a.store;g=e.data.length;c=0;for(b=0;bc){c=d;i=f}}}return i},initComponent:function(){var a=this,d=Ext.isDefined,f=a.store,e=a.transform,b,c;if('pinList' in a){a.collapseOnSelect=!a.pinList}if(e){b=Ext.getDom(e);if(b){if(!a.store){f=Ext.Array.map(Ext.Array.from(b.options),function(a){return [a.value,a.text]})}if(!a.name){a.name=b.name}if(!('value' in a)){a.value=b.value}}}a.bindStore(f||'ext-empty-store',!0,!0);c=a.queryMode==='local';if(!d(a.queryDelay)){a.queryDelay=c?10:500}if(!d(a.minChars)){a.minChars=c?0:4}Ext.form.field.Picker.prototype.initComponent.call(this);a.doQueryTask=new Ext.util.DelayedTask(a.doRawQuery,a);if(b){if(a.transformInPlace){a.render(b.parentNode,b);delete a.renderTo}Ext.removeNode(b)}},getSubTplData:function(c){var b,a;b=Ext.form.field.Picker.prototype.getSubTplData.call(this,c);a=b.inputElAriaAttributes;if(a){a['aria-autocomplete']='list'}return b},getSubTplMarkup:function(c){var b=this,a='',d=Ext.form.field.Picker.prototype.getSubTplMarkup.apply(this,arguments);if(b.hiddenName){a=''}return a+d},applyDisplayTpl:function(a){var b=this;if(!a){a=new Ext.XTemplate('{[typeof values === "string" ? values : values["'+b.getDisplayField()+'"]]}'+b.getDelimiter()+'');a.auto=!0}else {if(!a.isTemplate){a=new Ext.XTemplate(a)}}return a},applyFilters:function(b,a){var c=this;if(b===null||b.isFilterCollection){return b}if(b){if(!a){a=this.getFilters()}a.beginUpdate();a.splice(0,a.length,b);a.each(function(d){d.ownerId=c.id});a.endUpdate()}return a},applyValueNotFoundText:function(b){var a=this,c=a.valueNotFoundRecord||(a.valueNotFoundRecord=new Ext.data.Model());c.set(a.displayField,b);if(a.valueField&&a.displayField!==a.valueField){c.set(a.valueField,b)}return b},getFilters:function(b){var a=this.filters;if(!a&&b!==!1){a=new Ext.util.FilterCollection();this.setFilters(a)}return a},updateFilters:function(a,c){var b=this;if(c){c.un('endupdate','onEndUpdateFilters',b)}if(a){a.on('endupdate','onEndUpdateFilters',b)}b.onEndUpdateFilters(a)},onEndUpdateFilters:function(a){var b=this,f=b.filtered,e=!!a&&a.length>0,d,c;if(f||e){b.filtered=e;d=[];c=b.store.getFilters();c.each(function(c){if(c.ownerId===b.id&&!a.contains(c)){d.push(c)}});c.splice(0,d,a.items)}},completeEdit:function(c){var a=this,b=a.queryFilter;Ext.form.field.Picker.prototype.completeEdit.call(this,c);a.doQueryTask.cancel();a.assertValue();if(b&&a.queryMode==='local'&&a.clearFilterOnBlur){a.getStore().getFilters().remove(b)}},onFocus:function(b){var a=this;Ext.form.field.Picker.prototype.onFocus.call(this,b);if(a.triggerAction!=='all'&&a.queryFilter&&a.queryMode==='local'&&a.clearFilterOnBlur){delete a.lastQuery;a.doRawQuery()}},assertValue:function(){var a=this,e=a.getRawValue(),c=a.getDisplayValue(),d=a.lastSelectedRecords,b;if(a.forceSelection){if(a.multiSelect){if(e!==c){a.setRawValue(c)}}else {b=a.findRecordByDisplay(e);if(b){if(a.getDisplayValue([a.getRecordDisplayData(b)])!==c){a.select(b,!0)}}else {if(d&&(!a.allowBlank||a.rawValue)){a.setValue(d)}else {if(d){delete a.lastSelectedRecords}a.setRawValue('')}}}}a.collapse()},onTypeAhead:function(){var a=this,e=a.displayField,d=a.store.findRecord(e,a.getRawValue()),f=a.getPicker(),b,g,c;if(d){b=d.get(e);g=b.length;c=a.getRawValue().length;f.highlightItem(f.getNode(d));if(c!==0&&c!==g){a.setRawValue(b);a.selectText(c,b.length)}}},resetToDefault:Ext.emptyFn,beforeReset:function(){var a=this.queryFilter;Ext.form.field.Picker.prototype.beforeReset.call(this);if(a){this.getStore().getFilters().remove(a)}},onUnbindStore:function(){var a=this,c=a.picker,b=a.queryFilter;if(b&&!a.store.destroyed){a.changingFilters=!0;a.getStore().removeFilter(b,!0);a.changingFilters=!1}a.pickerSelectionModel.destroy();if(c){c.bindStore(null)}},onBindStore:function(b,f){var a=this,d=a.picker,c,e;if(b){if(b.autoCreated){a.queryMode='local';a.valueField=a.displayField='field1';if(!b.expanded){a.displayField='field2'}if(a.getDisplayTpl().auto){a.setDisplayTpl(null)}}if(!Ext.isDefined(a.valueField)){a.valueField=a.displayField}c={byValue:{rootProperty:'data',unique:!1}};c.byValue.property=a.valueField;b.setExtraKeys(c);if(a.displayField===a.valueField){b.byText=b.byValue}else {c.byText={rootProperty:'data',unique:!1};c.byText.property=a.displayField;b.setExtraKeys(c)}e={rootProperty:'data',extraKeys:{byInternalId:{property:'internalId'},byValue:{property:a.valueField,rootProperty:'data'}},listeners:{beginupdate:a.onValueCollectionBeginUpdate,endupdate:a.onValueCollectionEndUpdate,scope:a}};a.valueCollection=new Ext.util.Collection(e);a.pickerSelectionModel=new Ext.selection.DataViewModel({mode:a.multiSelect?'SIMPLE':'SINGLE',deselectOnContainerClick:!1,enableInitialSelection:!1,pruneRemoved:!1,selected:a.valueCollection,store:b,listeners:{scope:a,lastselectedchanged:a.updateBindSelection}});if(!f){a.resetToDefault()}if(d){d.setSelectionModel(a.pickerSelectionModel);if(d.getStore()!==b){d.bindStore(b)}}}},bindStore:function(a,e,c){var b=this,d=b.queryFilter;b.mixins.storeholder.bindStore.call(b,a,c);a=b.getStore();if(a&&d&&!e){a.getFilters().add(d)}if(!c&&a&&!a.isEmptyStore){b.setValueOnData()}},getStoreListeners:function(c){if(!c.isEmptyStore){var a=this,b={datachanged:a.onDataChanged,load:a.onLoad,exception:a.onException,update:a.onStoreUpdate,remove:a.checkValueOnChange};if(!c.getRemoteFilter()){b.filterchange=a.checkValueOnChange}return b}},onDataChanged:function(){if(this.grow&&this.growToLongestValue){this.autoSize()}},checkValueOnChange:function(){var a=this;if(!a.destroying&&a.getStore().isLoaded()){if(a.multiSelect){}else {if(a.forceSelection&&!a.changingFilters&&!a.findRecordByValue(a.value)){a.setValue(null)}}}},onStoreUpdate:function(b,a){this.updateValue()},onException:function(){this.collapse()},onLoad:function(b,e,d){var a=this,c=!a.valueCollection.byValue.get(a.value);if(d&&c&&!(b.lastOptions&&'rawQuery' in b.lastOptions)){a.setValueOnData()}a.checkValueOnChange()},setValueOnData:function(){var a=this;a.setValue(a.value);if(a.isExpanded&&a.getStore().getCount()){a.doAutoSelect()}},doRawQuery:function(){var a=this,b=a.inputEl.dom.value;if(a.multiSelect){b=b.split(a.delimiter).pop()}a.doQuery(b,!1,!0)},doQuery:function(c,f,g){var a=this,d=a.getStore(),e=d.filters&&!d.filters.length&&!!c,b=a.beforeQuery({query:c||'',rawQuery:g,forceAll:f,combo:a,cancel:!1});if(b!==!1&&!b.cancel){if(a.queryCaching&&!e&&b.query===a.lastQuery){a.getPicker().refresh();a.expand()}else {a.lastQuery=b.query;if(a.queryMode==='local'){a.doLocalQuery(b)}else {a.doRemoteQuery(b)}}}return !0},beforeQuery:function(a){var b=this;if(b.fireEvent('beforequery',a)===!1){a.cancel=!0}else {if(!a.cancel){if(a.query.length0){a=b.picker.getSelectionModel();if(a.lastSelected&&a.selected.length){c=a.lastSelected}d.getNavigationModel().setPosition(c)}},doTypeAhead:function(){var a=this,b=Ext.event.Event;if(!a.typeAheadTask){a.typeAheadTask=new Ext.util.DelayedTask(a.onTypeAhead,a)}if(a.lastKey!==b.BACKSPACE&&a.lastKey!==b.DELETE){a.typeAheadTask.delay(a.typeAheadDelay)}},onTriggerClick:function(){var a=this;if(!a.readOnly&&!a.disabled){if(a.isExpanded){a.collapse()}else {if(a.triggerAction==='all'){a.doQuery(a.allQuery,!0)}else {if(a.triggerAction==='last'){a.doQuery(a.lastQuery,!0)}else {a.doQuery(a.getRawValue(),!1,!0)}}}}},onFieldMutation:function(b){var a=this,c=b.getKey(),d=c===b.BACKSPACE||c===b.DELETE,e=a.inputEl.dom.value,f=e.length;if(!a.readOnly&&(e!==a.lastMutatedValue||d)&&c!==b.TAB){a.lastMutatedValue=e;a.lastKey=c;if(f&&(b.type!=='keyup'||(!b.isSpecialKey()||d))){a.doQueryTask.delay(a.queryDelay)}else {if(!f&&(!c||d)){++a.suspendCheckChange;if(!a.multiSelect){a.value=null;a.displayTplData=undefined}if(a.clearValueOnEmpty){a.valueCollection.beginUpdate();a.pickerSelectionModel.deselectAll();a.valueCollection.removeAll();a.valueCollection.endUpdate()}a.collapse();if(a.queryFilter){a.changingFilters=!0;a.store.removeFilter(a.queryFilter,!0);a.changingFilters=!1}--a.suspendCheckChange}Ext.form.field.Picker.prototype.onFieldMutation.call(this,b)}}},onDestroy:function(){var a=this;a.doQueryTask.cancel();if(a.typeAheadTask){a.typeAheadTask.cancel();a.typeAheadTask=null}a.bindStore(null);a.valueCollection=Ext.destroy(a.valueCollection);Ext.form.field.Picker.prototype.onDestroy.call(this)},onAdded:function(){var a=this;Ext.form.field.Picker.prototype.onAdded.apply(this,arguments);if(a.picker){a.picker.ownerCt=a.up('[floating]');a.picker.registerWithOwnerCt()}},createPicker:function(){var a=this,b,c=Ext.apply({xtype:'boundlist',id:a.pickerId,pickerField:a,selectionModel:a.pickerSelectionModel,floating:!0,hidden:!0,store:a.getPickerStore(),displayField:a.displayField,preserveScrollOnRefresh:!0,pageSize:a.pageSize,tpl:a.tpl},a.listConfig,a.defaultListConfig);b=a.picker=Ext.widget(c);if(a.pageSize){b.pagingToolbar.on('beforechange',a.onPageChange,a)}if(!b.initialConfig.maxHeight){b.on({beforeshow:a.onBeforePickerShow,scope:a})}b.getSelectionModel().on({beforeselect:a.onBeforeSelect,beforedeselect:a.onBeforeDeselect,focuschange:a.onFocusChange,scope:a});b.getNavigationModel().navigateOnSpace=!1;return b},getPickerStore:function(){return this.store},onBeforePickerShow:function(d){var b=this,a=b.getPosition()[1]-Ext.getBody().getScroll().top,c=Ext.Element.getViewportHeight()-a-b.getHeight();d.maxHeight=Math.max(a,c)-5},onBeforeSelect:function(c,b,a){return this.fireEvent('beforeselect',this,b,a)},onBeforeDeselect:function(c,b,a){return this.fireEvent('beforedeselect',this,b,a)},onFocusChange:function(e,d,b){var c=this.picker,a;if(b){a=Ext.get(c.getNodeByRecord(b));if(a){this.ariaEl.dom.setAttribute('aria-activedescendant',a.id)}}},getSelection:function(){var a=this.getPicker().getSelectionModel(),b=a.getSelection();return b.length?a.getLastSelected():null},updateSelection:function(c){var a=this,b;if(!a.ignoreNextSelection){a.ignoreNextSelection=!0;b=a.getPicker().getSelectionModel();if(c){b.select(c);a.hasHadSelection=!0}else {b.deselectAll()}a.ignoreNextSelection=!1}},updateBindSelection:function(d,c){var a=this,b=null;if(!a.ignoreNextSelection){a.ignoreNextSelection=!0;if(c.length){b=d.getLastSelected();a.hasHadSelection=!0}if(a.hasHadSelection){a.setSelection(b)}a.ignoreNextSelection=!1}},onValueCollectionBeginUpdate:Ext.emptyFn,onValueCollectionEndUpdate:function(){var a=this,e=a.store,b=a.valueCollection.getRange(),d=b[0],c=b.length;a.updateBindSelection(a.pickerSelectionModel,b);if(a.isSelectionUpdating()){return}Ext.suspendLayouts();a.lastSelection=b;if(c){a.lastSelectedRecords=b}a.updateValue();if(c&&(!a.multiSelect&&e.contains(d)||a.collapseOnSelect||!e.getCount())){a.updatingValue=!0;a.collapse();a.updatingValue=!1}Ext.resumeLayouts(!0);if(c&&!a.suspendCheckChange){if(!a.multiSelect){b=d}a.fireEvent('select',a,b)}},isSelectionUpdating:function(){var a=this.pickerSelectionModel;return a.deselectingDuringSelect||a.refreshing},onExpand:function(){var a=this.getPicker().getNavigationModel();if(a){a.enable()}this.doAutoSelect()},onCollapse:function(){var a=this.getPicker().getNavigationModel();if(a){a.disable()}if(this.updatingValue){this.doQueryTask.cancel()}},select:function(b,e){var a=this,d=a.picker,c;if(b&&b.isModel&&e===!0&&d){c=!d.getSelectionModel().isSelected(b)}if(!c){a.suspendEvent('select')}a.setValue(b);a.resumeEvent('select')},findRecord:function(c,d){var b=this.store,a=b.findExact(c,d);return a!==-1?b.getAt(a):!1},getSelectedRecord:function(){return this.findRecordByValue(this.value)||null},findRecordByValue:function(c){var a=this.store.byValue.get(c),b=!1;if(a){b=a[0]||a}return b},findRecordByDisplay:function(c){var a=this.store.byText.get(c),b=!1;if(a){b=a[0]||a}return b},addValue:function(a){if(a!=null){return this.doSetValue(a,!0)}},setValue:function(b){var a=this;if(b!=null){return a.doSetValue(b)}else {a.suspendEvent('select');a.valueCollection.beginUpdate();a.pickerSelectionModel.deselectAll();a.valueCollection.endUpdate();a.lastSelectedRecords=null;a.resumeEvent('select')}},setRawValue:function(a){Ext.form.field.Picker.prototype.setRawValue.call(this,a);this.lastMutatedValue=a},doSetValue:function(c,p){var a=this,f=a.getStore(),v=f.getModel(),e=[],u=[],r=a.autoLoadOnValue,m=f.getCount()>0||f.isLoaded(),l=f.hasPendingLoad(),o=r&&!m&&!l,t=a.forceSelection,n=a.pickerSelectionModel,s=a.displayField===a.valueField,j=f.isEmptyStore,k=a.lastSelection,d,h,b,i,g,q;if(l||o||!m||j){if(!c.isModel){if(p){a.value=Ext.Array.from(a.value).concat(c)}else {a.value=c}a.setHiddenValue(a.value);a.setRawValue(s?c:'')}if(o&&!j){f.load()}if(!c.isModel||j){return a}}c=p?Ext.Array.from(a.value).concat(c):Ext.Array.from(c);for(d=0,h=c.length;d0){h.hiddenDataEl.setHtml(Ext.DomHelper.markup({tag:'input',type:'hidden',name:i}));a=1;g=d.firstChild}while(a>c){d.removeChild(b[0]);--a}while(am){if(a.anchorToTarget){a.defaultAlign='r-l';if(a.mouseOffset){a.mouseOffset[0]*=-1}}a.anchor='right';return a.getTargetXY()}if(b[1]l){if(a.anchorToTarget){a.defaultAlign='b-t';if(a.mouseOffset){a.mouseOffset[1]*=-1}}a.anchor='bottom';return a.getTargetXY()}}a.anchorCls='x-tip-anchor-'+a.getAnchorPosition();a.anchorEl.addCls(a.anchorCls);a.targetCounter=0;return b}else {c=a.getMouseOffset();return a.targetXY?[a.targetXY[0]+c[0],a.targetXY[1]+c[1]]:c}},calculateConstrainedPosition:function(e){var a=this,d,b,c;if(!e&&a.isContainedFloater()){d=a.isVisible();if(!d){a.el.show()}b=a.getTargetXY();if(!d){a.el.hide()}c=a.floatParent.getTargetEl().getViewRegion();b[0]-=c.left;b[1]-=c.top}else {b=a.callOverridden(arguments)}return b},getMouseOffset:function(){var a=this,b=a.anchor?[0,0]:[15,18];if(a.mouseOffset){b[0]+=a.mouseOffset[0];b[1]+=a.mouseOffset[1]}return b},fadeOut:function(){var a=this;a.el.fadeOut({duration:a.fadeOutDuration,callback:function(){a.hide();a.el.setOpacity('')}})},getAnchorPosition:function(){var a=this,b;if(a.anchor){a.tipAnchor=a.anchor.charAt(0)}else {b=a.defaultAlign.match(/^([a-z]+)-([a-z]+)(\?)?$/);a.tipAnchor=b[1].charAt(0)}switch(a.tipAnchor){case 't':return 'top';case 'b':return 'bottom';case 'r':return 'right';}return 'left'},getAnchorAlign:function(){switch(this.anchor){case 'top':return 'tl-bl';case 'left':return 'tl-tr';case 'right':return 'tr-tl';default:return 'bl-tl';}},getOffsets:function(){var b=this,c,a,d=b.getAnchorPosition().charAt(0);if(b.anchorToTarget&&!b.trackMouse){switch(d){case 't':a=[0,9];break;case 'b':a=[0,-13];break;case 'r':a=[-13,0];break;default:a=[9,0];break;}}else {switch(d){case 't':a=[-15-b.anchorOffset,30];break;case 'b':a=[-19-b.anchorOffset,-13-b.el.dom.offsetHeight];break;case 'r':a=[-15-b.el.dom.offsetWidth,-13-b.anchorOffset];break;default:a=[25,-13-b.anchorOffset];break;}}c=b.getMouseOffset();a[0]+=c[0];a[1]+=c[1];return a},onTargetOver:function(b){var a=this,d=a.delegate,c;if(a.disabled||b.within(a.target.dom,!0)){return}c=d?b.getTarget(d):!0;if(c){a.triggerElement=c;a.triggerEvent=b;a.clearTimer('hide');a.targetXY=b.getXY();a.delayShow()}},delayShow:function(c){var a=this,b=a.el&&(c===!1||!a.trackMouse)&&a.getTargetXY();if(a.hidden&&!a.showTimer){if(Ext.Date.getElapsed(a.lastActive)=b.length){a.colIdx=0}else {a.colIdx++}a.setColumn(a.colIdx)}while(!a.getCell(!0));break;}}},statics:{compare:function(a,b){return a.rowIdx-b.rowIdx||a.colIdx-b.colIdx}}},1,0,0,0,0,0,[Ext.grid,'CellContext'],0);Ext.cmd.derive('Ext.grid.ColumnComponentLayout',Ext.layout.component.Auto,{type:'columncomponent',setWidthInDom:!0,_paddingReset:{paddingTop:'',paddingBottom:''},columnAutoCls:'x-column-header-text-container-auto',beginLayout:function(a){Ext.layout.component.Auto.prototype.beginLayout.apply(this,arguments);a.titleContext=a.getEl('titleEl')},beginLayoutCycle:function(d){var b=this,a=b.owner,c=d.widthModel.shrinkWrap;Ext.layout.component.Auto.prototype.beginLayoutCycle.apply(this,arguments);if(c){a.el.setWidth('')}a.textContainerEl[c&&!a.isGroupHeader?'addCls':'removeCls'](b.columnAutoCls);a.titleEl.setStyle(b._paddingReset)},publishInnerHeight:function(a,e){var d=this,b=d.owner,c;if(b.getRootHeaderCt().hiddenHeaders){a.setProp('innerHeight',0);return}if(!a.hasRawContent){if(b.headerWrap&&!a.hasDomProp('width')){d.done=!1;return}c=e-a.getBorderInfo().height;a.setProp('innerHeight',c-b.titleEl.getHeight(),!1)}},measureContentHeight:function(a){return a.el.dom.offsetHeight},publishInnerWidth:function(a,b){if(!a.hasRawContent){a.setProp('innerWidth',b-a.getBorderInfo().width,!1)}},calculateOwnerHeightFromContentHeight:function(a,c){var d=Ext.layout.component.Auto.prototype.calculateOwnerHeightFromContentHeight.apply(this,arguments),b=this.owner;if(!a.hasRawContent){if(!b.headerWrap||a.hasDomProp('width')){return c+b.titleEl.getHeight()+a.getBorderInfo().height}return null}return d},calculateOwnerWidthFromContentWidth:function(a,d){var c=this.owner,f=a.getPaddingInfo().width,e=this.getTriggerOffset(c,a),b;if(c.isGroupHeader){b=d}else {b=Math.max(d,c.textEl.getWidth()+a.titleContext.getPaddingInfo().width)}return b+f+e},getTriggerOffset:function(a,c){var b=0;if(c.widthModel.shrinkWrap&&!a.menuDisabled){if(a.query('>:not([hidden])').length===0){b=a.getTriggerElWidth()}}return b}},0,0,0,0,['layout.columncomponent'],0,[Ext.grid,'ColumnComponentLayout'],0);Ext.cmd.derive('Ext.layout.container.Fit',Ext.layout.container.Container,{alternateClassName:'Ext.layout.FitLayout',itemCls:'x-fit-item',type:'fit',manageMargins:!0,sizePolicies:{0:{readsWidth:1,readsHeight:1,setsWidth:0,setsHeight:0},1:{readsWidth:0,readsHeight:1,setsWidth:1,setsHeight:0},2:{readsWidth:1,readsHeight:0,setsWidth:0,setsHeight:1},3:{readsWidth:0,readsHeight:0,setsWidth:1,setsHeight:1}},getItemSizePolicy:function(d,b){var a=b||this.owner.getSizeModel(),c=(a.width.shrinkWrap?0:1)|(a.height.shrinkWrap?0:2);return this.sizePolicies[c]},beginLayoutCycle:function(a,p){var f=this,j=f.lastHeightModel&&f.lastHeightModel.calculated,m=f.lastWidthModel&&f.lastWidthModel.calculated,l=m||j,h=0,i=0,b,k,g,e,q,n,c,d,o,r;Ext.layout.container.Container.prototype.beginLayoutCycle.apply(this,arguments);if(l&&a.targetContext.el.dom.tagName.toUpperCase()!=='TD'){l=m=j=!1}k=a.childItems;q=k.length;for(g=0;g0){for(g=0;g'+a.view.emptyText+''}a.view.getComponentLayout().headerCt=a.headerCt;a.mon(a.view,{uievent:a.processEvent,scope:a});a.headerCt.view=a.view;if(a.hasListeners.viewcreated){a.fireEvent('viewcreated',a,a.view)}}return a.view},getColumnManager:function(){return this.columnManager},getVisibleColumnManager:function(){return this.visibleColumnManager},getTopLevelColumnManager:function(){return this.ownerGrid.getColumnManager()},getTopLevelVisibleColumnManager:function(){return this.ownerGrid.getVisibleColumnManager()},setAutoScroll:Ext.emptyFn,applyScrollable:function(a){if(this.view){this.view.setScrollable(a)}return a},getScrollable:function(){return null},processEvent:function(g,h,f,c,d,b,e,i){var a=b.position.column;if(a){return a.processEvent.apply(a,arguments)}},ensureVisible:function(b,a){this.doEnsureVisible(b,a)},scrollByDeltaY:function(b,a){this.getView().scrollBy(0,b,a)},scrollByDeltaX:function(b,a){this.getView().scrollBy(b,0,a)},afterCollapse:function(){this.saveScrollPos();Ext.panel.Panel.prototype.afterCollapse.apply(this,arguments)},afterExpand:function(){Ext.panel.Panel.prototype.afterExpand.apply(this,arguments);this.restoreScrollPos()},saveScrollPos:Ext.emptyFn,restoreScrollPos:Ext.emptyFn,onHeaderResize:function(){var a=this.view.getScrollable(),b;if(a&&a.isTouchScroller){b=a.getSize();if(b){a.setSize({x:this.headerCt.getTableWidth(),y:b.y})}}},onHeaderMove:function(e,f,b,c,d){var a=this;if(a.optimizedColumnMove===!1){a.view.refreshView()}else {a.view.moveColumn(c,d,b)}a.delayScroll()},onHeaderHide:function(b,c){var a=this.view;if(!b.childHideCount&&a.refreshCounter){a.refreshView()}},onHeaderShow:function(b,c){var a=this.view;if(a.refreshCounter){a.refreshView()}},onHeadersChanged:function(b,c){var a=this;if(a.rendered&&!a.reconfiguring){a.view.refreshView();a.delayScroll()}},delayScroll:function(){var a=this.view;if(a){this.scrollTask.delay(10,null,null,[a])}},onViewReady:function(){this.fireEvent('viewready',this)},onRestoreHorzScroll:function(){var a=this,b=a.scrollXPos;if(b){a.syncHorizontalScroll(a,!0)}},getScrollerOwner:function(){var a=this;if(!this.scrollerOwner){a=this.up('[scrollerOwner]')}return a},getLhsMarker:function(){var a=this;return a.lhsMarker||(a.lhsMarker=Ext.DomHelper.append(a.el,{role:'presentation',cls:a.resizeMarkerCls},!0))},getRhsMarker:function(){var a=this;return a.rhsMarker||(a.rhsMarker=Ext.DomHelper.append(a.el,{role:'presentation',cls:a.resizeMarkerCls},!0))},getSelection:function(){return this.getSelectionModel().getSelection()},updateSelection:function(c){var a=this,b;if(!a.ignoreNextSelection){a.ignoreNextSelection=!0;b=a.getSelectionModel();if(c){b.select(c)}else {b.deselectAll()}a.ignoreNextSelection=!1}},updateBindSelection:function(d,c){var a=this,b=null;if(!a.ignoreNextSelection){a.ignoreNextSelection=!0;if(c.length){b=d.getLastSelected();a.hasHadSelection=!0}if(a.hasHadSelection){a.setSelection(b)}a.ignoreNextSelection=!1}},updateHeaderBorders:function(a){this[a?'removeCls':'addCls'](this.noHeaderBordersCls)},getNavigationModel:function(){return this.getView().getNavigationModel()},getSelectionModel:function(){return this.getView().getSelectionModel()},getScrollTarget:function(){var a=this.getScrollerOwner().query('tableview');return a[a.length-1]},syncHorizontalScroll:function(e,b){var a=this,c=a.view.getScrollX(),d;b=b===!0;if(a.rendered&&(b||c!==a.scrollXPos)){if(b){d=a.getScrollTarget();d.setScrollX(c)}a.headerCt.setScrollX(c);a.scrollXPos=c}},onStoreLoad:Ext.emptyFn,getEditorParent:function(){return this.body},bindStore:function(b,d){var a=this,c=a.getView();if(b){a.store=b;if(c.store!==b){c.bindStore(b,!1)}a.mon(b,{load:a.onStoreLoad,scope:a});a.storeRelayers=a.relayEvents(b,['filterchange','groupchange'])}else {a.unbindStore()}},unbindStore:function(){var a=this,b=a.store,c;if(b){b.trackStateChanges=!1;a.store=null;a.mun(b,{load:a.onStoreLoad,scope:a});Ext.destroy(a.storeRelayers);c=a.view;if(c.store){c.bindStore(null)}}},setColumns:function(a){if(a.length||this.getColumnManager().getColumns().length){this.reconfigure(undefined,a)}},setStore:function(a){this.reconfigure(a);if(this.autoLoad&&!a.isEmptyStore&&!(a.loading||a.isLoaded())){a.load()}},reconfigure:function(b,c){var a=this,f=a.store,e=a.headerCt,i=a.lockable,h=e?e.items.getRange():a.columns,d=a.getView(),j,g;if(arguments.length===1&&Ext.isArray(b)){c=b;b=null}if(c){c=Ext.Array.slice(c)}a.reconfiguring=!0;if(b){b=Ext.StoreManager.lookup(b)}a.fireEvent('beforereconfigure',a,b,c,f,h);Ext.suspendLayouts();if(i){a.reconfigureLockable(b,c)}else {j=d.blockRefresh;d.blockRefresh=!0;if(b&&b!==f){a.unbindStore();a.bindStore(b)}if(c){delete a.scrollXPos;e.removeAll();e.add(c)}d.blockRefresh=j;g=d.refreshCounter}Ext.resumeLayouts(!0);if(i){a.afterReconfigureLockable()}else {if(d.refreshCounter===g){d.refreshView()}}a.fireEvent('reconfigure',a,b,c,f,h);delete a.reconfiguring},beforeDestroy:function(){var a=this,b=a.scrollTask;if(b){b.cancel();a.scrollTask=null}Ext.destroy(a.focusEnterLeaveListeners);Ext.panel.Panel.prototype.beforeDestroy.call(this)},onDestroy:function(){var a=this;if(a.lockable){a.destroyLockable()}a.unbindStore();Ext.panel.Panel.prototype.onDestroy.call(this);a.columns=a.storeRelayers=a.columnManager=a.visibleColumnManager=null},destroy:function(){var a=this;Ext.panel.Panel.prototype.destroy.call(this);if(a.destroyed){a.view=a.selModel=a.headerCt=null}},privates:{initFocusableElement:function(){},doEnsureVisible:function(a,c){if(this.lockable){return this.ensureLockedVisible(a,c)}if(typeof a!=='number'&&!a.isEntity){a=this.store.getById(a)}var b=this,d=b.getView(),f=d.getNode(a),g,h,k,j,m,l,i,e,n;if(c){g=c.callback;h=c.scope;k=c.animate;j=c.highlight;m=c.select;l=c.focus;e=c.column}if(b.deferredEnsureVisible){b.deferredEnsureVisible.destroy()}if(!d.componentLayoutCounter){b.deferredEnsureVisible=d.on({resize:b.doEnsureVisible,args:Ext.Array.slice(arguments),scope:b,single:!0,destroyable:!0});return}if(typeof e==='number'){e=b.ownerGrid.getVisibleColumnManager().getColumns()[e]}if(f){i=d.getScrollable();if(e){n=Ext.fly(f).selectNode(e.getCellSelector())}if(i){i.scrollIntoView(n||f,!!e,k,j)}if(!a.isEntity){a=d.getRecord(f)}if(m){d.getSelectionModel().select(a)}if(l){d.getNavigationModel().setPosition(a,0)}Ext.callback(g,h||b,[!0,a,f])}else {if(d.bufferedRenderer){d.bufferedRenderer.scrollTo(a,{animate:k,highlight:j,select:m,focus:l,column:e,callback:function(f,e,d){Ext.callback(g,h||b,[!0,e,d])}})}else {Ext.callback(g,h||b,[!1,null])}}},getFocusEl:function(){return this.getView().getFocusEl()},setActionableMode:function(b,c){var a=this.ownerGrid;if(!a.destroying&&a.view.setActionableMode(b,c)!==!1){a.fireEvent('actionablemodechange',b);a[b?'addCls':'removeCls'](a.actionableModeCls);return !0}}}},1,['tablepanel'],['component','box','container','panel','tablepanel'],{'component':!0,'box':!0,'container':!0,'panel':!0,'tablepanel':!0},['widget.tablepanel'],0,[Ext.panel,'Table'],0);Ext.define('Ext.theme.neptune.panel.Table',{override:'Ext.panel.Table',lockableBodyBorder:!0,initComponent:function(){var a=this;(arguments.callee.$previous||Ext.panel.Panel.prototype.initComponent).call(this);if(!a.hasOwnProperty('bodyBorder')&&!a.hideHeaders&&(a.lockableBodyBorder||!a.lockable)){a.bodyBorder=!0}}});Ext.cmd.derive('Ext.grid.ColumnLayout',Ext.layout.container.HBox,{type:'gridcolumn',firstHeaderCls:'x-column-header-first',lastHeaderCls:'x-column-header-last',initLayout:function(){Ext.layout.container.HBox.prototype.initLayout.call(this);if(this.scrollbarWidth===undefined){this.self.prototype.scrollbarWidth=Ext.getScrollbarSize().width}},beginLayout:function(d){var b=this,j=b.owner,e=b.firstHeaderCls,f=b.lastHeaderCls,h=[e,f],i=b.getVisibleItems(),g=i.length,c,a;Ext.layout.container.HBox.prototype.beginLayout.call(this,d);for(c=0;c0){b=this.getColumns()[a-1]}return b},getNextSibling:function(c){var a=this.getHeaderIndex(c),b;if(a!==-1){b=this.getColumns()[a+1]}return b||null},getFirst:function(){var a=this.getColumns();return a.length>0?a[0]:null},getLast:function(){var a=this.getColumns(),b=a.length;return b>0?a[b-1]:null},getHeaderByDataIndex:function(d){var c=this.getColumns(),e=c.length,a,b;for(a=0;a=d.left&&e=n.getMaxPosition().y-c.all.last(!0).offsetHeight){b.rowIdx--}e=Math.min(b.rowIdx,h.getCount()-1);f=Math.min(f,j.getColumns().length);d=h.getAt(e);i=j.getColumns()[f]}}else {if(k){d=e=null}else {if(g==null){g=a.lastFocused?a.lastFocused.column:0}if(typeof b==='number'){e=Math.max(Math.min(b,h.getCount()-1),0);d=h.getAt(b)}else {if(b.isEntity){d=b;e=h.indexOf(d)}else {if(b.tagName){d=c.getRecord(b);e=h.indexOf(d);if(e===-1){d=null}}else {if(p){return}k=!0;d=e=null}}}}if(d){if(e===-1){a.recordIndex=-1;d=h.getAt(0);e=0;g=null}if(g==null){if(!(i=a.column)){f=0;i=j.getColumns()[0]}}else {if(typeof g==='number'){i=j.getColumns()[g];f=g}else {i=g;f=j.indexOf(g)}}}else {k=!0;i=f=null}}if(e===a.recordIndex&&f===a.columnIndex&&c===a.position.view){return a.focusPosition(a.position)}if(a.cell){a.cell.removeCls(a.focusCls)}a.previousRecordIndex=a.recordIndex;a.previousRecord=a.record;a.previousItem=a.item;a.previousCell=a.cell;a.previousColumn=a.column;a.previousColumnIndex=a.columnIndex;a.previousPosition=a.position.clone();a.selectionStart=m.selectionStart;a.position.setAll(c,a.recordIndex=e,a.columnIndex=f,a.record=d,a.column=i);if(k){a.item=a.cell=null}else {a.focusPosition(a.position,o)}if(!q){m.fireEvent('focuschange',m,a.previousRecord,a.record);c.fireEvent('rowfocus',a.record,a.item,a.recordIndex);c.fireEvent('cellfocus',a.record,a.cell,a.position)}if(l&&!o&&a.cell!==a.previousCell){a.fireNavigateEvent(l)}},focusPosition:function(b){var a=this,c,d;a.item=a.cell=null;if(b&&b.record&&b.column){c=b.view;if(b.rowElement){d=a.item=b.rowElement}else {d=c.getRowByRecord(b.record)}if(d){a.cell=b.cellElement||Ext.fly(d).down(b.column.getCellSelector(),!0);if(a.cell){a.cell=new Ext.dom.Fly(a.cell);c.lastFocused=a.lastFocused=a.position.clone();a.focusItem(a.cell);c.focusEl=a.cell}else {a.position.setAll();a.record=a.column=a.recordIndex=a.columnIndex=null}}else {d=c.dataSource.indexOf(b.record);a.position.setAll();a.record=a.column=a.recordIndex=a.columnIndex=null;if(d!==-1&&c.bufferedRenderer){a.lastKeyEvent=null;c.bufferedRenderer.scrollTo(d,!1,a.afterBufferedScrollTo,a)}}}},focusItem:function(a){a.addCls(this.focusCls);a.focus()},getCell:function(){return this.cell},getPosition:function(f){var c=this,a=c.position,b,e,d;if(a.record&&a.column){if(f){return a}e=a.view;d=e.dataSource;b=d.indexOf(a.record);if(b===-1){b=a.rowIdx;if(!(a.record=d.getAt(b))){b=-1}}if(b===-1||e.getVisibleColumnManager().indexOf(a.column)===-1){a.setAll();c.record=c.column=c.recordIndex=c.columnIndex=null}else {return a}}return null},getLastFocused:function(){var c=this,b,a=c.lastFocused;if(a&&a.record&&a.column){b=a.view;if(b.dataSource.indexOf(a.record)!==-1&&b.getVisibleColumnManager().indexOf(a.column)!==-1){return a}}},onKeyTab:function(a){var e=!a.shiftKey,d=a.position.clone(),g=d.view,f=a.position.cellElement,b=Ext.fly(f).findTabbableElements(),c,i=g.ownerGrid.actionables,j=i.length,h;a.preventDefault();c=b[Ext.Array.indexOf(b,a.target)+(e?1:-1)];while(!c&&(f=f[e?'nextSibling':'previousSibling'])){d.setColumn(g.getHeaderByCell(f));for(h=0;hj.height}a.setProp('viewOverflowY',i)}},measureContentHeight:function(e){var d=this.owner,b=d.body.dom,c=d.emptyEl,a=0;if(c){a+=c.offsetHeight}if(b){a+=b.offsetHeight}if(e.headerContext.state.boxPlan.tooNarrow){a+=Ext.getScrollbarSize().height}return a},flushColumnWidths:function(){var a=this,i=a.layout,d=a.ownerContext,g=a.columnsChanged,h=d.target,j=g.length,b,c,e,f;if(d.state.columnFlusher!==a){return}for(c=0;c0){h+=b;Ext.fly(f[c].el).setHeight(a)}else {g-=b}}a=i.rowHeight+g;if(Ext.isIE9&&d.view.ownerGrid.rowLines){a--}if(d.rowHeight+h=c+d;a--){e[a]=e[a-d];e[a].setAttribute('data-recordIndex',a)}}b.endIndex=b.endIndex+d}else {b.startIndex=c;b.endIndex=c+d-1}for(a=0;ab.endIndex){delete d[a]}}while(a!==f);delete d[a]},getCount:function(){return this.count},slice:function(e,a){var d=this.elements,c=[],b;if(!a){a=this.endIndex}else {a=Math.min(this.endIndex,a-1)}for(b=e||this.startIndex;b<=a;b++){c.push(d[b])}return c},replaceElement:function(a,b,d){var e=this.elements,c=typeof a==='number'?a:this.indexOf(a);if(c>-1){b=Ext.getDom(b);if(d){a=e[c];a.parentNode.insertBefore(b,a);Ext.removeNode(a);b.setAttribute('data-recordIndex',c)}this.elements[c]=b}return this},indexOf:function(b){var c=this.elements,a;b=Ext.getDom(b);for(a=this.startIndex;a<=this.endIndex;a++){if(c[a]===b){return a}}return -1},removeRange:function(g,c,j){var a=this,e=a.elements,i=[],d,b,h,f;if(c==null){c=a.endIndex+1}else {c=Math.min(a.endIndex+1,c+1)}if(g==null){g=a.startIndex}h=c-g;for(b=g,f=c;b<=a.endIndex;b++,f++){d=e[b];if(b=b.startIndex&&f<=b.endIndex){a[a.length]=f}}Ext.Array.sort(a);e=a.length}else {if(ab.endIndex){return}e=1;a=[a]}for(d=g=a[0],c=0;d<=b.endIndex;d++,g++){if(c=b.startIndex){j=h[d]=h[g];j.setAttribute('data-recordIndex',d)}else {delete h[d]}}b.endIndex-=e;b.count-=e},scroll:function(i,t,m){var b=this,e=b.view,p=e.store,c=b.elements,r=i.length,q=e.getNodeContainer(),k=e.hasListeners.itemremove,s=e.hasListeners.itemadd,h=b.statics().range,a,d,o,j,l,n,f,g;if(!i.length){return}if(t===-1){if(m){if(k){f=[];g=[]}n=b.endIndex-m+1;if(h){h.setStartBefore(c[n]);h.setEndAfter(c[b.endIndex]);h.deleteContents();for(a=n;a<=b.endIndex;a++){d=c[a];delete c[a];if(k){f.push(p.getByInternalId(d.getAttribute('data-recordId')));g.push(d)}}}else {for(a=n;a<=b.endIndex;a++){d=c[a];delete c[a];Ext.removeNode(d);if(k){f.push(p.getByInternalId(d.getAttribute('data-recordId')));g.push(d)}}}e.fireEvent('itemremove',f,n,g,e);b.endIndex-=m}if(i.length){l=e.bufferRender(i,b.startIndex-=r);j=l.children;for(a=0;a','{[view.renderTHead(values, out, parent)]}','{%','view.renderRows(values.rows, values.columns, values.viewStartIndex, out);','%}','{[view.renderTFoot(values, out, parent)]}','','{% ','view = columns = column = null;','%}',{definitions:'var view, tableCls, columns, i, len, column;',priority:0}],outerRowTpl:['','{%','this.nextTpl.applyOut(values, out, parent)','%}','',{priority:9999}],rowTpl:['{%','var dataRowCls = values.recordIndex === -1 ? "" : " x-grid-row";','%}','','{%','parent.view.renderCell(values, parent.record, parent.recordIndex, parent.rowIndex, xindex - 1, out, parent)','%}','','',{priority:0}],cellTpl:['{tdStyle}"',' tabindex="-1" data-columnid="{[values.column.getItemId()]}">','
    {style}" ','{cellInnerAttr:attributes}>{value}
    ','',{priority:0}],refreshSelmodelOnRefresh:!1,tableValues:{},rowValues:{itemClasses:[],rowClasses:[]},cellValues:{classes:['x-grid-cell x-grid-td']},constructor:function(a){if(a.grid.isTree){a.baseCls='x-tree-view'}Ext.view.View.prototype.constructor.call(this,a)},hasVariableRowHeight:function(b){var a=this;return a.variableRowHeight||a.store.isGrouped()||a.getVisibleColumnManager().hasVariableRowHeight()||!b&&a.lockingPartner&&a.lockingPartner.hasVariableRowHeight(!0)},initComponent:function(){var a=this;if(a.columnLines){a.addCls(a.grid.colLinesCls)}if(a.rowLines){a.addCls(a.grid.rowLinesCls)}a.body=new Ext.dom.Fly();a.body.id=a.id+'gridBody';if(!a.trackOver){a.overItemCls=null}a.headerCt.view=a;a.grid.view=a;a.initFeatures(a.grid);a.itemSelector=a.getItemSelector();a.all=new Ext.view.NodeCache(a);Ext.view.View.prototype.initComponent.call(this)},applySelectionModel:function(a,f){var d=this,b=d.ownerGrid,e=a.type,c=d.disableSelection||b.disableSelection;if(!f){if(!(a&&a.isSelectionModel)){a=b.selModel||a}}if(a){if(a.isSelectionModel){a.allowDeselect=b.allowDeselect||a.selectionMode!=='SINGLE';a.locked=c}else {if(typeof a==='string'){a={type:a}}else {a.type=b.selType||a.selType||a.type||e}if(!a.mode){if(b.simpleSelect){a.mode='SIMPLE'}else {if(b.multiSelect){a.mode='MULTI'}}}a=Ext.Factory.selection(Ext.apply({allowDeselect:b.allowDeselect,locked:c},a))}}return a},updateSelectionModel:function(b,c){var a=this;if(c){c.un({scope:a,lastselectedchanged:a.updateBindSelection,selectionchange:a.updateBindSelection});Ext.destroy(a.selModelRelayer)}a.selModelRelayer=a.relayEvents(b,['selectionchange','beforeselect','beforedeselect','select','deselect','focuschange']);b.on({scope:a,lastselectedchanged:a.updateBindSelection,selectionchange:a.updateBindSelection});a.selModel=b},getVisibleColumnManager:function(){return this.ownerCt.getVisibleColumnManager()},getColumnManager:function(){return this.ownerCt.getColumnManager()},getTopLevelVisibleColumnManager:function(){return this.ownerGrid.getVisibleColumnManager()},moveColumn:function(c,h,j){var b=this,m=j>1,e=m&&document.createRange?document.createRange():null,g=m&&!e?document.createDocumentFragment():null,l=h,p=b.getGridColumns().length,k=p-1,r=(b.firstCls||b.lastCls)&&(h===0||h===p||c===0||c===k),f,i,q,n,d,a,o;if(b.rendered&&h!==c){q=b.el.query(b.rowSelector);for(f=0,n=q.length;f=(a-1)*b&&d.endIndex<=a*b-1){c.get(a);return !1}},onViewScroll:function(a,b,c){if(!this.ignoreScroll){Ext.view.View.prototype.onViewScroll.call(this,a,b,c)}},createRowElement:function(e,f,d){var a=this,c=a.renderBuffer,b=a.collectData([e],f);b.columns=d;a.tpl.overwrite(c,b);a.cleanupData();return Ext.fly(c).down(a.getNodeContainerSelector(),!0).firstChild},bufferRender:function(e,f){var c=this,a=c.renderBuffer,b,d=document.createRange?document.createRange():null;c.tpl.overwrite(a,c.collectData(e,f));c.cleanupData();Ext.fly(a).saveTabbableState({skipSelf:!0,includeHidden:!0});a=Ext.fly(a).down(c.getNodeContainerSelector(),!0);if(d){d.selectNodeContents(a);b=d.extractContents()}else {b=document.createDocumentFragment();while(a.firstChild){b.appendChild(a.firstChild)}}return {fragment:b,children:Ext.Array.toArray(b.childNodes)}},collectData:function(c,b){var a=this;a.rowValues.view=a;a.tableValues.view=a;a.tableValues.rows=c;a.tableValues.columns=null;a.tableValues.viewStartIndex=b;a.tableValues.touchScroll=a.touchScroll;a.tableValues.tableStyle='width:'+a.headerCt.getTableWidth()+'px';return a.tableValues},cleanupData:function(){var a=this.tableValues;a.view=a.columns=a.rows=this.rowValues.view=null},refreshSize:function(c){var a=this,b=a.getBodySelector();if(b){a.body.attach(a.el.down(b,!0))}if(!a.hasLoadingHeight){Ext.suspendLayouts();Ext.view.View.prototype.refreshSize.apply(this,arguments);if(c||a.hasVariableRowHeight()&&a.dataSource.getCount()){a.grid.updateLayout()}Ext.resumeLayouts(!0)}},clearViewEl:function(g){var a=this,b=a.all,i=a.getStore(),d,c,f,h=b.slice(),e=[];if(a.hasListeners.itemremove){for(d=b.startIndex;d<=b.endIndex;d++){e.push(i.getByInternalId(b.item(d,!0).getAttribute('data-recordId')))}}a.fireEvent('itemremove',e,b.startIndex,h,a);Ext.view.View.prototype.clearViewEl.call(this);c=Ext.fly(a.getNodeContainer());if(c&&!g){f=a.getTargetEl();if(f.dom!==c.dom){c.destroy()}}},getMaskTarget:function(){return this.ownerCt.body},statics:{getBoundView:function(a){return Ext.getCmp(a.getAttribute('data-boundView'))}},getRecord:function(a){if(this.store.destroyed){return}if(a.isModel){return a}a=this.getNode(a);if(a){return this.dataSource.getByInternalId(a.getAttribute('data-recordId'))}},indexOf:function(a){a=this.getNode(a);if(!a&&a!==0){return -1}return this.all.indexOf(a)},indexInStore:function(a){return a?this.dataSource.indexOf(this.getRecord(a)):-1},indexOfRow:function(a){var c=this.dataSource,b;if(a.isCollapsedPlaceholder){b=c.indexOfPlaceholder(a)}else {b=c.indexOf(a)}return b},renderRows:function(e,g,d,h){var b=this,a=b.rowValues,f=e.length,c;a.view=b;a.columns=g;a.rowRole=b.rowAriaRole;b.cellValues.cellRole=b.cellAriaRole;for(c=0;c');for(a=0;a')}d.push('')},renderRow:function(c,e,j){var a=this,k=e===-1,h=a.selectionModel,b=a.rowValues,d=b.itemClasses,g=b.rowClasses,l=a.itemCls,f,i=a.rowTpl;b.rowAttr={};b.record=c;b.recordId=c.internalId;b.recordIndex=a.store.indexOf(c);b.rowIndex=e;b.rowId=a.getRowId(c);b.itemCls=b.rowCls='';if(!b.columns){b.columns=a.ownerCt.getVisibleColumnManager().getColumns()}d.length=g.length=0;if(!k){d[0]=l;if(!a.ownerCt.disableSelection&&h.isRowSelected){if(h.isRowSelected(c)){d.push(a.selectedItemCls)}}if(a.stripeRows&&e%2!==0){d.push(a.altRowCls)}if(a.getRowClass){f=a.getRowClass(c,e,null,a.dataSource);if(f){g.push(f)}}}if(j){i.applyOut(b,j,a.tableValues)}else {return i.apply(b,a.tableValues)}},renderCell:function(b,f,j,n,m,p){var c=this,l,h=c.selectionModel,a=c.cellValues,d=a.classes,k=f.data[b.dataIndex],o=c.cellTpl,g,e,i=c.navigationModel.getPosition();a.record=f;a.column=b;a.recordIndex=j;a.rowIndex=n;a.columnIndex=a.cellIndex=m;a.align=b.align;a.innerCls=b.innerCls;a.tdCls=a.tdStyle=a.tdAttr=a.style='';a.unselectableAttr=c.enableTextSelection?'':'unselectable="on"';d[1]=b.getCellId();e=2;if(b.renderer&&b.renderer.call){l=c.ownerCt.columnManager.getHeaderIndex(b);g=b.renderer.call(b.usingDefaultRenderer?b:b.scope||c.ownerCt,k,a,f,j,l,c.dataSource,c);if(a.css){f.cssWarning=!0;a.tdCls+=' '+a.css;a.css=null}if(a.tdCls){d[e++]=a.tdCls}}else {g=k}a.value=g==null||g===''?b.emptyCellText:g;if(b.tdCls){d[e++]=b.tdCls}if(c.markDirty&&f.dirty&&f.isModified(b.dataIndex)){d[e++]=c.dirtyCls}if(b.isFirstVisible){d[e++]=c.firstCls}if(b.isLastVisible){d[e++]=c.lastCls}if(!c.enableTextSelection){d[e++]=c.unselectableCls}if(h&&(h.isCellModel||h.isSpreadsheetModel)&&h.isCellSelected(c,j,b)){d[e++]=c.selectedCellCls}if(i&&i.record.id===f.id&&i.column===b){d[e++]=c.focusedItemCls}d.length=e;a.tdCls=d.join(' ');o.applyOut(a,p);a.column=a.record=null},getRow:function(a){var b;if(!a&&a!==0||!this.rendered){return null}if(a.target){a=a.target}if(Ext.isString(a)){return Ext.fly(a).down(this.rowSelector,!0)}if(Ext.isNumber(a)){b=this.all.item(a);return b&&b.down(this.rowSelector,!0)}if(a.isModel){return this.getRowByRecord(a)}b=Ext.fly(a);if(b.is(this.itemSelector)){return this.getRowFromItem(b)}return b.findParent(this.rowSelector,this.getTargetEl())},getRowId:function(a){return this.id+'-record-'+a.internalId},constructRowId:function(a){return this.id+'-record-'+a},getNodeById:function(a){a=this.constructRowId(a);return this.retrieveNode(a,!1)},getRowById:function(a){a=this.constructRowId(a);return this.retrieveNode(a,!0)},getNodeByRecord:function(a){return this.retrieveNode(this.getRowId(a),!1)},getRowByRecord:function(a){return this.retrieveNode(this.getRowId(a),!0)},getRowFromItem:function(c){var b=Ext.getDom(c).tBodies[0].childNodes,d=b.length,a;for(a=0;a1){A=c._extData;j=a.createRowElement(d,a.indexOfRow(d),f);if(Ext.fly(c,'_internal').hasCls(u)){Ext.fly(j).addCls(u)}if(Ext.isIE9m&&c.mergeAttributes){c.mergeAttributes(j,!0)}else {o=j.attributes;H=o.length;for(l=0;l0){if(Ext.supports.ScrollWidthInlinePaddingBug){e+=c.getCellPaddingAfter(d[0])}if(c.columnLines){e+=Ext.fly(d[0].parentNode).getBorderWidth('lr')}}g.setWidth(1);b.textEl.setStyle({'text-overflow':'clip',display:'table-cell'});a=b.textEl.dom.offsetWidth+b.titleEl.getPadding('lr');b.textEl.setStyle({'text-overflow':'',display:''});for(;fh){return !1}if(d){b.view=d}b.setPosition(a,0)}else {b.navigate(+1)};break;case 'left':if(e.isFirstColumn()){a=d&&c.isNormalView?a:a-1;if(a<0){return !1}if(d){b.view=d;f=d.getVisibleColumnManager().getColumns()}b.setPosition(a,f[f.length-1])}else {b.navigate(-1)};break;case 'up':if(a===0){return !1}else {b.setRow(a-1)};break;case 'down':if(a===h){return !1}else {b.setRow(a+1)};break;}if(g&&g.call(j||c,b)!==!0){return !1}return b},walkRows:function(f,e){var i=this,j=i.dataSource,g=0,d=f,h,b=e<0?0:j.getCount()-1,c=b?1:-1,a=f;do{if(b?a>=b:a<=b){return d||b}a+=c;if((h=Ext.fly(i.getRow(a)))&&h.isVisible(!0)){g+=c;d=a}}while(g!==e);return a},walkRecs:function(h,g){var k=this,a=k.dataSource,i=0,e=h,j,c=g<0?0:(a.isBufferedStore?a.getTotalCount():a.getCount())-1,f=c?1:-1,b=a.indexOf(h),d;do{if(c?b>=c:b<=c){return e}b+=f;d=a.getAt(b);if(!d.isCollapsedPlaceholder&&(j=Ext.fly(k.getNodeByRecord(d)))&&j.isVisible(!0)){i+=f;e=d}}while(i!==g);return e},getFirstVisibleRowIndex:function(){var a=this,c=a.dataSource.isBufferedStore?a.dataSource.getTotalCount():a.dataSource.getCount(),b=a.indexOf(a.all.first())-1;do{b+=1;if(b===c){return}}while(!Ext.fly(a.getRow(b)).isVisible(!0));return b},getLastVisibleRowIndex:function(){var b=this,a=b.indexOf(b.all.last());do{a-=1;if(a===-1){return}}while(!Ext.fly(b.getRow(a)).isVisible(!0));return a},getHeaderCt:function(){return this.headerCt},getPosition:function(b,a){return (new Ext.grid.CellContext(this)).setPosition(b,a)},onDestroy:function(){var a=this,c=a.featuresMC,d,b;if(c){for(b=0,d=c.getCount();b=a.viewSize)){a.onReplace(e,d,[],c)}else {Ext.view.View.prototype.onAdd.apply(this,arguments)}b.setPendingStripe(d)},onRemove:function(f,d,e){var a=this,b=a.bufferedRenderer,c;if(a.rendered&&b&&a.dataSource.getCount()+d.length>=b.viewSize){c=a.saveFocusState();b.onReplace(f,e,d,[]);c()}else {Ext.view.View.prototype.onRemove.apply(this,arguments)}a.setPendingStripe(e)},saveFocusState:function(){var b=this,g=b.dataSource,c=b.actionableMode,d=b.getNavigationModel(),a=c?b.actionPosition:d.getPosition(!0),f,e;if(a){a=a.clone();if(c){b.ownerGrid.setActionableMode(!1)}b.el.dom.focus();d.setPosition();return function(){if(g.getCount()){f=Math.min(a.rowIdx,b.all.getCount()-1);e=Math.min(a.colIdx,b.getVisibleColumnManager().getColumns().length-1);a=(new Ext.grid.CellContext(b)).setPosition(g.contains(a.record)?a.record:f,e);if(c){b.ownerGrid.setActionableMode(!0,a)}else {b.cellFocused=!0;d.setPosition(a,null,null,null,!0)}}else {a.column.focus()}}}return Ext.emptyFn},onDataRefresh:function(c){var b=this,a=b.ownerCt;if(a&&a.isCollapsingOrExpanding===2){a.on('expand',b.onDataRefresh,b,{single:!0});return}Ext.view.View.prototype.onDataRefresh.call(this,c)},getViewRange:function(){var a=this;if(a.bufferedRenderer){return a.bufferedRenderer.getViewRange()}return Ext.view.View.prototype.getViewRange.call(this)},setPendingStripe:function(b){var a=this.stripeOnUpdate;if(a===null){a=b}else {a=Math.min(a,b)}this.stripeOnUpdate=a},onEndUpdate:function(){var b=this,a=b.stripeOnUpdate,c=b.all.startIndex;if(b.rendered&&(a||a===0)){if(a-1)&&!g;b=b+(c?1:-1)){o=n[b];e.setColumn(o);k=Ext.fly(d).down(e.column.getCellSelector());for(h=0;h=0&&!(b.isGroupHeader&&(!b.items||!b.items.length))&&h!==c){i=a.isGroupHeader?a.query(':not([hidden]):not([isGroupHeader])').length:1;if(h<=c&&i>1){c-=i}d.getRootHeaderCt().grid.view.moveColumn(h,c,i)}p.fireEvent('columnmove',e,a,h,c);e.isDDMoveInGrid=d.isDDMoveInGrid=!1;if(d.isGroupHeader&&!e.isGroupHeader){if(e!==d){a.savedFlex=a.flex;delete a.flex;a.width=o}}else {if(!e.isGroupHeader){if(a.savedFlex){a.flex=a.savedFlex;delete a.width}}}Ext.resumeLayouts(!0)}}},1,0,0,0,0,0,[Ext.grid.header,'DropZone'],0);Ext.cmd.derive('Ext.grid.plugin.HeaderReorderer',Ext.plugin.Abstract,{init:function(a){this.headerCt=a;a.on({boxready:this.onHeaderCtRender,single:!0,scope:this})},destroy:function(){var a=this;a.headerCt.un('boxready',a.onHeaderCtRender,a);Ext.destroy(a.dragZone,a.dropZone);a.headerCt=a.dragZone=a.dropZone=null;Ext.plugin.Abstract.prototype.destroy.call(this)},onHeaderCtRender:function(){var a=this;a.dragZone=new Ext.grid.header.DragZone(a.headerCt);a.dropZone=new Ext.grid.header.DropZone(a.headerCt);if(a.disabled){a.dragZone.disable()}},enable:function(){this.disabled=!1;if(this.dragZone){this.dragZone.enable()}},disable:function(){this.disabled=!0;if(this.dragZone){this.dragZone.disable()}}},0,0,0,0,['plugin.gridheaderreorderer'],0,[Ext.grid.plugin,'HeaderReorderer'],0);Ext.cmd.derive('Ext.grid.header.Container',Ext.container.Container,{border:!0,baseCls:'x-grid-header-ct',dock:'top',weight:100,defaultType:'gridcolumn',detachOnRemove:!1,defaultWidth:100,sortAscText:'Sort Ascending',sortDescText:'Sort Descending',sortClearText:'Clear Sort',columnsText:'Columns',headerOpenCls:'x-column-header-open',menuSortAscCls:'x-hmenu-sort-asc',menuSortDescCls:'x-hmenu-sort-desc',menuColsIcon:'x-cols-icon',blockEvents:!1,dragging:!1,sortOnClick:!0,enableFocusableContainer:!1,childHideCount:0,sortable:!0,enableColumnHide:!0,initComponent:function(){var a=this;a.plugins=a.plugins||[];a.defaults=a.defaults||{};if(!a.isColumn){if(a.enableColumnResize){a.resizer=new Ext.grid.plugin.HeaderResizer();a.plugins.push(a.resizer)}if(a.enableColumnMove){a.reorderer=new Ext.grid.plugin.HeaderReorderer();a.plugins.push(a.reorderer)}}if(a.isColumn&&!a.isGroupHeader){if(!a.items||a.items.length===0){a.isContainer=a.isFocusableContainer=!1;a.focusable=!0;a.layout={type:'container',calculate:Ext.emptyFn}}}else {a.layout=Ext.apply({type:'gridcolumn',align:'stretch'},a.initialConfig.layout);a.defaults.columnLines=a.columnLines;if(!a.isGroupHeader){a.isRootHeader=!0;if(!a.hiddenHeaders){a.enableFocusableContainer=!0;a.ariaRole='rowgroup'}a.columnManager=new Ext.grid.ColumnManager(!1,a);a.visibleColumnManager=new Ext.grid.ColumnManager(!0,a);if(a.grid){a.grid.columnManager=a.columnManager;a.grid.visibleColumnManager=a.visibleColumnManager}}else {a.visibleColumnManager=new Ext.grid.ColumnManager(!0,a);a.columnManager=new Ext.grid.ColumnManager(!1,a)}}a.menuTask=new Ext.util.DelayedTask(a.updateMenuDisabledState,a);Ext.container.Container.prototype.initComponent.call(this)},insertNestedHeader:function(d){var b=this,e=d.ownerCt,f=b.ownerCt,c=f.layout.owner,a;if(e){if(b.isGroupHeader&&!f.isNestedParent){a=c.items.indexOf(b)}e.remove(d,!1)}if(a===undefined){a=c.items.indexOf(b)}c.insert(a,d)},isNested:function(){return !!this.getRootHeaderCt().down('[isNestedParent]')},isNestedGroupHeader:function(){var a=this,b=a.getRefOwner().query('>:not([hidden])');return b.length===1&&b[0]===a},maybeShowNestedGroupHeader:function(){var a=this.items,b;if(a&&a.length===1&&(b=a.getAt(0))&&b.hidden){b.show()}},setNestedParent:function(a){a.isNestedParent=!1;a.ownerCt.isNestedParent=!!(this.ownerCt.items.length===1&&a.ownerCt.items.length===1)},initEvents:function(){var a=this,b,c;Ext.container.Container.prototype.initEvents.call(this);if(!a.isColumn&&!a.isGroupHeader){b=a.onHeaderCtEvent;c={click:b,dblclick:b,contextmenu:b,mouseover:a.onHeaderCtMouseOver,mouseout:a.onHeaderCtMouseOut,scope:a};if(Ext.supports.Touch){c.longpress=a.onHeaderCtLongPress}a.mon(a.el,c)}},onHeaderCtEvent:function(a,g){var c=this,f=c.getHeaderElByEvent(a),b,e,d;if(c.longPressFired){c.longPressFired=!1;return}if(f&&!c.blockEvents){b=Ext.getCmp(f.id);if(b){e=b[b.clickTargetName];if(!b.isGroupHeader&&!b.isContainer||a.within(e)){if(a.type==='click'||a.type==='tap'){d=b.onTitleElClick(a,e,c.sortOnClick);if(d){c.onHeaderTriggerClick(d,a,a.pointerType==='touch'?d.el:d.triggerEl)}else {c.onHeaderClick(b,a,g)}}else {if(a.type==='contextmenu'){c.onHeaderContextMenu(b,a,g)}else {if(a.type==='dblclick'&&b.resizable){b.onTitleElDblClick(a,e.dom)}}}}}}},blockNextEvent:function(){this.blockEvents=!0;Ext.asap(this.unblockEvents,this)},unblockEvents:function(){this.blockEvents=!1},onHeaderCtMouseOver:function(b,e){var c,a,d;if(!b.within(this.el,!0)){c=b.getTarget('.'+Ext.grid.column.Column.prototype.baseCls);a=c&&Ext.getCmp(c.id);if(a){d=a[a.clickTargetName];if(b.within(d)){a.onTitleMouseOver(b,d.dom)}}}},onHeaderCtMouseOut:function(c,g){var f='.'+Ext.grid.column.Column.prototype.baseCls,d=c.getTarget(f),e=c.getRelatedTarget(f),a,b;if(d!==e){if(d){a=Ext.getCmp(d.id);if(a){b=a[a.clickTargetName];a.onTitleMouseOut(c,b.dom)}}if(e){a=Ext.getCmp(e.id);if(a){b=a[a.clickTargetName];a.onTitleMouseOver(c,b.dom)}}}},onHeaderCtLongPress:function(d){var a=this,b=a.getHeaderElByEvent(d),c=Ext.getCmp(b.id);if(!c.menuDisabled){a.longPressFired=!0;a.showMenuBy(d,b,c)}},getHeaderElByEvent:function(a){return a.getTarget('.'+Ext.grid.column.Column.prototype.baseCls)},isLayoutRoot:function(){if(this.hiddenHeaders){return !1}return Ext.container.Container.prototype.isLayoutRoot.call(this)},getRootHeaderCt:function(){var a=this;return a.isRootHeader?a:a.up('[isRootHeader]')},onDestroy:function(){var a=this;if(a.menu){a.menu.un('hide',a.onMenuHide,a)}a.menuTask.cancel();Ext.container.Container.prototype.onDestroy.call(this);Ext.destroy(a.visibleColumnManager,a.columnManager,a.menu);a.columnManager=a.visibleColumnManager=null},applyColumnsState:function(h,n){if(!h||!h.length){return}var f=this,m=f.items.items,o=m.length,b=0,i=h.length,g,e,a,d,k=!1,c=[],l={},j=[];for(g=0;g=a.visibleFromIdx){b++}Ext.container.Container.prototype.onMove.apply(this,arguments);if(a.isGroupHeader){c=a.visibleColumnManager.getColumns().length}d.onHeaderMoved(a,c,a.visibleFromIdx,b)},maybeContinueRemove:function(){var a=this;return a.isGroupHeader&&!a.applyingState&&!a.isNestedParent&&a.ownerCt&&!a.items.getCount()},onRemove:function(b,c){var a=this,d=a.ownerCt,e=b.lastHiddenHeader;Ext.container.Container.prototype.onRemove.call(this,b,c);if(!a.destroying){if(!a.isDDMoveInGrid){a.onHeadersChanged(b,!1)}if(a.maybeContinueRemove()){if(b.rendered){a.detachComponent(b)}Ext.suspendLayouts();d.remove(a);Ext.resumeLayouts(!0)}}},onHeadersChanged:function(c,d){var b,a=this.getRootHeaderCt();this.purgeHeaderCtCache(this);if(a){a.onColumnsChanged();if(!c.isGroupHeader){b=a.ownerCt;if(b&&!d){b.onHeadersChanged(a,c)}}}},onHeaderMoved:function(d,f,c,e){var a=this,b=a.ownerCt;if(a.rendered){if(b&&b.onHeaderMove){b.onHeaderMove(a,d,f,c,e)}a.fireEvent('columnmove',a,d,c,e)}},onColumnsChanged:function(){var a=this,b=a.menu,c,d;if(a.rendered){a.fireEvent('columnschanged',a);if(b&&(c=b.child('#columnItemSeparator'))){d=b.child('#columnItem');c.destroy();d.destroy()}}},lookupComponent:function(b){var a=Ext.container.Container.prototype.lookupComponent.apply(this,arguments);if(!a.isGroupHeader&&a.width===undefined&&!a.flex){a.width=this.defaultWidth}return a},setSortState:function(){var e=this.up('[store]').store,d=this.visibleColumnManager.getColumns(),f=d.length,c,b,a;for(c=0;cgridcolumn[hideable]'),g=e.length,d;for(;cj.el.dom.clientHeight?Ext.getScrollbarSize().width:0),n=0,e=k.getVisibleGridColumns(),o=b.hidden,f,c,a,g,d;function getTotalFlex(){for(c=0,f=e.length;cg){b.width=g;l=!0}else {b.width=d;h-=d+m;getTotalFlex()}applyWidth();Ext.resumeLayouts(!0)},autoSizeColumn:function(a){var b=this.view;if(b){b.autoSizeColumn(a);if(this.forceFit){this.applyForceFit(a)}}},getRefItems:function(b){var a=Ext.container.Container.prototype.getRefItems.call(this,b);if(this.menu){a.push(this.menu)}return a},privates:{beginChildHide:function(){++this.childHideCount},endChildHide:function(){--this.childHideCount},getFocusables:function(){return this.isRootHeader?this.getVisibleGridColumns():this.items.items},createFocusableContainerKeyNav:function(b){var a=this;return new Ext.util.KeyNav(b,{scope:a,down:a.showHeaderMenu,left:a.onFocusableContainerLeftKey,right:a.onFocusableContainerRightKey,home:a.onHomeKey,end:a.onEndKey,space:a.onHeaderActivate,enter:a.onHeaderActivate})},onHomeKey:function(a){return this.focusChild(null,!0,a)},onEndKey:function(a){return this.focusChild(null,!1,a)},showHeaderMenu:function(b){var a=this.getFocusableFromEvent(b);if(a&&a.isColumn&&a.triggerEl){this.onHeaderTriggerClick(a,b,a.triggerEl)}},onHeaderActivate:function(d){var a=this.getFocusableFromEvent(d),c,b;if(a&&a.isColumn){c=a.getView();if(a.sortable&&this.sortOnClick){b=c.getNavigationModel().getLastFocused();a.toggleSortState();if(b){c.ownerCt.ensureVisible(b.record)}}this.onHeaderClick(a,d,a.el)}},onFocusableContainerMousedown:function(c,b){var a=Ext.Component.fromElement(b);if(a===this){c.preventDefault()}else {a.focus()}}}},0,['headercontainer'],['component','box','container','headercontainer'],{'component':!0,'box':!0,'container':!0,'headercontainer':!0},['widget.headercontainer'],[[Ext.util.FocusableContainer.prototype.mixinId||Ext.util.FocusableContainer.$className,Ext.util.FocusableContainer]],[Ext.grid.header,'Container'],0);Ext.cmd.derive('Ext.grid.column.Column',Ext.grid.header.Container,{alternateClassName:'Ext.grid.Column',config:{triggerVisible:!1,sorter:null},baseCls:'x-column-header',hoverCls:'x-column-header-over',ariaRole:'columnheader',enableFocusableContainer:!1,sortState:null,possibleSortStates:['ASC','DESC'],ariaSortStates:{ASC:'ascending',DESC:'descending'},childEls:['titleEl','triggerEl','textEl','textContainerEl'],headerWrap:!1,renderTpl:['','{%this.renderContainer(out,values)%}'],dataIndex:null,text:' ',menuText:null,emptyCellText:' ',sortable:!0,resizable:!0,hideable:!0,menuDisabled:!1,renderer:!1,align:'left',draggable:!0,tooltipType:'qtip',initDraggable:Ext.emptyFn,tdCls:'',producesHTML:!0,ignoreExport:!1,isHeader:!0,isColumn:!0,tabIndex:-1,ascSortCls:'x-column-header-sort-ASC',descSortCls:'x-column-header-sort-DESC',componentLayout:'columncomponent',groupSubHeaderCls:'x-group-sub-header',groupHeaderCls:'x-group-header',clickTargetName:'titleEl',detachOnRemove:!0,initResizable:Ext.emptyFn,rendererNames:{column:'renderer',edit:'editRenderer',summary:'summaryRenderer'},formatterNames:{column:'formatter',edit:'editFormatter',summary:'summaryFormatter'},initComponent:function(){var a=this;if(!a.rendererScope){a.rendererScope=a.scope}if(a.header!=null){a.text=a.header;a.header=null}if(a.cellWrap){a.tdCls=(a.tdCls||'')+' x-wrap-cell'}if(a.columns!=null){a.isGroupHeader=!0;a.ariaRole='presentation';a.items=a.columns;a.columns=a.flex=a.width=null;a.cls=(a.cls||'')+' '+a.groupHeaderCls;a.sortable=a.resizable=!1;a.align='center'}else {if(a.flex){a.minWidth=a.minWidth||Ext.grid.plugin.HeaderResizer.prototype.minColWidth}}a.addCls('x-column-header-align-'+a.align);a.setupRenderer();a.setupRenderer('edit');a.setupRenderer('summary');Ext.grid.header.Container.prototype.initComponent.apply(this,arguments)},onAdded:function(e,g,f){var a=this,c,d,b;Ext.grid.header.Container.prototype.onAdded.call(this,e,g,f);if(!a.headerId){d=a.up('tablepanel');b=d?d.ownerGrid:a.getRootHeaderCt();b.headerCounter=(b.headerCounter||0)+1;a.headerId='h'+b.headerCounter}if(!a.stateId){a.stateId=a.initialConfig.id||a.headerId}c=a.getSorter();if(c&&!c.initialConfig.id){c.setId((a.dataIndex||a.stateId)+'-sorter')}},applySorter:function(a){return this.getRootHeaderCt().up('tablepanel').store.getData().getSorters().decodeSorter(a)},bindFormatter:function(a){var b=this;return function(c){return a.format(c,a.scope||b.rendererScope||b.resolveListenerScope())}},bindRenderer:function(b){var a=this;a.hasCustomRenderer=!0;return function(){return Ext.callback(b,a.rendererScope,arguments,0,a)}},setupRenderer:function(c){c=c||'column';var a=this,b=a[a.formatterNames[c]],d=a[a.rendererNames[c]],f=c==='column',e,g;if(!b){if(d){if(typeof d==='string'){d=a[a.rendererNames[c]]=a.bindRenderer(d);g=!0}if(f){a.hasCustomRenderer=g||d.length>1}}else {if(f&&a.defaultRenderer){a.renderer=a.defaultRenderer;a.usingDefaultRenderer=!0}}}else {e=b.indexOf('this.')===0;if(e){b=b.substring(5)}b=Ext.app.bind.Template.prototype.parseFormat(b);a[a.formatterNames[c]]=null;if(e){b.scope=null}a[a.rendererNames[c]]=a.bindFormatter(b)}},getView:function(){var a=this.getRootHeaderCt();if(a){return a.view}},onFocusLeave:function(a){Ext.grid.header.Container.prototype.onFocusLeave.call(this,a);if(this.activeMenu){this.activeMenu.hide()}},initItems:function(){var a=this;Ext.grid.header.Container.prototype.initItems.apply(this,arguments);if(a.isGroupHeader){if(a.config.hidden||!a.hasVisibleChildColumns()){a.hide()}}},hasVisibleChildColumns:function(){var c=this.items.items,d=c.length,a,b;for(a=0;agridcolumn:not([hidden]):not([menuDisabled])');c=a.length;if(Ext.Array.contains(a,b.hideCandidate)){c--}if(c){return !1}b.hideCandidate=this},isLockable:function(){var a={result:this.lockable!==!1};if(a.result){this.ownerCt.bubble(this.hasMultipleVisibleChildren,null,[a])}return a.result},isLocked:function(){return this.locked||!!this.up('[isColumn][locked]','[isRootHeader]')},hasMultipleVisibleChildren:function(a){if(!this.isXType('headercontainer')){a.result=!1;return !1}if(this.query('>gridcolumn:not([hidden])').length>1){return !1}},hide:function(){var a=this,b=a.getRootHeaderCt(),c=a.getRefOwner();if(c.constructing){Ext.grid.header.Container.prototype.hide.call(this);return a}if(a.rendered&&!a.isVisible()){return a}if(b.forceFit){a.visibleSiblingCount=b.getVisibleGridColumns().length-1;if(a.flex){a.savedWidth=a.getWidth();a.flex=null}}b.beginChildHide();Ext.suspendLayouts();if(c.isGroupHeader){if(a.isNestedGroupHeader()){c.hide()}if(a.isSubHeader&&!a.isGroupHeader&&c.query('>gridcolumn:not([hidden])').length===1){c.lastHiddenHeader=a}}Ext.grid.header.Container.prototype.hide.call(this);b.endChildHide();b.onHeaderHide(a);Ext.resumeLayouts(!0);return a},show:function(){var a=this,c=a.getRootHeaderCt(),b=a.getRefOwner();if(a.isVisible()){return a}if(b.isGroupHeader){b.lastHiddenHeader=null}if(a.rendered){if(c.forceFit){c.applyForceFit(a)}}Ext.suspendLayouts();if(a.isSubHeader&&b.hidden){b.show(!1,!0)}Ext.grid.header.Container.prototype.show.apply(this,arguments);if(a.isGroupHeader){a.maybeShowNestedGroupHeader()}b=a.getRootHeaderCt();if(b){b.onHeaderShow(a)}Ext.resumeLayouts(!0);return a},shouldUpdateCell:function(d,b){if(!this.preventUpdate){if(this.hasCustomRenderer){return 1}if(b){var e=b.length,a,c;for(a=0;aActions',ignoreExport:!0,sortable:!1,innerCls:'x-grid-cell-inner-action-col',actionIconCls:'x-action-col-icon',constructor:function(g){var a=this,b=Ext.apply({},g),d=b.items||a.items||[a],e,c,f;a.origRenderer=b.renderer||a.renderer;a.origScope=b.scope||a.scope;a.renderer=a.scope=b.renderer=b.scope=null;b.items=null;Ext.grid.column.Column.prototype.constructor.call(this,b);a.items=d;for(c=0,f=d.length;c':'>')}return h},updater:function(e,d,c,f,b){var a={};Ext.fly(e).addCls(a.tdCls).down(this.getView().innerSelector,!0).innerHTML=this.defaultRenderer(d,a,c,null,null,b,f)},enableAction:function(a,c){var b=this;if(!a){a=0}else {if(!Ext.isNumber(a)){a=Ext.Array.indexOf(b.items,a)}}b.items[a].disabled=!1;b.up('tablepanel').el.select('.x-action-col-'+a).removeCls(b.disabledCls);if(!c){b.fireEvent('enable',b)}},disableAction:function(a,c){var b=this;if(!a){a=0}else {if(!Ext.isNumber(a)){a=Ext.Array.indexOf(b.items,a)}}b.items[a].disabled=!0;b.up('tablepanel').el.select('.x-action-col-'+a).addCls(b.disabledCls);if(!c){b.fireEvent('disable',b)}},beforeDestroy:function(){this.renderer=this.items=null;return Ext.grid.column.Column.prototype.beforeDestroy.apply(this,arguments)},processEvent:function(f,g,n,h,i,d,l,o){var b=this,c=d.getTarget(),e=f==='keydown'&&d.getKey(),m,a,j,k=Ext.fly(n);d.stopSelection=!e&&b.stopSelection;if(e&&(c===n||!k.contains(c))){c=k.query('.'+b.actionIconCls,!0);if(c.length===1){c=c[0]}else {return}}if(c&&(m=c.className.match(b.actionIdRe))){a=b.items[parseInt(m[1],10)];j=a.disabled||(a.isDisabled?a.isDisabled.call(a.scope||b.origScope||b,g,h,i,a,l):!1);if(a&&!j){if(f==='mousedown'&&!b.getView().actionableMode){d.preventDefault()}else {if(f==='click'||(e===d.ENTER||e===d.SPACE)){Ext.callback(a.handler||b.handler,a.scope||b.origScope,[g,h,i,a,d,l,o],undefined,b);if(!g.el.contains(Ext.Element.getActiveElement())){return !1}}}}}return Ext.grid.column.Column.prototype.processEvent.apply(this,arguments)},cascade:function(b,a){b.call(a||this,this)},getRefItems:function(){return []},privates:{getFocusables:function(){return []},shouldUpdateCell:function(){return 2}}},1,['actioncolumn'],['component','box','container','headercontainer','gridcolumn','actioncolumn'],{'component':!0,'box':!0,'container':!0,'headercontainer':!0,'gridcolumn':!0,'actioncolumn':!0},['widget.actioncolumn'],0,[Ext.grid.column,'Action',Ext.grid,'ActionColumn'],0);Ext.cmd.derive('Ext.grid.column.Check',Ext.grid.column.Column,{alternateClassName:['Ext.ux.CheckColumn','Ext.grid.column.CheckColumn'],align:'center',ignoreExport:!0,stopSelection:!0,tdCls:'x-grid-cell-checkcolumn',innerCls:'x-grid-cell-inner-checkcolumn',clickTargetName:'el',defaultFilterType:'boolean',constructor:function(){this.scope=this;Ext.grid.column.Column.prototype.constructor.apply(this,arguments)},processEvent:function(h,n,k,e,m,b,g,l){var a=this,d=h==='keydown'&&b.getKey(),f=h==='mousedown',j=a.disabled,i,c;b.stopSelection=!d&&a.stopSelection;if(!j&&(f||(d===b.ENTER||d===b.SPACE))){c=!a.isRecordChecked(g);if(a.fireEvent('beforecheckchange',a,e,c)!==!1){a.setRecordCheck(g,c,k,l,b);a.fireEvent('checkchange',a,e,c);if(f&&!a.getView().actionableMode){b.preventDefault()}}}else {i=Ext.grid.column.Column.prototype.processEvent.apply(this,arguments)}return i},onEnable:function(){Ext.grid.column.Column.prototype.onEnable.apply(this,arguments);this._setDisabled(!1)},onDisable:function(){this._setDisabled(!0)},_setDisabled:function(d){var b=this,c=b.disabledCls,a;a=b.up('tablepanel').el.select(b.getCellSelector());if(d){a.addCls(c)}else {a.removeCls(c)}},defaultRenderer:function(d,c){var a='x-',b=a+'grid-checkcolumn';if(this.disabled){c.tdCls+=' '+this.disabledCls}if(d){b+=' '+a+'grid-checkcolumn-checked'}return '
    '},isRecordChecked:function(a){var b=this.property;if(b){return a[b]}return a.get(this.dataIndex)},setRecordCheck:function(c,a,e,f,g){var b=this,d=b.property;if(d){c[d]=a;b.updater(e,a)}else {c.set(b.dataIndex,a)}},updater:function(a,b){a=Ext.fly(a);a[this.disabled?'addCls':'removeCls'](this.disabledCls);Ext.fly(a.down(this.getView().innerSelector,!0).firstChild)[b?'addCls':'removeCls']('x-grid-checkcolumn-checked')}},1,['checkcolumn'],['component','box','container','headercontainer','gridcolumn','checkcolumn'],{'component':!0,'box':!0,'container':!0,'headercontainer':!0,'gridcolumn':!0,'checkcolumn':!0},['widget.checkcolumn'],0,[Ext.grid.column,'Check',Ext.ux,'CheckColumn',Ext.grid.column,'CheckColumn'],0);Ext.cmd.derive('Ext.grid.column.Number',Ext.grid.column.Column,{alternateClassName:'Ext.grid.NumberColumn',defaultFilterType:'number',format:'0,000.00',producesHTML:!1,defaultRenderer:function(a){return Ext.util.Format.number(a,this.format)},updater:function(b,a){Ext.fly(b).down(this.getView().innerSelector,!0).innerHTML=Ext.grid.column.Number.prototype.defaultRenderer.call(this,a)}},0,['numbercolumn'],['component','box','container','headercontainer','gridcolumn','numbercolumn'],{'component':!0,'box':!0,'container':!0,'headercontainer':!0,'gridcolumn':!0,'numbercolumn':!0},['widget.numbercolumn'],0,[Ext.grid.column,'Number',Ext.grid,'NumberColumn'],0);Ext.cmd.derive('Ext.grid.column.RowNumberer',Ext.grid.column.Column,{alternateClassName:'Ext.grid.RowNumberer',isRowNumberer:!0,text:' ',width:23,sortable:!1,draggable:!1,autoLock:!0,lockable:!1,align:'right',producesHTML:!1,ignoreExport:!0,constructor:function(b){var a=this;a.width=a.width;Ext.grid.column.Column.prototype.constructor.apply(this,arguments);a.sortable=!1;a.scope=a},resizable:!1,hideable:!1,menuDisabled:!0,dataIndex:'',cls:'x-row-numberer',tdCls:'x-grid-cell-row-numberer x-grid-cell-special',innerCls:'x-grid-cell-inner-row-numberer',rowspan:undefined,defaultRenderer:function(j,b,f,i,h,a,g){var c=this.rowspan,e=a.currentPage,d=g.store.indexOf(f);if(b&&c){b.tdAttr='rowspan="'+c+'"'}if(e>1){d+=(e-1)*a.pageSize}return d+1},updater:function(d,c,b,e,a){Ext.fly(d).down(this.getView().innerSelector,!0).innerHTML=this.defaultRenderer(c,null,b,null,null,a,e)}},1,['rownumberer'],['component','box','container','headercontainer','gridcolumn','rownumberer'],{'component':!0,'box':!0,'container':!0,'headercontainer':!0,'gridcolumn':!0,'rownumberer':!0},['widget.rownumberer'],0,[Ext.grid.column,'RowNumberer',Ext.grid,'RowNumberer'],0);Ext.define('Ext.theme.neptune.grid.column.RowNumberer',{override:'Ext.grid.column.RowNumberer',width:25});Ext.cmd.derive('Ext.grid.column.Widget',Ext.grid.column.Column,{config:{defaultWidgetUI:{}},ignoreExport:!0,sortable:!1,onWidgetAttach:null,preventUpdate:!0,stopSelection:!0,initComponent:function(){var b=this,a;Ext.grid.column.Column.prototype.initComponent.apply(this,arguments);a=b.widget;b.widget=a=Ext.apply({},a);if(!a.ui){a.ui=b.getDefaultWidgetUI()[a.xtype]||'default'}b.isFixedSize=Ext.isNumber(a.width)},processEvent:function(c,d,h,e,f,b,g,i){var a;if(this.stopSelection&&c==='click'){a=b.getTarget(d.innerSelector);if(a&&a!==b.target){b.stopSelection=!0}}},beforeRender:function(){var a=this,b=a.tdCls,c;a.listenerScopeFn=function(b){if(b==='this'){return this}return a.resolveListenerScope(b)};a.liveWidgets={};a.cachedStyles={};a.freeWidgetStack=[c=a.getFreeWidget()];b=b?b+' ':'';a.tdCls=b+c.getTdCls();a.setupViewListeners(a.getView());Ext.grid.column.Column.prototype.beforeRender.call(this)},afterRender:function(){var a=this.getView();Ext.grid.column.Column.prototype.afterRender.call(this);if(a&&a.viewReady&&!a.ownerGrid.reconfiguring){this.onViewRefresh(a,a.getViewRange())}},defaultRenderer:Ext.emptyFn,updater:function(c,b,a){this.updateWidget(a)},onResize:function(e){var a=this,d=a.liveWidgets,c=a.getView(),f,b;if(!a.isFixedSize&&a.rendered&&c&&c.viewReady){b=c.getEl().down(a.getCellInnerSelector());if(b){e-=parseInt(a.getCachedStyle(b,'padding-left'),10)+parseInt(a.getCachedStyle(b,'padding-right'),10);for(f in d){d[f].setWidth(e)}}}},onAdded:function(){var b=this,a;Ext.grid.column.Column.prototype.onAdded.apply(this,arguments);a=b.getView();if(a){b.setupViewListeners(a);if(a&&a.viewReady&&b.rendered&&a.getEl().down(b.getCellSelector())){b.onViewRefresh(a,a.getViewRange())}}},onRemoved:function(e){var a=this,c=a.liveWidgets,b=a.viewListeners,d;if(a.rendered){a.viewListeners=b&&Ext.destroy(b);if(!e){for(d in c){c[d].detachFromBody()}}}Ext.grid.column.Column.prototype.onRemoved.apply(this,arguments)},onDestroy:function(){var b=this,e=b.liveWidgets,d=b.freeWidgetStack,g,a,c,f;if(b.rendered){for(g in e){a=e[g];a.$widgetRecord=a.$widgetColumn=null;delete a.getWidgetRecord;delete a.getWidgetColumn;a.destroy()}for(c=0,f=d.length;c{text} {linkHrefCls}{childElCls}" href="{href}" target="{hrefTarget}" hidefocus="true" unselectable="on" tabindex="{tabIndex}" {$}="{.}">{text}',maskOnDisable:!1,iconAlign:'left',initComponent:function(){var a=this,b=a.cls?[a.cls]:[],c;if(a.hasOwnProperty('canActivate')){a.focusable=a.canActivate}if(a.plain){b.push('x-menu-item-plain')}if(b.length){a.cls=b.join(' ')}if(a.menu){c=a.menu;a.menu=null;a.setMenu(c)}Ext.Component.prototype.initComponent.apply(this,arguments)},canFocus:function(){var a=this;return a.focusable&&a.rendered&&a.canActivate!==!1&&!a.destroying&&!a.destroyed&&a.isVisible(!0)},onFocus:function(b){var a=this;Ext.Component.prototype.onFocus.call(this,b);if(!a.disabled){if(!a.plain){a.addCls(a.activeCls)}a.activated=!0;if(a.hasListeners.activate){a.fireEvent('activate',a)}}},onFocusLeave:function(b){var a=this;Ext.Component.prototype.onFocusLeave.call(this,b);if(a.activated){if(!a.plain){a.removeCls(a.activeCls)}a.doHideMenu();a.activated=!1;if(a.hasListeners.deactivate){a.fireEvent('deactivate',a)}}},doHideMenu:function(){var a=this.menu;this.cancelDeferExpand();if(a&&a.isVisible()){a.hide()}},deferHideParentMenus:function(){for(var a=this.getRefOwner();a&&(a.isMenu&&a.floating||a.isMenuItem);a=a.getRefOwner()){if(a.isMenu){a.hide()}}},expandMenu:function(c,b){var a=this;if(a.activated&&a.menu){a.hideOnClick=!1;a.cancelDeferHide();b=b==null?a.menuExpandDelay:b;if(b===0){a.doExpandMenu(c)}else {a.cancelDeferExpand();a.expandMenuTimer=Ext.defer(a.doExpandMenu,b,a,[c])}}},doExpandMenu:function(c){var b=this,a=b.menu;if(!a.isVisible()){b.parentMenu.activeChild=a;a.ownerCmp=b;a.parentMenu=b.parentMenu;a.constrainTo=document.body;a.autoFocus=!c||!c.pointerType;a.showBy(b,b.menuAlign)}},getRefItems:function(c){var b=this.menu,a;if(b){a=b.getRefItems(c);a.unshift(b)}return a||[]},getValue:function(){return this.value},hideMenu:function(b){var a=this;if(a.menu){a.cancelDeferExpand();a.hideMenuTimer=Ext.defer(a.doHideMenu,Ext.isNumber(b)?b:a.menuHideDelay,a)}},onClick:function(b){var a=this,e=a.clickHideDelay,f=b.browserEvent,d,c;if(!a.href||a.disabled){b.stopEvent();if(a.disabled){return !1}}if(a.disabled||a.handlingClick){return}if(a.hideOnClick){if(!e){a.deferHideParentMenus()}else {a.deferHideParentMenusTimer=Ext.defer(a.deferHideParentMenus,e,a)}}d=a.fireEvent('click',a,b);if(a.destroyed){return}if(d!==!1&&a.handler){Ext.callback(a.handler,a.scope,[a,b],0,a)}if(Ext.isIE9m){c=f.returnValue===!1?!0:!1}else {c=!!f.defaultPrevented}if(a.href&&b.type!=='click'&&!c){a.handlingClick=!0;a.itemEl.dom.click();a.handlingClick=!1}if(!a.hideOnClick){a.focus()}return d},onRemoved:function(){var a=this;if(a.activated&&a.parentMenu.activeItem===a){a.parentMenu.deactivateActiveItem()}Ext.Component.prototype.onRemoved.apply(this,arguments);a.parentMenu=a.ownerCmp=null},beforeDestroy:function(){var a=this;if(a.rendered){a.clearTip()}Ext.Component.prototype.beforeDestroy.call(this)},onDestroy:function(){var a=this;a.cancelDeferExpand();a.cancelDeferHide();clearTimeout(a.deferHideParentMenusTimer);a.setMenu(null);Ext.Component.prototype.onDestroy.apply(this,arguments)},beforeRender:function(){var a=this,c=a.glyph,j=Ext._glyphFontFamily,b=!!(a.icon||a.iconCls||c),f=!!a.menu,i=a.iconAlign==='right'&&!f,e=a.isMenuCheckItem,d=[],k=a.ownerCt,g=k.plain,h;if(a.plain){a.ariaEl='el'}Ext.Component.prototype.beforeRender.call(this);if(b){if(f&&a.showCheckbox){b=!1}}if(typeof c==='string'){h=c.split('@');c=h[0];j=h[1]}if(!g||b&&!i||e){if(k.showSeparator&&!g){d.push(a.indentCls)}else {d.push(a.indentNoSeparatorCls)}}if(f){d.push(a.indentRightArrowCls)}else {if(b&&(i||e)){d.push(a.indentRightIconCls)}}Ext.applyIf(a.renderData,{hasHref:!!a.href,href:a.href||'#',hrefTarget:a.hrefTarget,icon:a.icon,iconCls:a.iconCls,glyph:c,glyphCls:c?'x-menu-item-glyph':undefined,glyphFontFamily:j,hasIcon:b,hasMenu:f,indent:!g||b||e,isCheckItem:e,rightIcon:i,plain:a.plain,text:a.text,arrowCls:a.arrowCls,baseIconCls:a.baseIconCls,textCls:a.textCls,indentCls:d.join(' '),linkCls:a.linkCls,linkHrefCls:a.linkHrefCls,groupCls:a.group?a.groupCls:'',tabIndex:a.tabIndex})},onRender:function(){var a=this;Ext.Component.prototype.onRender.apply(this,arguments);if(a.tooltip){a.setTooltip(a.tooltip,!0)}},getMenu:function(){return this.menu||null},setMenu:function(b,f){var a=this,e=a.menu,h=a.arrowEl,d=a.ariaEl.dom,c,g;if(e){e.ownerCmp=e.parentMenu=null;if(f===!0||f!==!1&&a.destroyMenu){Ext.destroy(e)}if(d){d.removeAttribute('aria-haspopup');d.removeAttribute('aria-owns')}else {c=a.ariaRenderAttributes||(a.ariaRenderAttributes={});delete c['aria-haspopup'];delete c['aria-owns']}}if(b){g=b.isMenu;b=a.menu=Ext.menu.Manager.get(b,{ownerCmp:a,focusOnToFront:!1});b.setOwnerCmp(a,g);if(d){d.setAttribute('aria-haspopup',!0);d.setAttribute('aria-owns',b.id)}else {c=a.ariaRenderAttributes||(a.ariaRenderAttributes={});c['aria-haspopup']=!0;c['aria-owns']=b.id}}else {b=a.menu=null}if(b&&a.rendered&&!a.destroying&&h){h[b?'addCls':'removeCls'](a.arrowCls)}},setHandler:function(b,a){this.handler=b||null;this.scope=a},setIcon:function(a){var b=this.iconEl,c=this.icon;if(b){b.src=a||Ext.BLANK_IMAGE_URL}this.icon=a;this.fireEvent('iconchange',this,c,a)},setIconCls:function(b){var a=this,c=a.iconEl,d=a.iconCls;if(c){if(a.iconCls){c.removeCls(a.iconCls)}if(b){c.addCls(b)}}a.iconCls=b;a.fireEvent('iconchange',a,d,b)},setText:function(b){var a=this,d=a.textEl||a.el,c=a.text;a.text=b;if(a.rendered){d.setHtml(b||'');a.updateLayout()}a.fireEvent('textchange',a,c,b)},getTipAttr:function(){return this.tooltipType==='qtip'?'data-qtip':'title'},clearTip:function(){if(Ext.quickTipsActive&&Ext.isObject(this.tooltip)){Ext.tip.QuickTipManager.unregister(this.itemEl)}},setTooltip:function(b,c){var a=this;if(a.rendered){if(!c){a.clearTip()}if(Ext.quickTipsActive&&Ext.isObject(b)){Ext.tip.QuickTipManager.register(Ext.apply({target:a.itemEl.id},b));a.tooltip=b}else {a.itemEl.dom.setAttribute(a.getTipAttr(),b)}}else {a.tooltip=b}return a},privates:{cancelDeferExpand:function(){window.clearTimeout(this.expandMenuTimer)},cancelDeferHide:function(){window.clearTimeout(this.hideMenuTimer)},getFocusEl:function(){return this.plain?this.el:this.itemEl}}},0,['menuitem'],['component','box','menuitem'],{'component':!0,'box':!0,'menuitem':!0},['widget.menuitem'],[[Ext.mixin.Queryable.prototype.mixinId||Ext.mixin.Queryable.$className,Ext.mixin.Queryable]],[Ext.menu,'Item',Ext.menu,'TextItem'],0);Ext.cmd.derive('Ext.menu.CheckItem',Ext.menu.Item,{checkedCls:'x-menu-item-checked',uncheckedCls:'x-menu-item-unchecked',groupCls:'x-menu-group-icon',hideOnClick:!1,checkChangeDisabled:!1,submenuText:'{0} submenu',ariaRole:'menuitemcheckbox',childEls:['checkEl'],showCheckbox:!0,isMenuCheckItem:!0,checkboxCls:'x-menu-item-checkbox',initComponent:function(){var a=this;a.checked=!!a.checked;Ext.menu.Item.prototype.initComponent.apply(this,arguments);if(a.group){Ext.menu.Manager.registerCheckable(a);if(a.initialConfig.hideOnClick!==!1){a.hideOnClick=!0}}},beforeRender:function(){var a=this,b;Ext.menu.Item.prototype.beforeRender.call(this);Ext.apply(a.renderData,{checkboxCls:a.checkboxCls,showCheckbox:a.showCheckbox});b=a.ariaRenderAttributes||(a.ariaRenderAttributes={});b['aria-checked']=a.menu?'mixed':a.checked;if(a.menu){b['aria-label']=Ext.String.formatEncode(a.submenuText,a.text)}},afterRender:function(){var a=this;Ext.menu.Item.prototype.afterRender.call(this);a.checked=!a.checked;a.setChecked(!a.checked,!0);if(a.checkChangeDisabled){a.disableCheckChange()}if(Ext.isGecko&&a.checkEl){a.checkEl.on('mousedown',a.onMouseDownCheck)}},disableCheckChange:function(){var a=this,b=a.checkEl;if(b){b.addCls(a.disabledCls)}if(Ext.isIE8&&a.rendered){a.el.repaint()}a.checkChangeDisabled=!0},enableCheckChange:function(){var a=this,b=a.checkEl;if(b){b.removeCls(a.disabledCls)}a.checkChangeDisabled=!1},onMouseDownCheck:function(a){a.preventDefault()},onClick:function(b){var a=this;if(!(a.disabled||a.checkChangeDisabled||a.checked&&a.group||a.menu&&'touch'===b.pointerType&&!a.checkEl.contains(b.target))){a.setChecked(!a.checked);if(b.type==='keydown'&&a.menu){return !1}}Ext.menu.Item.prototype.onClick.call(this,b)},onDestroy:function(){Ext.menu.Manager.unregisterCheckable(this);Ext.menu.Item.prototype.onDestroy.apply(this,arguments)},setText:function(c){var a=this,b=a.ariaEl.dom;Ext.menu.Item.prototype.setText.call(this,c);if(b&&a.menu){b.setAttribute('aria-label',Ext.String.formatEncode(a.submenuText,c))}},setChecked:function(b,d){var a=this,f=a.checkedCls,e=a.uncheckedCls,c=a.el,g=a.ariaEl.dom;if(a.checked!==b&&(d||a.fireEvent('beforecheckchange',a,b)!==!1)){if(c){if(b){c.addCls(f);c.removeCls(e)}else {c.addCls(e);c.removeCls(f)}}if(g){g.setAttribute('aria-checked',a.menu?'mixed':!!b)}a.checked=b;Ext.menu.Manager.onCheckChange(a,b);if(!d){Ext.callback(a.checkHandler,a.scope,[a,b],0,a);a.fireEvent('checkchange',a,b)}}}},0,['menucheckitem'],['component','box','menuitem','menucheckitem'],{'component':!0,'box':!0,'menuitem':!0,'menucheckitem':!0},['widget.menucheckitem'],0,[Ext.menu,'CheckItem'],0);Ext.cmd.derive('Ext.menu.Separator',Ext.menu.Item,{focusable:!1,canActivate:!1,hideOnClick:!1,plain:!0,separatorCls:'x-menu-item-separator',text:' ',ariaRole:'separator',beforeRender:function(){this.addCls(this.separatorCls);Ext.menu.Item.prototype.beforeRender.call(this)}},0,['menuseparator'],['component','box','menuitem','menuseparator'],{'component':!0,'box':!0,'menuitem':!0,'menuseparator':!0},['widget.menuseparator'],0,[Ext.menu,'Separator'],0);Ext.define('Ext.theme.neptune.menu.Separator',{override:'Ext.menu.Separator',border:!0});Ext.cmd.derive('Ext.menu.Menu',Ext.panel.Panel,{enableKeyNav:!0,allowOtherMenus:!1,ariaRole:'menu',floating:!0,constrain:!0,hidden:!0,hideMode:'visibility',ignoreParentClicks:!1,isMenu:!0,showSeparator:!0,minWidth:undefined,defaultMinWidth:120,defaultAlign:'tl-bl?',focusOnToFront:!1,bringParentToFront:!1,defaultFocus:':focusable',menuClickBuffer:0,baseCls:'x-menu',_iconSeparatorCls:'x-menu-icon-separator',_itemCmpCls:'x-menu-item-cmp',layout:{type:'vbox',align:'stretchmax',overflowHandler:'Scroller'},initComponent:function(){var a=this,d=['x-menu'],c=a.bodyCls?[a.bodyCls]:[],e=a.floating!==!1,b={element:'el',click:a.onClick,mouseover:a.onMouseOver,scope:a};if(Ext.supports.Touch){b.pointerdown=a.onMouseOver}a.on(b);a.on({beforeshow:a.onBeforeShow,scope:a});if(a.plain){d.push('x-menu-plain')}a.cls=d.join(' ');c.push('x-menu-body',Ext.dom.Element.unselectableCls);a.bodyCls=c.join(' ');if(e){if(a.minWidth===undefined){a.minWidth=a.defaultMinWidth}}else {a.hidden=!!a.initialConfig.hidden;a.constrain=!1}Ext.panel.Panel.prototype.initComponent.apply(this,arguments);Ext.override(a.getLayout(),{configureItem:a.configureItem})},initFloatConstrain:Ext.emptyFn,getInherited:function(){var a=Ext.panel.Panel.prototype.getInherited.call(this);a.hidden=this.hidden;return a},beforeRender:function(){var a=this;Ext.panel.Panel.prototype.beforeRender.apply(this,arguments);if(!a.getSizeModel().width.shrinkWrap){a.layout.align='stretch'}if(a.floating){a.ariaRenderAttributes=a.ariaRenderAttributes||{};a.ariaRenderAttributes['aria-expanded']=!!a.autoShow}},onBoxReady:function(){var a=this,c=a._iconSeparatorCls,b=a.focusableKeyNav;if(b){b.map.processEventScope=a;b.map.processEvent=function(a){if(a.keyCode===a.ESC){a.target=this.el.dom}return a};b.map.addBinding([{key:Ext.event.Event.ESC,handler:a.onEscapeKey,scope:a},{key:/[\w]/,handler:a.onShortcutKey,scope:a,shift:!1,ctrl:!1,alt:!1}])}else {a.escapeKeyNav=new Ext.util.KeyNav(a.el,{eventName:'keydown',scope:a,esc:a.onEscapeKey})}Ext.panel.Panel.prototype.onBoxReady.apply(this,arguments);if(a.showSeparator){a.iconSepEl=a.body.insertFirst({role:'presentation',cls:c+' '+c+'-'+a.ui,html:' '})}if(Ext.supports.MSPointerEvents||Ext.supports.PointerEvents){a.el.on({scope:a,click:a.preventClick,translate:!1})}a.mouseMonitor=a.el.monitorMouseLeave(100,a.onMouseLeave,a)},onFocusLeave:function(b){var a=this;Ext.panel.Panel.prototype.onFocusLeave.call(this,b);a.mixins.focusablecontainer.onFocusLeave.call(a,b);if(a.floating){a.hide()}},canActivateItem:function(a){return a&&a.isFocusable()},deactivateActiveItem:function(){var b=this,a=b.lastFocusedChild;if(a){a.blur()}},getItemFromEvent:function(d){var c=this,b=c.layout.getRenderTarget().dom,a=d.getTarget();while(a.parentNode!==b){a=a.parentNode;if(!a){return}}return Ext.getCmp(a.id)},lookupComponent:function(a){var b=this;if(typeof a==='string'){a=b.lookupItemFromString(a)}else {if(Ext.isObject(a)){a=b.lookupItemFromObject(a)}}if(!a.dock){a.minWidth=a.minWidth||b.minWidth}return a},lookupItemFromObject:function(a){var b=this;if(!a.isComponent){if(!a.xtype){a=Ext.create('Ext.menu.'+(Ext.isBoolean(a.checked)?'Check':'')+'Item',a)}else {a=Ext.ComponentManager.create(a,a.xtype)}}if(a.isMenuItem){a.parentMenu=b}return a},lookupItemFromString:function(a){return a==='separator'||a==='-'?new Ext.menu.Separator():new Ext.menu.Item({canActivate:!1,hideOnClick:!1,plain:!0,text:a})},configureItem:function(a){var c=this.owner,f='x-',e=c.ui,b,d;if(a.isMenuItem){a.setUI(e)}else {if(c.items.getCount()>1&&!a.rendered&&!a.dock){d=c._itemCmpCls;b=[d+' '+d+'-'+e];if(!c.plain&&(a.indent!==!1||a.iconCls==='no-icon')){b.push(f+'menu-item-indent-'+e)}if(a.rendered){a.el.addCls(b)}else {a.cls=(a.cls||'')+' '+b.join(' ')}a.$extraMenuCls=b}}this.callParent(arguments)},onRemove:function(a){Ext.panel.Panel.prototype.onRemove.call(this,a);if(!a.destroyed&&a.$extraMenuCls){a.el.removeCls(a.$extraMenuCls)}},onClick:function(b){var c=this,f=b.type,a,d,e=f==='keydown';if(c.disabled){b.stopEvent();return}a=c.getItemFromEvent(b);if(a&&a.isMenuItem){if(!a.menu||!c.ignoreParentClicks){d=a.onClick(b)}else {b.stopEvent()}if(a.menu&&d!==!1&&e){a.expandMenu(b,0)}}if(!a||a.disabled){a=undefined}c.fireEvent('click',c,a,b)},onDestroy:function(){var a=this;if(a.escapeKeyNav){a.escapeKeyNav.destroy()}a.parentMenu=a.ownerCmp=a.escapeKeyNav=null;if(a.rendered){a.el.un(a.mouseMonitor);Ext.destroy(a.iconSepEl)}Ext.menu.Manager.onHide(a);Ext.panel.Panel.prototype.onDestroy.apply(this,arguments)},onMouseLeave:function(a){if(this.disabled){return}this.fireEvent('mouseleave',this,a)},onMouseOver:function(c){var a=this,g=c.getRelatedTarget(),e=!a.el.contains(g),b=a.getItemFromEvent(c),d=a.parentMenu,f=a.ownerCmp;if(e&&d){d.setActiveItem(f);f.cancelDeferHide();d.mouseMonitor.mouseenter()}if(a.disabled){return}if(b){if(!b.containsFocus){b.focus()}if(b.expandMenu){b.expandMenu(c)}}if(e){a.fireEvent('mouseenter',a,c)}a.fireEvent('mouseover',a,b,c)},setActiveItem:function(a){var b=this;if(a&&a!==b.lastFocusedChild){b.focusChild(a,1)}},onEscapeKey:function(){if(this.floating){this.hide()}},onShortcutKey:function(h,g){var e=String.fromCharCode(g.getCharCode()),c=this.query('>[text]'),f=c.length,a=this.lastFocusedChild,d=Ext.Array.indexOf(c,a),b=d;for(;;){if(++b===f){b=0}a=c[b];if(b===d){return}if(a.text&&a.text[0].toUpperCase()===e){a.focus();return}}},onFocusableContainerTabKey:function(a){if(this.floating){this.hide()}},onFocusableContainerEnterKey:function(a){this.onClick(a)},onFocusableContainerSpaceKey:function(a){this.onClick(a)},onFocusableContainerLeftKey:function(a){a.preventDefault();if(this.parentMenu){this.ownerCmp.focus();this.hide()}},onFocusableContainerRightKey:function(b){var c=this,a=c.lastFocusedChild;b.preventDefault();if(a&&a.expandMenu){a.expandMenu(b,0)}},onBeforeShow:function(){if(Ext.Date.getElapsed(this.lastHide)tablepanel:not(hidden)>tableview');if(a){a.focus()}},focusRow:function(c){var b,a=this.getNavigationModel().lastFocused;b=a?a.view:this.normalView;b.focusRow(c)},focusCell:function(a){a.view.focusCell(a)},onRowFocus:function(){this.relayFn('onRowFocus',arguments)},isVisible:function(a){return this.ownerGrid.isVisible(a)},getFocusEl:function(){var b,a=this.getNavigationModel().lastFocused;b=a?a.view:this.normalView;return b.getFocusEl()},getCellInclusive:function(a,c){var d=a.column,b=this.lockedGrid.getColumnManager().getColumns().length;if(d>=b){a=Ext.apply({},a);a.column-=b;return this.normalView.getCellInclusive(a,c)}else {return this.lockedView.getCellInclusive(a,c)}},getHeaderByCell:function(a){if(a){return this.getVisibleColumnManager().getHeaderById(a.getAttribute('data-columnId'))}return !1},onRowSelect:function(){this.relayFn('onRowSelect',arguments)},onRowDeselect:function(){this.relayFn('onRowDeselect',arguments)},onCellSelect:function(a){a.column.getView().onCellSelect({record:a.record,column:a.column})},onCellDeselect:function(a){a.column.getView().onCellDeselect({record:a.record,column:a.column})},getCellByPosition:function(a,c){var e=this,b=a.view,d=a.column;if(b===e){a=(new Ext.grid.CellContext(d.getView())).setPosition(a.record,a.column)}return b.getCellByPosition(a,c)},getRecord:function(b){var a=this.lockedView.getRecord(b);if(!a){a=this.normalView.getRecord(b)}return a},scrollBy:function(){var a=this.normalView;a.scrollBy.apply(a,arguments)},ensureVisible:function(){var a=this.normalView;a.ensureVisible.apply(a,arguments)},disable:function(){this.relayFn('disable',arguments)},enable:function(){this.relayFn('enable',arguments)},addElListener:function(){this.relayFn('addElListener',arguments)},refreshNode:function(){this.relayFn('refreshNode',arguments)},addRowCls:function(){this.relayFn('addRowCls',arguments)},removeRowCls:function(){this.relayFn('removeRowCls',arguments)},destroy:function(){var a=this;a.rendered=!1;a.bindStore(null,!1,'dataSource');Ext.destroy(a.lockedViewEventRelayers,a.normalViewEventRelayers);a.lockedViewEventRelayers=a.normalViewEventRelayers=null;a.callParent();Ext.destroy(a.loadMask,a.navigationModel,a.selModel);a.lockedView.lockingPartner=a.normalView.lockingPartner=null;a.lockedGrid=a.lockedView=a.normalGrid=a.normalView=null;a.loadMask=a.navigationModel=a.selModel=a.headerCt=null;a.ownerGrid=a.storeListeners=null}},1,0,0,0,0,[[Ext.util.Observable.prototype.mixinId||Ext.util.Observable.$className,Ext.util.Observable],[Ext.util.StoreHolder.prototype.mixinId||Ext.util.StoreHolder.$className,Ext.util.StoreHolder],[Ext.util.Focusable.prototype.mixinId||Ext.util.Focusable.$className,Ext.util.Focusable]],[Ext.grid.locking,'View',Ext.grid,'LockingView'],function(){this.borrow(Ext.Component,['up']);this.borrow(Ext.view.AbstractView,['doFirstRefresh','applyFirstRefresh']);this.borrow(Ext.view.Table,['cellSelector','selectedCellCls','selectedItemCls'])});Ext.cmd.derive('Ext.grid.locking.Lockable',Ext.Base,{alternateClassName:'Ext.grid.Lockable',syncRowHeight:!0,headerCounter:0,scrollDelta:40,lockedGridCls:'x-grid-inner-locked',normalGridCls:'x-grid-inner-normal',lockingBodyCls:'x-grid-locking-body',unlockText:'Unlock',lockText:'Lock',bothCfgCopy:['hideHeaders','enableColumnHide','enableColumnMove','enableColumnResize','sortableColumns','multiColumnSort','columnLines','rowLines','variableRowHeight','numFromEdge','trailingBufferZone','leadingBufferZone','scrollToLoadBuffer','syncRowHeight'],normalCfgCopy:['scroll'],lockedCfgCopy:[],determineXTypeToCreate:function(g){var f=this,a,b,d,e,c;if(f.subGridXType){a=f.subGridXType}else {if(!g){return 'gridpanel'}b=this.getXTypes().split('/');d=b.length;e=b[d-1];c=b[d-2];if(c!=='tablepanel'){a=c}else {a=e}}return a},injectLockable:function(){this.focusable=!1;this.lockable=!0;this.hasView=!0;var a=this,q=Ext.getScrollbarSize(),l=q.width,o=a.store=Ext.StoreManager.lookup(a.store),d=a.lockedViewConfig,g=a.normalViewConfig,s=Ext.Object,m,i,b,c,e,n,f,h,j=a.viewConfig,r=j&&j.loadMask,u=r!==undefined?r:a.loadMask,p=a.bufferedRenderer,k=l>0&&Ext.supports.touchScroll!==2,t=a.getInherited().rtl;m=a.constructLockableFeatures();a.features=null;i=a.constructLockablePlugins();a.plugins=i.topPlugins;b={id:a.id+'-locked',$initParent:a,isLocked:!0,bufferedRenderer:p,ownerGrid:a,ownerLockable:a,xtype:a.determineXTypeToCreate(!0),store:o,reserveScrollbar:k,scrollable:{indicators:{x:!0,y:!1}},scrollerOwner:!1,animate:!1,border:!1,cls:a.lockedGridCls,isLayoutRoot:function(){return this.floatedFromCollapse||a.normalGrid.floatedFromCollapse},features:m.lockedFeatures,plugins:i.lockedPlugins};c={id:a.id+'-normal',$initParent:a,isLocked:!1,bufferedRenderer:p,ownerGrid:a,ownerLockable:a,xtype:a.determineXTypeToCreate(),store:o,reserveScrollbar:a.reserveScrollbar,scrollerOwner:!1,border:!1,cls:a.normalGridCls,isLayoutRoot:function(){return this.floatedFromCollapse||a.lockedGrid.floatedFromCollapse},features:m.normalFeatures,plugins:i.normalPlugins};a.addCls('x-grid-locked');Ext.copy(c,a,a.bothCfgCopy,!0);Ext.copy(b,a,a.bothCfgCopy,!0);Ext.copy(c,a,a.normalCfgCopy,!0);Ext.copy(b,a,a.lockedCfgCopy,!0);Ext.apply(c,a.normalGridConfig);Ext.apply(b,a.lockedGridConfig);for(e=0;e>#normalHeaderCt',items:e},j={itemId:'normalHeaderCt',stretchMaxPartner:'^^>>#lockedHeaderCt',items:f},l={locked:i,normal:j},g;if(Ext.isObject(b)){Ext.applyIf(i,b);Ext.applyIf(j,b);g=Ext.apply({},b);delete g.items;Ext.apply(c,g);b=b.items}c.constructing=!0;for(d=0,k=b.length;d0&&f){h.stopEvent();a+=e;d.setScrollY(a);b.normalGrid.getView().setScrollY(a);b.onNormalViewScroll()}}},onLockedViewScroll:function(){var f=this,e=f.lockedGrid.getView(),a=f.normalGrid.getView(),c=e.getScrollY(),g=a.getScrollY(),b,d;if(g!==c){a.setScrollY(c);if(a.bufferedRenderer){d=e.body.dom;b=a.body.dom;b.style.position='absolute';b.style.top=d.style.top}}},onNormalViewScroll:function(){var e=this,b=e.lockedGrid.getView(),c=e.normalGrid.getView(),f=b.getScrollY(),d=c.getScrollY(),a;if(d!==f){b.setScrollY(d);if(c.bufferedRenderer){a=b.body;if(a.dom){a.dom.style.position='absolute';a.translate(null,c.bufferedRenderer.bodyTop)}}}},syncRowHeights:function(){if(!this.destroyed){var f=this,b=f.normalGrid.getView(),a=f.lockedGrid.getView(),d=b.syncRowHeightBegin(),c=a.syncRowHeightBegin(),e;b.syncRowHeightMeasure(d);a.syncRowHeightMeasure(c);b.syncRowHeightFinish(d,c);a.syncRowHeightFinish(c,d);e=b.getScrollY();a.setScrollY(e)}},modifyHeaderCt:function(){var a=this;a.lockedGrid.headerCt.getMenuItems=a.getMenuItems(a.lockedGrid.headerCt.getMenuItems,!0);a.normalGrid.headerCt.getMenuItems=a.getMenuItems(a.normalGrid.headerCt.getMenuItems,!1);a.lockedGrid.headerCt.showMenuBy=Ext.Function.createInterceptor(a.lockedGrid.headerCt.showMenuBy,a.showMenuBy);a.normalGrid.headerCt.showMenuBy=Ext.Function.createInterceptor(a.normalGrid.headerCt.showMenuBy,a.showMenuBy)},onUnlockMenuClick:function(){this.unlock()},onLockMenuClick:function(){this.lock()},showMenuBy:function(f,g,c){var d=this.getMenu(),a=d.down('#unlockItem'),b=d.down('#lockItem'),e=a.prev();if(c.lockable===!1){e.hide();a.hide();b.hide()}else {e.show();a.show();b.show();if(!a.initialConfig.disabled){a.setDisabled(c.lockable===!1)}if(!b.initialConfig.disabled){b.setDisabled(!c.isLockable())}}},getMenuItems:function(d,b){var a=this,f=a.unlockText,h=a.lockText,g='x-hmenu-unlock',i='x-hmenu-lock',c=a.onUnlockMenuClick.bind(a),e=a.onLockMenuClick.bind(a);return function(){var a=d.call(this);a.push('-',{itemId:'unlockItem',iconCls:g,text:f,handler:c,disabled:!b});a.push({itemId:'lockItem',iconCls:i,text:h,handler:e,disabled:b});return a}},delaySyncLockedWidth:function(){var a=this,b=a.syncLockedWidthTask;if(!a.view.all.getCount()){return}if(!b){b=a.syncLockedWidthTask=new Ext.util.DelayedTask(a.syncLockedWidth,a)}b.delay(1)},syncLockedWidth:function(){var b=this,c=b.rendered,a=b.lockedGrid,g=a.view,d=b.normalGrid,e=a.getVisibleColumnManager().getColumns().length,f=d.getVisibleColumnManager().getColumns().length,h=b.syncLockedWidthTask;if(h){h.cancel()}Ext.suspendLayouts();if(f){d.show();if(e){if(c&&a.shrinkWrapColumns&&!a.headerCt.forceFit){delete a.flex;a.setWidth(a.headerCt.getTableWidth()+a.gridPanelBorderWidth)}a.addCls(b.lockedGridCls);a.show();if(a.split){b.child('splitter').show();b.addCls('x-grid-locked-split')}}else {if(c){a.getView().clearViewEl(!0)}a.hide();if(a.split){b.child('splitter').hide();b.removeCls('x-grid-locked-split')}}if(Ext.supports.touchScroll!==2&&Ext.Component.pendingLayouts){g.getScrollable().setX(!0)}if(c){b.ignoreMousewheel=g.scrollFlags.y}}else {d.hide();a.flex=1;delete a.width;a.removeCls(b.lockedGridCls);a.show();b.ignoreMousewheel=!0}Ext.resumeLayouts(!0);return [e,f]},onLockedHeaderSortChange:Ext.emptyFn,onNormalHeaderSortChange:Ext.emptyFn,lock:function(a,l,g){var e=this,i=e.normalGrid,b=e.lockedGrid,d=i.view,c=b.view,m=i.headerCt,h,k,j,f;a=a||m.getMenu().activeHeader;j=a.hasFocus;g=g||b.headerCt;k=a.ownerCt;if(!a.isLockable()){return}if(a.flex&&b.shrinkWrapColumns){a.width=a.getWidth();a.flex=null}Ext.suspendLayouts();if(b.hidden){if(!b.componentLayoutCounter){if(c.bufferedRenderer){c.bufferedRenderer.onViewResize(c,0,d.getHeight())}f=d.getScrollY()}b.show()}d.blockRefresh=c.blockRefresh=!0;a.ownerCmp=a.ownerCt;k.remove(a,!1);a.locked=!0;if(Ext.isDefined(l)){g.insert(l,a)}else {g.add(a)}d.blockRefresh=c.blockRefresh=!1;a.ownerCmp=null;h=e.syncLockedWidth();if(h[0]){b.getView().refreshView()}if(h[1]){i.getView().refreshView()}e.fireEvent('lockcolumn',e,a);Ext.resumeLayouts(!0);if(f){c.setScrollY(f);d.setScrollY(f)}if(j){a.focus()}},unlock:function(a,f,g){var b=this,e=b.normalGrid,d=b.lockedGrid,i=e.view,h=d.view,k=d.headerCt,c,j;if(!Ext.isDefined(f)){f=0}a=a||k.getMenu().activeHeader;j=a.hasFocus;g=g||e.headerCt;Ext.suspendLayouts();i.blockRefresh=h.blockRefresh=!0;a.ownerCmp=a.ownerCt;a.ownerCt.remove(a,!1);a.locked=!1;g.insert(f,a);i.blockRefresh=h.blockRefresh=!1;a.ownerCmp=null;c=b.syncLockedWidth();if(c[0]){d.getView().refreshView()}if(c[1]){e.getView().refreshView()}b.fireEvent('unlockcolumn',b,a);Ext.resumeLayouts(!0);if(j){a.focus()}},reconfigureLockable:function(a,f){var d=this,h=d.store,c=d.lockedGrid,e=d.normalGrid,b,g;if(a&&a!==h){a=Ext.data.StoreManager.lookup(a);d.store=a;c.view.blockRefresh=e.view.blockRefresh=!0;c.bindStore(a);b=c.view;b.store=a;if(!b.dataSource.isFeatureStore){b.dataSource=a}if(b.bufferedRenderer){b.bufferedRenderer.bindStore(a)}e.bindStore(a);b=e.view;b.store=a;if(!b.dataSource.isFeatureStore){b.dataSource=a}if(b.bufferedRenderer){b.bufferedRenderer.bindStore(a)}d.view.store=a;g=d.view.loadMask;if(g&&g.isLoadMask){g.bindStore(a)}d.view.bindStore(e.view.dataSource,!1,'dataSource');c.view.blockRefresh=e.view.blockRefresh=!1}if(f){c.reconfiguring=e.reconfiguring=!0;c.headerCt.removeAll();e.headerCt.removeAll();f=d.processColumns(f,c);c.headerCt.add(f.locked.items);e.headerCt.add(f.normal.items);c.reconfiguring=e.reconfiguring=!1;d.syncLockedWidth()}d.refreshCounter=c.view.refreshCounter},afterReconfigureLockable:function(){var a=this.lockedGrid.getView();if(this.refreshCounter===a.refreshCounter){this.view.refresh()}},constructLockableFeatures:function(){var b=this.features,a,e,c,d,f=0,g;if(b){if(!Ext.isArray(b)){b=[b]}c=[];d=[];g=b.length;for(;f0){a.onViewResize(b,null,e);if(c&&d.getCount()!==c.length){c.length=0;c.push.apply(c,a.store.getRange(d.startIndex,d.endIndex))}}}},beforeTableLayout:function(b){var a=this.view.body.dom;if(a){b.bodyHeight=a.offsetHeight;b.bodyWidth=a.offsetWidth}},afterTableLayout:function(d){var a=this,b=a.view,c;if(d.bodyHeight&&b.body.dom){delete a.rowHeight;a.refreshSize();c=b.body.dom.offsetHeight;if(c!==d.bodyHeight){a.onViewResize(b,null,b.el.lastBox.height);if(c=a.store.getCount()){a.setBodyTop(0)}else {if(a.bodyTop>a.scrollTop||a.bodyTop+cb){a.position=a.scrollTop=Math.max(b-a.bodyHeight,0);c.setScrollY(a.scrollTop)}if(a.bodyTop>b){c.body.translate(null,a.bodyTop=a.position)}if(c.getScrollable()){a.refreshScroller(c,b)}},refreshScroller:function(b,c){var a=b.getScrollable();if(a){if(a.setElementSize){a.setElementSize()}a.setSize({x:b.headerCt.getTableWidth(),y:c})}},setViewSize:function(c,o){var a=this,h=a.store,g=a.view,d=g.all,j=d.getCount(),e,f,b=a.view.lockingPartner&&a.view.lockingPartner.bufferedRenderer,i=j-c,n,m,l,k;if(b&&!o&&b.view.componentLayoutCounter){if(b.viewSize>c){c=b.viewSize}else {b.setViewSize(c,!0)}}i=j-c;if(i){a.scrollTop=g.getScrollY();a.viewSize=c;if(h.isBufferedStore){h.setViewSize(c)}if(j){k=h.getCount();e=d.startIndex;f=Math.min(e+c-1,k-1);if(e===d.startIndex&&f===d.endIndex){if(i<0){a.handleViewScroll(-1)}}else {if(b){b.disable()}if(i<0){if(k>j){h.getRange(d.endIndex+1,f,{callback:function(b,d){l=g.doAdd(b,d);g.fireEvent('itemadd',b,d,l);a.setBodyTop(a.bodyTop)}})}else {a.refreshView(0)}}else {e=d.endIndex-(i-1);f=d.endIndex;m=d.slice(e,f+1);d.removeRange(e,f,!0);if(g.hasListeners.itemremove){n=h.getRange(e,f);g.fireEvent('itemremove',n,e,m)}a.setBodyTop(a.bodyTop)}if(b){b.enable()}}}}return c},getViewRange:function(){var d=this,c=d.view.all,a=d.store,b=0;if(c.getCount()){b=c.startIndex}else {if(a.isBufferedStore){if(!a.currentPage){a.currentPage=1}b=c.startIndex=(a.currentPage-1)*(a.pageSize||1);a.currentPage=1}}if(a.data.getCount()){return a.getRange(b,b+(d.viewSize||a.defaultViewSize)-1)}else {return []}},onReplace:function(l,d,j,k){var a=this,c=a.view,b=c.all,i,g=b.getCount(),h=d+j.length-1,e=k.length-j.length,f=e*a.rowHeight;if(d>=b.startIndex+a.viewSize){a.refreshSize();return}if(g&&h=a.viewSize){b.moveBlock(e);a.refreshSize();i=b.startIndex;if(e>0){a.doNotMirror=!0;a.handleViewScroll(-1);a.doNotMirror=!1}if(b.startIndex===i){if(b.startIndex){a.setBodyTop(a.bodyTop+=f);c.suspendEvent('scroll');c.scrollBy(0,f);c.resumeEvent('scroll');a.position=a.scrollTop=c.getScrollY()}}else {c.suspendEvent('scroll');c.scrollBy(0,(i-b.startIndex)*a.rowHeight);c.resumeEvent('scroll')}c.refreshSize(b.getCount()!==g);return}if(g&&d>b.endIndex){a.refreshSize();if(e>0){a.onRangeFetched(null,b.startIndex,Math.min(l.getCount(),b.startIndex+a.viewSize)-1,null,!0)}c.refreshSize(b.getCount()!==g);return}if(d0?1:-1;if(Math.abs(c)>=20||b!==a.lastScrollDirection){a.lastScrollDirection=b;a.handleViewScroll(a.lastScrollDirection)}}},onViewScrollEnd:function(){if(this.needsPointerEventsFix){this.view.body.dom.style.pointerEvents=''}},handleViewScroll:function(h){var a=this,d=a.view.all,g=a.store,f=a.viewSize,e=g.getCount()-1,b,c;if(h===-1){if(d.startIndex){if(a.topOfViewCloseToEdge()){b=Math.max(0,a.getLastVisibleRowIndex()+a.trailingBufferZone-f)}}}else {if(d.endIndexa.scrollTop-a.numFromEdge*a.rowHeight}else {return a.getFirstVisibleRowIndex()-a.view.all.startIndexd){a=c-d+1}}}if(a===0&&c===0&&e===0){b.doRefreshView([],0,0)}else {g.getRange(a,c,{callback:b.doRefreshView,scope:b})}},doRefreshView:function(i,h,p,q){var a=this,b=a.view,c=b.all,l=c.startIndex,m=c.endIndex,e,f,n=c.getCount(),o,k=h!==c.startIndex,g,d,j;if(b.refreshCounter){if(b.hasListeners.beforerefresh&&b.fireEvent('beforerefresh',b)===!1){return}b.refreshing=a.refreshing=!0;j=b.saveFocusState();b.clearViewEl(!0);b.refreshCounter++;if(i.length){o=b.doAdd(i,h);if(k){e=c.item(l,!0);f=c.item(m,!0);if(e){d=-e.offsetTop}else {if(f){d=c.last(!0).offsetTop-f.offsetTop}}if(d){a.bodyTop=Math.max(a.bodyTop+d,0);a.scrollTop=a.bodyTop?a.scrollTop+d:0}else {a.bodyTop=g=h*a.rowHeight;a.scrollTop=Math.max(g-a.rowHeight*(gc.endIndex){r=c.startIndex-e;b.clearViewEl(!0);g=b.doAdd(h,e);b.fireEvent('itemadd',h,e,g);for(o=0;oc.endIndex||jp){d=a.scrollTop-a.rowHeight*p}}b.clearViewEl(!0);a.teleported=!1}if(!c.getCount()){g=b.doAdd(h,e);b.fireEvent('itemadd',h,e,g)}else {if(j>c.endIndex){l=Math.max(e-c.startIndex,0);if(k){i=c.item(c.startIndex+l,!0).offsetTop}g=c.scroll(Ext.Array.slice(h,c.endIndex+1-e),1,l);if(k){d=a.bodyTop+i}else {d=m}}else {l=Math.max(c.endIndex-j,0);u=c.startIndex;g=c.scroll(Ext.Array.slice(h,0,c.startIndex-e),-1,l);if(k){d=a.bodyTop-c.item(u,!0).offsetTop;if(!c.startIndex){if(d){b.setScrollY(a.position=a.scrollTop-=d);d=0}}else {if(d<0){i=c.startIndex*a.rowHeight;b.setScrollY(a.position=a.scrollTop+=i);d=a.bodyTop+i}}}else {d=m}}}a.position=a.scrollTop}if(t&&!v.contains(q)){n=b.actionableMode?b.actionPosition:b.lastFocused;if(n&&n.column){b.onFocusLeave({});n.column.focus()}}d=Math.max(Math.floor(d),0);if(b.positionBody){a.setBodyTop(d)}if(g&&f&&!f.disabled){f.scrollTop=f.position=a.scrollTop;if(f.view.ownerCt.isVisible()){s=f.onRangeFetched(null,e,j,x,!0);if(b.ownerGrid.syncRowHeight||f.variableRowHeight!==k){a.syncRowHeights(g,s);a.bodyHeight=b.body.dom.offsetHeight}}if(f.bodyTop!==d){f.setBodyTop(d)}f.view.setScrollY(a.scrollTop)}return g},syncRowHeights:function(b,e){var d=this,c=0,f=1,i=[],h=[],j=Ext.grid.locking.RowSynchronizer,a,g;if(b&&e){c=b.length;f=e.length}if(c!==f){b=d.view.all.slice();e=d.view.lockingPartner.all.slice();c=f=b.length}for(a=0;ae||i+a.bodyHeightc||j+a.bodyHeightc){return a.getLastVisibleRowIndex(f,b-1,e,c)}k=i+l[b].offsetHeight;if(k>=c){return b}else {if(b!==d){return a.getLastVisibleRowIndex(b+1,d,e,c)}}}return a.getFirstVisibleRowIndex()+Math.ceil(h/a.rowHeight)},getScrollHeight:function(){var a=this,j=a.view,d=j.all,i=a.store,c=i.getCount(),g=d.getCount(),h,f,e,b;if(!c){return 0}if(!a.hasOwnProperty('rowHeight')){if(g){if(a.variableRowHeight){a.rowHeight=Math.floor(a.bodyHeight/g)}else {h=d.first();f=h.getHeight();if(Ext.isIE8){e=h.getBorderWidth('b');if(e>0){f-=e}}a.rowHeight=f}}else {delete a.rowHeight}}if(a.variableRowHeight){if(d.endIndex===c-1){b=a.bodyTop+a.bodyHeight-1}else {b=Math.floor((c-g)*a.rowHeight)+a.bodyHeight;b+=a.bodyTop-d.startIndex*a.rowHeight}}else {b=Math.floor(c*a.rowHeight)}return a.scrollHeight=b},attemptLoad:function(b,c){var a=this;if(a.scrollToLoadBuffer){if(!a.loadTask){a.loadTask=new Ext.util.DelayedTask(a.doAttemptLoad,a,[])}a.loadTask.delay(a.scrollToLoadBuffer,a.doAttemptLoad,a,[b,c])}else {a.doAttemptLoad(b,c)}},cancelLoad:function(){if(this.loadTask){this.loadTask.cancel()}},doAttemptLoad:function(b,c){var a=this;if(!a.destroyed){a.store.getRange(b,c,{loadId:++a.loadId,callback:function(e,f,g,d){if(d.loadId===a.loadId){a.onRangeFetched(e,f,g,d)}},fireEvent:!1})}},destroy:function(){var a=this,b=a.view;a.cancelLoad();if(b&&b.el){b.un('scroll',a.onViewScroll,a)}if(a.store){a.unbindStore()}a.viewListeners=a.gridListeners=a.view=a.grid=Ext.destroy(a.viewListeners,a.stretcher,a.gridListeners);Ext.plugin.Abstract.prototype.destroy.call(this)}},0,0,0,0,['plugin.bufferedrenderer'],0,[Ext.grid.plugin,'BufferedRenderer'],function(a){if(Ext.supports.Touch){a.prototype.leadingBufferZone=a.prototype.trailingBufferZone=2;a.prototype.numFromEdge=1}});Ext.cmd.derive('Ext.util.Queue',Ext.Base,{constructor:function(){this.clear()},add:function(b){var a=this,c=a.getKey(b);if(!a.map[c]){++a.length;a.items.push(b);a.map[c]=b}return b},clear:function(){var a=this,b=a.items;a.items=[];a.map={};a.length=0;return b},contains:function(b){var a=this.getKey(b);return this.map.hasOwnProperty(a)},getCount:function(){return this.length},getKey:function(a){return a.id},remove:function(b){var a=this,e=a.getKey(b),d=a.items,c;if(a.map[e]){c=Ext.Array.indexOf(d,b);Ext.Array.erase(d,c,1);delete a.map[e];--a.length}return b}},1,0,0,0,0,0,[Ext.util,'Queue'],0);Ext.cmd.derive('Ext.layout.ContextItem',Ext.Base,{heightModel:null,widthModel:null,sizeModel:null,optOut:!1,ownerSizePolicy:null,boxChildren:null,boxParent:null,children:[],dirty:null,dirtyCount:0,hasRawContent:!0,isContextItem:!0,isTopLevel:!1,consumersContentHeight:0,consumersContentWidth:0,consumersContainerHeight:0,consumersContainerWidth:0,consumersHeight:0,consumersWidth:0,ownerCtContext:null,remainingChildDimensions:0,props:null,state:null,wrapsComponent:!1,constructor:function(s){var a=this,o=Ext.layout.SizeModel.sizeModels,l=o.configured,g=o.shrinkWrap,r,c,f,d,k,i,b,p,m,q,n,h,e,j;Ext.apply(a,s);b=a.target;r=a.el;a.id=b.id;a.flushedProps={};a.props=k={};a.styles={};if(!b.isComponent){c=r.lastBox}else {a.wrapsComponent=!0;a.framing=b.frameSize||null;a.isComponentChild=b.ownerLayout&&b.ownerLayout.isComponentLayout;c=b.lastBox;f=b.ownerCt;if(f&&(d=f.el&&a.context.items[f.el.id])){a.ownerCtContext=d}a.sizeModel=i=b.getSizeModel(d&&d.widthModel.pairsByHeightOrdinal[d.heightModel.ordinal]);a.widthModel=h=i.width;a.heightModel=e=i.height;if(c&&c.invalid===!1){q=b.width===(p=c.width);n=b.height===(m=c.height);if(h===g&&e===g){j=!0}else {if(h===l&&q){j=e===g||e===l&&n}}if(j){a.optOut=!0;k.width=p;k.height=m}}}a.lastBox=c},init:function(r,i){var a=this,c=a.props,e=a.dirty,b=a.ownerCtContext,h=a.target.ownerLayout,j=!a.state,s=r||j,n,l,t,q,k,d,o=a.heightModel,p=a.widthModel,f,g,m=0;a.dirty=a.invalid=!1;a.props={};a.remainingChildDimensions=0;if(a.boxChildren){a.boxChildren.length=0}if(!j){a.clearAllBlocks('blocks');a.clearAllBlocks('domBlocks')}if(!a.wrapsComponent){return s}d=a.target;a.state={};if(j){if(d.beforeLayout&&d.beforeLayout!==Ext.emptyFn){d.beforeLayout()}if(!b&&(q=d.ownerCt)){b=a.context.items[q.el.id]}if(b){a.ownerCtContext=b;a.isBoxParent=h&&h.isItemBoxParent(a)}else {a.isTopLevel=!0}a.frameBodyContext=a.getEl('frameBody')}else {b=a.ownerCtContext;a.isTopLevel=!b;n=a.children;for(l=0,t=n.length;l0);if(r){a.widthModel=a.heightModel=null;k=d.getSizeModel(b&&b.widthModel.pairsByHeightOrdinal[b.heightModel.ordinal]);if(j){a.sizeModel=k}a.widthModel=k.width;a.heightModel=k.height;if(b&&!a.isComponentChild){if(h.needsItemSize||!d.liquidLayout){b.remainingChildDimensions+=2}else {if(a.widthModel.calculated){++b.remainingChildDimensions}if(a.heightModel.calculated){++b.remainingChildDimensions}}}}else {if(c){a.recoverProp('x',c,e);a.recoverProp('y',c,e);if(a.widthModel.calculated){a.recoverProp('width',c,e)}else {if('width' in c){++m}}if(a.heightModel.calculated){a.recoverProp('height',c,e)}else {if('height' in c){++m}}if(b&&!a.isComponentChild){b.remainingChildDimensions+=m}}}if(c&&h&&h.manageMargins){a.recoverProp('margin-top',c,e);a.recoverProp('margin-right',c,e);a.recoverProp('margin-bottom',c,e);a.recoverProp('margin-left',c,e)}if(i){f=i.heightModel;g=i.widthModel;if(g&&f&&p&&o){if(p.shrinkWrap&&o.shrinkWrap){if(g.constrainedMax&&f.constrainedMin){f=null}}}if(g){a.widthModel=g}if(f){a.heightModel=f}if(i.state){Ext.apply(a.state,i.state)}}return s},initContinue:function(f){var b=this,a=b.ownerCtContext,g=b.target,c=b.widthModel,e=g.getInherited(),d;if(c.fixed){e.inShrinkWrapTable=!1}else {delete e.inShrinkWrapTable}if(f){if(a&&c.shrinkWrap){d=a.isBoxParent?a:a.boxParent;if(d){d.addBoxChild(b)}}else {if(c.natural){b.boxParent=a}}}return f},initDone:function(d){var a=this,b=a.props,c=a.state;if(a.remainingChildDimensions===0){b.containerChildrenSizeDone=!0}if(d){b.containerLayoutDone=!0}if(a.boxChildren&&a.boxChildren.length&&a.widthModel.shrinkWrap){a.el.setWidth(10000);c.blocks=(c.blocks||0)+1}},initAnimation:function(){var a=this,b=a.target,c=a.ownerCtContext;if(c&&c.isTopLevel){a.animatePolicy=b.ownerLayout.getAnimatePolicy(a)}else {if(!c&&b.isCollapsingOrExpanding&&b.animCollapse){a.animatePolicy=b.componentLayout.getAnimatePolicy(a)}}if(a.animatePolicy){a.context.queueAnimation(a)}},addBlock:function(f,a,e){var b=this,d=b[f]||(b[f]={}),c=d[e]||(d[e]={});if(!c[a.id]){c[a.id]=a;++a.blockCount;++b.context.blockCount}},addBoxChild:function(a){var d=this,b,c=a.widthModel;a.boxParent=this;a.measuresBox=c.shrinkWrap?a.hasRawContent:c.natural;if(a.measuresBox){b=d.boxChildren;if(b){b.push(a)}else {d.boxChildren=[a]}}},addPositionStyles:function(b,c){var d=c.x,e=c.y,a=0;if(d!==undefined){b.left=d+'px';++a}if(e!==undefined){b.top=e+'px';++a}return a},addTrigger:function(c,e){var b=this,h=e?'domTriggers':'triggers',f=b[h]||(b[h]={}),g=b.context,a=g.currentLayout,d=f[c]||(f[c]={});if(!d[a.id]){d[a.id]=a;++a.triggerCount;d=g.triggers[e?'dom':'data'];(d[a.id]||(d[a.id]=[])).push({item:this,prop:c});if(b.props[c]!==undefined){if(!e||!(b.dirty&&c in b.dirty)){++a.firedTriggers}}}},boxChildMeasured:function(){var a=this,b=a.state,c=b.boxesMeasured=(b.boxesMeasured||0)+1;if(c===a.boxChildren.length){b.clearBoxWidth=1;++a.context.progressCount;a.markDirty()}},borderNames:['border-top-width','border-right-width','border-bottom-width','border-left-width'],marginNames:['margin-top','margin-right','margin-bottom','margin-left'],paddingNames:['padding-top','padding-right','padding-bottom','padding-left'],trblNames:['top','right','bottom','left'],cacheMissHandlers:{borderInfo:function(b){var a=b.getStyles(b.borderNames,b.trblNames);a.width=a.left+a.right;a.height=a.top+a.bottom;return a},marginInfo:function(b){var a=b.getStyles(b.marginNames,b.trblNames);a.width=a.left+a.right;a.height=a.top+a.bottom;return a},paddingInfo:function(b){var c=b.frameBodyContext||b,a=c.getStyles(b.paddingNames,b.trblNames);a.width=a.left+a.right;a.height=a.top+a.bottom;return a}},checkCache:function(a){return this.cacheMissHandlers[a](this)},clearAllBlocks:function(c){var a=this[c],b;if(a){for(b in a){this.clearBlocks(c,b)}}},clearBlocks:function(g,f){var c=this[g],b=c&&c[f],d,a,e;if(b){delete c[f];d=this.context;for(e in b){a=b[e];--d.blockCount;if(!--a.blockCount&&!a.pending&&!a.done){d.queueLayout(a)}}}},block:function(b,a){this.addBlock('blocks',b,a)},domBlock:function(b,a){this.addBlock('domBlocks',b,a)},fireTriggers:function(g,e){var c=this[g],b=c&&c[e],f=this.context,a,d;if(b){for(d in b){a=b[d];++a.firedTriggers;if(!a.done&&!a.blockCount&&!a.pending){f.queueLayout(a)}}}},flush:function(){var a=this,d=a.dirty,b=a.state,c=a.el;a.dirtyCount=0;if('attributes' in a){c.set(a.attributes);delete a.attributes}if('innerHTML' in a){c.innerHTML=a.innerHTML;delete a.innerHTML}if(b&&b.clearBoxWidth){b.clearBoxWidth=0;a.el.setStyle('width',null);if(!--b.blocks){a.context.queueItemLayouts(a)}}if(d){delete a.dirty;a.writeProps(d,!0)}},flushAnimations:function(){var b=this,k=b.previousSize,a,h,l,f,d,g,e,m,c,j,i;if(k){a=b.target;h=a.getAnimationProps();l=h.duration;f=Ext.Object.getKeys(b.animatePolicy);d=Ext.apply({},{from:{},to:{},duration:l||Ext.fx.Anim.prototype.duration},h);for(g=0,e=0,m=f.length;e0},runLayout:function(a){var b=this,c=b.getCmp(a.owner);a.pending=!1;if(c.state.blocks){return}a.done=!0;++a.calcCount;++b.calcCount;a.calculate(c);if(a.done){b.layoutDone(a);if(a.completeLayout){b.queueCompletion(a)}if(a.finalizeLayout){b.queueFinalize(a)}}else {if(!a.pending&&!a.invalid&&!(a.blockCount+a.triggerCount-a.firedTriggers)){b.queueLayout(a)}}},setItemSize:function(a,g,f){var b=a,c=1,e,d;if(a.isComposite){b=a.elements;c=b.length;a=b[0]}else {if(!a.dom&&!a.el){c=b.length;a=b[0]}}for(d=0;da){a=d.weight}}},this);return a},getSplitterTarget:function(b){var a=b.collapseTarget;if(a&&a.collapsed){return a.placeholder||a}return a},isItemBoxParent:function(a){return !0},isItemShrinkWrap:function(a){return !0},insertSplitter:function(a,f,e,d){var c=a.region,b=Ext.apply({xtype:'bordersplitter',collapseTarget:a,id:a.id+'-splitter',hidden:e,canResize:a.splitterResize!==!1,splitterFor:a,synthetic:!0},d),g=f+(c==='south'||c==='east'?0:1);if(a.collapseMode==='mini'){b.collapsedCls=a.collapsedCls}a.splitter=this.owner.add(g,b)},getMoveAfterIndex:function(b){var a=Ext.layout.container.Container.prototype.getMoveAfterIndex.apply(this,arguments);if(b.splitter){a++}return a},moveItemBefore:function(c,a){var b;if(a&&a.splitter){b=a.region;if(b==='south'||b==='east'){a=a.splitter}}return Ext.layout.container.Container.prototype.moveItemBefore.call(this,c,a)},onAdd:function(a,i){var b=this,d=a.placeholderFor,f=a.region,e,c,g,h;Ext.layout.container.Container.prototype.onAdd.apply(this,arguments);if(f){Ext.apply(a,b.regionFlags[f]);if(b.owner.isViewport){a.isViewportBorderChild=!0}if(a.initBorderRegion){a.initBorderRegion()}e=f==='center';if(e){b.centerRegion=a}else {c=a.split;g=!!a.hidden;if(typeof c==='object'){h=c;c=!0}if((a.isHorz||a.isVert)&&(c||a.collapseMode==='mini')){b.insertSplitter(a,i,g||!c,h)}}if(!e&&!a.hasOwnProperty('collapseMode')){a.collapseMode=b.panelCollapseMode}if(!a.hasOwnProperty('animCollapse')){if(a.collapseMode!=='placeholder'){a.animCollapse=!1}else {a.animCollapse=b.panelCollapseAnimate}}}else {if(d){Ext.apply(a,b.regionFlags[d.region]);a.region=d.region;a.weight=d.weight}}},onDestroy:function(){this.centerRegion=null;Ext.layout.container.Container.prototype.onDestroy.call(this)},onRemove:function(a,f){var d=this,h=a.region,e=a.splitter,c=d.owner,g=c.destroying,b;if(h){if(a.isCenter){d.centerRegion=null}delete a.isCenter;delete a.isHorz;delete a.isVert;if(e&&!c.destroying){c.doRemove(e,!0)}delete a.splitter}Ext.layout.container.Container.prototype.onRemove.apply(this,arguments);if(!g&&!f&&a.rendered){b=a.getEl();if(b){b.setStyle('top','');b.setStyle(d.horzPositionProp,'')}}},regionMeta:{center:{splitterDelta:0},north:{splitterDelta:1},south:{splitterDelta:-1},west:{splitterDelta:1},east:{splitterDelta:-1}},regionFlags:{center:{isCenter:!0,isHorz:!1,isVert:!1},north:{isCenter:!1,isHorz:!1,isVert:!0,collapseDirection:'top'},south:{isCenter:!1,isHorz:!1,isVert:!0,collapseDirection:'bottom'},west:{isCenter:!1,isHorz:!0,isVert:!1,collapseDirection:'left'},east:{isCenter:!1,isHorz:!0,isVert:!1,collapseDirection:'right'}},setupSplitterNeighbors:function(l){var i={},m=l.length,k=this.touchedRegions,h,b,j,g,d,a,f,e,c;for(h=0;h{%this.renderBody(out, values)%}'],targetElCls:'x-center-target',beginLayout:function(b){var h=this,f=h.percentRe,e,g,d,c,a,j,i;Ext.layout.container.Fit.prototype.beginLayout.call(this,b);e=b.childItems;for(d=0,g=e.length;dm){a=m}}if(a-d<2){return null}c=new Ext.util.Region(v,t,s,u);i.constraintAdjusters[i.getCollapseDirection()](c,d,a,e);i.dragInfo={minRange:d,maxRange:a,targetSize:q};return c},constraintAdjusters:{left:function(a,c,b,d){a[0]=a.x=a.left=a.right+c;a.right+=b+d.getWidth()},top:function(a,c,b,d){a[1]=a.y=a.top=a.bottom+c;a.bottom+=b+d.getHeight()},bottom:function(a,c,b,d){a.bottom=a.top-c;a.top-=b+d.getHeight()},right:function(a,c,b,d){a.right=a.left-c;a[0]=a.x=a.left=a.x-b+d.getWidth()}},onBeforeStart:function(h){var c=this,f=c.splitter,d=f.collapseTarget,e=f.neighbors,g=e.length,a,b;if(d.collapsed){return !1}for(a=0;ad){a.minWidth=a.el.getWidth()*c}else {a.minHeight=a.el.getHeight()*d}}if(a.throttle){e=Ext.Function.createThrottled(function(){Ext.resizer.ResizeTracker.prototype.resize.apply(a,arguments)},a.throttle);a.resize=function(f,d,c){if(c){Ext.resizer.ResizeTracker.prototype.resize.apply(a,arguments)}else {e.apply(null,arguments)}}}},onBeforeStart:function(a){this.startBox=this.target.getBox()},getProxy:function(){var a=this;if(!a.dynamic&&!a.proxy){a.proxy=a.createProxy(a.target||a.el);a.hideProxy=!0}if(a.proxy){a.proxy.show();return a.proxy}},createProxy:function(a){var b,c=this.proxyCls;if(a.isComponent){b=a.getProxy().addCls(c)}else {b=a.createProxy({tag:'div',role:'presentation',cls:c,id:a.id+'-rzproxy'},Ext.getBody())}b.removeCls('x-proxy-el');return b},onStart:function(a){this.activeResizeHandle=Ext.get(this.getDragTarget().id);if(!this.dynamic){this.resize(this.startBox)}},onMouseDown:function(c,b){var a=Ext.fly(b.parentNode);Ext.dd.DragTracker.prototype.onMouseDown.apply(this,arguments);if(a&&a.shim){a.maskIframes()}},onMouseUp:function(b){var a=Ext.fly(this.dragTarget.parentNode);Ext.dd.DragTracker.prototype.onMouseUp.apply(this,arguments);if(a&&a.shim){a.unmaskIframes()}},onDrag:function(a){if(this.dynamic||this.proxy){this.updateDimensions(a)}},updateDimensions:function(s,r){var c=this,h=c.activeResizeHandle.region,d=c.getOffset(c.constrainTo?'dragTarget':null),b=c.startBox,n,f=0,e=0,k,j,l=0,m=0,q,i,g,a,o,p;h=c.convertRegionName(h);switch(h){case 'south':e=d[1];g=2;break;case 'north':e=-d[1];m=-e;g=2;break;case 'east':f=d[0];g=1;break;case 'west':f=-d[0];l=-f;g=1;break;case 'northeast':e=-d[1];m=-e;f=d[0];i=[b.x,b.y+b.height];g=3;break;case 'southeast':e=d[1];f=d[0];i=[b.x,b.y];g=3;break;case 'southwest':f=-d[0];l=-f;e=d[1];i=[b.x+b.width,b.y];g=3;break;case 'northwest':e=-d[1];m=-e;f=-d[0];l=-f;i=[b.x+b.width,b.y+b.height];g=3;break;}a={width:b.width+f,height:b.height+e,x:b.x+l,y:b.y+m};k=Ext.Number.snap(a.width,c.widthIncrement);j=Ext.Number.snap(a.height,c.heightIncrement);if(k!==a.width||j!==a.height){switch(h){case 'northeast':a.y-=j-a.height;break;case 'north':a.y-=j-a.height;break;case 'southwest':a.x-=k-a.width;break;case 'west':a.x-=k-a.width;break;case 'northwest':a.x-=k-a.width;a.y-=j-a.height;}a.width=k;a.height=j}if(a.widthc.maxWidth){a.width=Ext.Number.constrain(a.width,c.minWidth,c.maxWidth);if(l){a.x=b.x+(b.width-a.width)}}else {c.lastX=a.x}if(a.heightc.maxHeight){a.height=Ext.Number.constrain(a.height,c.minHeight,c.maxHeight);if(m){a.y=b.y+(b.height-a.height)}}else {c.lastY=a.y}if(c.preserveRatio||s.shiftKey){n=c.startBox.width/c.startBox.height;o=Math.min(Math.max(c.minHeight,a.width/n),c.maxHeight);p=Math.min(Math.max(c.minWidth,a.height*n),c.maxWidth);if(g===1){a.height=o}else {if(g===2){a.width=p}else {q=Math.abs(i[0]-this.lastXY[0])/Math.abs(i[1]-this.lastXY[1]);if(q>n){a.height=o}else {a.width=p}if(h==='northeast'){a.y=b.y-(a.height-b.height)}else {if(h==='northwest'){a.y=b.y-(a.height-b.height);a.x=b.x-(a.width-b.width)}else {if(h==='southwest'){a.x=b.x-(a.width-b.width)}}}}}}c.setPosition=a.x!==c.startBox.x||a.y!==c.startBox.y;c.resize(a,r)},resize:function(b,e){var a=this,c,d=a.setPosition;if(a.dynamic||!a.dynamic&&e){if(d){a.target.setBox(b)}else {a.target.setSize(b.width,b.height)}}if(!e){c=a.getProxy();if(c&&c!==a.target){if(d||a.hideProxy){c.setBox(b)}else {c.setSize(b.width,b.height)}}}},onEnd:function(a){this.updateDimensions(a,!0);if(this.proxy&&this.hideProxy){this.proxy.hide()}},convertRegionName:function(a){return a}},1,0,0,0,0,0,[Ext.resizer,'ResizeTracker'],0);Ext.cmd.derive('Ext.resizer.Resizer',Ext.Base,{alternateClassName:'Ext.Resizable',handleCls:'x-resizable-handle',overCls:'x-resizable-handle-over',pinnedCls:'x-resizable-pinned',wrapCls:'x-resizable-wrap',wrappedCls:'x-resizable-wrapped',delimiterRe:/(?:\s*[,;]\s*)|\s+/,dynamic:!0,handles:'s e se',height:null,width:null,heightIncrement:0,widthIncrement:0,minHeight:20,minWidth:20,maxHeight:10000,maxWidth:10000,pinned:!1,preserveRatio:!1,transparent:!1,possiblePositions:{n:'north',s:'south',e:'east',w:'west',se:'southeast',sw:'southwest',nw:'northwest',ne:'northeast'},ariaRole:'presentation',constructor:function(e){var a=this,d=a.handles,q=Ext.dom.Element.unselectableCls,h=[],b,k,i,m,p,c,f,n,l,g,o,j;if(Ext.isString(e)||Ext.isElement(e)||e.dom){b=e;e=arguments[1]||{};e.target=b}a.mixins.observable.constructor.call(a,e);b=a.target;if(b){if(b.isComponent){b.addClsWithUI('resizable');if(b.minWidth){a.minWidth=b.minWidth}if(b.minHeight){a.minHeight=b.minHeight}if(b.maxWidth){a.maxWidth=b.maxWidth}if(b.maxHeight){a.maxHeight=b.maxHeight}if(b.floating){if(!a.hasOwnProperty('handles')){a.handles='n ne e se s sw w nw'}}a.el=b.getEl()}else {b=a.el=a.target=Ext.get(b)}}else {b=a.target=a.el=Ext.get(a.el)}a.el.addCls(Ext.Component.prototype.borderBoxCls);if(Ext.isNumber(a.width)){a.width=Ext.Number.constrain(a.width,a.minWidth,a.maxWidth)}if(Ext.isNumber(a.height)){a.height=Ext.Number.constrain(a.height,a.minHeight,a.maxHeight)}if(a.width!==null||a.height!==null){a.target.setSize(a.width,a.height)}m=a.el.dom.tagName.toUpperCase();if(m==='TEXTAREA'||m==='IMG'||m==='TABLE'){a.originalTarget=a.target;g=b.isComponent?b.getEl():b;a.el.addCls(a.wrappedCls);a.target=a.el=a.el.wrap({role:'presentation',cls:a.wrapCls,id:a.el.id+'-rzwrap',style:g.getStyle(['margin-top','margin-bottom'])});o=g.getPositioning();a.el.setPositioning(o);g.clearPositioning();l=g.getBox();if(o.position!=='absolute'){l.x=0;l.y=0}a.el.setBox(l);g.setStyle('position','absolute');a.isTargetWrapped=!0}a.el.position();if(a.pinned){a.el.addCls(a.pinnedCls)}a.resizeTracker=new Ext.resizer.ResizeTracker({disabled:a.disabled,target:b,el:a.el,constrainTo:a.constrainTo,handleCls:a.handleCls,overCls:a.overCls,throttle:a.throttle,proxy:a.originalTarget?a.el:null,dynamic:a.originalTarget?!0:a.dynamic,originalTarget:a.originalTarget,delegate:'.'+a.handleCls,preserveRatio:a.preserveRatio,heightIncrement:a.heightIncrement,widthIncrement:a.widthIncrement,minHeight:a.minHeight,maxHeight:a.maxHeight,minWidth:a.minWidth,maxWidth:a.maxWidth});a.resizeTracker.on({mousedown:a.onBeforeResize,drag:a.onResize,dragend:a.onResizeEnd,scope:a});if(a.handles==='all'){a.handles='n s e w ne nw se sw'}d=a.handles=a.handles.split(a.delimiterRe);i=a.possiblePositions;p=d.length;k=a.handleCls+' '+a.handleCls+'-{0}';if(a.target.isComponent){j=a.target.baseCls;k+=' '+j+'-handle '+j+'-handle-{0}';if(Ext.supports.CSS3BorderRadius){k+=' '+j+'-handle-{0}-br'}}for(c=0;c')}}Ext.DomHelper.append(a.el,h.join(''));h.length=0;for(c=0;c-1){this.doSelect(a.record,!1,b)}},onCellDeselect:function(a,b){if(a&&a.rowIdx!==undefined){this.doDeselect(a.record,b)}},onSelectChange:function(g,f,e,h){var b=this,a,c,d;if(f){a=b.nextSelection;c='select'}else {a=b.selection;c='deselect'}d=a.view||b.primaryView;if((e||b.fireEvent('before'+c,b,g,a.rowIdx,a.colIdx))!==!1&&h()!==!1){if(f){d.onCellSelect(a)}else {d.onCellDeselect(a);delete b.selection}if(!e){b.fireEvent(c,b,g,a.rowIdx,a.colIdx)}}},refresh:function(){var b=this.getPosition(),a;if(b&&(a=this.store.indexOf(this.selected.last()))!==-1){b.rowIdx=a}},onColumnMove:function(b,d,c,e){var a=b.up('tablepanel');if(a){this.onViewRefresh(a.view)}},onUpdate:function(c){var a=this,b;if(a.isSelected(c)){b=a.selecting?a.nextSelection:a.selection;a.view.onCellSelect(b)}},onViewRefresh:function(d){var f=this,b=f.getPosition(),g,c=d.headerCt,e,a;if(b&&b.view===d){e=b.record;a=b.column;if(!a.isDescendantOf(c)){a=c.queryById(a.id)||c.down('[text="'+a.text+'"]')||c.down('[dataIndex="'+a.dataIndex+'"]')}if(b.record){if(a&&d.store.indexOfId(e.getId())!==-1){g=(new Ext.grid.CellContext(d)).setPosition({row:e,column:a});f.setPosition(g)}}else {f.selection=null}}},selectByPosition:function(b,a){this.setPosition(b,a)}},0,0,0,0,['selection.cellmodel'],0,[Ext.selection,'CellModel'],0);Ext.cmd.derive('Ext.selection.RowModel',Ext.selection.DataViewModel,{enableKeyNav:!0,isRowModel:!0,deselectOnContainerClick:!1,onUpdate:function(b){var d=this,a=d.view,c;if(a&&d.isSelected(b)){c=a.indexOf(b);a.onRowSelect(c);if(b===d.lastFocused){a.onRowFocus(c,!0)}}},onSelectChange:function(c,g,e,j){var a=this,i=a.views||[a.view],k=i.length,b=a.store.indexOf(c),h=g?'select':'deselect',f,d;if((e||a.fireEvent('before'+h,a,c,b))!==!1&&j()!==!1){for(f=0;f '},selectByPosition:function(a,b){if(!a.isCellContext){a=(new Ext.grid.CellContext(this.view)).setPosition(a.row,a.column)}if(!this.checkOnly||a.column===this.column){Ext.selection.RowModel.prototype.selectByPosition.call(this,a,b)}},onSelectChange:function(){Ext.selection.RowModel.prototype.onSelectChange.apply(this,arguments);if(!this.suspendChange){this.updateHeaderState()}},onStoreLoad:function(){Ext.selection.RowModel.prototype.onStoreLoad.apply(this,arguments);this.updateHeaderState()},onStoreAdd:function(){Ext.selection.RowModel.prototype.onStoreAdd.apply(this,arguments);this.updateHeaderState()},onStoreRemove:function(){Ext.selection.RowModel.prototype.onStoreRemove.apply(this,arguments);this.updateHeaderState()},onStoreRefresh:function(){Ext.selection.RowModel.prototype.onStoreRefresh.apply(this,arguments);this.updateHeaderState()},maybeFireSelectionChange:function(a){if(a&&!this.suspendChange){this.updateHeaderState()}Ext.selection.RowModel.prototype.maybeFireSelectionChange.apply(this,arguments)},resumeChanges:function(){Ext.selection.RowModel.prototype.resumeChanges.call(this);if(!this.suspendChange){this.updateHeaderState()}},updateHeaderState:function(){var a=this,e=a.store,g=e.getCount(),h=a.views,c=!1,f=0,d,i,b;if(!e.isBufferedStore&&g>0){d=a.selected;c=!0;for(b=0,i=d.getCount();b style="{bodyStyle}">{%this.renderContainer(out,values)%}',_reverseDockNames:{left:'right',right:'left'},_layoutAlign:{top:'end',right:'begin',bottom:'begin',left:'end'},initComponent:function(){var a=this,b=a.initialConfig.layout,d=b&&b.align,c=b&&b.overflowHandler;if(a.plain){a.addCls(a.baseCls+'-plain')}Ext.panel.Bar.prototype.initComponent.call(this);a.setLayout({align:d||(a.getTabStretchMax()?'stretchmax':a._layoutAlign[a.dock]),overflowHandler:c||'scroller'});a.on({click:a.onClick,element:'el',scope:a})},ensureTabVisible:function(a){var b=this,d=b.tabPanel,c=b.layout.overflowHandler;if(b.rendered&&c&&b.tooNarrow&&c.scrollToItem){if(a||a===0){if(!a.isTab){if(Ext.isNumber(a)){a=this.items.getAt(a)}else {if(a.isComponent&&d&&d.items.contains(a)){a=a.tab}}}}if(!a){a=b.activeTab}if(a){c.scrollToItem(a)}}},initRenderData:function(){var a=this;return Ext.apply(Ext.panel.Bar.prototype.initRenderData.call(this),{bodyCls:a.bodyCls,baseBodyCls:a._baseBodyCls,bodyTargetCls:a.bodyTargetCls,stripCls:a._stripCls,dock:a.dock})},setDock:function(f){var b=this,a=b.items,d=b.ownerCt,e,c,g;a=a&&a.items;if(a){for(c=0,g=a.length;c1){if(a&&a!==b&&!a.disabled){c=a}else {c=b.next('tab[disabled=false]')||b.prev('tab[disabled=false]')}}return c||d.activeTab},setActiveTab:function(b,c){var a=this;if(!b.disabled&&b!==a.activeTab){if(a.activeTab){if(a.activeTab.destroyed){a.previousTab=null}else {a.previousTab=a.activeTab;a.activeTab.deactivate();a.deactivateFocusable(a.activeTab)}}b.activate();a.activateFocusable(b);a.activeTab=b;a.needsScroll=!0;if(!c){a.fireEvent('change',a,b,b.card);a.updateLayout()}}},privates:{adjustTabPositions:function(){var g=this,f=g.items.items,h=f.length,a,b,e,c,d;if(!Ext.isIE8){d=g._getTabAdjustProp();while(h--){a=f[h];e=a.el;b=a.lastBox;c=a.isTab?a.getActualRotation():0;if(c===1&&a.isVisible()){e.setStyle(d,b.x+b.width+'px')}else {if(c===2&&a.isVisible()){e.setStyle(d,b.x-b.height+'px')}}}}},applyTargetCls:function(a){this.bodyTargetCls=a},_getTabAdjustProp:function(){return 'left'},getTargetEl:function(){return this.body||this.frameBody||this.el},onClick:function(c,g){var f=this,e,a,b,d;if(c.getTarget('.x-box-scroller')){return}if(Ext.isIE8&&f.vertical){d=f.getTabInfoFromPoint(c.getXY());a=d.tab;b=d.close}else {e=c.getTarget('.'+Ext.tab.Tab.prototype.baseCls);a=e&&Ext.getCmp(e.id);b=a&&a.closeEl&&g===a.closeEl.dom}if(b){c.preventDefault()}if(a&&a.isDisabled&&!a.isDisabled()){a.beforeClick(b);if(a.closable&&b){a.onCloseClick()}else {f.doActivateTab(a)}}},doActivateTab:function(a){var b=this.tabPanel;if(b){if(!a.disabled){b.setActiveTab(a.card)}}else {this.setActiveTab(a)}},onFocusableContainerFocus:function(d){var b=this,c=b.mixins.focusablecontainer,a;a=c.onFocusableContainerFocus.call(b,d);if(a&&a.isTab){b.doActivateTab(a)}},onFocusableContainerFocusEnter:function(d){var b=this,c=b.mixins.focusablecontainer,a;a=c.onFocusableContainerFocusEnter.call(b,d);if(a&&a.isTab){b.doActivateTab(a)}},focusChild:function(d,c){var b=this,e=b.mixins.focusablecontainer,a;a=e.focusChild.call(b,d,c);if(b.activateOnFocus&&a&&a.isTab){b.doActivateTab(a)}}}},0,['tabbar'],['component','box','container','tabbar'],{'component':!0,'box':!0,'container':!0,'tabbar':!0},['widget.tabbar'],[[Ext.util.FocusableContainer.prototype.mixinId||Ext.util.FocusableContainer.$className,Ext.util.FocusableContainer]],[Ext.tab,'Bar'],0);Ext.cmd.derive('Ext.tab.Panel',Ext.panel.Panel,{alternateClassName:['Ext.TabPanel'],config:{tabBar:undefined,tabPosition:'top',tabRotation:'default',tabStretchMax:!0},removePanelHeader:!0,plain:!1,itemCls:'x-tabpanel-child',minTabWidth:undefined,maxTabWidth:undefined,deferredRender:!0,_defaultTabRotation:{top:0,right:1,bottom:0,left:2},initComponent:function(){var a=this,c=a.activeTab!==null?a.activeTab||0:null,d=a.dockedItems,b=a.header,f=a.tabBarHeaderPosition,e=a.getTabBar(),g;a.layout=new Ext.layout.container.Card(Ext.apply({owner:a,deferredRender:a.deferredRender,itemCls:a.itemCls,activeItem:c},a.layout));if(f!=null){b=a.header=Ext.apply({},b);g=b.items=b.items?b.items.slice():[];b.itemPosition=f;g.push(e);b.hasTabBar=!0}else {d=[].concat(a.dockedItems||[]);d.push(e);a.dockedItems=d}Ext.panel.Panel.prototype.initComponent.apply(this,arguments);c=a.activeTab=a.getComponent(c);if(c){e.setActiveTab(c.tab,!0)}},onRender:function(){var b=this.items.items,c=b.length,a;Ext.panel.Panel.prototype.onRender.apply(this,arguments);for(a=0;a','
    lineempty" role="presentation">
    ','','
    -end-plus {expanderCls}" role="presentation">
    ','','
    {checkboxCls}-checked">
    ','
    ','',' role="presentation" class="{childCls} {baseIconCls} {customIconCls} ','{baseIconCls}-leafparent-expandedparent {iconCls}" ','style="background-image:url({icon})"/>>','','{value}','','{value}',''],uiFields:{checked:1,icon:1,iconCls:1},rowFields:{expanded:1,loaded:1,expandable:1,leaf:1,loading:1,qtip:1,qtitle:1,cls:1},initComponent:function(){var a=this;a.rendererScope=a.scope;a.setupRenderer();a.innerRenderer=a.renderer;a.renderer=a.treeRenderer;Ext.grid.column.Column.prototype.initComponent.call(this);a.scope=a;a.hasCustomRenderer=a.innerRenderer&&a.innerRenderer.length>1},treeRenderer:function(i,a,c,g,f,h,j){var e=this,d=c.get('cls'),b;if(a&&d){a.tdCls+=' '+d}b=e.initTemplateRendererData(i,a,c,g,f,h,j);return e.getTpl('cellTpl').apply(b)},initTemplateRendererData:function(j,i,d,m,l,n,k){var a=this,f=a.innerRenderer,b=d.data,c=d.parentNode,g=k.rootVisible,h=[],e;while(c&&(g||c.data.depth>0)){e=c.data;h[g?e.depth:e.depth-1]=e.isLast?0:1;c=c.parentNode}return {record:d,baseIconCls:a.iconCls,customIconCls:b.icon||b.iconCls?a.customIconCls:'',iconCls:b.iconCls,icon:b.icon,checkboxCls:a.checkboxCls,checked:b.checked,elbowCls:a.elbowCls,expanderCls:a.expanderCls,textCls:a.textCls,leaf:b.leaf,expandable:d.isExpandable(),expanded:b.expanded,isLast:d.isLastVisible(),blankUrl:Ext.BLANK_IMAGE_URL,href:b.href,hrefTarget:b.hrefTarget,lines:h,metaData:i,childCls:a.getChildCls?a.getChildCls()+' ':'',value:f?f.apply(a.rendererScope,arguments):j}},shouldUpdateCell:function(f,a){var e=this,c=0,d,b;if(a){d=a.length;for(;c1;Ext.grid.NavigationModel.prototype.initKeyNav.call(this,e);for(b=0,d=a.keyNav.length;b1},onCellClick:function(f,e,c,d,g,b,a){Ext.grid.NavigationModel.prototype.onCellClick.call(this,f,e,c,d,g,b,a);return !a.nodeToggled},onKeyLeft:function(b){var c=this,d=b.view,a=c.record;if(c.isTreeGrid&&!b.ctrlKey){return Ext.grid.NavigationModel.prototype.onKeyLeft.call(this,b)}if(b.position.column.isTreeColumn&&a.isExpanded()){d.collapse(a)}else {a=a.parentNode;if(a&&!(a.isRoot()&&!d.rootVisible)){c.setPosition(a,null,b)}}},onKeyRight:function(b){var c=this,a=c.record;if(c.isTreeGrid&&!b.ctrlKey){return Ext.grid.NavigationModel.prototype.onKeyRight.call(this,b)}if(!a.isLeaf()){if(b.position.column.isTreeColumn&&!a.isExpanded()){b.view.expand(a)}else {if(a.isExpanded()){a=a.childNodes[0];if(a){c.setPosition(a)}}}}},onKeyEnter:function(a){if(this.record.data.checked!=null){this.toggleCheck(a)}else {Ext.grid.NavigationModel.prototype.onKeyEnter.call(this,a)}},onKeySpace:function(a){if(this.record.data.checked!=null){this.toggleCheck(a)}else {Ext.grid.NavigationModel.prototype.onKeySpace.call(this,a)}},toggleCheck:function(a){this.view.onCheckChange(a)},onAsterisk:function(a){this.view.ownerCt.expandAll()}},0,0,0,0,['view.navigation.tree'],0,[Ext.tree,'NavigationModel'],0);Ext.cmd.derive('Ext.tree.View',Ext.view.Table,{config:{selectionModel:{type:'treemodel'}},isTreeView:!0,loadingCls:'x-grid-tree-loading',expandedCls:'x-grid-tree-node-expanded',leafCls:'x-grid-tree-node-leaf',expanderSelector:'.x-tree-expander',checkboxSelector:'.x-tree-checkbox',expanderIconOverCls:'x-tree-expander-over',nodeAnimWrapCls:'x-tree-animator-wrap',ariaRole:'tree',loadMask:!1,rootVisible:!0,expandDuration:250,collapseDuration:250,toggleOnDblClick:!0,stripeRows:!1,treeRowTpl:['{%','this.processRowValues(values);','this.nextTpl.applyOut(values, out, parent);','%}',{priority:10,processRowValues:function(a){var b=a.record,c=a.view;a.rowAttr['data-qtip']=b.get('qtip')||'';a.rowAttr['data-qtitle']=b.get('qtitle')||'';if(b.isExpanded()){a.rowClasses.push(c.expandedCls)}if(b.isLeaf()){a.rowClasses.push(c.leafCls)}if(b.isLoading()){a.rowClasses.push(c.loadingCls)}}}],initComponent:function(){var a=this;if(a.bufferedRenderer){a.animate=!1}else {if(a.initialConfig.animate===undefined){a.animate=Ext.enableFx}}a.store=a.panel.getStore();a.onRootChange(a.store.getRoot());a.animQueue={};a.animWraps={};Ext.view.Table.prototype.initComponent.call(this);a.store.setRootVisible(a.rootVisible);a.addRowTpl(Ext.XTemplate.getTpl(a,'treeRowTpl'))},onFillComplete:function(f,d,b){var a=this,e=a.store,c=e.indexOf(b[0]);d.triggerUIUpdate();if(!b.length||c===-1){return}a.onAdd(a.store,b,c);a.refreshPartner()},refreshPartner:function(){var a=this.lockingPartner;if(a){a.refresh()}},afterComponentLayout:function(e,d,c,b){var a=this.getScrollable();Ext.view.Table.prototype.afterComponentLayout.call(this,e,d,c,b);if(a&&!this.bufferedRenderer){a.refresh()}},processUIEvent:function(a){if(a.getTarget('.'+this.nodeAnimWrapCls,this.el)){return !1}return Ext.view.Table.prototype.processUIEvent.call(this,a)},setRootNode:function(a){this.node=a},getChecked:function(){var a=[];this.node.cascadeBy(function(b){if(b.get('checked')){a.push(b)}});return a},isItemChecked:function(a){return a.get('checked')},createAnimWrap:function(b,e){var d=this,c=d.getNode(b),a;a=Ext.fly(c).insertSibling({role:'presentation',tag:'div',cls:d.nodeAnimWrapCls},'after');return {record:b,node:c,el:a,expanding:!1,collapsing:!1,animateEl:a,targetEl:a}},getAnimWrap:function(a,d){if(!this.animate){return null}var c=this.animWraps,b=c[a.internalId];if(d!==!1){while(!b&&a){a=a.parentNode;if(a){b=c[a.internalId]}}}return b},doAdd:function(h,c){var d=this,l=h[0],i=l.parentNode,m=d.all,e,a=d.getAnimWrap(i),g,f,k,j,b;if(!a||!a.expanding){return Ext.view.Table.prototype.doAdd.call(this,h,c)}j=d.bufferRender(h,c,!0);b=j.children;i=a.record;g=a.targetEl;f=g.dom.childNodes;k=f.length;e=c-d.indexInStore(i)-1;if(!k||e>=k){g.appendChild(j.fragment,!0)}else {Ext.fly(f[e]).insertSibling(b,'before',!0)}m.insert(c,b);return b},onRemove:function(h,c,b){var a=this,g,d,e=a.hasListeners.remove,f;if(a.viewReady){g=a.store.getCount()===0;if(a.bufferedRenderer){return Ext.view.Table.prototype.onRemove.call(this,h,c,b)}if(e){f=this.all.slice(b,b+c.length)}if(g){a.refresh()}else {for(d=c.length-1,b+=d;d>=0;--d,--b){a.doRemove(c[d],b)}a.refreshSizePending=!0}if(e){a.fireEvent('itemremove',c,b,f,a)}}},doRemove:function(c,b){var g=this,f=g.all,a=g.getAnimWrap(c),d=f.item(b),e=d?d.dom:null;if(!e||!a||!a.collapsing){return Ext.view.Table.prototype.doRemove.call(this,c,b)}a.targetEl.dom.insertBefore(e,a.targetEl.dom.firstChild);f.removeElement(b)},onBeforeExpand:function(c,d,e){var b=this,a;if(b.rendered&&b.all.getCount()&&b.animate){if(b.getNode(c)){a=b.getAnimWrap(c,!1);if(!a){a=b.animWraps[c.internalId]=b.createAnimWrap(c);a.animateEl.setHeight(0)}else {if(a.collapsing){a.targetEl.select(b.itemSelector).destroy()}}a.expanding=!0;a.collapsing=!1}}},onExpand:function(b){var a=this,h=a.animQueue,i=b.getId(),f=a.getNode(b),g=f?a.indexOf(f):-1,c,d,e;if(a.singleExpand){a.ensureSingleExpand(b)}if(g===-1){return}c=a.getAnimWrap(b,!1);if(!c){b.isExpandingOrCollapsing=!1;a.fireEvent('afteritemexpand',b,g,f);return}d=c.animateEl;e=c.targetEl;d.stopAnimation();h[i]=!0;Ext.on('idle',function(){d.dom.style.height='0px'},null,{single:!0});d.animate({from:{height:0},to:{height:e.dom.scrollHeight},duration:a.expandDuration,listeners:{afteranimate:function(){var f=e.dom.childNodes,d=Ext.Element.getActiveElement();if(f.length){if(!e.contains(d)){d=null}c.el.insertSibling(f,'before',!0);if(d){Ext.fly(d).focus()}}c.el.destroy();a.animWraps[c.record.internalId]=h[i]=null}},callback:function(){b.isExpandingOrCollapsing=!1;if(!a.destroyed){a.refreshSize(!0)}a.fireEvent('afteritemexpand',b,g,f)}})},onBeforeCollapse:function(c,g,f,d,e){var b=this,a;if(b.rendered&&b.all.getCount()){if(b.animate){if(c.isVisible()){a=b.getAnimWrap(c);if(!a){a=b.animWraps[c.internalId]=b.createAnimWrap(c,f)}else {if(a.expanding){a.targetEl.select(this.itemSelector).destroy()}}a.expanding=!1;a.collapsing=!0;a.callback=d;a.scope=e}}else {b.onCollapseCallback=d;b.onCollapseScope=e}}},onCollapse:function(c){var a=this,g=a.animQueue,h=c.getId(),d=a.getNode(c),f=d?a.indexOf(d):-1,b=a.getAnimWrap(c),e;if(!a.all.getCount()||!c.isVisible()){return}if(!b){c.isExpandingOrCollapsing=!1;a.fireEvent('afteritemcollapse',c,f,d);Ext.callback(a.onCollapseCallback,a.onCollapseScope);a.onCollapseCallback=a.onCollapseScope=null;return}e=b.animateEl;g[h]=!0;e.stopAnimation();e.animate({to:{height:0},duration:a.collapseDuration,listeners:{afteranimate:function(){b.el.destroy();a.animWraps[b.record.internalId]=g[h]=null}},callback:function(){c.isExpandingOrCollapsing=!1;if(!a.destroyed){a.refreshSize(!0)}a.fireEvent('afteritemcollapse',c,f,d);Ext.callback(b.callback,b.scope);b.callback=b.scope=null}})},isAnimating:function(a){return !!this.animQueue[a.getId()]},expand:function(a,f,d,e){var g=this,b=!!g.animate,c;if(!b||!a.isExpandingOrCollapsing){if(!a.isLeaf()){a.isExpandingOrCollapsing=b}Ext.suspendLayouts();c=a.expand(f,d,e);Ext.resumeLayouts(!0);return c}},collapse:function(a,e,c,d){var f=this,b=!!f.animate;if(!b||!a.isExpandingOrCollapsing){if(!a.isLeaf()){a.isExpandingOrCollapsing=b}return a.collapse(e,c,d)}},toggle:function(a,d,b,c){if(a.isExpanded()){this.collapse(a,d,b,c)}else {this.expand(a,d,b,c)}},onItemDblClick:function(a,e,d,f){var b=this,c=b.editingPlugin;Ext.view.Table.prototype.onItemDblClick.call(this,a,e,d,f);if(b.toggleOnDblClick&&a.isExpandable()&&!(c&&c.clicksToEdit===2)){b.toggle(a)}},onCellClick:function(d,g,c,i,h,a){var b=this,f=a.position.column,e;if(f.isTreeColumn){if(a.getTarget(b.checkboxSelector,d)&&Ext.isBoolean(e=c.get('checked'))&&b.fireEvent('beforecheckchange',c,e,a)!==!1){b.onCheckChange(a);if(f.stopSelection){a.stopSelection=!0}}else {if(a.getTarget(b.expanderSelector,d)&&c.isExpandable()){b.getNavigationModel().setPosition(a.position);b.toggle(c,a.ctrlKey);a.nodeToggled=!0}}return Ext.view.Table.prototype.onCellClick.call(this,d,g,c,i,h,a)}},onCheckChange:function(c){var a=c.record,b=!a.get('checked');a.set('checked',b);this.fireEvent('checkchange',a,b,c)},onItemMouseOver:function(c,b,d,a){if(a.getTarget(this.expanderSelector,b)){a.getTarget(this.cellSelector,null,!0).addCls(this.expanderIconOverCls)}},onItemMouseOut:function(c,b,d,a){if(a.getTarget(this.expanderSelector,b)){a.getTarget(this.cellSelector,null,!0).removeCls(this.expanderIconOverCls)}},getStoreListeners:function(){return Ext.apply(Ext.view.Table.prototype.getStoreListeners.call(this),{rootchange:this.onRootChange,fillcomplete:this.onFillComplete})},onBindStore:function(b,f,e,a){var d=a&&a.getRootNode(),c=b&&b.getRootNode();Ext.view.Table.prototype.onBindStore.call(this,b,f,e,a);if(c!==d){this.onRootChange(c,d)}},onRootChange:function(b,c){var a=this,d=a.grid;if(c){a.rootListeners.destroy();a.rootListeners=null}if(b){a.rootListeners=b.on({beforeexpand:a.onBeforeExpand,expand:a.onExpand,beforecollapse:a.onBeforeCollapse,collapse:a.onCollapse,destroyable:!0,scope:a});d.addRelayers(b)}},ensureSingleExpand:function(b){var a=b.parentNode;if(a){a.eachChild(function(a){if(a!==b&&a.isExpanded()){a.collapse()}})}}},0,['treeview'],['component','box','dataview','tableview','gridview','treeview'],{'component':!0,'box':!0,'dataview':!0,'tableview':!0,'gridview':!0,'treeview':!0},['widget.treeview'],0,[Ext.tree,'View'],0);Ext.cmd.derive('Ext.tree.Panel',Ext.panel.Table,{alternateClassName:['Ext.tree.TreePanel','Ext.TreePanel'],viewType:'treeview',treeCls:'x-tree-panel',rowLines:!1,lines:!0,useArrows:!1,singleExpand:!1,ddConfig:{enableDrag:!0,enableDrop:!0},rootVisible:!0,displayField:'text',root:null,normalCfgCopy:['displayField','root','singleExpand','useArrows','lines','rootVisible','scroll'],lockedCfgCopy:['displayField','root','singleExpand','useArrows','lines','rootVisible'],isTree:!0,arrowCls:'x-tree-arrows',linesCls:'x-tree-lines',noLinesCls:'x-tree-no-lines',autoWidthCls:'x-autowidth-table',constructor:function(a){a=a||{};if(a.animate===undefined){a.animate=Ext.isBoolean(this.animate)?this.animate:Ext.enableFx}this.enableAnimations=a.animate;delete a.animate;Ext.panel.Table.prototype.constructor.call(this,a)},initComponent:function(){var a=this,c=[a.treeCls],b,d;if(a.useArrows){c.push(a.arrowCls);a.lines=!1}if(a.lines){c.push(a.linesCls)}else {if(!a.useArrows){c.push(a.noLinesCls)}}b=a.applyStore(a.store);if(!b.getRoot()){b.setRoot({})}b.setRootVisible(a.rootVisible);a.viewConfig=Ext.apply({rootVisible:a.rootVisible,animate:a.enableAnimations,singleExpand:a.singleExpand,node:b.getRoot(),hideHeaders:a.hideHeaders,navigationModel:'tree'},a.viewConfig);if(!a.columns){if(a.initialConfig.hideHeaders===undefined){a.hideHeaders=!0}a.addCls(a.autoWidthCls);a.columns=[{xtype:'treecolumn',text:'Name',flex:1,dataIndex:a.displayField}]}if(a.cls){c.push(a.cls)}a.cls=c.join(' ');Ext.panel.Table.prototype.initComponent.call(this);d=a.getView();a.relayEvents(d,['beforecheckchange','checkchange','afteritemexpand','afteritemcollapse'])},applyStore:function(a){var b=this;if(Ext.isString(a)){a=b.store=Ext.StoreMgr.lookup(a)}else {if(!a||!a.isStore){a=Ext.apply({type:'tree',proxy:'memory'},a);if(b.root){a.root=b.root}if(b.fields){a.fields=b.fields}else {if(b.model){a.model=b.model}}if(b.folderSort){a.folderSort=b.folderSort}a=b.store=Ext.StoreMgr.lookup(a)}else {if(b.root){a=b.store=Ext.data.StoreManager.lookup(a);a.setRoot(b.root);if(b.folderSort!==undefined){a.folderSort=b.folderSort;a.sort()}}}}return a},setStore:function(a){var b=this;a=b.applyStore(a);if(!a.getRoot()){a.setRoot({})}a.setRootVisible(b.rootVisible);if(b.view){b.view.setRootNode(a.getRootNode())}b.bindStore(a)},bindStore:function(b,e){var a=this,c=b.getRoot(),d=a.bufferedRenderer;Ext.panel.Table.prototype.bindStore.apply(this,arguments);if(d){if(d.store){d.bindStore(b)}}b.singleExpand=a.singleExpand;a.storeListeners=a.mon(b,{destroyable:!0,rootchange:a.onRootChange,scope:a});a.storeRelayers=a.relayEvents(b,['beforeload','load']);if(!a.rootVisible&&!b.autoLoad&&!(c.isExpanded()||c.isLoading())){if(c.isLoaded()){c.data.expanded=!0;b.onNodeExpand(c,c.childNodes)}else {if(b.autoLoad!==!1){c.data.expanded=!1;c.expand()}}}b.ownerTree=a;if(!e){a.view.setRootNode(c)}},addRelayers:function(b){var a=this;if(a.rootRelayers){a.rootRelayers.destroy();a.rootRelayers=null}a.rootRelayers=a.mon(b,{destroyable:!0,append:a.createRelayer('itemappend'),remove:a.createRelayer('itemremove'),move:a.createRelayer('itemmove',[0,4]),insert:a.createRelayer('iteminsert'),beforeappend:a.createRelayer('beforeitemappend'),beforeremove:a.createRelayer('beforeitemremove'),beforemove:a.createRelayer('beforeitemmove'),beforeinsert:a.createRelayer('beforeiteminsert'),expand:a.createRelayer('itemexpand',[0,1]),collapse:a.createRelayer('itemcollapse',[0,1]),beforeexpand:a.createRelayer('beforeitemexpand',[0,1]),beforecollapse:a.createRelayer('beforeitemcollapse',[0,1]),scope:a})},unbindStore:function(){var a=this,b=a.store;if(b){Ext.panel.Table.prototype.unbindStore.call(this);Ext.destroy(a.storeListeners,a.storeRelayers,a.rootRelayers);delete b.ownerTree;b.singleExpand=null}},setRootNode:function(){return this.store.setRoot.apply(this.store,arguments)},getRootNode:function(){return this.store.getRoot()},onRootChange:function(a){this.view.setRootNode(a)},getChecked:function(){return this.getView().getChecked()},isItemChecked:function(a){return a.get('checked')},expandNode:function(b,d,a,c){return this.getView().expand(b,d,a,c||this)},collapseNode:function(b,d,a,c){return this.getView().collapse(b,d,a,c||this)},expandAll:function(c,d){var b=this,a=b.getRootNode();if(a){Ext.suspendLayouts();a.expand(!0,c,d||b);Ext.resumeLayouts(!0)}},collapseAll:function(d,a){var c=this,b=c.getRootNode(),e=c.getView();if(b){Ext.suspendLayouts();a=a||c;if(e.rootVisible){b.collapse(!0,d,a)}else {b.collapseChildren(!0,d,a)}Ext.resumeLayouts(!0)}},expandPath:function(p,a){var i=arguments,b=this,j=b.view,g=a&&a.field||b.store.model.idProperty,o,n,k=a&&a.separator||'/',c,e,d,h,f,m,l;if(a&&typeof a==='object'){g=a.field||b.store.model.idProperty;k=a.separator||'/';c=a.callback;e=a.scope;o=a.select;n=a.focus}else {g=i[1]||b.store.model.idProperty;k=i[2]||'/';c=i[3];e=i[4]}if(Ext.isEmpty(p)){return Ext.callback(c,e||b,[!1,null])}f=p.split(k);m=!f[0];if(m){d=b.getRootNode();h=1}else {d=b.store.findNode(g,f[0]);h=0}if(!d||m&&d.get(g)!==f[1]){return Ext.callback(c,e||b,[!1,d])}l=function(m){var d=this,q,k,i;if(++h===f.length){if(o){j.getSelectionModel().select(d)}if(n){j.getNavigationModel().setPosition(d,0)}return Ext.callback(c,e||b,[!0,d,j.getNode(d)])}for(k=0,q=m?m.length:0;k2?b[2]:null,e=a>3?b[3]:'/',d=a>4?b[4]:null,f=a>5?b[5]:!1;document.cookie=h+'='+escape(g)+(c===null?'':'; expires='+c.toUTCString())+(e===null?'':'; path='+e)+(d===null?'':'; domain='+d)+(f===!0?'; secure':'')},get:function(e){var d=document.cookie.split('; '),f=d.length,b,a,c;for(a=0;a'],childEls:['iframeEl'],initComponent:function(){Ext.Component.prototype.initComponent.call(this);this.frameName=this.frameName||this.id+'-frame'},initEvents:function(){var a=this;Ext.Component.prototype.initEvents.call(this);a.iframeEl.on('load',a.onLoad,a)},initRenderData:function(){return Ext.apply(Ext.Component.prototype.initRenderData.call(this),{src:this.src,frameName:this.frameName})},getBody:function(){var a=this.getDoc();return a.body||a.documentElement},getDoc:function(){try{return this.getWin().document}catch(b){return null}},getWin:function(){var a=this,b=a.frameName,c=Ext.isIE?a.iframeEl.dom.contentWindow:window.frames[b];return c},getFrame:function(){var a=this;return a.iframeEl.dom},beforeDestroy:function(){this.cleanupListeners(!0);Ext.Component.prototype.beforeDestroy.call(this)},cleanupListeners:function(c){var a,b;if(this.rendered){try{a=this.getDoc();if(a){Ext.get(a).un(this._docListeners);if(c){for(b in a){if(a.hasOwnProperty&&a.hasOwnProperty(b)){delete a[b]}}}}}catch(d){}}},onLoad:function(){var a=this,c=a.getDoc(),b=a.onRelayedEvent;if(c){try{Ext.get(c).on(a._docListeners={mousedown:b,mousemove:b,mouseup:b,click:b,dblclick:b,scope:a})}catch(d){}Ext.get(this.getWin()).on('beforeunload',a.cleanupListeners,a);this.el.unmask();this.fireEvent('load',this)}else {if(a.src){this.el.unmask();this.fireEvent('error',this)}}},onRelayedEvent:function(a){var b=this.iframeEl,c=b.getTrueXY(),e=a.getXY(),d=a.getTrueXY();a.xy=[c[0]+d[0],c[1]+d[1]];a.injectEvent(b);a.xy=e},load:function(c){var a=this,b=a.loadMask,d=a.getFrame();if(a.fireEvent('beforeload',a,c)!==!1){if(b&&a.el){a.el.mask(b)}d.src=a.src=c||a.src}}},0,['uxiframe'],['component','box','uxiframe'],{'component':!0,'box':!0,'uxiframe':!0},['widget.uxiframe'],0,[Ext.ux,'IFrame'],0);Ext.cmd.derive('Ext.ux.colorpick.Selection',Ext.Base,{mixinId:'colorselection',config:{format:'hex6',value:'FF0000',color:null,previousColor:null},applyColor:function(b){var a=b;if(Ext.isString(a)){a=Ext.ux.colorpick.ColorUtils.parseColor(b)}return a},applyValue:function(a){var b=Ext.ux.colorpick.ColorUtils.parseColor(a);return this.formatColor(b)},formatColor:function(a){return Ext.ux.colorpick.ColorUtils.formats[this.getFormat()](a)},updateColor:function(b){var a=this;if(!a.syncing){a.syncing=!0;a.setValue(a.formatColor(b));a.syncing=!1}},updateValue:function(b,c){var a=this;if(!a.syncing){a.syncing=!0;a.setColor(b);a.syncing=!1}this.fireEvent('change',a,b,c)}},0,0,0,0,0,0,[Ext.ux.colorpick,'Selection'],0);Ext.cmd.derive('Ext.ux.colorpick.ColorUtils',Ext.Base,function(a){var b=Ext.isIE&&Ext.ieVersion<10;return {singleton:!0,constructor:function(){a=this},backgroundTpl:b?"filter: progid:DXImageTransform.Microsoft.gradient(GradientType=0, startColorstr='#{alpha}{hex}', endColorstr='#{alpha}{hex}');":'background: {rgba};',setBackground:b?function(c,b){if(c){var f=Ext.XTemplate.getTpl(a,'backgroundTpl'),e={hex:a.rgb2hex(b.r,b.g,b.b),alpha:Math.floor(b.a*255).toString(16)},d=f.apply(e);c.applyStyles(d)}}:function(b,d){if(b){var f=Ext.XTemplate.getTpl(a,'backgroundTpl'),e={rgba:a.getRGBAString(d)},c=f.apply(e);b.applyStyles(c)}},formats:{HEX6:function(b){return a.rgb2hex(b.r,b.g,b.b)},HEX8:function(b){var c=a.rgb2hex(b.r,b.g,b.b),d=Math.round(b.a*255).toString(16);if(d.length<2){c+='0'}c+=d.toUpperCase();return c}},hexRe:/#?([0-9a-f]{3,8})/i,rgbaAltRe:/rgba\(\s*([\w#\d]+)\s*,\s*([\d\.]+)\s*\)/,rgbaRe:/rgba\(\s*([\d\.]+)\s*,\s*([\d\.]+)\s*,\s*([\d\.]+)\s*,\s*([\d\.]+)\s*\)/,rgbRe:/rgb\(\s*([\d\.]+)\s*,\s*([\d\.]+)\s*,\s*([\d\.]+)\s*\)/,parseColor:function(d){if(!d){return null}var e=this,f=e.colorMap[d],b,c,g;if(f){c={r:f[0],g:f[1],b:f[2],a:1}}else {if(d==='transparent'){c={r:0,g:0,b:0,a:0}}else {b=e.hexRe.exec(d);if(b){b=b[1];switch(b.length){default:return null;case 3:c={r:parseInt(b[0]+b[0],16),g:parseInt(b[1]+b[1],16),b:parseInt(b[2]+b[2],16),a:1};break;case 6:case 8:c={r:parseInt(b.substr(0,2),16),g:parseInt(b.substr(2,2),16),b:parseInt(b.substr(4,2),16),a:parseInt(b.substr(6,2)||'ff',16)/255};break;}}else {b=e.rgbaRe.exec(d);if(b){c={r:parseFloat(b[1]),g:parseFloat(b[2]),b:parseFloat(b[3]),a:parseFloat(b[4])}}else {b=e.rgbaAltRe.exec(d);if(b){c=e.parseColor(b[1]);c.a=parseFloat(b[2]);return c}b=e.rgbRe.exec(d);if(b){c={r:parseFloat(b[1]),g:parseFloat(b[2]),b:parseFloat(b[3]),a:1}}else {return null}}}}}g=this.rgb2hsv(c.r,c.g,c.b);return Ext.apply(c,g)},getRGBAString:function(b){return 'rgba('+b.r+','+b.g+','+b.b+','+b.a+')'},getRGBString:function(b){return 'rgb('+b.r+','+b.g+','+b.b+')'},hsv2rgb:function(e,i,h){e=e*360;if(e===360){e=0}var c=h*i;var g=e/60;var d=c*(1-Math.abs(g%2-1));var b=[0,0,0];switch(Math.floor(g)){case 0:b=[c,d,0];break;case 1:b=[d,c,0];break;case 2:b=[0,c,d];break;case 3:b=[0,d,c];break;case 4:b=[d,0,c];break;case 5:b=[c,0,d];break;default:break;}var f=h-c;b[0]+=f;b[1]+=f;b[2]+=f;b[0]=Math.round(b[0]*255);b[1]=Math.round(b[1]*255);b[2]=Math.round(b[2]*255);return {r:b[0],g:b[1],b:b[2]}},rgb2hsv:function(e,d,c){e=e/255;d=d/255;c=c/255;var g=Math.max(e,d,c);var k=Math.min(e,d,c);var f=g-k;var h=0;if(f!==0){if(g===e){h=(d-c)/f%6}else {if(g===d){h=(c-e)/f+2}else {if(g===c){h=(e-d)/f+4}}}}var b=h*60;if(b===360){b=0}var j=g;var i=0;if(f!==0){i=f/j}b=b/360;if(b<0){b=b+1}return {h:b,s:i,v:j}},rgb2hex:function(d,c,b){d=d.toString(16);c=c.toString(16);b=b.toString(16);if(d.length<2){d='0'+d}if(c.length<2){c='0'+c}if(b.length<2){b='0'+b}return (d+c+b).toUpperCase()},colorMap:{aliceblue:[240,248,255],antiquewhite:[250,235,215],aqua:[0,255,255],aquamarine:[127,255,212],azure:[240,255,255],beige:[245,245,220],bisque:[255,228,196],black:[0,0,0],blanchedalmond:[255,235,205],blue:[0,0,255],blueviolet:[138,43,226],brown:[165,42,42],burlywood:[222,184,135],cadetblue:[95,158,160],chartreuse:[127,255,0],chocolate:[210,105,30],coral:[255,127,80],cornflowerblue:[100,149,237],cornsilk:[255,248,220],crimson:[220,20,60],cyan:[0,255,255],darkblue:[0,0,139],darkcyan:[0,139,139],darkgoldenrod:[184,132,11],darkgray:[169,169,169],darkgreen:[0,100,0],darkgrey:[169,169,169],darkkhaki:[189,183,107],darkmagenta:[139,0,139],darkolivegreen:[85,107,47],darkorange:[255,140,0],darkorchid:[153,50,204],darkred:[139,0,0],darksalmon:[233,150,122],darkseagreen:[143,188,143],darkslateblue:[72,61,139],darkslategray:[47,79,79],darkslategrey:[47,79,79],darkturquoise:[0,206,209],darkviolet:[148,0,211],deeppink:[255,20,147],deepskyblue:[0,191,255],dimgray:[105,105,105],dimgrey:[105,105,105],dodgerblue:[30,144,255],firebrick:[178,34,34],floralwhite:[255,255,240],forestgreen:[34,139,34],fuchsia:[255,0,255],gainsboro:[220,220,220],ghostwhite:[248,248,255],gold:[255,215,0],goldenrod:[218,165,32],gray:[128,128,128],green:[0,128,0],greenyellow:[173,255,47],grey:[128,128,128],honeydew:[240,255,240],hotpink:[255,105,180],indianred:[205,92,92],indigo:[75,0,130],ivory:[255,255,240],khaki:[240,230,140],lavender:[230,230,250],lavenderblush:[255,240,245],lawngreen:[124,252,0],lemonchiffon:[255,250,205],lightblue:[173,216,230],lightcoral:[240,128,128],lightcyan:[224,255,255],lightgoldenrodyellow:[250,250,210],lightgray:[211,211,211],lightgreen:[144,238,144],lightgrey:[211,211,211],lightpink:[255,182,193],lightsalmon:[255,160,122],lightseagreen:[32,178,170],lightskyblue:[135,206,250],lightslategray:[119,136,153],lightslategrey:[119,136,153],lightsteelblue:[176,196,222],lightyellow:[255,255,224],lime:[0,255,0],limegreen:[50,205,50],linen:[250,240,230],magenta:[255,0,255],maroon:[128,0,0],mediumaquamarine:[102,205,170],mediumblue:[0,0,205],mediumorchid:[186,85,211],mediumpurple:[147,112,219],mediumseagreen:[60,179,113],mediumslateblue:[123,104,238],mediumspringgreen:[0,250,154],mediumturquoise:[72,209,204],mediumvioletred:[199,21,133],midnightblue:[25,25,112],mintcream:[245,255,250],mistyrose:[255,228,225],moccasin:[255,228,181],navajowhite:[255,222,173],navy:[0,0,128],oldlace:[253,245,230],olive:[128,128,0],olivedrab:[107,142,35],orange:[255,165,0],orangered:[255,69,0],orchid:[218,112,214],palegoldenrod:[238,232,170],palegreen:[152,251,152],paleturquoise:[175,238,238],palevioletred:[219,112,147],papayawhip:[255,239,213],peachpuff:[255,218,185],peru:[205,133,63],pink:[255,192,203],plum:[221,160,203],powderblue:[176,224,230],purple:[128,0,128],red:[255,0,0],rosybrown:[188,143,143],royalblue:[65,105,225],saddlebrown:[139,69,19],salmon:[250,128,114],sandybrown:[244,164,96],seagreen:[46,139,87],seashell:[255,245,238],sienna:[160,82,45],silver:[192,192,192],skyblue:[135,206,235],slateblue:[106,90,205],slategray:[119,128,144],slategrey:[119,128,144],snow:[255,255,250],springgreen:[0,255,127],steelblue:[70,130,180],tan:[210,180,140],teal:[0,128,128],thistle:[216,191,216],tomato:[255,99,71],turquoise:[64,224,208],violet:[238,130,238],wheat:[245,222,179],white:[255,255,255],whitesmoke:[245,245,245],yellow:[255,255,0],yellowgreen:[154,205,5]}}},1,0,0,0,0,0,[Ext.ux.colorpick,'ColorUtils'],function(c){var a=c.formats,b={};a['#HEX6']=function(b){return '#'+a.HEX6(b)};a['#HEX8']=function(b){return '#'+a.HEX8(b)};Ext.Object.each(a,function(a,d){b[a.toLowerCase()]=function(b){var e=d(b);return e.toLowerCase()}});Ext.apply(a,b)});Ext.cmd.derive('Ext.ux.colorpick.ColorMapController',Ext.app.ViewController,{onFirstBoxReady:function(){var a=this,c=a.getView(),d=c.down('#dragHandle'),b=d.dd;b.constrain=!0;b.constrainTo=c.getEl();b.initialConstrainTo=b.constrainTo;b.on('drag',Ext.bind(a.onHandleDrag,a));a.mon(c.getEl(),{mousedown:a.onMouseDown,dragstart:a.onDragStart,scope:a})},onHandleDrag:function(k,l){var h=this,a=h.getView(),e=a.down('#dragHandle'),i=e.getX()-a.getX(),j=e.getY()-a.getY(),d=a.getEl(),g=d.getWidth(),f=d.getHeight(),b=i/g,c=j/f;if(b>0.99){b=1}if(c>0.99){c=1}a.fireEvent('handledrag',b,c)},onMouseDown:function(b){var c=this,d=c.getView(),a=d.down('#dragHandle');a.setY(b.getY());a.setX(b.getX());c.onHandleDrag();a.dd.onMouseDown(b,a.dd.el)},onDragStart:function(d){var c=this,b=c.getView(),a=b.down('#dragHandle');a.dd.onDragStart(d,a.dd.el)},onMapClick:function(h){var f=this,a=f.getView(),g=a.down('#dragHandle'),c=a.getXY(),d=h.getXY(),b,e;b=d[0]-c[0];e=d[1]-c[1];g.getEl().setStyle({left:b+'px',top:e+'px'});f.onHandleDrag()},onColorBindingChanged:function(n){var i=this,m=i.getViewModel(),a=m.get('selectedColor'),b,d=i.getView(),l=d.down('#dragHandle'),c=d.getEl(),k=c.getWidth(),j=c.getHeight(),e,f,g,h;b=Ext.ux.colorpick.ColorUtils.rgb2hsv(a.r,a.g,a.b);e=b.s;g=k*e;f=1-b.v;h=j*f;l.getEl().setStyle({left:g+'px',top:h+'px'})},onHueBindingChanged:function(d){var c=this,e=c.getViewModel(),a,b;a=Ext.ux.colorpick.ColorUtils.hsv2rgb(d,1,1);b=Ext.ux.colorpick.ColorUtils.rgb2hex(a.r,a.g,a.b);c.getView().getEl().applyStyles({'background-color':'#'+b})}},0,0,0,0,['controller.colorpickercolormapcontroller'],0,[Ext.ux.colorpick,'ColorMapController'],0);Ext.cmd.derive('Ext.ux.colorpick.ColorMap',Ext.container.Container,{controller:'colorpickercolormapcontroller',cls:'x-colorpicker-colormap',items:[{xtype:'component',cls:'x-colorpicker-colormap-draghandle-container',itemId:'dragHandle',width:1,height:1,draggable:!0,html:'
    '}],listeners:{boxready:{single:!0,fn:'onFirstBoxReady',scope:'controller'},colorbindingchanged:{fn:'onColorBindingChanged',scope:'controller'},huebindingchanged:{fn:'onHueBindingChanged',scope:'controller'}},afterRender:function(){var c=this,a=c.mapGradientUrl,b=c.el;Ext.container.Container.prototype.afterRender.call(this);if(!a){a=b.getStyle('background-image');a=a.substring(4,a.length-1);if(a.indexOf('"')===0){a=a.substring(1,a.length-1)}Ext.ux.colorpick.ColorMap.prototype.mapGradientUrl=a}b.setStyle('background-image','none');b=c.layout.getElementTarget();b.createChild({tag:'img',cls:'x-colorpicker-colormap-blender',src:a})},setPosition:function(c){var b=this,a=b.down('#dragHandle');if(!a.dd||!a.dd.constrain){return}if(typeof a.dd.dragEnded!=='undefined'&&!a.dd.dragEnded){return}b.fireEvent('colorbindingchanged',c)},setHue:function(b){var a=this;if(!a.getEl()){return}a.fireEvent('huebindingchanged',b)}},0,['colorpickercolormap'],['component','box','container','colorpickercolormap'],{'component':!0,'box':!0,'container':!0,'colorpickercolormap':!0},['widget.colorpickercolormap'],0,[Ext.ux.colorpick,'ColorMap'],0);Ext.cmd.derive('Ext.ux.colorpick.SelectorModel',Ext.app.ViewModel,{data:{selectedColor:{r:255,g:255,b:255,h:0,s:1,v:1,a:1},previousColor:{r:0,g:0,b:0,h:0,s:1,v:1,a:1}},formulas:{hex:{get:function(a){var e=a('selectedColor.r').toString(16),d=a('selectedColor.g').toString(16),c=a('selectedColor.b').toString(16),b;b=Ext.ux.colorpick.ColorUtils.rgb2hex(e,d,c);return '#'+b},set:function(a){var b=Ext.ux.colorpick.ColorUtils.hex2rgb(a);this.changeRGB(b)}},red:{get:function(a){return a('selectedColor.r')},set:function(a){this.changeRGB({r:a})}},green:{get:function(a){return a('selectedColor.g')},set:function(a){this.changeRGB({g:a})}},blue:{get:function(a){return a('selectedColor.b')},set:function(a){this.changeRGB({b:a})}},hue:{get:function(a){return a('selectedColor.h')*360},set:function(a){this.changeHSV({h:a/360})}},saturation:{get:function(a){return a('selectedColor.s')*100},set:function(a){this.changeHSV({s:a/100})}},value:{get:function(a){var b=a('selectedColor.v');return b*100},set:function(a){this.changeHSV({v:a/100})}},alpha:{get:function(a){var b=a('selectedColor.a');return b*100},set:function(a){this.set('selectedColor',Ext.applyIf({a:a/100},this.data.selectedColor))}}},changeHSV:function(a){Ext.applyIf(a,this.data.selectedColor);var b=Ext.ux.colorpick.ColorUtils.hsv2rgb(a.h,a.s,a.v);a.r=b.r;a.g=b.g;a.b=b.b;this.set('selectedColor',a)},changeRGB:function(a){Ext.applyIf(a,this.data.selectedColor);var b=Ext.ux.colorpick.ColorUtils.rgb2hsv(a.r,a.g,a.b);a.h=b.h;a.s=b.s;a.v=b.v;this.set('selectedColor',a)}},0,0,0,0,['viewmodel.colorpick-selectormodel'],0,[Ext.ux.colorpick,'SelectorModel'],0);Ext.cmd.derive('Ext.ux.colorpick.SelectorController',Ext.app.ViewController,{initViewModel:function(){var b=this,a=b.getView();a.childViewModel.bind('{selectedColor}',function(b){a.setColor(b)})},destroy:function(){var c=this,b=c.getView(),a=b.childViewModel;if(a){a.destroy();b.childViewModel=null}Ext.app.ViewController.prototype.destroy.call(this)},changeHSV:function(a){var b=this.getView(),d=b.getColor(),c;Ext.applyIf(a,d);c=Ext.ux.colorpick.ColorUtils.hsv2rgb(a.h,a.s,a.v);Ext.apply(a,c);b.setColor(a)},onColorMapHandleDrag:function(a,b){this.changeHSV({s:a,v:1-b})},onValueSliderHandleDrag:function(a){this.changeHSV({v:1-a})},onSaturationSliderHandleDrag:function(a){this.changeHSV({s:1-a})},onHueSliderHandleDrag:function(a){this.changeHSV({h:1-a})},onAlphaSliderHandleDrag:function(c){var a=this.getView(),d=a.getColor(),b=Ext.applyIf({a:1-c},d);a.setColor(b);a.el.repaint()},onPreviousColorSelected:function(c,a){var b=this.getView();b.setColor(a)},onOK:function(){var b=this,a=b.getView();a.fireEvent('ok',a,a.getValue())},onCancel:function(){this.fireViewEvent('cancel',this.getView())},onResize:function(){var c=this,h=c.getView(),b=h.childViewModel,a=c.getReferences(),d,f,g,e;if(!c.hasResizedOnce){c.hasResizedOnce=!0;return}d=b.get('hue');f=b.get('saturation');g=b.get('value');e=b.get('alpha');console.log('h='+d);a.colorMap.setPosition(b.getData());a.hueSlider.setHue(d);a.satSlider.setSaturation(f);a.valueSlider.setValue(g);a.alphaSlider.setAlpha(e)}},0,0,0,0,['controller.colorpick-selectorcontroller'],0,[Ext.ux.colorpick,'SelectorController'],0);Ext.cmd.derive('Ext.ux.colorpick.ColorPreview',Ext.Component,{style:'position: relative',html:'
    ',cls:'x-colorpreview',height:256,onRender:function(){var a=this;Ext.Component.prototype.onRender.apply(this,arguments);a.mon(a.el.down('.btn'),'click',a.onClick,a)},onClick:function(){this.fireEvent('click',this,this.color)},setColor:function(b){var a=this,c=a.getEl();if(!c){return}a.color=b;a.applyBgStyle(b)},bgStyleTpl:Ext.create('Ext.XTemplate',Ext.isIE&&Ext.ieVersion<10?"filter: progid:DXImageTransform.Microsoft.gradient(GradientType=0, startColorstr='#{hexAlpha}{hex}', endColorstr='#{hexAlpha}{hex}');":'background: {rgba};'),applyBgStyle:function(a){var h=this,b=Ext.ux.colorpick.ColorUtils,g=h.getEl().down('.filter'),f,d,e,c;f=b.rgb2hex(a.r,a.g,a.b);d=Ext.util.Format.hex(Math.floor(a.a*255),2);e=b.getRGBAString(a);c=this.bgStyleTpl.apply({hex:f,hexAlpha:d,rgba:e});g.applyStyles(c)}},0,['colorpickercolorpreview'],['component','box','colorpickercolorpreview'],{'component':!0,'box':!0,'colorpickercolorpreview':!0},['widget.colorpickercolorpreview'],0,[Ext.ux.colorpick,'ColorPreview'],0);Ext.cmd.derive('Ext.ux.colorpick.SliderController',Ext.app.ViewController,{boxReady:function(e){var b=this,d=b.getDragContainer(),c=b.getDragHandle(),a=c.dd;a.constrain=!0;a.constrainTo=d.getEl();a.initialConstrainTo=a.constrainTo;a.on('drag',b.onHandleDrag,b)},getDragHandle:function(){return this.view.lookupReference('dragHandle')},getDragContainer:function(){return this.view.lookupReference('dragHandleContainer')},onHandleDrag:function(i){var b=this,g=b.getView(),c=b.getDragContainer(),f=b.getDragHandle(),h=f.getY()-c.getY(),e=c.getEl(),d=e.getHeight(),a=h/d;if(a>0.99){a=1}g.fireEvent('handledrag',a)},onMouseDown:function(c){var b=this,a=b.getDragHandle(),d=c.getY();a.setY(d);b.onHandleDrag();a.el.repaint();a.dd.onMouseDown(c,a.dd.el)},onDragStart:function(c){var b=this,a=b.getDragHandle();a.dd.onDragStart(c,a.dd.el)},onMouseUp:function(){var a=this.getDragHandle();a.dd.dragEnded=!0}},0,0,0,0,['controller.colorpick-slidercontroller'],0,[Ext.ux.colorpick,'SliderController'],0);Ext.cmd.derive('Ext.ux.colorpick.Slider',Ext.container.Container,{controller:'colorpick-slidercontroller',baseCls:'x-colorpicker-slider',layout:'center',referenceHolder:!0,listeners:{element:'el',mousedown:'onMouseDown',mouseup:'onMouseUp',dragstart:'onDragStart'},items:{xtype:'container',cls:'x-colorpicker-draghandle-container',reference:'dragHandleContainer',height:'100%',items:{xtype:'component',cls:'x-colorpicker-draghandle-outer',reference:'dragHandle',width:'100%',height:1,draggable:!0,html:'
    '}},getDragHandle:function(){return this.lookupReference('dragHandle')},getDragContainer:function(){return this.lookupReference('dragHandleContainer')}},0,['colorpickerslider'],['component','box','container','colorpickerslider'],{'component':!0,'box':!0,'container':!0,'colorpickerslider':!0},['widget.colorpickerslider'],0,[Ext.ux.colorpick,'Slider'],0);Ext.cmd.derive('Ext.ux.colorpick.SliderAlpha',Ext.ux.colorpick.Slider,{cls:'x-colorpicker-alpha',gradientStyleTpl:Ext.create('Ext.XTemplate',Ext.isIE&&Ext.ieVersion<10?"filter: progid:DXImageTransform.Microsoft.gradient(GradientType=0, startColorstr='#FF{hex}', endColorstr='#00{hex}');":'background: -mox-linear-gradient(top, rgba({r}, {g}, {b}, 1) 0%, rgba({r}, {g}, {b}, 0) 100%);background: -webkit-linear-gradient(top,rgba({r}, {g}, {b}, 1) 0%, rgba({r}, {g}, {b}, 0) 100%);background: -o-linear-gradient(top, rgba({r}, {g}, {b}, 1) 0%, rgba({r}, {g}, {b}, 0) 100%);background: -ms-linear-gradient(top, rgba({r}, {g}, {b}, 1) 0%, rgba({r}, {g}, {b}, 0) 100%);background: linear-gradient(to bottom, rgba({r}, {g}, {b}, 1) 0%, rgba({r}, {g}, {b}, 0) 100%);'),setAlpha:function(h){var d=this,g=d.getDragContainer(),a=d.getDragHandle(),f=g.getEl(),e=f.getHeight(),c,b;if(!a.dd||!a.dd.constrain){return}if(typeof a.dd.dragEnded!=='undefined'&&!a.dd.dragEnded){return}b=e*(1-h/100);c=a.getEl();c.setStyle({top:b})},setColor:function(a){var b=this,e=b.getDragContainer(),c,d;if(!b.getEl()){return}c=Ext.ux.colorpick.ColorUtils.rgb2hex(a.r,a.g,a.b);d=e.getEl().down('.x-autocontainer-innerCt');d.applyStyles(b.gradientStyleTpl.apply({hex:c,r:a.r,g:a.g,b:a.b}))}},0,['colorpickerslideralpha'],['component','box','container','colorpickerslider','colorpickerslideralpha'],{'component':!0,'box':!0,'container':!0,'colorpickerslider':!0,'colorpickerslideralpha':!0},['widget.colorpickerslideralpha'],0,[Ext.ux.colorpick,'SliderAlpha'],0);Ext.cmd.derive('Ext.ux.colorpick.SliderSaturation',Ext.ux.colorpick.Slider,{cls:'x-colorpicker-saturation',gradientStyleTpl:Ext.create('Ext.XTemplate',Ext.isIE&&Ext.ieVersion<10?"filter: progid:DXImageTransform.Microsoft.gradient(GradientType=0, startColorstr='#{hex}', endColorstr='#ffffff');":'background: -mox-linear-gradient(top, #{hex} 0%, #ffffff 100%);background: -webkit-linear-gradient(top, #{hex} 0%,#ffffff 100%);background: -o-linear-gradient(top, #{hex} 0%,#ffffff 100%);background: -ms-linear-gradient(top, #{hex} 0%,#ffffff 100%);background: linear-gradient(to bottom, #{hex} 0%,#ffffff 100%);'),setSaturation:function(g){var d=this,h=d.getDragContainer(),a=d.getDragHandle(),f=h.getEl(),e=f.getHeight(),b,c;if(!a.dd||!a.dd.constrain){return}if(typeof a.dd.dragEnded!=='undefined'&&!a.dd.dragEnded){return}b=1-g/100;c=e*b;a.getEl().setStyle({top:c+'px'})},setHue:function(e){var b=this,d=b.getDragContainer(),a,c;if(!b.getEl()){return}a=Ext.ux.colorpick.ColorUtils.hsv2rgb(e,1,1);c=Ext.ux.colorpick.ColorUtils.rgb2hex(a.r,a.g,a.b);d.getEl().applyStyles(b.gradientStyleTpl.apply({hex:c}))}},0,['colorpickerslidersaturation'],['component','box','container','colorpickerslider','colorpickerslidersaturation'],{'component':!0,'box':!0,'container':!0,'colorpickerslider':!0,'colorpickerslidersaturation':!0},['widget.colorpickerslidersaturation'],0,[Ext.ux.colorpick,'SliderSaturation'],0);Ext.cmd.derive('Ext.ux.colorpick.SliderValue',Ext.ux.colorpick.Slider,{cls:'x-colorpicker-value',gradientStyleTpl:Ext.create('Ext.XTemplate',Ext.isIE&&Ext.ieVersion<10?"filter: progid:DXImageTransform.Microsoft.gradient(GradientType=0, startColorstr='#{hex}', endColorstr='#000000');":'background: -mox-linear-gradient(top, #{hex} 0%, #000000 100%);background: -webkit-linear-gradient(top, #{hex} 0%,#000000 100%);background: -o-linear-gradient(top, #{hex} 0%,#000000 100%);background: -ms-linear-gradient(top, #{hex} 0%,#000000 100%);background: linear-gradient(to bottom, #{hex} 0%,#000000 100%);'),setValue:function(h){var d=this,g=d.getDragContainer(),a=d.getDragHandle(),f=g.getEl(),e=f.getHeight(),b,c;if(!a.dd||!a.dd.constrain){return}if(typeof a.dd.dragEnded!=='undefined'&&!a.dd.dragEnded){return}b=1-h/100;c=e*b;a.getEl().setStyle({top:c+'px'})},setHue:function(e){var b=this,d=b.getDragContainer(),a,c;if(!b.getEl()){return}a=Ext.ux.colorpick.ColorUtils.hsv2rgb(e,1,1);c=Ext.ux.colorpick.ColorUtils.rgb2hex(a.r,a.g,a.b);d.getEl().applyStyles(b.gradientStyleTpl.apply({hex:c}))}},0,['colorpickerslidervalue'],['component','box','container','colorpickerslider','colorpickerslidervalue'],{'component':!0,'box':!0,'container':!0,'colorpickerslider':!0,'colorpickerslidervalue':!0},['widget.colorpickerslidervalue'],0,[Ext.ux.colorpick,'SliderValue'],0);Ext.cmd.derive('Ext.ux.colorpick.SliderHue',Ext.ux.colorpick.Slider,{cls:'x-colorpicker-hue',afterRender:function(){var c=this,a=c.gradientUrl,b=c.el;Ext.ux.colorpick.Slider.prototype.afterRender.call(this);if(!a){a=b.getStyle('background-image');a=a.substring(4,a.length-1);if(a.indexOf('"')===0){a=a.substring(1,a.length-1)}Ext.ux.colorpick.SliderHue.prototype.gradientUrl=a}b.setStyle('background-image','none');b=c.getDragContainer().layout.getElementTarget();b.createChild({tag:'img',cls:'x-colorpicker-hue-gradient',src:a})},setHue:function(h){var d=this,g=d.getDragContainer(),a=d.getDragHandle(),f=g.getEl(),e=f.getHeight(),c,b;if(!a.dd||!a.dd.constrain){return}if(typeof a.dd.dragEnded!=='undefined'&&!a.dd.dragEnded){return}b=e*(360-h)/360;c=a.getEl();c.setStyle({top:b+'px'})}},0,['colorpickersliderhue'],['component','box','container','colorpickerslider','colorpickersliderhue'],{'component':!0,'box':!0,'container':!0,'colorpickerslider':!0,'colorpickersliderhue':!0},['widget.colorpickersliderhue'],0,[Ext.ux.colorpick,'SliderHue'],0);Ext.cmd.derive('Ext.ux.colorpick.Selector',Ext.container.Container,{controller:'colorpick-selectorcontroller',width:580,height:337,cls:'x-colorpicker',padding:10,layout:{type:'hbox',align:'stretch'},defaultBindProperty:'value',twoWayBindable:['value'],fieldWidth:50,fieldPad:5,showPreviousColor:!1,showOkCancelButtons:!1,listeners:{resize:'onResize'},constructor:function(c){var a=this,b=Ext.Factory.viewModel('colorpick-selectormodel');a.childViewModel=b;a.items=[a.getMapAndHexRGBFields(b),a.getSliderAndHField(b),a.getSliderAndSField(b),a.getSliderAndVField(b),a.getSliderAndAField(b),a.getPreviewAndButtons(b,c)];Ext.container.Container.prototype.constructor.apply(this,arguments)},updateColor:function(b){var a=this;a.mixins.colorselection.updateColor.call(a,b);a.childViewModel.set('selectedColor',b)},updatePreviousColor:function(a){this.childViewModel.set('previousColor',a)},getMapAndHexRGBFields:function(d){var c=this,a={top:0,right:c.fieldPad,bottom:0,left:0},b=c.fieldWidth;return {xtype:'container',viewModel:d,cls:'x-colorpicker-escape-overflow',flex:1,layout:{type:'vbox',align:'stretch'},margin:'0 10 0 0',items:[{xtype:'colorpickercolormap',reference:'colorMap',flex:1,bind:{position:{bindTo:'{selectedColor}',deep:!0},hue:'{selectedColor.h}'},listeners:{handledrag:'onColorMapHandleDrag'}},{xtype:'container',layout:'hbox',defaults:{labelAlign:'top',labelSeparator:'',allowBlank:!1,onChange:function(){if(this.isValid()){Ext.form.field.Base.prototype.onChange.apply(this,arguments)}}},items:[{xtype:'textfield',fieldLabel:'HEX',flex:1,bind:'{hex}',margin:a,readOnly:!0},{xtype:'numberfield',fieldLabel:'R',bind:'{red}',width:b,hideTrigger:!0,maxValue:255,minValue:0,margin:a},{xtype:'numberfield',fieldLabel:'G',bind:'{green}',width:b,hideTrigger:!0,maxValue:255,minValue:0,margin:a},{xtype:'numberfield',fieldLabel:'B',bind:'{blue}',width:b,hideTrigger:!0,maxValue:255,minValue:0,margin:0}]}]}},getSliderAndHField:function(b){var a=this;return {xtype:'container',viewModel:b,cls:'x-colorpicker-escape-overflow',width:a.fieldWidth,layout:{type:'vbox',align:'stretch'},items:[{xtype:'colorpickersliderhue',reference:'hueSlider',flex:1,bind:{hue:'{selectedColor.h}'},listeners:{handledrag:'onHueSliderHandleDrag'}},{xtype:'numberfield',fieldLabel:'H',labelAlign:'top',width:a.fieldWidth,labelSeparator:'',bind:'{hue}',hideTrigger:!0,maxValue:360,minValue:0,allowBlank:!1,margin:0}]}},getSliderAndSField:function(b){var a=this;return {xtype:'container',viewModel:b,cls:'x-colorpicker-escape-overflow',width:a.fieldWidth,layout:{type:'vbox',align:'stretch'},margin:{right:a.fieldPad,left:a.fieldPad},items:[{xtype:'colorpickerslidersaturation',reference:'satSlider',flex:1,bind:{saturation:'{saturation}',hue:'{selectedColor.h}'},listeners:{handledrag:'onSaturationSliderHandleDrag'}},{xtype:'numberfield',fieldLabel:'S',labelAlign:'top',labelSeparator:'',bind:'{saturation}',hideTrigger:!0,maxValue:100,minValue:0,allowBlank:!1,margin:0}]}},getSliderAndVField:function(a){var b=this;return {xtype:'container',viewModel:a,cls:'x-colorpicker-escape-overflow',width:b.fieldWidth,layout:{type:'vbox',align:'stretch'},items:[{xtype:'colorpickerslidervalue',reference:'valueSlider',flex:1,bind:{value:'{value}',hue:'{selectedColor.h}'},listeners:{handledrag:'onValueSliderHandleDrag'}},{xtype:'numberfield',fieldLabel:'V',labelAlign:'top',labelSeparator:'',bind:'{value}',hideTrigger:!0,maxValue:100,minValue:0,allowBlank:!1,margin:0}]}},getSliderAndAField:function(b){var a=this;return {xtype:'container',viewModel:b,cls:'x-colorpicker-escape-overflow',width:a.fieldWidth,layout:{type:'vbox',align:'stretch'},margin:{left:a.fieldPad},items:[{xtype:'colorpickerslideralpha',reference:'alphaSlider',flex:1,bind:{alpha:'{alpha}',color:{bindTo:'{selectedColor}',deep:!0}},listeners:{handledrag:'onAlphaSliderHandleDrag'}},{xtype:'numberfield',fieldLabel:'A',labelAlign:'top',labelSeparator:'',bind:'{alpha}',hideTrigger:!0,maxValue:100,minValue:0,allowBlank:!1,margin:0}]}},getPreviewAndButtons:function(c,b){var a=[{xtype:'colorpickercolorpreview',flex:1,bind:{color:{bindTo:'{selectedColor}',deep:!0}}}];if(b.showPreviousColor){a.push({xtype:'colorpickercolorpreview',flex:1,bind:{color:{bindTo:'{previousColor}',deep:!0}},listeners:{click:'onPreviousColorSelected'}})}if(b.showOkCancelButtons){a.push({xtype:'button',text:'OK',margin:'10 0 0 0',handler:'onOK'},{xtype:'button',text:'Cancel',margin:'10 0 0 0',handler:'onCancel'})}return {xtype:'container',viewModel:c,width:70,margin:'0 0 0 10',items:a,layout:{type:'vbox',align:'stretch'}}}},1,['colorselector'],['component','box','container','colorselector'],{'component':!0,'box':!0,'container':!0,'colorselector':!0},['widget.colorselector'],[[Ext.ux.colorpick.Selection.prototype.mixinId||Ext.ux.colorpick.Selection.$className,Ext.ux.colorpick.Selection]],[Ext.ux.colorpick,'Selector'],0);Ext.cmd.derive('Ext.ux.colorpick.ButtonController',Ext.app.ViewController,{afterRender:function(a){a.updateColor(a.getColor())},destroy:function(){var a=this.getView(),b=a.colorPickerWindow;if(b){b.destroy();a.colorPickerWindow=a.colorPicker=null}Ext.app.ViewController.prototype.destroy.call(this)},getPopup:function(){var b=this.getView(),a=b.colorPickerWindow,c;if(!a){a=Ext.create(b.getPopup());b.colorPickerWindow=a;a.colorPicker=b.colorPicker=c=a.lookupReference('selector');c.setFormat(b.getFormat());c.on({ok:'onColorPickerOK',cancel:'onColorPickerCancel',scope:this});a.on({close:'onColorPickerCancel',scope:this})}return a},onClick:function(){var e=this,d=e.getView(),b=d.getColor(),c=e.getPopup(),a=c.colorPicker;a.setColor(b);a.setPreviousColor(b);c.showBy(d,'tl-br?')},onColorPickerOK:function(b){var a=this.getView(),c=b.getColor(),d=a.colorPickerWindow;d.hide();a.setColor(c)},onColorPickerCancel:function(){var b=this.getView(),a=b.colorPickerWindow;a.hide()},syncColor:function(a){var b=this.getView();Ext.ux.colorpick.ColorUtils.setBackground(b.filterEl,a)}},0,0,0,0,['controller.colorpick-buttoncontroller'],0,[Ext.ux.colorpick,'ButtonController'],0);Ext.cmd.derive('Ext.ux.colorpick.Button',Ext.Component,{controller:'colorpick-buttoncontroller',baseCls:'x-colorpicker-button',width:20,height:20,childEls:['btnEl','filterEl'],config:{popup:{lazy:!0,$value:{xtype:'window',closeAction:'hide',referenceHolder:!0,minWidth:540,minHeight:200,layout:'fit',header:!1,resizable:!0,items:{xtype:'colorselector',reference:'selector',showPreviousColor:!0,showOkCancelButtons:!0}}}},defaultBindProperty:'value',twoWayBindable:'value',renderTpl:'
    ',listeners:{click:'onClick',element:'btnEl'},updateColor:function(b){var a=this,c=a.colorPicker;a.mixins.colorselection.updateColor.call(a,b);Ext.ux.colorpick.ColorUtils.setBackground(a.filterEl,b);if(c){c.setColor(b)}},updateFormat:function(b){var a=this.colorPicker;if(a){a.setFormat(b)}}},0,['colorbutton'],['component','box','colorbutton'],{'component':!0,'box':!0,'colorbutton':!0},['widget.colorbutton'],[[Ext.ux.colorpick.Selection.prototype.mixinId||Ext.ux.colorpick.Selection.$className,Ext.ux.colorpick.Selection]],[Ext.ux.colorpick,'Button'],0);Ext.cmd.derive('Ext.ux.colorpick.Field',Ext.form.field.Picker,{editable:!1,matchFieldWidth:!1,beforeBodyEl:['
    '],cls:'x-colorpicker-field',childEls:['swatchEl'],config:{popup:{lazy:!0,$value:{xtype:'window',closeAction:'hide',referenceHolder:!0,minWidth:540,minHeight:200,layout:'fit',header:!1,resizable:!0,items:{xtype:'colorselector',reference:'selector',showPreviousColor:!0,showOkCancelButtons:!0}}}},afterRender:function(){Ext.form.field.Picker.prototype.afterRender.call(this);this.updateValue(this.value)},createPicker:function(){var a=this,c=a.getPopup(),b;a.colorPickerWindow=c=Ext.create(c);a.colorPicker=b=c.lookupReference('selector');b.setFormat(a.getFormat());b.setColor(a.getColor());b.on({ok:'onColorPickerOK',cancel:'onColorPickerCancel',scope:a});c.on({close:'onColorPickerCancel',scope:a});return a.colorPickerWindow},onColorPickerOK:function(a){this.setColor(a.getColor());this.collapse()},onColorPickerCancel:function(){this.collapse()},onExpand:function(){var a=this.getColor();this.colorPicker.setPreviousColor(a)},setValue:function(c){var a=this,b=a.applyValue(c);(arguments.callee.$previous||Ext.form.field.Picker.prototype.setValue).call(this,b);a.updateValue(b)},updateFormat:function(b){var a=this.colorPicker;if(a){a.setFormat(b)}},updateValue:function(c){var a=this,b;if(!a.syncing){a.syncing=!0;a.setColor(c);a.syncing=!1}b=a.getColor();Ext.ux.colorpick.ColorUtils.setBackground(a.swatchEl,b);if(a.colorPicker){a.colorPicker.setColor(b)}}},0,['colorfield'],['component','box','field','textfield','pickerfield','colorfield'],{'component':!0,'box':!0,'field':!0,'textfield':!0,'pickerfield':!0,'colorfield':!0},['widget.colorfield'],[[Ext.ux.colorpick.Selection.prototype.mixinId||Ext.ux.colorpick.Selection.$className,Ext.ux.colorpick.Selection]],[Ext.ux.colorpick,'Field'],0);Ext.cmd.derive('Ext.ux.rating.Picker',Ext.Widget,{focusable:!0,cachedConfig:{family:'monospace',glyphs:'☆★',minimum:1,limit:5,overStyle:null,rounding:1,scale:'125%',selectedStyle:null,tooltip:null,trackOver:!0,value:null,tooltipText:null,trackingValue:null},config:{animate:null},element:{cls:'ux-rating-picker',reference:'element',children:[{reference:'innerEl',cls:'ux-rating-picker-inner',listeners:{click:'onClick',mousemove:'onMouseMove',mouseenter:'onMouseEnter',mouseleave:'onMouseLeave'},children:[{reference:'valueEl',cls:'ux-rating-picker-value'},{reference:'trackerEl',cls:'ux-rating-picker-tracker'}]}]},defaultBindProperty:'value',twoWayBindable:'value',overCls:'ux-rating-picker-over',trackOverCls:'ux-rating-picker-track-over',applyGlyphs:function(a){if(typeof a==='string'){a=[a.charAt(0),a.charAt(1)]}else {if(typeof a[0]==='number'){a=[String.fromCharCode(a[0]),String.fromCharCode(a[1])]}}return a},applyOverStyle:function(a){this.trackerEl.applyStyles(a)},applySelectedStyle:function(a){this.valueEl.applyStyles(a)},applyTooltip:function(a){if(a&&typeof a!=='function'){if(!a.isTemplate){a=new Ext.XTemplate(a)}a=a.apply.bind(a)}return a},applyTrackingValue:function(a){return this.applyValue(a)},applyValue:function(a){if(a!==null){var b=this.getRounding(),c=this.getLimit(),d=this.getMinimum();a=Math.round(Math.round(a/b)*b*1000)/1000;a=ac?c:a}return a},onClick:function(a){var b=this.valueFromEvent(a);this.setValue(b)},onMouseEnter:function(){this.element.addCls(this.overCls)},onMouseLeave:function(){this.element.removeCls(this.overCls)},onMouseMove:function(a){var b=this.valueFromEvent(a);this.setTrackingValue(b)},updateFamily:function(a){this.element.setStyle('fontFamily',"'"+a+"'")},updateGlyphs:function(){this.refreshGlyphs()},updateLimit:function(){this.refreshGlyphs()},updateScale:function(a){this.element.setStyle('fontSize',a)},updateTooltip:function(){this.refreshTooltip()},updateTooltipText:function(c){var e=this.innerEl,b=Ext.tip&&Ext.tip.QuickTipManager,d=b&&b.tip,a;if(b){e.dom.setAttribute('data-qtip',c);this.trackerEl.dom.setAttribute('data-qtip',c);a=d&&d.activeTarget;a=a&&a.el;if(a&&e.contains(a)){d.update(c)}}},updateTrackingValue:function(d){var a=this,b=a.trackerEl,c=a.valueToPercent(d);b.setStyle('width',c);a.refreshTooltip()},updateTrackOver:function(a){this.element[a?'addCls':'removeCls'](this.trackOverCls)},updateValue:function(e,g){var a=this,h=a.getAnimate(),c=a.valueEl,f=a.valueToPercent(e),b,d;if(a.isConfiguring||!h){c.setStyle('width',f)}else {c.stopAnimation();c.animate(Ext.merge({from:{width:a.valueToPercent(g)},to:{width:f}},h))}a.refreshTooltip();if(!a.isConfiguring){if(a.hasListeners.change){a.fireEvent('change',a,e,g)}b=a.getWidgetColumn&&a.getWidgetColumn();d=b&&a.getWidgetRecord&&a.getWidgetRecord();if(d&&b.dataIndex){d.set(b.dataIndex,e)}}},afterCachedConfig:function(){this.refresh();return Ext.Widget.prototype.afterCachedConfig.apply(this,arguments)},initConfig:function(a){this.isConfiguring=!0;this.callParent([a]);this.refresh()},setConfig:function(){var a=this;a.isReconfiguring=!0;a.callParent(arguments);a.isReconfiguring=!1;a.refresh();return a},destroy:function(){this.tip=Ext.destroy(this.tip);Ext.Widget.prototype.destroy.call(this)},privates:{getGlyphTextNode:function(b){var a=b.lastChild;if(!a||a.nodeType!==3){a=b.ownerDocument.createTextNode('');b.appendChild(a)}return a},getTooltipData:function(){var a=this;return {component:a,tracking:a.getTrackingValue(),trackOver:a.getTrackOver(),value:a.getValue()}},refresh:function(){var a=this;if(a.invalidGlyphs){a.refreshGlyphs(!0)}if(a.invalidTooltip){a.refreshTooltip(!0)}},refreshGlyphs:function(j){var a=this,g=!j&&(a.isConfiguring||a.isReconfiguring),i,c,h,b,d,e,f;if(!g){i=a.getGlyphTextNode(a.innerEl.dom);f=a.getGlyphTextNode(a.valueEl.dom);e=a.getGlyphTextNode(a.trackerEl.dom);c=a.getGlyphs();h=a.getLimit();for(b=d='';h--;){d+=c[0];b+=c[1]}i.nodeValue=d;f.nodeValue=b;e.nodeValue=b}a.invalidGlyphs=g},refreshTooltip:function(f){var a=this,c=!f&&(a.isConfiguring||a.isReconfiguring),b=a.getTooltip(),d,e;if(!c){b=a.getTooltip();if(b){d=a.getTooltipData();e=b(d);a.setTooltipText(e)}}a.invalidTooltip=c},valueFromEvent:function(g){var a=this,e=a.innerEl,j=g.getX(),d=a.getRounding(),i=e.getX(),c=j-i,f=e.getWidth(),h=a.getLimit(),b;if(a.getInherited().rtl){c=f-c}b=c/f*h;b=Math.ceil(b/d)*d;return b},valueToPercent:function(a){a=a/this.getLimit()*100;return a+'%'}}},0,['rating'],['widget','rating'],{'widget':!0,'rating':!0},['widget.rating'],0,[Ext.ux.rating,'Picker'],0);Ext.cmd.derive('common.BandFilter',Ext.container.ButtonGroup,{alternateClassName:['Portal.BandFilter'],filters:['g','r','i','z','Y','RGB'],defaultFilter:'rgb',buttonWidth:30,vertical:!1,config:{availableFilters:[]},initComponent:function(){var a=this;if(!a.filters){Ext.Error.raise('You must specify a filters config.')}a.items=this.createFilters();var b='bands';if(a.itemId){b='bands_'+a.itemId}if(a.vertical){a.layout={type:'vbox',align:'stretch'}}else {a.layout={type:'hbox',align:'stretch'}}a.defaults={allowDepress:!1,enableToggle:!0,toggleGroup:b,toggleHandler:function(b){if(b.pressed){var c=b.value;a.fireEvent('onfilter',c,b,a)}}};Ext.container.ButtonGroup.prototype.initComponent.apply(this,arguments)},createFilters:function(){var c=this,f=[],d,a,b;for(var e=0;e1){b.width=50}if(c.defaultFilter==a){b.pressed=!0}f.push(b)}return f},getFilter:function(){var g=this,a=null,b,e,c;b=this.filters;e=Array();c=this.items;for(var d=0;d0){a.getTrigger('clear').show();a.getTrigger('search').hide();if(this.getMinSearch()>0&&a.getValue().length>=this.getMinSearch()){if(a.isValid()&&a.getValue()!==''){this.fireEvent('search',a.getValue(),this)}}}else {a.getTrigger('clear').hide();a.getTrigger('search').show();this.fireEvent('cancel')}},buffer:500},triggers:{clear:{cls:'x-form-clear-trigger',handler:function(a){a.reset();this.getTrigger('clear').hide();this.getTrigger('search').show();this.fireEvent('cancel')},hidden:!0},search:{cls:'x-form-search-trigger',handler:function(){}}},config:{minSearch:null}},0,['common-searchfield'],['component','box','field','textfield','common-searchfield'],{'component':!0,'box':!0,'field':!0,'textfield':!0,'common-searchfield':!0},['widget.common-searchfield'],0,[common,'SearchField'],0);Ext.cmd.derive('common.data.proxy.CrsfToken',Ext.Base,{singleton:!0,constructor:function(){Ext.Ajax.on('beforerequest',function(b,a){if(!(/^http:.*/.test(a.url)||/^https:.*/.test(a.url))){if(typeof a.headers=='undefined'){a.headers={'Accept':'application/json','X-CSRFToken':Ext.util.Cookies.get('csrftoken')}}else {a.headers['Application']='application/json';a.headers['X-CSRFToken']=Ext.util.Cookies.get('csrftoken')}}},this)}},1,0,0,0,0,0,[common.data.proxy,'CrsfToken'],0);Ext.cmd.derive('common.data.proxy.Django',Ext.data.proxy.Rest,{headers:{'Accept':'application/json;'},startParam:'offset',sortParam:'ordering',reader:{type:'json',rootProperty:'results',totalProperty:'count'},writer:{},actionMethods:{create:'POST',read:'GET',update:'PATCH',destroy:'DELETE'},encodeSorters:function(b){var c=[],a,d;for(var e in b){a=b[e];d=(a.getDirection()=='DESC'?'-':'')+a.getProperty();c.push(d)}return c.join()},getParams:function(b){var a=Ext.data.proxy.Rest.prototype.getParams.apply(this,arguments);if(!b.isReadOperation){return a}var c=b.getFilters();delete a[this.getFilterParam()];Ext.each(c,function(f){var e=f.getProperty(),d=f.getValue(),c,g;switch(f.getOperator()){case '<':c=Ext.String.format('{0}__lt',e);a[c]=d;break;case '<=':c=Ext.String.format('{0}__lte',e);a[c]=d;break;case '>=':c=Ext.String.format('{0}__gte',e);a[c]=d;break;case '>':c=Ext.String.format('{0}__gt',e);a[c]=d;break;case '!=':c=Ext.String.format('{0}__ne',e);a[c]=d;break;case 'in':c=Ext.String.format('{0}__in',e);a[c]=d.join();break;case 'like':c=Ext.String.format('{0}__icontains',e);a[c]=d;break;case 'range':c=Ext.String.format('{0}__range',e);g=Ext.String.format('{0},{1}',d[0],d[1]);a[c]=g;break;default:a[e]=d;}});return a},buildUrl:function(c){var b=this,e=c.getOperation(),h=e.getRecords(),g=h?h[0]:null,i=b.getFormat(),a=b.getUrl(c),d,f;if(g&&!g.phantom){d=g.getId()}else {d=e.getId()}if(b.getAppendId()&&b.isValidId(d)||e.action==='update'){if(!a.match(b.slashRe)){a+='/'}a+=encodeURIComponent(d);f=c.getParams();if(f){delete f[b.getIdParam()]}a+='/'}if(i){if(!a.match(b.periodRe)){a+='.'}a+=i}c.setUrl(a);return Ext.data.RestProxy.superclass.buildUrl.apply(this,arguments)}},0,0,0,0,['proxy.django'],0,[common.data.proxy,'Django'],0);Ext.cmd.derive('common.store.MyStore',Ext.data.Store,{proxy:{type:'django'},listeners:{load:function(h,i,e,f){if(e===!1){var g=h.proxy;var d=g.reader;if(d.jsonData){var b=d.jsonData;if(b!='undefined'){console.log('Load Failure: %o',b);Ext.Msg.alert('Status',b.msg)}}else {var a=f.getError(),c;switch(a.status){case 403:c=JSON.parse(a.response.responseText);Ext.MessageBox.show({title:a.status+' - '+a.statusText,msg:c.detail,buttons:Ext.MessageBox.OK,icon:Ext.MessageBox.WARNING,closable:!1,scope:this,fn:function(){var c=window.location.pathname,b=window.location.hostname,a;a=Ext.String.format('http://{0}/dri/api/api-auth/login/?next={1}',b,c);window.location.assign(a)}});break;case 408:c=JSON.parse(a.response.responseText);Ext.MessageBox.show({title:a.status+' - '+a.statusText,msg:'Maximum execution time exceeded.',buttons:Ext.MessageBox.OK,icon:Ext.MessageBox.WARNING});break;}}}}}},0,0,0,0,0,0,[common.store,'MyStore'],0);Ext.cmd.derive('common.contact.ContactController',Ext.app.ViewController,{onFormCancel:function(){this.getView().lookupReference('windowForm').getForm().reset();this.getView().close()},onFormSubmit:function(){var c=this.getView(),d=c.lookupReference('windowForm'),b=d.getForm(),a=b.getValues();a.current_url=window.location.href;a.current_user=window.sessionStorage.dri_username;if(b.isValid()){Ext.Ajax.request({url:'/dri/api/contact/',method:'POST',params:a,success:function(){c.close();Ext.MessageBox.alert('Thank you!','Your inquiry has been sent. We will respond as soon as possible.')},failure:function(a,b){Ext.MessageBox.show({title:a.status+' - '+a.statusText,msg:'Sorry, message was not sent.',buttons:Ext.MessageBox.OK,icon:Ext.MessageBox.WARNING,scope:this})}})}}},0,0,0,0,['controller.contact'],0,[common.contact,'ContactController'],0);Ext.cmd.derive('common.contact.Contact',Ext.window.Window,{reference:'contactWindow',title:'Contact Us',controller:'contact',width:400,height:500,minWidth:300,minHeight:380,layout:'fit',resizable:!0,modal:!0,defaultFocus:'firstName',closeAction:'destroy',items:[{xtype:'form',reference:'windowForm',layout:{type:'vbox',align:'stretch'},border:!1,bodyPadding:10,fieldDefaults:{msgTarget:'side',labelAlign:'top',labelWidth:100,labelStyle:'font-weight:bold'},items:[{margin:'0 0 20 0',xtype:'component',html:['Thank you for visiting our site! We welcome your feedback; ','please click the button below to send us a message. We will ','respond to your inquiry as quickly as possible.']},{xtype:'textfield',fieldLabel:'Name',name:'name',allowBlank:!1},{xtype:'textfield',fieldLabel:'Your Email Address',vtype:'email',name:'from',allowBlank:!1},{xtype:'textfield',fieldLabel:'Subject',name:'subject',allowBlank:!1},{xtype:'textareafield',fieldLabel:'How can we help?',labelAlign:'top',flex:1,margin:'0',name:'message',allowBlank:!1,emptyText:'Describe the problem or share your ideas.'}],buttons:[{text:'Cancel',handler:'onFormCancel'},{text:'Send',handler:'onFormSubmit'}]}]},0,['form-contact-window'],['component','box','container','panel','window','form-contact-window'],{'component':!0,'box':!0,'container':!0,'panel':!0,'window':!0,'form-contact-window':!0},['widget.form-contact-window'],0,[common.contact,'Contact'],0);Ext.cmd.derive('common.footer.FooterController',Ext.app.ViewController,{onClickContact:function(){if(this.wincontact){this.wincontact=null}this.wincontact=Ext.create('common.contact.Contact',{});this.wincontact.show()}},0,0,0,0,['controller.footer'],0,[common.footer,'FooterController'],0);Ext.cmd.derive('common.footer.Footer',Ext.toolbar.Toolbar,{controller:'footer',cls:'des-portal-footer',height:28,layout:{pack:'center',align:'middle'},viewModel:{data:{}},items:[{xtype:'tbtext',html:'Powered by LIneA | Dark Energy Survey | NCSA',cls:'des-portal-footer-text'}]},0,['dri-footer'],['component','box','container','toolbar','dri-footer'],{'component':!0,'box':!0,'container':!0,'toolbar':!0,'dri-footer':!0},['widget.dri-footer'],0,[common.footer,'Footer'],0);Ext.cmd.derive('common.ToolbarController',Ext.app.ViewController,{listen:{component:{'dri-header':{afterrender:'onAfterRender'}}},logout:function(){var b=window.location.protocol,c=window.location.host,a=Ext.String.format('{0}//{1}/dri/api/api-auth/logout/?next=/dri/apps/',b,c);window.location.assign(a)},projectHome:function(){var b=window.location.protocol,c=window.location.host,a=Ext.String.format('{0}//{1}/',b,c);window.location.assign(a)},contact:function(){if(this.wincontact){this.wincontact=null}this.wincontact=Ext.create('common.contact.Contact',{});this.wincontact.show()},about:function(){window.open('http://www.linea.gov.br')},onAfterRender:function(){var a=this;a.loadUsername();a.loaddTutorials()},loaddTutorials:function(){var b=this,c=b.getViewModel(),a=c.getStore('tutorials');a.addFilter([{property:'app_name',value:c.get('internal_name')}]);a.load({scope:this,callback:b.onLoadTutorials})},onLoadTutorials:function(){var b=this,d=b.getViewModel(),c=d.getStore('tutorials'),a=b.lookupReference('headermenututorials');if(c.count()>0){a.enable()}else {a.disable()}},tutorials:function(){var b=this,c=b.getViewModel(),a=c.getStore('tutorials');if(this.wincontact){this.wincontact=null}this.wintutorials=Ext.create('common.help.Tutorials',{store:a});this.wintutorials.show()},loadUsername:function(){var a=this,b=a.getViewModel();Ext.Ajax.request({url:'/dri/api/logged/get_logged/?format=json',success:function(c){var a=JSON.parse(c.responseText);b.set('username',a.username);window.dri_username=a.username}})}},0,0,0,0,['controller.toolbar'],0,[common,'ToolbarController'],0);Ext.cmd.derive('common.help.TutorialsController',Ext.app.ViewController,{onSelect:function(e,c){var d=this,b=d.lookupReference('video'),a;a=Ext.create('Ext.ux.IFrame',{flex:1,src:c.get('ttr_src')});b.removeAll();b.add(a)}},0,0,0,0,['controller.tutorials'],0,[common.help,'TutorialsController'],0);Ext.cmd.derive('common.help.Tutorials',Ext.window.Window,{title:'Tutorials',controller:'tutorials',config:{store:null},initComponent:function(){var a=this;Ext.apply(this,{layout:'border',width:700,height:400,minWidth:300,minHeight:280,resizable:!0,modal:!0,closeAction:'destroy',items:[{xtype:'grid',reference:'tutorials_grid',region:'west',split:!0,hideHeaders:!0,width:200,store:a.getStore(),columns:[{dataIndex:'ttr_title',flex:1}],listeners:{select:'onSelect'}},{xtype:'panel',region:'center',reference:'video',split:!0,layout:{type:'vbox',pack:'start',align:'stretch'}}]});Ext.window.Window.prototype.initComponent.apply(this,arguments)}},0,['tutorials-window'],['component','box','container','panel','window','tutorials-window'],{'component':!0,'box':!0,'container':!0,'panel':!0,'window':!0,'tutorials-window':!0},['widget.tutorials-window'],0,[common.help,'Tutorials'],0);Ext.cmd.derive('common.header.Toolbar',Ext.toolbar.Toolbar,{controller:'toolbar',cls:'des-portal-headerbar toolbar-btn-shadow',layout:{type:'hbox',align:'middle'},viewModel:{data:{home:'',desPortalLogo:'resources/des-portal-logo.png',tooltip:'Home',username:''},stores:{tutorials:{fields:['id','application','application_display_name','ttr_title','ttr_src','ttr_description'],remoteSort:!0,remoteFilter:!0,autoLoad:!1,pageSize:0,proxy:{type:'django',url:'/dri/api/tutorial/'}}}},viewItems:function(){return [{xtype:'component',cls:'des-portal-logo',bind:{html:'Home'}},{xtype:'component',cls:'des-portal-appname',bind:{html:'{name}'},flex:1},'->',{xtype:'button',cls:'delete-focus-bg',ui:'white-toolbar',scale:'medium',itemId:'btnusername',bind:{text:'{username}'}},{xtype:'button',iconCls:'x-fa fa-home',ui:'white-toolbar',cls:'delete-focus-bg',scale:'medium',handler:'projectHome',tooltip:'Home of the Science Server'},{xtype:'button',reference:'headermenu',iconCls:'x-fa fa-bars',cls:'delete-focus-bg',ui:'white-toolbar',scale:'medium',arrowVisible:!1,menu:[{text:'About LIneA',handler:'about'},{text:'Contact Us',handler:'contact'},{text:'Help',iconCls:'x-fa fa-question-circle',reference:'headermenututorials',disabled:!0,handler:'tutorials'},'-',{text:'Log out',iconCls:'x-fa fa-sign-out',handler:'logout'}]}]},initComponent:function(){this.items=this.viewItems();Ext.toolbar.Toolbar.prototype.initComponent.call(this)},afterRender:function(){var c=this,b=window.location.href,a;a=b.split('#')[0];c.getViewModel().set('home',a);Ext.toolbar.Toolbar.prototype.afterRender.apply(this,arguments)}},0,['dri-header'],['component','box','container','toolbar','dri-header'],{'component':!0,'box':!0,'container':!0,'toolbar':!0,'dri-header':!0},['widget.dri-header'],0,[common.header,'Toolbar'],0);Ext.cmd.derive('common.model.Dataset',Ext.data.Model,{fields:[{name:'id',type:'int'},{name:'tag',type:'int'},{name:'tag_display_name',type:'string'},{name:'release',type:'int'},{name:'release_display_name',type:'string'},{name:'tite',type:'int'},{name:'run',type:'string'},{name:'date',type:'string'},{name:'tli_tilename',type:'string'},{name:'tli_ra',type:'float'},{name:'tli_ra',type:'float'},{name:'tli_dec',type:'float'},{name:'tli_urall',type:'float'},{name:'tli_udecll',type:'float'},{name:'tli_uraur',type:'float'},{name:'tli_udecur',type:'float'},{name:'release_tag',type:'string',convert:function(b,a){return Ext.String.format('{0} - {1}',a.get('release_display_name'),a.get('tag_display_name'))}},{name:'image_src_ptif',type:'string'},{name:'image_src_thumbnails',type:'string'},{name:'g',type:'string',convert:function(b,a){return Ext.String.format('{0}/{1}/{2}.png',a.get('image_src_thumbnails'),'g',a.get('tli_tilename'))}},{name:'r',type:'string',convert:function(b,a){return Ext.String.format('{0}/{1}/{2}.png',a.get('image_src_thumbnails'),'r',a.get('tli_tilename'))}},{name:'i',type:'string',convert:function(b,a){return Ext.String.format('{0}/{1}/{2}.png',a.get('image_src_thumbnails'),'i',a.get('tli_tilename'))}},{name:'z',type:'string',convert:function(b,a){return Ext.String.format('{0}/{1}/{2}.png',a.get('image_src_thumbnails'),'z',a.get('tli_tilename'))}},{name:'y',type:'string',convert:function(b,a){return Ext.String.format('{0}/{1}/{2}.png',a.get('image_src_thumbnails'),'y',a.get('tli_tilename'))}},{name:'irg',type:'string',convert:function(b,a){return Ext.String.format('{0}/{1}/{2}.png',a.get('image_src_thumbnails'),'irg',a.get('tli_tilename'))}}],isInsideTile:function(a,e){var d=this,a=parseFloat(a),e=parseFloat(e),b,c,f,g;if(a>180){a=a-360}b=d.get('tli_urall');c=d.get('tli_uraur');f=d.get('tli_udecll');g=d.get('tli_udecur');if(b>180){b=b-360}if(c>180){c=c-360}if(a>b&&af&&e180){value=value-360}value=Ext.util.Format.number(value,'0.0000');return parseFloat(value)}},{name:'decul',type:'float',convert:function(b,a){value=a.get('tli_decul');value=Ext.util.Format.number(value,'0.0000');return parseFloat(value)}},{name:'rall',type:'float',convert:function(b,a){value=a.get('tli_rall');if(value>180){value=value-360}value=Ext.util.Format.number(value,'0.0000');return parseFloat(value)}},{name:'decll',type:'float',convert:function(b,a){value=a.get('tli_decll');value=Ext.util.Format.number(value,'0.0000');return parseFloat(value)}},{name:'ralr',type:'float',convert:function(b,a){value=a.get('tli_ralr');if(value>180){value=value-360}value=Ext.util.Format.number(value,'0.0000');return parseFloat(value)}},{name:'declr',type:'float',convert:function(b,a){value=a.get('tli_declr');value=Ext.util.Format.number(value,'0.0000');return parseFloat(value)}},{name:'raur',type:'float',convert:function(b,a){value=a.get('tli_raur');if(value>180){value=value-360}value=Ext.util.Format.number(value,'0.0000');return parseFloat(value)}},{name:'decur',type:'float',convert:function(b,a){value=a.get('tli_decur');value=Ext.util.Format.number(value,'0.0000');return parseFloat(value)}}]},0,0,0,0,0,0,[common.model,'Footprint'],0);Ext.cmd.derive('common.model.Map',Ext.data.Model,{fields:[{name:'id',type:'int'},{name:'prd_name',type:'string'},{name:'prd_display_name',type:'string'},{name:'prd_user_display_name',type:'string'},{name:'prd_class',type:'int'},{name:'prd_is_public',type:'boolean'},{name:'pcl_display_name',type:'string'},{name:'pcl_is_system',type:'boolean'},{name:'pgr_group',type:'int'},{name:'pgr_display_name',type:'string'},{name:'epr_original_id',type:'string'},{name:'prd_filter',type:'string'},{name:'prl_related',type:'string'},{name:'prl_cross_identification',type:'string'},{name:'prl_cross_property',type:'string'},{name:'tablename',type:'string'},{name:'mpa_nside',type:'int'},{name:'mpa_ordering',type:'string'}]},0,0,0,0,0,0,[common.model,'Map'],0);Ext.cmd.derive('common.model.Survey',Ext.data.Model,{fields:[{name:'id',type:'int'},{name:'srv_release',type:'int'},{name:'srv_filter',type:'int'},{name:'filter',type:'string'},{name:'srv_project',type:'string'},{name:'srv_display_name',type:'string'},{name:'srv_url',type:'string'},{name:'srv_target',type:'string'},{name:'srv_fov',type:'string'}]},0,0,0,0,0,0,[common.model,'Survey'],0);Ext.cmd.derive('common.model.Tag',Ext.data.Model,{fields:[{name:'id',type:'int'},{name:'tag_release',type:'int'},{name:'tag_name',type:'string'},{name:'tag_display_name',type:'string'},{name:'tag_status',type:'boolean'},{name:'tag_install_date',type:'date'},{name:'is_new',type:'boolean',convert:function(e,b){if(b.get('tag_install_date')){var a=b.get('tag_install_date'),c=-2,d=Ext.Date.add(new Date(),Ext.Date.DAY,c);return Ext.Date.between(a,d,a)}}}]},0,0,0,0,0,0,[common.model,'Tag'],0);Ext.cmd.derive('common.store.Tiles',common.store.MyStore,{pageSize:100,remoteFilter:!0,remoteSort:!0,proxy:{type:'django',url:'/dri/api/tiles/'},filterByRaDec:function(a,d){var a=parseFloat(a),d=parseFloat(d),b,c,e;this.each(function(f){if(a>180){a=a-360}b=f.get('tli_urall');c=f.get('tli_uraur');if(b>180){b=b-360}if(c>180){c=c-360}if(ba&&f.get('tli_udecur')>d){e=f;return !1}},this);return e}},0,0,0,0,['store.tiles'],0,[common.store,'Tiles'],0);Ext.cmd.derive('common.store.Datasets',common.store.Tiles,{model:'common.model.Dataset',remoteFilter:!0,remoteSort:!0,pageSize:100,proxy:{type:'django',url:'/dri/api/dataset/'}},0,0,0,0,['store.datasets'],0,[common.store,'Datasets'],0);Ext.cmd.derive('common.store.Footprints',common.store.Tiles,{model:'common.model.Footprint',remoteFilter:!0,remoteSort:!0,pageSize:0,proxy:{type:'django',url:'/dri/api/footprints/',reader:{type:'array'}}},0,0,0,0,['store.footprints'],0,[common.store,'Footprints'],0);Ext.cmd.derive('common.store.Maps',common.store.MyStore,{model:'common.model.Map',autoLoad:!1,pageSize:0,remoteFilter:!0,proxy:{type:'django',url:'/dri/api/map/'}},0,0,0,0,['store.maps'],0,[common.store,'Maps'],0);Ext.cmd.derive('common.store.MyTreeStore',Ext.data.TreeStore,{proxy:{type:'django',appendId:!1,reader:{type:'json',rootProperty:'children'}},listeners:{load:function(h,i,e,f){if(e===!1){var g=h.proxy;var d=g.reader;if(d.jsonData){var b=d.jsonData;if(b!='undefined'){console.log('Load Failure: %o',b);Ext.Msg.alert('Status',b.msg)}}else {var a=f.getError(),c=JSON.parse(a.response.responseText);switch(a.status){case 403:Ext.MessageBox.show({title:a.status+' - '+a.statusText,msg:c.detail,buttons:Ext.MessageBox.OK,icon:Ext.MessageBox.WARNING,closable:!1,scope:this,fn:function(){var c=window.location.pathname,b=window.location.hostname,a;a=Ext.String.format('http://{0}/dri/api/api-auth/login/?next={1}',b,c);window.location.assign(a)}});break;default:Ext.MessageBox.show({title:a.status+' - '+a.statusText,msg:c.detail,buttons:Ext.MessageBox.OK,icon:Ext.MessageBox.WARNING,scope:this});}}}}}},0,0,0,0,0,0,[common.store,'MyTreeStore'],0);Ext.cmd.derive('common.store.Surveys',common.store.MyStore,{model:'common.model.Survey',autoLoad:!1,remoteFilter:!0,remoteSort:!0,pageSize:0,proxy:{type:'django',url:'/dri/api/surveys/'}},0,0,0,0,['store.surveys'],0,[common.store,'Surveys'],0);Ext.cmd.derive('common.store.Tags',common.store.MyStore,{model:'common.model.Tag',remoteFilter:!0,remoteSort:!0,proxy:{type:'django',url:'/dri/api/tags/'},sorters:[{property:'tag_display_name',direction:'ASC'}]},0,0,0,0,['store.tags'],0,[common.store,'Tags'],0);Ext.cmd.derive('visiomatic.Interface',Ext.Base,{makeToolbar:function(){return Ext.create('Ext.toolbar.Toolbar',{items:[]})},makeToolbarButtons:function(){var a=this,c=a.getAuxTools(),b=[];if(a.getEnableShift()){b.push({xtype:'button',tooltip:'Switch between Visiomatic / Aladdin.',iconCls:'x-fa fa-exchange',scope:a,handler:a.onShift})}if(a.getEnableLink()){b.push({xtype:'button',tooltip:'Get link',iconCls:'x-fa fa-link',scope:a,handler:a.getLinkToPosition})}if(c.length>0){Ext.each(c,function(a){b.push(a)})}return b},makeMousePosition:function(){var a=this.getMap();return Ext.DomHelper.append(a._controlCorners['topright'],{tag:'div',cls:'leaflet-right leaflet-control leaflet-control-wcs-dialog visiomatic-mouse-position',html:'
    Mouse RA, Dec (0,0)
    '})}},0,0,0,0,0,0,[visiomatic,'Interface'],0);Ext.cmd.derive('visiomatic.VisiomaticModel',Ext.app.ViewModel,{data:{release:null,tag:null,dataset:null}},0,0,0,0,['viewmodel.visiomatic'],0,[visiomatic,'VisiomaticModel'],0);Ext.cmd.derive('visiomatic.VisiomaticController',Ext.app.ViewController,{},0,0,0,0,['controller.visiomatic'],0,[visiomatic,'VisiomaticController'],0);Ext.cmd.derive('visiomatic.catalog.Catalogs',Ext.tree.Panel,{initComponent:function(){var a=this;Ext.apply(this,{emptyText:'No data to display.',hideHeaders:!0,rootVisible:!1,useArrows:!0,selModel:{mode:'SINGLE'},columns:[{xtype:'treecolumn',text:'Name',flex:2,sortable:!0,dataIndex:'text',renderer:a.getTooltipName}],tbar:[{xtype:'textfield',emptyText:'Search by name',reference:'SearchField',flex:1,triggers:{clear:{cls:'x-form-clear-trigger',handler:'cancelFilter',hidden:!0},search:{cls:' x-form-search-trigger'}},listeners:{change:'filterCatalogByname',buffer:500}}]});Ext.tree.Panel.prototype.initComponent.apply(this,arguments)},getTooltipName:function(d,e,b){var f=this,c,a;if(b.get('leaf')){c=new Ext.XTemplate('
    ','{prd_display_name}','','


    {description}

    ','
    ','
    ');a=c.apply(b.data);e.tdAttr='data-qtip="'+a+'"'}return d}},0,['visiomatic-catalogs-tree'],['component','box','container','panel','tablepanel','treepanel','visiomatic-catalogs-tree'],{'component':!0,'box':!0,'container':!0,'panel':!0,'tablepanel':!0,'treepanel':!0,'visiomatic-catalogs-tree':!0},['widget.visiomatic-catalogs-tree'],0,[visiomatic.catalog,'Catalogs'],0);Ext.cmd.derive('visiomatic.model.CatalogTree',Ext.data.Model,{fields:[{name:'id'},{name:'prd_name',type:'string'},{name:'prd_display_name',type:'string'},{name:'prd_class',type:'int'},{name:'pcl_display_name',type:'string'},{name:'pcl_is_system',type:'boolean'},{name:'pgr_group',type:'int'},{name:'pgr_display_name',type:'string'},{name:'epr_original_id',type:'string'},{name:'epr_name',type:'string'},{name:'epr_username',type:'string'},{name:'epr_start_date',type:'date'},{name:'epr_end_date',type:'date'},{name:'epr_readme',type:'string'},{name:'epr_comment',type:'string'},{name:'ctl_num_columns',type:'int'},{name:'ctl_num_tiles',type:'int'},{name:'ctl_num_objects',type:'int'},{name:'cds_source',type:'string'},{name:'cds_fieldnames',type:'string'},{name:'editable',type:'boolean',defaultValue:!1},{name:'markable',type:'boolean',defaultValue:!1},{name:'release_display_name',type:'string'},{name:'external_catalog',type:'boolean',defaultValue:!1}]},0,0,0,0,0,0,[visiomatic.model,'CatalogTree'],0);Ext.cmd.derive('visiomatic.store.CatalogsTree',common.store.MyTreeStore,{model:'visiomatic.model.CatalogTree',autoLoad:!1,remoteFilter:!0,proxy:{api:{read:'/dri/api/catalog/get_class_tree_by_group/'}}},0,0,0,0,['store.catalogs-overlay-tree'],0,[visiomatic.store,'CatalogsTree'],0);Ext.cmd.derive('visiomatic.store.Overlays',Ext.data.ArrayStore,{remoteFilter:!1,remoteSort:!1,autoLoad:!1,pageSize:0},0,0,0,0,['store.overlays'],0,[visiomatic.store,'Overlays'],0);Ext.cmd.derive('visiomatic.model.FilterCondition',Ext.data.Model,{fields:[{name:'id',type:'int','default':null,persist:!1},{name:'filterset',type:'int'},{name:'fcd_property',type:'int'},{name:'fcd_property_name',type:'string'},{name:'fcd_operation',type:'string'},{name:'fcd_value',type:'string'},{name:'operator_display_name',type:'string',persist:!1},{name:'property_display_name',type:'string',persist:!1,convert:function(a,c){var b=c.get('fcd_property_name');switch(b){case '_meta_rating':a='Rating';break;case '_meta_reject':a='Reject';break;}return a}}]},0,0,0,0,0,0,[visiomatic.model,'FilterCondition'],0);Ext.cmd.derive('visiomatic.store.FilterConditions',Ext.data.Store,{model:'visiomatic.model.FilterCondition',remoteFilter:!1,pageSize:0,sorters:[{property:'id',direction:'ASC'}]},0,0,0,0,['store.overlay-filter-conditions'],0,[visiomatic.store,'FilterConditions'],0);Ext.cmd.derive('visiomatic.catalog.CatalogViewModel',Ext.app.ViewModel,{stores:{catalogs:{type:'catalogs-overlay-tree'},overlays:{type:'overlays'}},data:{visiomatic:null,currentColor:'1dff00',currentFilters:null,pointType:0,pointSize:1},links:{currentCatalog:{type:'visiomatic.model.CatalogTree',create:!0},dataset:{type:'common.model.Dataset',create:!0}}},0,0,0,0,['viewmodel.catalogoverlay'],0,[visiomatic.catalog,'CatalogViewModel'],0);Ext.cmd.derive('visiomatic.model.Object',Ext.data.Model,{idProperty:'_meta_id',fields:[{name:'_meta_id'},{name:'_meta_catalog_id',type:'int'},{name:'_meta_is_system',type:'boolean'},{name:'_meta_ra',type:'float'},{name:'_meta_dec',type:'float'},{name:'_meta_radius',type:'float'}]},0,0,0,0,0,0,[visiomatic.model,'Object'],0);Ext.cmd.derive('visiomatic.store.Objects',common.store.MyStore,{remoteFilter:!0,remoteSort:!0,autoLoad:!1,model:'visiomatic.model.Object',pageSize:5000,proxy:{type:'django',timeout:90000,api:{read:'/dri/api/catalogobjects/'}}},0,0,0,0,['store.overlay-objects'],0,[visiomatic.store,'Objects'],0);Ext.cmd.derive('visiomatic.store.ExternalObjects',common.store.MyStore,{remoteFilter:!0,remoteSort:!1,autoLoad:!1,model:'visiomatic.model.Object',pageSize:10000,proxy:{type:'django',timeout:60000,api:{read:'/dri/api/vizier/'}}},0,0,0,0,['store.overlay-external-objects'],0,[visiomatic.store,'ExternalObjects'],0);Ext.cmd.derive('visiomatic.model.Overlay',Ext.data.Model,{idProperty:'id',fields:[{name:'id',type:'int'},{name:'name',type:'string'},{name:'color',type:'string'},{name:'visible',type:'boolean'},{name:'status',type:'string'},{name:'status_message',type:'string'},{name:'count',type:'int'},{name:'total_count',type:'int'},{name:'excess',type:'int'},{name:'catalog'},{name:'layers'},{name:'objects'},{name:'filters'},{name:'objectUrl'},{name:'pointSize',type:'float'}]},0,0,0,0,0,0,[visiomatic.model,'Overlay'],0);Ext.cmd.derive('visiomatic.filter.FiltersController',Ext.app.ViewController,{listen:{component:{'overlay-filters-window':{changecatalog:'onChangeCatalog'}}},onChangeCatalog:function(b){var a=this,d=a.getViewModel(),c=d.getStore('contents');a.clearImputs();c.addFilter({property:'pcn_product_id',value:b.get('id')})},onLoadContents:function(a){},onAddFilter:function(){var d=this,a=d.getViewModel(),b=a.get('content'),f=a.get('operator'),h=a.get('value'),g=a.getStore('filters'),e=a.get('afilters'),c;c=Ext.create('visiomatic.model.FilterCondition',{fcd_property:b.get('id'),fcd_property_name:b.get('column_name'),fcd_operation:f.get('name'),fcd_value:h,property_display_name:b.get('display_name'),operator_display_name:f.get('display_name')});e.push(c);g.add(c);a.set('afilters',e);d.clearImputs();d.checkHaveFilters()},onRemoveFilterClick:function(f,d,c,e,g,b){var a=this;Ext.MessageBox.confirm('','The Filter will be removed. Do you want continue?',function(h){if(h==='yes'){b.drop();a.createAFilters();a.checkHaveFilters()}},this)},createAFilters:function(){var c=this,e=c.getViewModel(),d=c.lookup('gridFilters'),b=d.getStore(),a=[];console.log(b);b.each(function(b){console.log(b);a.push(b)},this);e.set('afilters',a)},checkHaveFilters:function(){var b=this,a=b.getViewModel(),c=a.get('afilters'),d=b.lookup('BtnApply');if(c.length>0){a.set('haveFilters',!0)}else {a.set('haveFilters',!1)}},onSelectProperty:function(f,c){var a=this,b=a.getViewModel(),d=b.get('afilters'),e},onSelectOperator:function(b,a){},onCancelFilter:function(){this.getView().close()},onApplyFilter:function(){var a=this,e=a.getView(),c=a.getViewModel(),d=c.get('currentCatalog'),b=c.get('afilters');if(b.length>0){a.applyFilters(d,b)}},applyFilters:function(c,d){var b=this,a=b.getView();a.fireEvent('applyfilters',d,c,b);a.close()},clearImputs:function(){var e=this,a=e.getReferences(),c=a.cmbProperty,b=a.cmbOperator,d=a.txtValue;c.reset();b.reset();d.reset()}},0,0,0,0,['controller.overlay_filters'],0,[visiomatic.filter,'FiltersController'],0);Ext.cmd.derive('visiomatic.model.CatalogContent',Ext.data.Model,{fields:[{name:'id',type:'int'},{name:'product_id',type:'int'},{name:'setting_id',type:'int'},{name:'column_name',type:'string'},{name:'class_id',type:'int'},{name:'category',type:'string'},{name:'display_name',type:'string'},{name:'ucd',type:'string'},{name:'unit',type:'string'},{name:'reference',type:'string'},{name:'mandatory',type:'boolean'},{name:'content_setting',type:'int'},{name:'is_visible',type:'boolean'},{name:'order',type:'int'}]},0,0,0,0,0,0,[visiomatic.model,'CatalogContent'],0);Ext.cmd.derive('visiomatic.store.ProductDisplayContents',common.store.MyStore,{model:'visiomatic.model.CatalogContent',remoteFilter:!0,remoteSort:!1,pageSize:0,proxy:{url:'/dri/api/productcontent/get_display_content/'},sorters:[{property:'order',direction:'ASC'},{property:'display_name',direction:'ASC'}],ucds:['meta.id;meta.main','pos.eq.ra;meta.main','pos.eq.dec;meta.main'],check_ucds:function(){var a=this,b=[];a.each(function(c){if(a.ucds.indexOf(c.get('ucd'))!==-1){b.push(!0)}},a);if(b.length===a.ucds.length){return !0}else {return !1}}},0,0,0,0,['store.overlay-product-display-contents'],0,[visiomatic.store,'ProductDisplayContents'],0);Ext.cmd.derive('visiomatic.filter.FiltersModel',Ext.app.ViewModel,{stores:{contents:{type:'overlay-product-display-contents',storeId:'productContents',autoLoad:!1},filters:{type:'overlay-filter-conditions',storeId:'filterConditions',autoLoad:!1},operators:{fields:['name','display_name','type'],data:[{name:'=',display_name:'is equal to',type:'text'},{name:'!=',display_name:'is not equal to',type:'text'},{name:'>',display_name:'is greater than',type:'text'},{name:'>=',display_name:'is greater than or equal to',type:'text'},{name:'<',display_name:'is less than',type:'text'},{name:'<=',display_name:'is less than or equal to',type:'text'}]}},data:{operator:null,value:null,haveFilters:!1,afilters:[]},links:{currentCatalog:{type:'visiomatic.model.CatalogTree',create:!0}}},0,0,0,0,['viewmodel.overlay_filters'],0,[visiomatic.filter,'FiltersModel'],0);Ext.cmd.derive('visiomatic.filter.FiltersWindow',Ext.window.Window,{title:'Filters',width:500,height:300,modal:!0,autoShow:!0,controller:'overlay_filters',viewModel:'overlay_filters',closeAction:'destroy',bodyPadding:20,layout:{type:'vbox',align:'stretch'},config:{currentCatalog:null},items:[{xtype:'form',reference:'filterForm',layout:{type:'vbox',align:'stretch'},border:!1,fieldDefaults:{msgTarget:'side',labelAlign:'top',labelWidth:100,labelStyle:'font-weight:bold'},items:[{xtype:'fieldset',title:'Add condition',items:[{xtype:'fieldcontainer',layout:'hbox',defaults:{flex:1},items:[{xtype:'combobox',emptyText:'Property',itemId:'cmbProperty',reference:'cmbProperty',publishes:'id',displayField:'display_name',bind:{store:'{contents}',selection:'{content}'},listeners:{select:'onSelectProperty'},minChars:0,queryMode:'local',editable:!1,readOnly:!1,margin:'0 5 0 0'},{xtype:'combobox',itemId:'cmbOperator',reference:'cmbOperator',publishes:'name',displayField:'display_name',emptyText:'Operator',bind:{store:'{operators}',selection:'{operator}'},listeners:{select:'onSelectOperator'},minChars:0,queryMode:'local',editable:!1,readOnly:!1,forceSelection:!0,margin:'0 5 0 0'},{xtype:'textfield',reference:'txtValue',emptyText:'Value',bind:{value:'{value}'},margin:'0 5 0 0',allowBlank:!1},{xtype:'button',iconCls:'x-fa fa-plus',width:40,flex:!1,handler:'onAddFilter'}]}]}]},{xtype:'grid',reference:'gridFilters',layout:'fit',border:!0,framed:!0,hideHeaders:!0,flex:1,bind:{store:'{filters}'},viewConfig:{markDirty:!1},columns:[{text:'Property',dataIndex:'property_display_name',flex:1},{text:'Operator',dataIndex:'operator_display_name',flex:1},{text:'Value',dataIndex:'fcd_value',flex:1},{xtype:'actioncolumn',width:60,sortable:!1,menuDisabled:!0,align:'center',items:[{iconCls:'x-fa fa-minus-circle color-soft-red',tooltip:'Remove condition',handler:'onRemoveFilterClick'}]}]}],buttons:[{text:'Cancel',handler:'onCancelFilter'},{text:'Ok',reference:'BtnApply',handler:'onApplyFilter',bind:{disabled:'{!haveFilters}'}}],setCurrentCatalog:function(a){var b=this;if(a&&a.get('id')>0){b.currentCatalog=a;b.getViewModel().set('currentCatalog',a);b.fireEvent('changecatalog',a)}},setFilterSet:function(a){var d=this,c=d.getViewModel(),b=c.getStore('filters'),e=d.lookup('btnDeleteFilterSet'),f=d.lookup('txtFilter');if(a&&a.get('id')>0){c.set('filterSet',a);c.set('filterName',a.get('fst_name'));f.setReadOnly(!0);e.enable();b.addFilter({property:'filterset',value:a.get('id')});b.load()}else {c.set('filterName',null);f.setReadOnly(!1);e.disable();b.clearFilter();b.removeAll(!0)}}},0,['overlay-filters-window'],['component','box','container','panel','window','overlay-filters-window'],{'component':!0,'box':!0,'container':!0,'panel':!0,'window':!0,'overlay-filters-window':!0},['widget.overlay-filters-window'],0,[visiomatic.filter,'FiltersWindow'],0);Ext.cmd.derive('visiomatic.catalog.CatalogController',Ext.app.ViewController,{listen:{component:{'visiomatic-catalog-overlay':{changedataset:'onChangeDataset'}}},baseFilters:[],winFilter:null,onChangeDataset:function(d){var a=this,c=a.getViewModel(),b=c.getStore('overlays');b.removeAll();a.loadCatalogs()},loadCatalogs:function(){var c=this,d=c.getViewModel(),b=d.getStore('catalogs'),a;a=[{property:'group',operator:'in',value:['objects_catalog','targets','value_added_catalogs','external_catalogs']}];c.baseFilters=a;b.addFilter(a);b.load()},onSelectCatalog:function(){var a=this,d=a.getViewModel(),b=d.get('currentFilters'),c=a.lookup('CatalogsTree'),f=c.selection,e=a.lookup('btnFilter');b=[]},filterCatalogByname:function(){var a=this,h=a.lookup('CatalogsTree'),b=a.lookup('SearchField'),c=h.getStore(),d=b.getValue(),e=[],f;if(d.length>0){b.getTrigger('clear').show();if(c.isLoading()){console.log('Store is Loading: %o',c.isLoading());var g=c.getProxy();g.abort();console.log('Store proxy abort')}f={property:'search',value:d};e.push(f);a.filterCatalogs(e)}else {b.getTrigger('clear').hide();a.filterCatalogs()}},filterCatalogs:function(a){var d=this,g=d.getViewModel(),b=g.getStore('catalogs'),f=d.baseFilters,e,c=Ext.clone(f);b.clearFilter(!0);b.removeAll();if(a&&Array.isArray(a)){for(index in a){e=a[index];c.push(e)}}b.filter(c)},cancelFilter:function(){var b=this,a=b.lookup('SearchField');a.reset();b.filterCatalogs();a.getTrigger('clear').hide()},onClickOverlay:function(){var b=this,c=b.getViewModel(),k=b.lookup('CatalogsTree'),d=k.selection,j=c.get('currentColor'),i=c.get('currentFilters'),h=c.getStore('overlays'),e=b.lookup('cmbPointType'),g=e.getValue(),f=c.get('pointSize')/1000,a;c.set('currentCatalog',d);a=Ext.create('visiomatic.model.Overlay',{name:d.get('prd_display_name'),catalog:d,color:Ext.String.format('#{0}',j),visible:!0,count:null,layers:null,pointType:g,pointSize:f,status:'loading',filters:null});h.add(a);if(!d.get('external_catalog')){a.set('objects',Ext.create('visiomatic.store.Objects',{}));a.set('filters',i);b.loadObjects(a)}else {a.set('objects',Ext.create('visiomatic.store.ExternalObjects',{}));a.set('objectUrl',!0);b.loadExternalCatalogObjects(a)}},loadExternalCatalogObjects:function(b){var d=this,f=d.getViewModel(),e=f.get('visiomatic'),c=b.get('objects'),a;a=e.getBounds();c.addFilter([{property:'cds_source',value:b.get('catalog').get('cds_source')},{property:'cds_fieldnames',value:b.get('catalog').get('cds_fieldnames')},{property:'lat',value:a.lat},{property:'lng',value:a.lng},{property:'dlat',value:a.dlat},{property:'dlng',value:a.dlng}]);c.load({callback:function(e,c,a){d.onLoadObjects(b,c,a)}})},loadObjects:function(a){var f=this,h=f.getViewModel(),g=h.get('visiomatic'),b=a.get('objects'),d=a.get('filters'),c=[],e;e=g.getBox();b.addFilter([{property:'product',value:a.get('catalog').get('id')},{property:'coordinates',value:JSON.stringify(e)}]);if(d!==null){Ext.each(d,function(b){c.push({property:b.get('fcd_property_name'),operator:b.get('fcd_operation'),value:b.get('fcd_value')})});b.addFilter(c)}b.load({callback:function(d,c,b){f.onLoadObjects(a,c,b)}})},onLoadObjects:function(a,c,g){var i=this,j=i.getViewModel(),h=j.get('visiomatic'),b=a.get('objects'),d,e;a.set('count',b.count());if(!g){var f=c.error.statusText;if(c.error.status==0){f='Communication Failure or Time out'}d=Ext.String.format('Sorry, there was a server error, and this operation can not be performed.
    Error: {0} - {1}',c.error.status,f);a.set('status','error');a.set('status_message',d);console.log('Server Side ERROR: %o - %o',c.error.status,c.error.statusText)}else {if(b.count()>0){if(b.totalCount>b.pageSize){e=b.totalCount-b.pageSize;d=Ext.String.format('The query returned more objects than the limit.
    {0} objects are not being displayed.
    Limit: {1}
    Query returned: {2}
    ',e,b.pageSize,b.totalCount);a.set('total_count',b.totalCount);a.set('excess',e);a.set('status','alert');a.set('status_message',d)}else {a.set('status','ok')}}else {a.set('status','warning')}layers=h.overlayCatalog(a.get('name'),b,{color:a.get('color'),objectUrl:a.get('objectUrl'),pointType:a.get('pointType'),pointSize:a.get('pointSize')});a.set('layers',layers)}},onRemoveOverlay:function(i,f,h){var g=this,c=g.getViewModel(),e=c.getStore('overlays'),d=c.get('visiomatic'),b=e.getAt(f),a=b.get('layers');if(a!==null){d.showHideLayer(a,!1)}b.erase()},onChangeVisibility:function(i,e,g){var h=this,b=h.getViewModel(),d=b.getStore('overlays'),c=b.get('visiomatic'),f=d.getAt(e),a=f.get('layers');if(a!==null){c.showHideLayer(a,g)}},onClickBtnFilter:function(){var a=this,d=a.getViewModel(),c=a.lookup('CatalogsTree'),b=c.selection;if(b&&b.get('id')>0){a.winFilter=Ext.create('visiomatic.filter.FiltersWindow',{listeners:{scope:a,applyfilters:'onApplyFilters'}});a.winFilter.setCurrentCatalog(b);a.winFilter.show()}},onApplyFilters:function(a,d){var b=this,c=b.getViewModel();if(a.length>0){c.set('currentFilters',a)}}},0,0,0,0,['controller.catalogoverlay'],0,[visiomatic.catalog,'CatalogController'],0);Ext.cmd.derive('visiomatic.catalog.Submit',Ext.form.Panel,{initComponent:function(){var a=this;Ext.apply(this,{bodyPadding:5,layout:{type:'vbox',align:'stretch'},items:[{xtype:'fieldset',flex:1,border:!1,items:[{xtype:'fieldcontainer',layout:'hbox',items:[{xtype:'tbtext',html:'Color:',width:45},{xtype:'colorbutton',bind:'{currentColor}',width:55,margin:'0 20 0 5',tooltip:'Choose a color. Click on the color and then on ok.'}]},{xtype:'fieldcontainer',layout:'hbox',items:[{xtype:'combobox',labelWidth:45,flex:1,reference:'cmbPointType',fieldLabel:'Marker',displayField:'name',valueField:'name',queryMode:'local',store:{fields:['name'],data:[{'name':'circle'},{'name':'ellipse'},{'name':'square'},{'name':'triangle'}]},value:'circle'},{xtype:'numberfield',name:'pointsize',fieldLabel:'Size',labelWidth:40,width:100,bind:'{pointSize}',minValue:1,maxValue:10,margin:'0 0 0 5'}]},{xtype:'button',iconCls:'x-fa fa-filter',text:'Filters',tooltip:'Filters',handler:'onClickBtnFilter',reference:'btnFilter',width:100}]}],buttons:[{text:'Apply',handler:'onClickOverlay'}]});Ext.form.Panel.prototype.initComponent.apply(this,arguments)}},0,['visiomatic-catalogs-submit'],['component','box','container','panel','form','visiomatic-catalogs-submit'],{'component':!0,'box':!0,'container':!0,'panel':!0,'form':!0,'visiomatic-catalogs-submit':!0},['widget.visiomatic-catalogs-submit'],0,[visiomatic.catalog,'Submit'],0);Ext.cmd.derive('visiomatic.catalog.OverlayGrid',Ext.grid.Panel,{initComponent:function(){var a=this;Ext.apply(this,{hideHeaders:!0,viewConfig:{markDirty:!1,listeners:{scope:a,render:a.addTooltipToColumnName,destroy:function(a){delete a.tip}}},columns:[{text:'Visible',xtype:'checkcolumn',dataIndex:'visible',width:30,listeners:{checkchange:'onChangeVisibility'},align:'center'},{text:'Color',dataIndex:'color',width:30,align:'center',renderer:a.renderColumnColor},{text:'Name',dataIndex:'name',tdCls:'nameTdCls',flex:2,renderer:a.renderColumnName},{menuDisabled:!0,xtype:'actioncolumn',width:30,items:[{iconCls:'x-fa fa-trash-o color-overlay-grid-icon',tooltip:'Remove',handler:'onRemoveOverlay'}]}]});Ext.grid.Panel.prototype.initComponent.apply(this,arguments)},addTooltipToColumnName:function(a){var b=this;a.tip=Ext.create('Ext.tip.ToolTip',{target:a.getId(),delegate:a.itemSelector+' .nameTdCls',trackMouse:!0,listeners:{beforeshow:function updateTipBody(c){var d=c.target.component;var e=d.getRecord(c.triggerElement);c.update(b.getTooltipName(e))}}})},getTooltipName:function(a){var f=this,b=a.get('filters'),d,e,c;if(a.get('status')!=='error'){d=Ext.String.format('{0}
    Entries: {1}',a.get('name'),a.get('count'));if(b!==null&&b.length>0){c='
    Filters:
    ';Ext.each(b,function(b){e=Ext.String.format('{0} {1} {2}
    ',b.get('fcd_property_name'),b.get('operator_display_name'),b.get('fcd_value'));c+=e});d+=c}return d}else {return a.get('status_message')}},renderColumnName:function(a,d,b){var c=16;if(a.length>c){a=a.substr(0,c);a=a+'...'}if(b.get('status')!=='loading'&&b.get('status')!=='error'){return Ext.String.format('{0} ({1} entries)',a,b.get('count'))}else {return a}},renderColumnColor:function(a,c,b){switch(b.get('status')){case 'loading':a='';break;case 'ok':a=Ext.String.format('',a);break;case 'alert':msg=b.get('status_message');a='';c.tdAttr='data-qtip= "'+msg+'"';break;case 'warning':a='';break;case 'error':msg=b.get('status_message');a='';break;}return a}},0,['visiomatic-catalogs-overlays-grid'],['component','box','container','panel','tablepanel','gridpanel','grid','visiomatic-catalogs-overlays-grid'],{'component':!0,'box':!0,'container':!0,'panel':!0,'tablepanel':!0,'gridpanel':!0,'grid':!0,'visiomatic-catalogs-overlays-grid':!0},['widget.visiomatic-catalogs-overlays-grid'],0,[visiomatic.catalog,'OverlayGrid'],0);Ext.cmd.derive('visiomatic.catalog.CatalogOverlayWindow',Ext.window.Window,{controller:'catalogoverlay',viewModel:'catalogoverlay',config:{visiomatic:null,dataset:null},initComponent:function(){var a=this;Ext.apply(this,{title:'Catalog Overlay',width:600,height:450,closeAction:'hide',layout:{type:'hbox',align:'stretch'},items:[{xtype:'panel',split:!0,flex:1,framed:!0,layout:{type:'vbox',align:'stretch'},items:[{xtype:'visiomatic-catalogs-tree',reference:'CatalogsTree',flex:1,bind:{store:'{catalogs}'},listeners:{select:'onSelectCatalog'}},{xtype:'visiomatic-catalogs-submit',height:150,bind:{disabled:'{!CatalogsTree.selection.leaf}'}}]},{xtype:'visiomatic-catalogs-overlays-grid',split:!0,framed:!0,flex:1,bind:{store:'{overlays}'}}]});Ext.window.Window.prototype.initComponent.apply(this,arguments)},setVisiomatic:function(a){this.visiomatic=a;this.getViewModel().set('visiomatic',a)},setDataset:function(c){var a=this,d=a.getDataset(),b=!1;if(d!==null&&d.get('id')>0){if(d.get('id')===c.get('id')){b=!1}else {b=!0}}else {b=!0}if(b){a.dataset=c;a.getViewModel().set('dataset',c);a.fireEvent('changedataset',c,a)}}},0,['visiomatic-catalog-overlay'],['component','box','container','panel','window','visiomatic-catalog-overlay'],{'component':!0,'box':!0,'container':!0,'panel':!0,'window':!0,'visiomatic-catalog-overlay':!0},['widget.visiomatic-catalog-overlay'],0,[visiomatic.catalog,'CatalogOverlayWindow'],0);Ext.cmd.derive('visiomatic.download.FitsController',Ext.app.ViewController,{listen:{component:{'target-download-descut':{changeLoadFits:'onChangeLoadFits'}}},listen:{component:{'target-download-descut':{changeLoadFits:'onChangeLoadFits'}}},onChangeLoadFits:function(b,c){var f=this,e=f.getView(),a=e.getViewModel(),d=a.getStore('fitsFiles');a.set('catalog',c);a.set('tilename',b);d.filter([{property:'tilename',value:b},{property:'catalog',value:c}])}},0,0,0,0,['controller.fits-files'],0,[visiomatic.download,'FitsController'],0);Ext.cmd.derive('visiomatic.model.FitsFiles',Ext.data.Model,{proxy:{type:'django',url:'/dri/api/get_fits_by_tilename'},fields:[{name:'tilename',type:'string','default':null,persist:!1},{name:'band',type:'string','default':null,persist:!1},{name:'url',type:'string','default':null,persist:!1}]},0,0,0,0,0,0,[visiomatic.model,'FitsFiles'],0);Ext.cmd.derive('visiomatic.store.FitsFiles',common.store.MyStore,{model:'visiomatic.model.FitsFiles',remoteFilter:!0,pageSize:0,proxy:{url:'/dri/api/get_fits_by_tilename'},sorters:[{property:'tilename',direction:'ASC'}]},0,0,0,0,['store.fits-files'],0,[visiomatic.store,'FitsFiles'],0);Ext.cmd.derive('visiomatic.download.FitsModel',Ext.app.ViewModel,{stores:{fitsFiles:{type:'fits-files'}}},0,0,0,0,['viewmodel.fits-files'],0,[visiomatic.download,'FitsModel'],0);Ext.cmd.derive('visiomatic.download.DescutDownloadWindow',Ext.window.Window,{viewModel:'fits-files',controller:'fits-files',title:'Download',width:600,height:400,modal:!0,autoShow:!0,closeAction:'destroy',layout:{type:'vbox',align:'stretch'},initComponent:function(){var a=this;Ext.apply(this,{layout:'fit',items:[{xtype:'gridpanel',scrollable:!0,bind:{store:'{fitsFiles}'},columns:[{text:'Tile Name',dataIndex:'tilename',flex:1},{text:'Band',dataIndex:'band'},{text:'URL',dataIndex:'url',renderer:function(a,b,c){return ' '}}]}],buttons:[{xtype:'label',text:'Right click "Save link as" to download files',flex:1},{text:'Cancel',scope:a,handler:'onCancel'}]});Ext.window.Window.prototype.initComponent.apply(this,arguments)},onCancel:function(){this.close()},loadFits:function(a,b){var c=this;this.loadFits=a;c.fireEvent('changeLoadFits',a,b)}},0,['target-download-descut'],['component','box','container','panel','window','target-download-descut'],{'component':!0,'box':!0,'container':!0,'panel':!0,'window':!0,'target-download-descut':!0},['widget.target-download-descut'],0,[visiomatic.download,'DescutDownloadWindow'],0);Ext.cmd.derive('visiomatic.Visiomatic',Ext.panel.Panel,{controller:'visiomatic',viewModel:'visiomatic',height:'100%',width:'100%',libL:null,config:{map:null,mapOptions:{fullscreenControl:!0,zoom:1,enableLineaOverlay:!0},prefix:'',enableSidebar:!0,enableSmallCrosshair:!1,enableCatalogs:!1,availableCatalogs:['GALEX_AIS','2MASS','AllWISE','SDSS','PPMXL','Abell','NVSS','FIRST','GAIA_DR1'],enableMiniMap:!1,miniMapOptions:{position:'topright',width:128,height:128,zoomLevelOffset:-6,nativeCelsys:!0},miniMap:null,enableWcs:!0,wcsUnits:[{label:'RA, Dec (Deg)',units:'deg'},{label:'RA, Dec (HMS)',units:'HMS'}],enableScale:!0,image:null,imageLayer:null,imageOptions:{credentials:!0,center:!1,fov:!1,mixingMode:'color',defaultChannel:2,contrast:0.7,gamma:2.8,colorSat:2,channelLabelMatch:'[ugrizY]'},radiusOptions:{weight:2,opacity:0.8,fillOpacity:0.01,color:'#2db92d',dashArray:'5, 5, 1, 5',interactive:!1},catalogOptions:{weight:2,opacity:0.8,fillOpacity:0.01,color:'#2db92d',interactive:!0,pointType:'circle',pointSize:0.001},crosshairOptions:{color:'#90FA3A',weight:1,opacity:0.5,smoothFactor:1,centerPadding:0.001,size:0.005},release:null,tag:null,dataset:null,currentDataset:null,enableTools:!0,auxTools:[],enableLink:!0,enableShift:!0,ready:!1,lradius:null,lcrosshair:null,showCrosshair:!1,enableContextMenu:!0,mlocate:'',showComments:!1},_winCatalogOverlay:null,bind:{release:'{release}',tag:'{tag}',dataset:'{dataset}'},initComponent:function(){var a=this,e=window.location.host,b,d,c;if(window.L){a.libL=window.L}else {console.log('window.L ainda nao esta carregada, incluir no app.json a biblioteca Leaflet')}this.cmpVisiomatic=c=Ext.create('Ext.Component',{id:a.getMapContainer(),width:'100%',height:'100%',listeners:{deactivate:a.onDeactivate}});if(a.getEnableTools()){b=a.makeToolbar();tools=a.makeToolbarButtons();b.add(tools);a.tbar=b}Ext.apply(this,{items:[c]});Ext.panel.Panel.prototype.initComponent.apply(this,arguments)},afterRender:function(){var a=this,c=a.libL,d=a.getMapContainer(),e=a.getMapOptions(),b;Ext.panel.Panel.prototype.afterRender.apply(this,arguments);b=c.map(d,e);b.attributionControl.setPrefix(a.getPrefix());c.control.reticle().addTo(b);b.on('dblclick',a.onDblClick,a);b.on('contextmenu',a.onContextMenuClick,a);b.on('layeradd',a.onLayerAdd,a);b.on('move',a.onMove,a);b.on('mousemove',a.onMouseMove,a);b.on('overlaycatalog',a.showCatalogOverlayWindow,a);b.on('mouseup',a.savePreferences,a);b.on('keypress',a.savePreferences,a);a.setMap(b);if(a.getEnableSidebar()){a.createSidebar()}if(a.getEnableWcs()){a.addWcsController()}if(a.getEnableScale()){a.addScaleController()}a.cmpMousePosition=a.makeMousePosition()},savePreferences:function(){var c=this,a=c.getImageLayer();var b={credentials:!0,channelLabelMatch:'[ugrizY]',mixingMode:a.iipMode,contrast:a.iipContrast,gamma:a.iipGamma,invertCMap:a.iipInvertCMap,colorSat:a.iipColorSat,quality:a.iipQuality};localStorage.removeItem('imageOptions');localStorage.setItem('imageOptions',JSON.stringify(b))},onResize:function(){Ext.panel.Panel.prototype.onResize.apply(this,arguments);var a=this.getMap();if(a){a.invalidateSize()}},onDeactivate:function(){console.log('onDeactivate');var a=this;if(a._winCatalogOverlay){a._winCatalogOverlay.close()}},getMapContainer:function(){return this.getId()+'-placeholder'},createSidebar:function(){var c=this,b=c.libL,f=c.getMap(),e=c.getAvailableCatalogs(),a,d=[];a=b.control.sidebar().addTo(f);b.control.iip.channel().addTo(a);b.control.iip.image().addTo(a);if(c.getEnableCatalogs()){Ext.Array.each(e,function(a){d.push(b.Catalog[a])});b.control.iip.catalog(d).addTo(a)}b.control.iip.region([]).addTo(a);b.control.iip.profile().addTo(a);b.control.iip.snapshot().addTo(a);a.addTabList()},createSmallCrosshair:function(){var b=this,a=b.getRaDec(),c={color:'#90FA3A',weight:1,opacity:0.8,smoothFactor:1,centerPadding:5.0E-4,size:0.0015};b.drawSmallCrosshair(a.ra,a.dec,c)},addWcsController:function(){var a=this,c=a.libL,d=a.getMap(),b=a.getWcsUnits();c.control.wcs({coordinates:b,position:'topright'}).addTo(d)},addScaleController:function(){var a=this,b=a.libL,c=a.getMap();b.control.scale.wcs({pixels:!1}).addTo(c)},setCurrentDataset:function(a){var b=this;b.currentDataset=a},setImage:function(e,d){var a=this,i=a.libL,j=a.getMap(),h=a.getMiniMap(),b=a.getImageLayer(),c=a.getImageOptions(),f,k,g;a.setReady(!1);if(a._winCatalogOverlay!==null){a._winCatalogOverlay.close();a._winCatalogOverlay=null}d=d||{};if(b){c={credentials:c.credentials,channelLabelMatch:'[ugrizY]',mixingMode:b.iipMode,contrast:b.iipContrast,gamma:b.iipGamma,invertCMap:b.iipInvertCMap,colorSat:b.iipColorSat,quality:b.iipQuality}}f=Ext.Object.merge(c,d);a.image=e;if(!b){b=i.tileLayer.iip(e,f).addTo(j);a.setImageLayer(b)}else {a.removeImageLayer();g=i.tileLayer.iip(e,f).addTo(j);a.setImageLayer(g)}if(a.getEnableMiniMap()){if(h){h.remove()}a.createMiniMap()}},createMiniMap:function(){var a=this,e=a.libL,h=a.getMap(),g=a.getMiniMapOptions(),f=a.getImageOptions(),d=a.getImage(),c,b;if(d){b=e.tileLayer.iip(d,{credentials:f.credentials,mixingMode:'color',defaultChannel:2,contrast:0.7,gamma:2.8,colorSat:2,channelLabelMatch:'[ugrizY]'});c=e.control.extraMap(b,g).addTo(h);a.setMiniMap(c)}},setView:function(c,a,h,f){var b=this,g=b.libL,e=b.getMap(),d;c=parseFloat(parseFloat(c).toFixed(3));a=parseFloat(parseFloat(a).toFixed(3));d=g.latLng(a,c);e.setView(d,e.options.crs.fovToZoom(e,h,d));if(b.getShowCrosshair()){if(!f){b.drawCrosshair(c,a)}}},onLayerAdd:function(b){var a=this;if(b.layer.type==='tilelayer'){a.setReady(!0);a.fireEvent('changeimage',a)}},onDblClick:function(b){var a=this;a.fireEvent('dblclick',b,a)},onContextMenuClick:function(b){var a=this,c=a.getMap();if(!a.isObjectContextMenu){a.showContextMenuImage(b)}a.isObjectContextMenu=!1},removeImageLayer:function(){var b=this,a=b.getMap();if(a!==null){a.eachLayer(function(b){a.removeLayer(b)})}},getRaDec:function(){var c=this,d=c.libL,b=c.getMap(),e=b.options.crs,a=b.getCenter();return {'ra':parseFloat(a.lng),'dec':parseFloat(a.lat)}},getBounds:function(){var m=this,j=m.libL,c=m.getMap(),b=c.options.crs,k=b.forceNativeCelsys&&!this.options.nativeCelsys,e=k?b.celsysToEq(c.getCenter()):c.getCenter(),n=Math.abs(Math.cos(e.lat*Math.PI/180)),d=c.getPixelBounds(),f=c.getZoom(),a,g,l,i,h,o;a=k?[b.celsysToEq(c.unproject(d.min,f)),b.celsysToEq(c.unproject(j.point(d.min.x,d.max.y),f)),b.celsysToEq(c.unproject(d.max,f)),b.celsysToEq(c.unproject(libLpoint(d.max.x,d.min.y),f))]:[c.unproject(d.min,f),c.unproject(j.point(d.min.x,d.max.y),f),c.unproject(d.max,f),c.unproject(j.point(d.max.x,d.min.y),f)];g=parseFloat(e.lng.toFixed(6));l=parseFloat(e.lat.toFixed(6));i=(Math.max(b._deltaLng(a[0],e),b._deltaLng(a[1],e),b._deltaLng(a[2],e),b._deltaLng(a[3],e))-Math.min(b._deltaLng(a[0],e),b._deltaLng(a[1],e),b._deltaLng(a[2],e),b._deltaLng(a[3],e)))*n;h=Math.max(a[0].lat,a[1].lat,a[2].lat,a[3].lat)-Math.min(a[0].lat,a[1].lat,a[2].lat,a[3].lat);if(h<1.0E-4){h=1.0E-4}if(i<1.0E-4){i=1.0E-4}if(g>360){g=g-360}return {lat:parseFloat(l.toFixed(6)),lng:parseFloat(g.toFixed(6)),dlat:parseFloat(h.toFixed(6)),dlng:parseFloat(i.toFixed(6))}},getBox:function(){var h=this,e,d,b,c,a,g,f;bounding=h.getBounds();if(bounding.lng>360){bounding.lng=bounding.lng-360}d=parseFloat(bounding.lng+bounding.dlng/2).toFixed(6);b=parseFloat(bounding.lat+bounding.dlat/2).toFixed(6);c=parseFloat(bounding.lng-bounding.dlng/2).toFixed(6);a=parseFloat(bounding.lat-bounding.dlat/2).toFixed(6);g=[d,b];f=[c,a];e=[g,f];return e},getFov:function(){var e=this,a=e.getMap(),d=a.options.crs,c=a.getCenter(),b;b=d.zoomToFov(a,a.getZoom(),c);return b},onMove:function(){var a=this,b=a.getRaDec(),c=a.getFov();a.fireEvent('changeposition',b,c,a)},onMouseMove:function(b){var d=String(b.latlng.lng.toFixed(5)+', '+b.latlng.lat.toFixed(5)),a=this,c=a.getMap();this.cmpMousePosition.children[0].innerHTML='Mouse RA, Dec ('+d+')';a.currentPosition={radec:[b.latlng.lng.toFixed(5),b.latlng.lat.toFixed(5)],container:[b.containerPoint.x,b.containerPoint.y]};if(a.cropInit&&a.cropInit==a.cropEnd&&a.isCropping){if(a.cropRectangle){c.removeLayer(a.cropRectangle)}a.cropRectangle=a.drawRectangle(a.cropInit['radec'],a.currentPosition['radec'])}if(a.getEnableSmallCrosshair()){a.createSmallCrosshair()}},getLinkToPosition:function(){var b=this,e=b.getMap(),a=b.getRaDec(),c=b.getFov(),d;if(a.dec>0){d=a.ra.toFixed(3).replace('.',',')+'+'+a.dec.toFixed(3).replace('.',',')}else {d=a.ra.toFixed(3).replace('.',',')+a.dec.toFixed(3).replace('.',',')}if(c){c=c.toFixed(2).replace('.',',')}b.fireEvent('link',encodeURIComponent(d),c,a,b)},onShift:function(){this.fireEvent('shift',this.getRaDec(),this)},isReady:function(){return this.getReady()},panTo:function(a){var b=this.getMap();this.coordinatesToLatLng(a,function(c){if(c){b.panTo(c)}})},coordinatesToLatLng:function(a,b){visiomatic.Visiomatic.coordinatesToLatLng(a,b)},hmsToLatLng:function(a,b){visiomatic.Visiomatic.hmsToLatLng(a,b)},drawRadius:function(g,e,d,n,l){var a=this,b=a.libL,f=a.getMap(),j=f.options.crs,h=a.getRadiusOptions(),o=g+'_'+e,i,c,m;if(a.getLradius()){f.removeLayer(a.getLradius());a.setLradius(null)}m=Ext.Object.merge(h,l);if(n==='arcmin'){d=d/60}var k={type:'FeatureCollection',features:[{type:'Feature',id:o,properties:{},geometry:{type:'Point',coordinates:[g,e]}}]};c=b.geoJson(k,{coordsToLatLng:function(a){if(j.forceNativeCelsys){var c=j.eqToCelsys(b.latLng(a[1],a[0]));return new b.LatLng(c.lat,c.lng,a[2])}else {return new b.LatLng(a[1],a[0],a[2])}},pointToLayer:function(a,c){i=Ext.Object.merge(h,{majAxis:d,minAxis:d,posAngle:90});return b.ellipse(b.latLng(e,g),i)}});a.setLradius(c);f.addLayer(c);return c},showHideRadius:function(d){var c=this,b=c.getMap(),a=c.getLradius();if(a!==null){if(d){b.addLayer(a)}else {b.removeLayer(a)}}},overlayCatalog:function(l,j,k){var c=this,b=c.libL,g=c.getMap(),h=g.options.crs,i=c.getCatalogOptions(),a,d,f,e;a=Ext.Object.merge(i,k);d={type:'FeatureCollection',features:[]};j.each(function(a){if(c.isInsideTile(a.get('_meta_ra'),a.get('_meta_dec'))){f={type:'Feature',id:a.get('_meta_id'),title:l,properties:a.data,is_system:a.get('_meta_is_system'),geometry:{type:'Point',coordinates:[a.get('_meta_ra'),a.get('_meta_dec')]}};d.features.push(f)}},c);e=b.geoJson(d,{coordsToLatLng:function(a){if(h.forceNativeCelsys){var c=h.eqToCelsys(b.latLng(a[1],a[0]));return new b.LatLng(c.lat,c.lng,a[2])}else {return new b.LatLng(a[1],a[0],a[2])}},pointToLayer:function(e,d){if(e.is_system){if(e.properties._meta_radius){radius=e.properties._meta_radius/60;opts=c.getRadiusOptions()}}if(a.pointType==='ellipse'){var q=0.001,r=0.001,m=90;try{var o=e.properties._meta_a_image,p=e.properties._meta_b_image,f=e.properties._meta_theta_image;if(typeof o=='number'&&typeof p=='number'&&typeof f=='number'){q=o/3600;r=p/3600;m=f}}catch(x){}a.majAxis=q,a.minAxis=r,a.posAngle=m;return b.ellipse(d,a)}else {if(a.pointType==='square'){var w=[[d.lat-a.pointSize,d.lng-a.pointSize],[d.lat+a.pointSize,d.lng+a.pointSize]];var v=b.rectangle(w,a);return v}else {if(a.pointType==='triangle'){var h,i,g,n,s,t,u;h=[b.latLng(d.lat-a.pointSize,d.lng-a.pointSize),b.latLng(d.lat-a.pointSize,d.lng+a.pointSize)];g=[b.latLng(d.lat-a.pointSize,d.lng-a.pointSize),b.latLng(d.lat+a.pointSize,d.lng)];i=[b.latLng(d.lat-a.pointSize,d.lng+a.pointSize),b.latLng(d.lat+a.pointSize,d.lng)];s=b.polyline(h,a);u=b.polyline(g,a);t=b.polyline(i,a);n=new b.LayerGroup([s,u,t]);return n}else {a.majAxis=a.pointSize;a.minAxis=a.pointSize;a.posAngle=90;circle=b.ellipse(d,a);return circle}}}}}).bindPopup(c.createOverlayPopup).on('dblclick',function(){alert('TODO: OPEN IN EXPLORER!')}).on('contextmenu',c.onLayerContextMenu,c);g.addLayer(e);c.redraw();return e},redraw:function(){var d=this,c=d.getMap(),a=$(c.getContainer()),b=a.width();if(b>0){a.css({width:b+2});c.invalidateSize();a.css({width:'initial'})}},createOverlayPopup:function(i){var a=i.feature,h=a.properties,j=['_meta_mag_auto_g','_meta_mag_auto_r','_meta_mag_auto_i','_meta_mag_auto_z','_meta_mag_auto_y'],e=[],d=[],c=a.properties._meta_id,g=['RAJ2000','DEJ2000'],b=[],f;Ext.each(j,function(a){try{mag_name=a.slice(-1);if(mag_name=='y'){mag_name='Y'}mag_value=h[a];tag=''+mag_name+': '+mag_value.toFixed(2)+'';e.push(tag)}catch(k){}});if(a.properties._meta_is_system){c=''+a.properties._meta_id+''}else {if(a.properties._meta_catalog_class=='coadd_objects'){c=''+a.properties._meta_id+''}else {if(a.properties._meta_object_url){c=''+a.properties._meta_id+'';for(property in a.properties){if(!property.startsWith('_meta_')&&g.indexOf(property)==-1){b.push(property)}}if(b.length<=15){for(key in b.sort()){property=b[key];d.push(''+property+': '+a.properties[property]+'')}}}else {}}}f=''+a.title+'
    '+e.join('')+d.join('')+'
    ID: '+c+'
    RA, Dec (deg): '+a.properties._meta_ra.toFixed(5)+', '+a.properties._meta_dec.toFixed(5)+'
    ';return f},onDblClickOverlay:function(){console.log('onDblClickOverlay(%o)',arguments)},showHideLayer:function(a,c){var d=this,b=d.getMap();if(a!==null){if(c){b.addLayer(a)}else {b.removeLayer(a)}}},showHideComments:function(a,b){},onLayerContextMenu:function(a){var b=this;b.isObjectContextMenu=!0;if(a.target.targetPosition){b.showContextMenuImage(a)}else {if(a.target.targetObjet){a.layer={feature:a.target.targetObjet.feature}}b.showContextMenuObject(a)}},createCommentIcon:function(d,c){var b=this,e,a;a=b.markPosition(d,'mapmaker-comment comment-maker').on('contextmenu',b.onLayerContextMenu,b);if(c){c.commentMaker=a;a.targetObjet=c}else {a.targetPosition=d}a.getElement().style.display=b.getShowComments()?'':'none'},updateComment:function(b,a,c){},markPosition:function(i,g,e){var h=this,c=h.libL,j=h.getMap(),b,a,f,d;if(arguments.length==2){b=i;e=g;d=[12,25]}else {b=c.latLng(g,i);d=[8,44]}if(e){f=c.divIcon({className:'visiomatic-marker-position',iconAnchor:d,html:''});a=c.marker(b,{icon:f})}else {a=c.marker(b)}a.addTo(j);return a},setShowCrosshair:function(c){var b=this,d=b.getMap(),a=b.lcrosshair;b.showCrosshair=c;if(a!==null){if(c){d.addLayer(a)}else {d.removeLayer(a)}}},onToggleCrosshair:function(c,a,d){var b=this;if(d.pressed){b.drawCrosshair(c,a)}else {b.removeCrosshair(c,a)}},drawCrosshair:function(e,d,m){var c=this,a=c.libL,l=c.getMap(),o=c.getCrosshairOptions(),n=null,b,f,g,p,k,h,j,i;b=Ext.Object.merge({},o);if(m){b=Ext.Object.merge(b,m)}if(c.lcrosshair){if(l.hasLayer(c.lcrosshair)){l.removeLayer(c.lcrosshair);c.lsmallcrosshair=null}}p=a.latLng(d,e);f=b.centerPadding?b.centerPadding:0.001;g=b.size?b.size:0.005;k=[a.latLng(d+f,e),a.latLng(d+g,e)];h=[a.latLng(d-f,e),a.latLng(d-g,e)];j=[a.latLng(d,e+f),a.latLng(d,e+g)];i=[a.latLng(d,e-f),a.latLng(d,e-g)];k=a.polyline(k,b);h=a.polyline(h,b);j=a.polyline(j,b);i=a.polyline(i,b);n=new a.LayerGroup([k,h,j,i]);c.lcrosshair=n;if(c.getShowCrosshair()){l.addLayer(c.lcrosshair)}return c.lcrosshair},removeCrosshair:function(){var a=this,b=a.getMap();if(a.lcrosshair){if(b.hasLayer(a.lcrosshair)){b.removeLayer(a.lcrosshair);a.lsmallcrosshair=null}}},drawSmallCrosshair:function(d,c,e){var b=this,a=b.libL,h=b.getMap(),n=b.getCrosshairOptions(),p=null,m,f,g,o,l,i,k,j;m=Ext.Object.merge({},n);if(e){m=Ext.Object.merge(m,e)}if(b.lsmallcrosshair){if(h.hasLayer(b.lsmallcrosshair)){h.removeLayer(b.lsmallcrosshair);b.lsmallcrosshair=null}}o=a.latLng(c,d);f=0.005/h._zoom;g=0.01/h._zoom;l=[a.latLng(c+f,d),a.latLng(c+g,d)];i=[a.latLng(c-f,d),a.latLng(c-g,d)];k=[a.latLng(c,d+f),a.latLng(c,d+g)];j=[a.latLng(c,d-f),a.latLng(c,d-g)];l=a.polyline(l,e);i=a.polyline(i,e);k=a.polyline(k,e);j=a.polyline(j,e);layerSmall=new a.LayerGroup([l,i,k,j]);b.lsmallcrosshair=layerSmall;if(b.getEnableSmallCrosshair()&&e){h.addLayer(b.lsmallcrosshair)}return b.lsmallcrosshair},showCatalogOverlayWindow:function(){var b=this,c=b.getCurrentDataset(),a=b._winCatalogOverlay;if(c!==null&&c.get('id')>0){if(a!=null){a.show()}else {a=Ext.create('visiomatic.catalog.CatalogOverlayWindow',{visiomatic:b});b.add(a);a.show();b._winCatalogOverlay=a}b._winCatalogOverlay.setDataset(c)}else {console.log('Dataset nao foi definido, a funcao overlay precisa de um dataset.');return !1}},showDownloadWindow:function(){var d=this,a=d.getCurrentDataset(),c;if(a.get('tli_tilename')){c=a.get('tli_tilename');var b=Ext.create('visiomatic.download.DescutDownloadWindow');b.loadFits(c,'Y3A1_COADD');b.show()}else {alert('File not found.')}},showContextMenuImage:function(b){var a=this,c=b.target,d={x:b.originalEvent.clientX,y:b.originalEvent.clientY};if(!a.getEnableContextMenu()){return}if(b.originalEvent.target.classList.contains('comment-maker')&&!c.targetPosition){return a.showContextMenuObject(b)}if(!this.contextMenuImage){this.contextMenuImage=new Ext.menu.Menu({items:[{id:'comment-position',text:'Comment Position',handler:function(c){a.fireEvent('imageMenuItemClick',a.contextMenuImage.target,a.getCurrentDataset())}}]})}c.latlng=b.latlng;a.contextMenuImage.target=c;a.contextMenuImage.showAt(d)},initCrop:function(){var a=this,b=a.getMap();b.on('mousedown',a.startCrop,a);a.isCropping=!0;b.dragging.removeHooks()},startCrop:function(){var a=this,b=a.getMap();a.cropInit=a.currentPosition;a.cropEnd=a.cropInit;b.off('mousedown',a.startCrop,a);b.on('mouseup',a.endCrop,a)},endCrop:function(c){var a=this,b=a.getMap();a.cropEnd=a.currentPosition;b.off('mouseup',a.endCrop,a);a.downloadCrop(a.cropInit,a.cropEnd);if(a.cropRectangle){b.removeLayer(a.cropRectangle)}a.cropInit=null;a.isCropping=!1;b.dragging.addHooks()},downloadCrop:function(d,e){var i=this,p=i.libL,h=i.getMap(),g=document.createElement('a'),a=i.getImageLayer();var o=h.getCenter(),j=h.getPixelBounds(),c=h.getZoom(),b;if(c>a.iipMaxZoom){b=Math.pow(2,c-a.iipMaxZoom);c=a.iipMaxZoom}else {b=1}var l=a.iipImageSize[c].x*b,m=a.iipImageSize[c].y*b,f=Math.abs(d.container[0]-e.container[0]),n=Math.abs(d.container[1]-e.container[1]);var k={x:j.min.x+Math.min(d.container[0],e.container[0]),y:j.min.y+Math.min(d.container[1],e.container[1])};g.href=a.getTileUrl({x:1,y:1}).replace(/JTL\=\d+\,\d+/g,'RGN='+k.x/l+','+k.y/m+','+f/l+','+n/m+'&WID='+(this._snapType===0?Math.floor(f/b):Math.floor(f/b/a.wcs.scale(c)))+'&CVT=jpeg');g.download=a._title+'_'+p.IIPUtils.latLngToHMSDMS(o).replace(/[\s\:\.]/g,'')+'.jpg';var q=Ext.create('visiomatic.crop.CropWindow',{image:g,height:n+100,width:f+100})},showContextMenuObject:function(a){var c,b=this,d={x:a.originalEvent.clientX,y:a.originalEvent.clientY};if(!b.getEnableContextMenu()){return}if(!this.contextMenuObject){this.contextMenuObject=new Ext.menu.Menu({items:[{id:'comment-object',text:'Comment Object',handler:function(c){b.fireEvent('objectMenuItemClick',a,this.feature)}}]})}c=b.contextMenuObject.items.get('comment-object');c.feature=a.layer?a.layer.feature:null;b.contextMenuObject.showAt(d)},drawRectangle:function(h,j,q){var f=this,a=f.libL,r=f.getMap(),e=h[0],c=h[1],d=j[0],b=j[1],l,g,k,i,p,m,n,o;pathOptions=Ext.Object.merge(f.getCrosshairOptions(),q);l=[a.latLng(c,d),a.latLng(c,e)];g=[a.latLng(b,d),a.latLng(b,e)];k=[a.latLng(c,e),a.latLng(b,e)];i=[a.latLng(c,d),a.latLng(b,d)];p=a.polyline(l,pathOptions);m=a.polyline(g,pathOptions);n=a.polyline(k,pathOptions);o=a.polyline(i,pathOptions);layer=new a.LayerGroup([p,m,n,o]);r.addLayer(layer);return layer},isInsideTile:function(d,b){var c=this,a=c.getCurrentDataset();if(a!=null&&a.get('id')>0){return a.isInsideTile(d,b)}else {return !0}},statics:{coordinatesToLatLng:function(a,c){var d,b=visiomatic.Visiomatic.strToSystem(a);a=a.trim().replace(/( )+/g,' ');d=a.split(',');if(b&&b.system=='latlng'){return c(b.value)}else {if(b&&b.system=='HMS'){return visiomatic.Visiomatic.hmsToLatLng(a,c)}}c(null)},hmsToLatLng:function(b,a){var c='http://cdsweb.u-strasbg.fr/cgi-bin/nph-sesame/-oI/A?'+b;$.get(c,function(c){var d=visiomatic.Visiomatic.parseCoords(c,!0);if(a){a(d)}})},latLngToHMSDMS:function(f){var c=(f.lng+360)/360;c=(c-Math.floor(c))*24;var e=Math.floor(c),d=(c-e)*60,a=Math.floor(d),b=(d-a)*60;if(b>=60){a++;b=0}if(a===60){e++;a=0}var j=(e<10?'0':'')+e.toString()+':'+(a<10?'0':'')+a.toString()+':'+(b<10?'0':'')+b.toFixed(3),h=Math.abs(f.lat),i=f.lat<0?'-':'+',g=Math.floor(h);d=(h-g)*60;a=Math.floor(d);b=(d-a)*60;if(b>=60){a++;b=0}if(a===60){e++;a=0}return j+' '+i+(g<10?'0':'')+g.toString()+':'+(a<10?'0':'')+a.toString()+':'+(b<10?'0':'')+b.toFixed(2)},strToSystem:function(a){var b;if(a){a=a.trim().replace(/( )+/g,' ');b=a.split(',');if(b.length==2&&a.split(':').length==1){return {value:{lng:Number(b[0]),lat:Number(b[1])},system:'latlng'}}b=a.split(' ');if(b.length==2&&a.split(':').length==5){return {value:a,system:'HMS'}}}return null},parseCoords:function(b){var a=/J\s(\d+\.?\d*)\s*,?\s*\+?(-?\d+\.?\d*)/g.exec(b);if(a&&a.length>=3){return L.latLng(Number(a[2]),Number(a[1]))}return null}}},0,['visiomatic'],['component','box','container','panel','visiomatic'],{'component':!0,'box':!0,'container':!0,'panel':!0,'visiomatic':!0},['widget.visiomatic'],[['interface',visiomatic.Interface]],[visiomatic,'Visiomatic'],0);Ext.cmd.derive('visiomatic.crop.CropWindow',Ext.window.Window,{title:'Crop',width:400,height:400,modal:!0,autoShow:!0,closeAction:'destroy',layout:{type:'hbox'},initComponent:function(){var a=this,b=a.image;Ext.apply(this,{layout:'ux.center',items:[{xtype:'image',src:b.href,alt:b.download,height:a.height-100,width:a.width-100}],buttons:[{xtype:'label',text:'Right click "Save image as" to download the image',flex:1},{text:'Cancel',scope:a,handler:'onCancel'}]});Ext.window.Window.prototype.initComponent.apply(this,arguments)},onCancel:function(){this.close()},loadImage:function(a){var b=this;this.image=a}},0,['target-download-crop'],['component','box','container','panel','window','target-download-crop'],{'component':!0,'box':!0,'container':!0,'panel':!0,'window':!0,'target-download-crop':!0},['widget.target-download-crop'],0,[visiomatic.crop,'CropWindow'],0);Ext.cmd.derive('aladin.Events',Ext.Base,{mouseIsDown:!1,mouseInitialPosition:[],mouseLastPosition:[],addCustomEvents:function(){var a=this;a.addDblClickListener();a.addMouseDown();a.addMouseMoveListener();a.addMouseUP()},addDblClickListener:function(){var a=this,d=a.getAladin(),f=d.view,e=d.view.reticleCanvas,b,c;e.addEventListener('dblclick',function(d){c=f.imageCanvas.relMouseCoords(d);b=a.mousePositionToSky(c);if(b){a.updateLocation(b);a.fireEvent('ondblclick',b,a)}})},addMouseDown:function(){var a=this,f=a.getAladin(),d=f.view,e=d.reticleCanvas,b,c;e.addEventListener('mousedown',function(e){c=d.imageCanvas.relMouseCoords(e);b=a.mousePositionToSky(c);if(b){a.mouseIsDown=!0;a.mouseInitialPosition=b;a.mouseLastPosition=b}})},addMouseMoveListener:function(){var a=this,f=a.getAladin(),d=f.view,e=d.reticleCanvas,b,c;e.addEventListener('mousemove',function(e){c=d.imageCanvas.relMouseCoords(e);b=a.mousePositionToSky(c);if(b){a.updateLocation(a.getRaDec(),b);if(a.mouseIsDown){a.mouseLastPosition=b;a.fireEvent('reticlemove',a.getRaDec(),a)}}})},addMouseUP:function(){var a=this,f=a.getAladin(),d=f.view,e=d.reticleCanvas,c,b;e.addEventListener('mouseup',function(e){b=d.imageCanvas.relMouseCoords(e);c=a.mousePositionToSky(b);if(c){if(a.mouseIsDown){if(!Ext.Array.equals(a.mouseInitialPosition,a.mouseLastPosition)){a.fireEvent('onpanend',a.getRaDec(),a)}else {a.fireEvent('onclick',a.mouseLastPosition,a)}}a.mouseIsDown=!1;a.mouseInitialPosition=[];a.mouseLastPosition=[]}})},mousePositionToSky:function(e){var g=this,f=g.getAladin(),a=f.view,d,b,c=[];d=AladinUtils.viewToXy(e.x,e.y,a.width,a.height,a.largestDim,a.zoomFactor);try{b=a.projection.unproject(d.x,d.y)}catch(h){return}if(a.cooFrame==CooFrameEnum.GAL){c=CooConversion.GalacticToJ2000([b.ra,b.dec])}else {c=[parseFloat(b.ra.toFixed(5)),parseFloat(b.dec.toFixed(5))]}return c},skyToString:function(a){if(a&&a[0]&&a[1]){return String(a[0].toFixed(5)+', '+a[1].toFixed(5))}},updateLocation:function(e,d){var a=this,c,b;c=a.skyToString(e);b=a.skyToString(d);a.setLocation(c,b)},onClickBtnMap:function(){var a=this,c=a.getViewModel(),b=c.get('release');if(a.windowMapSelection==null){a.windowMapSelection=Ext.create('aladin.maps.MapSelectionWindow',{width:182,height:237,x:45,y:55,resizable:!1,aladin:a})}a.windowMapSelection.setRelease(b);if(a.windowMapSelection.isHidden()){a.windowMapSelection.show()}else {a.windowMapSelection.hide()}}},0,0,0,0,0,0,[aladin,'Events'],0);Ext.cmd.derive('aladin.model.Image',Ext.data.Model,{fields:[{name:'id',type:'int'},{name:'img_url',type:'string'},{name:'product',type:'int'}]},0,0,0,0,0,0,[aladin.model,'Image'],0);Ext.cmd.derive('aladin.store.Images',common.store.MyStore,{model:'aladin.model.Image',autoLoad:!1,pageSize:0,remoteFilter:!0,proxy:{type:'django',url:'/dri/api/aladin/image/'}},0,0,0,0,['store.aladin_images'],0,[aladin.store,'Images'],0);Ext.cmd.derive('aladin.maps.MapSelectionController',Ext.app.ViewController,{listen:{component:{'aladin-maps-mapselectionwindow':{changerelease:'onChangeRelease'}}},onChangeRelease:function(k){var a=this,h=a.getViewModel(),g=h.getView(),c=h.getStore('maps_store'),f=a.lookup('cmbType'),e=a.lookup('cmbClass'),b=f.getStore(),i=e.getStore(),d=a.lookup('cmbFilter'),j=d.getStore();g.setLoading(!0);c.addFilter([{property:'release_id',value:k},{property:'with_image',value:!0}]);c.load({callback:function(){f.reset();b.removeAll();e.reset();i.removeAll();d.reset();j.removeAll();c.each(function(a){if(b.findRecord('pgr_group',a.get('pgr_group'))==null){b.add(a)}},this);g.setLoading(!1)}})},onSelectMapType:function(h){var b=this,i=b.getViewModel(),f=h.selection,g=i.getStore('maps_store'),d=b.lookup('cmbClass'),a=d.getStore(),c=b.lookup('cmbFilter'),e=c.getStore();d.reset();a.removeAll();c.reset();e.removeAll();g.each(function(b){if(b.get('pgr_group')==f.get('pgr_group')&&a.findRecord('prd_class',b.get('prd_class'))==null){a.add(b)}},this)},onSelectMapClass:function(f){var d=this,g=d.getViewModel(),c=f.selection,e=g.getStore('maps_store'),b=d.lookup('cmbFilter'),a=b.getStore();b.reset();a.removeAll();e.each(function(b){if(b.get('pgr_group')==c.get('pgr_group')&&b.get('prd_class')==c.get('prd_class')){a.add(b)}},this)},onSelectMapFilter:function(g){var d=this,c=d.getViewModel(),f=c.getView(),e=f.getAladin(),b=g.selection,a=c.getStore('aladin_images_store');a.addFilter([{property:'product',value:b.get('id')}]);a.load({callback:function(){if(a.getCount()!=1){Ext.MessageBox.alert('Warning',a.getCount().toString()+' images found for same map!')}else {aladin_last_nonmap_survey=c.get('aladin_last_nonmap_survey');if(aladin_last_nonmap_survey==null){c.set('aladin_last_nonmap_survey',e.getImageSurvey())}var f=a.getAt(0).get('img_url');survey={'id':'map_'+b.get('id').toString(),'url':f,'name':b.get('pcl_display_name'),'filter':b.get('prd_filter'),'maxOrder':3,'frame':'equatorial','options':{'imgFormat':'png'}};e.readProperties(f,function(a){survey['maxOrder']=a['maxOrder'];d.setMapSurvey(survey)},function(a){console.log('aladin.readProperties() error: %o',a);d.setMapSurvey(survey)})}}})},setMapSurvey:function(c){var e=this,a=e.getViewModel(),d=a.getView(),b=d.getAladin();mapSurvey=b.createImageSurvey(c);b.setImageSurvey(mapSurvey);a.set('aladin_last_map_survey',mapSurvey);a.set('map_selected',!0)},onDisplayOnOff:function(f){var e=this,a=e.getViewModel(),d=a.getView(),c=d.getAladin(),b=null;if(a.get('map_selected')){b=a.get('aladin_last_map_survey')}else {b=a.get('aladin_last_nonmap_survey')}c.setImageSurvey(b)}},0,0,0,0,['controller.mapselection'],0,[aladin.maps,'MapSelectionController'],0);Ext.cmd.derive('aladin.maps.MapSelectionWindow',Ext.window.Window,{controller:'mapselection',viewModel:'mapselection',config:{aladin:null},initComponent:function(){var a=this,b=a.getViewModel();Ext.apply(this,{title:'Map viewer',closeAction:'hide',bodyPadding:5,items:[{xtype:'combobox',reference:'cmbType',fieldLabel:'Map Type:',labelAlign:'top',emptyText:'',displayField:'pgr_display_name',valueField:'pgr_group',store:{type:'maps',autoLoad:!1,remoteFilter:!1},listeners:{select:'onSelectMapType'},editable:!1,queryMode:'local'},{xtype:'combobox',reference:'cmbClass',fieldLabel:'Map Class:',labelAlign:'top',emptyText:'',displayField:'pcl_display_name',valueField:'prd_class',store:{type:'maps',autoLoad:!1,remoteFilter:!1},listeners:{select:'onSelectMapClass'},editable:!1,queryMode:'local'},{xtype:'combobox',reference:'cmbFilter',fieldLabel:'Filter:',labelAlign:'top',emptyText:'',displayField:'prd_filter',valueField:'id',store:{type:'maps',autoLoad:!1,remoteFilter:!1},listeners:{select:'onSelectMapFilter'},editable:!1,queryMode:'local'},{xtype:'checkbox',reference:'chkOnOff',boxLabel:'Display Map',handler:'onDisplayOnOff',bind:{disabled:'{!aladin_switchable}',value:'{map_selected}'}}]});Ext.window.Window.prototype.initComponent.apply(this,arguments)},setRelease:function(a){var b=this,c=b.getViewModel();if(a!=c.get('release')){c.set('release',a);b.fireEvent('changerelease',a)}}},0,['aladin-maps-mapselectionwindow'],['component','box','container','panel','window','aladin-maps-mapselectionwindow'],{'component':!0,'box':!0,'container':!0,'panel':!0,'window':!0,'aladin-maps-mapselectionwindow':!0},['widget.aladin-maps-mapselectionwindow'],0,[aladin.maps,'MapSelectionWindow'],0);Ext.cmd.derive('aladin.Interfaces',Ext.Base,{windowInfo:null,windowMapSelection:null,enableDisableInfo:function(d,c){var b=this,a=b.windowInfo;if(!a){a=b.createWindowInfo()}a.setVisible(c)},createWindowInfo:function(){var b=this,a;a=Ext.create('Ext.Component',{width:280,height:100,x:5,y:10,renderTo:b.body,header:!1,resizable:!1,constrain:!0,cls:'aladin-location-info',style:{position:'absolute',zIndex:29},tpl:['
    {image_survey}','
    {tilename}','
    RA, Dec (deg): {location}
    Mouse RA, Dec (deg): {mlocation}
    ']});b.windowInfo=a;return a},getInfoData:function(){var g=this,a=g.getViewModel(),e=a.get('tile'),f=a.get('tag'),k=a.get('release_name'),d,b,c='',j='',i='',h='';if(f){h=k;i=f.get('tag_display_name')}if(e){j=e.get('tli_tilename')}b=g.getImageSurvey();if(b&&b.id!='empty_survey'){c=b.name}d={image_survey:c,location:a.get('location'),mlocation:a.get('mlocation'),release:h,tag:i,tilename:j};return d},updateInfoData:function(){var a=this,c=a.windowInfo,b=a.getInfoData();if(a.windowInfo){c.setData(b)}},makeToolbar:function(){var c=this,a=c.getToolbarPosition(),b=!1;if(a==='left'||a==='right'){b=!0}return Ext.create('Ext.toolbar.Toolbar',{vertical:b,reference:'aladinToolbar'})},makeToolbarButtons:function(){var a=this,c,b=[],e=a.getToolbarPosition(),f=!1;if(e==='left'||e==='right'){f=!0}if(a.getEnableShift()){b.push({xtype:'button',tooltip:'Goto Visiomatic.',iconCls:'x-fa fa-exchange',scope:a,handler:a.onShift,bind:{disabled:'{!tile}'}})}if(a.getEnableLayersControl()){b.push({xtype:'button',scope:a,iconCls:'x-fa fa-picture-o',tooltip:'Image Layer',menu:a.createImageLayersMenuItems(),menuAlign:'tr',arrowVisible:!1,itemId:'BtnImageLayers'})}if(a.getShowFilters()){var d=Ext.create('common.BandFilter',{filters:['g','r','i','z','Y','irg'],defaultFilter:'irg',vertical:f,listeners:{scope:a,'onfilter':a.onFilter}});a.setBandFilter(d);b.push(d)}if(a.getEnableViewMenu()){b.push(a.createViewMenu())}if(a.getEnableMaps()){b.push({xtype:'button',tooltip:'Map Viewer',iconCls:'x-fa fa-th',scope:a,handler:a.onClickBtnMap})}if(a.getEnableGoto()){b.push({iconCls:'x-fa fa-search',tooltip:'Go To position. 356.0085, 0.5168 or 23 44 2.040 +00 31 0.48',menuAlign:'tr',arrowVisible:!1,menu:[{xtype:'textfield',emptyText:'RA (deg), Dec (deg)',triggers:{'goto':{cls:'x-form-search-trigger',scope:this,handler:a.submitGoToPosition,tooltip:'Go To position. 356.0085, 0.5168 or 23 44 2.040 +00 31 0.48'}},listeners:{scope:this,specialkey:function(b,a){if(a.getKey()==a.ENTER){this.submitGoToPosition(b)}}}}]})}if(a.getEnableExportPng()){if(Ext.firefoxVersion>0){b.push({xtype:'button',tooltip:'Snapshot',iconCls:'x-fa fa-camera',scope:a,handler:a.exportAsPng})}}c=a.getAuxTools();if(c.length>0){Ext.each(c,function(a){b.push(a)})}return b},createViewMenu:function(){var c=this,b,a;a=c.createViewMenuItems();if(a.length>0){b=Ext.create('Ext.button.Button',{iconCls:'x-fa fa-cog',tooltip:'Change view settings',itemId:'ViewMenu',menu:a,menuAlign:'tr',arrowVisible:!1})}return b},createViewMenuItems:function(){var a=this,b=[];b.push({xtype:'menucheckitem',text:'Tiles Grid',itemId:'TileGridMenu',menu:[],menuAlign:'tr',checkHandler:a.onCheckTileGridMenu,disabled:!0,checked:a.getTilesGridVisible()});b.push('-');if(a.getEnableColorMap()){b.push(a.createColorMapMenu())}b.push('-');if(a.getEnableFootprint()){var c=a.getHideFootprint();b.push({xtype:'menucheckitem',itemId:'DesFootprint',text:'Des Footprint',checked:!c,scope:a,checkHandler:a.showDesFootprint})}if(a.getEnableReticle()){b.push({xtype:'menucheckitem',text:'Reticle',checked:!0,scope:a,checkHandler:a.showReticle})}if(a.getEnableHealpixGrid()){b.push({xtype:'menucheckitem',text:'Healpix Grid',scope:a,checkHandler:a.showHealpixGrid})}if(a.getEnableHealpixGrid()){b.push({xtype:'menucheckitem',text:'Info',scope:a,checkHandler:a.enableDisableInfo,checked:a.getInfoEnabled()})}return b},createTileGridMenu:function(){var b=this,d=b.down('#ViewMenu'),c=b.createTileGridMenuItems(),a=b.down('#TileGridMenu');if(!a){a={text:'Tiles Grid',itemId:'TileGridMenu',menu:c};d.getMenu().add(a)}else {a.getMenu().removeAll();a.getMenu().add(c);a.enable()}},createTileGridMenuItems:function(){var a=this,c=a.getStoreTags(),b=[];if(c.count()>0){c.each(function(c){b.push({xtype:'menucheckitem',text:c.get('tag_display_name'),tag:c.get('id'),scope:a,checkHandler:a.onCheckTileGrid})},this)}return b},createColorMapMenu:function(){var c=this,b,a;a=c.createColorMapMenuItems();b={text:'Color Map',tooltip:'Change Color Map',reference:'BtnColorMap',itemId:'BtnColorMap',menu:a,menuAlign:'tr',arrowVisible:!1};return b},createColorMapMenuItems:function(){var a=this,c=a.getColorMaps(),b=[];for(var d in c){b.push({xtype:'menucheckitem',text:c[d],group:'colormaps',mapName:c[d],scope:a,checkHandler:a.changeColorMap})}b.push('-');b.push({text:'Reverse',scope:a,handler:a.reverseColor});return b},updateColorMapMenu:function(){var a=this,d=a.down('#BtnColorMap'),b,c;b=Ext.clone(ColorMap.MAPS_NAMES);a.setColorMaps(b);c=a.createColorMapMenuItems();d.setMenu(c)},createImageLayersMenuItems:function(){var a=this,f=a.getExternalSurveys(),b=a.getSurveys(),c=[],d,g;if(b!=null&&b.length>0){for(var e in b){desSurvey=b[e];if(desSurvey.id!='empty_survey'){c.push({xtype:'menucheckitem',text:desSurvey['name'],group:'imageSurveys',survey:desSurvey,scope:a,checked:!0,checkHandler:a.selectExternalSurvey})}}c.push('-')}for(var e in f){d=f[e];c.push({xtype:'menucheckitem',text:d['name'],group:'imageSurveys',survey:d,scope:a,checkHandler:a.selectExternalSurvey})}return c},updateImageLayersMenuItems:function(){var c=this,b=c.down('#BtnImageLayers'),a;if(b){a=c.createImageLayersMenuItems();b.setMenu(a)}}},0,0,0,0,0,0,[aladin,'Interfaces'],0);Ext.cmd.derive('aladin.Aladin',Ext.panel.Panel,{layout:'fit',libA:null,colorsDefault:['#A0F65A','#00BFFF','#FF0000','#FFFF00','#FF7F00','#7D26CD','#FF1493'],colorsAvailable:[],config:{aladinId:null,cmpAladin:null,aladin:null,aladinReady:!1,hipsDir:'/static/stripeHiPS',aladinOptions:{fov:180,target:'02 23 11.851 -09 40 21.59',cooFrame:'J2000',survey:'empty_survey',showReticle:!0,showZoomControl:!0,showFullscreenControl:!0,showLayersControl:!1,showGotoControl:!1,showShareControl:!1,showCatalog:!0,showFrame:!1,showCooGrid:!1,fullScreen:!1,reticleColor:'rgb(178, 50, 178)',reticleSize:28,log:!0,allowFullZoomout:!0},aladinWidth:300,aladinHeight:300,autoSize:!0,storeSurveys:null,storeMaps:null,surveys:[],maps:[],colorMaps:[],emptySurvey:{'id':'empty_survey','url':'','name':'','filter':'','maxOrder':11,'frame':'equatorial','options':{imgFormat:'png'}},enableLayersControl:!0,enableToolbar:!0,showFilters:!1,bandFilter:null,availableFilters:[],enableViewMenu:!0,enableExportPng:!0,enableReticle:!0,enableHealpixGrid:!0,enableColorMap:!0,enableFootprint:!0,hideFootprint:!0,enableGoto:!1,gotoSetPosition:!0,auxTools:[],storeTags:null,storeTiles:null,tilesGridVisible:!1,enableInfo:!0,infoEnabled:!0,location:'',mlocation:'',initialFov:null,enableMaps:!0,enableShift:!1,toolbarPosition:'left',externalSurveys:[{'id':'P/2MASS/color','url':'http://alasky.u-strasbg.fr/2MASS/Color','name':'2MASS colored','maxOrder':9,'frame':'equatorial','format':'jpeg'},{'id':'P/DSS2/color','url':'http://alasky.u-strasbg.fr/DSS/DSSColor','name':'DSS colored','maxOrder':9,'frame':'equatorial','format':'jpeg'},{'id':'P/DSS2/red','url':'http://alasky.u-strasbg.fr/DSS/DSS2Merged','name':'DSS2 Red (F+R)','maxOrder':9,'frame':'equatorial','format':'jpeg fits'},{'id':'P/Fermi/color','url':'http://alasky.u-strasbg.fr/Fermi/Color','name':'Fermi color','maxOrder':3,'frame':'equatorial','format':'jpeg'},{'id':'P/Finkbeiner','url':'http://alasky.u-strasbg.fr/FinkbeinerHalpha','maxOrder':3,'frame':'galactic','format':'jpeg fits','name':'Halpha'},{'id':'P/GALEXGR6/AIS/color','url':'http://alasky.u-strasbg.fr/GALEX/GR6-02-Color','name':'GALEX Allsky Imaging Survey colored','maxOrder':8,'frame':'equatorial','format':'jpeg'},{'id':'P/IRIS/color','url':'http://alasky.u-strasbg.fr/IRISColor','name':'IRIS colored','maxOrder':3,'frame':'galactic','format':'jpeg'},{'id':'P/Mellinger/color','url':'http://alasky.u-strasbg.fr/MellingerRGB','name':'Mellinger colored','maxOrder':4,'frame':'galactic','format':'jpeg'},{'id':'P/SDSS9/color','url':'http://alasky.u-strasbg.fr/SDSS/DR9/color','name':'SDSS9 colored','maxOrder':10,'frame':'equatorial','format':'jpeg'},{'id':'P/SPITZER/color','url':'http://alasky.u-strasbg.fr/SpitzerI1I2I4color','name':'IRAC color I1,I2,I4 - (GLIMPSE, SAGE, SAGE-SMC, SINGS)','maxOrder':9,'frame':'galactic','format':'jpeg'},{'id':'P/VTSS/Ha','url':'http://alasky.u-strasbg.fr/VTSS/Ha','maxOrder':3,'frame':'galactic','format':'png jpeg fits','name':'VTSS-Ha'},{'id':'P/XMM/EPIC','url':'http://saada.u-strasbg.fr/xmmallsky','name':'XMM-Newton stacked EPIC images (no phot. normalization)','maxOrder':7,'frame':'equatorial','format':'png fits'},{'id':'P/XMM/PN/color','url':'http://saada.unistra.fr/xmmpnsky','name':'XMM PN colored','maxOrder':7,'frame':'equatorial','format':'png jpeg'},{'id':'P/allWISE/color','url':'http://alasky.u-strasbg.fr/AllWISE/RGB-W4-W2-W1/','name':'AllWISE color','maxOrder':8,'frame':'equatorial','format':'jpeg'},{'id':'P/GLIMPSE360','url':'http://www.spitzer.caltech.edu/glimpse360/aladin/data','name':'GLIMPSE360','maxOrder':9,'frame':'equatorial','format':'jpeg'}]},isFirstSurvey:!0,viewModel:{data:{location:'',mlocation:'',tile:null,tag:null,release:null,release_name:''}},session:!0,initComponent:function(){var a=this,c,b,d;if(window.A){a.libA=window.A}else {console.log('window.A ainda nao esta carregada')}a.setAladinId(a.getId()+'-placeholder');c=Ext.create('Ext.Component',{id:a.getAladinId(),width:a.getAladinWidth(),height:a.getAladinHeight()});if(a.getEnableToolbar()){b=a.leftToolBar=a.makeToolbar();d=a.makeToolbarButtons();b.add(d);if(a.getToolbarPosition()==='left'){a.lbar=b}else {if(a.getToolbarPosition()==='top'){a.tbar=b}}}Ext.apply(this,{items:[c],listeners:{scope:a,afterrender:'onAfterrender'}});Ext.panel.Panel.prototype.initComponent.apply(this,arguments)},onAfterrender:function(){var a=this,d='#'+a.getAladinId(),e=a.libA,c=a.getAladinOptions(),b,f;b=e.aladin(d,c);b.view.setUnknownSurveyIfNeeded=function(){};b._setImageSurvey=b.setImageSurvey;b.setImageSurvey=function(d,c){return b._setImageSurvey(d,function(){a.onChangeImageSurvey();if(c){c()}})};a.setAladin(b);a.createImageSurveys();if(a.getEnableColorMap()){a.updateColorMapMenu()}if(a.getInfoEnabled()){a.enableDisableInfo(null,a.getInfoEnabled())}a.addCustomEvents();a.setAladinReady(!0);a.fireEvent('aladinready',a)},onChangeImageSurvey:function(){this.addCustomEvents()},aladinIsReady:function(){var a=this;return a.getAladinReady()},getRaDec:function(){var b=this,a=b.getAladin();return a.getRaDec()},getEmptySurvey:function(){return Ext.clone(this.emptySurvey)},readProperties:function(c,a,b){ProgressiveCat.readProperties(c,a,b)},onResize:function(){var a=this,b=a.getAladin();if(a.getAutoSize()){b.view.fixLayoutDimensions()}},setSurveys:function(a){this.surveys=null;this.surveys=a;if(this.getAladin()&&a.length>0){this.removeLayers();this.createImageSurveys()}},createImageSurvey:function(e){var c=this,f=c.getEmptySurvey(),d=c.getAladin(),a,b,g;a=Ext.Object.merge(f,e);b=d.createImageSurvey(String(a.id),a.name,a.url,a.cooFrame,a.maxOrder,a.options);return b},createImageSurveys:function(){var a=this,b=a.getSurveys(),d=a.getFilter(),f=a.getEmptySurvey(),e,c;if(b.length===0){b.push(f)}for(var g in b){e=b[g];a.createImageSurvey(e)}if(d){c=a.getSurveyByFilter(d)}else {c=b[0]}a.updateImageLayersMenuItems();a.setImageSurvey(c)},getSurveyByFilter:function(c){var d=this,b=d.getSurveys(),a;for(var e in b){a=b[e];if(a.filter.toLowerCase()==c.toLowerCase()){return a}}},getImageSurvey:function(){var b=this,a=b.getAladin();if(a){return a.getBaseImageLayer()}else {return null}},setImageSurvey:function(b){var a=this,c=a.getAladin(),d=a.getEmptySurvey();if(b){c.setImageSurvey(b.id);if(a.isFirstSurvey){if(b.target!==''){a.goToPosition(b.target)}if(a.getInitialFov()){a.setFov(a.getInitialFov())}else {if(b.fov){a.setFov(b.fov)}}a.isFirstSurvey=!1}a.showDesFootprint();a.addCustomEvents();a.fireEvent('changeimage',b,a)}else {c.setImageSurvey(d.id)}},setStoreSurveys:function(a){var b=this;if(a){a.on({scope:this,load:'onStoreSurveysLoad',beforeload:'onStoreSurveysBeforeLoad'});b.storeSurveys=a}},onStoreSurveysBeforeLoad:function(a){var b=this;b.setLoading({store:a})},onStoreSurveysLoad:function(d){var a=this,g=a.getAladin(),f=a.getEmptySurvey(),c=[],b=[],e;if(d.count()===0){console.log('NAO TEM SURVEY');a.setImageSurvey(f)}d.each(function(a){e={id:String(a.get('id')),url:a.get('srv_url'),name:a.get('srv_display_name'),filter:a.get('filter'),target:a.get('srv_target'),fov:a.get('srv_fov')};c.push(e);b.push(a.get('filter'))});a.setSurveys(c);a.setAvailableFilters(b)},setLocation:function(c,b){var a=this,d=a.getViewModel();a.location=c;a.mlocation=b;d.set('location',c);d.set('mlocation',b);if(a.getAladin()){a.onChangeLocation()}},onChangeLocation:function(a){var b=this;if(!a){a=b.getRaDec()}b.identifyTile(a);b.updateInfoData()},setAvailableFilters:function(a){var b=this,c=b.getBandFilter();if(a.length>0){if(b.getShowFilters()){c.setAvailableFilters(a)}}},setStoreTags:function(a){var b=this;if(a){b.storeTags=a;a.on('load','onLoadStoreTags',this)}},onLoadStoreTags:function(b){var a=this;if(a.getEnableViewMenu()){if(b.count()>0){a.createTileGridMenu()}}},setStoreTiles:function(a){var b=this;b.storeTiles=a;a.on('beforeload','onBeforeloadStoreTiles',this);a.on('load','onLoadStoreTiles',this)},onBeforeloadStoreTiles:function(){var a=this;a.setLoading(!0)},onLoadStoreTiles:function(){var a=this,b;a.setLoading(!1);if(a.getEnableViewMenu()){b=a.down('#TileGridMenu');if(b.checked){a.onCheckTileGridMenu(b,b.checked)}}a.identifyTile()},getTileByPosition:function(c){var e=this,b=e.getStoreTiles(),a=c,d;if(!c){a=e.getRaDec()}if(b&&b.count()){d=b.filterByRaDec(a[0],a[1])}return d},identifyTile:function(f){var b=this,c=b.getViewModel(),e=c.get('tileid'),a,d;a=b.getTileByPosition(f);if(a){if(a.get('id')!==e){d=b.getStoreTags().getById(a.get('tag'));c.set('release_name',a.get('release_display_name'));c.set('tile',a);c.set('tag',d);b.fireEvent('changetile',a,d,b)}}else {c.set('tile',null);c.set('tag',null);b.fireEvent('changetile',a,d,b)}},onFilter:function(b){var a=this,c;c=a.getSurveyByFilter(b);a.setImageSurvey(c);a.fireEvent('changefilter',b,a)},getFilter:function(){var a=this,b=a.getBandFilter();if(a.getShowFilters()){return b.getFilter()}},setFilter:function(b){var c=this,a=c.getBandFilter();a.setFilter(b)},changeMapSurvey:function(a){var c=this,d=c.getAladin(),b;b={id:String(a.map_id),url:a.map_url,name:a.map_name,filter:a.map_filter,maxOrder:3};mapSurvey=c.createImageSurvey(b);d.setImageSurvey(mapSurvey.id)},selectExternalSurvey:function(b){var d=this,c=d.getAladin(),a=b.survey;c.setImageSurvey(a.id)},exportAsPng:function(){var b=this,a=b.getAladin();a.exportAsPNG()},showReticle:function(d,b){var c=this,a=c.getAladin();a.showReticle(b)},showHealpixGrid:function(d,b){var c=this,a=c.getAladin();a.showHealpixGrid(b)},showDesFootprint:function(a,b){var c=this;if(!a){a=c.down('#DesFootprint');b=a.checked}c.plotDesFootprint(b)},reverseColor:function(){var b=this,a=b.getAladin();a.getBaseImageLayer().getColorMap().reverse()},changeColorMap:function(b){var c=this,a=c.getAladin();a.getBaseImageLayer().getColorMap().update(b.mapName)},plotDesFootprint:function(e){var d=this,c=d.getAladin();des=d.getDesFootprintCoordinates();if(c.view.overlays[0]!=undefined){overlays=c.view.overlays;plotDes=!1;for(var b=overlays.length-1;b>=0;b--){if(overlays[b].name=='des'){plotDes=!0;if(e){overlays[b].show()}else {overlays[b].hide()}}}if(plotDes==!1){var a=A.graphicOverlay({color:'#ee2345',lineWidth:2,name:'des'});c.addOverlay(a);a.add(A.polyline(des))}}else {var a=A.graphicOverlay({color:'#ee2345',lineWidth:2,name:'des'});c.addOverlay(a);a.add(A.polyline(des))}},onCheckTileGridMenu:function(b,a){var d=this,c=b.getMenu();c.items.each(function(c){c.setChecked(a)},d)},onCheckTileGrid:function(b,a){this.showTileGrid(b.tag,a)},showTileGrid:function(c,g){var a=this,e=a.getStoreTiles(),f=a.getStoreTags(),d=f.getById(c),b;if(g){b=e.query('tag',c);if(b.count()>0){a.plotFootprint(d,b)}}else {a.setVisibleFootprint(d.get('tag_name'),!1)}},plotFootprint:function(e,h){var c=this,f=c.getAladin(),b=c.libA,a,d,g;d=b.catalog({name:'Recent tiles',sourceSize:14,color:'#e67e22'});a=c.getFootprintByName(e.get('tag_name'));if(a){a.show()}else {a=b.graphicOverlay({color:c.getColor(),lineWidth:1,name:String(e.get('tag_name'))});f.addOverlay(a);h.each(function(c){var f=[[c.get('raul'),c.get('decul')],[c.get('rall'),c.get('decll')],[c.get('ralr'),c.get('declr')],[c.get('raur'),c.get('decur')]];a.addFootprints(b.polygon(f));if(c.get('is_new')){g=!0;d.addSources([b.marker(c.get('tli_ra'),c.get('tli_dec'),{popupTitle:'Tile Recently Added',popupDesc:'Creation date: '+c.get('date')})])}},this);if(g&&!e.get('is_new')){f.addCatalog(d)}}},parsePosition:function(a){var b,d,c;if(a){if(a.indexOf(',')!=-1){a=a.split(',');b=parseFloat(a[0].trim());d=parseFloat(a[1].trim());if(b<0){b=b+360}c=[b,d];a=c.join(', ')}else {a=c}return a}},goToPosition:function(b){var c=this,d=c.getAladin(),a;if(b){a=c.parsePosition(b);d.gotoObject(a)}},setFov:function(b){var d=this,c=d.getAladin(),a=parseFloat(b);if(a){c.setFoV(a)}},getFov:function(){var b=this,a=b.getAladin();return a.getFov()},getFootprintByName:function(d){var e=this,c=e.getAladin(),a=c.view.overlays,b=null;if(a.length>0){a.forEach(function(a){if(a.name==d){b=a}})}return b},setVisibleFootprint:function(c,b){var d=this,a;if(b=='undefined'){b=!0}a=d.getFootprintByName(c);if(a){if(b){a.show()}else {a.hide()}}},removeLayers:function(){var b=this,a=b.getAladin();a.removeLayers()},getColor:function(){var a=this,c=a.colorsDefault,b;if(a.colorsAvailable.length===0){a.colorsAvailable=Ext.clone(c)}b=a.colorsAvailable.shift();return b},onShift:function(){this.fireEvent('shift',this.getRaDec(),this)},onShowLayerBox:function(){var b=this,a=b.getViewModel().getView().getAladin();a.hideBoxes();a.showLayerBox();return !1},overlayDrawCircle:function(b,a,c){a.beginPath();a.arc(b.x,b.y,b.data['size']*2,0,2*Math.PI,!1);a.closePath();a.strokeStyle='#c38';a.lineWidth=3;a.globalAlpha=0.7,a.stroke();var d=Math.max(c['fov'][0],c['fov'][1]);return},getDesFootprintCoordinates:function(){var a=[[23,-7],[22,-7],[21,-7],[20,-7],[19,-7],[18,-7],[17,-7],[16,-7],[15,-7],[14,-7],[13,-7],[12,-7],[11,-7],[10,-7],[9,-7],[8,-7],[7,-7],[6,-7],[5,-7],[4,-7],[3,-7],[2,-7],[1,-7],[0,-7],[0,-6],[0,-5],[0,-4],[0,-3],[0,-2],[-1,-2],[-2,-2],[-3,-2],[-4,-2],[-5,-2],[-6,-2],[-7,-2],[-8,-2],[-9,-2],[-10,-2],[-11,-2],[-12,-2],[-13,-2],[-14,-2],[-15,-2],[-16,-2],[-17,-2],[-18,-2],[-19,-2],[-20,-2],[-21,-2],[-22,-2],[-23,-2],[-24,-2],[-25,-2],[-26,-2],[-27,-2],[-28,-2],[-29,-2],[-30,-2],[-31,-2],[-32,-2],[-33,-2],[-34,-2],[-35,-2],[-36,-2],[-37,-2],[-38,-2],[-39,-2],[-40,-2],[-41,-2],[-42,-2],[-43,-2],[-43,-1],[-43,0],[-43,1],[-43,2],[-42,2],[-41,2],[-40,2],[-39,2],[-38,2],[-37,2],[-36,2],[-35,2],[-34,2],[-33,2],[-32,2],[-31,2],[-30,2],[-29,2],[-28,2],[-27,2],[-26,2],[-25,2],[-24,2],[-23,2],[-22,2],[-21,2],[-20,2],[-19,2],[-18,2],[-17,2],[-16,2],[-15,2],[-14,2],[-13,2],[-12,2],[-11,2],[-10,2],[-9,2],[-8,2],[-7,2],[-6,2],[-5,2],[-4,2],[-3,2],[-2,2],[-1,2],[0,2],[0,2],[0,3],[0,4],[0,5],[1,5],[2,5],[3,5],[4,5],[5,5],[6,5],[7,5],[8,5],[9,5],[10,5],[11,5],[12,5],[13,5],[14,5],[15,5],[16,5],[17,5],[18,5],[19,5],[20,5],[21,5],[22,5],[23,5],[24,5],[25,5],[26,5],[27,5],[28,5],[29,5],[30,5],[31,5],[32,5],[33,5],[34,5],[35,5],[36,5],[37,5],[38,5],[39,5],[40,5],[41,5],[42,5],[43,5],[44,5],[45,5],[45,5],[45,4],[45,3],[45,2],[45,1],[45,0],[45,-1],[45,-2],[45,-3],[45,-4],[45,-5],[45,-6],[45,-7],[45,-8],[45,-9],[45.83584,-9.06842],[46.36744,-9.14567],[46.89697,-9.22888],[47.42429,-9.3181],[47.94928,-9.41337],[48.47183,-9.51474],[48.99181,-9.62226],[49.50912,-9.73598],[50.02364,-9.85594],[50.53529,-9.98221],[51.04396,-10.11482],[51.54955,-10.25382],[52.05199,-10.39926],[52.55118,-10.55119],[53.04706,-10.70965],[53.53954,-10.87467],[54.02856,-11.0463],[54.51405,-11.22457],[54.99596,-11.40952],[55.47423,-11.60118],[55.94881,-11.79957],[56.41965,-12.00471],[56.88672,-12.21663],[57.34998,-12.43534],[57.80939,-12.66086],[58.26493,-12.89318],[58.71657,-13.13232],[59.16429,-13.37827],[59.60807,-13.63102],[60.0479,-13.89057],[60.48377,-14.15689],[60.91568,-14.42997],[61.3436,-14.70979],[61.76755,-14.99631],[62.18753,-15.2895],[62.60354,-15.58931],[63.01557,-15.89572],[63.42365,-16.20866],[63.82778,-16.52808],[64.22797,-16.85393],[66,-18],[67,-18],[68,-18],[69,-18],[70,-18],[71,-18],[72,-18],[73,-18],[74,-18],[75,-18],[76,-18],[77,-18],[78,-18],[79,-18],[80,-18],[81,-18],[82,-18],[83,-18],[84,-18],[85,-18],[86,-18],[86.66667,-19],[87.33333,-20],[88,-21],[88.66667,-22],[89.41596,-23.1317],[89.68146,-24.3655],[89.95879,-25.59111],[90.24749,-26.80814],[90.54705,-28.01619],[90.8569,-29.21488],[91.17643,-30.40381],[91.50499,-31.58263],[91.84185,-32.75095],[92.18623,-33.90841],[92.53729,-35.05464],[92.89409,-36.18931],[93.25565,-37.31205],[93.62088,-38.42252],[93.98862,-39.5204],[94.35759,-40.60535],[94.72643,-41.67704],[95.09367,-42.73517],[95.45771,-43.77942],[95.81685,-44.80949],[96.16922,-45.82508],[96.51286,-46.8259],[96.84562,-47.81168],[97.16521,-48.78213],[97.46918,-49.73698],[97.75487,-50.67597],[98.01948,-51.59884],[98.25999,-52.50536],[98.47317,-53.39526],[98.65561,-54.26832],[98.80364,-55.1243],[98.91339,-55.96299],[98.98075,-56.78417],[99.00136,-57.58762],[98.97062,-58.37314],[98.88371,-59.14055],[98.73552,-59.88964],[98.52073,-60.62023],[98.23379,-61.33214],[98,-61.5],[97,-61.5],[96,-61.5],[95,-61.5],[94,-61.5],[93,-61.5],[92,-61.5],[91,-61.5],[90,-61.5],[89,-61.5],[88,-61.5],[87,-61.5],[86,-61.5],[85,-61.5],[84,-61.5],[83,-62],[78.66667,-63],[74.33333,-64],[69.1922,-65.62708],[68.293,-65.99135],[67.35218,-66.34555],[66.36917,-66.68914],[65.34355,-67.02152],[64.27503,-67.3421],[63.1635,-67.65026],[62.00905,-67.9454],[60.81197,-68.22686],[59.5728,-68.49402],[58.29235,-68.74623],[56.97169,-68.98287],[55.6122,-69.20331],[54.21558,-69.40695],[52.78381,-69.59321],[51.31925,-69.76152],[49.82454,-69.91137],[48.30265,-70.04227],[46.75683,-70.15381],[45.19062,-70.2456],[43.60779,-70.31734],[42.0123,-70.36875],[40.4083,-70.39968],[38.8,-70.41],[37.1917,-70.39968],[35.5877,-70.36875],[33.99221,-70.31734],[32.40938,-70.2456],[30.84317,-70.15381],[29.29735,-70.04227],[27.77546,-69.91137],[26.28075,-69.76152],[24.81619,-69.59321],[23.38442,-69.40695],[21.9878,-69.20331],[20.62831,-68.98287],[19.30765,-68.74623],[18.0272,-68.49402],[16.78803,-68.22686],[15.59095,-67.9454],[14.4365,-67.65026],[13.32497,-67.3421],[12.25645,-67.02152],[11.23083,-66.68914],[10.24782,-66.34555],[9.307,-65.99135],[8.4078,-65.62708],[7.54955,-65.2533],[4,-65],[3,-65],[2,-65],[1,-65],[0,-65],[-1,-65],[-2,-65],[-3,-65],[-4,-65],[-5,-65],[-6,-65],[-7,-65],[-8,-65],[-9,-65],[-10,-65],[-11,-65],[-12,-65],[-13,-65],[-14,-65],[-15,-65],[-16,-65],[-17,-65],[-18,-65],[-19,-65],[-20,-65],[-21,-65],[-22,-65],[-23,-65],[-24,-65],[-25,-65],[-26,-65],[-27,-65],[-28,-65],[-29,-65],[-30,-65],[-31,-65],[-32,-65],[-33,-65],[-34,-65],[-35,-65],[-36,-65],[-37,-65],[-38,-65],[-39,-65],[-40,-65],[-41,-65],[-42,-65],[-43,-65],[-44,-65],[-45,-65],[-46,-65],[-47,-65],[-48,-65],[-49,-65],[-50,-65],[-51,-65],[-52,-65],[-53,-65],[-54,-65],[-55,-65],[-56,-65],[-57,-65],[-56.8,-64],[-56.6,-63],[-56.4,-62],[-56.2,-61],[-56,-60],[-55.9,-59],[-55.8,-58],[-55.7,-57],[-55.6,-56],[-55.5,-55],[-55.4,-54],[-55.3,-53],[-55.2,-52],[-55.1,-51],[-55,-50],[-54.9,-49],[-54.8,-48],[-54.7,-47],[-54.6,-46],[-54.5,-45],[-54.4,-44],[-54.3,-43],[-54.2,-42],[-54.1,-41],[-54,-40],[-53,-40],[-52,-40],[-51,-40],[-50,-40],[-49,-40],[-48,-40],[-47,-40],[-46,-40],[-45,-40],[-44,-40],[-43,-40],[-42,-40],[-41,-40],[-40,-40],[-39,-40],[-38,-40],[-37,-40],[-36,-40],[-35,-40],[-34,-40],[-33,-40],[-32,-40],[-31,-40],[-30,-40],[-29,-40],[-28,-40],[-27,-40],[-26,-40],[-25,-40],[-24,-40],[-23,-40],[-22,-40],[-21,-40],[-20,-40],[-19,-40],[-18,-40],[-17,-40],[-16,-40],[-15,-40],[-14,-40],[-13,-40],[-12,-40],[-11,-40],[-10,-40],[-9,-40],[-8,-40],[-7,-40],[-6,-40],[-5,-40],[-4,-40],[-3,-40],[-1.47219,-38.64048],[-1.27518,-38.12814],[-1.07231,-37.61674],[-0.86376,-37.1064],[-0.6497,-36.59723],[-0.43028,-36.08933],[-0.20564,-35.58282],[0.02406,-35.07782],[0.25871,-34.57444],[0.49818,-34.0728],[0.74235,-33.57301],[0.99113,-33.0752],[1.24441,-32.5795],[1.50209,-32.08601],[1.7641,-31.59488],[2.03036,-31.10621],[2.30079,-30.62015],[2.57532,-30.13681],[2.85391,-29.65632],[3.13648,-29.17881],[3.423,-28.70441],[3.71342,-28.23325],[4.0077,-27.76546],[4.30581,-27.30116],[4.60772,-26.84048],[4.9134,-26.38355],[5.22284,-25.93051],[5.53601,-25.48147],[5.8529,-25.03656],[6.17351,-24.59591],[6.49782,-24.15964],[6.82584,-23.72788],[7.15756,-23.30074],[7.49299,-22.87835],[7.83212,-22.46081],[8.17498,-22.04826],[8.52155,-21.6408],[8.87186,-21.23855],[9.22592,-20.8416],[9.58374,-20.45008],[9.94533,-20.06407],[10.3107,-19.68369],[10.67989,-19.30903],[11.05289,-18.94018],[11.42973,-18.57723],[11.81042,-18.22027],[12.19498,-17.86938],[12.58343,-17.52465],[12.97577,-17.18614],[13.37203,-16.85393],[13.77222,-16.52808],[14.17635,-16.20866],[14.58443,-15.89572],[14.99646,-15.58931],[15.41247,-15.2895],[15.83245,-14.99631],[16.2564,-14.70979],[16.68432,-14.42997],[17.11623,-14.15689],[17.5521,-13.89057],[17.99193,-13.63102],[18.43571,-13.37827],[18.88343,-13.13232],[19.33507,-12.89318],[19.79061,-12.66086],[20.25002,-12.43534],[20.71328,-12.21663],[21.18035,-12.00471],[21.65119,-11.79957],[22.12577,-11.60118],[22.60404,-11.40952],[23.08595,-11.22457],[23,-10],[23,-9],[23,-8],[23,-7]];return a}},0,['aladin'],['component','box','container','panel','aladin'],{'component':!0,'box':!0,'container':!0,'panel':!0,'aladin':!0},['widget.aladin'],[['events',aladin.Events],['interface',aladin.Interfaces]],[aladin,'Aladin'],0);Ext.cmd.derive('aladin.maps.MapSelectionViewModel',Ext.app.ViewModel,{stores:{maps_store:{type:'maps',autoLoad:!1},aladin_images_store:{type:'aladin_images',autoLoad:!1}},data:{release:null,aladin_last_map_survey:null,aladin_last_nonmap_survey:null,map_selected:!1},formulas:{aladin_switchable:function(a){return a('aladin_last_nonmap_survey')!=null&&a('aladin_last_map_survey')!=null}}},0,0,0,0,['viewmodel.mapselection'],0,[aladin.maps,'MapSelectionViewModel'],0);Ext.cmd.derive('Ext.draw.ContainerBase',Ext.panel.Panel,{previewTitleText:'Chart Preview',previewAltText:'Chart preview',layout:'container',addElementListener:function(){var a=this,b=arguments;if(a.rendered){a.el.on.apply(a.el,b)}else {a.on('render',function(){a.el.on.apply(a.el,b)})}},removeElementListener:function(){var a=this,b=arguments;if(a.rendered){a.el.un.apply(a.el,b)}},afterRender:function(){Ext.panel.Panel.prototype.afterRender.apply(this,arguments);this.initAnimator()},getItems:function(){var a=this,b=a.items;if(!b||!b.isMixedCollection){a.initItems()}return a.items},onRender:function(){Ext.panel.Panel.prototype.onRender.apply(this,arguments);this.element=this.el;this.innerElement=this.body},setItems:function(a){this.items=a;return a},setSurfaceSize:function(b,a){this.resizeHandler({width:b,height:a});this.renderFrame()},onResize:function(b,a,d,c){var e=this;Ext.panel.Panel.prototype.onResize.call(this,b,a,d,c);e.setBodySize({width:b,height:a})},preview:function(){var a=this.getImage();new Ext.window.Window({title:this.previewTitleText,closeable:!0,renderTo:Ext.getBody(),autoShow:!0,maximizeable:!0,maximized:!0,border:!0,layout:{type:'hbox',pack:'center',align:'middle'},items:{xtype:'container',items:{xtype:'image',mode:'img',cls:'x-chart-image',alt:this.previewAltText,src:a.data,listeners:{afterrender:function(){var b=this,c=b.imgEl.dom,d=a.type==='svg'?1:window['devicePixelRatio']||1,e;if(!c.naturalWidth||!c.naturalHeight){c.onload=function(){var e=c.naturalWidth,a=c.naturalHeight;b.setWidth(Math.floor(e/d));b.setHeight(Math.floor(a/d))}}else {e=b.getSize();b.setWidth(Math.floor(e.width/d));b.setHeight(Math.floor(e.height/d))}}}}}})},privates:{getTargetEl:function(){return this.innerElement},reattachToBody:function(){var a=this;if(a.pendingDetachSize){a.onBodyResize()}a.pendingDetachSize=!1;Ext.panel.Panel.prototype.reattachToBody.call(this)}}},0,0,['component','box','container','panel'],{'component':!0,'box':!0,'container':!0,'panel':!0},0,0,[Ext.draw,'ContainerBase'],0);Ext.cmd.derive('Ext.draw.SurfaceBase',Ext.Widget,{getOwnerBody:function(){return this.ownerCt.body},destroy:function(){var a=this;if(a.hasListeners.destroy){a.fireEvent('destroy',a)}Ext.Widget.prototype.destroy.call(this)}},0,0,['widget'],{'widget':!0},0,0,[Ext.draw,'SurfaceBase'],0);Ext.cmd.derive('Ext.draw.Color',Ext.Base,{statics:{colorToHexRe:/(.*?)rgb\((\d+),\s*(\d+),\s*(\d+)\)/,rgbToHexRe:/\s*rgb\((\d+),\s*(\d+),\s*(\d+)\)/,rgbaToHexRe:/\s*rgba\((\d+),\s*(\d+),\s*(\d+),\s*([\.\d]+)\)/,hexRe:/\s*#([0-9a-fA-F][0-9a-fA-F]?)([0-9a-fA-F][0-9a-fA-F]?)([0-9a-fA-F][0-9a-fA-F]?)\s*/,NONE:'none',RGBA_NONE:'rgba(0, 0, 0, 0)'},isColor:!0,lightnessFactor:0.2,constructor:function(d,b,c,a){this.setRGB(d,b,c,a)},setRGB:function(e,c,d,b){var a=this;a.r=Math.min(255,Math.max(0,e));a.g=Math.min(255,Math.max(0,c));a.b=Math.min(255,Math.max(0,d));if(b===undefined){a.a=1}else {a.a=Math.min(1,Math.max(0,b))}},getGrayscale:function(){return this.r*0.3+this.g*0.59+this.b*0.11},getHSL:function(){var h=this,f=h.r/255,e=h.g/255,g=h.b/255,b=Math.max(f,e,g),d=Math.min(f,e,g),c=b-d,a,j=0,i=0.5*(b+d);if(d!==b){j=i<=0.5?c/(b+d):c/(2-b-d);if(f===b){a=60*(e-g)/c}else {if(e===b){a=120+60*(g-f)/c}else {a=240+60*(f-e)/c}}if(a<0){a+=360}if(a>=360){a-=360}}return [a,j,i]},getHSV:function(){var g=this,d=g.r/255,c=g.g/255,f=g.b/255,b=Math.max(d,c,f),i=Math.min(d,c,f),e=b-i,a,j=0,h=b;if(i!=b){j=h?e/h:0;if(d===b){a=60*(c-f)/e}else {if(c===b){a=60*(f-d)/e+120}else {a=60*(d-c)/e+240}}if(a<0){a+=360}if(a>=360){a-=360}}return [a,j,h]},setHSL:function(f,g,c){var d=this,h=Math.abs,b,e,a;f=(f%360+360)%360;g=g>1?1:g<0?0:g;c=c>1?1:c<0?0:c;if(g===0||f===null){c*=255;d.setRGB(c,c,c)}else {f/=60;b=g*(1-h(2*c-1));e=b*(1-h(f%2-1));a=c-b/2;a*=255;b*=255;e*=255;switch(Math.floor(f)){case 0:d.setRGB(b+a,e+a,a);break;case 1:d.setRGB(e+a,b+a,a);break;case 2:d.setRGB(a,b+a,e+a);break;case 3:d.setRGB(a,e+a,b+a);break;case 4:d.setRGB(e+a,a,b+a);break;case 5:d.setRGB(b+a,a,e+a);break;}}return d},setHSV:function(f,g,c){var d=this,b,e,a;f=(f%360+360)%360;g=g>1?1:g<0?0:g;c=c>1?1:c<0?0:c;if(g===0||f===null){c*=255;d.setRGB(c,c,c)}else {f/=60;b=c*g;e=b*(1-Math.abs(f%2-1));a=c-b;a*=255;b*=255;e*=255;switch(Math.floor(f)){case 0:d.setRGB(b+a,e+a,a);break;case 1:d.setRGB(e+a,b+a,a);break;case 2:d.setRGB(a,b+a,e+a);break;case 3:d.setRGB(a,e+a,b+a);break;case 4:d.setRGB(e+a,a,b+a);break;case 5:d.setRGB(b+a,a,e+a);break;}}return d},createLighter:function(b){if(!b&&b!==0){b=this.lightnessFactor}var a=this.getHSL();a[2]=Ext.Number.constrain(a[2]+b,0,1);return Ext.draw.Color.fromHSL(a[0],a[1],a[2])},createDarker:function(a){if(!a&&a!==0){a=this.lightnessFactor}return this.createLighter(-a)},toString:function(){var a=this,b=Math.round;if(a.a===1){var e=b(a.r).toString(16),d=b(a.g).toString(16),c=b(a.b).toString(16);e=e.length===1?'0'+e:e;d=d.length===1?'0'+d:d;c=c.length===1?'0'+c:c;return ['#',e,d,c].join('')}else {return 'rgba('+[b(a.r),b(a.g),b(a.b),a.a===0?0:a.a.toFixed(15)].join(', ')+')'}},toHex:function(a){if(Ext.isArray(a)){a=a[0]}if(!Ext.isString(a)){return ''}if(a.substr(0,1)==='#'){return a}var b=Ext.draw.Color.colorToHexRe.exec(a);if(Ext.isArray(b)){var e=parseInt(b[2],10),c=parseInt(b[3],10),d=parseInt(b[4],10),f=d|c<<8|e<<16;return b[1]+'#'+('000000'+f.toString(16)).slice(-6)}else {return ''}},setFromString:function(b){var a,c,e,d,g=1,f=parseInt;if(b===Ext.draw.Color.NONE){this.r=this.g=this.b=this.a=0;return this}if((b.length===4||b.length===7)&&b.substr(0,1)==='#'){a=b.match(Ext.draw.Color.hexRe);if(a){c=f(a[1],16)>>0;e=f(a[2],16)>>0;d=f(a[3],16)>>0;if(b.length===4){c+=c*16;e+=e*16;d+=d*16}}}else {if(a=b.match(Ext.draw.Color.rgbToHexRe)){c=+a[1];e=+a[2];d=+a[3]}else {if(a=b.match(Ext.draw.Color.rgbaToHexRe)){c=+a[1];e=+a[2];d=+a[3];g=+a[4]}else {if(Ext.draw.Color.ColorList.hasOwnProperty(b.toLowerCase())){return this.setFromString(Ext.draw.Color.ColorList[b.toLowerCase()])}}}}if(typeof c==='undefined'){return this}this.r=c;this.g=e;this.b=d;this.a=g;return this}},3,0,0,0,0,0,[Ext.draw,'Color'],function(){var a=new this();this.addStatics({fly:function(b,e,d,c){switch(arguments.length){case 1:a.setFromString(b);break;case 3:case 4:a.setRGB(b,e,d,c);break;default:return null;}return a},ColorList:{aliceblue:'#f0f8ff',antiquewhite:'#faebd7',aqua:'#00ffff',aquamarine:'#7fffd4',azure:'#f0ffff',beige:'#f5f5dc',bisque:'#ffe4c4',black:'#000000',blanchedalmond:'#ffebcd',blue:'#0000ff',blueviolet:'#8a2be2',brown:'#a52a2a',burlywood:'#deb887',cadetblue:'#5f9ea0',chartreuse:'#7fff00',chocolate:'#d2691e',coral:'#ff7f50',cornflowerblue:'#6495ed',cornsilk:'#fff8dc',crimson:'#dc143c',cyan:'#00ffff',darkblue:'#00008b',darkcyan:'#008b8b',darkgoldenrod:'#b8860b',darkgray:'#a9a9a9',darkgreen:'#006400',darkkhaki:'#bdb76b',darkmagenta:'#8b008b',darkolivegreen:'#556b2f',darkorange:'#ff8c00',darkorchid:'#9932cc',darkred:'#8b0000',darksalmon:'#e9967a',darkseagreen:'#8fbc8f',darkslateblue:'#483d8b',darkslategray:'#2f4f4f',darkturquoise:'#00ced1',darkviolet:'#9400d3',deeppink:'#ff1493',deepskyblue:'#00bfff',dimgray:'#696969',dodgerblue:'#1e90ff',firebrick:'#b22222',floralwhite:'#fffaf0',forestgreen:'#228b22',fuchsia:'#ff00ff',gainsboro:'#dcdcdc',ghostwhite:'#f8f8ff',gold:'#ffd700',goldenrod:'#daa520',gray:'#808080',green:'#008000',greenyellow:'#adff2f',honeydew:'#f0fff0',hotpink:'#ff69b4',indianred:'#cd5c5c',indigo:'#4b0082',ivory:'#fffff0',khaki:'#f0e68c',lavender:'#e6e6fa',lavenderblush:'#fff0f5',lawngreen:'#7cfc00',lemonchiffon:'#fffacd',lightblue:'#add8e6',lightcoral:'#f08080',lightcyan:'#e0ffff',lightgoldenrodyellow:'#fafad2',lightgray:'#d3d3d3',lightgrey:'#d3d3d3',lightgreen:'#90ee90',lightpink:'#ffb6c1',lightsalmon:'#ffa07a',lightseagreen:'#20b2aa',lightskyblue:'#87cefa',lightslategray:'#778899',lightsteelblue:'#b0c4de',lightyellow:'#ffffe0',lime:'#00ff00',limegreen:'#32cd32',linen:'#faf0e6',magenta:'#ff00ff',maroon:'#800000',mediumaquamarine:'#66cdaa',mediumblue:'#0000cd',mediumorchid:'#ba55d3',mediumpurple:'#9370d8',mediumseagreen:'#3cb371',mediumslateblue:'#7b68ee',mediumspringgreen:'#00fa9a',mediumturquoise:'#48d1cc',mediumvioletred:'#c71585',midnightblue:'#191970',mintcream:'#f5fffa',mistyrose:'#ffe4e1',moccasin:'#ffe4b5',navajowhite:'#ffdead',navy:'#000080',oldlace:'#fdf5e6',olive:'#808000',olivedrab:'#6b8e23',orange:'#ffa500',orangered:'#ff4500',orchid:'#da70d6',palegoldenrod:'#eee8aa',palegreen:'#98fb98',paleturquoise:'#afeeee',palevioletred:'#d87093',papayawhip:'#ffefd5',peachpuff:'#ffdab9',peru:'#cd853f',pink:'#ffc0cb',plum:'#dda0dd',powderblue:'#b0e0e6',purple:'#800080',red:'#ff0000',rosybrown:'#bc8f8f',royalblue:'#4169e1',saddlebrown:'#8b4513',salmon:'#fa8072',sandybrown:'#f4a460',seagreen:'#2e8b57',seashell:'#fff5ee',sienna:'#a0522d',silver:'#c0c0c0',skyblue:'#87ceeb',slateblue:'#6a5acd',slategray:'#708090',snow:'#fffafa',springgreen:'#00ff7f',steelblue:'#4682b4',tan:'#d2b48c',teal:'#008080',thistle:'#d8bfd8',tomato:'#ff6347',turquoise:'#40e0d0',violet:'#ee82ee',wheat:'#f5deb3',white:'#ffffff',whitesmoke:'#f5f5f5',yellow:'#ffff00',yellowgreen:'#9acd32'},fromHSL:function(a,c,b){return (new this(0,0,0,0)).setHSL(a,c,b)},fromHSV:function(a,b,c){return (new this(0,0,0,0)).setHSL(a,b,c)},fromString:function(a){return (new this(0,0,0,0)).setFromString(a)},create:function(a){if(a instanceof this){return a}else {if(Ext.isArray(a)){return new Ext.draw.Color(a[0],a[1],a[2],a[3])}else {if(Ext.isString(a)){return Ext.draw.Color.fromString(a)}else {if(arguments.length>2){return new Ext.draw.Color(arguments[0],arguments[1],arguments[2],arguments[3])}else {return new Ext.draw.Color(0,0,0,0)}}}}}})});Ext.cmd.derive('Ext.draw.sprite.AnimationParser',Ext.Base,function(){function compute(a,c,b){return a+(c-a)*b}return {singleton:!0,attributeRe:/^url\(#([a-zA-Z\-]+)\)$/,color:{parseInitial:function(a,b){if(Ext.isString(a)){a=Ext.draw.Color.create(a)}if(Ext.isString(b)){b=Ext.draw.Color.create(b)}if(a instanceof Ext.draw.Color&&b instanceof Ext.draw.Color){return [[a.r,a.g,a.b,a.a],[b.r,b.g,b.b,b.a]]}else {return [a||b,b||a]}},compute:function(a,b,c){if(!Ext.isArray(a)||!Ext.isArray(b)){return b||a}else {return [compute(a[0],b[0],c),compute(a[1],b[1],c),compute(a[2],b[2],c),compute(a[3],b[3],c)]}},serve:function(a){var b=Ext.draw.Color.fly(a[0],a[1],a[2],a[3]);return b.toString()}},number:{parse:function(a){return a===null?null:+a},compute:function(a,b,c){if(!Ext.isNumber(a)||!Ext.isNumber(b)){return b||a}else {return compute(a,b,c)}}},angle:{parseInitial:function(b,a){if(a-b>Math.PI){a-=Math.PI*2}else {if(a-b<-Math.PI){a+=Math.PI*2}}return [b,a]},compute:function(a,b,c){if(!Ext.isNumber(a)||!Ext.isNumber(b)){return b||a}else {return compute(a,b,c)}}},path:{parseInitial:function(m,l){var e=m.toStripes(),c=l.toStripes(),a,i,f=e.length,g=c.length,j,h,k,d=c[g-1],b=[d[d.length-2],d[d.length-1]];for(a=f;a=1){return b.path}var c=0,k=e.length,a=0,g,d,h,i=b.temp.params,j=0;for(;cMath.min(a.x+a.width,b.x+b.width)||Math.max(a.y,b.y)-c>Math.min(a.y+a.height,b.y+b.height)},isPointInBBox:function(b,c,a){return !!a&&b>=a.x&&b<=a.x+a.width&&c>=a.y&&c<=a.y+a.height},spline:function(c){var a,e,i=c.length,g,j,k,d,h=0,b=new Float32Array(c.length),f=new Float32Array(c.length*3-2);b[0]=0;b[i-1]=0;for(a=1;a0;a--){h=3.732050807568877+48.248711305964385/(-13.928203230275537+Math.pow(0.07179676972449123,a));b[a]-=b[a+1]*h}d=c[0];g=d-b[0];for(a=0,e=0;a=c&&a>=b||a<=c&&a<=b){d=e=q}else {d=t((f-s)/n(a-c));if(cq){i-=j}d+=i;e+=i;k=f-o*v(d);g=a+o*u(d);l=f+p*v(e);h=a+p*u(e);if(a>c&&gc){k+=n(c-g)*(k-f)/(g-a);g=c}if(a>b&&hb){l-=n(b-h)*(l-f)/(h-a);h=b}return {x1:k,y1:g,x2:l,y2:h}},smooth:function(i,j,p){var o=i.length,m,n,c,d,k,l,e,f,g=[],h=[],a,b;for(a=0;a=Math.PI){a-=Math.PI*2}}return a}},data:function(a){if(Ext.isArray(a)){return a.slice()}else {if(a instanceof Float32Array){return new Float32Array(a)}}},bool:function(a){return !!a},color:function(a){if(a instanceof Ext.draw.Color){return a.toString()}else {if(a instanceof Ext.draw.gradient.Gradient){return a}else {if(!a){return Ext.draw.Color.NONE}else {if(Ext.isString(a)){if(a.substr(0,3)==='url'){a=Ext.draw.gradient.GradientDefinition.get(a);if(Ext.isString(a)){return a}}else {return Ext.draw.Color.fly(a).toString()}}}}}if(a.type==='linear'){return Ext.create('Ext.draw.gradient.Linear',a)}else {if(a.type==='radial'){return Ext.create('Ext.draw.gradient.Radial',a)}else {if(a.type==='pattern'){return Ext.create('Ext.draw.gradient.Pattern',a)}else {return Ext.draw.Color.NONE}}}},limited:function(a,b){return function(c){c=+c;return Ext.isNumber(c)?Math.min(Math.max(c,a),b):undefined}},limited01:function(a){a=+a;return Ext.isNumber(a)?Math.min(Math.max(a,0),1):undefined},enums:function(){var b={},c=Array.prototype.slice.call(arguments,0),a,d;for(a=0,d=c.length;a=(7-4*c)/11){return a*a-b((11-6*c-11*d)/4,2)}}},elastic:function(a,c){return b(2,10*--a)*j(20*a*h*(c||1)/3)}},a={},e,g,c;function createPoly(a){return function(c){return b(c,a)}}function addEasing(c,b){a[c+'In']=function(a){return b(a)};a[c+'Out']=function(a){return 1-b(1-a)};a[c+'InOut']=function(a){return a<=0.5?b(2*a)/2:(2-b(2*(1-a)))/2}}for(c=0,g=f.length;c-1},empty:function(){return this.animations.length===0},step:function(e){var f=this,c=f.animations,a,b=0,d=c.length;for(;b0},applyEasing:function(a){if(typeof a==='string'){a=Ext.draw.TimingFunctions.easingMap[a]}return a},applyCustomEasings:function(g,b){b=b||{};var e,f,d,a,c,h;for(f in g){e=!0;a=g[f];d=f.split(',');if(typeof a==='string'){a=Ext.draw.TimingFunctions.easingMap[a]}for(c=0,h=d.length;c=1){d[b]=h[b];delete h[b];if(e[b].remove){d.removeFromInstance=d.removeFromInstance||{};d.removeFromInstance[b]=!0}delete e[b]}else {d[b]=a.serve(a.compute(a.source,a.target,a.easing(f),c[b]));i=!0}}c.lastUpdate=g;this.setAnimating(c,i);return d},pushDown:function(b,a){a=Ext.draw.modifier.Modifier.prototype.pushDown.call(this,b.animationOriginal,a);return this.setAttrs(b,a)},popUp:function(a,b){a=a.prototype;b=this.setAttrs(a,b);if(this._next){return this._next.popUp(a,b)}else {return Ext.apply(a,b)}},step:function(g){var a=this,e=a.animatingPool.slice(),f=e.length,d=0,c,b;for(;d=a.x&&c<=a.x+a.width&&d>=a.y&&d<=a.y+a.height;if(e){return {sprite:this}}}return null},isVisible:function(){var a=this.attr,b=this.getParent(),e=b&&(b.isSurface||b.isVisible()),h=e&&!a.hidden&&a.globalAlpha,c=Ext.draw.Color.NONE,d=Ext.draw.Color.RGBA_NONE,g=a.fillOpacity&&a.fillStyle!==c&&a.fillStyle!==d,f=a.strokeOpacity&&a.strokeStyle!==c&&a.strokeStyle!==d,i=h&&(g||f);return !!i},repaint:function(){var a=this.getSurface();if(a){a.renderFrame()}},remove:function(){var a=this.getSurface();if(a&&a.isSurface){return a.remove(this)}return null},destroy:function(){var a=this,b=a.topModifier,c;while(b){c=b;b=b.getPrevious();c.destroy()}delete a.attr;a.remove();if(a.fireEvent('beforedestroy',a)!==!1){a.fireEvent('destroy',a)}a.callParent()}},1,0,0,0,['sprite.sprite'],[['observable',Ext.mixin.Observable]],[Ext.draw.sprite,'Sprite'],function(){this.def=new Ext.draw.sprite.AttributeDefinition(this.def);this.def.spriteClass=this});Ext.cmd.derive('Ext.draw.Path',Ext.Base,{statics:{pathRe:/,?([achlmqrstvxz]),?/gi,pathRe2:/-/gi,pathSplitRe:/\s|,/g},svgString:'',constructor:function(b){var a=this;a.commands=[];a.params=[];a.cursor=null;a.startX=0;a.startY=0;if(b){a.fromSvgString(b)}},clear:function(){var a=this;a.params.length=0;a.commands.length=0;a.cursor=null;a.startX=0;a.startY=0;a.dirt()},dirt:function(){this.svgString=''},moveTo:function(b,c){var a=this;if(!a.cursor){a.cursor=[b,c]}a.params.push(b,c);a.commands.push('M');a.startX=b;a.startY=c;a.cursor[0]=b;a.cursor[1]=c;a.dirt()},lineTo:function(b,c){var a=this;if(!a.cursor){a.cursor=[b,c];a.params.push(b,c);a.commands.push('M')}else {a.params.push(b,c);a.commands.push('L')}a.cursor[0]=b;a.cursor[1]=c;a.dirt()},bezierCurveTo:function(b,c,f,g,d,e){var a=this;if(!a.cursor){a.moveTo(b,c)}a.params.push(b,c,f,g,d,e);a.commands.push('C');a.cursor[0]=d;a.cursor[1]=e;a.dirt()},quadraticCurveTo:function(b,c,d,e){var a=this;if(!a.cursor){a.moveTo(b,c)}a.bezierCurveTo((2*b+a.cursor[0])/3,(2*c+a.cursor[1])/3,(2*b+d)/3,(2*c+e)/3,d,e)},closePath:function(){var a=this;if(a.cursor){a.cursor=null;a.commands.push('Z');a.dirt()}},arcTo:function(l,m,e,f,d,b,n){var i=this;if(b===undefined){b=d}if(n===undefined){n=0}if(!i.cursor){i.moveTo(l,m);return}if(d===0||b===0){i.lineTo(l,m);return}e-=l;f-=m;var g=i.cursor[0]-l,h=i.cursor[1]-m,q=e*h-f*g,j,k,y,A,z,t,w=Math.sqrt(g*g+h*h),x=Math.sqrt(e*e+f*f),u,c,a;if(q===0){i.lineTo(l,m);return}if(b!==d){j=Math.cos(n);k=Math.sin(n);y=j/d;A=k/b;z=-k/d;t=j/b;var v=y*g+A*h;h=z*g+t*h;g=v;v=y*e+A*f;f=z*e+t*f;e=v}else {g/=d;h/=b;e/=d;f/=b}c=g*x+e*w;a=h*x+f*w;u=1/(Math.sin(Math.asin(Math.abs(q)/(w*x))*0.5)*Math.sqrt(c*c+a*a));c*=u;a*=u;var B=(c*g+a*h)/(g*g+h*h),C=(c*e+a*f)/(e*e+f*f);var r=g*B-c,s=h*B-a,D=e*C-c,E=f*C-a,o=Math.atan2(s,r),p=Math.atan2(E,D);if(q>0){if(p=Math.PI*2){b.ellipse(j,k,h,i,g,d,d+Math.PI,l);b.ellipse(j,k,h,i,g,d+Math.PI,e,l);return}if(!l){if(e=y){s.push(d+b*p+f,e+c*p+g,d*p+b+f,e*p+c+g,b+f,c+g);u+=6;a-=y;o=d;d=b;b=-o;o=e;e=c;c=-o}if(a){i=(0.3294738052815987+0.012120855841304373*a)*a;h=Math.cos(a);j=Math.sin(a);v=h+i*j;w=j-i*h;s.push(d+b*i+f,e+c*i+g,d*v+b*w+f,e*v+c*w+g,d*h+b*j+f,e*h+c*j+g);u+=6}return u},arcSvg:function(b,c,i,y,m,v,x){if(b<0){b=-b}if(c<0){c=-c}var n=this,u=n.cursor[0],w=n.cursor[1],q=(u-v)/2,r=(w-x)/2,g=Math.cos(i),h=Math.sin(i),o=q*g+r*h,p=-q*h+r*g,k=o/b,l=p/c,a=k*k+l*l,s=(u+v)*0.5,t=(w+x)*0.5,e=0,f=0;if(a>=1){a=Math.sqrt(a);b*=a;c*=a}else {a=Math.sqrt(1/a-1);if(y===m){a=-a}e=a*b*l;f=-a*c*k;s+=g*e-h*f;t+=h*e+g*f}var j=Math.atan2((p-f)/c,(o-e)/b),d=Math.atan2((-p-f)/c,(-o-e)/b)-j;if(m){if(d<=0){d+=Math.PI*2}}else {if(d>=0){d-=Math.PI*2}}n.ellipse(s,t,b,c,i,j,j+d,1-m)},fromSvgString:function(k){if(!k){return}var e=this,b,g={a:7,c:6,h:1,l:2,m:2,q:4,s:4,t:2,v:1,z:0,A:7,C:6,H:1,L:2,M:2,Q:4,S:4,T:2,V:1,Z:0},h='',i,j,c=0,d=0,l=!1,a,f,m;if(Ext.isString(k)){b=k.replace(Ext.draw.Path.pathRe,' $1 ').replace(Ext.draw.Path.pathRe2,' -').split(Ext.draw.Path.pathSplitRe)}else {if(Ext.isArray(k)){b=k.join(',').split(Ext.draw.Path.pathSplitRe)}}for(a=0,f=0;a=0){f=Math.sqrt(f);a=(f-i)/2/l;if(00){a-=f/l;if(0a.x){c=a.x}if(ha.y){d=a.y}if(f=e.length||!d.isVisible()){return c}a.attr=e[b];c=a.isVisible(point,options);a.attr=f;return c},render:function(h,c,g,d){var e=this,b=e.getTemplate(),k=e.attr.matrix,j=b.attr,f=e.instances,a,i=e.position;k.toContext(c);b.preRender(h,c,g,d);b.useAttributes(c,d);for(a=0;ac){a=e.substr(c,d-c)}else {continue}}f=a.indexOf('/');if(f>0){a=a.substr(0,f)}else {if(f===0){continue}}if(a!=='normal'&&a!=='inherit'){g=h[a];if(g){b[g]=a}else {if(a.match(Ext.dom.Element.unitRe)){b.fontSize=a}else {b.fontFamily=e.substr(c);break}}}c=d+1}if(!b.fontStyle){b.fontStyle=''}if(!b.fontVariant){b.fontVariant=''}if(!b.fontWeight){b.fontWeight=''}this.setAttributes(b,!0)},fontProperties:{fontStyle:!0,fontVariant:!0,fontWeight:!0,fontSize:!0,fontFamily:!0},setAttributes:function(a,d,e){var b,c;if(a&&a.font){c={};for(b in a){if(!(b in this.fontProperties)){c[b]=a[b]}}a=c}Ext.draw.sprite.Sprite.prototype.setAttributes.call(this,a,d,e)},getBBox:function(d){var b=this,a=b.attr.bbox.plain,c=b.getSurface();if(a.dirty){b.updatePlainBBox(a);a.dirty=!1}if(c.getInherited().rtl&&c.getFlipRtlText()){b.updatePlainBBox(a,!0)}return Ext.draw.sprite.Sprite.prototype.getBBox.call(this,d)},rtlAlignments:{start:'end',center:'center',end:'start'},updatePlainBBox:function(j,s){var e=this,b=e.attr,g=b.x,l=b.y,k=[],u=b.font,v=b.text,t=b.textBaseline,m=b.textAlign,o=s&&e.oldSize?e.oldSize:e.oldSize=Ext.draw.TextMeasurer.measureText(v,u),n=e.getSurface(),i=n.getInherited().rtl,r=i&&n.getFlipRtlText(),q=n.getRect(),f=o.sizes,h=o.height,c=o.width,p=f?f.length:0,d,a=0;switch(t){case 'hanging':case 'top':break;case 'ideographic':case 'bottom':l-=h;break;case 'alphabetic':l-=h*0.8;break;case 'middle':l-=h*0.5;break;}if(r){g=q[2]-q[0]-g;m=e.rtlAlignments[m]}switch(m){case 'start':if(i){for(;a0&&d>0){c=Math.sqrt(a*a+d*d)*Math.abs(Math.cos(g-Math.atan(a/d)))/2;f=m.createLinearGradient(i+k*c,j+l*c,i-k*c,j-l*c);for(b=0;b=0;a--){b[a].destroy()}}else {for(;a>=0;a--){c=b[a];c.setParent(null);c.setSurface(null)}}b.length=0;this.map={};this.dirtyZIndex=!0},applyItems:function(a){if(this.getItems()){this.removeAll(!0)}return Ext.Array.from(this.add(a))},createItem:function(a){return Ext.create(a.xclass||'sprite.'+a.type,a)},getBBox:function(b,j){var b=Ext.Array.from(b),c=Infinity,g=-Infinity,d=Infinity,f=-Infinity,h,a,e,i;for(e=0,i=b.length;ea.x){c=a.x}if(ga.y){d=a.y}if(f0){a.isPendingRenderFrame=!0;return}var g=a.getRect(),d=a.getBackground(),e=a.getItems(),c,b,f;if(!g){return}a.orderByZIndex();if(a.getDirty()){a.clear();a.clearTransform();if(d){a.renderSprite(d)}for(b=0,f=e.length;bthis.position){this.removeElement(c[c.length-1])}for(b=0;bthis.position){Ext.fly(a[a.length-1]).destroy()}return 'url(#'+this.element.getId()+')'},destroy:function(){var b=this.statics().map,a=this.element;if(a&&a.dom){delete b[a.dom.id];a.destroy()}this.callParent()}},3,0,0,0,0,0,[Ext.draw.engine.SvgContext,'Gradient'],0);Ext.cmd.derive('Ext.draw.engine.Svg',Ext.draw.Surface,{statics:{BBoxTextCache:{}},config:{highPrecision:!1},getElementConfig:function(){return {reference:'element',style:{position:'absolute'},children:[{reference:'innerElement',style:{width:'100%',height:'100%',position:'relative'},children:[{tag:'svg',reference:'svgElement',namespace:'http://www.w3.org/2000/svg',width:'100%',height:'100%',version:1.1}]}]}},constructor:function(b){var a=this;Ext.draw.Surface.prototype.constructor.call(this,b);a.mainGroup=a.createSvgNode('g');a.defElement=a.createSvgNode('defs');a.svgElement.appendChild(a.mainGroup);a.svgElement.appendChild(a.defElement);a.ctx=new Ext.draw.engine.SvgContext(a)},createSvgNode:function(b){var a=document.createElementNS('http://www.w3.org/2000/svg',b);return Ext.get(a)},getSvgElement:function(c,d,b){var a;if(c.dom.childNodes.length>b){a=c.dom.childNodes[b];if(a.tagName===d){return Ext.get(a)}else {Ext.destroy(a)}}a=Ext.get(this.createSvgNode(d));if(b===0){c.insertFirst(a)}else {a.insertAfter(Ext.fly(c.dom.childNodes[b-1]))}a.cache={};return a},setElementAttributes:function(d,c){var f=d.dom,e=d.cache,a,b;for(a in c){b=c[a];if(e[a]!==b){e[a]=b;f.setAttribute(a,b)}}},getNextDef:function(a){return this.getSvgElement(this.defElement,a,this.defPosition++)},clearTransform:function(){var a=this;a.mainGroup.set({transform:a.matrix.toSvg()})},clear:function(){this.ctx.clear();this.defPosition=0},renderSprite:function(a){var d=this,c=d.getRect(),b=d.ctx;if(a.attr.hidden||a.attr.globalAlpha===0){b.save();b.restore();return}a.element=b.save();a.preRender(this);a.useAttributes(b,c);if(!1===a.render(this,b,[0,0,c[2],c[3]])){return !1}a.setDirty(!1);b.restore()},flatten:function(f,e){var a='',g=Ext.getClassName(this),b,d,c;a+='';for(c=0;c';a+=this.serializeNode(b.svgElement.dom);a+=''}a+='';return {data:'data:image/svg+xml;utf8,'+encodeURIComponent(a),type:'svg'}},serializeNode:function(a){var c='',b,d,e,f;if(a.nodeType===document.TEXT_NODE){return a.nodeValue}c+='<'+a.nodeName;if(a.attributes.length){for(b=0,d=a.attributes.length;b';return c},destroy:function(){var a=this;a.ctx.destroy();a.mainGroup.destroy();delete a.mainGroup;delete a.ctx;Ext.draw.Surface.prototype.destroy.call(this)},remove:function(a,b){if(a&&a.element){if(this.ctx){this.ctx.removeElement(a.element)}else {a.element.destroy()}a.element=null}Ext.draw.Surface.prototype.remove.apply(this,arguments)}},1,0,['widget','surface'],{'widget':!0,'surface':!0},0,0,[Ext.draw.engine,'Svg'],0);Ext.draw||(Ext.draw={});Ext.draw.engine||(Ext.draw.engine={});Ext.draw.engine.excanvas=!0;if(!document.createElement('canvas').getContext){(function(){var f=Math;var b=f.round;var n=f.sin;var m=f.cos;var t=f.abs;var s=f.sqrt;var c=10;var e=c/2;var u=+navigator.userAgent.match(/MSIE ([\d.]+)?/)[1];function getContext(){return this.context_||(this.context_=new CanvasRenderingContext2D_(this))}var p=Array.prototype.slice;function bind(c,a,d){var b=p.call(arguments,2);return function(){return c.apply(a,b.concat(p.call(arguments)))}}function encodeHtmlAttribute(a){return String(a).replace(/&/g,'&').replace(/"/g,'"')}function addNamespace(b,a,c){Ext.onReady(function(){if(!b.namespaces[a]){b.namespaces.add(a,c,'#default#VML')}})}function addNamespacesAndStylesheet(a){addNamespace(a,'g_vml_','urn:schemas-microsoft-com:vml');addNamespace(a,'g_o_','urn:schemas-microsoft-com:office:office');if(!a.styleSheets['ex_canvas_']){var b=a.createStyleSheet();b.owningElement.id='ex_canvas_';b.cssText='canvas{display:inline-block;overflow:hidden;text-align:left;width:300px;height:150px}'}}addNamespacesAndStylesheet(document);var o={init:function(b){var a=b||document;a.createElement('canvas');a.attachEvent('onreadystatechange',bind(this.init_,this,a))},init_:function(c){var b=c.getElementsByTagName('canvas');for(var a=0;a1){a--}if(6*a<1){return b+(c-b)*6*a}else {if(2*a<1){return c}else {if(3*a<2){return b+(c-b)*(2/3-a)*6}else {return b}}}}var k={};function processStyle(a){if(a in k){return k[a]}var c,e=1;a=String(a);if(a.charAt(0)=='#'){c=a}else {if(/^rgb/.test(a)){var b=getRgbHslContent(a);var c='#',f;for(var d=0;d<3;d++){if(b[d].indexOf('%')!=-1){f=Math.floor(percent(b[d])*255)}else {f=+b[d]}c+=h[clamp(f,0,255)]}e=+b[3]}else {if(/^hsl/.test(a)){var b=getRgbHslContent(a);c=hslToRgb(b);e=b[3]}else {c=r[a]||a}}}return k[a]={color:c,alpha:e}}var g={style:'normal',variant:'normal',weight:'normal',size:10,family:'sans-serif'};var l={};function processFontStyle(b){if(l[b]){return l[b]}var c=document.createElement('div');var a=c.style;try{a.font=b}catch(v){}return l[b]={style:a.fontStyle||g.style,variant:a.fontVariant||g.variant,weight:a.fontWeight||g.weight,size:a.fontSize||g.size,family:a.fontFamily||g.family}}function getComputedStyle(b,f){var a={};for(var e in b){a[e]=b[e]}var d=parseFloat(f.currentStyle.fontSize),c=parseFloat(b.size);if(typeof b.size=='number'){a.size=b.size}else {if(b.size.indexOf('px')!=-1){a.size=c}else {if(b.size.indexOf('em')!=-1){a.size=d*c}else {if(b.size.indexOf('%')!=-1){a.size=d/100*c}else {if(b.size.indexOf('pt')!=-1){a.size=c/0.75}else {a.size=d}}}}}a.size*=0.981;return a}function buildStyle(a){return a.style+' '+a.variant+' '+a.weight+' '+a.size+'px '+a.family}var q={'butt':'flat','round':'round'};function processLineCap(a){return q[a]||'square'}function CanvasRenderingContext2D_(a){this.m_=createMatrixIdentity();this.mStack_=[];this.aStack_=[];this.currentPath_=[];this.strokeStyle='#000';this.fillStyle='#000';this.lineWidth=1;this.lineJoin='miter';this.lineDash=[];this.lineCap='butt';this.miterLimit=c*1;this.globalAlpha=1;this.font='10px sans-serif';this.textAlign='left';this.textBaseline='alphabetic';this.canvas=a;var e='width:'+a.clientWidth+'px;height:'+a.clientHeight+'px;overflow:hidden;position:absolute';var b=a.ownerDocument.createElement('div');b.style.cssText=e;a.appendChild(b);var d=b.cloneNode(!1);d.style.backgroundColor='red';d.style.filter='alpha(opacity=0)';a.appendChild(d);this.element_=b;this.arcScaleX_=1;this.arcScaleY_=1;this.lineScale_=1}var a=CanvasRenderingContext2D_.prototype;a.clearRect=function(){if(this.textMeasureEl_){this.textMeasureEl_.removeNode(!0);this.textMeasureEl_=null}this.element_.innerHTML=''};a.beginPath=function(){this.currentPath_=[]};a.moveTo=function(b,c){var a=getCoords(this,b,c);this.currentPath_.push({type:'moveTo',x:a.x,y:a.y});this.currentX_=a.x;this.currentY_=a.y};a.lineTo=function(b,c){var a=getCoords(this,b,c);this.currentPath_.push({type:'lineTo',x:a.x,y:a.y});this.currentX_=a.x;this.currentY_=a.y};a.bezierCurveTo=function(a,b,c,d,g,h){var i=getCoords(this,g,h);var e=getCoords(this,a,b);var f=getCoords(this,c,d);bezierCurveTo(this,e,f,i)};function bezierCurveTo(b,c,d,a){b.currentPath_.push({type:'bezierCurveTo',cp1x:c.x,cp1y:c.y,cp2x:d.x,cp2y:d.y,x:a.x,y:a.y});b.currentX_=a.x;b.currentY_=a.y}a.quadraticCurveTo=function(d,e,g,h){var c=getCoords(this,d,e);var b=getCoords(this,g,h);var a={x:this.currentX_+2/3*(c.x-this.currentX_),y:this.currentY_+2/3*(c.y-this.currentY_)};var f={x:a.x+(b.x-this.currentX_)/3,y:a.y+(b.y-this.currentY_)/3};bezierCurveTo(this,a,f,b)};a.arc=function(d,f,a,g,i,h){a*=c;var p=h?'at':'wa';var b=d+m(g)*a-e;var q=f+n(g)*a-e;var l=d+m(i)*a-e;var r=f+n(i)*a-e;if(b==l&&!h){b+=0.125}var o=getCoords(this,d,f);var j=getCoords(this,b,q);var k=getCoords(this,l,r);this.currentPath_.push({type:p,x:o.x,y:o.y,radius:a,xStart:j.x,yStart:j.y,xEnd:k.x,yEnd:k.y})};a.rect=function(a,b,d,c){this.moveTo(a,b);this.lineTo(a+d,b);this.lineTo(a+d,b+c);this.lineTo(a,b+c);this.closePath()};a.strokeRect=function(a,b,d,c){var e=this.currentPath_;this.beginPath();this.moveTo(a,b);this.lineTo(a+d,b);this.lineTo(a+d,b+c);this.lineTo(a,b+c);this.closePath();this.stroke();this.currentPath_=e};a.fillRect=function(a,b,d,c){var e=this.currentPath_;this.beginPath();this.moveTo(a,b);this.lineTo(a+d,b);this.lineTo(a+d,b+c);this.lineTo(a,b+c);this.closePath();this.fill();this.currentPath_=e};a.createLinearGradient=function(b,d,c,e){var a=new CanvasGradient_('gradient');a.x0_=b;a.y0_=d;a.x1_=c;a.y1_=e;return a};a.createRadialGradient=function(d,f,b,e,g,c){var a=new CanvasGradient_('gradientradial');a.x0_=d;a.y0_=f;a.r0_=b;a.x1_=e;a.y1_=g;a.r1_=c;return a};a.drawImage=function(a,u){var j,k,i,h,d,e,m,l;var t=a.runtimeStyle.width;var s=a.runtimeStyle.height;a.runtimeStyle.width='auto';a.runtimeStyle.height='auto';var g=a.width;var f=a.height;a.runtimeStyle.width=t;a.runtimeStyle.height=s;if(arguments.length==3){j=arguments[1];k=arguments[2];d=e=0;m=i=g;l=h=f}else {if(arguments.length==5){j=arguments[1];k=arguments[2];i=arguments[3];h=arguments[4];d=e=0;m=g;l=f}else {if(arguments.length==9){d=arguments[1];e=arguments[2];m=arguments[3];l=arguments[4];j=arguments[5];k=arguments[6];i=arguments[7];h=arguments[8]}else {throw Error('Invalid number of arguments')}}}var r=getCoords(this,j,k);var o=[];var q=10;var p=10;var n=this.m_;o.push(' ','','');this.element_.insertAdjacentHTML('BeforeEnd',o.join(''))};a.setLineDash=function(a){if(a.length===1){a=a.slice();a[1]=a[0]}this.lineDash=a};a.getLineDash=function(){return this.lineDash};a.stroke=function(g){var d=[];var j=10;var i=10;d.push('');if(!g){appendStroke(this,d)}else {appendFill(this,d,f,e)}d.push('');this.element_.insertAdjacentHTML('beforeEnd',d.join(''))};function appendStroke(a,e){var d=processStyle(a.strokeStyle);var f=d.color;var c=d.alpha*a.globalAlpha;var b=a.lineScale_*a.lineWidth;if(b<1){c*=b}e.push('')}function appendFill(b,m,g,v){var a=b.fillStyle;var h=b.arcScaleX_;var i=b.arcScaleY_;var k=v.x-g.x;var j=v.y-g.y;if(a instanceof CanvasGradient_){var e=0;var o={x:0,y:0};var p=0;var s=1;if(a.type_=='gradient'){var G=a.x0_/h;var I=a.y0_/i;var H=a.x1_/h;var J=a.y1_/i;var l=getCoords(b,G,I);var w=getCoords(b,H,J);var E=w.x-l.x;var F=w.y-l.y;e=Math.atan2(E,F)*180/Math.PI;if(e<0){e+=360}if(e<1.0E-6){e=0}}else {var l=getCoords(b,a.x0_,a.y0_);o={x:(l.x-g.x)/k,y:(l.y-g.y)/j};k/=h*c;j/=i*c;var r=f.max(k,j);p=2*a.r0_/r;s=2*a.r1_/r-p}var d=a.colors_;d.sort(function(a,c){return a.offset-c.offset});var n=d.length;var B=d[0].color;var C=d[n-1].color;var y=d[0].alpha*b.globalAlpha;var z=d[n-1].alpha*b.globalAlpha;var t=[];for(var q=0;q')}else {if(a instanceof CanvasPattern_){if(k&&j){var K=-g.x;var L=-g.y;m.push('')}}else {var x=processStyle(b.fillStyle);var D=x.color;var A=x.alpha*b.globalAlpha;m.push('')}}}a.fill=function(){this.$stroke(!0)};a.closePath=function(){this.currentPath_.push({type:'close'})};function getCoords(f,b,d){var a=f.m_;return {x:c*(b*a[0][0]+d*a[1][0]+a[2][0])-e,y:c*(b*a[0][1]+d*a[1][1]+a[2][1])-e}}a.save=function(){var a={};copyState(this,a);this.aStack_.push(a);this.mStack_.push(this.m_);this.m_=matrixMultiply(createMatrixIdentity(),this.m_)};a.restore=function(){if(this.aStack_.length){copyState(this.aStack_.pop(),this);this.m_=this.mStack_.pop()}};function matrixIsFinite(a){return isFinite(a[0][0])&&isFinite(a[0][1])&&isFinite(a[1][0])&&isFinite(a[1][1])&&isFinite(a[2][0])&&isFinite(a[2][1])}function setM(b,a,c){if(!matrixIsFinite(a)){return}b.m_=a;if(c){var d=a[0][0]*a[1][1]-a[0][1]*a[1][0];b.lineScale_=s(t(d))}}a.translate=function(a,b){var c=[[1,0,0],[0,1,0],[a,b,1]];setM(this,matrixMultiply(c,this.m_),!1)};a.rotate=function(a){var b=m(a);var c=n(a);var d=[[b,c,0],[-c,b,0],[0,0,1]];setM(this,matrixMultiply(d,this.m_),!1)};a.scale=function(a,b){this.arcScaleX_*=a;this.arcScaleY_*=b;var c=[[a,0,0],[0,b,0],[0,0,1]];setM(this,matrixMultiply(c,this.m_),!0)};a.transform=function(a,b,c,d,e,f){var g=[[a,b,0],[c,d,0],[e,f,1]];setM(this,matrixMultiply(g,this.m_),!0)};a.setTransform=function(a,b,c,d,e,f){var g=[[a,b,0],[c,d,0],[e,f,1]];setM(this,g,!0)};a.drawText_=function(q,r,s,t,j){var i=this.m_,k=1000,e=0,h=k,g={x:0,y:0},d=[];var f=getComputedStyle(processFontStyle(this.font),this.element_);var n=buildStyle(f);var l=this.element_.currentStyle;var a=this.textAlign.toLowerCase();switch(a){case 'left':case 'center':case 'right':break;case 'end':a=l.direction=='ltr'?'right':'left';break;case 'start':a=l.direction=='rtl'?'right':'left';break;default:a='left';}switch(this.textBaseline){case 'hanging':case 'top':g.y=f.size/1.75;break;case 'middle':break;default:case null:case 'alphabetic':case 'ideographic':case 'bottom':g.y=-f.size/3;break;}switch(a){case 'right':e=k;h=0.05;break;case 'center':e=h=k/2;break;}var m=getCoords(this,r+g.x,s+g.y);d.push('');if(j){appendStroke(this,d)}else {appendFill(this,d,{x:-e,y:0},{x:h,y:f.size})}var p=i[0][0].toFixed(3)+','+i[1][0].toFixed(3)+','+i[0][1].toFixed(3)+','+i[1][1].toFixed(3)+',0,0';var o=b(m.x/c)+','+b(m.y/c);d.push('','','');this.element_.insertAdjacentHTML('beforeEnd',d.join(''))};a.fillText=function(b,c,d,a){this.drawText_(b,c,d,a,!1)};a.strokeText=function(b,c,d,a){this.drawText_(b,c,d,a,!0)};a.measureText=function(a){if(!this.textMeasureEl_){var c='';this.element_.insertAdjacentHTML('beforeEnd',c);this.textMeasureEl_=this.element_.lastChild}var b=this.element_.ownerDocument;this.textMeasureEl_.innerHTML='';this.textMeasureEl_.style.font=this.font;this.textMeasureEl_.appendChild(b.createTextNode(a));return {width:this.textMeasureEl_.offsetWidth}};a.clip=function(){};a.arcTo=function(){};a.createPattern=function(b,a){return new CanvasPattern_(b,a)};function CanvasGradient_(a){this.type_=a;this.x0_=0;this.y0_=0;this.r0_=0;this.x1_=0;this.y1_=0;this.r1_=0;this.colors_=[]}CanvasGradient_.prototype.addColorStop=function(b,a){a=processStyle(a);this.colors_.push({offset:b,color:a.color,alpha:a.alpha})};function CanvasPattern_(a,b){assertImageIsValid(a);switch(b){case 'repeat':case null:case '':this.repetition_='repeat';break;case 'repeat-x':case 'repeat-y':case 'no-repeat':this.repetition_=b;break;default:throwException('SYNTAX_ERR');}this.src_=a.src;this.width_=a.width;this.height_=a.height}function throwException(a){throw new DOMException_(a)}function assertImageIsValid(a){if(!a||a.nodeType!=1||a.tagName!='IMG'){throwException('TYPE_MISMATCH_ERR')}if(a.readyState!='complete'){throwException('INVALID_STATE_ERR')}}function DOMException_(a){this.code=this[a];this.message=a+': DOM Exception '+this.code}var d=DOMException_.prototype=new Error();d.INDEX_SIZE_ERR=1;d.DOMSTRING_SIZE_ERR=2;d.HIERARCHY_REQUEST_ERR=3;d.WRONG_DOCUMENT_ERR=4;d.INVALID_CHARACTER_ERR=5;d.NO_DATA_ALLOWED_ERR=6;d.NO_MODIFICATION_ALLOWED_ERR=7;d.NOT_FOUND_ERR=8;d.NOT_SUPPORTED_ERR=9;d.INUSE_ATTRIBUTE_ERR=10;d.INVALID_STATE_ERR=11;d.SYNTAX_ERR=12;d.INVALID_MODIFICATION_ERR=13;d.NAMESPACE_ERR=14;d.INVALID_ACCESS_ERR=15;d.VALIDATION_ERR=16;d.TYPE_MISMATCH_ERR=17;G_vmlCanvasManager=o;CanvasRenderingContext2D=CanvasRenderingContext2D_;CanvasGradient=CanvasGradient_;CanvasPattern=CanvasPattern_;DOMException=DOMException_})()}Ext.cmd.derive('Ext.draw.engine.Canvas',Ext.draw.Surface,{config:{highPrecision:!1},statics:{contextOverrides:{setGradientBBox:function(a){this.bbox=a},fill:function(){var d=this.fillStyle,b=this.fillGradient,a=this.fillOpacity,e=this.globalAlpha,c=this.bbox;if(d!==Ext.draw.Color.RGBA_NONE&&a!==0){if(b&&c){this.fillStyle=b.generateGradient(this,c)}if(a!==1){this.globalAlpha=e*a}this.$fill();if(a!==1){this.globalAlpha=e}if(b&&c){this.fillStyle=d}}},stroke:function(){var d=this.strokeStyle,b=this.strokeGradient,a=this.strokeOpacity,e=this.globalAlpha,c=this.bbox;if(d!==Ext.draw.Color.RGBA_NONE&&a!==0){if(b&&c){this.strokeStyle=b.generateGradient(this,c)}if(a!==1){this.globalAlpha=e*a}this.$stroke();if(a!==1){this.globalAlpha=e}if(b&&c){this.strokeStyle=d}}},fillStroke:function(d,b){var a=this,j=this.fillStyle,f=this.fillOpacity,h=this.strokeStyle,e=this.strokeOpacity,g=a.shadowColor,i=a.shadowBlur,c=Ext.draw.Color.RGBA_NONE;if(b===undefined){b=d.transformFillStroke}if(!b){d.inverseMatrix.toContext(a)}if(j!==c&&f!==0){a.fill();a.shadowColor=c;a.shadowBlur=0}if(h!==c&&e!==0){a.stroke()}a.shadowColor=g;a.shadowBlur=i},setLineDash:function(a){if(this.$setLineDash){this.$setLineDash(a)}},getLineDash:function(){if(this.$getLineDash){return this.$getLineDash()}},ellipse:function(e,f,c,d,g,i,j,h){var a=Math.cos(g),b=Math.sin(g);this.transform(a*c,b*c,-b*d,a*d,e,f);this.arc(0,0,1,i,j,h);this.transform(a/c,-b/d,b/c,a/d,-(a*e+b*f)/c,(b*e-a*f)/d)},appendPath:function(f){var c=this,d=0,a=0,e=f.commands,b=f.params,g=e.length;c.beginPath();for(;d=g.length){a.createCanvas()}b=g[c].dom;b.style.left=h+'px';b.style.top=i+'px';j=Math.min(e,p-i);if(j*f!==b.height){b.height=j*f;b.style.height=j+'px'}k=Math.min(e,q-h);if(k*f!==b.width){b.width=k*f;b.style.width=k+'px'}a.applyDefaults(a.contexts[c])}}for(c+=1;cs||a.x+a.widthr||a.y+a.height=0},filename:Ext.isString,width:Ext.isNumber,height:Ext.isNumber,scale:Ext.isNumber,pdf:Ext.isObject,jpeg:Ext.isObject},initAnimator:function(){this.frameCallbackId=Ext.draw.Animator.addFrameCallback('renderFrame',this)},applyGradients:function(d){var b=[],c,f,a,e;if(!Ext.isArray(d)){return b}for(c=0,f=d.length;c=0&&g[a[c].type]>i){a[c+1]=a[c];c--}a[c+1]=f}b=a[0].flatten(j,a);if(h==='image'){e=new Image();e.src=b.data;b.data=e;return b}if(h==='stream'){b.data=b.data.replace(/^data:image\/[^;]+/,'data:application/octet-stream');return b}return b},download:function(a){var d=this,e=[],f,b,c;a=Ext.apply({version:2,data:d.getImage().data},a);for(b in a){if(a.hasOwnProperty(b)){c=a[b];if(b in d.supportedOptions){if(d.supportedOptions[b].call(d,c)){e.push({tag:'input',type:'hidden',name:b,value:Ext.String.htmlEncode(Ext.isObject(c)?Ext.JSON.encode(c):c)})}}}}f=Ext.dom.Helper.markup({tag:'html',children:[{tag:'head'},{tag:'body',children:[{tag:'form',method:'POST',action:a.url||d.defaultDownloadServerUrl,children:e},{tag:'script',type:'text/javascript',children:'document.getElementsByTagName("form")[0].submit();'}]}]});window.open('','ImageDownload_'+Date.now()).document.write(f)},destroy:function(){var a=this.frameCallbackId;if(a){Ext.draw.Animator.removeFrameCallback(a)}Ext.draw.ContainerBase.prototype.destroy.call(this)}},0,['draw'],['component','box','container','panel','draw'],{'component':!0,'box':!0,'container':!0,'panel':!0,'draw':!0},['widget.draw'],0,[Ext.draw,'Container',Ext.draw,'Component'],function(){if(location.search.match('svg')){Ext.draw.Container.prototype.engine='Ext.draw.engine.Svg'}else {if(Ext.os.is.BlackBerry&&Ext.os.version.getMajor()===10||Ext.browser.is.AndroidStock4&&(Ext.os.version.getMinor()===1||Ext.os.version.getMinor()===2||Ext.os.version.getMinor()===3)){Ext.draw.Container.prototype.engine='Ext.draw.engine.Svg'}}});Ext.cmd.derive('Ext.chart.theme.Base',Ext.Base,{factoryConfig:{type:'chart.theme'},isTheme:!0,config:{baseColor:null,colors:undefined,gradients:null,chart:{defaults:{background:'white'}},axis:{defaults:{label:{x:0,y:0,textBaseline:'middle',textAlign:'center',fontSize:'default',fontFamily:'default',fontWeight:'default',fillStyle:'black'},title:{fillStyle:'black',fontSize:'default*1.23',fontFamily:'default',fontWeight:'default'},style:{strokeStyle:'black'},grid:{strokeStyle:'rgb(221, 221, 221)'}},top:{style:{textPadding:5}},bottom:{style:{textPadding:5}}},series:{defaults:{label:{fillStyle:'black',strokeStyle:'none',fontFamily:'default',fontWeight:'default',fontSize:'default*1.077',textBaseline:'middle',textAlign:'center'},labelOverflowPadding:5}},sprites:{text:{fontSize:'default',fontWeight:'default',fontFamily:'default',fillStyle:'black'}},seriesThemes:undefined,markerThemes:{type:['circle','cross','plus','square','triangle','diamond']},useGradients:!1,background:null},colorDefaults:['#94ae0a','#115fa6','#a61120','#ff8809','#ffd13e','#a61187','#24ad9a','#7c7474','#a66111'],constructor:function(a){this.initConfig(a);this.resolveDefaults()},defaultRegEx:/^default([+\-/\*]\d+(?:\.\d+)?)?$/,defaultOperators:{'*':function(a,b){return a*b},'+':function(a,b){return a+b},'-':function(a,b){return a-b}},resolveDefaults:function(){var a=this;Ext.onReady(function(){var g=Ext.clone(a.getSprites()),f=Ext.clone(a.getAxis()),e=Ext.clone(a.getSeries()),b,d,c;if(!a.superclass.defaults){b=Ext.getBody().createChild({tag:'div',cls:'x-component'});a.superclass.defaults={fontFamily:b.getStyle('fontFamily'),fontWeight:b.getStyle('fontWeight'),fontSize:parseFloat(b.getStyle('fontSize')),fontVariant:b.getStyle('fontVariant'),fontStyle:b.getStyle('fontStyle')};b.destroy()}a.replaceDefaults(g.text);a.setSprites(g);for(d in f){c=f[d];a.replaceDefaults(c.label);a.replaceDefaults(c.title)}a.setAxis(f);for(d in e){c=e[d];a.replaceDefaults(c.label)}a.setSeries(e)})},replaceDefaults:function(d){var e=this,g=e.superclass.defaults,h=e.defaultRegEx,c,b,a,f;if(Ext.isObject(d)){for(c in g){a=h.exec(d[c]);if(a){b=g[c];a=a[1];if(a){f=e.defaultOperators[a.charAt(0)];b=Math.round(f(b,parseFloat(a.substr(1))))}d[c]=b}}}},applyBaseColor:function(b){var a,c;if(b){a=b.isColor?b:Ext.draw.Color.fromString(b);c=a.getHSL()[2];if(c<0.15){a=a.createLighter(0.3)}else {if(c<0.3){a=a.createLighter(0.15)}else {if(c>0.85){a=a.createDarker(0.3)}else {if(c>0.7){a=a.createDarker(0.15)}}}}this.setColors([a.createDarker(0.3).toString(),a.createDarker(0.15).toString(),a.toString(),a.createLighter(0.12).toString(),a.createLighter(0.24).toString(),a.createLighter(0.31).toString()])}return b},applyColors:function(a){return a||this.colorDefaults},updateUseGradients:function(a){if(a){this.updateGradients({type:'linear',degrees:90})}},updateBackground:function(a){if(a){var b=this.getChart();b.defaults.background=a;this.setChart(b)}},updateGradients:function(d){var c=this.getColors(),g=[],e,a,f,b,h;if(Ext.isObject(d)){for(b=0,h=c&&c.length||0;bMath.PI){c-=Math.PI*2}if(p){c=c*(1-b)-Math.PI/2*b;m=h;h=g;g=m}else {c=c*(1-b)}a.rotationRads=c;a.x=n*(1-b)+j*b;a.y=o*(1-b)+k*b;d=j-n;e=k-o;if(Math.abs(e*h)>Math.abs(d*g)){if(e>0){a.calloutEndX=a.x-g/2*(d/e)*b;a.calloutEndY=a.y-g/2*b}else {a.calloutEndX=a.x+g/2*(d/e)*b;a.calloutEndY=a.y+g/2*b}}else {if(d>0){a.calloutEndX=a.x-h/2;a.calloutEndY=a.y-h/2*(e/d)*b}else {a.calloutEndX=a.x+h/2;a.calloutEndY=a.y+h/2*(e/d)*b}}if(a.calloutStartX&&a.calloutStartY){a.calloutHasLine=d>0&&a.calloutStartXa.calloutEndX||e>0&&a.calloutStartYa.calloutEndY}else {a.calloutHasLine=!0}}return a},pushDown:function(b,a){a=Ext.draw.modifier.Modifier.prototype.pushDown.call(this,b.calloutOriginal,a);return this.setAttrs(b,a)},popUp:function(a,b){a=a.prototype;b=this.setAttrs(a,b);if(this._next){return this._next.popUp(a,b)}else {return Ext.apply(a,b)}}},0,0,0,0,0,0,[Ext.chart.label,'Callout'],0);Ext.cmd.derive('Ext.chart.label.Label',Ext.draw.sprite.Text,{inheritableStatics:{def:{processors:{callout:'limited01',calloutHasLine:'bool',calloutPlaceX:'number',calloutPlaceY:'number',calloutStartX:'number',calloutStartY:'number',calloutEndX:'number',calloutEndY:'number',calloutColor:'color',calloutWidth:'number',calloutVertical:'bool',labelOverflowPadding:'number',display:'enums(none,under,over,rotate,insideStart,insideEnd,inside,outside)',orientation:'enums(horizontal,vertical)',renderer:'default'},defaults:{callout:0,calloutHasLine:!0,calloutPlaceX:0,calloutPlaceY:0,calloutStartX:0,calloutStartY:0,calloutEndX:0,calloutEndY:0,calloutWidth:1,calloutVertical:!1,calloutColor:'black',labelOverflowPadding:5,display:'none',orientation:'',renderer:null},triggers:{callout:'transform',calloutPlaceX:'transform',calloutPlaceY:'transform',labelOverflowPadding:'transform',calloutRotation:'transform',display:'hidden'},updaters:{hidden:function(a){a.hidden=a.display==='none'}}}},config:{fx:{customDurations:{callout:200}},field:null,calloutLine:!0},applyCalloutLine:function(a){if(a){return Ext.apply({},a)}},prepareModifiers:function(){Ext.draw.sprite.Text.prototype.prepareModifiers.apply(this,arguments);this.calloutModifier=new Ext.chart.label.Callout({sprite:this});this.fx.setNext(this.calloutModifier);this.calloutModifier.setNext(this.topModifier)},render:function(e,a){var b=this,d=b.attr,c=d.calloutColor;a.save();a.globalAlpha*=d.callout;if(a.globalAlpha>0&&d.calloutHasLine){if(c&&c.isGradient){c=c.getStops()[0].color}a.strokeStyle=c;a.fillStyle=c;a.lineWidth=d.calloutWidth;a.beginPath();a.moveTo(b.attr.calloutStartX,b.attr.calloutStartY);a.lineTo(b.attr.calloutEndX,b.attr.calloutEndY);a.stroke();a.beginPath();a.arc(b.attr.calloutStartX,b.attr.calloutStartY,1*d.calloutWidth,0,2*Math.PI,!0);a.fill();a.beginPath();a.arc(b.attr.calloutEndX,b.attr.calloutEndY,1*d.calloutWidth,0,2*Math.PI,!0);a.fill()}a.restore();Ext.draw.sprite.Text.prototype.render.apply(b,arguments)}},0,0,0,0,0,0,[Ext.chart.label,'Label'],0);Ext.cmd.derive('Ext.chart.series.Series',Ext.Base,{isSeries:!0,defaultBindProperty:'store',type:null,seriesType:'sprite',identifiablePrefix:'ext-line-',observableType:'series',darkerStrokeRatio:0.15,config:{chart:null,title:null,renderer:null,showInLegend:!0,triggerAfterDraw:!1,style:{},subStyle:{},themeStyle:{},colors:null,useDarkerStrokeColor:!0,store:null,label:{},labelOverflowPadding:null,showMarkers:!0,marker:null,markerSubStyle:null,itemInstancing:null,background:null,highlightItem:null,surface:null,overlaySurface:null,hidden:!1,highlight:!1,highlightCfg:{merge:function(a){return a},$value:{fillStyle:'yellow',strokeStyle:'red'}},animation:null,tooltip:null},directions:[],sprites:null,themeColorCount:function(){return 1},isStoreDependantColorCount:!1,themeMarkerCount:function(){return 0},getFields:function(d){var f=this,b=[],a,c,e;for(c=0,e=d.length;c0){if(!Ext.isBoolean(k)||!k){for(b=0;bd){d=a}}b.min=e;b.max=d},updateLabelData:function(){var h=this,l=h.getStore(),i=l.getData().items,e=h.getSprites(),k=h.getLabel().getTemplate(),d=Ext.Array.from(k.getField()),a,c,j,f,g,b;if(!e.length||!d.length){return}for(a=0;a=0){return a}}}}}},onChartDetached:function(b){var a=this;a.fireEvent('chartdetached',b,a);b.un('storechange','onStoreChange',a)},onChartAttached:function(b){var a=this;a.setBackground(a.getBackground());a.fireEvent('chartattached',b,a);b.on('storechange','onStoreChange',a);a.processData()},updateOverlaySurface:function(b){var a=this;if(b){if(a.getLabel()){a.getOverlaySurface().add(a.getLabel())}}},applyLabel:function(b,a){if(!a){a=new Ext.chart.Markers({zIndex:10});a.setTemplate(new Ext.chart.label.Label(b))}else {a.getTemplate().setAttributes(b)}return a},createItemInstancingSprite:function(f,e){var d=this,a=new Ext.chart.Markers(),c,b;a.setAttributes({zIndex:Number.MAX_VALUE});c=Ext.apply({},e);if(d.getHighlight()){c.highlight=d.getHighlight();c.modifiers=['highlight']}a.setTemplate(c);b=a.getTemplate();b.setAttributes(d.getStyle());b.fx.on('animationstart','onSpriteAnimationStart',this);b.fx.on('animationend','onSpriteAnimationEnd',this);f.bindMarker('items',a);d.getSurface().add(a);return a},getDefaultSpriteConfig:function(){return {type:this.seriesType,renderer:this.getRenderer()}},updateRenderer:function(d){var c=this,a=c.getChart(),b;if(a&&a.isInitializing){return}b=c.getSprites();if(b.length){b[0].setAttributes({renderer:d||null});if(a&&!a.isInitializing){a.redraw()}}},updateShowMarkers:function(d){var b=this.getSprites(),c=b&&b[0],a=c&&c.getMarker('markers');if(a){a.getTemplate().setAttributes({hidden:!d})}},createSprite:function(){var a=this,g=a.getSurface(),e=a.getItemInstancing(),b=g.add(a.getDefaultSpriteConfig()),f=a.getMarker(),c,d;b.setAttributes(a.getStyle());b.setSeries(a);if(e){b.itemsMarker=a.createItemInstancingSprite(b,e)}if(b.bindMarker){if(f){c=new Ext.chart.Markers();d=Ext.Object.merge({},f);if(a.getHighlight()){d.highlight=a.getHighlight();d.modifiers=['highlight']}c.setTemplate(d);c.getTemplate().fx.setCustomDurations({translationX:0,translationY:0});b.dataMarker=c;b.bindMarker('markers',c);a.getOverlaySurface().add(c)}if(a.getLabel().getTemplate().getField()){b.bindMarker('labels',a.getLabel())}}if(b.setStore){b.setStore(a.getStore())}b.fx.on('animationstart','onSpriteAnimationStart',a);b.fx.on('animationend','onSpriteAnimationEnd',a);a.sprites.push(b);return b},getSprites:Ext.emptyFn,onDataChanged:function(){var a=this,b=a.getChart(),d=b&&b.getStore(),c=a.getStore();if(c!==d){a.processData()}},isXType:function(a){return a==='series'},getItemId:function(){return this.getId()},applyThemeStyle:function(a,e){var d=this,b,c;b=a&&a.subStyle&&a.subStyle.fillStyle;c=b&&a.subStyle.strokeStyle;if(b&&!c){a.subStyle.strokeStyle=d.getStrokeColorsFromFillColors(b)}b=a&&a.markerSubStyle&&a.markerSubStyle.fillStyle;c=b&&a.markerSubStyle.strokeStyle;if(b&&!c){a.markerSubStyle.strokeStyle=d.getStrokeColorsFromFillColors(b)}return Ext.apply(e||{},a)},applyStyle:function(a,c){var b=Ext.ClassManager.get(Ext.ClassManager.getNameByAlias('sprite.'+this.seriesType));if(b&&b.def){a=b.def.normalize(a)}return Ext.apply({},a,c)},applySubStyle:function(a,c){var b=Ext.ClassManager.get(Ext.ClassManager.getNameByAlias('sprite.'+this.seriesType));if(b&&b.def){a=b.def.batchedNormalize(a,!0)}return Ext.merge({},c,a)},applyMarker:function(a,b){var d=a&&a.type||b&&b.type||'circle',c=Ext.ClassManager.get(Ext.ClassManager.getNameByAlias('sprite.'+d));if(c&&c.def){a=c.def.normalize(Ext.isObject(a)?a:{},!0);a.type=d}return Ext.merge(b||{},a)},applyMarkerSubStyle:function(a,b){var d=a&&a.type||b&&b.type||'circle',c=Ext.ClassManager.get(Ext.ClassManager.getNameByAlias('sprite.'+d));if(c&&c.def){a=c.def.batchedNormalize(a,!0)}return Ext.merge(b||{},a)},updateHidden:function(b){var a=this;a.getColors();a.getSubStyle();a.setSubStyle({hidden:b});a.processData();a.doUpdateStyles();if(!Ext.isArray(b)){a.updateLegendStore(b)}},updateLegendStore:function(c,g){var e=this,f=e.getChart(),b=f.getLegendStore(),d=e.getId(),a;if(b){if(arguments.length>1){a=b.findBy(function(a){return a.get('series')===d&&a.get('index')===g});if(a!==-1){a=b.getAt(a)}}else {a=b.findRecord('series',d)}if(a&&a.get('disabled')!==c){a.set('disabled',c)}}},setHiddenByIndex:function(c,b){var a=this;if(Ext.isArray(a.getHidden())){a.getHidden()[c]=b;a.updateHidden(a.getHidden());a.updateLegendStore(b,c)}else {a.setHidden(b)}},getStrokeColorsFromFillColors:function(c){var d=this,b=d.getUseDarkerStrokeColor(),e=Ext.isNumber(b)?b:d.darkerStrokeRatio,a;if(b){a=Ext.Array.map(c,function(a){a=Ext.isString(a)?a:a.stops[0].color;a=Ext.draw.Color.fromString(a);return a.createDarker(e).toString()})}else {a=Ext.Array.clone(c)}return a},updateThemeColors:function(d){var b=this,a=b.getThemeStyle(),f=Ext.Array.clone(d),e=b.getStrokeColorsFromFillColors(d),c={fillStyle:f,strokeStyle:e};a.subStyle=Ext.apply(a.subStyle||{},c);a.markerSubStyle=Ext.apply(a.markerSubStyle||{},c);b.doUpdateStyles()},themeOnlyIfConfigured:{},updateTheme:function(o){var c=this,d=o.getSeries(),m=c.getInitialConfig(),l=c.defaultConfig,n=c.getConfigurator().configs,k=d.defaults,j=d[c.type],i=c.themeOnlyIfConfigured,b,a,g,e,f,h;d=Ext.merge({},k,j);for(b in d){a=d[b];h=n[b];if(a!==null&&a!==undefined&&h){f=m[b];g=Ext.isObject(a);e=f===l[b];if(g){if(e&&i[b]){continue}a=Ext.merge({},a,f)}if(e||g){c[h.names.set](a)}}}},updateChartColors:function(b){var a=this;if(!a.getColors()){a.updateThemeColors(b)}},updateColors:function(a){this.updateThemeColors(a)},updateStyle:function(){this.doUpdateStyles()},updateSubStyle:function(){this.doUpdateStyles()},updateThemeStyle:function(){this.doUpdateStyles()},doUpdateStyles:function(){var c=this,b=c.sprites,e=c.getItemInstancing(),a=0,g=b&&b.length,h=c.getConfig('showMarkers',!0),f=c.getMarker(),d;for(;aa.to){c.call(this,a.max,a.getLabel(a.max),a.steps+1,a)}}else {var f=function(b){return !d.length||k(d,function(d){return l(d-b)>i})};h=this.getAxis();g=h.floatingAxes;d=[];i=(a.to-a.from)/(a.steps+1);if(h.getFloating()){for(j in g){d.push(g[j])}}if(a.mina.to&&f(a.max)){c.call(this,a.max,a.max,a.steps+1,a)}}},renderTicks:function(j,b,p,i){var c=this,a=c.attr,v=a.position,k=a.matrix,g=0.5*a.lineWidth,s=k.getXX(),q=k.getDX(),t=k.getYY(),r=k.getDY(),f=p.majorTicks,d=a.majorTickSize,e=p.minorTicks,h=a.minorTickSize;if(f){switch(v){case 'right':var m=function(a){return function(c,d,e){c=j.roundPixel(c*t+r)+g;b.moveTo(0,c);b.lineTo(a,c)}};c.iterate(f,m(d));e&&c.iterate(e,m(h));break;case 'left':var n=function(a){return function(c,d,e){c=j.roundPixel(c*t+r)+g;b.moveTo(i[2]-a,c);b.lineTo(i[2],c)}};c.iterate(f,n(d));e&&c.iterate(e,n(h));break;case 'bottom':var l=function(a){return function(c,d,e){c=j.roundPixel(c*s+q)-g;b.moveTo(c,0);b.lineTo(c,a)}};c.iterate(f,l(d));e&&c.iterate(e,l(h));break;case 'top':var o=function(a){return function(c,d,e){c=j.roundPixel(c*s+q)-g;b.moveTo(c,i[3]);b.lineTo(c,i[3]-a)}};c.iterate(f,o(d));e&&c.iterate(e,o(h));break;case 'angular':c.iterate(f,function(c,e,f){c=c/(a.max+1)*Math.PI*2+a.baseRotation;b.moveTo(a.centerX+a.length*Math.cos(c),a.centerY+a.length*Math.sin(c));b.lineTo(a.centerX+(a.length+d)*Math.cos(c),a.centerY+(a.length+d)*Math.sin(c))});break;case 'gauge':var u=c.getGaugeAngles();c.iterate(f,function(c,e,f){c=(c-a.min)/(a.max-a.min+1)*a.totalAngle-a.totalAngle+u.start;b.moveTo(a.centerX+a.length*Math.cos(c),a.centerY+a.length*Math.sin(c));b.lineTo(a.centerX+(a.length+d)*Math.cos(c),a.centerY+(a.length+d)*Math.sin(c))});break;}}},renderLabels:function(e,G,i,s){var h=this,a=h.attr,q=0.5*a.lineWidth,t=a.position,A=a.matrix,F=a.textPadding,J=A.getXX(),v=A.getDX(),K=A.getYY(),I=A.getDY(),m=0,w=i.majorTicks,k=Math.max(a.majorTickSize,a.minorTickSize)+a.lineWidth,y=Ext.draw.Draw.isBBoxIntersect,b=h.getLabel(),E,C,f=null,p=0,u=0,z=i.segmenter,o=h.getRenderer(),l=h.getAxis(),D=l.getTitle(),n=D&&D.attr.text!==''&&D.getBBox(),B,g=null,c,x,d,j,r;if(w&&b&&!b.attr.hidden){E=b.attr.font;if(G.font!==E){G.font=E}b.setAttributes({translationX:0,translationY:0},!0);b.applyTransformations();B=b.attr.inverseMatrix.elements.slice(0);switch(t){case 'left':j=n?n.x+n.width:0;switch(b.attr.textAlign){case 'start':r=e.roundPixel(j+v)-q;break;case 'end':r=e.roundPixel(s[2]-k+v)-q;break;default:r=e.roundPixel(j+(s[2]-j-k)/2+v)-q;};b.setAttributes({translationX:r},!0);break;case 'right':j=n?s[2]-n.x:0;switch(b.attr.textAlign){case 'start':r=e.roundPixel(k+v)+q;break;case 'end':r=e.roundPixel(s[2]-j+v)+q;break;default:r=e.roundPixel(k+(s[2]-k-j)/2+v)+q;};b.setAttributes({translationX:r},!0);break;case 'top':j=n?n.y+n.height:0;b.setAttributes({translationY:e.roundPixel(j+(s[3]-j-k)/2)-q},!0);break;case 'bottom':j=n?s[3]-n.y:0;b.setAttributes({translationY:e.roundPixel(k+(s[3]-k-j)/2)+q},!0);break;case 'radial':b.setAttributes({translationX:a.centerX},!0);break;case 'angular':b.setAttributes({translationY:a.centerY},!0);break;case 'gauge':b.setAttributes({translationY:a.centerY},!0);break;}if(t==='left'||t==='right'){h.iterate(w,function(j,a,n){if(a===undefined){return}if(o){d=Ext.callback(o,null,[l,a,i,f],0,l)}else {d=z.renderer(a,i,f)}f=a;b.setAttributes({text:String(d),translationY:e.roundPixel(j*K+I)},!0);b.applyTransformations();m=Math.max(m,b.getBBox().width+k);if(m<=h.thickness){x=Ext.draw.Matrix.fly(b.attr.matrix.elements.slice(0));c=x.prepend.apply(x,B).transformBBox(b.getBBox(!0));if(g&&!y(c,g,F)){return}e.renderSprite(b);g=c;p+=c.height;u++}})}else {if(t==='top'||t==='bottom'){h.iterate(w,function(j,a,n){if(a===undefined){return}if(o){d=Ext.callback(o,null,[l,a,i,f],0,l)}else {d=z.renderer(a,i,f)}f=a;b.setAttributes({text:String(d),translationX:e.roundPixel(j*J+v)},!0);b.applyTransformations();m=Math.max(m,b.getBBox().height+k);if(m<=h.thickness){x=Ext.draw.Matrix.fly(b.attr.matrix.elements.slice(0));c=x.prepend.apply(x,B).transformBBox(b.getBBox(!0));if(g&&!y(c,g,F)){return}e.renderSprite(b);g=c;p+=c.width;u++}})}else {if(t==='radial'){h.iterate(w,function(j,h,k){if(h===undefined){return}if(o){d=Ext.callback(o,null,[l,h,i,f],0,l)}else {d=z.renderer(h,i,f)}f=h;if(typeof d!=='undefined'){b.setAttributes({text:String(d),translationX:a.centerX-e.roundPixel(j)/a.max*a.length*Math.cos(a.baseRotation+Math.PI/2),translationY:a.centerY-e.roundPixel(j)/a.max*a.length*Math.sin(a.baseRotation+Math.PI/2)},!0);b.applyTransformations();c=b.attr.matrix.transformBBox(b.getBBox(!0));if(g&&!y(c,g)){return}e.renderSprite(b);g=c;p+=c.width;u++}})}else {if(t==='angular'){C=a.majorTickSize+a.lineWidth*0.5+(parseInt(b.attr.fontSize,10)||10)/2;h.iterate(w,function(k,h,n){if(h===undefined){return}if(o){d=Ext.callback(o,null,[l,h,i,f],0,l)}else {d=z.renderer(h,i,f)}f=h;m=Math.max(m,Math.max(a.majorTickSize,a.minorTickSize)+(a.lineCap!=='butt'?a.lineWidth*0.5:0));if(typeof d!=='undefined'){var j=k/(a.max+1)*Math.PI*2+a.baseRotation;b.setAttributes({text:String(d),translationX:a.centerX+(a.length+C)*Math.cos(j),translationY:a.centerY+(a.length+C)*Math.sin(j)},!0);b.applyTransformations();c=b.attr.matrix.transformBBox(b.getBBox(!0));if(g&&!y(c,g)){return}e.renderSprite(b);g=c;p+=c.width;u++}})}else {if(t==='gauge'){var H=h.getGaugeAngles();h.iterate(w,function(k,h,m){if(h===undefined){return}if(o){d=Ext.callback(o,null,[l,h,i,f],0,l)}else {d=z.renderer(h,i,f)}f=h;if(typeof d!=='undefined'){var j=(k-a.min)/(a.max-a.min+1)*a.totalAngle-a.totalAngle+H.start;b.setAttributes({text:String(d),translationX:a.centerX+(a.length+10)*Math.cos(j),translationY:a.centerY+(a.length+10)*Math.sin(j)},!0);b.applyTransformations();c=b.attr.matrix.transformBBox(b.getBBox(!0));if(g&&!y(c,g)){return}e.renderSprite(b);g=c;p+=c.width;u++}})}}}}}if(a.enlargeEstStepSizeByText&&u){p/=u;p+=k;p*=2;if(a.estStepSize1){h.thickness=m;a.bbox.plain.dirty=!0;a.bbox.transform.dirty=!0;h.doThicknessChanged();return !1}}},renderAxisLine:function(g,b,j,f){var h=this,a=h.attr,c=a.lineWidth*0.5,i=a.position,d,e;if(a.axisLine&&a.length){switch(i){case 'left':d=g.roundPixel(f[2])-c;b.moveTo(d,-a.endGap);b.lineTo(d,a.length+a.startGap+1);break;case 'right':b.moveTo(c,-a.endGap);b.lineTo(c,a.length+a.startGap+1);break;case 'bottom':b.moveTo(-a.startGap,c);b.lineTo(a.length+a.endGap,c);break;case 'top':d=g.roundPixel(f[3])-c;b.moveTo(-a.startGap,d);b.lineTo(a.length+a.endGap,d);break;case 'angular':b.moveTo(a.centerX+a.length,a.centerY);b.arc(a.centerX,a.centerY,a.length,0,Math.PI*2,!0);break;case 'gauge':e=h.getGaugeAngles();b.moveTo(a.centerX+Math.cos(e.start)*a.length,a.centerY+Math.sin(e.start)*a.length);b.arc(a.centerX,a.centerY,a.length,e.start,e.end,!0);break;}}},getGaugeAngles:function(){var c=this,b=c.attr.totalAngle,a;if(b<=Math.PI){a=(Math.PI-b)*0.5}else {a=-(Math.PI*2-b)*0.5}a=Math.PI*2-a;return {start:a,end:a-b}},renderGridLines:function(s,t,p,r){var c=this,q=c.getAxis(),b=c.attr,j=b.matrix,i=b.startGap,k=b.endGap,n=j.getXX(),o=j.getYY(),l=j.getDX(),m=j.getDY(),g=b.position,f=q.getGridAlignment(),h=p.majorTicks,a,e,d;if(b.grid){if(h){if(g==='left'||g==='right'){d=b.min*o+m+k+i;c.iterate(h,function(g,h,b){a=g*o+m+k;c.putMarker(f+'-'+(b%2?'odd':'even'),{y:a,height:d-a},e=b,!0);d=a});e++;a=0;c.putMarker(f+'-'+(e%2?'odd':'even'),{y:a,height:d-a},e,!0)}else {if(g==='top'||g==='bottom'){d=b.min*n+l+i;if(i){c.putMarker(f+'-even',{x:0,width:d},-1,!0)}c.iterate(h,function(g,h,b){a=g*n+l+i;c.putMarker(f+'-'+(b%2?'odd':'even'),{x:a,width:d-a},e=b,!0);d=a});e++;a=b.length+b.startGap+b.endGap;c.putMarker(f+'-'+(e%2?'odd':'even'),{x:a,width:d-a},e,!0)}else {if(g==='radial'){c.iterate(h,function(e,h,g){if(!e){return}a=e/b.max*b.length;c.putMarker(f+'-'+(g%2?'odd':'even'),{scalingX:a,scalingY:a},g,!0);d=a})}else {if(g==='angular'){c.iterate(h,function(g,h,e){if(!b.length){return}a=g/(b.max+1)*Math.PI*2+b.baseRotation;c.putMarker(f+'-'+(e%2?'odd':'even'),{rotationRads:a,rotationCenterX:0,rotationCenterY:0,scalingX:b.length,scalingY:b.length},e,!0);d=a})}}}}}}},renderLimits:function(u){var k=this,i=k.getAxis(),t=i.getChart(),s=t.getInnerPadding(),h=Ext.Array.from(i.getLimits());if(!h.length){return}var m=i.limits.surface.getRect(),c=k.attr,o=c.matrix,g=c.position,p=Ext.Object.chain,d=i.limits.titles,f,l,n,a,b,e,j,q,r;d.instances=[];d.position=0;if(g==='left'||g==='right'){for(e=0,j=h.length;ec.max){continue}b=b/c.max*c.length;a.line.cx=c.centerX;a.line.cy=c.centerY;a.line.scalingX=b;a.line.scalingY=b;a.line.strokeStyle=a.line.strokeStyle||c.strokeStyle;k.putMarker('circular-limit-lines',a.line,e,!0);if(a.line.title){d.createInstance(a.line.title);f=d.getBBoxFor(d.position-1);d.setAttributesFor(d.position-1,{x:c.centerX,y:c.centerY-b-f.height/2,fillStyle:a.line.title.fillStyle||a.line.strokeStyle})}}}else {if(g==='angular'){for(e=0,j=h.length;e-0.5*Math.PI&&b<0.5*Math.PI||b>1.5*Math.PI&&b<2*Math.PI?1:-1;d.setAttributesFor(d.position-1,{x:c.centerX+0.5*c.length*Math.cos(b)+n*f.height/2*Math.sin(b),y:c.centerY+0.5*c.length*Math.sin(b)-n*f.height/2*Math.cos(b),rotationRads:n===1?b:b-Math.PI,fillStyle:a.line.title.fillStyle||a.line.strokeStyle})}}}else {if(g==='gauge'){}}}}}},doThicknessChanged:function(){var a=this.getAxis();if(a){a.onThicknessChanged()}},render:function(e,a,d){var b=this,c=b.getLayoutContext();if(c){if(!1===b.renderLabels(e,a,c,d)){return !1}a.beginPath();b.renderTicks(e,a,c,d);b.renderAxisLine(e,a,c,d);b.renderGridLines(e,a,c,d);b.renderLimits(d);a.stroke()}}},0,0,0,0,['sprite.axis'],[['markerHolder',Ext.chart.MarkerHolder]],[Ext.chart.axis.sprite,'Axis'],0);Ext.cmd.derive('Ext.chart.axis.segmenter.Segmenter',Ext.Base,{config:{axis:null},constructor:function(a){this.initConfig(a)},renderer:function(a,b){return String(a)},from:function(a){return a},diff:Ext.emptyFn,align:Ext.emptyFn,add:Ext.emptyFn,preferredStep:Ext.emptyFn},1,0,0,0,0,0,[Ext.chart.axis.segmenter,'Segmenter'],0);Ext.cmd.derive('Ext.chart.axis.segmenter.Names',Ext.chart.axis.segmenter.Segmenter,{renderer:function(a,b){return a},diff:function(b,a,c){return Math.floor(a-b)},align:function(a,b,c){return Math.floor(a)},add:function(a,b,c){return a+b},preferredStep:function(d,a,b,c){return {unit:1,step:1}}},0,0,0,0,['segmenter.names'],0,[Ext.chart.axis.segmenter,'Names'],0);Ext.cmd.derive('Ext.chart.axis.segmenter.Numeric',Ext.chart.axis.segmenter.Segmenter,{isNumeric:!0,renderer:function(b,a){return b.toFixed(Math.max(0,a.majorTicks.unit.fixes))},diff:function(c,b,a){return Math.floor((b-c)/a.scale)},align:function(c,a,b){return Math.floor(c/(b.scale*a))*b.scale*a},add:function(a,b,c){return a+b*c.scale},preferredStep:function(d,a){var b=Math.floor(Math.log(a)*Math.LOG10E),c=Math.pow(10,b);a/=c;if(a<2){a=2}else {if(a<5){a=5}else {if(a<10){a=10;b++}}}return {unit:{fixes:-b,scale:c},step:a}},exactStep:function(d,a){var b=Math.floor(Math.log(a)*Math.LOG10E),c=Math.pow(10,b);return {unit:{fixes:-b+(a%c===0?0:1),scale:1},step:a}},adjustByMajorUnit:function(g,f,c){var e=c[0],d=c[1],b=g*f,a=e%b;if(a!==0){c[0]=e-a+(e<0?-b:0)}a=d%b;if(a!==0){c[1]=d-a+(d>0?b:0)}}},0,0,0,0,['segmenter.numeric'],0,[Ext.chart.axis.segmenter,'Numeric'],0);Ext.cmd.derive('Ext.chart.axis.segmenter.Time',Ext.chart.axis.segmenter.Segmenter,{config:{step:null},renderer:function(b,c){var a=Ext.Date;switch(c.majorTicks.unit){case 'y':return a.format(b,'Y');case 'mo':return a.format(b,'Y-m');case 'd':return a.format(b,'Y-m-d');}return a.format(b,'Y-m-d\nH:i:s')},from:function(a){return new Date(a)},diff:function(b,a,c){if(isFinite(b)){b=new Date(b)}if(isFinite(a)){a=new Date(a)}return Ext.Date.diff(b,a,c)},align:function(a,b,c){if(c==='d'&&b>=7){a=Ext.Date.align(a,'d',b);a.setDate(a.getDate()-a.getDay()+1);return a}else {return Ext.Date.align(a,c,b)}},add:function(a,b,c){return Ext.Date.add(new Date(a),c,b)},stepUnits:[[Ext.Date.YEAR,1,2,5,10,20,50,100,200,500],[Ext.Date.MONTH,1,3,6],[Ext.Date.DAY,1,7,14],[Ext.Date.HOUR,1,6,12],[Ext.Date.MINUTE,1,5,15,30],[Ext.Date.SECOND,1,5,15,30],[Ext.Date.MILLI,1,2,5,10,20,50,100,200,500]],preferredStep:function(g,h){if(this.getStep()){return this.getStep()}var i=new Date(+g),j=new Date(+g+Math.ceil(h)),c=this.stepUnits,b,f,e,a,d;for(a=0;a0){for(d=1;dg){a.max=a.to}if(a.fromf){a.max=a.to}if(a.from0){a.from=a.from+d*a.step*b;while(a.from0?a:b},applyLabel:function(b,a){if(!a){a=new Ext.draw.sprite.Text({})}if(this.limitTitleTpl){this.limitTitleTpl.setAttributes(b)}a.setAttributes(b);return a},applyLayout:function(a,b){a=Ext.factory(a,null,b,'axisLayout');a.setAxis(this);return a},applySegmenter:function(a,b){a=Ext.factory(a,null,b,'segmenter');a.setAxis(this);return a},updateMinimum:function(){this.range=null},updateMaximum:function(){this.range=null},hideLabels:function(){this.getSprites()[0].setDirty(!0);this.setLabel({hidden:!0})},showLabels:function(){this.getSprites()[0].setDirty(!0);this.setLabel({hidden:!1})},renderFrame:function(){this.getSurface().renderFrame()},updateChart:function(c,b){var a=this,d;if(b){b.unregister(a);b.un('serieschange',a.onSeriesChange,a);b.un('redraw',a.renderLimits,a);a.linkAxis();a.fireEvent('chartdetached',b,a)}if(c){c.on('serieschange',a.onSeriesChange,a);a.surface=null;d=a.getSurface();a.getLabel().setSurface(d);d.add(a.getSprites());d.add(a.getTitle());c.register(a);a.fireEvent('chartattached',c,a)}},applyBackground:function(a){var b=Ext.ClassManager.getByAlias('sprite.rect');return b.def.normalize(a)},processData:function(){this.getLayout().processData();this.range=null},getDirection:function(){return this.getChart().getDirectionForAxis(this.getPosition())},isSide:function(){var a=this.getPosition();return a==='left'||a==='right'},applyFields:function(a){return Ext.Array.from(a)},applyVisibleRange:function(a,b){this.getChart();if(a[0]>a[1]){var c=a[0];a[0]=a[1];a[0]=c}if(a[1]===a[0]){a[1]+=1/this.getMaxZoom()}if(a[1]>a[0]+1){a[0]=0;a[1]=1}else {if(a[0]<0){a[1]-=a[0];a[0]=0}else {if(a[1]>1){a[0]-=a[1]-1;a[1]=1}}}if(b&&a[0]===b[0]&&a[1]===b[1]){return undefined}return a},updateVisibleRange:function(a){this.fireEvent('visiblerangechange',this,a)},onSeriesChange:function(g){var a=this,e=g.getSeries(),h='get'+a.getDirection()+'Axis',f=[],b,i=e.length,d,c;for(b=0;bb){b=g[1]}}}if(!isFinite(b)){b=a.prevMax}if(!isFinite(c)){c=a.prevMin}if(a.getLabelInSpan()||c===b){b+=a.getIncrement();c-=a.getIncrement()}if(Ext.isNumber(a.getMinimum())){c=a.getMinimum()}else {a.prevMin=c}if(Ext.isNumber(a.getMaximum())){b=a.getMaximum()}else {a.prevMax=b}a.range=[Ext.Number.correctFloat(c),Ext.Number.correctFloat(b)];if(a.getReconcileRange()){a.reconcileRange()}if(a.getAdjustByMajorUnit()&&h.adjustByMajorUnit&&!a.getMajorTickSteps()){d=Ext.Object.chain(a.getSprites()[0].attr);d.min=a.range[0];d.max=a.range[1];d.visibleMin=j[0];d.visibleMax=j[1];f={attr:d,segmenter:h};l.calculateLayout(f);e=f.majorTicks;if(e){h.adjustByMajorUnit(e.step,e.unit.scale,a.range);d.min=a.range[0];d.max=a.range[1];delete f.majorTicks;l.calculateLayout(f);e=f.majorTicks;h.adjustByMajorUnit(e.step,e.unit.scale,a.range)}else {if(!a.hasClearRangePending){a.hasClearRangePending=!0;a.getChart().on('layout','clearRange',a)}}}if(!Ext.Array.equals(a.range,a.oldRange||[])){a.fireEvent('rangechange',a,a.range);a.oldRange=a.range}return a.range},clearRange:function(){delete this.hasClearRangePending;this.range=null},reconcileRange:function(){var a=this,e=a.getChart().getAxes(),g=a.getDirection(),d,f,c,b;if(!e){return}for(d=0,f=e.length;da.range[1]){a.range[1]=b[1]}}},applyStyle:function(b,a){var c=Ext.ClassManager.getByAlias('sprite.'+this.seriesType);if(c&&c.def){b=c.def.normalize(b)}a=Ext.apply(a||{},b);return a},themeOnlyIfConfigured:{grid:!0},updateTheme:function(p){var c=this,d=p.getAxis(),n=c.getPosition(),m=c.getInitialConfig(),l=c.defaultConfig,o=c.getConfigurator().configs,k=d.defaults,j=d[n],i=c.themeOnlyIfConfigured,b,a,g,e,f,h;d=Ext.merge({},k,j);for(b in d){a=d[b];h=o[b];if(a!==null&&a!==undefined&&h){f=m[b];g=Ext.isObject(a);e=f===l[b];if(g){if(e&&i[b]){continue}a=Ext.merge({},a,f)}if(e||g){c[h.names.set](a)}}}},updateCenter:function(d){var e=this.getSprites(),c=e[0],a=d[0],b=d[1];if(c){c.setAttributes({centerX:a,centerY:b})}if(this.gridSpriteEven){this.gridSpriteEven.getTemplate().setAttributes({translationX:a,translationY:b,rotationCenterX:a,rotationCenterY:b})}if(this.gridSpriteOdd){this.gridSpriteOdd.getTemplate().setAttributes({translationX:a,translationY:b,rotationCenterX:a,rotationCenterY:b})}},getSprites:function(){if(!this.getChart()){return}var a=this,e=a.getRange(),g=a.getPosition(),i=a.getChart(),d=i.getAnimation(),b,f,h=a.getLength(),c=a.superclass;if(d===!1){d={duration:0}}if(e){f=Ext.applyIf({position:g,axis:a,min:e[0],max:e[1],length:h,grid:a.getGrid(),hidden:a.getHidden(),titleOffset:a.titleOffset,layout:a.getLayout(),segmenter:a.getSegmenter(),totalAngle:a.getTotalAngle(),label:a.getLabel()},a.getStyle());if(!a.sprites.length){while(!c.xtype){c=c.superclass}b=Ext.create('sprite.'+c.xtype,f);b.fx.setCustomDurations({baseRotation:0});b.fx.on('animationstart','onAnimationStart',a);b.fx.on('animationend','onAnimationEnd',a);b.setLayout(a.getLayout());b.setSegmenter(a.getSegmenter());b.setLabel(a.getLabel());a.sprites.push(b);a.updateTitleSprite()}else {b=a.sprites[0];b.setAnimation(d);b.setAttributes(f)}if(a.getRenderer()){b.setRenderer(a.getRenderer())}}return a.sprites},updateTitleSprite:function(){var b=this,g=b.getLength();if(!b.sprites[0]||!Ext.isNumber(g)){return}var f=this.sprites[0].thickness,i=b.getSurface(),a=b.getTitle(),h=b.getPosition(),e=b.getMargin(),c=b.getTitleMargin(),d=i.roundPixel(g/2);if(a){switch(h){case 'top':a.setAttributes({x:d,y:e+c/2,textBaseline:'top',textAlign:'center'},!0);a.applyTransformations();b.titleOffset=a.getBBox().height+c;break;case 'bottom':a.setAttributes({x:d,y:f+c/2,textBaseline:'top',textAlign:'center'},!0);a.applyTransformations();b.titleOffset=a.getBBox().height+c;break;case 'left':a.setAttributes({x:e+c/2,y:d,textBaseline:'top',textAlign:'center',rotationCenterX:e+c/2,rotationCenterY:d,rotationRads:-Math.PI/2},!0);a.applyTransformations();b.titleOffset=a.getBBox().width+c;break;case 'right':a.setAttributes({x:f-e+c/2,y:d,textBaseline:'bottom',textAlign:'center',rotationCenterX:f+c/2,rotationCenterY:d,rotationRads:Math.PI/2},!0);a.applyTransformations();b.titleOffset=a.getBBox().width+c;break;}}},onThicknessChanged:function(){this.getChart().onThicknessChanged()},getThickness:function(){if(this.getHidden()){return 0}return (this.sprites[0]&&this.sprites[0].thickness||1)+this.titleOffset+this.getMargin()},onAnimationStart:function(){this.spriteAnimationCount++;if(this.spriteAnimationCount===1){this.fireEvent('animationstart',this)}},onAnimationEnd:function(){this.spriteAnimationCount--;if(this.spriteAnimationCount===0){this.fireEvent('animationend',this)}},getItemId:function(){return this.getId()},getAncestorIds:function(){return [this.getChart().getId()]},isXType:function(a){return a==='axis'},resolveListenerScope:function(d){var c=this,e=Ext._namedScopes[d],a=c.getChart(),b;if(!e){b=a?a.resolveListenerScope(d,!1):d||c}else {if(e.isThis){b=c}else {if(e.isController){b=a?a.resolveListenerScope(d,!1):c}else {if(e.isSelf){b=a?a.resolveListenerScope(d,!1):c;if(b===a&&!a.getInheritedConfig('defaultListenerScope')){b=c}}}}}return b},destroy:function(){var a=this;a.setChart(null);a.surface.destroy();a.surface=null;a.callParent()}},1,['axis'],['axis'],{'axis':!0},['widget.axis'],[['observable',Ext.mixin.Observable]],[Ext.chart.axis,'Axis'],0);Ext.cmd.derive('Ext.chart.LegendBase',Ext.view.View,{config:{tpl:['
    ','','
    ','','{name}','
    ','
    ','
    '],nodeContainerSelector:'div.x-legend-container',itemSelector:'div.x-legend-item',docked:'bottom'},setDocked:function(b){var a=this,d=a.ownerCt,c;a.docked=b;switch(b){case 'top':case 'bottom':a.addCls('x-horizontal');c='hbox';break;case 'left':case 'right':a.removeCls('x-horizontal');c='vbox';break;}if(d){d.setDocked(b)}},setStore:function(a){this.bindStore(a)},clearViewEl:function(){Ext.view.View.prototype.clearViewEl.apply(this,arguments);Ext.removeNode(this.getNodeContainer())},onItemClick:function(b,c,a,d){Ext.view.View.prototype.onItemClick.apply(this,arguments);this.toggleItem(a)}},0,0,['component','box','dataview'],{'component':!0,'box':!0,'dataview':!0},0,0,[Ext.chart,'LegendBase'],0);Ext.cmd.derive('Ext.chart.Legend',Ext.chart.LegendBase,{config:{baseCls:'x-legend',padding:5,rect:null,disableSelection:!0,toggleable:!0},toggleItem:function(h){if(!this.getToggleable()){return}var b=this.getStore(),f=0,d,g=!0,c,e,a;if(b){e=b.getCount();for(c=0;c1;a=b.getAt(h);if(a){d=a.get('disabled');if(d||g){a.set('disabled',!d)}}}}},0,['legend'],['component','box','dataview','legend'],{'component':!0,'box':!0,'dataview':!0,'legend':!0},['widget.legend'],0,[Ext.chart,'Legend'],0);Ext.cmd.derive('Ext.chart.AbstractChart',Ext.draw.Container,{isChart:!0,defaultBindProperty:'store',config:{store:'ext-empty-store',theme:'default',style:null,animation:!Ext.isIE8,series:[],axes:[],legend:null,colors:null,insetPadding:{top:10,left:10,right:10,bottom:10},background:null,interactions:[],mainRect:null,resizeHandler:null,highlightItem:null},animationSuspendCount:0,chartLayoutSuspendCount:0,axisThicknessSuspendCount:0,isThicknessChanged:!1,surfaceZIndexes:{background:0,main:1,grid:2,series:3,axis:4,chart:5,overlay:6,events:7},constructor:function(b){var a=this;a.itemListeners={};a.surfaceMap={};a.chartComponents={};a.isInitializing=!0;a.suspendChartLayout();a.animationSuspendCount++;Ext.draw.Container.prototype.constructor.apply(this,arguments);delete a.isInitializing;a.getSurface('main');a.getSurface('chart').setFlipRtlText(a.getInherited().rtl);a.getSurface('overlay').waitFor(a.getSurface('series'));a.animationSuspendCount--;a.resumeChartLayout()},applyAnimation:function(a,b){if(!a){a={duration:0}}else {if(a===!0){a={easing:'easeInOut',duration:500}}}return b?Ext.apply({},a,b):a},getAnimation:function(){if(this.animationSuspendCount){return {duration:0}}else {return (arguments.callee.$previous||Ext.draw.Container.prototype.getAnimation).call(this)}},applyInsetPadding:function(a,b){if(!Ext.isObject(a)){return Ext.util.Format.parseBox(a)}else {if(!b){return a}else {return Ext.apply(b,a)}}},suspendAnimation:function(){var b=this,c=b.getSeries(),e=c.length,d=-1,a;b.animationSuspendCount++;if(b.animationSuspendCount===1){while(++d0){this.axisThicknessSuspendCount--;if(this.axisThicknessSuspendCount===0&&this.isThicknessChanged){this.onThicknessChanged()}}},onThicknessChanged:function(){if(this.axisThicknessSuspendCount===0){this.isThicknessChanged=!1;this.performLayout()}else {this.isThicknessChanged=!0}},applySprites:function(a){var b=this.getSurface('chart');a=Ext.Array.from(a);b.removeAll(!0);b.add(a);return a},initItems:function(){var a=this.items,b,d,c;if(a&&!a.isMixedCollection){this.items=[];a=Ext.Array.from(a);for(b=0,d=a.length;b=0){a.splice(c,1)}},applyAxes:function(d,h){var b=this,l={left:'right',right:'left'},f=[],a,j,g,i,c,k,e;b.animationSuspendCount++;b.getStore();if(!h){h=[];h.map={}}e=h.map;f.map={};d=Ext.Array.from(d,!0);for(c=0,k=d.length;c0){a=b.applyColors(a)}return a||c&&c.getColors()},applyColors:function(a){a=Ext.Array.map(a,function(b){if(Ext.isString(b)){return b}else {return b.toString()}});return a},updateColors:function(k){var a=this,i=a.getTheme(),h=k||i&&i.getColors(),g=0,e=a.getSeries(),j=e&&e.length,b,d,f,c;if(h.length){for(b=0;b=0&&e<=a[2]&&f>=0&&f<=a[3])){return null}for(;d>=0;d--){h=g[d];b=h.getItemForPoint(e,f);if(b){return b}}return null},getItemsForPoint:function(h,i){var f=this,c=f.getSeries(),g=c.length,b=f.hasFirstLayout?g-1:-1,e=[],d,a;for(;b>=0;b--){d=c[b];a=d.getItemForPoint(h,i);if(a){e.push(a)}}return e},onAnimationStart:function(){this.fireEvent('animationstart',this)},onAnimationEnd:function(){this.fireEvent('animationend',this)},onDataChanged:function(){var a=this;if(a.isInitializing){return}var e=a.getMainRect(),c=a.getStore(),b=a.getSeries(),d=a.getAxes();if(!c||!d||!b){return}if(!e){a.on({redraw:a.onDataChanged,scope:a,single:!0});return}a.processData();a.redraw()},recordCount:0,processData:function(){var a=this,e=a.getStore().getCount(),f=a.getSeries(),g=f.length,b=!1,d=0,c;for(;da.recordCount){a.updateColors(a.getColors());a.recordCount=e}},bindStore:function(a){this.setStore(a)},applyHighlightItem:function(a,d){if(a===d){return}if(Ext.isObject(a)&&Ext.isObject(d)){var b=a,c=d,e=b.sprite&&(b.sprite[0]||b.sprite),f=c.sprite&&(c.sprite[0]||c.sprite);if(e===f&&b.index===c.index){return}}return a},updateHighlightItem:function(a,b){if(b){b.series.setAttributesForItem(b,{highlighted:!1})}if(a){a.series.setAttributesForItem(a,{highlighted:!0});this.fireEvent('itemhighlight',this,a,b)}this.fireEvent('itemhighlightchange',this,a,b)},destroyChart:function(){var a=this,f=a.getLegend(),h=a.getAxes(),g=a.getSeries(),e=a.getInteractions(),d=[],b,c;a.surfaceMap=null;for(b=0,c=e.length;bf&&bg&&ch){b=h}}if(ci){c=i}}a.selectionRect.setAttributes({width:b-a.startX,height:c-a.startY});if(Math.abs(a.startX-b)<11||Math.abs(a.startY-c)<11){a.selectionRect.setAttributes({globalAlpha:0.5})}else {a.selectionRect.setAttributes({globalAlpha:1})}l.renderFrame();return !1}},onGestureEnd:function(o){var a=this;if(a.zoomAnimationInProgress){return}if(a.getLocks()[a.gestureEvent]===a){var d=a.getChart(),e=a.getSurface(),f=d.getInnerRect(),k=d.getInnerPadding(),i=k.left,l=i+f[2],j=k.top,m=j+f[3],h=f[2],g=f[3],n=d.getEventXY(o),b=n[0],c=n[1];if(bl){b=l}}if(cm){c=m}}if(Math.abs(a.startX-b)<11||Math.abs(a.startY-c)<11){e.remove(a.selectionRect)}else {a.zoomBy([Math.min(a.startX,b)/h,1-Math.max(a.startY,c)/g,Math.max(a.startX,b)/h,1-Math.min(a.startY,c)/g]);a.selectionRect.setAttributes({x:Math.min(a.startX,b),y:Math.min(a.startY,c),width:Math.abs(a.startX-b),height:Math.abs(a.startY-c)});a.selectionRect.setAnimation(d.getAnimation()||{duration:0});a.selectionRect.setAttributes({globalAlpha:0,x:0,y:0,width:h,height:g});a.zoomAnimationInProgress=!0;d.suspendThicknessChanged();a.selectionRect.fx.on('animationend',function(){d.resumeThicknessChanged();e.remove(a.selectionRect);a.selectionRect=null;a.zoomAnimationInProgress=!1})}e.renderFrame();a.sync();a.unlockEvents(a.gestureEvent);a.setSeriesOpacity(1);if(!a.zoomAnimationInProgress){e.remove(a.selectionRect);a.selectionRect=null}}},zoomBy:function(b){var d=this,l=d.getAxes(),j=d.getChart(),k=j.getAxes(),n=j.getInherited().rtl,e,i={},f,g;if(n){b=b.slice();f=1-b[0];g=1-b[2];b[0]=Math.min(f,g);b[2]=Math.max(f,g)}for(var h=0;h=e[b-1]){return b-1}while(a+1>1,f=e[d];if(f===c){return d}else {if(ft&&cv&&dDec: '+a._meta_dec})]);console.log(a);e.addCatalog(b)}},0,['coadd-aladin'],['component','box','container','panel','aladin','coadd-aladin'],{'component':!0,'box':!0,'container':!0,'panel':!0,'aladin':!0,'coadd-aladin':!0},['widget.coadd-aladin'],0,[Explorer.view.coadd,'Aladin'],0);Ext.cmd.derive('Explorer.view.coadd.CoaddController',Ext.app.ViewController,{listen:{component:{'coadd-objects':{loadpanel:'onLoadPanel'},'coadd-visiomatic':{changedataset:'onChangeDataset',changeimage:'onChangeImage'}},store:{'#datasets':{load:'onLoadDatasets'}}},onLoadPanel:function(a,b){this.loadProduct(a)},loadProduct:function(d){var a=this,c=a.getView(),e=a.getViewModel(),b=e.getStore('products');c.setLoading(!0);b.addFilter({property:'prd_name',value:d});b.load({callback:function(){if(this.count()===1){a.onLoadProduct(this.first());c.setLoading(!1)}}})},onLoadProduct:function(b){var a=this,d=a.getViewModel(),e=a.getView(),c=a.lookup('detailPanel');d.set('currentProduct',b);c.setTitle(b.get('prd_display_name'));a.loadAssociations(b)},loadAssociations:function(e){var a=this,c=a.getView(),d=a.getViewModel(),b=d.getStore('associations');c.setLoading(!0);b.addFilter({property:'pca_product',value:e.get('id')});b.load({callback:function(){if(this.count()>0){this.each(function(a){if(a.get('pcc_ucd')==='meta.id;meta.main'){d.set('property_id',a.get('pcn_column_name'))}},a);c.setLoading(!1);a.loadObject()}}})},loadObject:function(){var b=this,a=b.getViewModel(),d=b.getView(),g=a.get('currentProduct'),c=a.getStore('objects'),f=a.get('object_id'),e=a.get('property_id');d.setLoading(!0);c.addFilter([{property:'product',value:g.get('id')},{property:e,value:f}]);c.load({callback:function(){if(this.count()===1){b.onLoadObject(this.first());d.setLoading(!1)}}})},onLoadObject:function(h){var b=this,c=b.getViewModel(),i=b.lookupReference('properties-grid'),d=c.getStore('properties'),g=c.getStore('datasets'),l=b.lookupReference('aladin'),k=b.getView(),a,e;d.removeAll();a=h.data;for(var f in a){var j=f.toLowerCase();if(j.indexOf('_meta_')===-1){d.add([[f.toLowerCase(),a[f]]])}}c.set('object_data',a);i.setStore(d);e=String(a._meta_ra)+','+String(a._meta_dec);g.addFilter([{property:'position',value:e}]);c.set('position',e);b.loadSpectralDistribution();k.setLoading(!1)},onLoadDatasets:function(a){var c=this,d=c.lookupReference('visiomatic'),b=d.lookupReference('cmbCurrentDataset');if(a.count()==1){c.changeImage(a.first());b.select(a.first());b.setReadOnly(!0)}else {if(a.count()>1){c.changeImage(a.first());b.select(a.first());b.setReadOnly(!1)}else {console.log('Nenhuma tile encontrada para o objeto')}}},changeImage:function(b){var d=this,a=d.lookupReference('visiomatic'),c=b.get('image_src_ptif');if(b){if(c!==''){a.setImage(c)}else {a.removeImageLayer()}}else {console.log('dataset nao encontrado')}},onChangeDataset:function(a){var b=this;b.changeImage(a);b.loadSurveys(a.get('release'));b.loadTags(a.get('release'))},onChangeImage:function(){var b=this,e=b.getViewModel(),a=e.get('object_data'),c=b.lookupReference('visiomatic'),d=0.03;c.setView(a._meta_ra,a._meta_dec,d)},loadSurveys:function(c){var b=this,d=b.getViewModel(),a=d.getStore('surveys');a.addFilter([{property:'srv_project',value:'DES'},{property:'srv_release',value:c}]);a.load({callback:function(){b.onLoadSurvey(this)}})},onLoadSurvey:function(e){var b=this,a=b.lookupReference('aladin'),c=b.getViewModel().get('position'),d=b.getViewModel().get('object_data');a.goToPosition(c);a.setFov(180);a.plotObject(d)},onSearch:function(a){var b=this,d=b.getViewModel(),c=d.getStore('properties');if(a!==''){c.filter([{property:'property',value:a}])}else {b.onSearchCancel()}},onSearchCancel:function(){var b=this,c=b.getViewModel(),a=c.getStore('properties');a.clearFilter()},loadTags:function(a){var c=this,d=c.getViewModel(),b=d.getStore('tags');if(a>0){b.addFilter([{property:'tag_release',value:a}]);b.load({callback:function(){c.onLoadTags(this)}})}},onLoadTags:function(a){var b=this;if(a.count()>0){b.loadTiles()}},loadTiles:function(){var e=this,b=e.getViewModel(),d=b.getStore('tags'),c=b.getStore('tiles'),a=[];d.each(function(b){a.push(b.get('id'))},this);c.filter([{property:'tag',operator:'in',value:a}])},onClickSimbad:function(){console.log('onClickSimbad()');var d=this,e=d.getViewModel(),a=e.get('object_data'),c=0.1,b;b=Ext.String.format('http://simbad.u-strasbg.fr/simbad/sim-coo?Coord={0}+{1}&CooFrame=FK5&CooEpoch=2000&Radius={2}&Radius.unit=arcmin&submit=submit+query',a._meta_ra,a._meta_dec,c);window.open(b,'_blank')},onClickNed:function(){console.log('onClickNed');var d=this,e=d.getViewModel(),a=e.get('object_data'),c=0.1,b;b=Ext.String.format('https://ned.ipac.caltech.edu/cgi-bin/objsearch?search_type=Near+Position+Search&in_csys=Equatorial&in_equinox=J2000.0&lon={0}d&lat={1}d&radius={2}',a._meta_ra,a._meta_dec,c);window.open(b,'_blank')},onClickVizier:function(){console.log('onClickVizier');var d=this,e=d.getViewModel(),a=e.get('object_data'),c=0.01,b;b=Ext.String.format('http://vizier.u-strasbg.fr/viz-bin/VizieR-5?-source=II/246&-c={0},{1},eq=J2000&-c.rs={2}',a._meta_ra,a._meta_dec,c);window.open(b,'_blank')},loadSpectralDistribution:function(){var k=this,g=k.getViewModel(),e=g.get('object_data'),j=g.getStore('spectral'),f=['mag_auto_g','mag_auto_r','mag_auto_i','mag_auto_z','mag_auto_y'],h=[474,645.5,783.5,926,1008],d,a,b,m,l;for(var i in e){var c=i.toLowerCase();if(f.indexOf(c)!==-1){a=parseFloat(parseFloat(e[c]).toFixed(2));if(parseInt(a)!==99&&parseInt(a)!==0){b=-0.4*a;b=parseFloat(b.toFixed(1))}d=h[f.indexOf(c)];j.add({flux:b,mag_auto:a,wavelength:d,property:c})}}}},0,0,0,0,['controller.coadd'],0,[Explorer.view.coadd,'CoaddController'],0);Ext.cmd.derive('Explorer.view.coadd.CoaddModel',Ext.app.ViewModel,{data:{source:null,object_id:null,object_data:null,property_id:null,position:null},links:{currentProduct:{type:'Explorer.model.Product',create:!0},currentDataset:{type:'common.model.Dataset',create:!0}},stores:{products:{type:'products'},associations:{type:'association'},objects:{type:'objects'},properties:{type:'array',fields:['property','value'],remoteSort:!1,remoteFilter:!1,sorters:[{property:'property',direction:'ASC'}]},datasets:{type:'datasets',storeId:'datasets',remoteSort:!1,sorters:[{property:'id',direction:'DESC'}]},surveys:{type:'surveys'},tags:{type:'tags',storeId:'Tags'},tiles:{type:'footprints',pageSize:0},spectral:{type:'spectral-distribution'}}},0,0,0,0,['viewmodel.coadd'],0,[Explorer.view.coadd,'CoaddModel'],0);Ext.cmd.derive('Explorer.view.coadd.Form',Ext.form.Panel,{initComponent:function(){var a=this;Ext.apply(this,{fieldDefaults:{labelAlign:'top',readOnly:!0},items:[{xtype:'fieldset',defaultType:'textfield',defaults:{anchor:'100%'},items:[{fieldLabel:'Source',bind:{value:'{currentProduct.tablename}'}},{fieldLabel:'Object ID',bind:{value:'{object_data._meta_id}'}},{fieldLabel:'RA, Dec (deg)',bind:{value:'{object_data._meta_ra}, {object_data._meta_dec}'}}]}]});Ext.form.Panel.prototype.initComponent.apply(this,arguments)}},0,['coadd-form'],['component','box','container','panel','form','coadd-form'],{'component':!0,'box':!0,'container':!0,'panel':!0,'form':!0,'coadd-form':!0},['widget.coadd-form'],0,[Explorer.view.coadd,'Form'],0);Ext.cmd.derive('Explorer.view.coadd.Properties',Ext.grid.Panel,{initComponent:function(){var a=this;Ext.apply(this,{columns:[{text:'Property',dataIndex:'property',width:200},{text:'Value',dataIndex:'value',renderer:this.formatNumber,flex:1}],tbar:[{xtype:'common-searchfield',minSearch:1,listeners:{'search':'onSearch','cancel':'onSearchCancel'},flex:1}]});Ext.grid.Panel.prototype.initComponent.apply(this,arguments)},formatNumber:function(a){if(typeof a==='number'){if(!isNaN(a)&&a.toString().indexOf('.')!=-1){a=a.toFixed(4)}}return a}},0,['coadd-properties'],['component','box','container','panel','tablepanel','gridpanel','grid','coadd-properties'],{'component':!0,'box':!0,'container':!0,'panel':!0,'tablepanel':!0,'gridpanel':!0,'grid':!0,'coadd-properties':!0},['widget.coadd-properties'],0,[Explorer.view.coadd,'Properties'],0);Ext.cmd.derive('Explorer.view.coadd.Visiomatic',visiomatic.Visiomatic,{enableTools:!1,initComponent:function(){var a=this;Ext.apply(this,{tbar:[{xtype:'combobox',reference:'cmbCurrentDataset',publishes:'id',width:250,displayField:'release_tag',bind:{store:'{datasets}',disabled:'{!coadd.COADD_OBJECT_ID}',selection:'{!currentDataset}'},queryMode:'local',listConfig:{itemTpl:['
    {release_display_name} - {tag_display_name}
    ']},listeners:{scope:this,change:'changeDataset'}},{xtype:'textfield',width:120,readOnly:!0,bind:{value:'{currentDataset.tli_tilename}'}}]});visiomatic.Visiomatic.prototype.initComponent.apply(this,arguments)},changeDataset:function(a){this.fireEvent('changedataset',a.getSelectedRecord(),this)}},0,['coadd-visiomatic'],['component','box','container','panel','visiomatic','coadd-visiomatic'],{'component':!0,'box':!0,'container':!0,'panel':!0,'visiomatic':!0,'coadd-visiomatic':!0},['widget.coadd-visiomatic'],0,[Explorer.view.coadd,'Visiomatic'],0);Ext.cmd.derive('Explorer.view.coadd.SpectralDistribution',Ext.chart.CartesianChart,{innerPadding:20,insetPadding:{top:40,right:20,bottom:20,left:20},sprites:[{type:'text',text:'Spectral Distribution',fontSize:22,width:100,height:30,x:40,y:20}],axes:[{type:'numeric',fields:['flux'],title:'log(Flux) [counts]',position:'left',grid:!0},{id:'wavelength-axis',type:'category',title:'Wavelength [nm]',fields:'wavelength',position:'bottom',grid:!0}],series:[{type:'scatter',xField:'wavelength',yField:'flux',marker:{type:'circle',fill:'#3333ff',radius:8,lineWidth:0},highlight:{radius:12,lineWidth:2},tooltip:{trackMouse:!0,renderer:function(b,a,c){b.setHtml(a.get('property')+': '+a.get('mag_auto'))}}}]},0,['coadd-spectral-distribution'],['component','box','container','panel','draw','cartesian','chart','coadd-spectral-distribution'],{'component':!0,'box':!0,'container':!0,'panel':!0,'draw':!0,'cartesian':!0,'chart':!0,'coadd-spectral-distribution':!0},['widget.coadd-spectral-distribution'],0,[Explorer.view.coadd,'SpectralDistribution'],0);Ext.cmd.derive('Explorer.view.coadd.Coadd',Ext.panel.Panel,{controller:'coadd',viewModel:'coadd',layout:'fit',initComponent:function(){var a=this;Ext.apply(this,{layout:{type:'hbox',pack:'start',align:'stretch'},defaults:{frame:!0},items:[{xtype:'panel',reference:'detailPanel',width:300,margin:'0 10 0 0',layout:{type:'vbox',pack:'start',align:'stretch'},items:[{xtype:'coadd-form',reference:'properties-form',split:!0,bbar:[{xtype:'button',text:'SIMBAD',handler:'onClickSimbad'},{xtype:'button',text:'NED',handler:'onClickNed'}]},{xtype:'coadd-properties',reference:'properties-grid',split:!0,flex:1}]},{xtype:'panel',flex:1,layout:{type:'vbox',pack:'start',align:'stretch'},margin:'0 0 10 0',defaults:{frame:!0},items:[{xtype:'panel',height:500,layout:{type:'hbox',pack:'start',align:'stretch'},defaults:{frame:!0},items:[{xtype:'coadd-visiomatic',reference:'visiomatic',margin:'0 10 0 0',split:!0,flex:1},{xtype:'coadd-aladin',reference:'aladin',split:!0,flex:1,bind:{storeSurveys:'{surveys}',storeTags:'{tags}',storeTiles:'{tiles}'}}]},{xtype:'panel',flex:1,layout:{type:'hbox',pack:'start',align:'stretch'},items:[{xtype:'coadd-spectral-distribution',reference:'SpectralChart',flex:1,bind:{store:'{spectral}'}},{xtype:'panel',flex:1}]}]}]});Ext.panel.Panel.prototype.initComponent.apply(this,arguments)},loadPanel:function(b){var a=this,e=a.getViewModel(),d=b[1],c=b[2];e.set('source',d);e.set('object_id',c);a.fireEvent('loadpanel',d,c,a)},updatePanel:function(a){}},0,['coadd-objects'],['component','box','container','panel','coadd-objects'],{'component':!0,'box':!0,'container':!0,'panel':!0,'coadd-objects':!0},['widget.coadd-objects'],0,[Explorer.view.coadd,'Coadd'],0);Ext.cmd.derive('Explorer.view.system.SystemController',Ext.app.ViewController,{listen:{component:{'system':{loadpanel:'onLoadPanel'},'system-visiomatic':{changedataset:'onChangeDataset',changeimage:'onChangeImage'}},store:{'#datasets':{load:'onLoadDatasets'}}},onLoadPanel:function(a,b){this.load(a)},load:function(a){var b=this;b.loadProduct(a)},loadProduct:function(d){var a=this,c=a.getView(),e=a.getViewModel(),b=e.getStore('products');c.setLoading(!0);b.addFilter({property:'prd_name',value:d});b.load({callback:function(){if(this.count()===1){a.onLoadProduct(this.first());c.setLoading(!1)}}})},onLoadProduct:function(b){var a=this,d=a.getViewModel(),e=a.getView(),c=a.lookup('detailPanel');d.set('currentProduct',b);c.setTitle(b.get('prd_display_name'));a.loadAssociations(b);a.loadMembersContent(b)},loadAssociations:function(e){var a=this,c=a.getView(),d=a.getViewModel(),b=d.getStore('associations');c.setLoading(!0);b.addFilter({property:'pca_product',value:e.get('id')});b.load({callback:function(){if(this.count()>0){this.each(function(a){if(a.get('pcc_ucd')==='meta.id;meta.main'){d.set('property_id',a.get('pcn_column_name'))}},a);c.setLoading(!1);a.loadObject()}}})},loadObject:function(){var b=this,a=b.getViewModel(),d=b.getView(),g=a.get('currentProduct'),c=a.getStore('objects'),f=a.get('object_id'),e=a.get('property_id');d.setLoading(!0);c.addFilter([{property:'product',value:g.get('id')},{property:e,value:f}]);c.load({callback:function(){if(this.count()===1){b.onLoadObject(this.first());d.setLoading(!1)}}})},onLoadObject:function(g){var c=this,b=c.getViewModel(),i=c.getView(),k=c.lookupReference('properties-grid'),d=b.getStore('properties'),h=b.get('currentProduct'),j=b.getStore('datasets'),m=c.lookupReference('aladin'),a,e;i.setLoading(!0);b.set('object',g);d.removeAll();a=g.data;b.set('object_data',a);for(var f in a){var l=f.toLowerCase();if(l.indexOf('_meta_')===-1){d.add([[f.toLowerCase(),a[f]]])}}k.setStore(d);e=String(a._meta_ra)+','+String(a._meta_dec);j.addFilter([{property:'position',value:e}]);b.set('position',e);i.setLoading(!1);if(h.get('prl_related')>0){c.loadSystemMembers(h,g)}},onLoadDatasets:function(a){var c=this,d=c.lookupReference('visiomatic'),b=d.lookupReference('cmbCurrentDataset');if(a.count()==1){c.changeImage(a.first());b.select(a.first());b.setReadOnly(!0)}else {if(a.count()>1){c.changeImage(a.first());b.select(a.first());b.setReadOnly(!1)}else {console.log('Nenhuma tile encontrada para o objeto')}}},changeImage:function(b){var d=this,a=d.lookupReference('visiomatic'),c=b.get('image_src_ptif');if(b){if(c!==''){a.setImage(c)}else {a.removeImageLayer()}}else {console.log('dataset nao encontrado')}},onChangeDataset:function(a){var b=this;b.changeImage(a);b.loadSurveys(a.get('release'));b.loadTags(a.get('release'))},onChangeImage:function(){var b=this,d=b.getViewModel(),f=d.get('currentProduct'),a=d.get('object'),c=b.lookupReference('visiomatic'),g=b.lookupReference('aladin'),e=d.getStore('members');fov=0.07;c.setView(a.get('_meta_ra'),a.get('_meta_dec'),fov);c.drawRadius(a.get('_meta_ra'),a.get('_meta_dec'),a.get('_meta_radius'),'arcmin');c.showHideRadius(!0);b.onLoadSystemMembers(e)},loadSurveys:function(c){var b=this,d=b.getViewModel(),a=d.getStore('surveys');a.addFilter([{property:'srv_project',value:'DES'},{property:'srv_release',value:c}]);a.load({callback:function(){b.onLoadSurvey(this)}})},onLoadSurvey:function(e){var c=this,a=c.lookupReference('aladin'),d=c.getViewModel().get('position'),b=c.getViewModel().get('object_data');a.goToPosition(d);a.setFov(180);a.drawRadius(b._meta_ra,b._meta_dec,b._meta_radius,'arcmin')},onSearch:function(a){var b=this,d=b.getViewModel(),c=d.getStore('properties');if(a!==''){c.filter([{property:'property',value:a}])}else {b.onSearchCancel()}},onSearchCancel:function(){var b=this,c=b.getViewModel(),a=c.getStore('properties');a.clearFilter()},loadMembersContent:function(d){var b=this,e=b.getViewModel(),a=e.getStore('displayContents'),c=b.lookupReference('members-grid');a.addFilter({'property':'pcn_product_id',value:d.get('prl_related')});a.load({callback:function(){if(this.check_ucds()){c.reconfigureGrid(this)}}})},loadSystemMembers:function(b,d){var c=this,e=c.getViewModel(),a=e.getStore('members');a.addFilter([{property:'product',value:b.get('prl_related')},{property:b.get('prl_cross_property'),value:d.get('id')}]);a.load({callback:function(){c.onLoadSystemMembers(this)}})},onLoadSystemMembers:function(d){var b=this,e=b.getViewModel(),c=b.lookupReference('visiomatic'),f=b.lookupReference('aladin'),a;a=c.overlayCatalog('sytem_members',d);c.showHideLayer(a,!0);e.set('overlayMembers',a);f.plotSystemMembers('system_members',d);e.set('have_members',!0)},onSelectSystemMember:function(b,a){this.highlightSystemMember(a)},highlightSystemMember:function(a,i){var e=this,b=e.getViewModel(),j=b.get('currentProduct'),k=b.get('object'),c=b.get('lMarkPosition'),d=e.lookupReference('visiomatic'),g=e.lookupReference('aladin'),h=d.getFov(),l=e.lookup('members-grid'),f;d.setView(a.get('_meta_ra'),a.get('_meta_dec'),h,!0);if(c){d.showHideLayer(c,!1)}c=d.markPosition(a.get('_meta_ra'),a.get('_meta_dec'),'x-fa fa-sort-desc fa-2x');b.set('lMarkPosition',c);f=String(a.get('_meta_ra'))+','+String(a.get('_meta_dec'));g.goToPosition(f);b.set('selected_member',a)},loadTags:function(a){var c=this,d=c.getViewModel(),b=d.getStore('tags');if(a>0){b.addFilter([{property:'tag_release',value:a}]);b.load({callback:function(){c.onLoadTags(this)}})}},onLoadTags:function(a){var b=this;if(a.count()>0){b.loadTiles()}},loadTiles:function(){var e=this,b=e.getViewModel(),d=b.getStore('tags'),c=b.getStore('tiles'),a=[];d.each(function(b){a.push(b.get('id'))},this);c.filter([{property:'tag',operator:'in',value:a}])},parseRA:function(a){if(a<0){return a+360}return a},onClickSimbad:function(){var c=this,e=c.getViewModel(),a=e.get('object_data'),d=2,b;b=Ext.String.format('http://simbad.u-strasbg.fr/simbad/sim-coo?Coord={0}+{1}&CooFrame=FK5&CooEpoch=2000&Radius={2}&Radius.unit=arcmin&submit=submit+query',c.parseRA(a._meta_ra),a._meta_dec,d);window.open(b,'_blank')},onClickNed:function(){var c=this,e=c.getViewModel(),a=e.get('object_data'),d=2,b;b=Ext.String.format('https://ned.ipac.caltech.edu/cgi-bin/objsearch?search_type=Near+Position+Search&in_csys=Equatorial&in_equinox=J2000.0&lon={0}d&lat={1}d&radius={2}',c.parseRA(a._meta_ra),a._meta_dec,d);window.open(b,'_blank')},onClickVizier:function(){var c=this,e=c.getViewModel(),a=e.get('object_data'),d=2,b;b=Ext.String.format('http://vizier.u-strasbg.fr/viz-bin/VizieR-5?-source=II/246&-c={0},{1},eq=J2000&-c.rs={2}',c.parseRA(a._meta_ra),a._meta_dec,d);window.open(b,'_blank')},onCmdClickPoint:function(a,b){this.highlightSystemMember(a,!0)}},0,0,0,0,['controller.system'],0,[Explorer.view.system,'SystemController'],0);Ext.cmd.derive('Explorer.view.system.SystemModel',Ext.app.ViewModel,{data:{source:null,object_id:null,object:null,object_data:null,property_id:null,overlayMembers:null,position:null,have_members:!1,selected_member:null},links:{currentProduct:{type:'Explorer.model.Product',create:!0},currentDataset:{type:'common.model.Dataset',create:!0}},stores:{products:{type:'products'},associations:{type:'association'},objects:{type:'objects'},members:{type:'objects'},displayContents:{type:'product-display-contents'},properties:{type:'array',fields:['property','value'],remoteSort:!1,remoteFilter:!1,sorters:[{property:'property',direction:'ASC'}]},datasets:{type:'datasets',storeId:'datasets',remoteSort:!1,sorters:[{property:'id',direction:'DESC'}]},surveys:{type:'surveys'},tags:{type:'tags',storeId:'Tags'},tiles:{type:'footprints',pageSize:0}}},0,0,0,0,['viewmodel.system'],0,[Explorer.view.system,'SystemModel'],0);Ext.cmd.derive('Explorer.view.system.Form',Ext.form.Panel,{initComponent:function(){var a=this;Ext.apply(this,{fieldDefaults:{labelAlign:'top',readOnly:!0},items:[{xtype:'fieldset',defaultType:'textfield',defaults:{anchor:'100%'},items:[{fieldLabel:'Source',bind:{value:'{currentProduct.tablename}'}},{fieldLabel:'Object ID',bind:{value:'{object_data._meta_id}'}},{fieldLabel:'RA, Dec (deg)',bind:{value:'{object_data._meta_ra}, {object_data._meta_dec}'}},{fieldLabel:'Radius (arcmin)',bind:{value:'{object_data._meta_radius}'}}]}]});Ext.form.Panel.prototype.initComponent.apply(this,arguments)}},0,['system-form'],['component','box','container','panel','form','system-form'],{'component':!0,'box':!0,'container':!0,'panel':!0,'form':!0,'system-form':!0},['widget.system-form'],0,[Explorer.view.system,'Form'],0);Ext.cmd.derive('Explorer.view.system.Properties',Ext.grid.Panel,{initComponent:function(){var a=this;Ext.apply(this,{columns:[{text:'Property',dataIndex:'property',flex:1},{text:'Value',dataIndex:'value',renderer:this.formatNumber,flex:1}],tbar:[{xtype:'common-searchfield',minSearch:1,listeners:{'search':'onSearch','cancel':'onSearchCancel'},flex:1}]});Ext.grid.Panel.prototype.initComponent.apply(this,arguments)},formatNumber:function(a){if(typeof a==='number'){if(!isNaN(a)&&a.toString().indexOf('.')!=-1){a=a.toFixed(4)}}return a}},0,['system-properties'],['component','box','container','panel','tablepanel','gridpanel','grid','system-properties'],{'component':!0,'box':!0,'container':!0,'panel':!0,'tablepanel':!0,'gridpanel':!0,'grid':!0,'system-properties':!0},['widget.system-properties'],0,[Explorer.view.system,'Properties'],0);Ext.cmd.derive('Explorer.view.system.Visiomatic',visiomatic.Visiomatic,{enableTools:!0,enableLink:!1,enableShift:!1,showCrosshair:!0,initComponent:function(){var a=this;Ext.apply(this,{auxTools:[{xtype:'combobox',reference:'cmbCurrentDataset',publishes:'id',width:250,displayField:'release_tag',bind:{store:'{datasets}',disabled:'{!coadd.COADD_OBJECT_ID}',selection:'{!currentDataset}'},queryMode:'local',listConfig:{itemTpl:['
    {release_display_name} - {tag_display_name}
    ']},listeners:{scope:this,change:'changeDataset'}},{xtype:'textfield',width:120,readOnly:!0,bind:{value:'{currentDataset.tli_tilename}'}},{xtype:'button',iconCls:'x-fa fa-crosshairs',tooltip:'Show/Hide Crosshair',enableToggle:!0,pressed:!0,scope:this,toggleHandler:'onShowHideCrosshair'}]});visiomatic.Visiomatic.prototype.initComponent.apply(this,arguments)},changeDataset:function(a){this.fireEvent('changedataset',a.getSelectedRecord(),this)},onShowHideCrosshair:function(c,a){var b=this;b.setShowCrosshair(a)}},0,['system-visiomatic'],['component','box','container','panel','visiomatic','system-visiomatic'],{'component':!0,'box':!0,'container':!0,'panel':!0,'visiomatic':!0,'system-visiomatic':!0},['widget.system-visiomatic'],0,[Explorer.view.system,'Visiomatic'],0);Ext.cmd.derive('Explorer.view.system.Aladin',aladin.Aladin,{initComponent:function(){var a=this;Ext.apply(this,{hideFootprint:!1,enableGoto:!1,enableShift:!1,infoEnabled:!1,enableLayersControl:!1,toolbarPosition:'top',showFilters:!1});aladin.Aladin.prototype.initComponent.apply(this,arguments)},plotObject:function(a,e){var d=this,f=d.getAladin(),c=d.libA,b;b=c.catalog({name:e,sourceSize:12,color:'#A0F65A'});b.addSources([c.marker(a._meta_ra,a._meta_dec,{popupTitle:'ID: '+a._meta_id,popupDesc:'RA: '+a._meta_ra+'
    Dec: '+a._meta_dec})]);f.addCatalog(b)},plotSystemMembers:function(e,f){var b=this,g=b.getAladin(),d=b.libA,c=[],a;a=d.catalog({name:e,sourceSize:12,color:'#A0F65A'});f.each(function(a){var b=d.marker(a.get('_meta_ra'),a.get('_meta_dec'),{popupTitle:'ID: '+a.get('_meta_id'),popupDesc:'J2000: '+a.get('_meta_ra')+', '+a.get('_meta_dec')});c.push(b)},b);a.addSources(c);g.addCatalog(a)},drawRadius:function(a,d,c,h,i){var f=this,g=f.getAladin(),e=f.libA,b;a=parseFloat(a);d=parseFloat(d);if(a<0){a=a+360}b=e.graphicOverlay({color:'#ee2345',lineWidth:3});g.addOverlay(b);if(h==='arcmin'){c=c/60}b.add(e.circle(a,d,c))}},0,['system-aladin'],['component','box','container','panel','aladin','system-aladin'],{'component':!0,'box':!0,'container':!0,'panel':!0,'aladin':!0,'system-aladin':!0},['widget.system-aladin'],0,[Explorer.view.system,'Aladin'],0);Ext.cmd.derive('Explorer.view.system.MembersGrid',Ext.grid.Panel,{config:{ready:!1,columnRating:!1,columnAccept:!1,columnComments:!1},emptyText:'No data to dysplay.',initComponent:function(){var a=this;Ext.apply(this,{enableLocking:!0,syncRowHeight:!0,columns:[Ext.create('Ext.grid.RowNumberer'),{text:'',dataIndex:'',width:50},{text:'',dataIndex:'',flex:!0}],viewConfig:{stripeRows:!0,markDirty:!1,getRowClass:function(a){return a.get('_meta_reject')===!0?'rejected-row':''}}});Ext.grid.Panel.prototype.initComponent.apply(this,arguments)},reconfigureGrid:function(d){var a=this,b=[],c;b.push(Ext.create('Ext.grid.RowNumberer',{width:50,resizable:!0,locked:!0}));if(d.count()>0){c=!1;d.each(function(f){if(f.get('is_visible')){var e={text:a.createColumnText(f),dataIndex:f.get('column_name').toLowerCase(),tooltip:a.createColumnTooltip(f),renderer:a.formatNumber,lockable:!0};if(f.get('ucd')=='meta.id;meta.main'){e.locked=!0;e.lockable=!0;e.renderer=null;c=!0}if(f.get('column_name').toLowerCase()=='tilename'){e.width=120}if(f.get('ucd')==='pos.eq.ra;meta.main'||f.get('ucd')==='pos.eq.dec;meta.main'){e.width=90;e.xtype='numbercolumn';e.format='0.000';e.renderer=null;e.locked=!0;e.lockable=!0}if(f.get('ucd')==='phys.angSize;src'){e.width=80;e.xtype='numbercolumn';e.format='0.000';e.renderer=null;e.lockable=!0}b.push(e)}},this);if(a.getColumnRating()&&c===!0){b.push({xtype:'widgetcolumn',width:90,sortable:!0,text:'Rating',dataIndex:'_meta_rating',tooltip:'Rating',widget:{xtype:'rating',minimum:0,scale:'115%',selectedStyle:'color: rgb(96, 169, 23);',style:{'color':'#777777'}}})}if(a.getColumnAccept()&&c===!0){b.push({xtype:'checkcolumn',text:'Reject',dataIndex:'_meta_reject',tooltip:'Reject',sortable:!0,width:80})}if(a.getColumnComments()&&c===!0){b.push({text:'Comments',dataIndex:'_meta_comments',tooltip:'Comments',align:'center',flex:1,sortable:!1,minWidth:80,renderer:function(b,c,e){var a='';if(b>0){if(b==1){a=' '}else {a=''}}return a}})}}else {b.push({text:'Placeholder',dataIndex:'',hidden:!0})}a.reconfigure(null,b);a.setReady(!0);this.fireEvent('ready',this)},getTypeColumn:function(a){switch(a){case 'integer':case 'real':case 'double precision':case 'bigint':case 'smallint':return 'number';break;case 'text':return 'string';break;}},createColumnText:function(a){var c=a.get('unit'),b=a.get('display_name');var d=c!=''?Ext.String.format('{0} ( {1} )',b,c):b;return d},createColumnTooltip:function(a){var b=new Ext.XTemplate('
    ','

    {display_name}

    ','','

    Name: {column_name}

    ','
    ','','

    Unit: {unit}

    ','
    ','','

    ucd: {ucd}

    ','
    ','','

    Reference: {reference}

    ','
    ','
    ');return b.apply(a.data)},formatNumber:function(a){var b=3,d,c;if(typeof a==='number'){if(a>10000){a=a.toExponential(1)}else {if(a.toString().indexOf('.')!=-1){d=a.toString().split('.');c=d[1];if(c.length>b){a=a.toFixed(b)}}}}return a}},0,['system-members-grid'],['component','box','container','panel','tablepanel','gridpanel','grid','system-members-grid'],{'component':!0,'box':!0,'container':!0,'panel':!0,'tablepanel':!0,'gridpanel':!0,'grid':!0,'system-members-grid':!0},['widget.system-members-grid'],0,[Explorer.view.system,'MembersGrid'],0);Ext.cmd.derive('Explorer.view.system.D3SvgComponent',Ext.Component,{title:'D3 Js',config:{baseCls:'x-d3',svgMargin:{top:50,left:50,right:50,bottom:50},legend:{width:0,height:0,y:20,iconSize:20},store:null,xAxisTitle:null,yAxisTitle:null,plotTitle:null,ready:!1},d3:null,resizeDelay:250,resizeTimerId:0,size:null,defs:null,wrapper:null,wrapperClipRect:null,wrapperClipId:'wrapper-clip',svg:null,defaultCls:{wrapper:'x-d3-wrapper',scene:'x-d3-scene',hidden:'x-d3-hidden'},proportionalSize:!0,scene:null,sceneRect:null,initComponent:function(){var a=this;Ext.Component.prototype.initComponent.apply(this,arguments);if(window.d3){a.d3=window.d3;a.on('resize','onElementResize',a)}else {console.log('window.d3 ainda nao esta carregada, incluir no app.json a biblioteca D3JS')}},onElementResize:function(a,b){this.handleResize(this.getSize())},handleResize:function(b,d){var a=this,c=a.getEl();if(!(c&&(b=b||c.getSize())&&b.width&&b.height)){return}clearTimeout(a.resizeTimerId);if(d){a.resizeTimerId=0}else {a.resizeTimerId=Ext.defer(a.handleResize,a.resizeDelay,a,[b,!0]);return}a.resizeHandler(b);a.size=b},resizeHandler:function(f){var a=this,l=a.getSvg(),c=a.getSvgMargin(),k=a.getInherited().rtl,j=a.getWrapper(),i=a.getWrapperClipRect(),h=a.getScene(),e=f&&f.width,d=f&&f.height,g=a.getLegend(),b;if(!(e&&d)){return}a.clearScene();if(a.proportionalSize){e=d+g.width}l.attr('width',e).attr('height',d);b=a.sceneRect||(a.sceneRect={});b.x=k?c.right:c.left;b.y=c.top;b.width=e-c.left-c.right-g.width;b.height=d-c.top-c.bottom;j.attr('transform','translate('+b.x+','+b.y+')');i.attr('width',b.width).attr('height',b.height);a.sceneRect=b;a.onSceneResize(h,b);a.fireEvent('sceneresize',a,h,b)},getSvg:function(){var a=this,b=a.getEl();return a.svg||(a.svg=a.d3.select(b.dom).append('svg').attr('version','1.1'))},getWrapper:function(){var a=this,b=a.wrapper;if(!b){b=a.wrapper=a.getSvg().append('g').classed(a.defaultCls.wrapper,!0)}return b},getWrapperClipRect:function(){var a=this,b=a.wrapperClipRect;if(!b){b=a.wrapperClipRect=a.getDefs().append('clipPath').attr('id',a.wrapperClipId).append('rect').attr('fill','white')}return b},getDefs:function(){var a=this.defs;if(!a){a=this.defs=this.getSvg().append('defs')}return a},getScene:function(){var a=this,c=a.getWrapper(),b=a.scene;if(!b){a.scene=b=c.append('g').classed(a.defaultCls.scene,!0);a.setupScene(b);a.fireEvent('scenesetup',a,b)}return b},setupScene:Ext.emptyFn,destroy:function(){this.getSvg().remove();Ext.Component.prototype.destroy.call(this)},clearScene:function(){var c=this,a=c.scene,b=c.defs;if(a){a=a.node();a.removeAttribute('transform');while(a.firstChild){a.removeChild(a.firstChild)}}if(b){b=b.node();while(b.firstChild){b.removeChild(b.firstChild)}}},onSceneResize:function(b,c){var a=this;a.setReady(!0);a.performLayout(b,c)},performLayout:Ext.emptyFn,showScene:function(){this.scene&&this.scene.classed(this.defaultCls.hidden,!1)},hideScene:function(){this.scene&&this.scene.classed(this.defaultCls.hidden,!0)},applyPadding:function(a,c){var b;if(!Ext.isObject(a)){b=Ext.util.Format.parseBox(a)}else {if(!c){b=a}else {b=Ext.apply(c,a)}}return b},setStore:function(a){this.store=a},setPlotTitle:function(b){var a=this;a.plotTitle=b;if(a.getReady()){a.createPlotTitle()}},setXAxisTitle:function(b){var a=this;a.xAxisTitle=b;if(a.getReady()){a.createAxisTitles()}},setYAxisTitle:function(b){var a=this;a.yAxisTitle=b;if(a.getReady()){a.createAxisTitles()}},createAxisTitles:function(){var a=this,f=a.getScene(),e=a.getSvgMargin(),b=a.sceneRect,c=a.getXAxisTitle(),d=a.getYAxisTitle(),g='xAxisTitle-'+a.getId(),h='yAxisTitle-'+a.getId();a.d3.select('#'+g).remove();a.d3.select('#'+h).remove();if(c){f.append('text').attr('id',g).attr('transform','translate('+b.width/2+' ,'+(b.height+e.bottom/2)+')').attr('dy','1em').style('text-anchor','middle').text(c)}if(d){f.append('text').attr('id',h).attr('transform','rotate(-90)').attr('y',0-e.left).attr('x',0-b.height/2).attr('dy','1em').style('text-anchor','middle').text(d)}},createPlotTitle:function(){var a=this,e=a.getScene(),d=a.getSvgMargin(),f=a.sceneRect,b=a.getPlotTitle(),c='plotTitle-'+a.getId();title=a.d3.select('#'+c);if(title){title.remove()}if(b){e.append('text').attr('id',c).attr('x',f.width/2).attr('y',0-d.top/2).attr('text-anchor','middle').style('font-size','1.2em').text(b)}}},0,0,['component','box'],{'component':!0,'box':!0},0,0,[Explorer.view.system,'D3SvgComponent'],0);Ext.cmd.derive('Explorer.view.system.SpatialDistribution',Explorer.view.system.D3SvgComponent,{},0,['system-spatial-distribution'],['component','box','system-spatial-distribution'],{'component':!0,'box':!0,'system-spatial-distribution':!0},['widget.system-spatial-distribution'],0,[Explorer.view.system,'SpatialDistribution'],0);Ext.cmd.derive('Explorer.view.system.ZDistribution',Explorer.view.system.D3SvgComponent,{plotTitle:'z Distribution',xAxisTitle:'Redshift',yAxisTitle:'N',proportionalSize:!1,performLayout:function(b,e){console.log('performLayout(%o, %o)',b,e);var a=this,i=e.width,f=e.height,d=a.processData(a.getStore()),k=a.getSvgMargin();var c=d3.scaleLinear().domain([d3.min(d),d3.max(d)]).range([0,i]);var g=d3.histogram().domain(c.domain()).thresholds(c.ticks(15))(d);var h=d3.scaleLinear().domain([0,d3.max(g,function(a){return a.length})]).range([f,0]);var j=d3.line().x(function(a,d){return c(a.x0)}).y(function(a,c){return h(a.length)}).curve(d3.curveStepAfter);b.append('g').attr('class','axis axis--x').attr('transform','translate(0,'+f+')').call(d3.axisBottom(c));b.append('g').attr('class','axis axis--y').call(d3.axisLeft(h).ticks(5).tickFormat(d3.format('d')));b.append('path').attr('class','line').attr('d',j(g)).attr('fill','none').attr('stroke','steelblue').attr('stroke-width','2px');a.createAxisTitles();a.createPlotTitle()},processData:function(b){var c=this,a=[];b.each(function(c){a.push(c.get('zp'))});return a}},0,['system-z-distribution'],['component','box','system-z-distribution'],{'component':!0,'box':!0,'system-z-distribution':!0},['widget.system-z-distribution'],0,[Explorer.view.system,'ZDistribution'],0);Ext.cmd.derive('Explorer.view.system.MagDistribution',Explorer.view.system.ZDistribution,{plotTitle:'Mag Distribution',xAxisTitle:'Mag',yAxisTitle:'N',processData:function(b){var c=this,a=[];b.each(function(c){a.push(c.get('mag'))});return a}},0,['system-mag-distribution'],['component','box','system-z-distribution','system-mag-distribution'],{'component':!0,'box':!0,'system-z-distribution':!0,'system-mag-distribution':!0},['widget.system-mag-distribution'],0,[Explorer.view.system,'MagDistribution'],0);Ext.cmd.derive('Explorer.view.system.Cmd',Explorer.view.system.D3SvgComponent,{config:{dataSeries:{gr:{id:'g-r',title:'(g-r) vs. r',xAxisTitle:'r',yAxisTitle:'g-r',values:[]},ri:{id:'r-i',title:'(r-i) vs. i',xAxisTitle:'i',yAxisTitle:'r-i',values:[]},iz:{id:'i-z',title:'(i-z) vs. z',xAxisTitle:'z',yAxisTitle:'i-z',values:[]},zy:{id:'z-y',title:'(z-y) vs. Y',xAxisTitle:'Y',yAxisTitle:'z-Y',values:[]}},plotData:[],svgMargin:{top:50,left:50,right:100,bottom:50},legend:{width:0,height:0,y:20,iconSize:20,iconPadding:5},colorScale:null},idleTimeout:null,idleDelay:350,proportionalSize:!1,performLayout:function(d,f){var a=this,h=f.width,e=f.height,i=a.getDataSeries(),b=a.loadData(a.getStore(),i),c=0.2;var g=d3.scaleOrdinal(d3['schemeCategory10']);a.setColorScale(g);a.x=d3.scaleLinear().range([0,h]).domain([d3.min(b,function(a){return d3.min(a.values,function(b){return b.x-c})}),d3.max(b,function(a){return d3.max(a.values,function(b){return b.x+c})})]);a.xAxis=d3.axisBottom(a.x);a.y=d3.scaleLinear().range([e,0]).domain([d3.min(b,function(a){return d3.min(a.values,function(b){return b.y-c})}),d3.max(b,function(a){return d3.max(a.values,function(b){return b.y+c})})]);a.yAxis=d3.axisLeft(a.y);a.brush=d3.brush().extent([[0,0],[h,e]]).on('end',function(){a.onBrushendend()});a.gx=d.append('g').attr('class','axis axis--x').attr('id','axis--x').attr('transform','translate(0,'+e+')').call(a.xAxis);a.gy=d.append('g').attr('class','axis axis--y').attr('id','axis--y').call(a.yAxis);a.scene.append('g').attr('class','brush').call(a.brush);a.scatter=d.append('g').attr('id','scatterplot');a.scatter.selectAll('.series').data(b).enter().append('g').attr('class','series').attr('id',function(a){return 'serie-'+a.id}).attr('active',!1).style('fill',function(b,a){return g(a)}).style('opacity',1).style('display','none').selectAll('.dot').data(function(a){return a.values}).enter().append('circle').attr('class','dot').attr('r',3.5).attr('cx',function(b){return a.x(b.x)}).attr('cy',function(b){return a.y(b.y)}).on('mouseover',function(b){a.onMouseOverPoint(b,this)}).on('mouseout',function(b){a.onMouseOutPoint(b,this)}).on('click',function(b){a.onClickPoint(b,this)});a.createAxisTitles();a.createPlotTitle();a.createLegendBox(d,f,b);a.deactiveAllSeries();a.activeSerie(b[0])},loadData:function(c,a){var d=this,b=[];c.each(function(b){var h=parseFloat(b.get('mag_g')),e=parseFloat(b.get('mag_r')),d=parseFloat(b.get('mag_i')),f=parseFloat(b.get('mag_r')),g=parseFloat(b.get('mag_y'));a.gr.values.push({'id':b.get('_meta_id'),'x':e,'y':h-e,'serie':'g-r'});a.ri.values.push({'id':b.get('_meta_id'),'x':d,'y':e-d,'serie':'r-i'});a.iz.values.push({'id':b.get('_meta_id'),'x':f,'y':d-f,'serie':'i-z'});a.zy.values.push({'id':b.get('_meta_id'),'x':g,'y':f-g,'serie':'z-y'})});b.push(a.gr);b.push(a.ri);b.push(a.iz);b.push(a.zy);d.setPlotData(b);return b},createLegendBox:function(d,f,e){var b=this,a=b.getLegend(),c=b.getColorScale();var h=d.selectAll('.legend').data(e).enter().append('g').attr('class','legend').attr('id',function(a){return 'legendItem-'+a.id}).attr('transform',function(g,c){var b=a.iconSize+a.iconPadding;return 'translate('+f.width+','+c*b+')'}).on('click',function(a){b.changeSerie(a)}).each(function(b,h){g=d3.select(this);g.append('rect').attr('width',a.iconSize).attr('height',a.iconSize).style('fill',c(h));g.append('text').attr('x',a.iconSize+5).attr('y',10).attr('dy','.35em').text(b.title)})},showHideSerie:function(c,d){var a=d3.select('#legendItem-'+c.id),b=d3.select('#serie-'+c.id);if(d){b.attr('active',!0).transition().duration(1000).style('opacity',1).style('display','block');a.transition().duration(1000).style('opacity',1)}else {b.attr('active',!1).transition().duration(1000).style('opacity',0).style('display','none');a.transition().duration(1000).style('opacity',0.3)}},changeSerie:function(a){var b=this,d=d3.select('#serie-'+a.id),c=d.attr('active')==='true'?!0:!1;if(c){b.deactiveSerie(a)}else {b.deactiveAllSeries();b.activeSerie(a)}},activeSerie:function(a){var b=this;b.showHideSerie(a,!0);b.setPlotTitle(a.title);b.setXAxisTitle(a.xAxisTitle);b.setYAxisTitle(a.yAxisTitle)},deactiveAllSeries:function(){var a=this,b=a.getPlotData();Ext.each(b,function(b){a.deactiveSerie(b)})},deactiveSerie:function(a){var b=this;b.showHideSerie(a,!1)},onMouseOverPoint:function(d,c){var e=this,a=d3.select(c),b=d3.select('#serie-'+d.serie);b.transition().duration(300).attr('fill-opacity',0.2);a.attr('r',6).attr('fill-opacity',1).style('cursor','pointer')},onMouseOutPoint:function(d,c){var e=this,a=d3.select(c),b=d3.select('#serie-'+d.serie);b.transition().duration(300).attr('fill-opacity',null);a.attr('r',3.5).attr('fill-opacity',null).style('cursor','default')},onClickPoint:function(d,e){var a=this,c=a.getStore(),b;b=c.findRecord('_meta_id',d.id);a.fireEvent('clickpoint',b,a)},onBrushendend:function(){var a=this,d=a.getScene(),b=a.plotData,c=0.2;a.s=d3.event.selection;if(!a.s){if(!a.idleTimeout){return a.idleTimeout=setTimeout(function(){a.idleTimeout=null},a.idleDelay)}a.y.domain(d3.extent(b,function(a){return a.y})).nice();a.x.domain([d3.min(b,function(a){return d3.min(a.values,function(b){return b.x-c})}),d3.max(b,function(a){return d3.max(a.values,function(b){return b.x+c})})]);a.y.domain([d3.min(b,function(a){return d3.min(a.values,function(b){return b.y-c})}),d3.max(b,function(a){return d3.max(a.values,function(b){return b.y+c})})])}else {a.x.domain([a.s[0][0],a.s[1][0]].map(a.x.invert,a.x));a.y.domain([a.s[1][1],a.s[0][1]].map(a.y.invert,a.y));d.select('.brush').call(a.brush.move,null)}a.zoom()},zoom:function(){var a=this,c=a.getScene(),b;b=a.scatter.transition().duration(750);d3.select('#axis--x').transition(b).call(a.xAxis);d3.select('#axis--y').transition(b).call(a.yAxis);a.scatter.selectAll('circle').transition(b).attr('cx',function(b){return a.x(b.x)}).attr('cy',function(b){return a.y(b.y)})}},0,['system-cmd'],['component','box','system-cmd'],{'component':!0,'box':!0,'system-cmd':!0},['widget.system-cmd'],0,[Explorer.view.system,'Cmd'],0);Ext.cmd.derive('Explorer.view.system.System',Ext.panel.Panel,{controller:'system',viewModel:'system',layout:'fit',initComponent:function(){var a=this;Ext.apply(this,{layout:'border',defaults:{frame:!0},items:[{xtype:'panel',region:'west',width:300,margin:'0 10 0 0',collapsible:!0,reference:'detailPanel',layout:{type:'vbox',pack:'start',align:'stretch'},items:[{xtype:'system-form',reference:'properties-form',split:!0,bbar:[{xtype:'button',text:'SIMBAD',handler:'onClickSimbad'},{xtype:'button',text:'NED',handler:'onClickNed'}]},{xtype:'system-properties',reference:'properties-grid',split:!0,flex:1}]},{xtype:'panel',region:'center',flex:1,split:!0,layout:{type:'vbox',pack:'start',align:'stretch'},margin:'0 0 10 0',defaults:{frame:!0},items:[{xtype:'panel',flex:1,split:!0,layout:{type:'hbox',pack:'start',align:'stretch'},defaults:{frame:!0},items:[{xtype:'system-visiomatic',reference:'visiomatic',margin:'0 10 0 0',split:!0,flex:1},{xtype:'system-aladin',reference:'aladin',split:!0,flex:1,bind:{storeSurveys:'{surveys}',storeTags:'{tags}',storeTiles:'{tiles}'}}]},{xtype:'tabpanel',flex:1,split:!0,items:[{xtype:'system-members-grid',title:'System Members',reference:'members-grid',bind:{store:'{members}',selection:'{selected_member}'},listeners:{select:'onSelectSystemMember'}},{xtype:'panel',title:'z and Mag Distribution',layout:{type:'hbox',pack:'start',align:'stretch'},bind:{disabled:'{!have_members}'},items:[{xtype:'system-z-distribution',flex:1,bind:{store:'{members}'}},{xtype:'system-mag-distribution',flex:1,bind:{store:'{members}'}}]},{xtype:'system-spatial-distribution',title:'Spatial Distribution',disabled:!0},{xtype:'system-cmd',title:'CMD',bind:{store:'{members}',disabled:'{!have_members}'},listeners:{clickpoint:'onCmdClickPoint'}}]}]}]});Ext.panel.Panel.prototype.initComponent.apply(this,arguments)},loadPanel:function(b){var a=this,e=a.getViewModel(),d=b[1],c=b[2];e.set('source',d);e.set('object_id',c);a.fireEvent('loadpanel',d,c,a)},updatePanel:function(a){}},0,['system'],['component','box','container','panel','system'],{'component':!0,'box':!0,'container':!0,'panel':!0,'system':!0},['widget.system'],0,[Explorer.view.system,'System'],0);Ext.cmd.derive('Explorer.view.main.MainController',Ext.app.ViewController,{routes:{'coadd/:source/:object':{action:'onCoadd'},'system/:source/:object':{action:'onSystem'}},setActivePanel:function(e){var h=this,g=h.getReferences(),b=g.mainCardPanel,d=b.getLayout(),f=e.routeId,c=b.child('component[routeId='+f+']'),a=null;if(!c){a=b.add(e);a.loadPanel(arguments);d.setActiveItem(a)}else {a=c;a.updatePanel(arguments);d.setActiveItem(a)}},onCoadd:function(c,a){var b=Ext.create('Explorer.view.coadd.Coadd',{hideMode:'offsets',routeId:'coadd',layout:'fit'});this.setActivePanel(b,c,a)},onSystem:function(c,a){var b=Ext.create('Explorer.view.system.System',{hideMode:'offsets',routeId:'sytem',layout:'fit'});this.setActivePanel(b,c,a)}},0,0,0,0,['controller.main'],0,[Explorer.view.main,'MainController'],0);Ext.cmd.derive('Explorer.view.main.MainModel',Ext.app.ViewModel,{data:{name:'Explorer',internal_name:'explorer',loremIpsum:'Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum.'}},0,0,0,0,['viewmodel.main'],0,[Explorer.view.main,'MainModel'],0);Ext.cmd.derive('Explorer.view.main.Main',Ext.container.Container,{controller:'main',viewModel:'main',layout:{type:'vbox',align:'stretch'},items:[{xtype:'dri-header'},{xtype:'container',flex:1,reference:'mainCardPanel',layout:{type:'card',anchor:'100%'}},{xtype:'dri-footer'}]},0,['app-main'],['component','box','container','app-main'],{'component':!0,'box':!0,'container':!0,'app-main':!0},['widget.app-main'],0,[Explorer.view.main,'Main'],0);Ext.application({name:'Explorer',extend:Explorer.Application,mainView:'Explorer.view.main.Main'}); \ No newline at end of file +var $jscomp=$jscomp||{};$jscomp.scope={};$jscomp.defineProperty=typeof Object.defineProperties=='function'?Object.defineProperty:function(b,c,a){a=a;if(b==Array.prototype||b==Object.prototype){return}b[c]=a.value};$jscomp.getGlobal=function(a){return typeof window!='undefined'&&window===a?a:typeof global!='undefined'&&global!=null?global:a};$jscomp.global=$jscomp.getGlobal(this);$jscomp.polyfill=function(i,f,j,k){if(!f){return}var a=$jscomp.global;var b=i.split('.');for(var e=0;ec){if(--b in this){this[--d]=this[b]}else {delete this[d]}}}return this};return b},'es6-impl','es3');$jscomp.SYMBOL_PREFIX='jscomp_symbol_';$jscomp.initSymbol=function(){$jscomp.initSymbol=function(){};if(!$jscomp.global['Symbol']){$jscomp.global['Symbol']=$jscomp.Symbol}};$jscomp.symbolCounter_=0;$jscomp.Symbol=function(a){return $jscomp.SYMBOL_PREFIX+(a||'')+$jscomp.symbolCounter_++};$jscomp.initSymbolIterator=function(){$jscomp.initSymbol();var a=$jscomp.global['Symbol'].iterator;if(!a){a=$jscomp.global['Symbol'].iterator=$jscomp.global['Symbol']('iterator')}if(typeof Array.prototype[a]!='function'){$jscomp.defineProperty(Array.prototype,a,{configurable:!0,writable:!0,value:function(){return $jscomp.arrayIterator(this)}})}$jscomp.initSymbolIterator=function(){}};$jscomp.arrayIterator=function(a){var b=0;return $jscomp.iteratorPrototype(function(){if(bd){b=d}b=Number(b);if(b<0){b=Math.max(0,d+b)}for(var e=Number(c||0);e-0.25){var f=b;var g=1;var c=b;var d=0;var e=1;while(d!=c){f*=b;e*=-1;c=(d=c)+e*f/++g}return c}return Math.log(1+b)};return b},'es6-impl','es3');$jscomp.polyfill('Math.atanh',function(b){if(b){return b}var a=Math.log1p;var c=function(c){c=Number(c);return (a(c)-a(-c))/2};return c},'es6-impl','es3');$jscomp.polyfill('Math.cbrt',function(a){if(a){return a}var b=function(b){if(b===0){return b}b=Number(b);var c=Math.pow(Math.abs(b),1/3);return b<0?-c:c};return b},'es6-impl','es3');$jscomp.polyfill('Math.clz32',function(a){if(a){return a}var b=function(b){b=Number(b)>>>0;if(b===0){return 32}var c=0;if((b&4.29490176E9)===0){b<<=16;c+=16}if((b&4.27819008E9)===0){b<<=8;c+=8}if((b&4.02653184E9)===0){b<<=4;c+=4}if((b&3.221225472E9)===0){b<<=2;c+=2}if((b&2.147483648E9)===0){c++}return c};return b},'es6-impl','es3');$jscomp.polyfill('Math.cosh',function(a){if(a){return a}var b=Math.exp;var c=function(c){c=Number(c);return (b(c)+b(-c))/2};return c},'es6-impl','es3');$jscomp.polyfill('Math.expm1',function(a){if(a){return a}var b=function(b){b=Number(b);if(b<0.25&&b>-0.25){var e=b;var f=1;var c=b;var d=0;while(d!=c){e*=b/++f;c=(d=c)+e}return c}return Math.exp(b)-1};return b},'es6-impl','es3');$jscomp.polyfill('Math.hypot',function(a){if(a){return a}var b=function(c,d,h){c=Number(c);d=Number(d);var b,g,f;var e=Math.max(Math.abs(c),Math.abs(d));for(b=2;b1.0E100||e<1.0E-100){c=c/e;d=d/e;f=c*c+d*d;for(b=2;b>>16&65535;var d=b&65535;var g=c>>>16&65535;var e=c&65535;var h=f*e+d*g<<16>>>0;return d*e+h|0};return b},'es6-impl','es3');$jscomp.polyfill('Math.log10',function(a){if(a){return a}var b=function(b){return Math.log(b)/Math.LN10};return b},'es6-impl','es3');$jscomp.polyfill('Math.log2',function(a){if(a){return a}var b=function(b){return Math.log(b)/Math.LN2};return b},'es6-impl','es3');$jscomp.polyfill('Math.sign',function(a){if(a){return a}var b=function(b){b=Number(b);return b===0||isNaN(b)?b:b>0?1:-1};return b},'es6-impl','es3');$jscomp.polyfill('Math.sinh',function(a){if(a){return a}var b=Math.exp;var c=function(c){c=Number(c);if(c===0){return c}return (b(c)-b(-c))/2};return c},'es6-impl','es3');$jscomp.polyfill('Math.tanh',function(a){if(a){return a}var b=function(b){b=Number(b);if(b===0){return b}var c=Math.exp(-2*Math.abs(b));var d=(1-c)/(1+c);return b<0?-d:d};return b},'es6-impl','es3');$jscomp.polyfill('Math.trunc',function(a){if(a){return a}var b=function(b){b=Number(b);if(isNaN(b)||b===Infinity||b===-Infinity||b===0){return b}var c=Math.floor(Math.abs(b));return b<0?-c:c};return b},'es6-impl','es3');$jscomp.polyfill('Number.EPSILON',function(a){return Math.pow(2,-52)},'es6-impl','es3');$jscomp.polyfill('Number.MAX_SAFE_INTEGER',function(){return 9.007199254740991E15},'es6-impl','es3');$jscomp.polyfill('Number.MIN_SAFE_INTEGER',function(){return -9.007199254740991E15},'es6-impl','es3');$jscomp.polyfill('Number.isFinite',function(a){if(a){return a}var b=function(b){if(typeof b!=='number'){return !1}return !isNaN(b)&&b!==Infinity&&b!==-Infinity};return b},'es6-impl','es3');$jscomp.polyfill('Number.isInteger',function(a){if(a){return a}var b=function(b){if(!Number.isFinite(b)){return !1}return b===Math.floor(b)};return b},'es6-impl','es3');$jscomp.polyfill('Number.isNaN',function(a){if(a){return a}var b=function(b){return typeof b==='number'&&isNaN(b)};return b},'es6-impl','es3');$jscomp.polyfill('Number.isSafeInteger',function(a){if(a){return a}var b=function(b){return Number.isInteger(b)&&Math.abs(b)<=Number.MAX_SAFE_INTEGER};return b},'es6-impl','es3');$jscomp.polyfill('Object.assign',function(a){if(a){return a}var b=function(e,f){for(var d=1;d3?f:b,e);return !0}else {if(c.writable&&!Object.isFrozen(b)){b[d]=e;return !0}}return !1};return b},'es6','es5');$jscomp.polyfill('Reflect.setPrototypeOf',function(a){if(a){return a}if(typeof ''.__proto__!='object'){return null}var b=function(b,c){try{b.__proto__=c;return b.__proto__===c}catch(d){return !1}};return b},'es6','es5');$jscomp.ASSUME_NO_NATIVE_SET=!1;$jscomp.polyfill('Set',function(b){var c=!$jscomp.ASSUME_NO_NATIVE_SET&&function(){if(!b||!b.prototype.entries||typeof Object.seal!='function'){return !1}try{b=b;var d=Object.seal({x:4});var c=new b($jscomp.makeIterator([d]));if(!c.has(d)||c.size!=1||c.add(d)!=c||c.size!=1||c.add({x:4})!=c||c.size!=2){return !1}var e=c.entries();var a=e.next();if(a.done||a.value[0]!=d||a.value[1]!=d){return !1}a=e.next();if(a.done||a.value[0]==d||a.value[0].x!=4||a.value[1]!=a.value[0]){return !1}return e.next().done}catch(f){return !1}}();if(c){return b}$jscomp.initSymbol();$jscomp.initSymbolIterator();var a=function(a){this.map_=new Map();if(a){var e=$jscomp.makeIterator(a);var c;while(!(c=e.next()).done){var d=c.value;this.add(d)}}this.size=this.map_.size};a.prototype.add=function(a){this.map_.set(a,a);this.size=this.map_.size;return this};a.prototype['delete']=function(c){var a=this.map_['delete'](c);this.size=this.map_.size;return a};a.prototype.clear=function(){this.map_.clear();this.size=0};a.prototype.has=function(a){return this.map_.has(a)};a.prototype.entries=function(){return this.map_.entries()};a.prototype.values=function(){return this.map_.values()};a.prototype.keys=a.prototype.values;$jscomp.initSymbol();$jscomp.initSymbolIterator();a.prototype[Symbol.iterator]=a.prototype.values;a.prototype.forEach=function(c,a){var d=this;this.map_.forEach(function(e){return c.call(a,e,e,d)})};return a},'es6-impl','es3');$jscomp.checkStringArgs=function(a,c,b){if(a==null){throw new TypeError("The 'this' value for String.prototype."+b+' must not be null or undefined')}if(c instanceof RegExp){throw new TypeError('First argument to String.prototype.'+b+' must not be a regular expression')}return a+''};$jscomp.polyfill('String.prototype.codePointAt',function(a){if(a){return a}var b=function(b){var e=$jscomp.checkStringArgs(this,null,'codePointAt');var f=e.length;b=Number(b)||0;if(!(b>=0&&b56319||b+1===f){return c}var d=e.charCodeAt(b+1);if(d<56320||d>57343){return c}return (c-55296)*1024+d+9216};return b},'es6-impl','es3');$jscomp.polyfill('String.prototype.endsWith',function(a){if(a){return a}var b=function(b,c){var d=$jscomp.checkStringArgs(this,b,'endsWith');b=b+'';if(c===void 0){c=d.length}var f=Math.max(0,Math.min(c|0,d.length));var e=b.length;while(e>0&&f>0){if(d[--f]!=b[--e]){return !1}}return e<=0};return b},'es6-impl','es3');$jscomp.polyfill('String.fromCodePoint',function(a){if(a){return a}var b=function(e){var c='';for(var d=0;d1114111||b!==Math.floor(b)){throw new RangeError('invalid_code_point '+b)}if(b<=65535){c+=String.fromCharCode(b)}else {b-=65536;c+=String.fromCharCode(b>>>10&1023|55296);c+=String.fromCharCode(b&1023|56320)}}return c};return b},'es6-impl','es3');$jscomp.polyfill('String.prototype.includes',function(a){if(a){return a}var b=function(b,c){var d=$jscomp.checkStringArgs(this,b,'includes');return d.indexOf(b,c||0)!==-1};return b},'es6-impl','es3');$jscomp.polyfill('String.prototype.repeat',function(a){if(a){return a}var b=function(b){var c=$jscomp.checkStringArgs(this,null,'repeat');if(b<0||b>1342177279){throw new RangeError('Invalid count value')}b=b|0;var d='';while(b){if(b&1){d+=c}if(b>>>=1){c+=c}}return d};return b},'es6-impl','es3');$jscomp.stringPadding=function(c,a){var b=c!==undefined?String(c):' ';if(!(a>0)||!b){return ''}var d=Math.ceil(a/b.length);return b.repeat(d).substring(0,a)};$jscomp.polyfill('String.prototype.padEnd',function(a){if(a){return a}var b=function(d,c){var b=$jscomp.checkStringArgs(this,null,'padStart');var e=d-b.length;return b+$jscomp.stringPadding(c,e)};return b},'es8','es3');$jscomp.polyfill('String.prototype.padStart',function(a){if(a){return a}var b=function(d,c){var b=$jscomp.checkStringArgs(this,null,'padStart');var e=d-b.length;return $jscomp.stringPadding(c,e)+b};return b},'es8','es3');$jscomp.polyfill('String.prototype.startsWith',function(a){if(a){return a}var b=function(b,g){var c=$jscomp.checkStringArgs(this,b,'startsWith');b=b+'';var h=c.length;var e=b.length;var f=Math.max(0,Math.min(g|0,c.length));var d=0;while(d=e};return b},'es6-impl','es3');$jscomp.arrayFromIterator=function(c){var b;var a=[];while(!(b=c.next()).done){a.push(b.value)}return a};$jscomp.arrayFromIterable=function(a){if(a instanceof Array){return a}else {return $jscomp.arrayFromIterator($jscomp.makeIterator(a))}};$jscomp.inherits=function(a,b){function tempCtor(){}tempCtor.prototype=b.prototype;a.superClass_=b.prototype;a.prototype=new tempCtor();a.prototype.constructor=a;for(var c in b){if(Object.defineProperties){var d=Object.getOwnPropertyDescriptor(b,c);if(d){Object.defineProperty(a,c,d)}}else {a[c]=b[c]}}};$jscomp.polyfill('WeakSet',function(b){function isConformant(){if(!b||!Object.seal){return !1}try{var c=Object.seal({});var d=Object.seal({});var a=new b([c]);if(!a.has(c)||a.has(d)){return !1}a['delete'](c);a.add(d);return !a.has(c)&&a.has(d)}catch(e){return !1}}if(isConformant()){return b}var a=function(a){this.map_=new WeakMap();if(a){$jscomp.initSymbol();$jscomp.initSymbolIterator();var e=$jscomp.makeIterator(a);var c;while(!(c=e.next()).done){var d=c.value;this.add(d)}}};a.prototype.add=function(a){this.map_.set(a,!0);return this};a.prototype.has=function(a){return this.map_.has(a)};a.prototype['delete']=function(a){return this.map_['delete'](a)};return a},'es6-impl','es3');try{if(Array.prototype.values.toString().indexOf('[native code]')==-1){delete Array.prototype.values}}catch(a){}var Explorer=Explorer||{};if(!Explorer.model){Explorer.model={}}if(!Explorer.store){Explorer.store={}}if(!Explorer.view){Explorer.view={}}if(!Explorer.view.coadd){Explorer.view.coadd={}}if(!Explorer.view.main){Explorer.view.main={}}if(!Explorer.view.system){Explorer.view.system={}}var Ext=Ext||{};if(!Ext.Toolbar){Ext.Toolbar={}}if(!Ext.app){Ext.app={}}if(!Ext.app.bind){Ext.app.bind={}}if(!Ext.app.domain){Ext.app.domain={}}if(!Ext.app.route){Ext.app.route={}}if(!Ext.button){Ext.button={}}if(!Ext.chart){Ext.chart={}}if(!Ext.chart.axis){Ext.chart.axis={}}if(!Ext.chart.axis.layout){Ext.chart.axis.layout={}}if(!Ext.chart.axis.segmenter){Ext.chart.axis.segmenter={}}if(!Ext.chart.axis.sprite){Ext.chart.axis.sprite={}}if(!Ext.chart.grid){Ext.chart.grid={}}if(!Ext.chart.interactions){Ext.chart.interactions={}}if(!Ext.chart.label){Ext.chart.label={}}if(!Ext.chart.overrides){Ext.chart.overrides={}}if(!Ext.chart.plugin){Ext.chart.plugin={}}if(!Ext.chart.series){Ext.chart.series={}}if(!Ext.chart.series.sprite){Ext.chart.series.sprite={}}if(!Ext.chart.theme){Ext.chart.theme={}}if(!Ext.container){Ext.container={}}if(!Ext.core){Ext.core={}}if(!Ext.data){Ext.data={}}if(!Ext.data.field){Ext.data.field={}}if(!Ext.data.flash){Ext.data.flash={}}if(!Ext.data.identifier){Ext.data.identifier={}}if(!Ext.data.matrix){Ext.data.matrix={}}if(!Ext.data.operation){Ext.data.operation={}}if(!Ext.data.proxy){Ext.data.proxy={}}if(!Ext.data.reader){Ext.data.reader={}}if(!Ext.data.request){Ext.data.request={}}if(!Ext.data.schema){Ext.data.schema={}}if(!Ext.data.session){Ext.data.session={}}if(!Ext.data.validator){Ext.data.validator={}}if(!Ext.data.writer){Ext.data.writer={}}if(!Ext.dd){Ext.dd={}}if(!Ext.dom){Ext.dom={}}if(!Ext.dom.Element){Ext.dom.Element={}}if(!Ext.draw){Ext.draw={}}if(!Ext.draw.engine){Ext.draw.engine={}}if(!Ext.draw.engine.SvgContext){Ext.draw.engine.SvgContext={}}if(!Ext.draw.gradient){Ext.draw.gradient={}}if(!Ext.draw.modifier){Ext.draw.modifier={}}if(!Ext.draw.sprite){Ext.draw.sprite={}}if(!Ext.event){Ext.event={}}if(!Ext.event.gesture){Ext.event.gesture={}}if(!Ext.event.publisher){Ext.event.publisher={}}if(!Ext.form){Ext.form={}}if(!Ext.form.Action){Ext.form.Action={}}if(!Ext.form.action){Ext.form.action={}}if(!Ext.form.field){Ext.form.field={}}if(!Ext.form.trigger){Ext.form.trigger={}}if(!Ext.fx){Ext.fx={}}if(!Ext.fx.animation){Ext.fx.animation={}}if(!Ext.fx.easing){Ext.fx.easing={}}if(!Ext.fx.runner){Ext.fx.runner={}}if(!Ext.fx.target){Ext.fx.target={}}if(!Ext.grid){Ext.grid={}}if(!Ext.grid.column){Ext.grid.column={}}if(!Ext.grid.header){Ext.grid.header={}}if(!Ext.grid.locking){Ext.grid.locking={}}if(!Ext.grid.plugin){Ext.grid.plugin={}}if(!Ext.layout){Ext.layout={}}if(!Ext.layout.boxOverflow){Ext.layout.boxOverflow={}}if(!Ext.layout.component){Ext.layout.component={}}if(!Ext.layout.component.field){Ext.layout.component.field={}}if(!Ext.layout.container){Ext.layout.container={}}if(!Ext.layout.container.border){Ext.layout.container.border={}}if(!Ext.layout.container.boxOverflow){Ext.layout.container.boxOverflow={}}if(!Ext.list){Ext.list={}}if(!Ext.menu){Ext.menu={}}if(!Ext.mixin){Ext.mixin={}}if(!Ext.overrides){Ext.overrides={}}if(!Ext.overrides.app){Ext.overrides.app={}}if(!Ext.overrides.app.domain){Ext.overrides.app.domain={}}if(!Ext.overrides.dom){Ext.overrides.dom={}}if(!Ext.overrides.event){Ext.overrides.event={}}if(!Ext.overrides.event.publisher){Ext.overrides.event.publisher={}}if(!Ext.overrides.plugin){Ext.overrides.plugin={}}if(!Ext.overrides.util){Ext.overrides.util={}}if(!Ext.panel){Ext.panel={}}if(!Ext.perf){Ext.perf={}}if(!Ext.plugin){Ext.plugin={}}if(!Ext.promise){Ext.promise={}}if(!Ext.resizer){Ext.resizer={}}if(!Ext.scroll){Ext.scroll={}}if(!Ext.selection){Ext.selection={}}if(!Ext.state){Ext.state={}}if(!Ext.tab){Ext.tab={}}if(!Ext.theme){Ext.theme={}}if(!Ext.theme.crisp){Ext.theme.crisp={}}if(!Ext.theme.crisp.view){Ext.theme.crisp.view={}}if(!Ext.theme.neptune){Ext.theme.neptune={}}if(!Ext.theme.neptune.container){Ext.theme.neptune.container={}}if(!Ext.theme.neptune.grid){Ext.theme.neptune.grid={}}if(!Ext.theme.neptune.grid.column){Ext.theme.neptune.grid.column={}}if(!Ext.theme.neptune.layout){Ext.theme.neptune.layout={}}if(!Ext.theme.neptune.layout.component){Ext.theme.neptune.layout.component={}}if(!Ext.theme.neptune.menu){Ext.theme.neptune.menu={}}if(!Ext.theme.neptune.panel){Ext.theme.neptune.panel={}}if(!Ext.theme.neptune.resizer){Ext.theme.neptune.resizer={}}if(!Ext.theme.neptune.toolbar){Ext.theme.neptune.toolbar={}}if(!Ext.tip){Ext.tip={}}if(!Ext.toolbar){Ext.toolbar={}}if(!Ext.tree){Ext.tree={}}if(!Ext.util){Ext.util={}}if(!Ext.util.paintmonitor){Ext.util.paintmonitor={}}if(!Ext.util.sizemonitor){Ext.util.sizemonitor={}}if(!Ext.util.translatable){Ext.util.translatable={}}if(!Ext.ux){Ext.ux={}}if(!Ext.ux.colorpick){Ext.ux.colorpick={}}if(!Ext.ux.layout){Ext.ux.layout={}}if(!Ext.ux.rating){Ext.ux.rating={}}if(!Ext.view){Ext.view={}}if(!Ext.window){Ext.window={}}var Portal=Portal||{};var aladin=aladin||{};if(!aladin.maps){aladin.maps={}}if(!aladin.model){aladin.model={}}if(!aladin.store){aladin.store={}}var common=common||{};if(!common.contact){common.contact={}}if(!common.data){common.data={}}if(!common.data.proxy){common.data.proxy={}}if(!common.footer){common.footer={}}if(!common.header){common.header={}}if(!common.help){common.help={}}if(!common.model){common.model={}}if(!common.store){common.store={}}var visiomatic=visiomatic||{};if(!visiomatic.catalog){visiomatic.catalog={}}if(!visiomatic.crop){visiomatic.crop={}}if(!visiomatic.download){visiomatic.download={}}if(!visiomatic.filter){visiomatic.filter={}}if(!visiomatic.model){visiomatic.model={}}if(!visiomatic.store){visiomatic.store={}}(function(q){var e,p=['constructor','toString','valueOf','toLocaleString'],n={},m={},k=0,l,j,a,b,o,f,c,d,g,h,i,t=function(){var s,t;j=Ext.Base;a=Ext.ClassManager;b=Ext.Class;for(s=p.length;s-->0;){t=1<0;){H=e[l];g[H]=j[H]}if(c.$isFunction){c=c(g)}v.data=c;x=c.statics;delete c.statics;c.$className=u;if('$className' in c){g.$className=c.$className}g.extend(Q);r=g.prototype;if(E){g.xtype=c.xtype=E[0];r.xtypes=E}r.xtypesChain=M;r.xtypesMap=O;c.alias=B;m.triggerExtended(g,c,v);if(c.onClassExtended){g.onExtended(c.onClassExtended,g);delete c.onClassExtended}if(c.privates&&h){h.call(b,g,c)}if(x){if(i){g.addStatics(x)}else {for(w in x){if(x.hasOwnProperty(w)){t=x[w];if(t&&t.$isFunction&&!t.$isClass&&t!==Ext.emptyFn&&t!==Ext.identityFn){g[w]=I=t;I.$owner=g;I.$name=w}g[w]=t}}}}if(c.inheritableStatics){g.addInheritableStatics(c.inheritableStatics);delete c.inheritableStatics}if(r.onClassExtended){m.onExtended(r.onClassExtended,m);delete r.onClassExtended}if(c.platformConfig&&d){d.call(b,g,c);delete c.platformConfig}if(c.config){o.call(b,g,c)}if(c.cachedConfig&&f){f.call(b,g,c);delete c.cachedConfig}v.onBeforeCreated(g,v.data,v);for(l=0,y=D&&D.length;l0){c--;a[c]='var Ext=window.'+Ext.name+';'+a[c]}}d=a.join('');b=e[d];if(!b){b=Function.prototype.constructor.apply(Function.prototype,a);e[d]=b}return b},functionFactory:function(){var b=Array.prototype.slice.call(arguments),a;if(Ext.isSandboxed){a=b.length;if(a>0){a--;b[a]='var Ext=window.'+Ext.name+';'+b[a]}}return Function.prototype.constructor.apply(Function.prototype,b)},Logger:{verbose:a,log:a,info:a,warn:a,error:function(a){throw new Error(a)},deprecate:a},getElementById:function(a){return document.getElementById(a)},splitAndUnescape:function(){var a={};return function(e,c){if(!e){return []}else {if(!c){return [e]}}var g=a[c]||(a[c]=new RegExp('\\\\'+c,'g')),f=[],d,b;d=e.split(c);while((b=d.shift())!==undefined){while(b.charAt(b.length-1)==='\\'&&d.length>0){b=b+c+d.shift()}b=b.replace(g,c);f.push(b)}return f}}()});Ext.returnTrue.$nullFn=Ext.returnId.$nullFn=!0})();Ext.platformTags.modern=!(Ext.platformTags.classic=Ext.isClassic=!0);(function(){function toString(){var d=this,b=d.sourceClass,a=d.sourceMethod,c=d.msg;if(a){if(c){a+='(): ';a+=c}else {a+='()'}}if(b){a=a?b+'.'+a:b}return a||c||''}Ext.Error=function(b){if(Ext.isString(b)){b={msg:b}}var a=new Error();Ext.apply(a,b);a.message=a.message||a.msg;a.toString=toString;return a};Ext.apply(Ext.Error,{ignore:!1,raise:function(a){a=a||{};if(Ext.isString(a)){a={msg:a}}var d=this,b=d.raise.caller,e,c;if(b===Ext.raise){b=b.caller}if(b){if(!a.sourceMethod&&(c=b.$name)){a.sourceMethod=c}if(!a.sourceClass&&(c=b.$owner)&&(c=c.$className)){a.sourceClass=c}}if(d.handle(a)!==!0){e=toString.call(a);throw new Ext.Error(a)}},handle:function(){return this.ignore}})})();Ext.deprecated=function(a){return Ext.emptyFn};Ext.raise=function(){Ext.Error.raise.apply(Ext.Error,arguments)};Ext.Array=function(){var c=Array.prototype,b=c.slice,f=function(){var a=[],b,c=20;if(!a.splice){return !1}while(c--){a.push('A')}a.splice(15,0,'F','F','F','F','F','F','F','F','F','F','F','F','F','F','F','F','F','F','F','F','F');b=a.length;a.splice(13,0,'XXX');if(b+1!==a.length){return !1}return !0}(),i='indexOf' in c,h=!0;function stableSort(b,e){var d=b.length,c=new Array(d),a;for(a=0;ac){for(b=l;b--;){a[h+b]=a[c+b]}}}if(e&&f===j){a.length=j;a.push.apply(a,d)}else {a.length=j+e;for(b=0;b>1;f=d(i,h[e]);if(f>=0){c=e+1}else {if(f<0){b=e-1}}}return c},defaultCompare:function(a,b){return ab?1:0},lexicalCompare:function(a,b){a=String(a);b=String(b);return ab?1:0},each:function(c,e,d,g){c=a.from(c);var b,f=c.length;if(g!==!0){for(b=0;b-1;b--){if(e.call(d||c[b],c[b],b,c)===!1){return b}}}return !0},forEach:'forEach' in c?function(a,c,b){return a.forEach(c,b)}:function(b,d,c){for(var a=0,e=b.length;a=0&&b>>0,c=e;if(arguments.length<3){while(!0){if(b in a){c=a[b++];break}if(++b>=d){throw new TypeError('Reduce of empty array with no initial value')}}}for(;bb){b=a}}}return b},mean:function(b){return b.length>0?a.sum(b)/b.length:undefined},sum:function(b){var d=0,a,e,c;for(a=0,e=b.length;ab?1:-1,a;for(a=b;a!=d;a+=e){c[a]=c[a+e]}c[d]=f},replace:j,splice:p,push:function(a){var d=arguments.length,c=1,b;if(a===undefined){a=[]}else {if(!Ext.isArray(a)){a=[a]}}for(;c=d){a=0}else {a=d-a}}if(a===0){b=c+b}else {if(a>=b.length){b+=c}else {b=b.substr(0,a)+c+b.substr(a)}}return b},startsWith:function(b,a,d){var c=e(b,a);if(c){if(d){b=b.toLowerCase();a=a.toLowerCase()}c=b.lastIndexOf(a,0)===0}return c},endsWith:function(b,a,d){var c=e(b,a);if(c){if(d){b=b.toLowerCase();a=a.toLowerCase()}c=b.indexOf(a,b.length-a.length)!==-1}return c},createVarName:function(a){return a.replace(l,'')},htmlEncode:function(a){return !a?a:String(a).replace(b,h)},htmlDecode:function(a){return !a?a:String(a).replace(d,g)},hasHtmlCharacters:function(a){return b.test(a)},addCharacterEntities:function(g){var i=[],h=[],e,f;for(e in g){f=g[e];a[e]=f;c[f]=e;i.push(f);h.push(e)}b=new RegExp('('+i.join('|')+')','g');d=new RegExp('('+h.join('|')+'|&#[0-9]{1,5};)','g')},resetCharacterEntities:function(){c={};a={};this.addCharacterEntities({'&':'&','>':'>','<':'<','"':'"',''':"'"})},urlAppend:function(a,b){if(!Ext.isEmpty(b)){return a+(a.indexOf('?')===-1?'?':'&')+b}return a},trim:function(a){if(a){a=a.replace(m,'')}return a||''},capitalize:function(a){if(a){a=a.charAt(0).toUpperCase()+a.substr(1)}return a||''},uncapitalize:function(a){if(a){a=a.charAt(0).toLowerCase()+a.substr(1)}return a||''},ellipsis:function(a,c,e){if(a&&a.length>c){if(e){var b=a.substr(0,c-2),d=Math.max(b.lastIndexOf(' '),b.lastIndexOf('.'),b.lastIndexOf('!'),b.lastIndexOf('?'));if(d!==-1&&d>=c-15){return b.substr(0,d)+'...'}}return a.substr(0,c-3)+'...'}return a},escapeRegex:function(a){return a.replace(i,'\\$1')},createRegex:function(b,d,e,c){var a=b;if(b!=null&&!b.exec){a=f.escapeRegex(String(b));if(d!==!1){a='^'+a}if(e!==!1){a+='$'}a=new RegExp(a,c!==!1?'i':'')}return a},escape:function(a){return a.replace(n,'\\$1')},toggle:function(b,a,c){return b===a?c:a},leftPad:function(c,d,b){var a=String(c);b=b||' ';while(a.length daysInMonth) {','d = daysInMonth;','}','}','h = from(h, from(def.h, dt.getHours()));','i = from(i, from(def.i, dt.getMinutes()));','s = from(s, from(def.s, dt.getSeconds()));','ms = from(ms, from(def.ms, dt.getMilliseconds()));','if(z >= 0 && y >= 0){','v = me.add(new Date(y < 100 ? 100 : y, 0, 1, h, i, s, ms), me.YEAR, y < 100 ? y - 100 : 0);','v = !strict? v : (strict === true && (z <= 364 || (me.isLeapYear(v) && z <= 365))? me.add(v, me.DAY, z) : null);','}else if(strict === true && !me.isValid(y, m + 1, d, h, i, s, ms)){','v = null;','}else{','if (W) {','year = y || (new Date()).getFullYear();','jan4 = new Date(year, 0, 4, 0, 0, 0);','d = jan4.getDay();','week1monday = new Date(jan4.getTime() - ((d === 0 ? 6 : d - 1) * 86400000));','v = Ext.Date.clearTime(new Date(week1monday.getTime() + ((W - 1) * 604800000 + 43200000)));','} else {','v = me.add(new Date(y < 100 ? 100 : y, m, d, h, i, s, ms), me.YEAR, y < 100 ? y - 100 : 0);','}','}','}','}','if(v){','if(zz != null){','v = me.add(v, me.SECOND, -v.getTimezoneOffset() * 60 - zz);','}else if(o){',"v = me.add(v, me.MINUTE, -v.getTimezoneOffset() + (sn == '+'? -1 : 1) * (hr * 60 + mn));",'}','}','return (v != null) ? v : null;'].join('\n');if(!Date.prototype.toISOString){Date.prototype.toISOString=function(){var a=this;return c(a.getUTCFullYear(),4,'0')+'-'+c(a.getUTCMonth()+1,2,'0')+'-'+c(a.getUTCDate(),2,'0')+'T'+c(a.getUTCHours(),2,'0')+':'+c(a.getUTCMinutes(),2,'0')+':'+c(a.getUTCSeconds(),2,'0')+'.'+c(a.getUTCMilliseconds(),3,'0')+'Z'}}function xf(a){var b=Array.prototype.slice.call(arguments,1);return a.replace(e,function(d,c){return b[c]})}return a={now:b.now,toString:function(a){if(!a){a=new b()}return a.getFullYear()+'-'+c(a.getMonth()+1,2,'0')+'-'+c(a.getDate(),2,'0')+'T'+c(a.getHours(),2,'0')+':'+c(a.getMinutes(),2,'0')+':'+c(a.getSeconds(),2,'0')},getElapsed:function(b,c){return Math.abs(b-(c||a.now()))},useStrict:!1,formatCodeToRegex:function(c,d){var b=a.parseCodes[c];if(b){b=typeof b==='function'?b():b;a.parseCodes[c]=b}return b?Ext.applyIf({c:b.c?xf(b.c,d||'{0}'):b.c},b):{g:0,c:null,s:Ext.String.escapeRegex(c)}},parseFunctions:{'MS':function(c,d){var a=(c||'').match(f);return a?new b(((a[1]||'')+a[2])*1):null},'time':function(c,d){var a=parseInt(c,10);if(a||a===0){return new b(a)}return null},'timestamp':function(c,d){var a=parseInt(c,10);if(a||a===0){return new b(a*1000)}return null}},parseRegexes:[],formatFunctions:{'MS':function(){return '\\/Date('+this.getTime()+')\\/'},'time':function(){return this.getTime().toString()},'timestamp':function(){return a.format(this,'U')}},y2kYear:50,MILLI:'ms',SECOND:'s',MINUTE:'mi',HOUR:'h',DAY:'d',MONTH:'mo',YEAR:'y',defaults:{},dayNames:['Sunday','Monday','Tuesday','Wednesday','Thursday','Friday','Saturday'],monthNames:['January','February','March','April','May','June','July','August','September','October','November','December'],monthNumbers:{January:0,Jan:0,February:1,Feb:1,March:2,Mar:2,April:3,Apr:3,May:4,June:5,Jun:5,July:6,Jul:6,August:7,Aug:7,September:8,Sep:8,October:9,Oct:9,November:10,Nov:10,December:11,Dec:11},defaultFormat:'m/d/Y',getShortMonthName:function(b){return a.monthNames[b].substring(0,3)},getShortDayName:function(b){return a.dayNames[b].substring(0,3)},getMonthNumber:function(b){return a.monthNumbers[b.substring(0,1).toUpperCase()+b.substring(1,3).toLowerCase()]},formatContainsHourInfo:function(a){return h.test(a.replace(d,''))},formatContainsDateInfo:function(a){return g.test(a.replace(d,''))},unescapeFormat:function(a){return a.replace(i,'')},formatCodes:{d:"Ext.String.leftPad(m.getDate(), 2, '0')",D:'Ext.Date.getShortDayName(m.getDay())',j:'m.getDate()',l:'Ext.Date.dayNames[m.getDay()]',N:'(m.getDay() ? m.getDay() : 7)',S:'Ext.Date.getSuffix(m)',w:'m.getDay()',z:'Ext.Date.getDayOfYear(m)',W:"Ext.String.leftPad(Ext.Date.getWeekOfYear(m), 2, '0')",F:'Ext.Date.monthNames[m.getMonth()]',m:"Ext.String.leftPad(m.getMonth() + 1, 2, '0')",M:'Ext.Date.getShortMonthName(m.getMonth())',n:'(m.getMonth() + 1)',t:'Ext.Date.getDaysInMonth(m)',L:'(Ext.Date.isLeapYear(m) ? 1 : 0)',o:'(m.getFullYear() + (Ext.Date.getWeekOfYear(m) == 1 && m.getMonth() > 0 ? +1 : (Ext.Date.getWeekOfYear(m) >= 52 && m.getMonth() < 11 ? -1 : 0)))',Y:"Ext.String.leftPad(m.getFullYear(), 4, '0')",y:"('' + m.getFullYear()).substring(2, 4)",a:"(m.getHours() < 12 ? 'am' : 'pm')",A:"(m.getHours() < 12 ? 'AM' : 'PM')",g:'((m.getHours() % 12) ? m.getHours() % 12 : 12)',G:'m.getHours()',h:"Ext.String.leftPad((m.getHours() % 12) ? m.getHours() % 12 : 12, 2, '0')",H:"Ext.String.leftPad(m.getHours(), 2, '0')",i:"Ext.String.leftPad(m.getMinutes(), 2, '0')",s:"Ext.String.leftPad(m.getSeconds(), 2, '0')",u:"Ext.String.leftPad(m.getMilliseconds(), 3, '0')",O:'Ext.Date.getGMTOffset(m)',P:'Ext.Date.getGMTOffset(m, true)',T:'Ext.Date.getTimezone(m)',Z:'(m.getTimezoneOffset() * -60)',c:function(){var e='Y-m-dTH:i:sP',d=[],b,f=e.length,c;for(b=0;b me.y2kYear ? 1900 + ty : 2000 + ty;\n',s:'(\\d{2})'},a:{g:1,c:'if (/(am)/i.test(results[{0}])) {\nif (!h || h == 12) { h = 0; }\n} else { if (!h || h < 12) { h = (h || 0) + 12; }}',s:'(am|pm|AM|PM)',calcAtEnd:!0},A:{g:1,c:'if (/(am)/i.test(results[{0}])) {\nif (!h || h == 12) { h = 0; }\n} else { if (!h || h < 12) { h = (h || 0) + 12; }}',s:'(AM|PM|am|pm)',calcAtEnd:!0},g:{g:1,c:'h = parseInt(results[{0}], 10);\n',s:'(1[0-2]|[0-9])'},G:{g:1,c:'h = parseInt(results[{0}], 10);\n',s:'(2[0-3]|1[0-9]|[0-9])'},h:{g:1,c:'h = parseInt(results[{0}], 10);\n',s:'(1[0-2]|0[1-9])'},H:{g:1,c:'h = parseInt(results[{0}], 10);\n',s:'(2[0-3]|[0-1][0-9])'},i:{g:1,c:'i = parseInt(results[{0}], 10);\n',s:'([0-5][0-9])'},s:{g:1,c:'s = parseInt(results[{0}], 10);\n',s:'([0-5][0-9])'},u:{g:1,c:'ms = results[{0}]; ms = parseInt(ms, 10)/Math.pow(10, ms.length - 3);\n',s:'(\\d+)'},O:{g:1,c:['o = results[{0}];','var sn = o.substring(0,1),','hr = o.substring(1,3)*1 + Math.floor(o.substring(3,5) / 60),','mn = o.substring(3,5) % 60;',"o = ((-12 <= (hr*60 + mn)/60) && ((hr*60 + mn)/60 <= 14))? (sn + Ext.String.leftPad(hr, 2, '0') + Ext.String.leftPad(mn, 2, '0')) : null;\n"].join('\n'),s:'([+-]\\d{4})'},P:{g:1,c:['o = results[{0}];','var sn = o.substring(0,1),','hr = o.substring(1,3)*1 + Math.floor(o.substring(4,6) / 60),','mn = o.substring(4,6) % 60;',"o = ((-12 <= (hr*60 + mn)/60) && ((hr*60 + mn)/60 <= 14))? (sn + Ext.String.leftPad(hr, 2, '0') + Ext.String.leftPad(mn, 2, '0')) : null;\n"].join('\n'),s:'([+-]\\d{2}:\\d{2})'},T:{g:0,c:null,s:'[A-Z]{1,5}'},Z:{g:1,c:'zz = results[{0}] * 1;\nzz = (-43200 <= zz && zz <= 50400)? zz : null;\n',s:'([+-]?\\d{1,5})'},c:function(){var d=[],b=[a.formatCodeToRegex('Y',1),a.formatCodeToRegex('m',2),a.formatCodeToRegex('d',3),a.formatCodeToRegex('H',4),a.formatCodeToRegex('i',5),a.formatCodeToRegex('s',6),{c:"ms = results[7] || '0'; ms = parseInt(ms, 10)/Math.pow(10, ms.length - 3);\n"},{c:['if(results[8]) {',"if(results[8] == 'Z'){",'zz = 0;',"}else if (results[8].indexOf(':') > -1){",a.formatCodeToRegex('P',8).c,'}else{',a.formatCodeToRegex('O',8).c,'}','}'].join('\n')}],c,e;for(c=0,e=b.length;c0?'-':'+')+Ext.String.leftPad(Math.floor(Math.abs(a)/60),2,'0')+(b?':':'')+Ext.String.leftPad(Math.abs(a%60),2,'0')},getDayOfYear:function(c){var e=0,b=a.clone(c),f=c.getMonth(),d;for(d=0,b.setDate(1),b.setMonth(0);d28){d=Math.min(d,a.getLastDateOfMonth(a.add(a.getFirstDateOfMonth(f),a.MONTH,c)).getDate())};b.setDate(d);b.setMonth(f.getMonth()+c);break;case a.YEAR:d=f.getDate();if(d>28){d=Math.min(d,a.getLastDateOfMonth(a.add(a.getFirstDateOfMonth(f),a.YEAR,c)).getDate())};b.setDate(d);b.setFullYear(f.getFullYear()+c);break;}}if(g){switch(h.toLowerCase()){case a.MILLI:e=1;break;case a.SECOND:e=1000;break;case a.MINUTE:e=1000*60;break;case a.HOUR:e=1000*60*60;break;case a.DAY:e=1000*60*60*24;break;case a.MONTH:d=a.getDaysInMonth(b);e=1000*60*60*24*d;break;case a.YEAR:d=a.isLeapYear(b)?366:365;e=1000*60*60*24*d;break;}if(e){b.setTime(b.getTime()+e*g)}}return b},subtract:function(d,b,c){return a.add(d,b,-c)},between:function(c,b,d){var a=c.getTime();return b.getTime()<=a&&a<=d.getTime()},compat:function(){var c,g=['useStrict','formatCodeToRegex','parseFunctions','parseRegexes','formatFunctions','y2kYear','MILLI','SECOND','MINUTE','HOUR','DAY','MONTH','YEAR','defaults','dayNames','monthNames','monthNumbers','getShortMonthName','getShortDayName','getMonthNumber','formatCodes','isValid','parseDate','getFormatCode','createFormat','createParser','parseCodes'],h=['dateFormat','format','getTimezone','getGMTOffset','getDayOfYear','getWeekOfYear','isLeapYear','getFirstDayOfMonth','getLastDayOfMonth','getDaysInMonth','getSuffix','clone','isDST','clearTime','add','between'],j=g.length,i=h.length,f,e,d;for(d=0;dd){return b-1};return b;case a.YEAR:b=d.getFullYear()-e.getFullYear();if(a.add(e,f,b)>d){return b-1}else {return b};}},align:function(e,f,d){var c=new b(+e);switch(f.toLowerCase()){case a.MILLI:return c;case a.SECOND:c.setUTCSeconds(c.getUTCSeconds()-c.getUTCSeconds()%d);c.setUTCMilliseconds(0);return c;case a.MINUTE:c.setUTCMinutes(c.getUTCMinutes()-c.getUTCMinutes()%d);c.setUTCSeconds(0);c.setUTCMilliseconds(0);return c;case a.HOUR:c.setUTCHours(c.getUTCHours()-c.getUTCHours()%d);c.setUTCMinutes(0);c.setUTCSeconds(0);c.setUTCMilliseconds(0);return c;case a.DAY:if(d===7||d===14){c.setUTCDate(c.getUTCDate()-c.getUTCDay()+1)};c.setUTCHours(0);c.setUTCMinutes(0);c.setUTCSeconds(0);c.setUTCMilliseconds(0);return c;case a.MONTH:c.setUTCMonth(c.getUTCMonth()-(c.getUTCMonth()-1)%d,1);c.setUTCHours(0);c.setUTCMinutes(0);c.setUTCSeconds(0);c.setUTCMilliseconds(0);return c;case a.YEAR:c.setUTCFullYear(c.getUTCFullYear()-c.getUTCFullYear()%d,1,1);c.setUTCHours(0);c.setUTCMinutes(0);c.setUTCSeconds(0);c.setUTCMilliseconds(0);return e;}}}}();Ext.Function=function(){var i=0,f,c=[],l=[],m=0,e={},d=window,b=Ext.global,h=!!(b.setImmediate&&b.clearImmediate),k=d.requestAnimationFrame||d.webkitRequestAnimationFrame||d.mozRequestAnimationFrame||d.oRequestAnimationFrame||function(c){var b=Ext.now(),a=Math.max(0,16-(b-i)),e=d.setTimeout(function(){c(b+a)},a);i=b+a;return e},g=function(){var h=c.length,g,d,a;f=null;for(d=0;d0){return setTimeout(function(){if(Ext.elevateFunction){Ext.elevateFunction(a)}else {a()}},b)}a();return 0},interval:function(a,c,d,e,b){a=Ext.Function.bind(a,d,e,b);return setInterval(function(){if(Ext.elevateFunction){Ext.elevateFunction(a)}else {a()}},c)},createSequence:function(a,b,c){if(!b){return a}else {return function(){var d=a.apply(this,arguments);b.apply(c||this,arguments);return d}}},createBuffered:function(b,c,d,e){var a;return function(){var f=e||Array.prototype.slice.call(arguments,0),g=d||this;if(a){clearTimeout(a)}a=setTimeout(function(){if(Ext.elevateFunction){Ext.elevateFunction(b,g,f)}else {b.apply(g,f)}},c)}},createAnimationFrame:function(f,d,e,c){var b;c=c||3;return function(){var g=e||Array.prototype.slice.call(arguments,0);d=d||this;if(c===3&&b){a.cancelAnimationFrame(b)}if(c&1||!b){b=a.requestAnimationFrame(function(){b=null;f.apply(d,g)})}}},requestAnimationFrame:function(i,d,h){var a=++m,b=Array.prototype.slice.call(arguments,0);b[3]=a;e[a]=1;c.push(b);if(!f){f=k(Ext.elevateFunction?j:g)}return a},cancelAnimationFrame:function(a){delete e[a]},createThrottled:function(h,f,a){var e=0,d,c,b,g=function(){if(Ext.elevateFunction){Ext.elevateFunction(h,a,c)}else {h.apply(a,c)}e=Ext.now();b=null};return function(){if(!a){a=this}d=Ext.now()-e;c=arguments;if(d>=f){clearTimeout(b);g()}else {if(!b){b=Ext.defer(g,f-d)}}}},createBarrier:function(a,c,b){return function(){if(!--a){c.apply(b,arguments)}}},interceptBefore:function(b,a,e,d){var c=b[a]||Ext.emptyFn;return b[a]=function(){var f=e.apply(d||this,arguments);c.apply(this,arguments);return f}},interceptAfter:function(b,a,e,d){var c=b[a]||Ext.emptyFn;return b[a]=function(){c.apply(this,arguments);return e.apply(d||this,arguments)}},makeCallback:function(b,a){return function(){return a[b].apply(a,arguments)}},memoize:function(e,c,a){var b={},d=a&&Ext.isFunction(a);return function(g){var f=d?a.apply(c,arguments):g;if(!(f in b)){b[f]=e.apply(c,arguments)}return b[f]}}};Ext.asap=h?function(b,d,c){if(d!=null||c!=null){b=a.bind(b,d,c)}return setImmediate(function(){if(Ext.elevateFunction){Ext.elevateFunction(b)}else {b()}})}:function(b,d,c){if(d!=null||c!=null){b=a.bind(b,d,c)}return setTimeout(function(){if(Ext.elevateFunction){Ext.elevateFunction(b)}else {b()}},0,!0)},Ext.asapCancel=h?function(a){clearImmediate(a)}:function(a){clearTimeout(a)};Ext.defer=a.defer;Ext.interval=a.interval;Ext.pass=a.pass;Ext.bind=a.bind;Ext.deferCallback=a.requestAnimationFrame;return a}();Ext.Number=new function(){var b=this,d=(0.9).toFixed()!=='1',c=Math,a={count:!1,inclusive:!1,wrap:!0};Ext.apply(b,{Clip:{DEFAULT:a,COUNT:Ext.applyIf({count:!0},a),INCLUSIVE:Ext.applyIf({inclusive:!0},a),NOWRAP:Ext.applyIf({wrap:!1},a)},clipIndices:function(d,c,f){f=f||a;var h=0,i=f.wrap,g,b,e;c=c||[];for(e=0;e<2;++e){g=b;b=c[e];if(b==null){b=h}else {if(e&&f.count){b+=g;b=b>d?d:b}else {if(i){b=b<0?d+b:b}if(e&&f.inclusive){++b}b=b<0?0:b>d?d:b}}h=d}c[0]=g;c[1]=ba?a:d},snap:function(a,c,e,f){var d;if(a===undefined||a=c){a+=c}else {if(d*2<-c){a-=c}}}}return b.constrain(a,e,f)},snapInRange:function(a,d,c,e){var f;c=c||0;if(a===undefined||a=d){a+=d}}if(e!==undefined){if(a>(e=b.snapInRange(e,d,c))){a=e}}return a},sign:function(a){a=+a;if(a===0||isNaN(a)){return a}return a>0?1:-1},toFixed:d?function(d,a){a=a||0;var b=c.pow(10,a);return (c.round(d*b)/b).toFixed(a)}:function(b,a){return b.toFixed(a)},from:function(a,b){if(isFinite(a)){a=parseFloat(a)}return !isNaN(a)?a:b},randomInt:function(a,b){return c.floor(c.random()*(b-a+1)+a)},correctFloat:function(a){return parseFloat(a.toPrecision(14))}});Ext.num=function(){return b.from.apply(this,arguments)}}();(function(){var b=function(){},d=/^\?/,f=/(\[):?([^\]]*)\]/g,e=/^([^\[]+)/,c=/\+/g,a=Ext.Object={chain:Object.create||function(a){b.prototype=a;var c=new b();b.prototype=null;return c},clear:function(a){for(var b in a){delete a[b]}return a},freeze:Object.freeze?function(b,c){if(b&&typeof b==='object'&&!Object.isFrozen(b)){Object.freeze(b);if(c){for(var d in b){a.freeze(b[d],c)}}}return b}:Ext.identityFn,toQueryObjects:function(e,c,f){var g=a.toQueryObjects,d=[],b,h;if(Ext.isArray(c)){for(b=0,h=c.length;b0){o=q.split('=');a=o[0];a=a.replace(c,'%20');a=decodeURIComponent(a);g=o[1];if(g!==undefined){g=g.replace(c,'%20');g=decodeURIComponent(g)}else {g=''}if(!v){if(i.hasOwnProperty(a)){if(!Ext.isArray(i[a])){i[a]=[i[a]]}i[a].push(g)}else {i[a]=g}}else {m=a.match(f);r=a.match(e);a=r[0];k=[];if(m===null){i[a]=g;continue}for(h=0,l=m.length;h@:]*)(?:[@]([^<>@:]+))?[>](.+)$/,resolveResource:function(b){var c=b,a;if(b&&b.charAt(0)==='<'){a=Ext._resourcePoolRe.exec(b);if(a){c=Ext.getResourcePath(a[3],a[1],a[2])}}return c},urlEncode:function(){var a=Ext.Array.from(arguments),b='';if(Ext.isString(a[1])){b=a[1]+'&';a[1]=!1}return b+Ext.Object.toQueryString.apply(Ext.Object,a)},urlDecode:function(){return Ext.Object.fromQueryString.apply(Ext.Object,arguments)},getScrollbarSize:function(d){var b=Ext._scrollbarSize;if(d||!b){var c=document.body,a=document.createElement('div');a.style.width=a.style.height='100px';a.style.overflow='scroll';a.style.position='absolute';c.appendChild(a);Ext._scrollbarSize=b={width:a.offsetWidth-a.clientWidth,height:a.offsetHeight-a.clientHeight};c.removeChild(a)}return b},typeOf:function(){var a=/\S/,d=Object.prototype.toString,c={number:1,string:1,'boolean':1,'undefined':1},b={'[object Array]':'array','[object Date]':'date','[object Boolean]':'boolean','[object Number]':'number','[object RegExp]':'regexp'};return function(e){if(e===null){return 'null'}var f=typeof e,g,h;if(c[f]){return f}g=b[h=d.call(e)];if(g){return g}if(f==='function'){return 'function'}if(f==='object'){if(e.nodeType!==undefined){if(e.nodeType===3){return a.test(e.nodeValue)?'textnode':'whitespace'}else {return 'element'}}return 'object'}return h}}(),factory:function(a,f,b,d){var e=Ext.ClassManager,c;if(!a||a.isInstance){if(b&&b!==a){b.destroy()}return a}if(d){if(typeof a==='string'){return e.instantiateByAlias(d+'.'+a)}else {if(Ext.isObject(a)&&'type' in a){return e.instantiateByAlias(d+'.'+a.type,a)}}}if(a===!0){return b||Ext.create(f)}if('xtype' in a){c=e.instantiateByAlias('widget.'+a.xtype,a)}else {if('xclass' in a){c=Ext.create(a.xclass,a)}}if(c){if(b){b.destroy()}return c}if(b){return b.setConfig(a)}return Ext.create(f,a)},log:function(){var a=function(){};a.info=a.warn=a.error=Ext.emptyFn;return a}()});(function(){var b=[''],c=/([^\d\.])/,f=/[^\d]/g,g=/[\-+]/g,h=/\s/g,e=/_/g,d={classic:1,modern:1},a;Ext.Version=a=function(k,p){var b=this,n=b.padModes,o,m,d,h,j,l,i;if(k.isVersion){k=k.version}b.version=i=String(k).toLowerCase().replace(e,'.').replace(g,'');o=i.charAt(0);if(o in n){i=i.substring(1);d=n[o]}else {d=p?n[p]:0}b.pad=d;l=i.search(c);b.shortVersion=i;if(l!==-1){b.release=j=i.substr(l,k.length);b.shortVersion=i.substr(0,l);j=a.releaseValueMap[j]||j}b.releaseValue=j||d;b.shortVersion=b.shortVersion.replace(f,'');b.parts=h=i.split('.');for(m=h.length;m--;){h[m]=parseInt(h[m],10)}if(d===Infinity){h.push(d)}b.major=h[0]||d;b.minor=h[1]||d;b.patch=h[2]||d;b.build=h[3]||d;return b};a.prototype={isVersion:!0,padModes:{'~':NaN,'^':Infinity},release:'',compareTo:function(f){var g=this,m=g.pad,j=g.parts,h=j.length,e=f.isVersion?f:new a(f),n=e.pad,k=e.parts,i=k.length,l=Math.max(h,i),b,c,d;for(b=0;bd){return 1}}c=g.releaseValue;d=e.releaseValue;if(cd){return 1}return 0},toString:function(){return this.version},valueOf:function(){return this.version},getMajor:function(){return this.major},getMinor:function(){return this.minor},getPatch:function(){return this.patch},getBuild:function(){return this.build},getRelease:function(){return this.release},getReleaseValue:function(){return this.releaseValue},isGreaterThan:function(a){return this.compareTo(a)>0},isGreaterThanOrEqual:function(a){return this.compareTo(a)>=0},isLessThan:function(a){return this.compareTo(a)<0},isLessThanOrEqual:function(a){return this.compareTo(a)<=0},equals:function(a){return this.compareTo(a)===0},match:function(a){a=String(a);return this.version.substr(0,a.length)===a},toArray:function(){var a=this;return [a.getMajor(),a.getMinor(),a.getPatch(),a.getBuild(),a.getRelease()]},getShortVersion:function(){return this.shortVersion},gt:function(a){return this.compareTo(a)>0},lt:function(a){return this.compareTo(a)<0},gtEq:function(a){return this.compareTo(a)>=0},ltEq:function(a){return this.compareTo(a)<=0}};Ext.apply(a,{aliases:{from:{extjs:'ext',core:'core',touch:'modern'},to:{ext:['extjs'],'core':['core'],modern:['touch']}},releaseValueMap:{dev:-6,alpha:-5,a:-5,beta:-4,b:-4,rc:-3,'#':-2,p:-1,pl:-1},getComponentValue:function(a){return !a?0:isNaN(a)?this.releaseValueMap[a]||a:parseInt(a,10)},compare:function(b,c){var d=b.isVersion?b:new a(b);return d.compareTo(c)},set:function(g,f,c){var b=a.aliases.to[f],d=c.isVersion?c:new a(c),e;g[f]=d;if(b){for(e=b.length;e-->0;){g[b[e]]=d}}return d}});Ext.apply(Ext,{compatVersions:{},versions:{},lastRegisteredVersion:null,getCompatVersion:function(b){var c=Ext.compatVersions,d;if(!b){d=c.ext||c.touch||c.core}else {d=c[a.aliases.from[b]||b]}return d||Ext.getVersion(b)},setCompatVersion:function(b,c){a.set(Ext.compatVersions,b,c)},setVersion:function(b,c){if(b in d){Ext.toolkit=b}Ext.lastRegisteredVersion=a.set(Ext.versions,b,c);return this},getVersion:function(c){var b=Ext.versions;if(!c){return b.ext||b.touch||b.core}return b[a.aliases.from[c]||c]},checkVersion:function(o,j){var p=Ext.isArray(o),s=a.aliases.from,q=p?o:b,t=q.length,n=Ext.versions,r=n.ext||n.touch,l,c,f,i,g,m,d,e,k;if(!p){b[0]=o}for(l=0;l=0){d=d.replace(h,'')}c=d.indexOf('@');if(c<0){e=d;k=r}else {m=d.substring(0,c);if(!(k=n[s[m]||m])){if(j){return !1}continue}e=d.substring(c+1)}c=e.indexOf('-');if(c<0){if(e.charAt(c=e.length-1)==='+'){i=e.substring(0,c);g=null}else {i=g=e}}else {if(c>0){i=e.substring(0,c);g=e.substring(c+1)}else {i=null;g=e.substring(c+1)}}f=!0;if(i){i=new a(i,'~');f=i.ltEq(k)}if(f&&g){g=new a(g,'~');f=g.gtEq(k)}}if(f){if(!j){return !0}}else {if(j){return !1}}}return !!j},deprecate:function(b,e,c,d){if(a.compare(Ext.getVersion(b),e)<1){c.call(d)}}})})();(function(c){var d=c&&c.packages||{},b=c&&c.compatibility,a,e;for(a in d){e=d[a];Ext.setVersion(a,e.version)}if(b){if(Ext.isString(b)){Ext.setCompatVersion('core',b)}else {for(a in b){Ext.setCompatVersion(a,b[a])}}}if(!d.ext&&!d.touch){Ext.setVersion('ext','6.0.1.250');Ext.setVersion('core','6.0.1.250')}})(Ext.manifest);Ext.Config=function(b){var c=this,a=b.charAt(0).toUpperCase()+b.substr(1);c.name=b;c.names={internal:'_'+b,initializing:'is'+a+'Initializing',apply:'apply'+a,update:'update'+a,get:'get'+a,set:'set'+a,initGet:'initGet'+a,changeEvent:b.toLowerCase()+'change'};c.root=c};Ext.Config.map={};Ext.Config.get=function(a){var b=Ext.Config.map,c=b[a]||(b[a]=new Ext.Config(a));return c};Ext.Config.prototype={self:Ext.Config,isConfig:!0,getGetter:function(){return this.getter||(this.root.getter=this.makeGetter())},getInitGetter:function(){return this.initGetter||(this.root.initGetter=this.makeInitGetter())},getSetter:function(){return this.setter||(this.root.setter=this.makeSetter())},getEventedSetter:function(){return this.eventedSetter||(this.root.eventedSetter=this.makeEventedSetter())},getInternalName:function(a){return a.$configPrefixed?this.names.internal:this.name},mergeNew:function(b,d,f,e){var a,c;if(!d){a=b}else {if(!b){a=d}else {a=Ext.Object.chain(d);for(c in b){if(!e||!(c in a)){a[c]=b[c]}}}}return a},mergeSets:function(a,f,e){var b=f?Ext.Object.chain(f):{},c,d;if(a instanceof Array){for(c=a.length;c--;){d=a[c];if(!e||!(d in b)){b[d]=!0}}}else {if(a){if(a.constructor===Object){for(c in a){d=a[c];if(!e||!(c in b)){b[c]=d}}}else {if(!e||!(a in b)){b[a]=!0}}}}return b},makeGetter:function(){var b=this.name,a=this.names.internal;return function(){var c=this.$configPrefixed?a:b;return this[c]}},makeInitGetter:function(){var e=this.name,a=this.names,d=a.set,c=a.get,b=a.initializing;return function(){var a=this;a[b]=!0;delete a[c];a[d](a.config[e]);delete a[b];return a[c].apply(a,arguments)}},makeSetter:function(){var g=this.name,a=this.names,e=a.internal,f=a.get,d=a.apply,c=a.update,b;b=function(b){var a=this,h=a.$configPrefixed?e:g,i=a[h];delete a[f];if(!a[d]||(b=a[d](b,i))!==undefined){if(b!==(i=a[h])){a[h]=b;if(a[c]){a[c](b,i)}}}return a};b.$isDefault=!0;return b},makeEventedSetter:function(){var i=this.name,a=this.names,f=a.internal,h=a.get,d=a.apply,b=a.update,e=a.changeEvent,g=function(a,c,e,d){a[d]=c;if(a[b]){a[b](c,e)}},c;c=function(c){var a=this,k=a.$configPrefixed?f:i,j=a[k];delete a[h];if(!a[d]||(c=a[d](c,j))!==undefined){if(c!==(j=a[k])){if(a.isConfiguring){a[k]=c;if(a[b]){a[b](c,j)}}else {a.fireEventedAction(e,[a,c,j],g,a,[a,c,j,k])}}}return a};c.$isDefault=!0;return c}};(function(){var c=Ext.Config,b=c.map,a=Ext.Object;Ext.Configurator=function(d){var b=this,e=d.prototype,c=d.superclass?d.superclass.self.$config:null;b.cls=d;b.superCfg=c;if(c){b.configs=a.chain(c.configs);b.cachedConfigs=a.chain(c.cachedConfigs);b.initMap=a.chain(c.initMap);b.values=a.chain(c.values);b.needsFork=c.needsFork}else {b.configs={};b.cachedConfigs={};b.initMap={};b.values={}}e.config=e.defaultConfig=b.values;d.$config=b};Ext.Configurator.prototype={self:Ext.Configurator,needsFork:!1,initList:null,add:function(t,l){var i=this,n=i.cls,k=i.configs,v=i.cachedConfigs,p=i.initMap,g=n.prototype,r=l&&l.$config.configs,u=i.values,m,f,s,h,b,j,e,q,o,d;for(e in t){d=t[e];m=d&&d.constructor===Object;f=m&&'$value' in d?d:null;if(f){s=!!f.cached;d=f.$value;m=d&&d.constructor===Object}h=f&&f.merge;b=k[e];if(b){if(l){h=b.merge;if(!h){continue}f=null}else {h=h||b.merge}j=u[e];if(h){d=h.call(b,d,j,n,l)}else {if(m){if(j&&j.constructor===Object){d=a.merge({},j,d)}}}}else {if(r){b=r[e];f=null}else {b=c.get(e)}k[e]=b;if(b.cached||s){v[e]=!0}q=b.names;if(!g[o=q.get]){g[o]=b.getter||b.getGetter()}if(!g[o=q.set]){g[o]=f&&f.evented?b.eventedSetter||b.getEventedSetter():b.setter||b.getSetter()}}if(f){if(b.owner!==n){k[e]=b=Ext.Object.chain(b);b.owner=n}Ext.apply(b,f);delete b.$value}if(!i.needsFork&&d&&(d.constructor===Object||d instanceof Array)){i.needsFork=!0}if(d!==null){p[e]=!0}else {if(g.$configPrefixed){g[k[e].names.internal]=null}else {g[k[e].name]=null}if(e in p){p[e]=!1}}u[e]=d}},configure:function(c,h){var k=this,u=k.configs,x=k.initMap,q=k.initListMap,o=k.initList,j=k.cls.prototype,i=k.values,r=0,v=!o,n,b,m,w,d,p,l,f,e,g,t,s,y;i=k.needsFork?a.fork(i):a.chain(i);c.isConfiguring=!0;if(v){k.initList=o=[];k.initListMap=q={};c.isFirstInstance=!0;for(e in x){w=x[e];b=u[e];t=b.cached;if(w){f=b.names;g=i[e];if(!j[f.set].$isDefault||j[f.apply]||j[f.update]||typeof g==='object'){if(t){(n||(n=[])).push(b)}else {o.push(b);q[e]=!0}c[f.get]=b.initGetter||b.getInitGetter()}else {j[b.getInternalName(j)]=g}}else {if(t){j[b.getInternalName(j)]=undefined}}}}l=n&&n.length;if(l){for(d=0;d0){for(a=0;ac.maxSize){c.unlinkEntry(f.prev,!0);--c.count}}return d.value},evict:Ext.emptyFn,linkEntry:function(c){var d=this.head,e=d.next;c.next=e;c.prev=d;d.next=c;e.prev=c},unlinkEntry:function(c,f){var d=c.next,e=c.prev;e.next=d;d.prev=e;if(f){this.evict(c.key,c.value)}}};a.destroy=a.clear})();(function(){var a,d=Ext.Base,b=d.$staticMembers,c=function(a,b){return a.length-b.length||(ab?1:0)};function makeCtor(a){function constructor(){return this.constructor.apply(this,arguments)||null}return constructor}Ext.Class=a=function(b,c,d){if(typeof b!='function'){d=c;c=b;b=null}if(!c){c={}}b=a.create(b,c);a.process(b,c,d);return b};Ext.apply(a,{makeCtor:makeCtor,onBeforeCreated:function(a,c,b){a.addMembers(c);b.onCreated.call(a,a)},create:function(a,f){var e=b.length,c;if(!a){a=makeCtor()}while(e--){c=b[e];a[c]=d[c]}return a},process:function(l,f,k){var j=f.preprocessors||a.defaultPreprocessors,o=this.preprocessors,e={onBeforeCreated:this.onBeforeCreated},d=[],b,c,g,n,h,m,i;delete f.preprocessors;l._classHooks=e;for(g=0,n=j.length;g0){b=h.test(c[d])}c=o[a];if(c&&!b){d=c.length;while(!b&&d-->0){b=h.test(c[d])}}}if(b){i[a]=1;l.push(a)}}}}}return l},getPath:function(a){var e=this,d=e.paths,b='',c;if(a in d){b=d[a]}else {c=e.getPrefix(a);if(c){a=a.substring(c.length+1);b=d[c];if(b){b+='/'}}b+=a.replace(e.dotRe,'/')+'.js'}return b},getPrefix:function(a){if(a in this.paths){return a}var d=this.getPrefixes(),e=d.length,b,c;while(e-->0){b=(c=d[e]).length;if(b0){b=i[d];f=c;c=b.value||c[b.name];if(!c&&h){f[b.name]=c={}}}return c},setNamespace:function(f,d){var b=a.getNamespaceEntry(f),c=Ext.global;if(b.parent){c=a.lookupName(b.parent,!0)}c[b.name]=d;return d},setXType:function(i,d){var f=i.$className,k=f?i:a.get(f=i),b=k.prototype,j=b.xtypes,c=b.xtypesChain,h=b.xtypesMap;if(!b.hasOwnProperty('xtypes')){b.xtypes=j=[];b.xtypesChain=c=c?c.slice(0):[];b.xtypesMap=h=Ext.apply({},h)}a.addAlias(f,'widget.'+d,!0);j.push(d);c.push(d);h[d]=!0},set:function(b,d){var c=a.getName(d);a.classes[b]=a.setNamespace(b,d);if(c&&c!==b){a.addAlternate(c,b)}return a},get:function(b){return a.classes[b]||a.lookupName(b,!1)},addNameAliasMappings:function(b){a.addAlias(b)},addNameAlternateMappings:function(b){a.addAlternate(b)},getByAlias:function(b){return a.get(a.getNameByAlias(b))},getByConfig:function(c,d){var f=c.xclass,b;if(f){b=f}else {b=c.xtype;if(b){d='widget.'}else {b=c.type}b=a.getNameByAlias(d+b)}return a.get(b)},getName:function(a){return a&&a.$className||''},getClass:function(a){return a&&a.self||null},create:function(c,b,f){var d=q(c);if(typeof b==='function'){b=b(d)}b.$className=c;return new n(d,b,function(){var m=b.postprocessors||a.defaultPostprocessors,s=a.postprocessors,i=[],d,j,q,k,p,h,l;delete b.postprocessors;for(j=0,q=m.length;j0;){c=a.lookupName(arguments[b],!0)}return c}});Ext.addRootNamespaces=a.addRootNamespaces;Ext.createWidget=Ext.widget;Ext.ns=Ext.namespace;n.registerPreprocessor('className',function(b,a){if('$className' in a){b.$className=a.$className}},!0,'first');n.registerPreprocessor('alias',function(q,d){var l=q.prototype,c=g(d.xtype),i=g(d.alias),j='widget.',p=j.length,k=Array.prototype.slice.call(l.xtypesChain||[]),h=Ext.merge({},l.xtypesMap||{}),a,f,m,b;for(a=0,f=i.length;a=d){Ext[o+'p']=!0}}}if(n.is.Opera&&parseInt(a,10)<=12){Ext.isOpera12m=!0}Ext.chromeVersion=Ext.isChrome?a:0;Ext.firefoxVersion=Ext.isFirefox?a:0;Ext.ieVersion=Ext.isIE?a:0;Ext.operaVersion=Ext.isOpera?a:0;Ext.safariVersion=Ext.isSafari?a:0;Ext.webKitVersion=Ext.isWebKit?a:0;this.setFlag(c+a,!0,r);this.setFlag(c+f.getShortVersion())}for(d in j){if(j.hasOwnProperty(d)){h=j[d];this.setFlag(h,c===h)}}this.setFlag(h);if(l){this.setFlag(g+(l.getMajor()||''));this.setFlag(g+l.getShortVersion())}for(d in k){if(k.hasOwnProperty(d)){h=k[d];this.setFlag(h,g===h,r)}}this.setFlag('Standalone',!!navigator.standalone);this.setFlag('Ripple',!!document.getElementById('tinyhippos-injected')&&!Ext.isEmpty(window.top.ripple));this.setFlag('WebWorks',!!window.blackberry);if(window.PhoneGap!==undefined||window.Cordova!==undefined||window.cordova!==undefined){q=!0;this.setFlag('PhoneGap');this.setFlag('Cordova')}if(/(iPhone|iPod|iPad).*AppleWebKit(?!.*Safari)(?!.*FBAN)/i.test(e)){q=!0}this.setFlag('WebView',q);this.isStrict=Ext.isStrict=document.compatMode==='CSS1Compat';this.isSecure=Ext.isSecure;this.identity=c+a+(this.isStrict?'Strict':'Quirks')};Ext.env.Browser.prototype={constructor:Ext.env.Browser,engineNames:{webkit:'WebKit',gecko:'Gecko',presto:'Presto',trident:'Trident',other:'Other'},enginePrefixes:{webkit:'AppleWebKit/',gecko:'Gecko/',presto:'Presto/',trident:'Trident/'},styleDashPrefixes:{WebKit:'-webkit-',Gecko:'-moz-',Trident:'-ms-',Presto:'-o-',Other:''},stylePrefixes:{WebKit:'Webkit',Gecko:'Moz',Trident:'ms',Presto:'O',Other:''},propertyPrefixes:{WebKit:'webkit',Gecko:'moz',Trident:'ms',Presto:'o',Other:''},is:function(a){return !!this.is[a]},name:null,version:null,engineName:null,engineVersion:null,setFlag:function(b,a,c){if(a===undefined){a=!0}this.is[b]=a;this.is[b.toLowerCase()]=a;if(c){Ext['is'+b]=a}return this},getStyleDashPrefix:function(){return this.styleDashPrefixes[this.engineName]},getStylePrefix:function(){return this.stylePrefixes[this.engineName]},getVendorProperyName:function(b){var a=this.propertyPrefixes[this.engineName];if(a.length>0){return a+Ext.String.capitalize(b)}return b},getPreferredTranslationMethod:function(a){if(typeof a==='object'&&'translationMethod' in a&&a.translationMethod!=='auto'){return a.translationMethod}else {return 'csstransform'}}};(function(a){Ext.browser=new Ext.env.Browser(a,!0);Ext.userAgent=a.toLowerCase();Ext.SSL_SECURE_URL=Ext.isSecure&&Ext.isIE?"javascript:''":'about:blank'})(Ext.global.navigator.userAgent);Ext.env.OS=function(j,k,b){var n=this,g=Ext.Boot.osNames,h=Ext.Boot.osPrefixes,a,c='',m=n.is,d,l,f,i,e;b=b||Ext.browser;for(d in h){if(h.hasOwnProperty(d)){l=h[d];f=j.match(new RegExp('(?:'+l+')([^\\s;]+)'));if(f){a=g[d];e=f[1];if(e&&e==='HTC_'){c=new Ext.Version('2.3')}else {if(e&&e==='Silk/'){c=new Ext.Version('2.3')}else {c=new Ext.Version(f[f.length-1])}}break}}}if(!a){a=g[(j.toLowerCase().match(/mac|win|linux/)||['other'])[0]];c=new Ext.Version('')}this.name=a;this.version=c;if(k){this.setFlag(k.replace(/ simulator$/i,''))}this.setFlag(a);if(c){this.setFlag(a+(c.getMajor()||''));this.setFlag(a+c.getShortVersion())}for(d in g){if(g.hasOwnProperty(d)){i=g[d];if(!m.hasOwnProperty(a)){this.setFlag(i,a===i)}}}if(this.name==='iOS'&&window.screen.height===568){this.setFlag('iPhone5')}if(b.is.Safari||b.is.Silk){if(this.is.Android2||this.is.Android3||b.version.shortVersion===501){b.setFlag('AndroidStock')}if(this.is.Android4){b.setFlag('AndroidStock');b.setFlag('AndroidStock4')}}};Ext.env.OS.prototype={constructor:Ext.env.OS,is:function(a){return !!this[a]},name:null,version:null,setFlag:function(b,a){if(a===undefined){a=!0}if(this.flags){this.flags[b]=a}this.is[b]=a;this.is[b.toLowerCase()]=a;return this}};(function(){var h=Ext.global.navigator,i=h.userAgent,e=Ext.env.OS,f=Ext.is||(Ext.is={}),a,c,b;e.prototype.flags=f;Ext.os=a=new e(i,h.platform);c=a.name;Ext['is'+c]=!0;Ext.isMac=f.Mac=f.MacOS;var d=window.location.search.match(/deviceType=(Tablet|Phone)/),g=window.deviceType;if(d&&d[1]){b=d[1]}else {if(g==='iPhone'){b='Phone'}else {if(g==='iPad'){b='Tablet'}else {if(!a.is.Android&&!a.is.iOS&&!a.is.WindowsPhone&&/Windows|Linux|MacOS/.test(c)){b='Desktop';Ext.browser.is.WebView=!!Ext.browser.is.Ripple}else {if(a.is.iPad||a.is.RIMTablet||a.is.Android3||Ext.browser.is.Silk||a.is.Android&&i.search(/mobile/i)===-1){b='Tablet'}else {b='Phone'}}}}}a.setFlag(b,!0);a.deviceType=b;delete e.prototype.flags})();Ext.feature={has:function(a){return !!this.has[a]},testElements:{},getTestElement:function(a,b){if(a===undefined){a='div'}else {if(typeof a!=='string'){return a}}if(b){return document.createElement(a)}if(!this.testElements[a]){this.testElements[a]=document.createElement(a)}return this.testElements[a]},isStyleSupported:function(a,d){var b=this.getTestElement(d).style,c=Ext.String.capitalize(a);if(typeof b[a]!=='undefined'||typeof b[Ext.browser.getStylePrefix(a)+c]!=='undefined'){return !0}return !1},isStyleSupportedWithoutPrefix:function(b,c){var a=this.getTestElement(c).style;if(typeof a[b]!=='undefined'){return !0}return !1},isEventSupported:function(e,d){if(d===undefined){d=window}var a=this.getTestElement(d),b='on'+e.toLowerCase(),c=b in a;if(!c){if(a.setAttribute&&a.removeAttribute){a.setAttribute(b,'');c=typeof a[b]==='function';if(typeof a[b]!=='undefined'){a[b]=undefined}a.removeAttribute(b)}}return c},getStyle:function(a,c){var b=a.ownerDocument.defaultView,d=b?b.getComputedStyle(a,null):a.currentStyle;return (d||a.style)[c]},getSupportedPropertyName:function(c,a){var b=Ext.browser.getVendorProperyName(a);if(b in c){return b}else {if(a in c){return a}}return null},detect:function(h){var c=this,g=document,m=c.toRun||c.tests,i=m.length,f=g.createElement('div'),k=[],j=Ext.supports,n=c.has,a,e,b,l,d;f.innerHTML='
    ';if(h){g.body.appendChild(f)}l=c.preDetected[Ext.browser.identity]||[];while(i--){b=m[i];d=l[i];a=b.name;e=b.names;if(d===undefined){if(!h&&b.ready){k.push(b);continue}d=b.fn.call(c,g,f)}if(a){j[a]=n[a]=d}else {if(e){while(e.length){a=e.pop();j[a]=n[a]=d}}}}if(h){g.body.removeChild(f)}c.toRun=k},report:function(){var b=[],c=this.tests.length,a;for(a=0;a
    ';b=a.childNodes.length===1;a.innerHTML='';return b}},{name:'touchScroll',fn:function(){var a=0;if(Ext.os.is.Desktop&&(navigator.maxTouchPoints||navigator.msMaxTouchPoints)){a=1}else {if(Ext.supports.Touch){a=2}}return a}},{name:'Touch',fn:function(){var a=navigator.msMaxTouchPoints||navigator.maxTouchPoints;if(Ext.browser.is.Chrome&&Ext.browser.version.isLessThanOrEqual(39)){return Ext.supports.TouchEvents&&a!==1||a>1}else {return Ext.supports.TouchEvents||a>0}}},{name:'TouchEvents',fn:function(){return this.isEventSupported('touchend')}},{name:'PointerEvents',fn:function(){return navigator.pointerEnabled}},{name:'MSPointerEvents',fn:function(){return navigator.msPointerEnabled}},{name:'Orientation',fn:function(){return 'orientation' in window&&this.isEventSupported('orientationchange')}},{name:'OrientationChange',fn:function(){return this.isEventSupported('orientationchange')}},{name:'DeviceMotion',fn:function(){return this.isEventSupported('devicemotion')}},{names:['Geolocation','GeoLocation'],fn:function(){return 'geolocation' in window.navigator}},{name:'SqlDatabase',fn:function(){return 'openDatabase' in window}},{name:'WebSockets',fn:function(){return 'WebSocket' in window}},{name:'Range',fn:function(){return !!document.createRange}},{name:'CreateContextualFragment',fn:function(){var a=!!document.createRange?document.createRange():!1;return a&&!!a.createContextualFragment}},{name:'History',fn:function(){return 'history' in window&&'pushState' in window.history}},{name:'Css3dTransforms',fn:function(){return this.has('CssTransforms')&&this.isStyleSupported('perspective')}},{name:'CssTransforms',fn:function(){return this.isStyleSupported('transform')}},{name:'CssTransformNoPrefix',fn:function(){return this.isStyleSupportedWithoutPrefix('transform')}},{name:'CssAnimations',fn:function(){return this.isStyleSupported('animationName')}},{names:['CssTransitions','Transitions'],fn:function(){return this.isStyleSupported('transitionProperty')}},{names:['Audio','AudioTag'],fn:function(){return !!this.getTestElement('audio').canPlayType}},{name:'Video',fn:function(){return !!this.getTestElement('video').canPlayType}},{name:'LocalStorage',fn:function(){try{if('localStorage' in window&&window['localStorage']!==null){localStorage.setItem('sencha-localstorage-test','test success');localStorage.removeItem('sencha-localstorage-test');return !0}}catch(b){}return !1}},{name:'XHR2',fn:function(){return window.ProgressEvent&&window.FormData&&window.XMLHttpRequest&&'withCredentials' in new XMLHttpRequest()}},{name:'XHRUploadProgress',fn:function(){if(window.XMLHttpRequest&&!Ext.browser.is.AndroidStock){var a=new XMLHttpRequest();return a&&'upload' in a&&'onprogress' in a.upload}return !1}},{name:'NumericInputPlaceHolder',fn:function(){return !(Ext.browser.is.AndroidStock4&&Ext.os.version.getMinor()<2)}},{name:'matchesSelector',fn:function(){var a=document.documentElement,d='matches',e='webkitMatchesSelector',b='msMatchesSelector',c='mozMatchesSelector';return a[d]?d:a[e]?e:a[b]?b:a[c]?c:null}},{name:'RightMargin',ready:!0,fn:function(c,b){var a=c.defaultView;return !(a&&a.getComputedStyle(b.firstChild.firstChild,null).marginRight!=='0px')}},{name:'DisplayChangeInputSelectionBug',fn:function(){var a=Ext.webKitVersion;return 0a';b=a.firstChild;a.innerHTML='
    b
    ';return b.innerHTML!=='a'}},{name:'IncludePaddingInWidthCalculation',ready:!0,fn:function(b,a){return a.childNodes[1].firstChild.offsetWidth===210}},{name:'IncludePaddingInHeightCalculation',ready:!0,fn:function(b,a){return a.childNodes[1].firstChild.offsetHeight===210}},{name:'TextAreaMaxLength',fn:function(a){return 'maxlength' in a.createElement('textarea')}},{name:'GetPositionPercentage',ready:!0,fn:function(b,a){return Ext.feature.getStyle(a.childNodes[2],'left')==='10%'}},{name:'PercentageHeightOverflowBug',ready:!0,fn:function(d){var c=!1,b,a;if(Ext.getScrollbarSize().height){a=this.getTestElement();b=a.style;b.height='50px';b.width='50px';b.overflow='auto';b.position='absolute';a.innerHTML=['
    ','
    ','
    '].join('');d.body.appendChild(a);if(a.firstChild.offsetHeight===50){c=!0}d.body.removeChild(a)}return c}},{name:'xOriginBug',ready:!0,fn:function(e,b){b.innerHTML='
    ';var a=document.getElementById('b1').getBoundingClientRect(),c=document.getElementById('b2').getBoundingClientRect(),d=document.getElementById('b3').getBoundingClientRect();return c.left!==a.left&&d.right!==a.right}},{name:'ScrollWidthInlinePaddingBug',ready:!0,fn:function(c){var d=!1,a,b;b=c.createElement('div');a=b.style;a.height='50px';a.width='50px';a.padding='10px';a.overflow='hidden';a.position='absolute';b.innerHTML='';c.body.appendChild(b);if(b.scrollWidth===70){d=!0}c.body.removeChild(b);return d}},{name:'rtlVertScrollbarOnRight',ready:!0,fn:function(d,c){c.innerHTML='
    ';var a=c.firstChild,b=a.firstChild;return b.offsetLeft+b.offsetWidth!==a.offsetLeft+a.offsetWidth}},{name:'rtlVertScrollbarOverflowBug',ready:!0,fn:function(c,b){b.innerHTML='
    ';var a=b.firstChild;return a.clientHeight===a.offsetHeight}},{identity:'defineProperty',fn:function(){if(Ext.isIE8m){Ext.Object.defineProperty=Ext.emptyFn;return !1}return !0}},{identify:'nativeXhr',fn:function(){if(typeof XMLHttpRequest!=='undefined'){return !0}XMLHttpRequest=function(){try{return new ActiveXObject('MSXML2.XMLHTTP.3.0')}catch(b){return null}};return !1}},{name:'SpecialKeyDownRepeat',fn:function(){return Ext.isWebKit?parseInt(navigator.userAgent.match(/AppleWebKit\/(\d+)/)[1],10)>=525:!(Ext.isGecko&&!Ext.isWindows||Ext.isOpera&&Ext.operaVersion<12)}},{name:'EmulatedMouseOver',fn:function(){return Ext.os.is.iOS}},{name:'Hashchange',fn:function(){var a=document.documentMode;return 'onhashchange' in window&&(a===undefined||a>7)}},{name:'FixedTableWidthBug',ready:!0,fn:function(){if(Ext.isIE8){return !1}var a=document.createElement('div'),b=document.createElement('div'),c;a.setAttribute('style','display:table;table-layout:fixed;');b.setAttribute('style','display:table-cell;min-width:50px;');a.appendChild(b);document.body.appendChild(a);a.offsetWidth;a.style.width='25px';c=a.offsetWidth;document.body.removeChild(a);return c===50}},{name:'FocusinFocusoutEvents',fn:function(){return !Ext.isGecko}},{name:'AsyncFocusEvents',fn:function(){return Ext.asyncFocus=!!Ext.isIE}},{name:'accessibility',ready:!0,fn:function(f){var g=f.body,b,c,a,e,d;function getColor(a){var c=[],e=0,g,b;if(a.indexOf('rgb(')!==-1){c=a.replace('rgb(','').replace(')','').split(', ')}else {if(a.indexOf('#')!==-1){g=a.length===7?/^#(\S\S)(\S\S)(\S\S)$/:/^#(\S)(\S)(\S)$/;b=a.match(g);if(b){c=['0x'+b[1],'0x'+b[2],'0x'+b[3]]}}}for(var d=0;d0};Ext.supports.HighContrastMode=!e.BackgroundImages;g.removeChild(b);b=c=null;return e}},0]};Ext.feature.tests.pop();Ext.supports={};Ext.feature.detect();Ext.env.Ready={blocks:(location.search||'').indexOf('ext-pauseReadyFire')>0?1:0,bound:0,delay:1,firing:!1,generation:0,listeners:[],nextId:0,sortGeneration:0,state:0,timer:null,bind:function(){var a=Ext.env.Ready,b=document;if(!a.bound){if(b.readyState==='complete'){a.onReadyEvent({type:b.readyState||'body'})}else {a.bound=1;if(Ext.browser.is.PhoneGap&&!Ext.os.is.Desktop){a.bound=2;b.addEventListener('deviceready',a.onReadyEvent,!1)}b.addEventListener('DOMContentLoaded',a.onReadyEvent,!1);window.addEventListener('load',a.onReadyEvent,!1)}}},block:function(){++this.blocks;Ext.isReady=!1},fireReady:function(){var a=Ext.env.Ready;if(!a.state){Ext._readyTime=Ext.ticks();Ext.isDomReady=!0;a.state=1;Ext.feature.detect(!0);if(!a.delay){a.handleReady()}else {if(navigator.standalone){a.timer=Ext.defer(function(){a.timer=null;a.handleReadySoon()},1)}else {a.handleReadySoon()}}}},handleReady:function(){var a=this;if(a.state===1){a.state=2;Ext._beforeReadyTime=Ext.ticks();a.invokeAll();Ext._afterReadyTime=Ext.ticks()}},handleReadySoon:function(b){var a=this;if(!a.timer){a.timer=Ext.defer(function(){a.timer=null;a.handleReady()},b||a.delay)}},invoke:function(a){var b=a.delay;if(b){Ext.defer(a.fn,b,a.scope)}else {if(Ext.elevateFunction){Ext.elevateFunction(a.fn,a.scope)}else {a.fn.call(a.scope)}}},invokeAll:function(){if(Ext.elevateFunction){Ext.elevateFunction(this.doInvokeAll,this)}else {this.doInvokeAll()}},doInvokeAll:function(){var a=this,b=a.listeners,c;if(!a.blocks){Ext.isReady=!0}a.firing=!0;while(b.length){if(a.sortGeneration!==a.generation){a.sortGeneration=a.generation;b.sort(a.sortFn)}c=b.pop();if(a.blocks&&!c.dom){b.push(c);break}a.invoke(c)}a.firing=!1},makeListener:function(d,c,b){var a={fn:d,id:++this.nextId,scope:c,dom:!1,priority:0};if(b){Ext.apply(a,b)}a.phase=a.dom?0:1;return a},on:function(e,d,c){var a=Ext.env.Ready,b=a.makeListener(e,d,c);if(a.state===2&&!a.firing&&(b.dom||!a.blocks)){a.invoke(b)}else {a.listeners.push(b);++a.generation;if(!a.bound){a.bind()}}},onReadyEvent:function(b){var a=Ext.env.Ready;if(Ext.elevateFunction){Ext.elevateFunction(a.doReadyEvent,a,arguments)}else {a.doReadyEvent(b)}},doReadyEvent:function(b){var a=this;if(a.bound>0){a.unbind();a.bound=-1}if(!a.state){a.fireReady()}},sortFn:function(a,b){return -(a.phase-b.phase||b.priority-a.priority||a.id-b.id)},unblock:function(){var a=this;if(a.blocks){if(!--a.blocks){if(a.state===2&&!a.firing){a.invokeAll()}}}},unbind:function(){var a=this,b=document;if(a.bound>1){b.removeEventListener('deviceready',a.onReadyEvent,!1)}b.removeEventListener('DOMContentLoaded',a.onReadyEvent,!1);window.removeEventListener('load',a.onReadyEvent,!1)}};(function(){var a=Ext.env.Ready;if(Ext.isIE9m){Ext.apply(a,{scrollTimer:null,readyStatesRe:/complete/i,pollScroll:function(){var b=!0;try{document.documentElement.doScroll('left')}catch(c){b=!1}if(b&&document.body){a.onReadyEvent({type:'doScroll'})}else {a.scrollTimer=Ext.defer(a.pollScroll,20)}return b},bind:function(){if(a.bound){return}var b=document,c;try{c=window.frameElement===undefined}catch(d){}if(!c||!b.documentElement.doScroll){a.pollScroll=Ext.emptyFn}else {if(a.pollScroll()){return}}if(b.readyState==='complete'){a.onReadyEvent({type:'already '+(b.readyState||'body')})}else {b.attachEvent('onreadystatechange',a.onReadyStateChange);window.attachEvent('onload',a.onReadyEvent);a.bound=1}},unbind:function(){document.detachEvent('onreadystatechange',a.onReadyStateChange);window.detachEvent('onload',a.onReadyEvent);if(Ext.isNumber(a.scrollTimer)){clearTimeout(a.scrollTimer);a.scrollTimer=null}},onReadyStateChange:function(){var b=document.readyState;if(a.readyStatesRe.test(b)){a.onReadyEvent({type:b})}}})}Ext.onDocumentReady=function(e,d,b){var c={dom:!0};if(b){Ext.apply(c,b)}a.on(e,d,c)};Ext.onReady=function(d,c,b){a.on(d,c,b)};Ext.onInternalReady=function(d,c,b){a.on(d,c,Ext.apply({priority:1000},b))};a.bind()})();Ext.Loader=new function(){var a=this,b=Ext.ClassManager,i=Ext.Boot,o=Ext.Class,c=Ext.env.Ready,k=Ext.Function.alias,h=['extend','mixins','requires'],j={},m=[],f=[],g=[],l={},d={},e={enabled:!0,scriptChainDelay:!1,disableCaching:!0,disableCachingParam:'_dc',paths:b.paths,preserveScripts:!0,scriptCharset:undefined},n={disableCaching:!0,disableCachingParam:!0,preserveScripts:!0,scriptChainDelay:'loadDelay'};Ext.apply(a,{isInHistory:j,isLoading:!1,history:m,config:e,readyListeners:f,optionalRequires:g,requiresMap:l,hasFileLoadError:!1,scriptsLoading:0,syncModeEnabled:!1,missingQueue:d,init:function(){var k=document.getElementsByTagName('script'),m=k[k.length-1].src,n=m.substring(0,m.lastIndexOf('/')+1),l=Ext._classPathMetadata,h=Ext.Microloader,g=Ext.manifest,d,i,j,e,f;if(!b.getPath('Ext')){b.setPath('Ext',n+'src')}if(l){Ext._classPathMetadata=null;a.addClassPathMappings(l)}if(g){d=g.loadOrder;i=Ext.Boot.baseUrl;if(d&&g.bootRelative){for(j=d.length,e=0;e1?'es':'')+': '+g.join(', '))}if(l.length){a.loadScripts({url:l,_classNames:g})}else {a.checkReady()}}else {if(c){c.call(k)}a.checkReady()}if(a.syncModeEnabled){if(m===1){return b.get(h[0])}}return a},makeLoadCallback:function(a,c){return function(){var e=[],d=a.length;while(d-->0){e[d]=b.get(a[d])}return c.apply(this,e)}},onLoadFailure:function(){var b=this,c=b.onError;a.hasFileLoadError=!0;--a.scriptsLoading;if(c){c.call(b.userScope,b)}a.checkReady()},onLoadSuccess:function(){var b=this,c=b.onLoad;--a.scriptsLoading;if(c){c.call(b.userScope,b)}a.checkReady()},onReady:function(g,e,h,d){if(h){c.on(g,e,d)}else {var b=c.makeListener(g,e,d);if(a.isLoading){f.push(b)}else {c.invoke(b)}}},addUsedClasses:function(b){var c,d,e;if(b){b=typeof b==='string'?[b]:b;for(d=0,e=b.length;d0){a.loadScripts({url:b,sequential:!0})}}}if(h.uses){b=h.uses;a.addUsedClasses(b)}});b.onCreated(a.historyPush);a.init()}();Ext._endTime=Ext.ticks();if(Ext._beforereadyhandler){Ext._beforereadyhandler()}Ext.cmd.derive('Ext.Mixin',Ext.Base,function(a){return {statics:{addHook:function(e,c,d,h){var g=Ext.isFunction(e),b=function(){var b=arguments,i=g?e:h[e],f=this.callParent(b);i.apply(this,b);return f},f=c.hasOwnProperty(d)&&c[d];if(g){e.$previous=Ext.emptyFn}b.$name=d;b.$owner=c.self;if(f){b.$previous=f.$previous;f.$previous=b}else {c[d]=b}}},onClassExtended:function(k,c){var b=c.mixinConfig,d=c.xhooks,j=k.superclass,i=c.onClassMixedIn,h,f,g,e;if(d){delete c.xhooks;(b||(c.mixinConfig=b={})).on=d}if(b){h=j.mixinConfig;if(h){c.mixinConfig=b=Ext.merge({},h,b)}c.mixinId=b.id;f=b.before;g=b.after;d=b.on;e=b.extended}if(f||g||d||e){c.onClassMixedIn=function(b){var h=this.prototype,l=b.prototype,j;if(f){Ext.Object.each(f,function(e,d){b.addMember(e,function(){if(h[d].apply(this,arguments)!==!1){return this.callParent(arguments)}})})}if(g){Ext.Object.each(g,function(e,d){b.addMember(e,function(){var f=this.callParent(arguments);h[d].apply(this,arguments);return f})})}if(d){for(j in d){a.addHook(d[j],l,j,h)}}if(e){b.onExtended(function(){var d=Ext.Array.slice(arguments,0);d.unshift(b);return e.apply(this,d)},this)}if(i){i.apply(this,arguments)}}}}}},0,0,0,0,0,0,[Ext,'Mixin'],0);Ext.util=Ext.util||{};Ext.util.DelayedTask=function(e,c,d,b,g){var a=this,f,h=function(){var f=Ext.GlobalEvents;clearInterval(a.id);a.id=null;e.apply(c,d||[]);if(g!==!1&&f.hasListeners.idle){f.fireEvent('idle')}};b=typeof b==='boolean'?b:!0;a.id=null;a.delay=function(i,l,j,k){if(b){a.cancel()}if(typeof i==='number'){f=i}e=l||e;c=j||c;d=k||d;if(!a.id){a.id=Ext.interval(h,f)}};a.cancel=function(){if(a.id){clearInterval(a.id);a.id=null}}};Ext.cmd.derive('Ext.util.Event',Ext.Base,function(){var d=Array.prototype.slice,c=Ext.Array.insert,b=Ext.Array.toArray,a={};return {isEvent:!0,suspended:0,noOptions:{},constructor:function(a,b){this.name=b;this.observable=a;this.listeners=[]},addListener:function(r,q,g,t,s){var a=this,p=!1,l=a.observable,o=a.name,d,m,i,h,f,k,j,b,e,n;if(a.findListener(r,q)===-1){m=a.createListener(r,q,g,t,s);if(a.firing){a.listeners=a.listeners.slice(0)}d=a.listeners;b=j=d.length;i=g&&g.priority;f=a._highestNegativePriorityIndex;k=f!==undefined;if(i){h=i<0;if(!h||k){for(e=h?f:0;e0},fireDelegated:function(a,b){this.firingObservable=a;return this.fire.apply(this,b)},fire:function(){var e=this,r=e.listeners,t=r.length,n=e.observable,i=n.isElement,w=n.isComponent,v=e.firingObservable,b,o,f,k,c,j,u,h,l,p,g,m,a,s,q;if(!e.suspended&&t>0){e.firing=!0;c=arguments.length?d.call(arguments,0):[];u=c.length;if(i){a=c[0]}for(k=0;k4?b:e;b=e;for(e in b){if(b.hasOwnProperty(e)){g=b[e];if(!h.$eventOptions[e]){f.addManagedListener(h,e,g.fn||g,g.scope||b.scope||i,g.fn?g:k,!0)}}}if(b&&b.destroyable){return new a(f,h,b)}}else {if(j!==d){h.doAddListener(e,j,i,b,null,f,f);if(!l&&b&&b.destroyable){return new a(f,h,e,j,i)}}}},removeManagedListener:function(h,a,k,j){var e=this,b,d,g,i,f;if(typeof a!=='string'){b=a;for(a in b){if(b.hasOwnProperty(a)){d=b[a];if(!h.$eventOptions[a]){e.removeManagedListener(h,a,d.fn||d,d.scope||b.scope||j)}}}}else {g=e.managedListeners?e.managedListeners.slice():[];a=Ext.canonicalEventName(a);for(f=0,i=g.length;f0,d=this.events;if(!b&&a&&d){a=d[a];if(a&&a.isEvent){return a.isSuspended()}}return b},suspendEvents:function(a){++this.eventsSuspended;if(a&&!this.eventQueue){this.eventQueue=[]}},suspendEvent:function(){var e=this,f=e.events,g=arguments.length,d,b,a;for(d=0;d0){i.push(g)}d--;if(d===0){f.resolve(i)}return g};m=function(d){h--;if(h===0){f.reject(new Error('Too few Promises were resolved.'))}return d};for(g=j=0,n=e.length;j0){b.type=a.substring(0,e);b.defaultType=a.substring(e+1)}if(f){delete d.factoryConfig;Ext.apply(b,f)}g=Ext.Factory.define(b.type,b);if(c.create===Ext.Base.create){c.create=g}}},0,0,0,0,0,0,[Ext.mixin,'Factoryable'],0);Ext.cmd.derive('Ext.data.request.Base',Ext.Base,{factoryConfig:{type:'request',defaultType:'ajax'},result:null,success:null,timer:null,constructor:function(a){var b=this;Ext.apply(b,a.options||{},a.ownerConfig);b.id=++Ext.data.Connection.requestId;b.owner=a.owner;b.options=a.options;b.requestOptions=a.requestOptions},start:function(){var a=this,b=a.getTimeout();if(b&&a.async){a.timer=Ext.defer(a.onTimeout,b,a)}},abort:function(){var a=this;a.clearTimer();if(!a.timedout){a.aborted=!0}a.abort=Ext.emptyFn},createDeferred:function(){return this.deferred=new Ext.Deferred()},getDeferred:function(){return this.deferred||this.createDeferred()},getPromise:function(){return this.getDeferred().promise},then:function(){var a=this.getPromise();return a.then.apply(a,arguments)},onComplete:function(){var a=this,b=a.deferred,c=a.result;a.clearTimer();if(b){if(a.success){b.resolve(c)}else {b.reject(c)}}},onTimeout:function(){var a=this;a.timedout=!0;a.timer=null;a.abort(!0)},getTimeout:function(){return this.timeout},clearTimer:function(){var a=this.timer;if(a){clearTimeout(a);this.timer=null}},destroy:function(){var a=this;a.abort();a.owner=a.options=a.requestOptions=a.result=null;a.callParent()},privates:{createException:function(){var a=this,b;b={request:a,requestId:a.id,status:a.aborted?-1:0,statusText:a.aborted?'transaction aborted':'communication failure',getResponseHeader:a._getHeader,getAllResponseHeaders:a._getHeaders};if(a.aborted){b.aborted=!0}if(a.timedout){b.timedout=!0}return b},_getHeader:function(b){var a=this.headers;return a&&a[b.toLowerCase()]},_getHeaders:function(){return this.headers}}},1,0,0,0,0,[[Ext.mixin.Factoryable.prototype.mixinId||Ext.mixin.Factoryable.$className,Ext.mixin.Factoryable]],[Ext.data.request,'Base'],0);Ext.cmd.derive('Ext.data.flash.BinaryXhr',Ext.Base,{statics:{flashPluginActivated:function(){Ext.data.flash.BinaryXhr.flashPluginActive=!0;Ext.data.flash.BinaryXhr.flashPlugin=document.getElementById('ext-flash-polyfill');Ext.GlobalEvents.fireEvent('flashready')},flashPluginActive:!1,flashPluginInjected:!1,connectionIndex:1,liveConnections:{},flashPlugin:null,onFlashStateChange:function(b,c,d){var a;a=this.liveConnections[Number(b)];if(a){a.onFlashStateChange(c,d)}},registerConnection:function(b){var a=this.connectionIndex;this.conectionIndex=this.connectionIndex+1;this.liveConnections[a]=b;return a},injectFlashPlugin:function(){var c=this,b,a;c.flashPolyfillEl=Ext.getBody().appendChild({id:'ext-flash-polyfill',cn:[{tag:'p',html:'To view this page ensure that Adobe Flash Player version 11.1.0 or greater is installed.'},{tag:'a',href:'http://www.adobe.com/go/getflashplayer',cn:[{tag:'img',src:window.location.protocol+'//www.adobe.com/images/shared/download_buttons/get_flash_player.gif',alt:'Get Adobe Flash player'}]}]});b=[Ext.Loader.getPath('Ext.data.Connection'),'../../../plugins/flash/swfobject.js'].join('/');a='/plugins/flash/FlashPlugin.swf';if(Ext.flashPluginPath){a=Ext.flashPluginPath}Ext.Loader.loadScript({url:b,onLoad:function(){var d='11.4.0';var e='playerProductInstall.swf';var f={};var b={};b.quality='high';b.bgcolor='#ffffff';b.allowscriptaccess='sameDomain';b.allowfullscreen='true';var c={};c.id='ext-flash-polyfill';c.name='polyfill';c.align='middle';swfobject.embedSWF(a,'ext-flash-polyfill','0','0',d,e,f,b,c)},onError:function(){},scope:c});Ext.data.flash.BinaryXhr.flashPluginInjected=!0}},readyState:0,status:0,statusText:'',responseBytes:null,javascriptId:null,constructor:function(b){if(!Ext.data.flash.BinaryXhr.flashPluginInjected){Ext.data.flash.BinaryXhr.injectFlashPlugin()}var a=this;Ext.apply(a,b);a.requestHeaders={}},abort:function(){var a=this;if(a.readyState==4){return}a.aborted=!0;if(!Ext.data.flash.BinaryXhr.flashPluginActive){Ext.GlobalEvents.removeListener('flashready',a.onFlashReady,a);return}Ext.data.flash.BinaryXhr.flashPlugin.abortRequest(a.javascriptId);delete Ext.data.flash.BinaryXhr.liveConnections[a.javascriptId]},getAllResponseHeaders:function(){var a=[];Ext.Object.each(this.responseHeaders,function(c,b){a.push(c+': '+b)});return a.join('\r\n')},getResponseHeader:function(b){var a=this.responseHeaders;return a&&a[b]||null},open:function(c,f,d,e,b){var a=this;a.method=c;a.url=f;a.async=d!==!1;a.user=e;a.password=b},overrideMimeType:function(a){this.mimeType=a},send:function(b){var a=this;a.body=b;if(!Ext.data.flash.BinaryXhr.flashPluginActive){Ext.GlobalEvents.addListener('flashready',a.onFlashReady,a)}else {this.onFlashReady()}},onFlashReady:function(){var a=this,b,c;a.javascriptId=Ext.data.flash.BinaryXhr.registerConnection(a);b={method:a.method,url:a.url,user:a.user,password:a.password,mimeType:a.mimeType,requestHeaders:a.requestHeaders,body:a.body,javascriptId:a.javascriptId};c=Ext.data.flash.BinaryXhr.flashPlugin.postBinary(b)},setReadyState:function(b){var a=this;if(a.readyState!=b){a.readyState=b;a.onreadystatechange()}},setRequestHeader:function(a,b){this.requestHeaders[a]=b},onreadystatechange:Ext.emptyFn,parseData:function(a){var b=this;this.status=a.status||0;b.responseHeaders={};if(b.mimeType){b.responseHeaders['content-type']=b.mimeType}if(a.reason=='complete'){this.responseBytes=a.data;b.responseHeaders['content-length']=a.data.length}else {if(a.reason=='error'||a.reason=='securityError'){this.statusText=a.text;b.responseHeaders['content-length']=0}}},onFlashStateChange:function(b,c){var a=this;if(b==4){a.parseData(c);delete Ext.data.flash.BinaryXhr.liveConnections[a.javascriptId]}a.setReadyState(b)}},1,0,0,0,0,0,[Ext.data.flash,'BinaryXhr'],0);Ext.cmd.derive('Ext.data.request.Ajax',Ext.data.request.Base,{statics:{parseStatus:function(a){a=a==1223?204:a;var c=a>=200&&a<300||a==304,b=!1;if(!c){switch(a){case 12002:case 12029:case 12030:case 12031:case 12152:case 13030:b=!0;break;}}return {success:c,isException:b}}},start:function(f){var a=this,e=a.options,c=a.requestOptions,d=a.isXdr,b,g;b=a.xhr=a.openRequest(e,c,a.async,a.username,a.password);if(!d){g=a.setupHeaders(b,e,c.data,c.params)}if(a.async){if(!d){b.onreadystatechange=Ext.Function.bind(a.onStateChange,a)}}if(d){a.processXdrRequest(a,b)}Ext.data.request.Base.prototype.start.call(this,f);b.send(f);if(!a.async){return a.onComplete()}return a},abort:function(c){var a=this,b=a.xhr;if(c||a.isLoading()){try{b.onreadystatechange=null}catch(d){b.onreadystatechange=Ext.emptyFn}b.abort();Ext.data.request.Base.prototype.abort.call(this,c);a.onComplete();a.cleanup()}},cleanup:function(){this.xhr=null;delete this.xhr},isLoading:function(){var c=this,a=c.xhr,b=a&&a.readyState,d=Ext.data.flash&&Ext.data.flash.BinaryXhr;if(!a||c.aborted||c.timedout){return !1}if(d&&a instanceof d){return b!==4}return b!==0&&b!==4},openRequest:function(d,b,f,e,g){var c=this,a=c.newRequest(d);if(e){a.open(b.method,b.url,f,e,g)}else {if(c.isXdr){a.open(b.method,b.url)}else {a.open(b.method,b.url,f)}}if(d.binary||c.binary){if(window.Uint8Array){a.responseType='arraybuffer'}else {if(a.overrideMimeType){a.overrideMimeType('text/plain; charset=x-user-defined')}}}if(d.withCredentials||c.withCredentials){a.withCredentials=!0}return a},newRequest:function(c){var a=this,b;if(c.binaryData){if(window.Uint8Array){b=a.getXhrInstance()}else {b=new Ext.data.flash.BinaryXhr()}}else {if(a.cors&&Ext.isIE9m){b=a.getXdrInstance();a.isXdr=!0}else {b=a.getXhrInstance();a.isXdr=!1}}return b},setupHeaders:function(m,f,j,l){var d=this,a=Ext.apply({},f.headers||{},d.defaultHeaders),e=d.defaultPostHeader,h=f.jsonData,i=f.xmlData,b='Content-Type',k=d.useDefaultXhrHeader,c,g;if(!a.hasOwnProperty(b)&&(j||l)){if(j){if(f.rawData){e='text/plain'}else {if(i&&Ext.isDefined(i)){e='text/xml'}else {if(h&&Ext.isDefined(h)){e='application/json'}}}}a[b]=e}if(k&&!a['X-Requested-With']){a['X-Requested-With']=d.defaultXhrHeader}if(a[b]===undefined||a[b]===null){delete a[b]}try{for(c in a){if(a.hasOwnProperty(c)){g=a[c];m.setRequestHeader(c,g)}}}catch(n){d.owner.fireEvent('exception',c,g)}return a},getXdrInstance:function(){var a;if(Ext.ieVersion>=8){a=new XDomainRequest()}else {Ext.raise({msg:'Your browser does not support CORS'})}return a},getXhrInstance:function(){var c=[function(){return new XMLHttpRequest()},function(){return new ActiveXObject('MSXML2.XMLHTTP.3.0')},function(){return new ActiveXObject('MSXML2.XMLHTTP')},function(){return new ActiveXObject('Microsoft.XMLHTTP')}],b=0,d=c.length,a;for(;b=0){j=e.substr(0,c).toLowerCase();if(e.charAt(c+1)==' '){++c}f[j]=e.substr(c+1)}}b={request:d,requestId:d.id,status:a.status,statusText:a.statusText,getResponseHeader:function(b){return f[b.toLowerCase()]},getAllResponseHeaders:function(){return f}};if(h){d.processXdrResponse(b,a)}if(d.binary){b.responseBytes=d.getByteArray(a)}else {b.responseText=a.responseText;b.responseXML=a.responseXML}return b},destroy:function(){this.xhr=null;Ext.data.request.Base.prototype.destroy.call(this)},privates:{getByteArray:function(b){var e=b.response,g=b.responseBody,h=Ext.data.flash&&Ext.data.flash.BinaryXhr,a,d,f,c;if(b instanceof h){a=b.responseBytes}else {if(window.Uint8Array){a=e?new Uint8Array(e):[]}else {if(Ext.isIE9p){try{a=(new VBArray(g)).toArray()}catch(i){a=[]}}else {if(Ext.isIE){if(!this.self.vbScriptInjected){this.injectVBScript()}getIEByteArray(b.responseBody,a=[])}else {a=[];d=b.responseText;f=d.length;for(c=0;c=500){this.run()}},run:function(){var a=this;if(!a.isRunning){return}var b=a.runningQueue,d=Ext.now(),c,e;a.lastRunTime=d;a.frameStartTime=d;b.push.apply(b,a.queue);for(c=0,e=b.length;c0){b=a.shift();this.invoke(b);this.processIdleQueue()}},processTaskQueue:function(){if(!this.hasOwnProperty('taskQueueTimer')){this.taskQueueTimer=Ext.defer(this.processTaskQueueItem,15,this)}},processTaskQueueItem:function(){delete this.taskQueueTimer;var a=this.taskQueue,b;if(a.length>0){b=a.shift();this.invoke(b);this.processTaskQueue()}}},1,0,0,0,0,0,[Ext,'AnimationQueue'],0);Ext.cmd.derive('Ext.ComponentManager',Ext.Base,{alternateClassName:'Ext.ComponentMgr',singleton:!0,count:0,typeName:'xtype',constructor:function(b){var a=this;Ext.apply(a,b||{});a.all={};a.references={};a.onAvailableCallbacks={}},create:function(a,b){if(typeof a==='string'){return Ext.widget(a)}if(a.isComponent){return a}if('xclass' in a){return Ext.create(a.xclass,a)}return Ext.widget(a.xtype||b,a)},get:function(a){return this.all[a]},register:function(b){var a=this,e=a.all,d=b.getId(),c=a.onAvailableCallbacks;e[d]=b;if(b.getReference&&b.getReference()){a.references[d]=b}++a.count;if(!a.hasFocusListener){Ext.on('focus',a.onGlobalFocus,a);a.hasFocusListener=!0}c=c&&c[d];if(c&&c.length){a.notifyAvailable(b)}},unregister:function(b){var a=b.getId();if(b.getReference&&b.getReference()){this.references[a]=null;delete this.references[a]}this.all[a]=null;delete this.all[a];this.count--},markReferencesDirty:function(){this.referencesDirty=!0},fixReferences:function(){var c=this,a=c.references,b;if(c.referencesDirty){for(b in a){if(a.hasOwnProperty(b)){a[b].fixReference()}}c.referencesDirty=!1}},onAvailable:function(a,f,d){var g=this,b=g.onAvailableCallbacks,e=g.all,c;if(a in e){c=e[a];f.call(d||c,c)}else {if(a){if(!Ext.isArray(b[a])){b[a]=[]}b[a].push(function(b){f.call(d||b,b)})}}},notifyAvailable:function(a){var b=this.onAvailableCallbacks[a&&a.getId()]||[];while(b.length){b.shift()(a)}},each:function(b,a){return Ext.Object.each(this.all,b,a)},getCount:function(){return this.count},getAll:function(){return Ext.Object.getValues(this.all)},getActiveComponent:function(){return Ext.Component.fromElement(Ext.dom.Element.getActiveElement())},onGlobalFocus:function(d){var h=this,g=d.toElement,f=d.fromElement,c=Ext.Component.fromElement(g),b=Ext.Component.fromElement(f),e,a;if(c===b){return}e=h.getCommonAncestor(b,c);if(b&&!(b.destroyed||b.destroying)){if(b.handleBlurEvent){b.handleBlurEvent(d)}for(a=b;a&&a!==e;a=a.getRefOwner()){if(!(a.destroyed||a.destroying)){a.onFocusLeave({event:d.event,type:'focusleave',target:f,relatedTarget:g,fromComponent:b,toComponent:c})}}}if(c&&!c.destroyed){if(c.handleFocusEvent){c.handleFocusEvent(d)}for(a=c;a&&a!==e;a=a.getRefOwner()){a.onFocusEnter({event:d.event,type:'focusenter',relatedTarget:f,target:g,fromComponent:b,toComponent:c})}}},getCommonAncestor:function(a,b){if(a===b){return a}while(a&&!(a.isAncestor(b)||a===b)){a=a.getRefOwner()}return a},privates:{clearAll:function(){this.all={};this.references={};this.onAvailableCallbacks={}},fromElement:function(i,b,e){var a=Ext.getDom(i),h=this.all,g=0,f,d,c;if(typeof b!=='number'){f=Ext.getDom(b);b=Number.MAX_VALUE}while(a&&a.nodeType===1&&g0){for(;a.first&&b;b--){a.removeAtKey(a.first.key)}}},destroy:function(){this.first=this.last=null;Ext.util.HashMap.prototype.destroy.call(this)}},0,0,0,0,0,0,[Ext.util,'LruCache'],0);Ext.cmd.derive('Ext.ComponentQuery',Ext.Base,{singleton:!0},0,0,0,0,0,0,[Ext,'ComponentQuery'],function(){var a=this,f=Ext.util.Operators,r=/(\d*)n\+?(\d*)/,q=/\D/,c=/^(\s)+/,b=/\\(.)/g,j=new Ext.util.LruCache({maxSize:100}),m=['var r = [],','i = 0,','it = items,','l = it.length,','c;','for (; i < l; i++) {','c = it[i];','if (c.{0}) {','r.push(c);','}','}','return r;'].join(''),d=function(b,a){return a.method.apply(this,[b].concat(a.args))},e=function(d,g){var b=[],c=0,e=d.length,a,f=g!=='>';for(;c\^])\s?|\s|$)/,o=/^(#)?((?:\\\.|[\w\-])+|\*)(?:\((true|false)\))?/,k=[{re:/^\.((?:\\\.|[\w\-])+)(?:\((true|false)\))?/,method:g,argTransform:function(a){if(a[1]!==undefined){a[1]=a[1].replace(b,'$1')}return a.slice(1)}},{re:/^(?:\[((?:[@?$])?[\w\-]*)\s*(?:([\^$*~%!\/]?=)\s*(['"])?((?:\\\]|.)*?)\3)?(?!\\)\])/,method:l,argTransform:function(c){var g=c[0],f=c[1],e=c[2],a=c[4],d;if(a!==undefined){a=a.replace(b,'$1')}if(e==='/='){d=j.get(a);if(d){a=d}else {a=j.add(a,new RegExp(a))}}return [f,e,a]}},{re:/^#((?:\\\.|[\w\-])+)/,method:i},{re:/^\:([\w\-]+)(?:\(((?:\{[^\}]+\})|(?:(?!\{)[^\s>\/]*?(?!\})))\))?/,method:n,argTransform:function(a){if(a[2]!==undefined){a[2]=a[2].replace(b,'$1')}return a.slice(1)}},{re:/^(?:\{([^\}]+)\})/,method:m}];a.Query=Ext.extend(Object,{constructor:function(a){a=a||{};Ext.apply(this,a)},execute:function(f){var c=this.operations,b=[],e,a,d;for(a=0,d=c.length;a=0;--c){g=l[c];b=g.mode;if(b){if(b==='^'){a=e(a,' ')}else {if(b==='>'){i=[];for(f=0,k=a.length;f1}});Ext.apply(a,{cache:new Ext.util.LruCache({maxSize:100}),pseudos:{not:function(d,f){var c=0,g=d.length,e=[],h=-1,b;for(;c0){b.push(a[0])}return b},last:function(a){var b=a.length,c=[];if(b>0){c.push(a[b-1])}return c},focusable:function(d){var e=d.length,c=[],b=0,a;for(;b=c.left&&(t=='t'&&v=='b'||t=='b'&&v=='t');o=f=c.top&&(s=='r'&&u=='l'||s=='l'&&u=='r');if(e+k>a.right){if(o){e=c.left-k;o=!1}else {e=a.right-k}}if(ea.bottom){if(p){f=c.top-j;p=!1}else {f=a.bottom-j}}if(fa.right){e=!0;d[0]=a.right-b.right}if(b.left+d[0]a.bottom){e=!0;d[1]=a.bottom-b.bottom}if(b.top+d[1]=b.x&&a.right<=b.right&&a.y>=b.y&&a.bottom<=b.bottom},intersect:function(a){var b=this,f=Math.max(b.y,a.y),e=Math.min(b.right,a.right),c=Math.min(b.bottom,a.bottom),d=Math.max(b.x,a.x);if(c>f&&e>d){return new this.self(f,e,c,d)}else {return !1}},union:function(a){var b=this,f=Math.min(b.y,a.y),e=Math.max(b.right,a.right),c=Math.max(b.bottom,a.bottom),d=Math.min(b.x,a.x);return new this.self(f,e,c,d)},constrainTo:function(b){var a=this,c=Ext.Number.constrain;a.top=a.y=c(a.top,b.y,b.bottom);a.bottom=c(a.bottom,b.y,b.bottom);a.left=a.x=c(a.left,b.x,b.right);a.right=c(a.right,b.x,b.right);return a},adjust:function(e,c,b,d){var a=this;a.top=a.y+=e;a.left=a.x+=d;a.right+=c;a.bottom+=b;return a},getOutOfBoundOffset:function(b,a){if(!Ext.isObject(b)){if(b=='x'){return this.getOutOfBoundOffsetX(a)}else {return this.getOutOfBoundOffsetY(a)}}else {a=b;var c=new Ext.util.Offset();c.x=this.getOutOfBoundOffsetX(a.x);c.y=this.getOutOfBoundOffsetY(a.y);return c}},getOutOfBoundOffsetX:function(a){if(a<=this.x){return this.x-a}else {if(a>=this.right){return this.right-a}}return 0},getOutOfBoundOffsetY:function(a){if(a<=this.y){return this.y-a}else {if(a>=this.bottom){return this.bottom-a}}return 0},isOutOfBound:function(b,a){if(!Ext.isObject(b)){if(b=='x'){return this.isOutOfBoundX(a)}else {return this.isOutOfBoundY(a)}}else {a=b;return this.isOutOfBoundX(a.x)||this.isOutOfBoundY(a.y)}},isOutOfBoundX:function(a){return athis.right},isOutOfBoundY:function(a){return athis.bottom},restrict:function(d,a,b){if(Ext.isObject(d)){var c;b=a;a=d;if(a.copy){c=a.copy()}else {c={x:a.x,y:a.y}}c.x=this.restrictX(a.x,b);c.y=this.restrictY(a.y,b);return c}else {if(d=='x'){return this.restrictX(a,b)}else {return this.restrictY(a,b)}}},restrictX:function(a,b){if(!b){b=1}if(a<=this.x){a-=(a-this.x)*b}else {if(a>=this.right){a-=(a-this.right)*b}}return a},restrictY:function(a,b){if(!b){b=1}if(a<=this.y){a-=(a-this.y)*b}else {if(a>=this.bottom){a-=(a-this.bottom)*b}}return a},getSize:function(){return {width:this.right-this.x,height:this.bottom-this.y}},copy:function(){return new this.self(this.y,this.right,this.bottom,this.x)},copyFrom:function(b){var a=this;a.top=a.y=a[1]=b.y;a.right=b.right;a.bottom=b.bottom;a.left=a.x=a[0]=b.x;return this},toString:function(){return 'Region['+this.top+','+this.right+','+this.bottom+','+this.left+']'},translateBy:function(b,c){if(arguments.length==1){c=b.y;b=b.x}var a=this;a.top=a.y+=c;a.right+=b;a.bottom+=c;a.left=a.x+=b;return a},round:function(){var a=this;a.top=a.y=Math.round(a.y);a.right=Math.round(a.right);a.bottom=Math.round(a.bottom);a.left=a.x=Math.round(a.x);return a},equals:function(a){return this.top===a.top&&this.right===a.right&&this.bottom===a.bottom&&this.left===a.left}},3,0,0,0,0,0,[Ext.util,'Region'],0);Ext.cmd.derive('Ext.util.Point',Ext.util.Region,{radianToDegreeConstant:180/Math.PI,origin:{x:0,y:0},statics:{fromEvent:function(b){var a=b.changedTouches,c=a&&a.length>0?a[0]:b;return this.fromTouch(c)},fromTouch:function(a){return new this(a.pageX,a.pageY)},from:function(a){if(!a){return new this(0,0)}if(!(a instanceof this)){return new this(a.x,a.y)}return a}},constructor:function(a,b){if(a==null){a=0}if(b==null){b=0}Ext.util.Region.prototype.constructor.call(this,b,a,b,a)},clone:function(){return new this.self(this.x,this.y)},copy:function(){return this.clone.apply(this,arguments)},copyFrom:function(a){this.x=a.x;this.y=a.y;return this},toString:function(){return 'Point['+this.x+','+this.y+']'},equals:function(a){return this.x===a.x&&this.y===a.y},isCloseTo:function(b,a){if(typeof a=='number'){return this.getDistanceTo(b)<=a}var e=b.x,f=b.y,c=a.x,d=a.y;return this.x<=e+c&&this.x>=e-c&&this.y<=f+d&&this.y>=f-d},isWithin:function(){return this.isCloseTo.apply(this,arguments)},isContainedBy:function(a){if(!(a instanceof Ext.util.Region)){a=Ext.get(a.el||a).getRegion()}return a.contains(this)},roundedEquals:function(a){if(!a||typeof a!=='object'){a=this.origin}return Math.round(this.x)===Math.round(a.x)&&Math.round(this.y)===Math.round(a.y)},getDistanceTo:function(a){if(!a||typeof a!=='object'){a=this.origin}var b=this.x-a.x,c=this.y-a.y;return Math.sqrt(b*b+c*c)},getAngleTo:function(a){if(!a||typeof a!=='object'){a=this.origin}var b=this.x-a.x,c=this.y-a.y;return Math.atan2(c,b)*this.radianToDegreeConstant}},3,0,0,0,0,0,[Ext.util,'Point'],function(){this.prototype.translate=this.prototype.translateBy});Ext.cmd.derive('Ext.event.Event',Ext.Base,{alternateClassName:'Ext.EventObjectImpl',isStopped:!1,defaultPrevented:!1,isEvent:!0,statics:{resolveTextNode:function(a){return a&&a.nodeType===3?a.parentNode:a},pointerEvents:{pointerdown:1,pointermove:1,pointerup:1,pointercancel:1,pointerover:1,pointerout:1,pointerenter:1,pointerleave:1,MSPointerDown:1,MSPointerMove:1,MSPointerUp:1,MSPointerOver:1,MSPointerOut:1,MSPointerCancel:1,MSPointerEnter:1,MSPointerLeave:1},mouseEvents:{mousedown:1,mousemove:1,mouseup:1,mouseover:1,mouseout:1,mouseenter:1,mouseleave:1},clickEvents:{click:1,dblclick:1},touchEvents:{touchstart:1,touchmove:1,touchend:1,touchcancel:1},focusEvents:{focus:1,blur:1,focusin:1,focusout:1,focusenter:1,focusleave:1},pointerTypes:{2:'touch',3:'pen',4:'mouse',touch:'touch',pen:'pen',mouse:'mouse'}},constructor:function(b){var a=this,c=a.self,h=a.self.resolveTextNode,i=b.changedTouches,g=i?i[0]:b,d=b.type,e,f;a.pageX=g.pageX;a.pageY=g.pageY;a.target=a.delegatedTarget=h(b.target);f=b.relatedTarget;if(f){a.relatedTarget=h(f)}a.browserEvent=a.event=b;a.type=d;a.button=b.button||0;a.shiftKey=b.shiftKey;a.ctrlKey=b.ctrlKey||b.metaKey||!1;a.altKey=b.altKey;a.charCode=b.charCode;a.keyCode=b.keyCode;a.buttons=b.buttons;if(a.button===0&&a.buttons===0){a.buttons=1}if(c.forwardTab!==undefined&&c.focusEvents[d]){a.forwardTab=c.forwardTab}if(c.mouseEvents[d]||c.clickEvents[d]){e='mouse'}else {if(c.pointerEvents[d]){e=c.pointerTypes[b.pointerType]}else {if(c.touchEvents[d]){e='touch'}}}if(e){a.pointerType=e}a.timeStamp=a.time=+(b.timeStamp||new Date())},chain:function(b){var a=Ext.Object.chain(this);a.parentEvent=this;return Ext.apply(a,b)},correctWheelDelta:function(a){var c=this.WHEEL_SCALE,b=Math.round(a/c);if(!b&&a){b=a<0?-1:1}return b},getCharCode:function(){return this.charCode||this.keyCode},getKey:function(){return this.keyCode||this.charCode},getKeyName:function(){return this.keyCodes[this.keyCode]},getPoint:function(){var a=this.getXY();return new Ext.util.Point(a[0],a[1])},getRelatedTarget:function(d,e,c){var a=this.relatedTarget,b=null;if(a){if(d){b=Ext.fly(a).findParent(d,e,c)}else {b=c?Ext.get(a):a}}return b},getTarget:function(b,c,a){return b?Ext.fly(this.target).findParent(b,c,a):a?Ext.get(this.target):this.target},getTime:function(){return this.time},getWheelDelta:function(){var a=this.getWheelDeltas();return a.y},getWheelDeltas:function(){var d=this,a=d.browserEvent,c=0,b=0;if(Ext.isDefined(a.wheelDeltaX)){c=a.wheelDeltaX;b=a.wheelDeltaY}else {if(a.wheelDelta){b=a.wheelDelta}else {if(a.detail){b=-a.detail;if(b>100){b=3}else {if(b<-100){b=-3}}if(Ext.isDefined(a.axis)&&a.axis===a.HORIZONTAL_AXIS){c=b;b=0}}}}return {x:d.correctWheelDelta(c),y:d.correctWheelDelta(b)}},getX:function(){return this.getXY()[0]},getXY:function(){var d=this,c=d.xy;if(!c){c=d.xy=[d.pageX,d.pageY];var g=c[0],e,f,a,b;if(!g&&g!==0){e=d.browserEvent;f=document;a=f.documentElement;b=f.body;c[0]=e.clientX+(a&&a.scrollLeft||b&&b.scrollLeft||0)-(a&&a.clientLeft||b&&b.clientLeft||0);c[1]=e.clientY+(a&&a.scrollTop||b&&b.scrollTop||0)-(a&&a.clientTop||b&&b.clientTop||0)}}return c},getY:function(){return this.getXY()[1]},hasModifier:function(){var a=this;return !!(a.ctrlKey||a.altKey||a.shiftKey||a.metaKey)},isNavKeyPress:function(c){var a=this,b=a.keyCode,d=a.type==='keypress';return (!d||Ext.isGecko)&&b>=33&&b<=40||!c&&(b===a.RETURN||b===a.TAB||b===a.ESC)},isSpecialKey:function(){var b=this,a=b.keyCode,d=Ext.isGecko,c=b.type==='keypress';return d&&c&&b.charCode===0||this.isNavKeyPress()||a===b.BACKSPACE||a===b.ENTER||a>=16&&a<=20||(!c||d)&&a>=44&&a<=46},makeUnpreventable:function(){this.browserEvent.preventDefault=Ext.emptyFn},preventDefault:function(){var a=this,b=a.parentEvent;a.defaultPrevented=!0;if(b){b.defaultPrevented=!0}a.browserEvent.preventDefault();return a},setCurrentTarget:function(a){this.currentTarget=this.delegatedTarget=a},stopEvent:function(){return this.preventDefault().stopPropagation()},stopPropagation:function(){var a=this,b=a.browserEvent,c=a.parentEvent;a.isStopped=!0;if(c){c.isStopped=!0}if(!b.stopPropagation){b.cancelBubble=!0;return a}b.stopPropagation();return a},within:function(b,d,c){var a;if(b){a=d?this.getRelatedTarget():this.getTarget()}return a?Ext.fly(b).contains(a)||!!(c&&a===Ext.getDom(b)):!1},deprecated:{'4.0':{methods:{getPageX:'getX',getPageY:'getY'}}}},1,0,0,0,0,0,[Ext.event,'Event',Ext,'EventObjectImpl'],function(f){var b=f.prototype,a={BACKSPACE:8,TAB:9,NUM_CENTER:12,ENTER:13,RETURN:13,SHIFT:16,CTRL:17,ALT:18,PAUSE:19,CAPS_LOCK:20,ESC:27,SPACE:32,PAGE_UP:33,PAGE_DOWN:34,END:35,HOME:36,LEFT:37,UP:38,RIGHT:39,DOWN:40,PRINT_SCREEN:44,INSERT:45,DELETE:46,ZERO:48,ONE:49,TWO:50,THREE:51,FOUR:52,FIVE:53,SIX:54,SEVEN:55,EIGHT:56,NINE:57,A:65,B:66,C:67,D:68,E:69,F:70,G:71,H:72,I:73,J:74,K:75,L:76,M:77,N:78,O:79,P:80,Q:81,R:82,S:83,T:84,U:85,V:86,W:87,X:88,Y:89,Z:90,CONTEXT_MENU:93,NUM_ZERO:96,NUM_ONE:97,NUM_TWO:98,NUM_THREE:99,NUM_FOUR:100,NUM_FIVE:101,NUM_SIX:102,NUM_SEVEN:103,NUM_EIGHT:104,NUM_NINE:105,NUM_MULTIPLY:106,NUM_PLUS:107,NUM_MINUS:109,NUM_PERIOD:110,NUM_DIVISION:111,F1:112,F2:113,F3:114,F4:115,F5:116,F6:117,F7:118,F8:119,F9:120,F10:121,F11:122,F12:123,WHEEL_SCALE:function(){var a;if(Ext.isGecko){a=3}else {if(Ext.isMac){if(Ext.isSafari&&Ext.webKitVersion>=532){a=120}else {a=12}a*=3}else {a=120}}return a}()},d={},c,e;Ext.apply(f,a);Ext.apply(b,a);delete a.WHEEL_SCALE;delete a.RETURN;for(c in a){e=a[c];d[e]=c}b.keyCodes=d;b.getTrueXY=b.getXY});Ext.define('Ext.overrides.event.Event',{override:'Ext.event.Event',mousedownEvents:{mousedown:1,pointerdown:1,touchstart:1},injectEvent:function(){var a,b={},c;if(!Ext.isIE9m&&document.createEvent){a={createHtmlEvent:function(e,d,c,b){var a=e.createEvent('HTMLEvents');a.initEvent(d,c,b);return a},createMouseEvent:function(d,n,h,f,m,b,c,i,k,g,j,l,e){var a=d.createEvent('MouseEvents'),o=d.defaultView||window;if(a.initMouseEvent){a.initMouseEvent(n,h,f,o,m,b,c,b,c,i,k,g,j,l,e)}else {a=d.createEvent('UIEvents');a.initEvent(n,h,f);a.view=o;a.detail=m;a.screenX=b;a.screenY=c;a.clientX=b;a.clientY=c;a.ctrlKey=i;a.altKey=k;a.metaKey=j;a.shiftKey=g;a.button=l;a.relatedTarget=e}return a},createUIEvent:function(b,f,d,c,e){var a=b.createEvent('UIEvents'),g=b.defaultView||window;a.initUIEvent(f,d,c,g,e);return a},fireEvent:function(a,c,b){a.dispatchEvent(b)}}}else {if(document.createEventObject){c={0:1,1:4,2:2};a={createHtmlEvent:function(d,e,c,b){var a=d.createEventObject();a.bubbles=c;a.cancelable=b;return a},createMouseEvent:function(n,o,i,g,m,b,d,j,l,h,k,e,f){var a=n.createEventObject();a.bubbles=i;a.cancelable=g;a.detail=m;a.screenX=b;a.screenY=d;a.clientX=b;a.clientY=d;a.ctrlKey=j;a.altKey=l;a.shiftKey=h;a.metaKey=k;a.button=c[e]||e;a.relatedTarget=f;return a},createUIEvent:function(d,f,c,b,e){var a=d.createEventObject();a.bubbles=c;a.cancelable=b;return a},fireEvent:function(a,c,b){a.fireEvent('on'+c,b)}}}}Ext.Object.each({load:[!1,!1],unload:[!1,!1],select:[!0,!1],change:[!0,!1],submit:[!0,!0],reset:[!0,!1],resize:[!0,!1],scroll:[!0,!1]},function(c,d){var f=d[0],e=d[1];b[c]=function(b,h){var g=a.createHtmlEvent(c,f,e);a.fireEvent(b,c,g)}});function createMouseEventDispatcher(b,d){var c=b!=='mousemove';return function(f,e){var g=e.getXY(),h=a.createMouseEvent(f.ownerDocument,b,!0,c,d,g[0],g[1],e.ctrlKey,e.altKey,e.shiftKey,e.metaKey,e.button,e.relatedTarget);a.fireEvent(f,b,h)}}Ext.each(['click','dblclick','mousedown','mouseup','mouseover','mousemove','mouseout'],function(a){b[a]=createMouseEventDispatcher(a,1)});Ext.Object.each({focusin:[!0,!1],focusout:[!0,!1],activate:[!0,!0],focus:[!1,!1],blur:[!1,!1]},function(c,d){var f=d[0],e=d[1];b[c]=function(b,h){var g=a.createUIEvent(b.ownerDocument,c,f,e,1);a.fireEvent(b,c,g)}});if(!a){b={};a={}}function cannotInject(b,a){}return function(a){var c=this,d=b[c.type]||cannotInject,e=a?a.dom||a:c.getTarget();d(e,c)}}(),preventDefault:function(){var c=this,a=c.browserEvent,e=c.parentEvent,d,b;if(typeof a.type!=='unknown'){c.defaultPrevented=!0;if(e){e.defaultPrevented=!0}if(a.preventDefault){a.preventDefault()}else {if(a.type==='mousedown'){b=a.target;d=b.getAttribute('unselectable');if(d!=='on'){b.setAttribute('unselectable','on');Ext.defer(function(){b.setAttribute('unselectable',d)},1)}}a.returnValue=!1;if(a.ctrlKey||a.keyCode>111&&a.keyCode<124){a.keyCode=-1}}}return c},stopPropagation:function(){var a=this,b=a.browserEvent;if(typeof b.type!=='unknown'){if(a.mousedownEvents[a.type]){Ext.GlobalEvents.fireMouseDown(a)}arguments.callee.$previous.call(this)}return a},deprecated:{'5.0':{methods:{clone:function(){return new this.self(this.browserEvent,this)}}}}},function(){var c=this,d,a=function(a){if(a.keyCode===9){c.forwardTab=!a.shiftKey}},b=function(a){if(a.keyCode===9){delete c.forwardTab}};if(Ext.isIE9m){d={0:0,1:0,4:1,2:2};c.override({statics:{enableIEAsync:function(b){var a,c={};for(a in b){c[a]=b[a]}return c}},constructor:function(a,f,e,c){var b=this;b.callParent([a,f,e,c]);b.button=d[a.button];if(a.type==='contextmenu'){b.button=2}b.toElement=a.toElement;b.fromElement=a.fromElement},mouseLeaveRe:/(mouseout|mouseleave)/,mouseEnterRe:/(mouseover|mouseenter)/,enableIEAsync:function(a){this.browserEvent=this.self.enableIEAsync(a)},getRelatedTarget:function(f,d,e){var a=this,c,b;if(!a.relatedTarget){c=a.type;if(a.mouseLeaveRe.test(c)){b=a.toElement}else {if(a.mouseEnterRe.test(c)){b=a.fromElement}}if(b){a.relatedTarget=a.self.resolveTextNode(b)}}return a.callParent([f,d,e])}});document.attachEvent('onkeydown',a);document.attachEvent('onkeyup',b);window.attachEvent('onunload',function(){document.detachEvent('onkeydown',a);document.detachEvent('onkeyup',b)})}else {if(document.addEventListener){document.addEventListener('keydown',a,!0);document.addEventListener('keyup',b,!0)}}});Ext.cmd.derive('Ext.event.publisher.Dom',Ext.event.publisher.Publisher,{type:'dom',handledDomEvents:[],reEnterCount:0,captureEvents:{animationstart:1,animationend:1,resize:1,focus:1,blur:1,scroll:1},directEvents:{mouseenter:1,mouseleave:1,pointerenter:1,pointerleave:1,MSPointerEnter:1,MSPointerLeave:1,load:1,unload:1,beforeunload:1,error:1,DOMContentLoaded:1,DOMFrameContentLoaded:1,hashchange:1},blockedPointerEvents:{pointerover:1,pointerout:1,pointerenter:1,pointerleave:1,MSPointerOver:1,MSPointerOut:1,MSPointerEnter:1,MSPointerLeave:1},blockedCompatibilityMouseEvents:{mouseenter:1,mouseleave:1},constructor:function(){var a=this;a.bubbleSubscribers={};a.captureSubscribers={};a.directSubscribers={};a.directCaptureSubscribers={};a.delegatedListeners={};a.initHandlers();Ext.onInternalReady(a.onReady,a);Ext.event.publisher.Publisher.prototype.constructor.call(this)},registerEvents:function(){var b=this,e=Ext.event.publisher.Publisher.publishersByEvent,d=b.handledDomEvents,f=d.length,c=0,a;for(;cb?1:a1){e=[];for(d=0;d0){b.invokeRecognizers('onTouchMove',a)}}},onTouchEnd:function(b){var a=this;if(!a.isStarted){return}a.updateTouches(b,!0);a.invokeRecognizers(a.isCancelEvent[b.type]?'onTouchCancel':'onTouchEnd',b);if(!a.activeTouches.length){a.isStarted=!1;a.invokeRecognizers('onEnd',b);if(Ext.enableGarbageCollector){Ext.dom.GarbageCollector.resume()}}},onTargetTouchMove:function(a){if(Ext.elevateFunction){Ext.elevateFunction(this.doTargetTouchMove,this,[a])}else {this.doTargetTouchMove(a)}},doTargetTouchMove:function(a){if(!Ext.getBody().contains(a.target)){this.onTouchMove(new Ext.event.Event(a))}},onTargetTouchEnd:function(a){if(Ext.elevateFunction){Ext.elevateFunction(this.doTargetTouchEnd,this,[a])}else {this.doTargetTouchEnd(a)}},doTargetTouchEnd:function(c){var b=this,a=c.target;a.removeEventListener('touchmove',b.onTargetTouchMove);a.removeEventListener('touchend',b.onTargetTouchEnd);a.removeEventListener('touchcancel',b.onTargetTouchEnd);if(!Ext.getBody().contains(a)){b.onTouchEnd(new Ext.event.Event(c))}},updateAsync:function(a){this.handlers=a?this._asyncHandlers:this._handlers},reset:function(){var a=this,d=a.recognizers,e=d.length,b,c;a.activeTouchesMap={};a.activeTouches=[];a.changedTouches=[];a.isStarted=!1;for(b=0;b=500){this.run()}},run:function(){this.pending=!1;var i=this.readQueue,h=this.writeQueue,c=null,d;if(this.mode){d=i;if(h.length>0){c=!1}}else {d=h;if(i.length>0){c=!0}}var g=d.slice(),f,j,b,a,e;d.length=0;for(f=0,j=g.length;f2){a.apply(e,b[2])}else {a.call(e)}}g.length=0;if(c!==null){this.request(c)}}},1,0,0,0,0,0,[Ext,'TaskQueue'],0);Ext.cmd.derive('Ext.util.sizemonitor.Abstract',Ext.Base,{config:{element:null,callback:Ext.emptyFn,scope:null,args:[]},width:0,height:0,contentWidth:0,contentHeight:0,constructor:function(a){this.refresh=Ext.Function.bind(this.refresh,this);this.info={width:0,height:0,contentWidth:0,contentHeight:0,flag:0};this.initElement();this.initConfig(a);this.bindListeners(!0)},bindListeners:Ext.emptyFn,applyElement:function(a){if(a){return Ext.get(a)}},updateElement:function(a){a.append(this.detectorsContainer);a.addCls('x-size-monitored')},applyArgs:function(a){return a.concat([this.info])},refreshMonitors:Ext.emptyFn,forceRefresh:function(){Ext.TaskQueue.requestRead('refresh',this)},getContentBounds:function(){return this.detectorsContainer.getBoundingClientRect()},getContentWidth:function(){return this.detectorsContainer.offsetWidth},getContentHeight:function(){return this.detectorsContainer.offsetHeight},refreshSize:function(){var b=this.getElement();if(!b||b.destroyed){return !1}var h=b.getWidth(),g=b.getHeight(),d=this.getContentWidth(),c=this.getContentHeight(),j=this.contentWidth,i=this.contentHeight,a=this.info,f=!1,e;this.width=h;this.height=g;this.contentWidth=d;this.contentHeight=c;e=(j!==d?1:0)+(i!==c?2:0);if(e>0){a.width=h;a.height=g;a.contentWidth=d;a.contentHeight=c;a.flag=e;f=!0;this.getCallback().apply(this.getScope(),this.getArgs())}return f},refresh:function(a){if(this.refreshSize()||a){Ext.TaskQueue.requestWrite('refreshMonitors',this)}},destroy:function(){var a=this,b=a.getElement();a.bindListeners(!1);if(b&&!b.destroyed){b.removeCls('x-size-monitored')}delete a._element;a.callParent()}},1,0,0,0,0,[[Ext.mixin.Templatable.prototype.mixinId||Ext.mixin.Templatable.$className,Ext.mixin.Templatable]],[Ext.util.sizemonitor,'Abstract'],0);Ext.cmd.derive('Ext.util.sizemonitor.Scroll',Ext.util.sizemonitor.Abstract,{getElementConfig:function(){return {reference:'detectorsContainer',classList:['x-size-monitors','scroll'],children:[{reference:'expandMonitor',className:'expand'},{reference:'shrinkMonitor',className:'shrink'}]}},constructor:function(a){this.onScroll=Ext.Function.bind(this.onScroll,this);Ext.util.sizemonitor.Abstract.prototype.constructor.apply(this,arguments)},bindListeners:function(b){var a=b?'addEventListener':'removeEventListener';this.expandMonitor[a]('scroll',this.onScroll,!0);this.shrinkMonitor[a]('scroll',this.onScroll,!0)},forceRefresh:function(){Ext.TaskQueue.requestRead('refresh',this,[!0])},onScroll:function(){Ext.TaskQueue.requestRead('refresh',this)},refreshMonitors:function(){var a=this.expandMonitor,b=this.shrinkMonitor,c=1000000;if(a&&!a.destroyed){a.scrollLeft=c;a.scrollTop=c}if(b&&!b.destroyed){b.scrollLeft=c;b.scrollTop=c}}},1,0,0,0,0,0,[Ext.util.sizemonitor,'Scroll'],0);Ext.cmd.derive('Ext.util.sizemonitor.OverflowChange',Ext.util.sizemonitor.Abstract,{constructor:function(a){this.onExpand=Ext.Function.bind(this.onExpand,this);this.onShrink=Ext.Function.bind(this.onShrink,this);Ext.util.sizemonitor.Abstract.prototype.constructor.apply(this,arguments)},getElementConfig:function(){return {reference:'detectorsContainer',classList:['x-size-monitors','overflowchanged'],children:[{reference:'expandMonitor',className:'expand',children:[{reference:'expandHelper'}]},{reference:'shrinkMonitor',className:'shrink',children:[{reference:'shrinkHelper'}]}]}},bindListeners:function(b){var a=b?'addEventListener':'removeEventListener';this.expandMonitor[a](Ext.browser.is.Firefox?'underflow':'overflowchanged',this.onExpand,!0);this.shrinkMonitor[a](Ext.browser.is.Firefox?'overflow':'overflowchanged',this.onShrink,!0)},onExpand:function(a){if(Ext.browser.is.Webkit&&a.horizontalOverflow&&a.verticalOverflow){return}Ext.TaskQueue.requestRead('refresh',this)},onShrink:function(a){if(Ext.browser.is.Webkit&&!a.horizontalOverflow&&!a.verticalOverflow){return}Ext.TaskQueue.requestRead('refresh',this)},refreshMonitors:function(){if(this.destroyed){return}var b=this.expandHelper,c=this.shrinkHelper,d=this.getContentBounds(),f=d.width,e=d.height,a;if(b&&!b.destroyed){a=b.style;a.width=f+1+'px';a.height=e+1+'px'}if(c&&!c.destroyed){a=c.style;a.width=f+'px';a.height=e+'px'}Ext.TaskQueue.requestRead('refresh',this)}},1,0,0,0,0,0,[Ext.util.sizemonitor,'OverflowChange'],0);Ext.cmd.derive('Ext.util.SizeMonitor',Ext.Base,{constructor:function(b){var a=Ext.util.sizemonitor;if(Ext.browser.is.Firefox){return new a.OverflowChange(b)}else {return new a.Scroll(b)}}},1,0,0,0,0,0,[Ext.util,'SizeMonitor'],0);Ext.cmd.derive('Ext.event.publisher.ElementSize',Ext.event.publisher.Publisher,{type:'size',handledEvents:['resize'],constructor:function(){this.monitors={};this.subscribers={};Ext.event.publisher.Publisher.prototype.constructor.apply(this,arguments)},subscribe:function(b){var a=b.id,c=this.subscribers,d=this.monitors;if(c[a]){++c[a]}else {c[a]=1;d[a]=new Ext.util.SizeMonitor({element:b,callback:this.onElementResize,scope:this,args:[b]})}b.on('painted','forceRefresh',d[a]);return !0},unsubscribe:function(e){var a=e.id,c=this.subscribers,d=this.monitors,b;if(c[a]&&!--c[a]){delete c[a];b=d[a];e.un('painted','forceRefresh',b);b.destroy();delete d[a]}},onElementResize:function(a,b){Ext.TaskQueue.requestRead('fire',this,[a,'resize',[a,b]])}},1,0,0,0,0,0,[Ext.event.publisher,'ElementSize'],function(a){a.instance=new a()});Ext.cmd.derive('Ext.util.paintmonitor.Abstract',Ext.Base,{config:{element:null,callback:Ext.emptyFn,scope:null,args:[]},eventName:'',monitorClass:'',constructor:function(a){this.onElementPainted=Ext.Function.bind(this.onElementPainted,this);this.initConfig(a)},bindListeners:function(a){this.monitorElement[a?'addEventListener':'removeEventListener'](this.eventName,this.onElementPainted,!0)},applyElement:function(a){if(a){return Ext.get(a)}},updateElement:function(a){this.monitorElement=Ext.Element.create({classList:['x-paint-monitor',this.monitorClass]},!0);a.appendChild(this.monitorElement);a.addCls('x-paint-monitored');this.bindListeners(!0)},onElementPainted:function(){},destroy:function(){var a=this,c=a.monitorElement,d=c.parentNode,b=a.getElement();a.bindListeners(!1);delete a.monitorElement;if(b&&!b.destroyed){b.removeCls('x-paint-monitored');delete a._element}if(d){d.removeChild(c)}a.callParent()}},1,0,0,0,0,0,[Ext.util.paintmonitor,'Abstract'],0);Ext.cmd.derive('Ext.util.paintmonitor.CssAnimation',Ext.util.paintmonitor.Abstract,{eventName:Ext.browser.is.WebKit?'webkitAnimationEnd':'animationend',monitorClass:'cssanimation',onElementPainted:function(a){if(a.animationName==='x-paint-monitor-helper'){this.getCallback().apply(this.getScope(),this.getArgs())}}},0,0,0,0,0,0,[Ext.util.paintmonitor,'CssAnimation'],0);Ext.cmd.derive('Ext.util.PaintMonitor',Ext.Base,{constructor:function(a){return new Ext.util.paintmonitor.CssAnimation(a)}},1,0,0,0,0,0,[Ext.util,'PaintMonitor'],0);Ext.cmd.derive('Ext.event.publisher.ElementPaint',Ext.event.publisher.Publisher,{type:'paint',handledEvents:['painted'],constructor:function(){this.monitors={};this.subscribers={};Ext.event.publisher.Publisher.prototype.constructor.apply(this,arguments)},subscribe:function(d){var b=this,a=d.id,c=b.subscribers;if(c[a]){++c[a]}else {c[a]=1;b.monitors[a]=new Ext.util.PaintMonitor({element:d,callback:b.onElementPainted,scope:b,args:[d]})}},unsubscribe:function(d){var a=d.id,b=this.subscribers,c=this.monitors;if(b[a]&&!--b[a]){delete b[a];c[a].destroy();delete c[a]}},onElementPainted:function(a){Ext.TaskQueue.requestRead('fire',this,[a,'painted',[a]])}},1,0,0,0,0,0,[Ext.event.publisher,'ElementPaint'],function(a){a.instance=new a()});Ext.cmd.derive('Ext.dom.Element',Ext.Base,function(a){var h=window,b=document,F='ext-window',D='ext-document',w='width',H='height',ac='min-width',_='min-height',ab='max-width',$='max-height',S='top',P='right',ag='bottom',R='left',aa='visibility',M='hidden',G='display',x='none',O='z-index',u='position',ad='relative',N='static',i='-',T=/\w/g,k=/\s+/,V=/[\s]+/,Y=/^(?:transparent|(?:rgba[(](?:\s*\d+\s*[,]){3}\s*0\s*[)]))$/i,U=/table-row|table-.*-group/,Q=/top/i,d={t:'border-top-width',r:'border-right-width',b:'border-bottom-width',l:'border-left-width'},f={t:'padding-top',r:'padding-right',b:'padding-bottom',l:'padding-left'},v={t:'margin-top',r:'margin-right',b:'margin-bottom',l:'margin-left'},Z=[f.l,f.r,f.t,f.b],B=[d.l,d.r,d.t,d.b],ae=/\d+$/,I=/\d+(px|em|%|en|ex|pt|in|cm|mm|pc)$/i,C='px',af=/(-[a-z])/gi,J=/([a-z0-9\-]+)\s*:\s*([^;\s]+(?:\s*[^;\s]+)*);?/gi,t=/^\d+(?:\.\d*)?px$/i,A={},y='originalDisplay',X=function(c,b){return b.charAt(1).toUpperCase()},E=function(d,e){var c,b,f;if(d.nodeType===1){d._extData=null;if(e){c=d.childNodes;for(b=0,f=c.length;bh.innerWidth?'portrait':'landscape'},getViewportHeight:function(){var c=a._viewportHeight;if(Ext.isIE9m){return b.documentElement.clientHeight}return c!=null?c:h.innerHeight},getViewportWidth:function(){var c=a._viewportWidth;if(Ext.isIE9m){return b.documentElement.clientWidth}return c!=null?c:h.innerWidth},getViewSize:function(){return {width:a.getViewportWidth(),height:a.getViewportHeight()}},normalize:function(b){return A[b]||(A[b]=b.replace(af,X))},_onWindowFocusChange:function(b){if(Ext.fly(b.target).is(a.editableSelector)){z=new Date();L=b.type==='focusin'||b.type==='pointerup'}},_onWindowResize:function(){var c=window.innerWidth,b=window.innerHeight,g=new Date(),f=1000,d,e;d=c-a._windowWidth;e=b-a._windowHeight;a._windowWidth=c;a._windowHeight=b;if(g-z=a.minKeyboardHeight){l=!1;K=new Date()}if(l){return}a._viewportWidth=c;a._viewportHeight=b},parseBox:function(c){c=c||0;var e=typeof c,b,d;if(e==='number'){return {top:c,right:c,bottom:c,left:c}}else {if(e!=='string'){return c}}b=c.split(' ');d=b.length;if(d===1){b[1]=b[2]=b[3]=b[0]}else {if(d===2){b[2]=b[0];b[3]=b[1]}else {if(d===3){b[3]=b[1]}}}return {top:parseFloat(b[0])||0,right:parseFloat(b[1])||0,bottom:parseFloat(b[2])||0,left:parseFloat(b[3])||0}},parseStyles:function(c){var d={},b;if(c){J.lastIndex=0;while(b=J.exec(c)){d[b[1]]=b[2]||''}}return d},select:function(d,c,e){return Ext.fly(e||b).select(d,c)},query:function(c,d,e){return Ext.fly(e||b).query(c,d)},unitizeBox:function(b,d){var c=this;b=c.parseBox(b);return c.addUnits(b.top,d)+' '+c.addUnits(b.right,d)+' '+c.addUnits(b.bottom,d)+' '+c.addUnits(b.left,d)},serializeForm:function(l){var m=l.elements||(b.forms[l]||Ext.getDom(l)).elements,n=!1,f=encodeURIComponent,g='',q=m.length,c,h,d,k,o,i,j,p,e;for(i=0;i0||b.scrollLeft!==0){e.push(b);g.push(c.attach(b).getScroll())}}return function(){var d,b,f;for(b=0,f=e.length;b '+d,!!c)},clone:function(c,d){var b=this.dom.cloneNode(c);if(Ext.supports.CloneNodeCopiesExpando){E(b,c)}return d?b:Ext.get(b)},constrainScrollLeft:function(c){var b=this.dom;return Math.max(Math.min(c,b.scrollWidth-b.clientWidth),0)},constrainScrollTop:function(c){var b=this.dom;return Math.max(Math.min(c,b.scrollHeight-b.clientHeight),0)},createChild:function(b,c,d){b=b||{tag:'div'};if(c){return Ext.DomHelper.insertBefore(c,b,d!==!0)}else {return Ext.DomHelper.append(this.dom,b,d!==!0)}},contains:function(b){if(!b){return !1}var d=this,c=Ext.getDom(b);return c===d.dom||d.isAncestor(c)},destroy:function(){var c=this,b=c.dom;if(b&&b.parentNode){b.parentNode.removeChild(b)}c.collect();if(!c.isFly){c.callParent()}},detach:function(){var b=this.dom;if(b&&b.parentNode&&b.tagName!=='BODY'){b.parentNode.removeChild(b)}return this},disableShadow:function(){var b=this.shadow;if(b){b.hide();b.disabled=!0}},disableShim:function(){var b=this.shim;if(b){b.hide();b.disabled=!0}},disableTouchContextMenu:function(){this._contextMenuListenerRemover=this.on({MSHoldVisual:function(b){b.preventDefault()},destroyable:!0,delegated:!1})},disableTouchScroll:function(){this.addCls(W);this.on({touchmove:function(b){b.preventDefault()},translate:!1})},doReplaceWith:function(c){var b=this.dom;b.parentNode.replaceChild(Ext.getDom(c),b)},doScrollIntoView:function(b,o,d,m,l,n){c=c||new Ext.dom.Fly();var e=this,k=e.dom,i=c.attach(b)[l](),j=b.scrollTop,h=e.getScrollIntoViewXY(b,i,j),f=h.x,g=h.y;if(m){if(d){d=Ext.apply({listeners:{afteranimate:function(){c.attach(k).highlight()}}},d)}else {c.attach(k).highlight()}}if(g!==j){c.attach(b).scrollTo('top',g,d)}if(o!==!1&&f!==i){c.attach(b)[n]('left',f,d)}return e},down:function(c,b){return this.selectNode(c,!!b)},enableShadow:function(f,e){var c=this,b=c.shadow||(c.shadow=new Ext.dom.Shadow(Ext.apply({target:c},f))),d=c.shim;if(d){d.offsets=b.outerOffsets;d.shadow=b;b.shim=d}if(e===!0||e!==!1&&c.isVisible()){b.show()}else {b.hide()}b.disabled=!1},enableShim:function(f,e){var c=this,b=c.shim||(c.shim=new Ext.dom.Shim(Ext.apply({target:c},f))),d=c.shadow;if(d){b.offsets=d.outerOffsets;b.shadow=d;d.shim=b}if(e===!0||e!==!1&&c.isVisible()){b.show()}else {b.hide()}b.disabled=!1},findParent:function(g,d,h){var i=this,c=i.dom,e=b.documentElement,f=0;if(d||d===0){if(typeof d!=='number'){e=Ext.getDom(d);d=Number.MAX_VALUE}}else {d=50}while(c&&c.nodeType===1&&f0&&d<0.5){b++}}}if(e){b-=c.getBorderWidth('tb')+c.getPadding('tb')}return b<0?0:b},getHtml:function(){return this.dom?this.dom.innerHTML:''},getLeft:function(b){return b?this.getLocalX():this.getX()},getLocalX:function(){var d=this,c,b=d.getStyle('left');if(!b||b==='auto'){b=0}else {if(t.test(b)){b=parseFloat(b)}else {b=d.getX();c=d.dom.offsetParent;if(c){b-=Ext.fly(c).getX()}}}return b},getLocalXY:function(){var e=this,d,f=e.getStyle(['left','top']),b=f.left,c=f.top;if(!b||b==='auto'){b=0}else {if(t.test(b)){b=parseFloat(b)}else {b=e.getX();d=e.dom.offsetParent;if(d){b-=Ext.fly(d).getX()}}}if(!c||c==='auto'){c=0}else {if(t.test(c)){c=parseFloat(c)}else {c=e.getY();d=e.dom.offsetParent;if(d){c-=Ext.fly(d).getY()}}}return [b,c]},getLocalY:function(){var d=this,c,b=d.getStyle('top');if(!b||b==='auto'){b=0}else {if(t.test(b)){b=parseFloat(b)}else {b=d.getY();c=d.dom.offsetParent;if(c){b-=Ext.fly(c).getY()}}}return b},getMargin:function(){var c={t:'top',l:'left',r:'right',b:'bottom'},b=['margin-top','margin-left','margin-right','margin-bottom'];return function(g){var h=this,e,f,d;if(!g){e=h.getStyle(b);d={};if(e&&typeof e==='object'){d={};for(f in v){d[f]=d[c[f]]=parseFloat(e[v[f]])||0}}}else {d=h.addStyles(g,v)}return d}}(),getPadding:function(b){return this.addStyles(b,f)},getParent:function(){return Ext.get(this.dom.parentNode)},getRight:function(b){return (b?this.getLocalX():this.getX())+this.getWidth()},getScroll:function(){var h=this,d=h.dom,g=b.documentElement,e,f,c=document.body;if(d===b||d===c){e=g.scrollLeft||(c?c.scrollLeft:0);f=g.scrollTop||(c?c.scrollTop:0)}else {e=d.scrollLeft;f=d.scrollTop}return {left:e,top:f}},getScrollIntoViewXY:function(r,b,c){var p=this.dom,h=Ext.getDom(r),j=this.getOffsetsTo(h),o=p.offsetWidth,m=p.offsetHeight,f=j[0]+b,g=j[1]+c,l=g+m,n=f+o,d=h.clientHeight,e=h.clientWidth,i=b,k=c,q=k+d,s=i+e;if(m>d||gq){c=l-d}}if(o>e||fs){b=n-e}}return {x:b,y:c}},getScrollLeft:function(){var c=this.dom;if(c===b||c===document.body){return this.getScroll().left}else {return c.scrollLeft}},getScrollTop:function(){var c=this.dom;if(c===b||c===document.body){return this.getScroll().top}else {return c.scrollTop}},getSize:function(b){return {width:this.getWidth(b),height:this.getHeight(b)}},getStyle:function(n,i){var k=this,e=k.dom,m=typeof n!=='string',p=k.styleHooks,b=n,j=b,q=1,h,o,f,d,g,c,l;if(m){f={};b=j[0];l=0;if(!(q=j.length)){return f}}if(!e||e.documentElement){return f||''}h=e.style;if(i){c=h}else {c=e.ownerDocument.defaultView.getComputedStyle(e,null);if(!c){i=!0;c=h}}do{d=p[b];if(!d){p[b]=d={name:a.normalize(b)}}if(d.get){g=d.get(e,k,i,c)}else {o=d.name;g=c[o]}if(!m){return g}f[b]=g;b=j[++l]}while(l0&&e<0.5){b++}}}if(h){b-=c.getBorderWidth('lr')+c.getPadding('lr')}return b<0?0:b},getX:function(){return this.getXY()[0]},getXY:function(){var h=Math.round,e=this.dom,f=0,g=0,c,d;if(e!==b&&e!==b.body){try{c=e.getBoundingClientRect()}catch(ah){c={left:0,top:0}}f=h(c.left);g=h(c.top);d=Ext.getDoc().getScroll();f+=d.left;g+=d.top}return [f,g]},getY:function(){return this.getXY()[1]},getZIndex:function(){return parseInt(this.getStyle('z-index'),10)},hasCls:function(c){var b=this.getData();if(!b.isSynchronized){this.synchronize()}return b.classMap.hasOwnProperty(c)},hide:function(){this.setVisible(!1);return this},insertAfter:function(b){b=Ext.getDom(b);b.parentNode.insertBefore(this.dom,b.nextSibling);return this},insertBefore:function(b){b=Ext.getDom(b);b.parentNode.insertBefore(this.dom,b);return this},insertFirst:function(b,c){b=b||{};if(b.nodeType||b.dom||typeof b==='string'){b=Ext.getDom(b);this.dom.insertBefore(b,this.dom.firstChild);return !c?Ext.get(b):b}else {return this.createChild(b,this.dom.firstChild,c)}},insertHtml:function(d,e,c){var b=Ext.DomHelper.insertHtml(d,this.dom,e);return c?Ext.get(b):b},insertSibling:function(b,k,f){var d=this,j=Ext.DomHelper,h=(k||'before').toLowerCase()==='after',c,g,i,e;if(Ext.isIterable(b)){i=b.length;g=Ext.fly(document.createDocumentFragment());if(Ext.isArray(b)){for(e=0;eb.clientHeight||b.scrollWidth>b.clientWidth},isStyle:function(b,c){return this.getStyle(b)===c},isVisible:function(d){var b=this.dom,c;if(!b){return !1}if(!s){s=new Ext.dom.Fly()}for(c=b.ownerDocument.documentElement;b!==c;b=b.parentNode){if(!b||b.nodeType===11||s.attach(b).isStyle(aa,M)||s.isStyle(G,x)){return !1}if(!d){break}}return !0},last:function(c,b){return this.matchNode('previousSibling','lastChild',c,b)},maskIframes:function(){var b=document.getElementsByTagName('iframe');Ext.each(b,function(c){var b=Ext.fly(c.parentNode),d=b.mask();d.setStyle('background-color','transparent')})},matchNode:function(g,f,c,e){var d=this.dom,b;if(!d){return null}b=d[f];while(b){if(b.nodeType===1&&(!c||Ext.fly(b,'_matchNode').is(c))){return !e?Ext.get(b):b}b=b[g]}return null},next:function(c,b){return this.matchNode('nextSibling','nextSibling',c,b)},parent:function(c,b){return this.matchNode('parentNode','parentNode',c,b)},position:function(c,d,e,f){var b=this;if(b.dom.tagName!=='BODY'){if(!c&&b.isStyle(u,N)){b.setStyle(u,ad)}else {if(c){b.setStyle(u,c)}}if(d){b.setStyle(O,d)}if(e||f){b.setXY([e||!1,f||!1])}}},prev:function(c,b){return this.matchNode('previousSibling','previousSibling',c,b)},query:function(b,e,j){var i=this.dom,g,l,k,h,f,c,d;if(!i){return null}e=e!==!1;b=b.split(',');if(!j){g=[]}for(c=0,l=b.length;c0){b=i.className.split(V);for(c=0,j=b.length;c=':function(b){var a=this._filterValue;return this.getCandidateValue(b,a)>=a},'>':function(b){var a=this._filterValue;return this.getCandidateValue(b,a)>a},'!=':function(a){var b=this,c=b._filterValue;a=b.getCandidateValue(a,c);if(b.isDateValue&&a instanceof Date){a=a.getTime();c=b.dateValue}return a!=c},'!==':function(a){var b=this,c=b._filterValue;a=b.getCandidateValue(a,c,!0);if(b.isDateValue&&a instanceof Date){a=a.getTime();c=b.dateValue}return a!==c},'in':function(b){var a=this._filterValue;return Ext.Array.contains(a,this.getCandidateValue(b,a))},notin:function(b){var a=this._filterValue;return !Ext.Array.contains(a,this.getCandidateValue(b,a))},like:function(b){var a=this._filterValue;return a&&this.getCandidateValue(b,a).toLowerCase().indexOf(a.toLowerCase())>-1}};a['==']=a['='];a.gt=a['>'];a.ge=a['>='];a.lt=a['<'];a.le=a['<='];a.eq=a['='];a.ne=a['!=']});Ext.cmd.derive('Ext.util.Observable',Ext.mixin.Observable,{$applyConfigs:!0},0,0,0,0,0,0,[Ext.util,'Observable'],function(a){var b=Ext.mixin.Observable;a.releaseCapture=b.releaseCapture;a.capture=b.capture;a.captureArgs=b.captureArgs;a.observe=a.observeClass=b.observe});Ext.cmd.derive('Ext.util.AbstractMixedCollection',Ext.Base,{isMixedCollection:!0,generation:0,indexGeneration:0,constructor:function(b,c){var a=this;if(arguments.length===1&&Ext.isObject(b)){a.initialConfig=b;Ext.apply(a,b)}else {a.allowFunctions=b===!0;if(c){a.getKey=c}a.initialConfig={allowFunctions:a.allowFunctions,getKey:a.getKey}}a.items=[];a.map={};a.keys=[];a.indexMap={};a.length=0;a.mixins.observable.constructor.call(a)},destroy:function(){var a=this;a.items=a.map=a.keys=a.indexMap=null;a.callParent()},allowFunctions:!1,add:function(b,d){var c=this.length,a;if(arguments.length===1){a=this.insert(c,b)}else {a=this.insert(c,b,d)}return a},getKey:function(a){return a.id},replace:function(b,c){var a=this,d,e;if(arguments.length==1){c=arguments[0];b=a.getKey(c)}d=a.map[b];if(typeof b=='undefined'||b===null||typeof d=='undefined'){return a.add(b,c)}a.generation++;e=a.indexOfKey(b);a.items[e]=c;a.map[b]=c;if(a.hasListeners.replace){a.fireEvent('replace',b,d,c)}return c},reorder:function(e){var b=this,f=b.items,a=0,h=f.length,c=[],g=[],d;b.suspendEvents();for(d in e){c[e[d]]=f[d]}for(a=0;a-1){g=e[b];delete e[b];delete f[b];e[c]=g;f[c]=d;a.keys[d]=c;a.indexGeneration=++a.generation}},addAll:function(a){var c=this,b;if(arguments.length>1||Ext.isArray(a)){c.insert(c.length,arguments.length>1?arguments:a)}else {for(b in a){if(a.hasOwnProperty(b)){if(c.allowFunctions||typeof a[b]!='function'){c.add(b,a[b])}}}}},each:function(f,e){var c=Ext.Array.push([],this.items),a=0,d=c.length,b;for(;a2){a=this.doInsert(c,[b],[d])}else {a=this.doInsert(c,[b])}a=a[0]}return a},doInsert:function(f,e,d){var b=this,c,i,a,g=e.length,j=g,o=b.hasListeners.add,k,h={},l,n,m;if(d!=null){b.useLinearSearch=!0}else {d=e;e=new Array(g);for(a=0;a=0;--c){a.remove(b[c])}}else {while(a.length){a.removeAt(0)}}}else {a.length=a.items.length=a.keys.length=0;a.map={};a.indexMap={};a.generation++;a.indexGeneration=a.generation}},removeAt:function(b){var a=this,d,c;if(b=0){a.length--;d=a.items[b];Ext.Array.erase(a.items,b,1);c=a.keys[b];if(typeof c!='undefined'){delete a.map[c]}Ext.Array.erase(a.keys,b,1);if(a.hasListeners.remove){a.fireEvent('remove',d,c)}a.generation++;return d}return !1},removeRange:function(c,b){var a=this,i,f,d,e,g,h;if(c=0){if(!b){b=1}e=Math.min(c+b,a.length);b=e-c;h=e===a.length;g=h&&a.indexGeneration===a.generation;for(d=c;d=0;a--){if(c[a]==null){b.removeAt(a)}}}else {return b.removeAt(b.indexOfKey(d))}},getCount:function(){return this.length},indexOf:function(b){var a=this,c;if(b!=null){if(!a.useLinearSearch&&(c=a.getKey(b))){return this.indexOfKey(c)}return Ext.Array.indexOf(a.items,b)}return -1},indexOfKey:function(a){if(!this.map.hasOwnProperty(a)){return -1}if(this.indexGeneration!==this.generation){this.rebuildIndexMap()}return this.indexMap[a]},rebuildIndexMap:function(){var b=this,d=b.indexMap={},c=b.keys,e=c.length,a;for(a=0;aa){e=!0;g=b;b=a;a=g}if(b<0){b=0}if(a==null||a>=d){a=d-1}c=f.slice(b,a+1);if(e&&c.length){c.reverse()}return c},filter:function(a,e,d,c){var b=[];if(Ext.isString(a)){b.push(new Ext.util.Filter({property:a,value:e,anyMatch:d,caseSensitive:c}))}else {if(Ext.isArray(a)||a instanceof Ext.util.Filter){b=b.concat(a)}}return this.filterBy(Ext.util.Filter.createFilterFn(b))},filterBy:function(h,g){var a=this,c=new a.self(a.initialConfig),e=a.keys,d=a.items,f=d.length,b;c.getKey=a.getKey;for(b=0;bb?1:a0){c.removeRange(b.multiSortLimit,g)};break;case 'prepend':c.insert(0,a);break;case 'append':c.addAll(a);break;case undefined:case null:case 'replace':c.clear();c.addAll(a);break;default:}}if(h!==!1){b.fireEvent('beforesort',b,a);b.onBeforeSort(a);if(b.getSorterCount()){b.doSort(b.generateComparator())}}return a},getSorterCount:function(){return this.getSorters().items.length},generateComparator:function(){var a=this.getSorters().getRange();return a.length?this.createComparator(a):this.emptyComparator},emptyComparator:function(){return 0},onBeforeSort:Ext.emptyFn,decodeSorters:function(b){if(!Ext.isArray(b)){if(b===undefined){b=[]}else {b=[b]}}var g=b.length,f=Ext.util.Sorter,e=this.getModel?this.getModel():this.model,d,a,c;for(c=0;c>1;c=d(h,f[a]);if(c>=0){b=a+1}else {if(c<0){e=a-1}}}return b},reorder:function(a){Ext.util.AbstractMixedCollection.prototype.reorder.call(this,a);this.fireEvent('sort',this)},sortByKey:function(a,b){this._sort('key',a,b||function(e,f){var c=String(e).toUpperCase(),d=String(f).toUpperCase();return c>d?1:cf){k=f}}}if(c){b.tasks=c}b.firing=!1;if(b.tasks.length){b.startTimer(k-g,Ext.Date.now())}if(j!==!1&&l.hasListeners.idle){l.fireEvent('idle')}},startTimer:function(b,e){var a=this,d=e+b,c=a.timerId;if(c&&a.nextExpires-d>a.interval){clearTimeout(c);c=null}if(!c){if(b=a.duration,b,c;if(h){d=a.duration;e=!0}b=this.collectTargetData(a,d,f,e);if(f){a.target.setAttr(b.anims[a.id].attributes,!0);g.collectTargetData(a,a.duration,f,e);a.paused=!0;b=a.target.target;if(a.target.isComposite){b=a.target.target.last()}c={};c[Ext.supports.CSS3TransitionEnd]=a.lastFrame;c.scope=a;c.single=!0;b.on(c)}return b},jumpToEnd:function(d){var a=this,b,c;if(!a.targetArr){a.targetArr={};c=!0}b=a.runAnim(d,!0);a.applyAnimAttrs(b,b.anims[d.id]);if(c){a.targetArr=null}},collectTargetData:function(a,d,f,e){var c=a.target.getId(),b=this.targetArr[c];if(!b){b=this.targetArr[c]={id:c,el:a.target,anims:{}}}b.anims[a.id]={id:a.id,anim:a,elapsed:d,isLastFrame:e,attributes:[{duration:a.duration,easing:f&&a.reverse?a.easingFn.reverse().toCSS3():a.easing,attrs:a.runAnim(d)}]};return b},applyAnimAttrs:function(c,a){var b=a.anim;if(a.attributes&&b.isRunning()){c.el.setAttr(a.attributes,!1,a.isLastFrame);if(a.isLastFrame){b.lastFrame()}}},applyPendingAttrs:function(){var c=this.targetArr,b,d,a,f,e;for(d in c){if(c.hasOwnProperty(d)){b=c[d];for(e in b.anims){if(b.anims.hasOwnProperty(e)){a=b.anims[e];f=a.anim;if(a.attributes&&f.isRunning()){b.el.setAttr(a.attributes,!1,a.isLastFrame);if(a.isLastFrame){f.lastFrame()}}}}}}}},1,0,0,0,0,[['queue',Ext.fx.Queue]],[Ext.fx,'Manager'],0);Ext.cmd.derive('Ext.fx.Animator',Ext.Base,{isAnimator:!0,duration:250,delay:0,delayStart:0,dynamic:!1,easing:'ease',running:!1,paused:!1,damper:1,iterations:1,currentIteration:0,keyframeStep:0,animKeyFramesRE:/^(from|to|\d+%?)$/,constructor:function(b){var a=this;b=Ext.apply(a,b||{});a.config=b;a.id=Ext.id(null,'ext-animator-');a.mixins.observable.constructor.call(a,b);a.timeline=[];a.createTimeline(a.keyframes);if(a.target){a.applyAnimator(a.target);Ext.fx.Manager.addAnim(a)}},sorter:function(a,b){return a.pct-b.pct},createTimeline:function(e){var d=this,b=[],k=d.to||{},g=d.duration,h,j,c,i,a,f;for(a in e){if(e.hasOwnProperty(a)&&d.animKeyFramesRE.test(a)){f={attrs:Ext.apply(e[a],k)};if(a==='from'){a=0}else {if(a==='to'){a=100}}f.pct=parseInt(a,10);b.push(f)}}Ext.Array.sort(b,d.sorter);i=b.length;for(c=0;c0},isRunning:function(){return !1}},1,0,0,0,0,[['observable',Ext.util.Observable]],[Ext.fx,'Animator'],0);Ext.cmd.derive('Ext.fx.CubicBezier',Ext.Base,{singleton:!0,cubicBezierAtTime:function(l,d,e,i,j,h){var a=3*d,b=3*(i-d)-a,f=1-a-b,c=3*e,g=3*(j-e)-c,k=1-c-g;function sampleCurveX(c){return ((f*c+b)*c+a)*c}function solve(f,b){var a=solveCurveX(f,b);return ((k*a+g)*a+c)*a}function solveCurveX(n,q){var g,k,c,m,o,p;for(c=n,p=0;p<8;p++){m=sampleCurveX(c)-n;if(Math.abs(m)k){return k}while(gm){g=c}else {k=c}c=(k-g)/2+g}return c}return solve(l,1/(200*h))},cubicBezier:function(b,d,c,e){var a=function(a){return Ext.fx.CubicBezier.cubicBezierAtTime(a,b,d,c,e,1)};a.toCSS3=function(){return 'cubic-bezier('+[b,d,c,e].join(',')+')'};a.reverse=function(){return Ext.fx.CubicBezier.cubicBezier(1-c,1-e,1-b,1-d)};return a}},0,0,0,0,0,0,[Ext.fx,'CubicBezier'],0);Ext.cmd.derive('Ext.fx.Easing',Ext.Base,function(){var b=Math,g=b.PI,a=b.pow,f=b.sin,e=b.sqrt,d=b.abs,c=1.70158;return {singleton:!0,linear:Ext.identityFn,ease:function(k){var c=0.07813-k/2,f=e(0.0066+c*c),g=f-c,i=a(d(g),1/3)*(g<0?-1:1),h=-f-c,j=a(d(h),1/3)*(h<0?-1:1),b=i+j+0.25;return a(1-b,2)*3*b*0.1+(1-b)*3*b*b+b*b*b},easeIn:function(b){return a(b,1.7)},easeOut:function(b){return a(b,0.48)},easeInOut:function(k){var c=0.48-k/1.04,f=e(0.1734+c*c),g=f-c,i=a(d(g),1/3)*(g<0?-1:1),h=-f-c,j=a(d(h),1/3)*(h<0?-1:1),b=i+j+0.5;return (1-b)*3*b*b+b*b*b},backIn:function(a){return a*a*((c+1)*a-c)},backOut:function(a){a=a-1;return a*a*((c+1)*a+c)+1},elasticIn:function(b){if(b===0||b===1){return b}var c=0.3,d=c/4;return a(2,-10*b)*f((b-d)*(2*g)/c)+1},elasticOut:function(a){return 1-Ext.fx.Easing.elasticIn(1-a)},bounceIn:function(a){return 1-Ext.fx.Easing.bounceOut(1-a)},bounceOut:function(a){var d=7.5625,b=2.75,c;if(a<1/b){c=d*a*a}else {if(a<2/b){a-=1.5/b;c=d*a*a+0.75}else {if(a<2.5/b){a-=2.25/b;c=d*a*a+0.9375}else {a-=2.625/b;c=d*a*a+0.984375}}}return c}}},0,0,0,0,0,0,[Ext.fx,'Easing'],function(c){var b=c.self,a=b.prototype;b.addMembers({'back-in':a.backIn,'back-out':a.backOut,'ease-in':a.easeIn,'ease-out':a.easeOut,'elastic-in':a.elasticIn,'elastic-out':a.elasticOut,'bounce-in':a.bounceIn,'bounce-out':a.bounceOut,'ease-in-out':a.easeInOut})});Ext.cmd.derive('Ext.fx.DrawPath',Ext.Base,{singleton:!0,pathToStringRE:/,?([achlmqrstvxz]),?/gi,pathCommandRE:/([achlmqstvz])[\s,]*((-?\d*\.?\d*(?:e[-+]?\d+)?\s*,?\s*)+)/ig,pathValuesRE:/(-?\d*\.?\d*(?:e[-+]?\d+)?)\s*,?\s*/ig,stopsRE:/^(\d+%?)$/,radian:Math.PI/180,is:function(b,a){a=String(a).toLowerCase();return a=='object'&&b===Object(b)||a=='undefined'&&typeof b==a||a=='null'&&b===null||a=='array'&&Array.isArray&&Array.isArray(b)||Object.prototype.toString.call(b).toLowerCase().slice(8,-1)==a},path2string:function(){return this.join(',').replace(Ext.fx.DrawPath.pathToStringRE,'$1')},pathToString:function(a){return a.join(',').replace(Ext.fx.DrawPath.pathToStringRE,'$1')},parsePathString:function(c){if(!c){return null}var d={a:7,c:6,h:1,l:2,m:2,q:4,s:4,t:2,v:1,z:0},a=[],b=this;if(b.is(c,'array')&&b.is(c[0],'array')){a=b.pathClone(c)}if(!a.length){String(c).replace(b.pathCommandRE,function(i,g,h){var e=[],f=g.toLowerCase();h.replace(b.pathValuesRE,function(b,a){if(a){e.push(+a)}});if(f=='m'&&e.length>2){a.push([g].concat(Ext.Array.splice(e,0,2)));f='l';g=g=='m'?'l':'L'}while(e.length>=d[f]){a.push([g].concat(Ext.Array.splice(e,0,d[f])));if(!d[f]){break}}})}a.toString=b.path2string;return a},pathClone:function(a){var d=[],c,f,b,e;if(!this.is(a,'array')||!this.is(a&&a[0],'array')){a=this.parsePathString(a)}for(b=0,e=a.length;b7){a[d].shift();var e=a[d];while(e.length){Ext.Array.splice(a,d++,0,['C'].concat(Ext.Array.splice(e,0,6)))}Ext.Array.erase(a,d,1);j=Math.max(c.length,b.length||0)}},m=function(d,f,e,g,a){if(d&&f&&d[a][0]=='M'&&f[a][0]!='M'){Ext.Array.splice(f,a,0,['M',g.x,g.y]);e.bx=0;e.by=0;e.x=d[a][1];e.y=d[a][2];j=Math.max(c.length,b.length||0)}},a,j,g,f,i,h;for(a=0,j=Math.max(c.length,b.length||0);a1){u=N(u);d=u*d;c=u*c}x=d*d;y=c*c;I=(X==v?-1:1)*N(R((x*y-x*j*j-y*i*i)/(x*j*j+y*i*i)));q=I*d*j/c+(m+e)/2;r=I*-c*i/d+(n+f)/2;b=M(((n-r)/c).toFixed(7));a=M(((f-r)/c).toFixed(7));b=ma){b=b-k*2}if(!v&&a>b){a=a-k*2}}else {b=o[0];a=o[1];q=o[2];r=o[3]}z=a-b;if(R(z)>Q){L=a;O=e;P=f;a=b+Q*(v&&a>b?1:-1);e=q+d*B(a);f=r+c*C(a);g=s.arc2curve(e,f,d,c,K,0,v,O,P,[a,L,q,r])}z=a-b;S=B(b);V=C(b);T=B(a);W=C(a);J=p.tan(z/4);D=4/3*d*J;E=4/3*c*J;F=[m,n];l=[m+D*V,n-E*S];G=[e+D*W,f-E*T];H=[e,f];l[0]=2*F[0]-l[0];l[1]=2*F[1]-l[1];if(o){return [l,G,H].concat(g)}else {g=[l,G,H].concat(g).join().split(',');A=[];U=g.length;for(h=0;h=d){b=d;f=!0}if(a.reverse){b=d-b}for(c in e){if(e.hasOwnProperty(c)){h=e[c];g=f?1:k(b/d);i[c]=j[c].set(h,g)}}a.frameCount++;return i},lastFrame:function(){var a=this,c=a.iterations,b=a.currentIteration;b++;if(b0},isRunning:function(){return this.paused===!1&&this.running===!0&&this.isAnimator!==!0}},1,0,0,0,0,[['observable',Ext.util.Observable]],[Ext.fx,'Anim'],0);Ext.enableFx=!0;Ext.cmd.derive('Ext.util.Animate',Ext.Base,{mixinId:'animate',isAnimate:!0,animate:function(b){var a=this;if(Ext.fx.Manager.hasFxBlock(a.id)){return a}Ext.fx.Manager.queueFx(new Ext.fx.Anim(a.anim(b)));return this},anim:function(a){if(!Ext.isObject(a)){return a?{}:!1}var b=this;if(a.stopAnimation){b.stopAnimation()}Ext.applyIf(a,Ext.fx.Manager.getFxDefaults(b.id));return Ext.apply({target:b,paused:!0},a)},getAnimationProps:function(){var b=this,a=b.layout;return a&&a.animate?a.animate:{}},stopFx:Ext.Function.alias(Ext.util.Animate,'stopAnimation'),stopAnimation:function(){Ext.fx.Manager.stopAnimation(this.id);return this},syncFx:function(){Ext.fx.Manager.setFxDefaults(this.id,{concurrent:!0});return this},sequenceFx:function(){Ext.fx.Manager.setFxDefaults(this.id,{concurrent:!1});return this},hasActiveFx:Ext.Function.alias(Ext.util.Animate,'getActiveAnimation'),getActiveAnimation:function(){return Ext.fx.Manager.getActiveAnimation(this.id)}},0,0,0,0,0,0,[Ext.util,'Animate'],0);Ext.cmd.derive('Ext.dom.Fly',Ext.dom.Element,{alternateClassName:'Ext.dom.Element.Fly',validNodeTypes:{1:1,9:1,11:1},isFly:!0,constructor:function(a){this.dom=a;this.el=this},attach:function(b){var a=this;if(!b){return a.detach()}a.dom=b;if(!Ext.cache[b.id]){a.getData().isSynchronized=!1}return a},detach:function(){this.dom=null},addListener:null,removeListener:null},1,0,0,0,0,0,[Ext.dom,'Fly',Ext.dom.Element,'Fly'],function(b){var a={};b.cache=a;Ext.fly=function(c,e){var d=null,h=Ext.fly,f,g;e=e||h.caller&&h.caller.$name||'_global';c=Ext.getDom(c);if(c){f=c.nodeType;if(b.prototype.validNodeTypes[f]||!f&&c.window==c){d=Ext.cache[c.id];if(!d||d.dom!==c){d=a[e]||(a[e]=new b());d.dom=c;g=d.getData(!0);if(g){g.isSynchronized=!1}}}}return d}});Ext.cmd.derive('Ext.dom.CompositeElementLite',Ext.Base,{alternateClassName:['Ext.CompositeElementLite'],isComposite:!0,isLite:!0,statics:{importElementMethods:function(){var b=Ext.dom.Element,a=this.prototype;Ext.Object.each(b.prototype,function(b,c){if(typeof c==='function'&&!a[b]){a[b]=function(){return this.invoke(b,arguments)}}})}},constructor:function(a,b){if(b){this.elements=a||[]}else {this.elements=[];this.add(a)}},getElement:function(b){var a=this._fly||(this._fly=new Ext.dom.Fly());return a.attach(b)},transformElement:function(a){return Ext.getDom(a)},getCount:function(){return this.elements.length},add:function(a,e){var d=this.elements,b,c;if(!a){return this}if(typeof a=='string'){a=Ext.fly(e||document).query(a)}else {if(a.isComposite){a=a.elements}else {if(!Ext.isIterable(a)){a=[a]}}}for(b=0,c=a.length;b-1){a=Ext.getDom(a);if(e){b=this.elements[c];b.parentNode.insertBefore(a,b);Ext.removeNode(b)}Ext.Array.splice(this.elements,c,1,a)}return this},clear:function(c){var d=this,b=d.elements,a=b.length-1;if(c){for(;a>=0;a--){Ext.removeNode(b[a])}}this.elements=[]},addElements:function(a,d){if(!a){return this}if(typeof a==='string'){a=Ext.dom.Element.selectorFunction(a,d)}var e=this.elements,c=a.length,b;for(b=0;b','','','',''].join(''),O=/(?:]*)?>)((\n|\r|.)*?)(?:<\/script>)/ig,J=/(?:)((\n|\r|.)*?)(?:<\/script>)/ig,G=/\ssrc=([\'\"])(.*?)\1/i,v=/\S/,E=/\stype=([\'\"])(.*?)\1/i,I=/^-ms-/,B=/(-[a-z])/gi,L=function(b,a){return a.charAt(1).toUpperCase()},r='x-masked',k='x-masked-relative',m='x-mask-msg',D=/^body/i,l={},u=function(d){var c=d.getData(),b=c[q];if(b===undefined){c[q]=b=a.VISIBILITY}return b},f=b.createRange?b.createRange():null,z={INPUT:!0,TEXTAREA:!0};if(Ext.isIE8){var p=b.createElement('div'),c=[],M=Ext.Function.createBuffered(function(){var b=c.length,a;for(a=0;a"+Ext.String.format(y,a)+''));b.selectNode('.'+a+'-mc').appendChild(this.dom);return b},clean:function(g){var c=this,d=c.dom,e=c.getData(),a=d.firstChild,f=-1,b;if(e.isCleaned&&g!==!0){return c}while(a){b=a.nextSibling;if(a.nodeType===3){if(!v.test(a.nodeValue)){d.removeChild(a)}else {if(b&&b.nodeType===3){a.appendData(Ext.String.trim(b.data));d.removeChild(b);b=a.nextSibling;a.nodeIndex=++f}}}else {Ext.fly(a,'_clean').clean();a.nodeIndex=++f}a=b}e.isCleaned=!0;return c},empty:f?function(){var a=this.dom;if(a.firstChild){f.setStartBefore(a.firstChild);f.setEndAfter(a.lastChild);f.deleteContents()}}:function(){var a=this.dom;while(a.lastChild){a.removeChild(a.lastChild)}},clearListeners:function(){this.removeAnchor();arguments.callee.$previous.call(this)},clearPositioning:function(a){a=a||'';return this.setStyle({left:a,right:a,top:a,bottom:a,'z-index':'',position:'static'})},createProxy:function(b,e,f){b=typeof b==='object'?b:{tag:'div',role:'presentation',cls:b};var d=this,c=e?Ext.DomHelper.append(e,b,!0):Ext.DomHelper.insertBefore(d.dom,b,!0);c.setVisibilityMode(a.DISPLAY);c.hide();if(f&&d.setBox&&d.getBox){c.setBox(d.getBox())}return c},clearOpacity:function(){return this.setOpacity('')},clip:function(){var a=this,c=a.getData(),b;if(!c[g]){c[g]=!0;b=a.getStyle([j,h,i]);c[n]={o:b[j],x:b[h],y:b[i]};a.setStyle(j,e);a.setStyle(h,e);a.setStyle(i,e)}return a},destroy:function(){var b=this,a=b.dom,f=b.getData(),e,d;if(a&&b.isAnimate){b.stopAnimation()}arguments.callee.$previous.call(this);if(a&&Ext.isIE8&&a.window!=a&&a.nodeType!==9&&a.tagName!=='BODY'&&a.tagName!=='HTML'){c[c.length]=a;M()}if(f){e=f.maskEl;d=f.maskMsg;if(e){e.destroy()}if(d){d.destroy()}}},enableDisplayMode:function(c){var b=this;b.setVisibilityMode(a.DISPLAY);if(c!==undefined){b.getData()[K]=c}return b},fadeIn:function(c){var a=this,b=a.dom;a.animate(Ext.apply({},c,{opacity:1,internalListeners:{beforeanimate:function(d){var a=Ext.fly(b,'_anim');if(a.isStyle('display','none')){a.setDisplayed('')}else {a.show()}}}}));return this},fadeOut:function(a){var b=this,c=b.dom;a=Ext.apply({opacity:0,internalListeners:{afteranimate:function(d){if(c&&d.to.opacity===0){var b=Ext.fly(c,'_anim');if(a.useDisplay){b.setDisplayed(!1)}else {b.hide()}}}}},a);b.animate(a);return b},fixDisplay:function(){var a=this;if(a.isStyle(d,s)){a.setStyle(o,e);a.setStyle(d,a._getDisplay());if(a.isStyle(d,s)){a.setStyle(d,'block')}}},frame:function(b,c,a){var d=this,f=d.dom,e;b=b||'#C3DAF9';c=c||1;a=a||{};e=function(){var g=Ext.fly(f,'_anim'),i=this,d,e,h;g.show();d=g.getBox();e=Ext.getBody().createChild({role:'presentation',id:g.dom.id+'-anim-proxy',style:{position:'absolute','pointer-events':'none','z-index':35000,border:'0px solid '+b}});h=new Ext.fx.Anim({target:e,duration:a.duration||1000,iterations:c,from:{top:d.y,left:d.x,borderWidth:0,opacity:1,height:d.height,width:d.width},to:{top:d.y-20,left:d.x-20,borderWidth:10,opacity:0,height:d.height+40,width:d.width+40}});h.on('afteranimate',function(){e.destroy();i.end()})};d.animate({duration:Math.max(a.duration,500)*2||2000,listeners:{beforeanimate:{fn:e}},callback:a.callback,scope:a.scope});return d},getColor:function(h,f,c){var a=this.getStyle(h),b=c||c===''?c:'#',d,g,e=0;if(!a||/transparent|inherit/.test(a)){return f}if(/^r/.test(a)){a=a.slice(4,a.length-1).split(',');g=a.length;for(;e5?b.toLowerCase():f},getLoader:function(){var c=this,b=c.getData(),a=b.loader;if(!a){b.loader=a=new Ext.ElementLoader({target:c})}return a},getPositioning:function(c){var a=this.getStyle(['left','top','position','z-index']),b=this.dom;if(c){if(a.left==='auto'){a.left=b.offsetLeft+'px'}if(a.top==='auto'){a.top=b.offsetTop+'px'}}return a},ghost:function(a,e){var b=this,d=b.dom,c;a=a||'b';c=function(){var h=Ext.fly(d,'_anim'),g=h.getWidth(),f=h.getHeight(),c=h.getXY(),i=h.getPositioning(),b={opacity:0};switch(a){case 't':b.y=c[1]-f;break;case 'l':b.x=c[0]-g;break;case 'r':b.x=c[0]+g;break;case 'b':b.y=c[1]+f;break;case 'tl':b.x=c[0]-g;b.y=c[1]-f;break;case 'bl':b.x=c[0]-g;b.y=c[1]+f;break;case 'br':b.x=c[0]+g;b.y=c[1]+f;break;case 'tr':b.x=c[0]+g;b.y=c[1]-f;break;}this.to=b;this.on('afteranimate',function(){var b=Ext.fly(d,'_anim');if(b){b.hide();b.clearOpacity();b.setPositioning(i)}})};b.animate(Ext.applyIf(e||{},{duration:500,easing:'ease-out',listeners:{beforeanimate:c}}));return b},hide:function(a){if(typeof a==='string'){this.setVisible(!1,a);return this}this.setVisible(!1,this.anim(a));return this},highlight:function(k,b){var g=this,e=g.dom,j={},i,h,c,d,a,f;b=b||{};d=b.listeners||{};c=b.attr||'backgroundColor';j[c]=k||'ffff9c';if(!b.to){h={};h[c]=b.endColor||g.getColor(c,'ffffff','')}else {h=b.to}b.listeners=Ext.apply(Ext.apply({},d),{beforeanimate:function(){i=e.style[c];var g=Ext.fly(e,'_anim');g.clearOpacity();g.show();a=d.beforeanimate;if(a){f=a.fn||a;return f.apply(a.scope||d.scope||t,arguments)}},afteranimate:function(){if(e){e.style[c]=i}a=d.afteranimate;if(a){f=a.fn||a;f.apply(a.scope||d.scope||t,arguments)}}});g.animate(Ext.apply({},b,{duration:1000,easing:'ease-in',from:j,to:h}));return g},hover:function(d,e,c,b){var a=this;a.on('mouseenter',d,c||a.dom,b);a.on('mouseleave',e,c||a.dom,b);return a},initDD:function(c,b,a){var d=new Ext.dd.DD(Ext.id(this.dom),c,b);return Ext.apply(d,a)},initDDProxy:function(c,b,a){var d=new Ext.dd.DDProxy(Ext.id(this.dom),c,b);return Ext.apply(d,a)},initDDTarget:function(c,b,a){var d=new Ext.dd.DDTarget(Ext.id(this.dom),c,b);return Ext.apply(d,a)},isFocusable:function(){var a=this.dom,b=!1,c;if(a&&!a.disabled){c=a.nodeName;b=!!Ext.Element.naturallyFocusableTags[c]||(c==='A'||c==='LINK')&&!!a.href||a.getAttribute('tabIndex')!=null||a.contentEditable==='true';if(Ext.isIE8&&c==='INPUT'&&a.type==='hidden'){b=!1}b=b&&this.isVisible(!0)}return b},isInputField:function(){var a=this.dom,b=a.contentEditable;if(z[a.tagName]&&a.type!=='button'||(b===''||b==='true')){return !0}return !1},isTabbable:function(f){var c=this.dom,a=!1,e,d,b;if(c&&!c.disabled){e=c.nodeName;b=c.getAttribute('tabIndex');d=b!=null;b-=0;if(e==='A'||e==='LINK'){if(c.href){a=d&&b<0?!1:!0}else {if(c.contentEditable==='true'){a=!d||d&&b>=0?!0:!1}else {a=d&&b>=0?!0:!1}}}else {if(c.contentEditable==='true'||Ext.Element.naturallyTabbableTags[e]){a=d&&b<0?!1:!0}else {if(d&&b>=0){a=!0}}}if(Ext.isIE8&&e==='INPUT'&&c.type==='hidden'){a=!1}a=a&&(f||(!this.component||this.component.isVisible(!0))&&this.isVisible(!0))}return a},isMasked:function(g){var b=this,f=b.getData(),e=f.maskEl,d=f.maskMsg,c=!1,a;if(e&&e.isVisible()){if(d){d.center(b)}c=!0}else {if(g){a=b.findParentNode();if(a){return Ext.fly(a).isMasked(g)}}}return c},load:function(a){this.getLoader().load(a);return this},mask:function(h,f,i){var c=this,d=c.dom,g=c.getData(),a=g.maskEl,e;if(!(D.test(d.tagName)&&c.getStyle('position')==='static')){c.addCls(k)}if(a){a.destroy()}a=Ext.DomHelper.append(d,{role:'presentation',cls:'x-mask x-border-box',children:{role:'presentation',cls:f?m+' '+f:m,cn:{tag:'div',role:'presentation',cls:'x-mask-msg-inner',cn:{tag:'div',role:'presentation',cls:'x-mask-msg-text',html:h||''}}}},!0);e=Ext.get(a.dom.firstChild);g.maskEl=a;c.addCls(r);a.setDisplayed(!0);if(typeof h==='string'){e.setDisplayed(!0);e.center(c)}else {e.setDisplayed(!1)}if(d===b.body){a.addCls('x-mask-fixed')}c.saveTabbableState({skipSelf:d===b.body});if(Ext.isIE9m&&d!==b.body&&c.isStyle('height','auto')){a.setSize(undefined,i||c.getHeight())}return a},monitorMouseLeave:function(e,d,f){var c=this,b,a={mouseleave:function(a){if(Ext.isIE9m){a.enableIEAsync()}b=Ext.defer(d,e,f||c,[a])},mouseenter:function(){clearTimeout(b)}};c.on(a);return a},puff:function(a){var c=this,e=c.dom,d,b=c.getBox(),f=c.getStyle(['width','height','left','right','top','bottom','position','z-index','font-size','opacity'],!0);a=Ext.applyIf(a||{},{easing:'ease-out',duration:500,useDisplay:!1});d=function(){var c=Ext.fly(e,'_anim');c.clearOpacity();c.show();this.to={width:b.width*2,height:b.height*2,x:b.x-b.width/2,y:b.y-b.height/2,opacity:0,fontSize:'200%'};this.on('afteranimate',function(){var b=Ext.fly(e,'_anim');if(b){if(a.useDisplay){b.setDisplayed(!1)}else {b.hide()}b.setStyle(f);Ext.callback(a.callback,a.scope)}})};c.animate({duration:a.duration,easing:a.easing,listeners:{beforeanimate:{fn:d}}});return c},selectable:function(){var b=this;b.dom.unselectable='';b.removeCls(a.unselectableCls);b.addCls(a.selectableCls);return b},setCapture:function(){var a=this.dom;if(Ext.isIE9m&&a.setCapture){a.setCapture()}},setHeight:function(c,a){var b=this;if(!a||!b.anim){arguments.callee.$previous.apply(this,arguments)}else {if(!Ext.isObject(a)){a={}}b.animate(Ext.applyIf({to:{height:c}},a))}return b},setHorizontal:function(){var a=this,b=a.verticalCls;delete a.vertical;if(b){delete a.verticalCls;a.removeCls(b)}delete a.setWidth;delete a.setHeight;if(!Ext.isIE8){delete a.getWidth;delete a.getHeight}delete a.styleHooks},updateText:function(d){var e=this,c,a;if(c){a=c.firstChild;if(!a||(a.nodeType!==3||a.nextSibling)){a=b.createTextNode();e.empty();c.appendChild(a)}if(d){a.data=d}}},setHtml:function(c,i,g,d){var a=this,f,e,h;if(!a.dom){return a}c=c||'';e=a.dom;if(i!==!0){e.innerHTML=c;Ext.callback(g,a);return a}f=Ext.id();c+='';h=Ext.interval(function(){var o,e,l,k,j,n,m;if(!(n=b.getElementById(f))){return !1}clearInterval(h);Ext.removeNode(n);o=Ext.getHead().dom;while(e=O.exec(c)){l=e[1];k=l?l.match(G):!1;if(k&&k[2]){m=b.createElement('script');m.src=k[2];j=l.match(E);if(j&&j[2]){m.type=j[2]}o.appendChild(m)}else {if(e[2]&&e[2].length>0){if(d){Ext.functionFactory(e[2]).call(d)}else {Ext.globalEval(e[2])}}}}Ext.callback(g,d||a)},20);e.innerHTML=c.replace(J,'');return a},setOpacity:function(c,b){var a=this;if(!a.dom){return a}if(!b||!a.anim){a.setStyle('opacity',c)}else {if(typeof b!='object'){b={duration:350,easing:'ease-in'}}a.animate(Ext.applyIf({to:{opacity:c}},b))}return a},setPositioning:function(a){return this.setStyle(a)},setVertical:function(e,d){var b=this,c=a.prototype;b.vertical=!0;if(d){b.addCls(b.verticalCls=d)}b.setWidth=c.setHeight;b.setHeight=c.setWidth;if(!Ext.isIE8){b.getWidth=c.getHeight;b.getHeight=c.getWidth}b.styleHooks=e===270?c.verticalStyleHooks270:c.verticalStyleHooks90},setSize:function(c,e,d){var b=this;if(Ext.isObject(c)){d=e;e=c.height;c=c.width}if(!d||!b.anim){b.dom.style.width=a.addUnits(c);b.dom.style.height=a.addUnits(e);if(b.shadow||b.shim){b.syncUnderlays()}}else {if(d===!0){d={}}b.animate(Ext.applyIf({to:{width:c,height:e}},d))}return b},setVisible:function(f,g){var b=this,h=b.dom,c=u(b);if(typeof g==='string'){switch(g){case d:c=a.DISPLAY;break;case o:c=a.VISIBILITY;break;case A:c=a.OFFSETS;break;case H:c=a.CLIP;break;}b.setVisibilityMode(c);g=!1}if(!g||!b.anim){if(c===a.DISPLAY){return b.setDisplayed(f)}else {if(c===a.OFFSETS){b[f?'removeCls':'addCls'](N)}else {if(c===a.CLIP){b[f?'removeCls':'addCls'](w)}else {if(c===a.VISIBILITY){b.fixDisplay();h.style.visibility=f?'':e}}}}}else {if(f){b.setOpacity(0.01);b.setVisible(!0)}if(!Ext.isObject(g)){g={duration:350,easing:'ease-in'}}b.animate(Ext.applyIf({callback:function(){if(!f){Ext.fly(h).setVisible(!1).setOpacity(1)}},to:{opacity:f?1:0}},g))}b.getData()[x]=f;if(b.shadow||b.shim){b.setUnderlaysVisible(f)}return b},setWidth:function(c,a){var b=this;if(!a||!b.anim){arguments.callee.$previous.apply(this,arguments)}else {if(!Ext.isObject(a)){a={}}b.animate(Ext.applyIf({to:{width:c}},a))}return b},setX:function(b,a){return this.setXY([b,this.getY()],a)},setXY:function(b,a){var c=this;if(!a||!c.anim){arguments.callee.$previous.call(this,b)}else {if(!Ext.isObject(a)){a={}}c.animate(Ext.applyIf({to:{x:b[0],y:b[1]}},a))}return this},setY:function(b,a){return this.setXY([this.getX(),b],a)},show:function(a){if(typeof a==='string'){this.setVisible(!0,a);return this}this.setVisible(!0,this.anim(a));return this},slideIn:function(a,c,d){var b=this,g=b.dom,h=g.style,j,e,f,i;a=a||'t';c=c||{};j=function(){var p=this,o=c.listeners,m=Ext.fly(g,'_anim'),j,n,l,k;if(!d){m.fixDisplay()}j=m.getBox();if((a=='t'||a=='b')&&j.height===0){j.height=g.scrollHeight}else {if((a=='l'||a=='r')&&j.width===0){j.width=g.scrollWidth}}n=m.getStyle(['width','height','left','right','top','bottom','position','z-index'],!0);m.setSize(j.width,j.height);if(c.preserveScroll){f=m.cacheScrollValues()}k=m.wrap({role:'presentation',id:Ext.id()+'-anim-wrap-for-'+m.dom.id,style:{visibility:d?'visible':'hidden'}});i=k.dom.parentNode;k.setPositioning(m.getPositioning());if(k.isStyle('position','static')){k.position('relative')}m.clearPositioning('auto');k.clip();if(f){f()}m.setStyle({visibility:'',position:'absolute'});if(d){k.setSize(j.width,j.height)}switch(a){case 't':l={from:{width:j.width+'px',height:'0px'},to:{width:j.width+'px',height:j.height+'px'}};h.bottom='0px';break;case 'l':l={from:{width:'0px',height:j.height+'px'},to:{width:j.width+'px',height:j.height+'px'}};b.anchorAnimX(a);break;case 'r':l={from:{x:j.x+j.width,width:'0px',height:j.height+'px'},to:{x:j.x,width:j.width+'px',height:j.height+'px'}};b.anchorAnimX(a);break;case 'b':l={from:{y:j.y+j.height,width:j.width+'px',height:'0px'},to:{y:j.y,width:j.width+'px',height:j.height+'px'}};break;case 'tl':l={from:{x:j.x,y:j.y,width:'0px',height:'0px'},to:{width:j.width+'px',height:j.height+'px'}};h.bottom='0px';b.anchorAnimX('l');break;case 'bl':l={from:{y:j.y+j.height,width:'0px',height:'0px'},to:{y:j.y,width:j.width+'px',height:j.height+'px'}};b.anchorAnimX('l');break;case 'br':l={from:{x:j.x+j.width,y:j.y+j.height,width:'0px',height:'0px'},to:{x:j.x,y:j.y,width:j.width+'px',height:j.height+'px'}};b.anchorAnimX('r');break;case 'tr':l={from:{x:j.x+j.width,width:'0px',height:'0px'},to:{x:j.x,width:j.width+'px',height:j.height+'px'}};h.bottom='0px';b.anchorAnimX('r');break;}k.show();e=Ext.apply({},c);delete e.listeners;e=new Ext.fx.Anim(Ext.applyIf(e,{target:k,duration:500,easing:'ease-out',from:d?l.to:l.from,to:d?l.from:l.to}));e.on('afteranimate',function(){var b=Ext.fly(g,'_anim');b.setStyle(n);if(d){if(c.useDisplay){b.setDisplayed(!1)}else {b.hide()}}if(k.dom){if(k.dom.parentNode){k.dom.parentNode.insertBefore(b.dom,k.dom)}else {i.appendChild(b.dom)}k.destroy()}if(f){f()}p.end()});if(o){e.on(o)}};b.animate({duration:c.duration?Math.max(c.duration,500)*2:1000,listeners:{beforeanimate:j}});return b},slideOut:function(a,b){return this.slideIn(a,b,!0)},swallowEvent:function(a,f){var b=this,c,d,e=function(b){b.stopPropagation();if(f){b.preventDefault()}};if(Ext.isArray(a)){d=a.length;for(c=0;c0){a.setAttribute(e,++f)}else {if(a.hasAttribute('tabIndex')){a.setAttribute(g,a.getAttribute('tabIndex'))}else {a.setAttribute(g,'none')}a.setAttribute('tabIndex','-1');a.setAttribute(e,'1')}}return c},restoreTabbableState:function(k,j){var g=this.dom,c=Ext.Element.tabbableSavedCounterAttribute,e=Ext.Element.tabbableSavedValueAttribute,b=[],h,f,b,a,d,i;if(!g){return this}if(!j){b=Ext.Array.from(g.querySelectorAll('['+c+']'))}if(!k){b.unshift(g)}for(d=0,i=b.length;d1){a.setAttribute(c,--f);continue}h=a.getAttribute(e);if(h==='none'){a.removeAttribute('tabIndex')}else {a.setAttribute('tabIndex',h)}a.removeAttribute(e);a.removeAttribute(c)}return b}},deprecated:{'4.0':{methods:{pause:function(b){var a=this;Ext.fx.Manager.setFxDefaults(a.id,{delay:b});return a},scale:function(c,a,b){this.animate(Ext.apply({},b,{width:c,height:a}));return this},shift:function(a){this.animate(a);return this}}},'4.2':{methods:{moveTo:function(b,c,a){return this.setXY([b,c],a)},setBounds:function(d,e,c,b,a){return this.setBox({x:d,y:e,width:c,height:b},a)},setLeftTop:function(d,e){var b=this,c=b.dom.style;c.left=a.addUnits(d);c.top=a.addUnits(e);if(b.shadow||b.shim){b.syncUnderlays()}return b},setLocation:function(b,c,a){return this.setXY([b,c],a)}}},'5.0':{methods:{getAttributeNS:function(a,b){return this.getAttribute(b,a)},getCenterXY:function(){return this.getAlignToXY(b,'c-c')},getComputedHeight:function(){return Math.max(this.dom.offsetHeight,this.dom.clientHeight)||parseFloat(this.getStyle(C))||0},getComputedWidth:function(){return Math.max(this.dom.offsetWidth,this.dom.clientWidth)||parseFloat(this.getStyle(F))||0},getStyleSize:function(){var d=this,e=this.dom,h=e===b||e===b.body,c,g,f;if(h){return {width:a.getViewportWidth(),height:a.getViewportHeight()}}c=d.getStyle(['height','width'],!0);if(c.width&&c.width!=='auto'){g=parseFloat(c.width)}if(c.height&&c.height!=='auto'){f=parseFloat(c.height)}return {width:g||d.getWidth(!0),height:f||d.getHeight(!0)}},isBorderBox:function(){return !0},isDisplayed:function(){return !this.isStyle('display','none')},focusable:'isFocusable'}}}}}(),function(){var g=Ext.dom.Element,a=g.prototype,t=!Ext.isIE8,f=document,q=f.defaultView,p=/alpha\(opacity=(.*)\)/i,w=/^\s+|\s+$/g,d=a.styleHooks,e=Ext.supports,c,b,l,m,i,j,n;a._init(g);delete a._init;Ext.plainTableCls='x-table-plain';Ext.plainListCls='x-list-plain';if(Ext.CompositeElementLite){Ext.CompositeElementLite.importElementMethods()}if(!e.Opacity&&Ext.isIE){Ext.apply(d.opacity,{get:function(d){var c=d.style.filter,b,a;if(c.match){b=c.match(p);if(b){a=parseFloat(b[1]);if(!isNaN(a)){return a?a/100:0}}}return 1},set:function(d,a){var b=d.style,c=b.filter.replace(p,'').replace(w,'');b.zoom=1;if(typeof a==='number'&&a>=0&&a<1){a*=100;b.filter=c+(c.length?' ':'')+'alpha(opacity='+a+')'}else {b.filter=c}}})}if(!e.matchesSelector){var r=/^([a-z]+|\*)?(?:\.([a-z][a-z\-_0-9]*))?$/i,v=/\-/g,h,s=function(a,c){var b=new RegExp('(?:^|\\s+)'+c.replace(v,'\\-')+'(?:\\s+|$)');if(a&&a!=='*'){a=a.toUpperCase();return function(d){return d.tagName===a&&b.test(d.className)}}return function(d){return b.test(d.className)}},u=function(a){a=a.toUpperCase();return function(b){return b.tagName===a}},k={};a.matcherCache=k;a.is=function(a){if(!a){return !0}var b=this.dom,g,e,d,c,j,l,i;if(b.nodeType!==1){return !1}if(!(d=Ext.isFunction(a)?a:k[a])){if(!(e=a.match(r))){c=b.parentNode;if(!c){j=!0;c=h||(h=f.createDocumentFragment());h.appendChild(b)}l=Ext.Array.indexOf(Ext.fly(c,'_is').query(a),b)!==-1;if(j){h.removeChild(b)}return l}i=e[1];g=e[2];k[a]=d=g?s(i,g):u(i)}return d(b)}}if(!q||!q.getComputedStyle){a.getStyle=function(o,p){var j=this,e=j.dom,n=typeof o!=='string',a=o,i=a,r=1,m=p,l=j.styleHooks,q,h,d,c,f,b,k;if(n){d={};a=i[0];k=0;if(!(r=i.length)){return d}}if(!e||e.documentElement){return d||''}h=e.style;if(p){b=h}else {b=e.currentStyle;if(!b){m=!0;b=h}}do{c=l[a];if(!c){l[a]=c={name:g.normalize(a)}}if(c.get){f=c.get(e,j,m,b)}else {q=c.name;f=b[q]}if(!n){return f}d[a]=f;a=i[++k]}while(k=9)){a.getAttribute=function(a,c){var d=this.dom,b;if(c){b=typeof d[c+':'+a];if(b!=='undefined'&&b!=='unknown'){return d[c+':'+a]||null}return null}if(a==='for'){a='htmlFor'}return d[a]||null}}Ext.onInternalReady(function(){var o=/^(?:transparent|(?:rgba[(](?:\s*\d+\s*[,]){3}\s*0\s*[)]))$/i,h=[],p=a.setWidth,n=a.setHeight,m=a.setSize,q=/^\d+(?:\.\d*)?px$/i,i,l,k,j;if(e.FixedTableWidthBug){d.width={name:'width',set:function(c,e,f){var a=c.style,b=f._needsTableWidthFix,d=a.display;if(b){a.display='none'}a.width=e;if(b){c.scrollWidth;a.display=d}}};a.setWidth=function(g,b){var a=this,e=a.dom,c=e.style,d=a._needsTableWidthFix,f=c.display;if(d&&!b){c.display='none'}p.call(a,g,b);if(d&&!b){e.scrollWidth;c.display=f}return a};a.setSize=function(h,g,b){var a=this,e=a.dom,c=e.style,d=a._needsTableWidthFix,f=c.display;if(d&&!b){c.display='none'}m.call(a,h,g,b);if(d&&!b){e.scrollWidth;c.display=f}return a}}if(Ext.isIE8){d.height={name:'height',set:function(f,b,e){var a=e.component,d,c;if(a&&a._syncFrameHeight&&e===a.el){c=a.frameBody.dom.style;if(q.test(b)){d=a.getFrameInfo();if(d){c.height=parseInt(b,10)-d.height+'px'}}else {if(!b||b==='auto'){c.height=''}}}f.style.height=b}};a.setHeight=function(b,e){var a=this.component,d,c;if(a&&a._syncFrameHeight&&this===a.el){c=a.frameBody.dom.style;if(!b||b==='auto'){c.height=''}else {d=a.getFrameInfo();if(d){c.height=b-d.height+'px'}}}return n.call(this,b,e)};a.setSize=function(f,b,e){var a=this.component,d,c;if(a&&a._syncFrameHeight&&this===a.el){c=a.frameBody.dom.style;if(!b||b==='auto'){c.height=''}else {d=a.getFrameInfo();if(d){c.height=b-d.height+'px'}}}return m.call(this,f,b,e)}}Ext.getDoc().on('selectstart',function(h,a){var e=g.selectableCls,d=g.unselectableCls,b=a&&a.tagName;b=b&&b.toLowerCase();if(b==='input'||b==='textarea'){return}while(a&&a.nodeType===1&&a!==f.documentElement){var c=Ext.fly(a);if(c.hasCls(e)){return}if(c.hasCls(d)){h.stopEvent();return}a=a.parentNode}});function fixTransparent(d,e,c,b){var a=b[this.name]||'';return o.test(a)?'transparent':a}function makeSelectionRestoreFn(a,b,c){return function(){a.selectionStart=b;a.selectionEnd=c}}function getRightMarginFixCleaner(i){var h=e.DisplayChangeInputSelectionBug,f=e.DisplayChangeTextAreaSelectionBug,a,d,b,c;if(h||f){a=g.getActiveElement();d=a&&a.tagName;if(f&&d==='TEXTAREA'||h&&d==='INPUT'&&a.type==='text'){if(Ext.fly(i).isAncestor(a)){b=a.selectionStart;c=a.selectionEnd;if(Ext.isNumber(b)&&Ext.isNumber(c)){return makeSelectionRestoreFn(a,b,c)}}}}return Ext.emptyFn}function fixRightMargin(c,g,f,e){var b=e.marginRight,a,d;if(b!=='0px'){a=c.style;d=a.display;a.display='inline-block';b=(f?e:c.ownerDocument.defaultView.getComputedStyle(c,null)).marginRight;a.display=d}return b}function fixRightMarginAndInputFocus(b,h,g,f){var c=f.marginRight,a,d,e;if(c!=='0px'){a=b.style;d=getRightMarginFixCleaner(b);e=a.display;a.display='inline-block';c=(g?f:b.ownerDocument.defaultView.getComputedStyle(b,'')).marginRight;a.display=e;d()}return c}if(!e.RightMargin){d.marginRight=d['margin-right']={name:'marginRight',get:e.DisplayChangeInputSelectionBug||e.DisplayChangeTextAreaSelectionBug?fixRightMarginAndInputFocus:fixRightMargin}}if(!e.TransparentColor){i=['background-color','border-color','color','outline-color'];for(l=i.length;l--;){k=i[l];j=g.normalize(k);d[k]=d[j]={name:j,get:fixTransparent}}}a.verticalStyleHooks90=c=Ext.Object.chain(d);a.verticalStyleHooks270=b=Ext.Object.chain(d);c.width=d.height||{name:'height'};c.height=d.width||{name:'width'};c['margin-top']={name:'marginLeft'};c['margin-right']={name:'marginTop'};c['margin-bottom']={name:'marginRight'};c['margin-left']={name:'marginBottom'};c['padding-top']={name:'paddingLeft'};c['padding-right']={name:'paddingTop'};c['padding-bottom']={name:'paddingRight'};c['padding-left']={name:'paddingBottom'};c['border-top']={name:'borderLeft'};c['border-right']={name:'borderTop'};c['border-bottom']={name:'borderRight'};c['border-left']={name:'borderBottom'};b.width=d.height||{name:'height'};b.height=d.width||{name:'width'};b['margin-top']={name:'marginRight'};b['margin-right']={name:'marginBottom'};b['margin-bottom']={name:'marginLeft'};b['margin-left']={name:'marginTop'};b['padding-top']={name:'paddingRight'};b['padding-right']={name:'paddingBottom'};b['padding-bottom']={name:'paddingLeft'};b['padding-left']={name:'paddingTop'};b['border-top']={name:'borderRight'};b['border-right']={name:'borderBottom'};b['border-bottom']={name:'borderLeft'};b['border-left']={name:'borderTop'};if(!Ext.scopeCss){h.push('x-body')}if(e.Touch){h.push('x-touch')}if(Ext.isIE&&Ext.isIE9m){h.push('x-ie','x-ie9m');h.push('x-ie8p');if(Ext.isIE8){h.push('x-ie8')}else {h.push('x-ie9','x-ie9p')}if(Ext.isIE8m){h.push('x-ie8m')}}if(Ext.isIE10){h.push('x-ie10')}if(Ext.isIE10p){h.push('x-ie10p')}if(Ext.isIE11){h.push('x-ie11')}if(Ext.isGecko){h.push('x-gecko')}if(Ext.isOpera){h.push('x-opera')}if(Ext.isOpera12m){h.push('x-opera12m')}if(Ext.isWebKit){h.push('x-webkit')}if(Ext.isSafari){h.push('x-safari')}if(Ext.isChrome){h.push('x-chrome')}if(Ext.isMac){h.push('x-mac')}if(Ext.isLinux){h.push('x-linux')}if(!e.CSS3BorderRadius){h.push('x-nbr')}if(!e.CSS3LinearGradient){h.push('x-nlg')}if(e.Touch){h.push('x-touch')}Ext.getBody().addCls(h)},null,{priority:1500})});Ext.cmd.derive('Ext.GlobalEvents',Ext.mixin.Observable,{alternateClassName:'Ext.globalEvents',observableType:'global',singleton:!0,resizeBuffer:100,idleEventMask:{mousemove:1,touchmove:1,pointermove:1,MSPointerMove:1,unload:1},constructor:function(){var a=this;a.callParent();Ext.onInternalReady(function(){a.attachListeners()})},attachListeners:function(){Ext.get(window).on('resize',this.fireResize,this,{buffer:this.resizeBuffer});Ext.getDoc().on('mousedown',this.fireMouseDown,this)},fireMouseDown:function(a){this.fireEvent('mousedown',a)},fireResize:function(){var a=this,d=Ext.Element,c=d.getViewportWidth(),b=d.getViewportHeight();if(a.curHeight!==b||a.curWidth!==c){a.curHeight=b;a.curWidth=c;a.fireEvent('resize',c,b)}}},1,0,0,0,0,0,[Ext,'GlobalEvents',Ext,'globalEvents'],function(a){Ext.on=function(){return a.addListener.apply(a,arguments)};Ext.un=function(){return a.removeListener.apply(a,arguments)}});Ext.define('Ext.overrides.GlobalEvents',{override:'Ext.GlobalEvents',deprecated:{5:{methods:{addListener:function(a,d,i,f,h,g,e){var c,b;if(a==='ready'){b=d}else {if(typeof a!=='string'){for(c in a){if(c==='ready'){b=a[c]}}}}if(b){Ext.onReady(b)}this.callParent([a,d,i,f,h,g,e])}}}}});Ext.USE_NATIVE_JSON=!1;Ext.JSON=new function(){var me=this,hasNative=window.JSON&&JSON.toString()==='[object JSON]',useHasOwn=!!{}.hasOwnProperty,pad=function(a){return a<10?'0'+a:a},doDecode=function(json){return eval('('+json+')')},doEncode=function(a,b){if(a===null||a===undefined){return 'null'}else {if(Ext.isDate(a)){return me.encodeDate(a)}else {if(Ext.isString(a)){if(Ext.isMSDate(a)){return me.encodeMSDate(a)}else {return me.encodeString(a)}}else {if(typeof a==='number'){return isFinite(a)?String(a):'null'}else {if(Ext.isBoolean(a)){return String(a)}else {if(a.toJSON){return a.toJSON()}else {if(Ext.isArray(a)){return encodeArray(a,b)}else {if(Ext.isObject(a)){return encodeObject(a,b)}else {if(typeof a==='function'){return 'null'}}}}}}}}}return 'undefined'},m={'\b':'\\b','\t':'\\t','\n':'\\n','\f':'\\f','\r':'\\r','"':'\\"','\\':'\\\\','\v':'\\u000b'},charToReplace=/[\\\"\x00-\x1f\x7f-\uffff]/g,encodeString=function(a){return '"'+a.replace(charToReplace,function(b){var c=m[b];return typeof c==='string'?c:'\\u'+('0000'+b.charCodeAt(0).toString(16)).slice(-4)})+'"'},encodeMSDate=function(a){return '"'+a+'"'},encodeArrayPretty=function(e,d){var f=e.length,c=d+' ',g=','+c,a=['[',c],b;for(b=0;b0}}return c},onBindNotify:function(b,c,a){a.syncing=a.syncing+1||1;this[a._config.names.set](b);--a.syncing},removeBindings:function(){var c=this,a,d,b;if(!c.destroying){a=c.getBind();if(a&&typeof a!=='string'){for(d in a){b=a[d];b.destroy();b._config=b.getTemplateScope=null}}}c.setBind(null)},updateSession:function(a){var b=this.getInherited();if(a){b.session=a}else {delete b.session}},updateViewModel:function(a){var c=this.getInherited(),b=this.getController();if(a){c.viewModel=a;a.setView(this);if(b){b.initViewModel(a)}}else {delete c.viewModel}}}},0,0,0,0,0,0,[Ext.mixin,'Bindable'],0);Ext.cmd.derive('Ext.mixin.ComponentDelegation',Ext.Mixin,{mixinConfig:{id:'componentDelegation'},privates:{addDelegatedListener:function(c,k,j,a,d,i,h){var b=this,e,g,f;d=d||a.order;if(d){f=a&&a.priority;if(!f){a=a?Ext.Object.chain(a):{};a.priority=b.$orderToPriority[d]}}e=b.$delegatedEvents||(b.$delegatedEvents={});g=e[c]||(e[c]=new Ext.util.Event(b,c));if(g.addListener(k,j,a,i,h)){b.$hasDelegatedListeners._incr_(c)}},clearDelegatedListeners:function(){var e=this,a=e.$delegatedEvents,b,c,d;if(a){for(b in a){c=a[b];d=c.listeners.length;c.clearListeners();e.$hasDelegatedListeners._decr_(b,d);delete a[b]}}},doFireDelegatedEvent:function(f,g){var e=this,d=!0,a,b,c;if(e.$hasDelegatedListeners[f]){a=e.getRefOwner();while(a){b=a.$delegatedEvents;if(b){c=b[f];if(c){d=c.fireDelegated(e,g);if(d===!1){break}}}a=a.getRefOwner()}}return d},removeDelegatedListener:function(c,f,e){var d=this,b=d.$delegatedEvents,a;if(b){a=b[c];if(a&&a.removeListener(f,e)){d.$hasDelegatedListeners._decr_(c);if(a.listeners.length===0){delete b[c]}}}}},onClassMixedIn:function(a){function HasListeners(){}a.prototype.HasListeners=a.HasListeners=HasListeners;HasListeners.prototype=a.hasListeners=new Ext.mixin.ComponentDelegation.HasDelegatedListeners()}},0,0,0,0,0,0,[Ext.mixin,'ComponentDelegation'],function(a){function HasDelegatedListeners(){}a.HasDelegatedListeners=HasDelegatedListeners;HasDelegatedListeners.prototype=a.prototype.$hasDelegatedListeners=new Ext.mixin.Observable.HasListeners()});Ext.cmd.derive('Ext.Widget',Ext.Evented,{isWidget:!0,element:{reference:'element'},observableType:'component',cachedConfig:{style:null},config:{userCls:null},eventedConfig:{width:null,height:null},template:[],constructor:function(c){var a=this,b;a.initId(c);a.initElement();a.mixins.observable.constructor.call(a,c);Ext.ComponentManager.register(a);b=a.getController();if(b){b.init(a)}},afterCachedConfig:function(){var c=this,j=c.self.prototype,f=c.referenceList,i=c.renderElement,d,h,a,b,g,e;j.renderTemplate=d=document.createDocumentFragment();d.appendChild(i.clone(!0,!0));e=d.querySelectorAll('[id]');for(a=0,b=e.length;a]+>/gi,stripScriptsRe:/(?:)((\n|\r|.)*?)(?:<\/script>)/ig,nl2brRe:/\r?\n/g,hashRe:/#+$/,allHashes:/^#+$/,formatPattern:/[\d,\.#]+/,formatCleanRe:/[^\d\.#]/g,I18NFormatCleanRe:null,formatFns:{},constructor:function(){a=this},undef:function(a){return a!==undefined?a:''},defaultValue:function(a,b){return a!==undefined&&a!==''?a:b},substr:'ab'.substr(-1)!='b'?function(d,a,c){var b=String(d);return a<0?b.substr(Math.max(b.length+a,0),c):b.substr(a,c)}:function(c,b,a){return String(c).substr(b,a)},lowercase:function(a){return String(a).toLowerCase()},uppercase:function(a){return String(a).toUpperCase()},usMoney:function(b){return a.currency(b,'$',2)},currency:function(b,f,c,h){var d='',e=',0',g=0;b=b-0;if(b<0){b=-b;d='-'}c=Ext.isDefined(c)?c:a.currencyPrecision;e+=c>0?'.':'';for(;gb){a=a.substring(a.length-b)}}while(a.length2){}else {if(e.length===2){d=e[1].length;f=e[1].match(a.hashRe);if(f){m=f[0].length;l='trailingZeroes=new RegExp(Ext.String.escapeRegex(utilFormat.decimalSeparator) + "*0{0,'+m+'}$")'}}}b=['var utilFormat=Ext.util.Format,extNumber=Ext.Number,neg,absVal,fnum,parts'+(h?',thousandSeparator,thousands=[],j,n,i':'')+(i?',formatString="'+c+'",formatPattern=/[\\d,\\.#]+/':'')+',trailingZeroes;return function(v){if(typeof v!=="number"&&isNaN(v=extNumber.from(v,NaN)))return"";neg=v<0;','absVal=Math.abs(v);','fnum=Ext.Number.toFixed(absVal, '+d+');',l,';'];if(h){if(d){b[b.length]='parts=fnum.split(".");';b[b.length]='fnum=parts[0];'}b[b.length]='if(absVal>=1000) {';b[b.length]='thousandSeparator=utilFormat.thousandSeparator;thousands.length=0;j=fnum.length;n=fnum.length%3||3;for(i=0;i')},capitalize:Ext.String.capitalize,uncapitalize:Ext.String.uncapitalize,ellipsis:Ext.String.ellipsis,escape:Ext.String.escape,escapeRegex:Ext.String.escapeRegex,htmlDecode:Ext.String.htmlDecode,htmlEncode:Ext.String.htmlEncode,leftPad:Ext.String.leftPad,toggle:Ext.String.toggle,trim:Ext.String.trim,parseBox:function(b){b=b||0;if(typeof b==='number'){return {top:b,right:b,bottom:b,left:b}}var a=b.split(' '),c=a.length;if(c===1){a[1]=a[2]=a[3]=a[0]}else {if(c===2){a[2]=a[0];a[3]=a[1]}else {if(c===3){a[3]=a[1]}}}return {top:parseInt(a[0],10)||0,right:parseInt(a[1],10)||0,bottom:parseInt(a[2],10)||0,left:parseInt(a[3],10)||0}}}},1,0,0,0,0,0,[Ext.util,'Format'],0);Ext.cmd.derive('Ext.Template',Ext.Base,{inheritableStatics:{from:function(a,b){a=Ext.getDom(a);return new this(a.value||a.innerHTML,b||'')}},useEval:Ext.isGecko,constructor:function(g){var d=this,c=arguments,f=[],e,b=c.length,a;d.initialConfig={};if(b===1&&Ext.isArray(g)){c=g;b=c.length}if(b>1){for(e=0;e]*)\>)|(?:<\/tpl>)/g,actionsRe:/\s*(elif|elseif|if|for|foreach|exec|switch|case|eval|between)\s*\=\s*(?:(?:"([^"]*)")|(?:'([^']*)'))\s*/g,propRe:/prop=(?:(?:"([^"]*)")|(?:'([^']*)'))/,defaultRe:/^\s*default\s*$/,elseRe:/^\s*else\s*$/},1,0,0,0,0,0,[Ext.util,'XTemplateParser'],0);Ext.cmd.derive('Ext.util.XTemplateCompiler',Ext.util.XTemplateParser,{useEval:Ext.isGecko,useIndex:Ext.isIE8m,useFormat:!0,propNameRe:/^[\w\d\$]*$/,compile:function(c){var a=this,b=a.generate(c);return a.useEval?a.evalTpl(b):(new Function('Ext',b))(Ext)},generate:function(d){var a=this,b='var fm=Ext.util.Format,ts=Object.prototype.toString;',c;a.maxLevel=0;a.body=['var c0=values, a0='+a.createArrayTest(0)+', p0=parent, n0=xcount, i0=xindex, k0, v;\n'];if(a.definitions){if(typeof a.definitions==='string'){a.definitions=[a.definitions,b]}else {a.definitions.push(b)}}else {a.definitions=[b]}a.switches=[];a.parse(d);a.definitions.push((a.useEval?'$=':'return')+' function ('+a.fnArgs+') {',a.body.join(''),'}');c=a.definitions.join('\n');a.definitions.length=a.body.length=a.switches.length=0;delete a.definitions;delete a.body;delete a.switches;return c},doText:function(a){var b=this,c=b.body;a=a.replace(b.aposRe,"\\'").replace(b.newLineRe,'\\n');if(b.useIndex){c.push("out[out.length]='",a,"'\n")}else {c.push("out.push('",a,"')\n")}},doExpr:function(b){var a=this.body;a.push('if ((v='+b+') != null) out');if(this.useIndex){a.push("[out.length]=v+''\n")}else {a.push(".push(v+'')\n")}},doTag:function(b){var a=this.parseTag(b);if(a){this.doExpr(a)}else {this.doText('{'+b+'}')}},doElse:function(){this.body.push('} else {\n')},doEval:function(a){this.body.push(a,'\n')},doIf:function(b,c){var a=this;if(b==='.'){a.body.push('if (values) {\n')}else {if(a.propNameRe.test(b)){a.body.push('if (',a.parseTag(b),') {\n')}else {a.body.push('if (',a.addFn(b),a.callFn,') {\n')}}if(c.exec){a.doExec(c.exec)}},doElseIf:function(b,c){var a=this;if(b==='.'){a.body.push('else if (values) {\n')}else {if(a.propNameRe.test(b)){a.body.push('} else if (',a.parseTag(b),') {\n')}else {a.body.push('} else if (',a.addFn(b),a.callFn,') {\n')}}if(c.exec){a.doExec(c.exec)}},doSwitch:function(b){var a=this,c;if(b==='.'||b==='#'){c=b==='.'?'values':'xindex';a.body.push('switch (',c,') {\n')}else {if(a.propNameRe.test(b)){a.body.push('switch (',a.parseTag(b),') {\n')}else {a.body.push('switch (',a.addFn(b),a.callFn,') {\n')}}a.switches.push(0)},doCase:function(e){var a=this,c=Ext.isArray(e)?e:[e],d=a.switches.length-1,f,b;if(a.switches[d]){a.body.push('break;\n')}else {a.switches[d]++}for(b=0,d=c.length;b1){ out.push("',d.between,'"); } \n')}},doForEach:function(c,d){var b=this,f,a=b.level,e=a-1,g;if(c==='.'){f='values'}else {if(b.propNameRe.test(c)){f=b.parseTag(c)}else {f=b.addFn(c)+b.callFn}}if(b.maxLevel1){ out.push("',d.between,'"); } \n')}},createArrayTest:'isArray' in Array?function(a){return 'Array.isArray(c'+a+')'}:function(a){return 'ts.call(c'+a+')==="[object Array]"'},doExec:function(d,e){var a=this,c='f'+a.definitions.length,b=a.guards[a.strict?0:1];a.definitions.push('function '+c+'('+a.fnArgs+') {',b.doTry,' var $v = values; with($v) {',' '+d,' }',b.doCatch,'}');a.body.push(c+a.callFn+'\n')},guards:[{doTry:'',doCatch:''},{doTry:'try { ',doCatch:' } catch(e) {\n}'}],addFn:function(c){var a=this,b='f'+a.definitions.length,d=a.guards[a.strict?0:1];if(c==='.'){a.definitions.push('function '+b+'('+a.fnArgs+') {',' return values','}')}else {if(c==='..'){a.definitions.push('function '+b+'('+a.fnArgs+') {',' return parent','}')}else {a.definitions.push('function '+b+'('+a.fnArgs+') {',d.doTry,' var $v = values; with($v) {',' return('+c+')',' }',d.doCatch,'}')}}return b},parseTag:function(h){var e=this,f=e.tagRe.exec(h),a,c,d,g,b;if(!f){return null}a=f[1];c=f[2];d=f[3];g=f[4];if(a=='.'){if(!e.validTypes){e.definitions.push('var validTypes={string:1,number:1,boolean:1};');e.validTypes=!0}b='validTypes[typeof values] || ts.call(values) === "[object Date]" ? values : ""'}else {if(a=='#'){b='xindex'}else {if(a=='$'){b='xkey'}else {if(a.substr(0,7)=='parent.'){b=a}else {if(isNaN(a)&&a.indexOf('-')==-1&&a.indexOf('.')!=-1){b='values.'+a}else {b="values['"+a+"']"}}}}}if(g){b='('+b+g+')'}if(c&&e.useFormat){d=d?','+d:'';if(c.substr(0,5)!='this.'){c='fm.'+c+'('}else {c+='('}}else {return b}return c+b+d+')'},evalTpl:function($){eval($);return $},newLineRe:/\r\n|\r|\n/g,aposRe:/[']/g,intRe:/^\s*(\d+)\s*$/,tagRe:/^([\w-\.\#\$]+)(?:\:([\w\.]*)(?:\((.*?)?\))?)?(\s?[\+\-\*\/]\s?[\d\.\+\-\*\/\(\)]+)?$/},0,0,0,0,0,0,[Ext.util,'XTemplateCompiler'],function(){var a=this.prototype;a.fnArgs='out,values,parent,xindex,xcount,xkey';a.callFn='.call(this,'+a.fnArgs+')'});Ext.cmd.derive('Ext.XTemplate',Ext.Template,{isXTemplate:!0,emptyObj:{},fn:null,strict:!1,apply:function(b,a,d,c){return this.applyOut(b,[],a,d,c).join('')},applyOut:function(g,d,f,c,b){var a=this,e;if(!a.fn){e=new Ext.util.XTemplateCompiler({useFormat:a.disableFormats!==!0,definitions:a.definitions,strict:a.strict});a.fn=e.compile(a.html)}c=c||1;b=b||1;if(a.strict){a.fn(d,g,f||a.emptyObj,c,b)}else {try{a.fn(d,g,f||a.emptyObj,c,b)}catch(h){}}return d},compile:function(){return this},statics:{getTpl:function(c,d){var b=c[d],a;if(b&&!b.isTemplate){b=Ext.ClassManager.dynInstantiate('Ext.XTemplate',b);if(c.hasOwnProperty(d)){a=c}else {for(a=c.self.prototype;a&&!a.hasOwnProperty(d);a=a.superclass){}}a[d]=b;b.owner=a}return b||null}}},0,0,0,0,0,0,[Ext,'XTemplate'],0);Ext.cmd.derive('Ext.app.EventDomain',Ext.Base,{statics:{instances:{}},isEventDomain:!0,isInstance:!1,constructor:function(){var a=this;if(!a.isInstance){Ext.app.EventDomain.instances[a.type]=a}a.bus={};a.monitoredClasses=[]},dispatch:function(l,h,m){h=Ext.canonicalEventName(h);var j=this,n=j.bus,b=n[h],c,a,i,g,e,k,d,f;if(!b){return !0}for(c in b){if(b.hasOwnProperty(c)&&j.match(l,c,j.controller)){a=b[c];for(i in a){if(a.hasOwnProperty(i)){g=a[i];if(g.controller.isActive()){e=g.list;k=e.length;for(d=0;da.clientWidth}}if(e==='scroll'){h=!0}else {if(e){h=a.scrollHeight>a.clientHeight}}if(g){i=f.height}if(h){j=f.width}}}return {width:j,height:i}},getPosition:function(){return this.position},updateDirectionLock:Ext.emptyFn,updateDisabled:Ext.emptyFn,updateIndicators:Ext.emptyFn,updateMaxPosition:Ext.emptyFn,updateMaxUserPosition:Ext.emptyFn,updateMinPosition:Ext.emptyFn,updateMinUserPosition:Ext.emptyFn,updateMomenumEasing:Ext.emptyFn,updateX:Ext.emptyFn,updateY:Ext.emptyFn,onPartnerScrollStart:Ext.emptyFn,onPartnerScrollEnd:Ext.emptyFn,refresh:function(){this.fireEvent('refresh',this);return this},removePartner:function(c){var b=this._partners,a=c._partners;if(b){delete b[c.getId()]}if(a){delete a[this.getId()]}},scrollBy:function(a,b,c){var d=this.getPosition();if(a){if(a.length){c=b;b=a[1];a=a[0]}else {if(typeof a!=='number'){c=b;b=a.y;a=a.x}}}a=typeof a==='number'?a+d.x:null;b=typeof b==='number'?b+d.y:null;return this.doScrollTo(a,b,c)},scrollIntoView:function(d,i,h,e){var a=this,c=a.getPosition(),b,f,g,j=a.getElement();if(d){b=Ext.fly(d).getScrollIntoViewXY(j,c.x,c.y);f=i===!1?c.x:b.x;g=b.y;if(e){a.on({scrollend:'doHighlight',scope:a,single:!0,args:[d,e]})}a.doScrollTo(f,g,h)}},isInView:function(d){var f=this,c={x:!1,y:!1},b,e=f.getElement(),a;if(d&&e.contains(d)){a=e.getRegion();b=Ext.fly(d).getRegion();c.x=b.right>a.left&&b.lefta.top&&b.top0){b-=1}if(c>0){c-=1}e.setSpacerXY({x:b,y:c});d.show()}}},deprecated:{5:{methods:{getScroller:function(){return this}}},'5.1.0':{methods:{scrollToTop:function(a){return this.scrollTo(0,0,a)},scrollToEnd:function(a){return this.scrollTo(Infinity,Infinity,a)}}}},privates:{getSpacer:function(){var b=this,a=b._spacer,c;if(!a){c=b.getElement();a=b._spacer=c.createChild({cls:b._spacerCls,role:'presentation'});a.setVisibilityMode(2);c.position()}return a},applySpacerXY:function(a,b){if(b&&a.x===b.x&&a.y===b.y){a=undefined}return a},updateSpacerXY:function(a){this.getSpacer().setLocalXY(a.x,a.y)},convertX:function(a){return a},doHighlight:function(b,a){if(a!==!0){Ext.fly(b).highlight(a)}else {Ext.fly(b).highlight()}},fireScrollStart:function(b,c){var a=this,d=a.component;a.invokePartners('onPartnerScrollStart',b,c);if(a.hasListeners.scrollstart){a.fireEvent('scrollstart',a,b,c)}if(d&&d.onScrollStart){d.onScrollStart(b,c)}Ext.GlobalEvents.fireEvent('scrollstart',a,b,c)},fireScroll:function(b,c){var a=this,d=a.component;a.invokePartners('onPartnerScroll',b,c);if(a.hasListeners.scroll){a.fireEvent('scroll',a,b,c)}if(d&&d.onScrollMove){d.onScrollMove(b,c)}Ext.GlobalEvents.fireEvent('scroll',a,b,c)},fireScrollEnd:function(b,c){var a=this,d=a.component;a.invokePartners('onPartnerScrollEnd',b,c);if(a.hasListeners.scrollend){a.fireEvent('scrollend',a,b,c)}if(d&&d.onScrollEnd){d.onScrollEnd(b,c)}Ext.GlobalEvents.fireEvent('scrollend',a,b,c)},initXStyle:function(){var b=this.getElement(),a=this.getX();if(b&&b.dom){if(!a){a='hidden'}else {if(a===!0){a='auto'}}b.setStyle('overflow-x',a)}},initYStyle:function(){var b=this.getElement(),a=this.getY();if(b&&b.dom){if(!a){a='hidden'}else {if(a===!0){a='auto'}}b.setStyle('overflow-y',a)}},invokePartners:function(d,g,h){var b=this,c=b._partners,a,e,f=d==='onPartnerScrollEnd';if(!b.suspendSync&!b.isReflecting){for(e in c){a=c[e].scroller;a.isReflecting=!0;a[d](b,g,h);if(f){a.isReflecting=!1}}}},clearReflecting:function(){this.isReflecting=!1},suspendPartnerSync:function(){this.suspendSync=(this.suspendSync||0)+1},resumePartnerSync:function(){if(this.suspendSync){this.suspendSync--}},updateDomScrollPosition:function(){var a=this,d=a.getElement(),b,c=a.position;if(d&&!d.destroyed){b=a.getElementScroll(d);c.x=b.left;c.y=b.top}a.positionDirty=!1;return c},getElementScroll:function(a){return a.getScroll()},onDomScroll:function(){var a=this,b,d,e,c;if(a.isTouchScroller&&Ext.supports.touchScroll===2){c=a.getElement().dom;c.scrollTop=c.scrollLeft=0;return}b=a.updateDomScrollPosition();d=b.x;e=b.y;if(!a.isScrolling){a.isScrolling=Ext.isScrolling=!0;a.fireScrollStart(d,e)}a.fireScroll(d,e);a.onDomScrollEnd()},onDomScrollEnd:function(){var a=this,b=a.getPosition(),c=b.x,d=b.y;a.isScrolling=Ext.isScrolling=!1;a.trackingScrollLeft=c;a.trackingScrollTop=d;a.fireScrollEnd(c,d)},onPartnerScroll:function(d,b,c){var a=d._partners[this.getId()].axis;if(a){if(a==='x'){c=null}else {if(a==='y'){b=null}}}this.doScrollTo(b,c,!1,!0)},restoreState:function(){var a=this,c=a.getElement(),b;if(c){b=c.dom;if(a.trackingScrollTop!==undefined){b.scrollTop=a.trackingScrollTop;b.scrollLeft=a.trackingScrollLeft}}}}},1,0,0,0,['scroller.scroller'],[[Ext.mixin.Factoryable.prototype.mixinId||Ext.mixin.Factoryable.$className,Ext.mixin.Factoryable]],[Ext.scroll,'Scroller'],0);Ext.cmd.derive('Ext.fx.easing.Abstract',Ext.Base,{config:{startTime:0,startValue:0},isEasing:!0,isEnded:!1,constructor:function(a){this.initConfig(a);return this},applyStartTime:function(a){if(!a){a=Ext.Date.now()}return a},updateStartTime:function(a){this.reset()},reset:function(){this.isEnded=!1},getValue:Ext.emptyFn},1,0,0,0,0,0,[Ext.fx.easing,'Abstract'],0);Ext.cmd.derive('Ext.fx.easing.Momentum',Ext.fx.easing.Abstract,{config:{acceleration:30,friction:0,startVelocity:0},alpha:0,updateFriction:function(b){var a=Math.log(1-b/10);this.theta=a;this.alpha=a/this.getAcceleration()},updateStartVelocity:function(a){this.velocity=a*this.getAcceleration()},updateAcceleration:function(a){this.velocity=this.getStartVelocity()*a;this.alpha=this.theta/a},getValue:function(){return this.getStartValue()-this.velocity*(1-this.getFrictionFactor())/this.theta},getFrictionFactor:function(){var a=Ext.Date.now()-this.getStartTime();return Math.exp(a*this.alpha)},getVelocity:function(){return this.getFrictionFactor()*this.velocity}},0,0,0,0,0,0,[Ext.fx.easing,'Momentum'],0);Ext.cmd.derive('Ext.fx.easing.Bounce',Ext.fx.easing.Abstract,{config:{springTension:0.3,acceleration:30,startVelocity:0},getValue:function(){var b=Ext.Date.now()-this.getStartTime(),a=b/this.getAcceleration(),c=a*Math.pow(Math.E,-this.getSpringTension()*a);return this.getStartValue()+this.getStartVelocity()*c}},0,0,0,0,0,0,[Ext.fx.easing,'Bounce'],0);Ext.cmd.derive('Ext.fx.easing.BoundMomentum',Ext.fx.easing.Abstract,{config:{momentum:null,bounce:null,minMomentumValue:0,maxMomentumValue:0,minVelocity:0.01,startVelocity:0},applyMomentum:function(b,a){return Ext.factory(b,Ext.fx.easing.Momentum,a)},applyBounce:function(b,a){return Ext.factory(b,Ext.fx.easing.Bounce,a)},updateStartTime:function(a){this.getMomentum().setStartTime(a);Ext.fx.easing.Abstract.prototype.updateStartTime.apply(this,arguments)},updateStartVelocity:function(a){this.getMomentum().setStartVelocity(a)},updateStartValue:function(a){this.getMomentum().setStartValue(a)},reset:function(){this.lastValue=null;this.isBouncingBack=!1;this.isOutOfBound=!1;return Ext.fx.easing.Abstract.prototype.reset.apply(this,arguments)},getValue:function(){var d=this.getMomentum(),j=this.getBounce(),f=d.getStartVelocity(),b=f>0?1:-1,i=this.getMinMomentumValue(),h=this.getMaxMomentumValue(),g=b==1?h:i,c=this.lastValue,a,e;if(f===0){return this.getStartValue()}if(!this.isOutOfBound){a=d.getValue();e=d.getVelocity();if(Math.abs(e)=i&&a<=h){return a}this.isOutOfBound=!0;j.setStartTime(Ext.Date.now()).setStartVelocity(e).setStartValue(g)}a=j.getValue();if(!this.isEnded){if(!this.isBouncingBack){if(c!==null){if(b==1&&ac){this.isBouncingBack=!0}}}else {if(Math.round(a)==g){this.isEnded=!0}}}this.lastValue=a;return a}},0,0,0,0,0,0,[Ext.fx.easing,'BoundMomentum'],0);Ext.cmd.derive('Ext.fx.easing.Linear',Ext.fx.easing.Abstract,{config:{duration:0,endValue:0},updateStartValue:function(a){this.distance=this.getEndValue()-a},updateEndValue:function(a){this.distance=a-this.getStartValue()},getValue:function(){var a=Ext.Date.now()-this.getStartTime(),b=this.getDuration();if(a>b){this.isEnded=!0;return this.getEndValue()}else {return this.getStartValue()+a/b*this.distance}}},0,0,0,0,['easing.linear'],0,[Ext.fx.easing,'Linear'],0);Ext.cmd.derive('Ext.fx.easing.EaseOut',Ext.fx.easing.Linear,{config:{exponent:4,duration:1500},getValue:function(){var a=Ext.Date.now()-this.getStartTime(),b=this.getDuration(),d=this.getStartValue(),f=this.getEndValue(),e=this.distance,i=a/b,h=1-i,g=1-Math.pow(h,this.getExponent()),c=d+g*e;if(a>=b){this.isEnded=!0;return f}return c}},0,0,0,0,['easing.ease-out'],0,[Ext.fx.easing,'EaseOut'],0);Ext.cmd.derive('Ext.util.translatable.Abstract',Ext.Evented,{config:{useWrapper:null,easing:null,easingX:null,easingY:null},x:0,y:0,activeEasingX:null,activeEasingY:null,isAnimating:!1,isTranslatable:!0,constructor:function(a){this.mixins.observable.constructor.call(this,a);this.position={x:0,y:0}},factoryEasing:function(a){return Ext.factory(a,Ext.fx.easing.Linear,null,'easing')},applyEasing:function(a){if(!this.getEasingX()){this.setEasingX(this.factoryEasing(a))}if(!this.getEasingY()){this.setEasingY(this.factoryEasing(a))}},applyEasingX:function(a){return this.factoryEasing(a)},applyEasingY:function(a){return this.factoryEasing(a)},doTranslate:Ext.emptyFn,translate:function(a,b,c){if(c){return this.translateAnimated(a,b,c)}if(this.isAnimating){this.stopAnimation()}if(!isNaN(a)&&typeof a=='number'){this.x=a}if(!isNaN(b)&&typeof b=='number'){this.y=b}this.doTranslate(a,b)},translateAxis:function(e,a,d){var b,c;if(e=='x'){b=a}else {c=a}return this.translate(b,c,d)},getPosition:function(){var b=this,a=b.position;a.x=-b.x;a.y=-b.y;return a},animate:function(a,b){this.activeEasingX=a;this.activeEasingY=b;this.isAnimating=!0;this.lastX=null;this.lastY=null;Ext.AnimationQueue.start(this.doAnimationFrame,this);this.fireEvent('animationstart',this,this.x,this.y);return this},translateAnimated:function(g,h,a){var b=this;if(!Ext.isObject(a)){a={}}if(b.isAnimating){b.stopAnimation()}b.callback=a.callback;b.callbackScope=a.scope;var f=Ext.Date.now(),e=a.easing,c=typeof g=='number'?a.easingX||e||b.getEasingX()||!0:null,d=typeof h=='number'?a.easingY||e||b.getEasingY()||!0:null;if(c){c=b.factoryEasing(c);c.setStartTime(f);c.setStartValue(b.x);c.setEndValue(g);if('duration' in a){c.setDuration(a.duration)}}if(d){d=b.factoryEasing(d);d.setStartTime(f);d.setStartValue(b.y);d.setEndValue(h);if('duration' in a){d.setDuration(a.duration)}}return b.animate(c,d)},doAnimationFrame:function(){var a=this,d=a.activeEasingX,e=a.activeEasingY,f=Date.now(),b,c;if(!a.isAnimating){return}a.lastRun=f;if(d===null&&e===null){a.stopAnimation();return}if(d!==null){a.x=b=Math.round(d.getValue());if(d.isEnded){a.activeEasingX=null;a.fireEvent('axisanimationend',a,'x',b)}}else {b=a.x}if(e!==null){a.y=c=Math.round(e.getValue());if(e.isEnded){a.activeEasingY=null;a.fireEvent('axisanimationend',a,'y',c)}}else {c=a.y}if(a.lastX!==b||a.lastY!==c){a.doTranslate(b,c);a.lastX=b;a.lastY=c}a.fireEvent('animationframe',a,b,c)},stopAnimation:function(){var a=this;if(!a.isAnimating){return}a.activeEasingX=null;a.activeEasingY=null;a.isAnimating=!1;Ext.AnimationQueue.stop(a.doAnimationFrame,a);a.fireEvent('animationend',a,a.x,a.y);if(a.callback){a.callback.call(a.callbackScope);a.callback=null}},refresh:function(){this.translate(this.x,this.y)},destroy:function(){if(this.isAnimating){this.stopAnimation()}Ext.Evented.prototype.destroy.call(this)}},1,0,0,0,0,0,[Ext.util.translatable,'Abstract'],0);Ext.cmd.derive('Ext.util.translatable.Dom',Ext.util.translatable.Abstract,{config:{element:null},applyElement:function(a){if(!a){return}return Ext.get(a)},updateElement:function(){this.refresh()}},0,0,0,0,0,0,[Ext.util.translatable,'Dom'],0);Ext.cmd.derive('Ext.util.translatable.CssTransform',Ext.util.translatable.Dom,{doTranslate:function(b,c){var a=this.getElement();if(!this.destroyed&&!a.destroyed){a.translate(b,c)}},destroy:function(){var a=this.getElement();if(a&&!a.destroyed){a.dom.style.webkitTransform=null}Ext.util.translatable.Dom.prototype.destroy.call(this)}},0,0,0,0,0,0,[Ext.util.translatable,'CssTransform'],0);Ext.cmd.derive('Ext.util.translatable.ScrollPosition',Ext.util.translatable.Dom,{type:'scrollposition',config:{useWrapper:!0},getWrapper:function(){var a=this.wrapper,c=this.getElement(),b;if(!a){b=c.getParent();if(!b){return null}if(b.hasCls('x-translatable-hboxfix')){b=b.getParent()}if(this.getUseWrapper()){a=c.wrap()}else {a=b}c.addCls('x-translatable');a.addCls('x-translatable-container');this.wrapper=a;a.on('painted',function(){if(!this.isAnimating){this.refresh()}},this);this.refresh()}return a},doTranslate:function(c,d){var b=this.getWrapper(),a;if(b){a=b.dom;if(typeof c=='number'){a.scrollLeft=500000-c}if(typeof d=='number'){a.scrollTop=500000-d}}},destroy:function(){var a=this,c=a.getElement(),b=a.wrapper;if(b){if(!c.destroyed){if(a.getUseWrapper()){b.doReplaceWith(c)}c.removeCls('x-translatable')}if(!b.destroyed){b.removeCls('x-translatable-container');b.un('painted','refresh',a)}delete a.wrapper;delete a._element}Ext.util.translatable.Dom.prototype.destroy.call(this)}},0,0,0,0,0,0,[Ext.util.translatable,'ScrollPosition'],0);Ext.cmd.derive('Ext.util.translatable.ScrollParent',Ext.util.translatable.Dom,{isScrollParent:!0,applyElement:function(b){var a=Ext.get(b);if(a){this.parent=a.parent()}return a},doTranslate:function(b,c){var a=this.parent;a.setScrollLeft(Math.round(-b));a.setScrollTop(Math.round(-c))},getPosition:function(){var c=this,a=c.position,b=c.parent;a.x=b.getScrollLeft();a.y=b.getScrollTop();return a}},0,0,0,0,0,0,[Ext.util.translatable,'ScrollParent'],0);Ext.cmd.derive('Ext.util.translatable.CssPosition',Ext.util.translatable.Dom,{doTranslate:function(b,c){var a=this.getElement().dom.style;if(typeof b=='number'){a.left=b+'px'}if(typeof c=='number'){a.top=c+'px'}},destroy:function(){var a=this.getElement().dom.style;a.left=null;a.top=null;Ext.util.translatable.Dom.prototype.destroy.call(this)}},0,0,0,0,0,0,[Ext.util.translatable,'CssPosition'],0);Ext.cmd.derive('Ext.util.Translatable',Ext.Base,{constructor:function(a){var b=Ext.util.translatable;switch(Ext.browser.getPreferredTranslationMethod(a)){case 'scrollposition':return new b.ScrollPosition(a);case 'scrollparent':return new b.ScrollParent(a);case 'csstransform':return new b.CssTransform(a);case 'cssposition':return new b.CssPosition(a);}}},1,0,0,0,0,0,[Ext.util,'Translatable'],0);Ext.cmd.derive('Ext.scroll.Indicator',Ext.Widget,{config:{axis:null,hideAnimation:!0,hideDelay:0,scroller:null,minLength:24},defaultHideAnimation:{to:{opacity:0},duration:300},names:{x:{side:'l',getSize:'getHeight',setLength:'setWidth',translate:'translateX'},y:{side:'t',getSize:'getWidth',setLength:'setHeight',translate:'translateY'}},oppositeAxis:{x:'y',y:'x'},cls:'x-scroll-indicator',applyHideAnimation:function(a){if(a){a=Ext.mergeIf({onEnd:this.onHideAnimationEnd,scope:this},this.defaultHideAnimation,a)}return a},constructor:function(c){var a=this,b;Ext.Widget.prototype.constructor.call(this,c);b=a.getAxis();a.names=a.names[b];a.element.addCls(a.cls+' '+a.cls+'-'+b)},hide:function(){var a=this,b=a.getHideDelay();if(b){a._hideTimer=Ext.defer(a.doHide,b,a)}else {a.doHide()}},setValue:function(c){var a=this,o=a.element,l=a.names,m=a.getAxis(),k=a.getScroller(),f=k.getMaxUserPosition()[m],g=k.getElementSize()[m],b=a.length,j=a.getMinLength(),e=b,i=g-b-a.sizeAdjust,h=Math.round,n=Math.max,d;if(c<0){e=h(n(b+b*c/g,j));d=0}else {if(c>f){e=h(n(b-b*(c-f)/g,j));d=i+b-e}else {d=h(c/f*i)}}a[l.translate](d);o[l.setLength](e)},show:function(){var a=this,b=a.element,c=b.getActiveAnimation();if(c){c.end()}if(!a._inDom){a.getScroller().getElement().appendChild(b);a._inDom=!0;if(!a.size){a.cacheStyles()}}a.refreshLength();clearTimeout(a._hideTimer);b.setStyle('opacity','')},privates:{cacheStyles:function(){var a=this,c=a.element,b=a.names;a.size=c[b.getSize]();a.margin=c.getMargin(b.side)},doHide:function(){var a=this.getHideAnimation(),b=this.element;if(a){b.animate(a)}else {b.setStyle('opacity',0)}},hasOpposite:function(){return this.getScroller().isAxisEnabled(this.oppositeAxis[this.getAxis()])},onHideAnimationEnd:function(){this.element.setStyle('opacity','0')},refreshLength:function(){var a=this,i=a.names,g=a.getAxis(),e=a.getScroller(),h=e.getSize()[g],c=e.getElementSize()[g],j=c/h,b=a.margin*2,d=a.hasOpposite()?b+a.size:b,f=Math.max(Math.round((c-d)*j),a.getMinLength());a.sizeAdjust=d;a.length=f;a.element[i.setLength](f)},translateX:function(a){this.element.translate(a)},translateY:function(a){this.element.translate(0,a)}}},1,['scrollindicator'],['widget','scrollindicator'],{'widget':!0,'scrollindicator':!0},['widget.scrollindicator'],0,[Ext.scroll,'Indicator'],0);Ext.cmd.derive('Ext.scroll.TouchScroller',Ext.scroll.Scroller,{isTouchScroller:!0,config:{autoRefresh:!0,bounceEasing:{duration:400},elementSize:undefined,indicators:!0,fps:'auto',maxAbsoluteVelocity:6,momentumEasing:{momentum:{acceleration:30,friction:0.5},bounce:{acceleration:30,springTension:0.3},minVelocity:1},outOfBoundRestrictFactor:0.5,innerElement:null,size:undefined,slotSnapEasing:{duration:150},slotSnapOffset:{x:0,y:0},startMomentumResetTime:300,translatable:{translationMethod:'auto',useWrapper:!1}},cls:'x-scroll-container',scrollerCls:'x-scroll-scroller',dragStartTime:0,dragEndTime:0,isDragging:!1,isAnimating:!1,isMouseEvent:{mousedown:1,mousemove:1,mouseup:1},listenerMap:{touchstart:'onTouchStart',touchmove:'onTouchMove',dragstart:'onDragStart',drag:'onDrag',dragend:'onDragEnd'},refreshCounter:0,constructor:function(c){var a=this,b='onEvent';a.elementListeners={touchstart:b,touchmove:b,dragstart:b,drag:b,dragend:b,scope:a};a.minPosition={x:0,y:0};a.startPosition={x:0,y:0};a.velocity={x:0,y:0};a.isAxisEnabledFlags={x:!1,y:!1};a.flickStartPosition={x:0,y:0};a.flickStartTime={x:0,y:0};a.lastDragPosition={x:0,y:0};a.dragDirection={x:0,y:0};Ext.scroll.Scroller.prototype.constructor.call(this,c);a.refreshAxes();a.scheduleRefresh={idle:a.doRefresh,scope:a,single:!0,destroyable:!0}},applyBounceEasing:function(b){var a=Ext.fx.easing.EaseOut;return {x:Ext.factory(b,a),y:Ext.factory(b,a)}},applyElementSize:function(b){var e=this.getElement(),a,c,d;if(!e){return null}a=e.dom;if(!a){return}if(b==null){c=a.clientWidth;d=a.clientHeight}else {c=b.x;d=b.y}return {x:c,y:d}},applyIndicators:function(b,a){var g=this,c,d,e,f;if(b){if(b===!0){c=d={}}else {e=b.x;f=b.y;if(e||f){c=e==null||e===!0?{}:e;d=e==null||f===!0?{}:f}else {c=d=b}}if(a){if(c){a.x.setConfig(c)}else {a.x.destroy();a.x=null}if(d){a.y.setConfig(d)}else {a.y.destroy();a.y=null}b=a}else {b={x:null,y:null};if(c){b.x=new Ext.scroll.Indicator(Ext.applyIf({axis:'x',scroller:g},c))}if(d){b.y=new Ext.scroll.Indicator(Ext.applyIf({axis:'y',scroller:g},d))}}}else {if(a){if(a.x){a.x.destroy()}if(a.y){a.y.destroy()}a.x=a.y=null}}return b},applyMomentumEasing:function(b){var a=Ext.fx.easing.BoundMomentum;return {x:Ext.factory(b,a),y:Ext.factory(b,a)}},applyInnerElement:function(a){if(a&&!a.isElement){a=Ext.get(a)}return a},applyMaxPosition:function(a,c){if(c&&a.x===c.x&&a.y===c.y){return}var d=this.getTranslatable(),b;if(d.isAnimating){b=d.activeEasingY;if(b&&b.getStartVelocity&&b.getStartVelocity()<0&&a.yi){d=i}}if(l){c=a.convertX(c);d=a.convertX(d)}if(d!==null){f=a.getBounceEasing()[b];f.setConfig({startTime:j,startValue:-c,endValue:-d});return f}if(e===0){return null}if(e<-g){e=-g}else {if(e>g){e=g}}f=a.getMomentumEasing()[b];h={startTime:j,startValue:-c,startVelocity:e*1.5,minMomentumValue:-i,maxMomentumValue:0};if(l){a.convertEasingConfig(h)}f.setConfig(h);return f},getSnapPosition:function(d){var e=this,c=e.getSlotSnapSize()[d],f=null,b,h,g,a;if(c!==0&&e.isAxisEnabled(d)){b=e.position[d];h=e.getSlotSnapOffset()[d];g=e.getMaxUserPosition()[d];a=Math.floor((b-h)%c);if(a!==0){if(b!==g){if(Math.abs(a)>c/2){f=Math.min(g,b+(a>0?c-a:a-c))}else {f=b-a}}else {f=b-a}}}return f},hideIndicators:function(){var d=this,a=d.getIndicators(),b,c;if(a){if(d.isAxisEnabled('x')){b=a.x;if(b){b.hide()}}if(d.isAxisEnabled('y')){c=a.y;if(c){c.hide()}}}},isAxisEnabled:function(a){this.getX();this.getY();return this.isAxisEnabledFlags[a]},onAnimationEnd:function(){this.snapToBoundary();this.onScrollEnd()},onAnimationFrame:function(d,b,c){var a=this.position;a.x=this.convertX(-b);a.y=-c;this.onScroll()},onAxisDrag:function(a,k){if(k&&this.isAxisEnabled(a)){var b=this,o=b.flickStartPosition,g=b.flickStartTime,f=b.lastDragPosition,d=b.dragDirection,r=b.position[a],q=b.getMinUserPosition()[a],e=b.getMaxUserPosition()[a],p=b.startPosition[a],l=f[a],c=p-k,i=d[a],h=b.getOutOfBoundRestrictFactor(),n=b.getStartMomentumResetTime(),m=Ext.Date.now(),j;if(ce){j=c-e;c=e+j*h}}if(c>l){d[a]=1}else {if(cn){o[a]=r;g[a]=m}f[a]=c;return !0}},onDomScroll:function(){var c=this,b,a;if(c.getTranslatable().isScrollParent){b=c.getElement().dom;a=c.position;a.x=b.scrollLeft;a.y=b.scrollTop}Ext.scroll.Scroller.prototype.onDomScroll.call(this)},onDrag:function(c){var a=this,b=a.lastDragPosition;if(!a.isDragging){return}if(a.onAxisDrag('x',a.convertX(c.deltaX))|a.onAxisDrag('y',c.deltaY)){a.doScrollTo(b.x,b.y)}},onDragEnd:function(d){var a=this,b,c;if(!a.isDragging){return}a.dragEndTime=Ext.Date.now();a.onDrag(d);a.isDragging=!1;b=a.getAnimationEasing('x',d);c=a.getAnimationEasing('y',d);if(b||c){a.getTranslatable().animate(b,c)}else {a.onScrollEnd()}},onDragStart:function(d){var a=this,b=a.getDirection(),m=d.absDeltaX,n=d.absDeltaY,o=a.getDirectionLock(),l=a.startPosition,g=a.flickStartPosition,j=a.flickStartTime,h=a.lastDragPosition,i=a.position,k=a.dragDirection,e=i.x,f=i.y,c=Ext.Date.now();if(o&&b!=='both'){if(b==='horizontal'&&m>n||b==='vertical'&&n>m){d.stopPropagation()}else {return}}h.x=e;h.y=f;g.x=e;g.y=f;l.x=e;l.y=f;j.x=c;j.y=c;k.x=0;k.y=0;a.dragStartTime=c;a.isDragging=!0;if(!a.isScrolling){a.onScrollStart()}},onElementResize:function(b,a){this.refresh(!0,{elementSize:{x:a.contentWidth,y:a.contentHeight},size:this.getAutoRefresh()?null:this.getSize()})},onElementScroll:function(b,a){a.scrollTop=a.scrollLeft=0},onEvent:function(b){var a=this,c=b.browserEvent;if((!a.self.isTouching||a.isTouching)&&(!a.getTranslatable().isScrollParent||!a.isMouseEvent[c.type]&&c.pointerType!=='mouse')&&(a.getY()||a.getX())){a[a.listenerMap[b.type]](b)}},onInnerElementResize:function(b,a){this.refresh(!0,{size:{x:a.width,y:a.height}})},onMouseWheel:function(j){var a=this,g=j.getWheelDeltas(),c=-g.x,d=-g.y,b=a.position,e=a.getMaxUserPosition(),f=a.getMinUserPosition(),h=Math.max,i=Math.min,k=h(i(b.x+c,e.x),f.x),l=h(i(b.y+d,e.y),f.y);c=k-b.x;d=l-b.y;if(!c&&!d){return}j.stopEvent();a.onScrollStart();a.scrollBy(c,d);a.onScroll();a.onScrollEnd()},onPartnerScrollEnd:function(b,c){var a=this;if(!a.getTranslatable().isScrollParent){a.fireScrollEnd(b,c)}Ext.scroll.Scroller.prototype.onPartnerScrollEnd.call(this,b,c);a.isScrolling=!1;a.hideIndicators()},onPartnerScrollStart:function(b,c){var a=this;a.isScrolling=!0;if(!a.getTranslatable().isScrollParent){a.fireScrollStart(b,c)}a.showIndicators()},onScroll:function(){var a=this,e=a.position,f=e.x,g=e.y,b=a.getIndicators(),c,d;if(b){if(a.isAxisEnabled('x')){c=b.x;if(c){c.setValue(f)}}if(a.isAxisEnabled('y')){d=b.y;if(d){d.setValue(g)}}}a.fireScroll(f,g)},onScrollEnd:function(){var a=this,b=a.position;if(a.isScrolling&&!a.isTouching&&!a.snapToSlot()){a.hideIndicators();a.isScrolling=Ext.isScrolling=!1;a.fireScrollEnd(b.x,b.y)}},onScrollStart:function(){var a=this,b=a.position;if(!a.isScrolling){a.showIndicators();a.isScrolling=Ext.isScrolling=!0;a.fireScrollStart(b.x,b.y)}},onTouchEnd:function(){var a=this;a.isTouching=a.self.isTouching=!1;if(!a.isDragging&&a.snapToSlot()){a.onScrollStart()}},onTouchMove:function(a){a.preventDefault()},onTouchStart:function(){var a=this;a.isTouching=a.self.isTouching=!0;Ext.getDoc().on({touchend:'onTouchEnd',scope:a,single:!0});a.stopAnimation()},refreshAxes:function(){var a=this,b=a.isAxisEnabledFlags,k=a.getSize(),h=a.getElementSize(),e=a.getIndicators(),f,g,c,d,i,j;if(!k||!h){return}f=Math.max(0,k.x-h.x);g=Math.max(0,k.y-h.y);c=a.getX();d=a.getY();a.setMaxPosition({x:f,y:g});if(c===!0||c==='auto'){b.x=!!f}else {if(c===!1){b.x=!1;i=e&&e.x;if(i){i.hide()}}else {if(c==='scroll'){b.x=!0}}}if(d===!0||d==='auto'){b.y=!!g}else {if(d===!1){b.y=!1;j=e&&e.y;if(j){j.hide()}}else {if(d==='scroll'){b.y=!0}}}a.setMaxUserPosition({x:b.x?f:0,y:b.y?g:0});if(Ext.supports.touchScroll===1){a.initXStyle();a.initYStyle()}},showIndicators:function(){var d=this,a=d.getIndicators(),b,c;if(a){if(d.isAxisEnabled('x')){b=a.x;if(b){b.show()}}if(d.isAxisEnabled('y')){c=a.y;if(c){c.show()}}}},snapToBoundary:function(){var a=this,d=a.getPosition();if(a.isConfiguring||!(d.x||d.y)){return}var f=a.getMinUserPosition(),e=a.getMaxUserPosition(),i=f.x,j=f.y,g=e.x,h=e.y,b=Math.round(d.x),c=Math.round(d.y);if(bg){b=g}}if(ch){c=h}}a.doScrollTo(b,c)},snapToSlot:function(){var a=this,c=a.getSnapPosition('x'),d=a.getSnapPosition('y'),b=a.getSlotSnapEasing();if(c!==null||d!==null){a.doScrollTo(c,d,{easingX:b.x,easingY:b.y});return !0}return !1},stopAnimation:function(){this.getTranslatable().stopAnimation()},toggleResizeListeners:function(e){var c=this,f=c.getElement(),b,a,d;if(f){d=c.getInnerElement();if(e){b=a='on'}else {if(e===null){b='on';a='un'}else {b=a='un'}}f[b]('resize','onElementResize',c);d[a]('resize','onInnerElementResize',c)}},unwrapContent:function(){var a=this.getInnerElement().dom,c=this.getElement().dom,b;while(b=a.firstChild){c.insertBefore(b,a)}},wrapContent:function(d){var a=document.createElement('div'),c=d.dom,b;while(b=c.lastChild){a.insertBefore(b,a.firstChild)}c.appendChild(a);this.setInnerElement(a);this._isWrapped=!0;return this.getInnerElement()}}},1,0,0,0,['scroller.touch'],0,[Ext.scroll,'TouchScroller'],0);Ext.cmd.derive('Ext.scroll.DomScroller',Ext.scroll.Scroller,{isDomScroller:!0,getMaxPosition:function(){var b=this.getElement(),c=0,d=0,a;if(b&&!b.destroyed){a=b.dom;c=a.scrollWidth-a.clientWidth;d=a.scrollHeight-a.clientHeight}return {x:c,y:d}},getMaxUserPosition:function(){var c=this,b=c.getElement(),d=0,e=0,a;if(b&&!b.destroyed){a=b.dom;if(c.getX()){d=a.scrollWidth-a.clientWidth}if(c.getY()){e=a.scrollHeight-a.clientHeight}}return {x:d,y:e}},getPosition:function(){var a=this;if(a.positionDirty){a.updateDomScrollPosition()}return a.position},getSize:function(){var a=this.getElement(),b,c;if(a&&!a.destroyed){c=a.dom;b={x:c.scrollWidth,y:c.scrollHeight}}else {b={x:0,y:0}}return b},updateElement:function(b,a){this.initXStyle();this.initYStyle()},updateX:function(a){this.initXStyle()},updateY:function(a){this.initYStyle()},privates:{doScrollTo:function(a,b,j){var e=this,d=e.getElement(),f,c,i,g,h,k;if(d&&!d.destroyed){c=d.dom;g=a===Infinity;h=b===Infinity;if(g||h){f=e.getMaxPosition();if(g){a=f.x}if(h){b=f.y}}a=e.convertX(a);if(j){i={};if(b!=null){i.scrollTop=b}if(a!=null){i.scrollLeft=a}d.animate(Ext.mergeIf({to:{scrollTop:b,scrollLeft:a}},j))}else {if(b!=null){c.scrollTop=b}if(a!=null){c.scrollLeft=a;if(Ext.isIE8){k=c.scrollLeft;c.scrollLeft=a}}}e.positionDirty=!0}},getElementScroll:function(a){return a.getScroll()},stopAnimation:function(){var a=this.getElement().getActiveAnimation();if(a){a.end()}}}},0,0,0,0,['scroller.dom'],0,[Ext.scroll,'DomScroller'],function(a){Ext.onDocumentReady(function(){a.document=new a({x:!0,y:!0,element:document.body})})});Ext.cmd.derive('Ext.util.Floating',Ext.Base,{mixinId:'floating',focusOnToFront:!0,shadow:'sides',animateShadow:!1,constrain:!1,config:{activeCounter:0,alwaysOnTop:!1},preventDefaultAlign:!1,_visModeMap:{visibility:1,display:2,offsets:3},constructor:function(){var a=this,e=a.el,d=a.shadow,c,b;if(d){b={mode:d===!0?'sides':d};c=a.shadowOffset;if(c){b.offset=c}b.animate=a.animateShadow;b.fixed=a.fixed;e.enableShadow(b,!1)}if(a.shim||Ext.useShims){e.enableShim({fixed:a.fixed},!1)}e.setVisibilityMode(a._visModeMap[a.hideMode]);a.el.on({mousedown:a.onMouseDown,scope:a,capture:!0});a.registerWithOwnerCt();a.initHierarchyEvents()},alignTo:function(b,d,f,e){var a=this,c;Ext.un('scroll',a.onAlignToScroll,a);if(b.isComponent){c=b.el}else {if(b.nodeType){c=Ext.fly(b)}else {c=b}}if(!c.contains(a.el)){Ext.on('scroll',a.onAlignToScroll,a)}a._lastAlignTarget=b;a._lastAlignToPos=d;a.mixins.positionable.alignTo.call(a,c,d,f,e)},initFloatConstrain:function(){var a=this,b=a.floatParent;if((a.constrain||a.constrainHeader)&&!a.constrainTo){a.constrainTo=b?b.getTargetEl():a.container}},initHierarchyEvents:function(){var b=this,a=this.syncHidden;if(!b.hasHierarchyEventListeners){b.mon(Ext.GlobalEvents,{hide:a,collapse:a,show:a,expand:a,added:a,scope:b});b.hasHierarchyEventListeners=!0}},registerWithOwnerCt:function(){var a=this,c=a.ownerCt,b=a.zIndexParent;if(b){b.unregisterFloatingItem(a)}b=a.zIndexParent=a.up('[floating]');a.floatParent=c||b;a.initFloatConstrain();delete a.ownerCt;if(b){b.registerFloatingItem(a)}else {Ext.WindowManager.register(a)}},onMouseDown:function(g){var b=this,f=b.focusTask,c=g.pointerType==='touch',a,d,e;if(b.floating&&(!f||!f.id)){a=g.target;d=b.el.dom;while(!c&&a&&a!==d){if(Ext.fly(a).isFocusable()){c=!0}a=a.parentNode}e=Ext.WindowManager.getActive()===b&&(a===d||c);if(!e){b.toFront(c)}}},onBeforeFloatLayout:function(){this.el.preventSync=!0},onAfterFloatLayout:function(){var a=this.el;if(a.shadow||a.shim){a.setUnderlaysVisible(!0);a.syncUnderlays()}},syncHidden:function(){var a=this,d=a.hidden||!a.rendered,c=a.hierarchicallyHidden=a.isHierarchicallyHidden(),b=a.pendingShow;if(d!==c){if(c){a.hide();a.pendingShow=!0}else {if(b){delete a.pendingShow;if(b.length){a.show.apply(a,b)}else {a.show()}}}}},setZIndex:function(a){var b=this;b.el.setZIndex(a);a+=10;if(b.floatingDescendants){a=Math.floor(b.floatingDescendants.setBase(a)/100)*100+10000}return a},doConstrain:function(c){var a=this,b=a.calculateConstrainedPosition(c,null,!0);if(b){a.setPosition(b)}},updateActiveCounter:function(b){var a=this.zIndexParent;if(a&&this.bringParentToFront!==!1){a.setActiveCounter(++Ext.ZIndexManager.activeCounter)}a=this.zIndexManager;if(a){a.onComponentUpdate(this)}},updateAlwaysOnTop:function(b){var a=this.zIndexManager;if(a){a.onComponentUpdate(this)}},toFront:function(b){var a=this;if(a.zIndexManager.bringToFront(a,b||!a.focusOnToFront)){if(a.hasListeners.tofront){a.fireEvent('tofront',a,a.el.getZIndex())}}return a},setActive:function(d,c){var a=this,b;if(d){if(a.el.shadow&&!a.maximized){a.el.enableShadow(null,!0)}if(c){b=Ext.ComponentManager.getActiveComponent();if(!b||!b.up(a)){a.focus()}}a.fireEvent('activate',a)}else {a.fireEvent('deactivate',a)}},toBack:function(){this.zIndexManager.sendToBack(this);return this},center:function(){var a=this,b;if(a.isVisible()){b=a.getAlignToXY(a.container,'c-c');a.setPagePosition(b)}else {a.needsCenter=!0}return a},onFloatShow:function(){if(this.needsCenter){this.center()}delete this.needsCenter;if(this.toFrontOnShow){this.toFront()}},fitContainer:function(f){var d=this,c=d.floatParent,a=c?c.getTargetEl():d.container,b=a.getViewSize(),e=c||a.dom!==document.body?[0,0]:a.getXY();b.x=e[0];b.y=e[1];d.setBox(b,f)},privates:{onFloatDestroy:function(){this.clearAlignEl()},clearAlignEl:function(){var a=this;if(a._lastAlignTarget){Ext.un('scroll',a.onAlignToScroll,a);a._lastAlignPos=a._lastAlignTarget=null}},onAlignToScroll:function(e){var b=this,a=b._lastAlignTarget,f=a.isFloating,c,d;if(a){if(a.isComponent){c=a.destroyed;a=a.el}else {if(a.nodeType){a=Ext.fly(a)}d=a.dom;c=!d||Ext.isGarbage(d)}if(c){b.clearAlignEl()}else {if((e.getElement().contains(a)||f)&&!e.getElement().contains(b.el)){b.alignTo(a,b._lastAlignToPos)}}}}}},1,0,0,0,0,0,[Ext.util,'Floating'],0);Ext.cmd.derive('Ext.util.ElementContainer',Ext.Base,{mixinId:'elementCt',config:{childEls:{$value:{},cached:!0,lazy:!0,merge:function(d,f,g,e){var c=f?Ext.Object.chain(f):{},b,a;if(d instanceof Array){for(b=d.length;b--;){a=d[b];if(!e||!(a in c)){if(typeof a==='string'){c[a]={name:a,itemId:a}}else {c[a.name]=a}}}}else {if(d){if(d.constructor===Object){for(b in d){if(!e||!(b in c)){a=d[b];if(a===!0){c[b]={itemId:b}}else {if(typeof a==='string'){c[b]={itemId:a}}else {c[b]=a;if(!('itemId' in a)){a.itemId=b}}}c[b].name=b}}}else {if(!e||!(d in c)){c[d]={name:d,itemId:d}}}}}return c}}},destroy:function(){var c=this,d=c.getChildEls(),a,b;for(b in d){a=c[b];if(a){if(a.destroy){a.component=null;a.destroy()}c[b]=null}}},privates:{addChildEl:function(a){var c=this,b=c.getChildEls();if(!c.hasOwnProperty('childEls')){c.childEls=b=Ext.Object.chain(b)}if(typeof a==='string'){a={name:a,itemId:a}}b[a.name]=a},afterClassMixedIn:function(a){var c=a.prototype,b=c.childEls;if(b){delete c.childEls;a.getConfigurator().add({childEls:b})}},attachChildEls:function(h,n){var i=this,k=i.getChildEls(),e=n||i,m=e.id+'-',l=!e.frame,f,g,b,j,c,a,d;for(f in k){b=k[f];if(l&&b.frame){continue}c=b.select;if(c){a=h.select(c,!0)}else {if(!(c=b.selectNode)){if(!(d=b.id)){d=m+b.itemId;a=Ext.cache[d]}else {a=Ext.cache[d]||h.getById(d)}}else {a=h.selectNode(c,!1)}}if(a){if(a.isElement){a.component=e}else {if(a.isComposite&&!a.isLite){g=a.elements;for(j=g.length;j--;){g[j].component=e}}}}i[f]=a||null}}}},0,0,0,0,0,0,[Ext.util,'ElementContainer'],0);Ext.cmd.derive('Ext.util.Renderable',Ext.Base,{mixinId:'renderable',frameCls:'x-frame',frameIdRegex:/[\-]frame\d+[TMB][LCR]$/,frameElNames:['TL','TC','TR','ML','MC','MR','BL','BC','BR','Table'],frameTpl:['{%this.renderDockedItems(out,values,0);%}','','
    {parent.baseCls}-{parent.ui}-{.}-tl{frameElCls}" role="presentation">','
    {parent.baseCls}-{parent.ui}-{.}-tr{frameElCls}" role="presentation">','
    {parent.baseCls}-{parent.ui}-{.}-tc{frameElCls}" role="presentation">
    ','
    ','
    ','
    ','
    {parent.baseCls}-{parent.ui}-{.}-ml{frameElCls}" role="presentation">','
    {parent.baseCls}-{parent.ui}-{.}-mr{frameElCls}" role="presentation">','
    {parent.baseCls}-{parent.ui}-{.}-mc{frameElCls}" role="presentation">','{%this.applyRenderTpl(out, values)%}','
    ','
    ','
    ','','
    {parent.baseCls}-{parent.ui}-{.}-bl{frameElCls}" role="presentation">','
    {parent.baseCls}-{parent.ui}-{.}-br{frameElCls}" role="presentation">','
    {parent.baseCls}-{parent.ui}-{.}-bc{frameElCls}" role="presentation">
    ','
    ','
    ','
    ','{%this.renderDockedItems(out,values,1);%}'],frameTableTpl:['{%this.renderDockedItems(out,values,0);%}','','','','','','','','','','','','','','','','','','','','','','{%this.renderDockedItems(out,values,1);%}'],_renderState:0,ariaEl:'el',_layerCls:'x-layer',_fixedLayerCls:'x-fixed-layer',ariaStaticRoles:{presentation:!0,article:!0,definition:!0,directory:!0,document:!0,img:!0,heading:!0,math:!0,note:!0,banner:!0,complementary:!0,contentinfo:!0,navigation:!0,search:!0,'undefined':!0,'null':!0},statics:{makeRenderSetter:function(c,b){var a=c.name;return function(g){var d=this,f=d.renderConfigs||(d.renderConfigs={}),e=f[b];if(d._renderState>=b){(c.setter||c.getSetter()).call(d,g)}else {if(!e){f[b]=e={}}if(!(a in e)){e[a]=d[a]}d[a]=g}return d}},processRenderConfig:function(g,e,c){var h=this.prototype,j=this.getConfigurator(),k=Ext.util.Renderable,l=k.makeRenderSetter,d=g[e],b,a,i,f;for(i in d){a=Ext.Config.get(i);if(!h[f=a.names.set]){b=a.renderSetter||(a.renderSetter={});h[f]=b[c]||(b[c]=l(a,c))}}delete g[e];j.add(d)}},onClassMixedIn:function(a){var e=a.override,c=this.processRenderConfig,d=function(b){if(b.beforeRenderConfig){this.processRenderConfig(b,'beforeRenderConfig',1)}if(b.renderConfig){this.processRenderConfig(b,'renderConfig',3)}e.call(this,b)},b=function(e,b){e.override=d;e.processRenderConfig=c;if(b.beforeRenderConfig){e.processRenderConfig(b,'beforeRenderConfig',1)}if(b.renderConfig){e.processRenderConfig(b,'renderConfig',3)}};b(a,a.prototype);a.onExtended(b)},afterRender:function(){var a=this,c={},i=a.protoEl,g=a.el,d,b,h,f,e;a.finishRenderChildren();a._renderState=4;if(a.contentEl){h='x-';f=h+'hidden-';e=a.contentEl=Ext.get(a.contentEl);e.component=a;e.removeCls([h+'hidden',f+'display',f+'offsets']);a.getContentTarget().appendChild(e.dom)}i.writeTo(c);b=c.removed;if(b){g.removeCls(b)}b=c.cls;if(b.length){g.addCls(b)}b=c.style;if(c.style){g.setStyle(b)}a.protoEl=null;if(!a.ownerCt&&!a.skipLayout){a.updateLayout()}if(!(a.x&&a.y)&&(a.pageX||a.pageY)){a.setPagePosition(a.pageX,a.pageY)}if(a.disableOnRender){a.onDisable()}d=a.controller;if(d&&d.afterRender){d.afterRender(a)}},afterFirstLayout:function(l,k){var a=this,g=a.x,h=a.y,j=a.defaultAlign,i=a.alignOffset,f,d,e,b,c;if(!a.ownerLayout){d=g!==undefined;e=h!==undefined}if(a.floating&&!a.preventDefaultAlign&&(!d||!e)){if(a.floatParent){b=a.floatParent.getTargetEl().getViewRegion();c=a.el.getAlignToXY(a.alignTarget||a.floatParent.getTargetEl(),j,i);b.x=c[0]-b.x;b.y=c[1]-b.y}else {c=a.el.getAlignToXY(a.alignTarget||a.container,j,i);b=a.el.translateXY(c[0],c[1])}g=d?g:b.x;h=e?h:b.y;d=e=!0}if(d||e){a.setPosition(g,h)}a.onBoxReady(l,k);f=a.controller;if(f&&f.boxReady){f.boxReady(a)}},beforeRender:function(){var a=this,d=a.floating,e=a.getComponentLayout(),b=a.userCls,c;a._renderState=1;a.ariaUsesMainElement=a.ariaEl==='el';c=a.controller;if(c&&c.beforeRender){c.beforeRender(a)}a.initBindable();if(a.renderConfigs){a.flushRenderConfigs()}if(a.reference){a.publishState()}if(b){a.addCls(b)}if(d){a.addCls(a.fixed?a._fixedLayerCls:a._layerCls);b=d.cls;if(b){a.addCls(b)}}a.frame=a.frame||a.alwaysFramed;if(!e.initialized){e.initLayout()}a.initOverflow();a.setUI(a.ui)},doApplyRenderTpl:function(d,a){var c=a.$comp,b;if(!c.rendered){b=c.initRenderTpl();b.applyOut(a.renderData,d)}},getElConfig:function(){var a=this,e=a.autoEl,c=a.getFrameInfo(),b={tag:'div',tpl:c?a.initFramingTpl(c.table):a.initRenderTpl()},g=a.layoutTargetCls,d=a.protoEl,f=a.ariaRole,h;a.initStyles(d);if(g&&!c){d.addCls(g)}d.writeTo(b);d.flush();if(e){if(Ext.isString(e)){b.tag=e}else {Ext.apply(b,e)}}if(f&&a.ariaUsesMainElement){b.role=f;if(!a.ariaStaticRoles[f]){b['aria-hidden']=!!a.hidden;b['aria-disabled']=!!a.disabled;if(a.ariaLabel&&!a.ariaLabelledBy){b['aria-label']=a.ariaLabel}if(a.collapsible){b['aria-expanded']=!a.collapsed}if(a.ariaRenderAttributes){Ext.apply(b,a.ariaRenderAttributes)}if(a.config.ariaAttributes){Ext.apply(b,a.getAriaAttributes())}}}b.id=a.id;if(b.tpl){if(c){b.tplData=h=a.getFrameRenderData();h.renderData=a.initRenderData()}else {b.tplData=a.initRenderData()}}a.ariaRenderAttributes=null;return b},getInsertPosition:function(a){if(a!==undefined){if(Ext.isNumber(a)){a=this.container.dom.childNodes[a]}else {a=Ext.getDom(a)}}return a},getRenderTree:function(){var a=this,b=null;if(!a.hasListeners.beforerender||a.fireEvent('beforerender',a)!==!1){a._renderState=1;a.beforeRender();a.rendering=!0;a._renderState=2;b=a.getElConfig();if(a.el){b.id=a.$pid=Ext.id(null,a.el.identifiablePrefix)}}return b},initRenderData:function(){var a=this,c=a.ariaRole,d,b;d=Ext.apply({$comp:a,id:a.id,ui:a.ui,uiCls:a.uiCls,baseCls:a.baseCls,componentCls:a.componentCls,frame:a.frame,renderScroller:a.touchScroll,scrollerCls:a.scrollerCls,childElCls:''},a.renderData);if(c&&!a.ariaUsesMainElement){b={role:c};if(!a.ariaStaticRoles[c]){b['aria-hidden']=!!a.hidden;b['aria-disabled']=!!a.disabled;if(a.ariaLabel&&!a.ariaLabelledBy){b['aria-label']=a.ariaLabel}if(a.collapsible){b['aria-expanded']=!a.collapsed}if(a.ariaRenderAttributes){Ext.apply(b,a.ariaRenderAttributes)}if(a.config.ariaAttributes){Ext.apply(b,a.getAriaAttributes())}}d.ariaAttributes=b}return d},onRender:function(i,h){var a=this,e=a.x,f=a.y,b=null,g=a.el,d,c;a.applyRenderSelectors();a.rendering=null;a.rendered=!0;a._renderState=3;if(a.renderConfigs){a.flushRenderConfigs()}if(e!=null){b={x:e}}if(f!=null){(b=b||{}).y=f}if(!a.getFrameInfo()){d=a.width;c=a.height;if(typeof d==='number'){b=b||{};b.width=d}if(typeof c==='number'){b=b||{};b.height=c}}if(a.touchScroll===1){a.getOverflowEl().disableTouchScroll()}a.lastBox=g.lastBox=b},render:function(c,g){var a=this,b=a.el,f=a.ownerLayout,h,d,e;if(b&&!b.isElement){a.wrapPrimaryEl(b);b=a.el}if(!a.skipLayout){Ext.suspendLayouts()}c=a.initContainer(c);e=a.getInsertPosition(g);if(!b){d=a.getRenderTree();if(f&&f.transformItemRenderTree){d=f.transformItemRenderTree(d)}if(d){if(e){b=Ext.DomHelper.insertBefore(e,d)}else {b=Ext.DomHelper.append(c,d)}a.wrapPrimaryEl(b);a.cacheRefEls(b)}}else {if(!a.hasListeners.beforerender||a.fireEvent('beforerender',a)!==!1){a.beforeRender();a.needsRenderTpl=a.rendering=!0;a._renderState=2;a.initStyles(b);if(a.allowDomMove!==!1){if(e){c.dom.insertBefore(b.dom,e)}else {c.dom.appendChild(b.dom)}}}else {h=!0}}if(b&&!h){a.finishRender(g)}if(!a.skipLayout){Ext.resumeLayouts(!a.hidden&&!c.isDetachedBody)}},ensureAttachedToBody:function(c){var a=this,b;while(a.ownerCt){a=a.ownerCt}if(a.container.isDetachedBody){a.container=b=Ext.getBody();b.appendChild(a.el.dom);if(c){a.updateLayout()}if(typeof a.x==='number'||typeof a.y==='number'){a.setPosition(a.x,a.y)}}},privates:{applyRenderSelectors:function(){var a=this,b=a.renderSelectors,e=a.el,d,c;a.attachChildEls(e);a.ariaEl=a[a.ariaEl]||a.el;if(b){for(c in b){d=b[c];if(d){a[c]=e.selectNode(d,!1)}}}},cacheRefEls:function(a){a=a||this.el;var e=Ext.cache,h=Ext.dom.Element,f=a.isElement?a.dom:a,d=f.querySelectorAll('[data-ref]'),g=d.length,c,b;for(b=0;b','
    ','','{%this.renderContent(out,values)%}','
    '],resizeHandles:'all',shrinkWrap:2,toFrontOnShow:!0,synthetic:!1,tplWriteMode:'overwrite',ui:'default',uiCls:[],userCls:null,weight:null,allowDomMove:!0,autoGenId:!1,borderBoxCls:'x-border-box',componentLayoutCounter:0,contentPaddingProperty:'padding',deferLayouts:!1,frameSize:null,horizontalPosProp:'left',isComponent:!0,_isLayoutRoot:!1,layoutSuspendCount:0,liquidLayout:!1,maskOnDisable:!0,offsetsCls:'x-hidden-offsets',rendered:!1,rootCls:'x-body',scrollerCls:'x-scroll-scroller',scrollerSelector:'.x-scroll-scroller',_scrollFlags:{auto:{auto:{overflowX:'auto',overflowY:'auto',x:!0,y:!0,both:!0},'false':{overflowX:'auto',overflowY:'hidden',x:!0,y:!1,both:!1},scroll:{overflowX:'auto',overflowY:'scroll',x:!0,y:!0,both:!0}},'false':{auto:{overflowX:'hidden',overflowY:'auto',x:!1,y:!0,both:!1},'false':{overflowX:'hidden',overflowY:'hidden',x:!1,y:!1,both:!1},scroll:{overflowX:'hidden',overflowY:'scroll',x:!1,y:!0,both:!1}},scroll:{auto:{overflowX:'scroll',overflowY:'auto',x:!0,y:!0,both:!0},'false':{overflowX:'scroll',overflowY:'hidden',x:!0,y:!1,both:!1},scroll:{overflowX:'scroll',overflowY:'scroll',x:!0,y:!0,both:!0}},none:{overflowX:'',overflowY:'',x:!1,y:!1,both:!1}},_scrollableCfg:{x:{x:!0,y:!1},y:{x:!1,y:!0},horizontal:{x:!0,y:!1},vertical:{x:!1,y:!0},both:{x:!0,y:!0},'true':{x:!0,y:!0}},validIdRe:Ext.validIdRe,constructor:function(b){var a=this,e,j,i,h,g,c,d,f;b=b||{};if(b.initialConfig){if(b.isAction){a.baseAction=b}b=b.initialConfig}else {if(b.tagName||b.dom||Ext.isString(b)){b={applyTo:b,id:b.id||b}}}a.initialConfig=b;a.getId();a.protoEl=new Ext.util.ProtoElement();a.initConfig(b);if(a.scrollable==null){g=a.autoScroll;if(g){f=!!g}else {c=a.overflowX;d=a.overflowY;if(c||d){f={x:c&&c!=='hidden'?c:!1,y:d&&d!=='hidden'?d:!1}}}if(f){a.setScrollable(f)}}i=a.xhooks;if(i){delete a.xhooks;Ext.override(a,i)}a.mixins.elementCt.constructor.call(a);a.setupProtoEl();if(a.cls){a.initialCls=a.cls;a.protoEl.addCls(a.cls)}if(a.style){a.initialStyle=a.style;a.protoEl.setStyle(a.style)}a.renderData=a.renderData||{};a.initComponent();if(!a.preventRegister){Ext.ComponentManager.register(a)}a.mixins.state.constructor.call(a);a.addStateEvents('resize');h=a.getController();if(h){h.init(a)}if(a.plugins){for(e=0,j=a.plugins.length;eh){o=j;f=!0}if(e&&k>i){p=k;f=!0}if(d||e){g=a.el.getStyle('overflow');if(g!=='hidden'){a.el.setStyle('overflow','hidden')}}if(f){r=!Ext.isNumber(a.width);q=!Ext.isNumber(a.height);a.setSize(p,o);a.el.setSize(i,h);if(r){delete a.width}if(q){delete a.height}}if(e){c.width=k}if(d){c.height=j}}n=a.constrain;l=a.constrainHeader;if(n||l){a.constrain=a.constrainHeader=!1;m=b.callback;b.callback=function(){a.constrain=n;a.constrainHeader=l;if(m){m.call(b.scope||a,arguments)}if(g!=='hidden'){a.el.setStyle('overflow',g)}}}return a.mixins.animate.animate.apply(a,arguments)},applyScrollable:function(a,c){var b=this,f=b.rendered,e,d;if(a){if(a===!0||typeof a==='string'){e=b._scrollableCfg[a];a=e}if(c){c.setConfig(a);a=c}else {a=Ext.Object.chain(a);if(f){a.element=b.getOverflowEl();d=b.getScrollerEl();if(d){a.innerElement=d}}a.autoRefresh=!1;if(Ext.supports.touchScroll===1){a.translatable={translationMethod:'scrollparent'};a.indicators=!1}a=Ext.scroll.Scroller.create(a);a.component=b}}else {if(c){c.setConfig({x:!1,y:!1});c.destroy();a=null}}if(b.rendered&&!b.destroying&&!b.destroyed){if(a){b.getOverflowStyle()}else {b.scrollFlags=b._scrollFlags.none}b.updateLayout()}return a},beforeComponentLayout:function(){return !0},beforeDestroy:Ext.emptyFn,beforeLayout:function(){if(this.floating){this.onBeforeFloatLayout()}},beforeSetPosition:function(a,b,f){var d=this,c=null,e,g,h,i;if(a){if(Ext.isNumber(e=a[0])){f=b;b=a[1];a=e}else {if((e=a.x)!==undefined){f=b;b=a.y;a=e}}}if(d.constrain||d.constrainHeader){c=d.calculateConstrainedPosition(null,[a,b],!0);if(c){a=c[0];b=c[1]}}g=a!==undefined;h=b!==undefined;if(g||h){d.x=a;d.y=b;i=d.adjustPosition(a,b);c={x:i.x,y:i.y,anim:f,hasX:g,hasY:h}}return c},beforeShow:Ext.emptyFn,bubble:function(d,b,c){var a=this;while(a){if(d.apply(b||a,c||[a])===!1){break}a=a.getBubbleTarget()}return this},clearListeners:function(){var a=this;a.mixins.observable.clearListeners.call(a);a.mixins.componentDelegation.clearDelegatedListeners.call(a)},cloneConfig:function(a){a=a||{};var d=a.id||Ext.id(),c=Ext.applyIf(a,this.initialConfig),b;c.id=d;b=Ext.getClass(this);return new b(c)},destroy:function(){var a=this,d=a.renderSelectors,f=a.getConfig('viewModel',!0),g=a.getConfig('session',!0),b,c,e;if(!a.hasListeners.beforedestroy||a.fireEvent('beforedestroy',a)!==!1){a.isDestroying=a.destroying=!0;c=a.floatParent||a.ownerCt;if(a.floating){delete a.floatParent;if(a.zIndexManager){a.zIndexManager.unregister(a);a.zIndexManager=null}}a.removeBindings();a.beforeDestroy();a.destroyBindable();if(c&&c.remove){c.remove(a,!1)}a.stopAnimation();a.onDestroy();Ext.destroy(a.plugins);if(a.rendered){Ext.Component.cancelLayout(a,!0)}a.componentLayout=null;if(a.hasListeners.destroy){a.fireEvent('destroy',a)}if(!a.preventRegister){Ext.ComponentManager.unregister(a)}a.mixins.state.destroy.call(a);if(a.floating){a.onFloatDestroy()}a.clearListeners();if(a.rendered){if(!a.preserveElOnDestroy){a.el.destroy()}a.el.component=null;a.mixins.elementCt.destroy.call(a);if(d){for(b in d){if(d.hasOwnProperty(b)){e=a[b];if(e){delete a[b];e.destroy()}}}}a.data=a.el=a.frameBody=a.rendered=a.afterRenderEvents=null;a.tpl=a.renderTpl=a.renderData=null;a.focusableContainer=a.container=a.scrollable=null}a.isDestroying=a.destroying=!1;a.callParent()}},disable:function(e,d){var a=this,b=a.focusableContainer,c=a.getInherited();if(!d){c.disabled=!0;a.savedDisabled=!0}if(a.maskOnDisable){c.disableMask=!0}if(!a.disabled){if(b){b.beforeFocusableChildDisable(a)}a.addCls(a.disabledCls);if(a.rendered){a.onDisable()}else {a.disableOnRender=!0}a.disabled=!0;if(e!==!0){a.fireEvent('disable',a)}if(b){b.onFocusableChildDisable(a)}}return a},doFireEvent:function(c,d,e){var a=this,b=a.mixins.observable.doFireEvent.call(a,c,d,e);if(b!==!1){b=a.mixins.componentDelegation.doFireDelegatedEvent.call(a,c,d)}return b},enable:function(e,c){var a=this,b=a.focusableContainer,d=a.getInherited();if(!c){delete a.getInherited().disabled;a.savedDisabled=!1}if(a.maskOnDisable){delete d.disableMask}if(a.disabled){if(!(c&&d.hasOwnProperty('disabled'))){if(b){b.beforeFocusableChildEnable(a)}a.disableOnRender=!1;a.removeCls(a.disabledCls);if(a.rendered){a.onEnable()}a.disabled=!1;if(e!==!0){a.fireEvent('enable',a)}if(b){b.onFocusableChildEnable(a)}}}return a},findParentBy:function(b){var a;for(a=this.getRefOwner();a&&!b(a,this);a=a.getRefOwner()){}return a||null},findParentByType:function(a){return Ext.isFunction(a)?this.findParentBy(function(b){return b.constructor===a}):this.up(a)},findPlugin:function(c){var a,b=this.plugins,d=b&&b.length;for(a=0;a-1;e--){b=g[e];if(b.query){a=b.query(c);a=a[a.length-1];if(a){return a}}if(b.is(c)){return b}}return f.previousNode(c,!0)}return null},previousSibling:function(c){var e=this.ownerCt,b,a,d;if(e){b=e.items;a=b.indexOf(this);if(a!==-1){if(c){for(--a;a>=0;a--){if((d=b.getAt(a)).is(c)){return d}}}else {if(a){return b.getAt(--a)}}}}return null},registerFloatingItem:function(b){var a=this;if(!a.floatingDescendants){a.floatingDescendants=new Ext.ZIndexManager(a)}a.floatingDescendants.register(b)},removeCls:function(c){var a=this,b=a.rendered?a.el:a.protoEl;b.removeCls.apply(b,arguments);return a},removeClsWithUI:function(a,k){var b=this,d=[],e=0,g=Ext.Array,i=g.remove,j=b.uiCls=g.clone(b.uiCls),f=b.activeUI,h,c;if(typeof a==='string'){a=a.indexOf(' ')<0?[a]:Ext.String.splitWords(a)}h=a.length;for(e=0;e1){arguments[0]=null;a.pendingShow=arguments}else {a.pendingShow=!0}}else {if(b&&a.isVisible()){if(a.floating){a.onFloatShow()}}else {if(a.fireEvent('beforeshow',a)!==!1){a.hidden=!1;delete this.getInherited().hidden;Ext.suspendLayouts();if(!b&&(a.autoRender||a.floating)){a.doAutoRender();b=a.rendered}if(b){a.beforeShow();Ext.resumeLayouts();a.onShow.apply(a,arguments);a.afterShow.apply(a,arguments)}else {Ext.resumeLayouts(!0)}}else {a.onShowVeto()}}}return a},showAt:function(b,c,d){var a=this;if(!a.rendered&&(a.autoRender||a.floating)){a.x=b;a.y=c;return a.show()}if(a.floating){a.setPosition(b,c,d)}else {a.setPagePosition(b,c,d)}return a.show()},showBy:function(b,d,c){var a=this;if(a.floating&&b){a.alignTarget=b;if(d){a.defaultAlign=d}if(c){a.alignOffset=c}a.show();if(!a.hidden){a.alignTo(b,d||a.defaultAlign,c||a.alignOffset)}}return a},suspendLayouts:function(){var a=this;if(!a.rendered){return}if(++a.layoutSuspendCount===1){a.suspendLayout=!0}},unitizeBox:function(a){return Ext.Element.unitizeBox(a)},unmask:function(){(this.getMaskTarget()||this.el).unmask();this.setMasked(!1)},unregisterFloatingItem:function(b){var a=this;if(a.floatingDescendants){a.floatingDescendants.unregister(b)}},up:function(c,b){var a=this.getRefOwner(),f=typeof b==='string',g=typeof b==='number',e=b&&b.isComponent,d=0;if(c){for(;a;a=a.getRefOwner()){d++;if(c.isComponent){if(a===c){return a}}else {if(Ext.ComponentQuery.is(a,c)){return a}}if(f&&a.is(b)){return}if(g&&d===b){return}if(e&&a===b){return}}}return a},update:function(b,i,k,j){var a=this,h=a.tpl&&!Ext.isString(b),g=a.getScrollable(),f=a.focusableContainer,e,c,d;if(h){a.data=b&&b.isEntity?b.getData(!0):b}else {a.html=Ext.isObject(b)?Ext.DomHelper.markup(b):b}if(a.rendered){e=a.getSizeModel();c=e.width.shrinkWrap||e.height.shrinkWrap;if(a.isContainer){d=a.layout.getRenderTarget();c=c||a.items.items.length>0}else {d=a.touchScroll?a.getScrollerEl():a.getTargetEl()}if(h){a.tpl[a.tplWriteMode](d,a.data||{})}else {d.setHtml(a.html,i,k,j||a)}if(c){a.updateLayout()}if(g){g.refresh(!0)}if(f){f.onFocusableChildUpdate(a)}}},setHtml:function(c,a,b){this.update(c,a,null,b)},applyData:function(a){this.update(a)},updateBox:function(a){this.setSize(a.width,a.height);this.setPagePosition(a.x,a.y);return this},_asLayoutRoot:{isRoot:!0},_notAsLayoutRoot:{isRoot:!1},updateLayout:function(b){var a=this,e,d=a.lastBox,c=b&&b.isRoot;if(d){d.invalid=!0}if(!a.rendered||a.layoutSuspendCount||a.suspendLayout){return}if(a.hidden){Ext.Component.cancelLayout(a)}else {if(typeof c!=='boolean'){c=a.isLayoutRoot()}}if(c||!a.ownerLayout||!a.ownerLayout.onContentChange(a)){if(!a.isLayoutSuspended()){e=b&&b.hasOwnProperty('defer')?b.defer:a.deferLayouts;Ext.Component.updateLayout(a,e)}}},updateMaxHeight:function(b,a){this.changeConstraint(b,a,'min','max-height','height')},updateMaxWidth:function(b,a){this.changeConstraint(b,a,'min','max-width','width')},updateMinHeight:function(b,a){this.changeConstraint(b,a,'max','min-height','height')},updateMinWidth:function(b,a){this.changeConstraint(b,a,'max','min-width','width')},getAnchorToXY:function(d,a,c,b){return d.getAnchorXY(a,c,b)},getBorderPadding:function(){return this.el.getBorderPadding()},getLocalX:function(){return this.el.getLocalX()},getLocalXY:function(){return this.el.getLocalXY()},getLocalY:function(){return this.el.getLocalY()},getX:function(){return this.el.getX()},getXY:function(){return this.el.getXY()},getY:function(){return this.el.getY()},setLocalX:function(a){this.el.setLocalX(a)},setLocalXY:function(a,b){this.el.setLocalXY(a,b)},setLocalY:function(a){this.el.setLocalY(a)},setX:function(b,a){this.el.setX(b,a)},setXY:function(b,a){this.el.setXY(b,a)},setY:function(b,a){this.el.setY(b,a)},privates:{addOverCls:function(){var a=this;if(!a.disabled){a.el.addCls(a.overCls)}},addUIToElement:function(){var a=this,d=a.baseCls+'-'+a.ui,e,c,f,b;a.addCls(d);if(a.rendered&&a.frame&&!Ext.supports.CSS3BorderRadius){d+='-';e=a.getChildEls();for(c in e){b=e[c].frame;if(b&&b!==!0){f=a[c];if(f){f.addCls(d+b)}}}}},changeConstraint:function(b,g,f,c,d){var a=this,e=a[d];if(b!=null&&typeof e==='number'){a[d]=Math[f](e,b)}if(a.liquidLayout){if(b!=null){a.setStyle(c,b+'px')}else {if(g){a.setStyle(c,'')}}}if(a.rendered){a.updateLayout()}},constructPlugin:function(a){var b=this;if(typeof a==='string'){a=Ext.PluginManager.create({},a,b)}else {a=Ext.PluginManager.create(a,null,b)}return a},constructPlugins:function(){var d=this,a=d.plugins,c,b,e;if(a){c=[];c.processed=!0;if(!Ext.isArray(a)){a=[a]}for(b=0,e=a.length;b=0){h=m[c].splitterDelta;if(e.getAt(d+h)!==b){e.remove(b);d=e.indexOf(a);if(h>0){++d}e.insert(d,b)}}}if(j){if(l){a.expand(!1)}i.remove(j);a.placeholder=null;if(l){a.collapse(null,!1)}}i.updateLayout();Ext.resumeLayouts(!0);a.fireEventArgs('changeregion',[a,g])}else {a.region=c}}return g},setWeight:function(b){var a=this,e=a.getOwningBorderContainer(),d=a.placeholder,c=a.weight;if(b!==c){if(a.fireEventArgs('beforechangeweight',[a,b])!==!1){a.weight=b;if(d){d.weight=b}if(e){e.updateLayout()}a.fireEventArgs('changeweight',[a,c])}}return c}},function(b){var a=b.prototype;a.setBorderRegion=a.setRegion;a.setRegionWeight=a.setWeight});Ext.define('Ext.theme.neptune.Component',{override:'Ext.Component',initComponent:function(){arguments.callee.$previous.call(this);if(this.dock&&this.border===undefined){this.border=!1}},privates:{initStyles:function(){var a=this,b=a.hasOwnProperty('border'),c=a.border;if(a.dock){a.border=null}arguments.callee.$previous.apply(this,arguments);if(b){a.border=c}else {delete a.border}}}},function(){Ext.namespace('Ext.theme.is').Neptune=!0;Ext.theme.name='Neptune'});Ext.define('Ext.theme.crisp.Component',{override:'Ext.Component'},function(){Ext.namespace('Ext.theme.is').Crisp=!0;Ext.theme.name='Crisp'});Ext.define('Ext.overrides.app.domain.Component',{override:'Ext.app.domain.Component'},function(a){a.monitor(Ext.Component)});Ext.cmd.derive('Ext.app.EventBus',Ext.Base,{singleton:!0,constructor:function(){var a=this,b=Ext.app.EventDomain.instances;a.callParent();a.domains=b;a.bus=b.component.bus},control:function(b,a){return this.domains.component.listen(b,a)},listen:function(b,c){var d=this.domains,a;for(a in b){if(b.hasOwnProperty(a)){d[a].listen(b[a],c)}}},unlisten:function(c){var a=Ext.app.EventDomain.instances,b;for(b in a){a[b].unlisten(c)}}},1,0,0,0,0,0,[Ext.app,'EventBus'],0);Ext.cmd.derive('Ext.app.domain.Global',Ext.app.EventDomain,{singleton:!0,type:'global',constructor:function(){var a=this;a.callParent();a.monitor(Ext.GlobalEvents)},listen:function(b,a){this.callParent([{global:b},a])},match:Ext.returnTrue},1,0,0,0,0,0,[Ext.app.domain,'Global'],0);Ext.cmd.derive('Ext.app.BaseController',Ext.Base,{isController:!0,config:{id:null,control:null,listen:null,routes:null,before:null},constructor:function(b){var a=this;Ext.apply(a,b);delete a.control;delete a.listen;a.eventbus=Ext.app.EventBus;a.mixins.observable.constructor.call(a,b);a.ensureId()},applyListen:function(a){if(Ext.isObject(a)){a=Ext.clone(a)}return a},applyControl:function(a){if(Ext.isObject(a)){a=Ext.clone(a)}return a},updateControl:function(a){this.ensureId();if(a){this.control(a)}},updateListen:function(a){this.ensureId();if(a){this.listen(a)}},updateRoutes:function(b){if(b){var e=this,f=e.getBefore()||{},g=Ext.app.route.Router,c,a,d;for(c in b){a=b[c];if(Ext.isString(a)){a={action:a}}d=a.action;if(!a.before){a.before=f[d]}g.connect(c,a,e)}}},isActive:function(){return !0},control:function(b,c,f){var e=this,d=f,a;if(Ext.isString(b)){a={};a[b]=c}else {a=b;d=c}e.eventbus.control(a,d||e)},listen:function(b,a){this.eventbus.listen(b,a||this)},destroy:function(){var a=this,b=a.eventbus;Ext.app.route.Router.disconnectAll(a);if(b){b.unlisten(a);a.eventbus=null}a.callParent()},redirectTo:function(a,c){if(a.isModel){a=a.toUrl()}if(!c){var b=Ext.util.History.getToken();if(b===a){return !1}}else {Ext.app.route.Router.onStateChange(a)}Ext.util.History.add(a);return !0}},1,0,0,0,0,[[Ext.mixin.Observable.prototype.mixinId||Ext.mixin.Observable.$className,Ext.mixin.Observable]],[Ext.app,'BaseController'],0);Ext.cmd.derive('Ext.app.Util',Ext.Base,{},0,0,0,0,0,0,[Ext.app,'Util'],function(){Ext.apply(Ext.app,{namespaces:{Ext:{}},addNamespaces:function(a){var d=Ext.app.namespaces,b,c;if(!Ext.isArray(a)){a=[a]}for(b=0,c=a.length;bb.length&&a+'.'===d.substring(0,a.length+1)){b=a}}return b===''?undefined:b},setupPaths:function(e,b,c){var a=Ext.manifest,d;if(e&&b!==null){a=a&&a.paths;if(!a||b!==undefined){Ext.Loader.setPath(e,b===undefined?'app':b)}}if(c){for(d in c){if(c.hasOwnProperty(d)){Ext.Loader.setPath(d,c[d])}}}}});Ext.getNamespace=Ext.app.getNamespace});Ext.cmd.derive('Ext.util.CollectionKey',Ext.Base,{isCollectionKey:!0,observerPriority:-200,config:{collection:null,keyFn:null,property:null,rootProperty:null,unique:!0},generation:0,map:null,mapRebuilds:0,constructor:function(a){this.initConfig(a)},get:function(a){var b=this.map||this.getMap();return b[a]||null},clear:function(){this.map=null},getRootProperty:function(){var b=this,a=(arguments.callee.$previous||Ext.Base.prototype.getRootProperty).call(this);return a!==null?a:b.getCollection().getRootProperty()},indexOf:function(i,b){var j=this.map||this.getMap(),c=j[i],e=this.getCollection(),h=e.length,d,a,f,g;if(!c){return -1}if(b===undefined){b=-1}if(c instanceof Array){f=c;a=h;for(g=f.length;g-->0;){d=e.indexOf(f[g]);if(db){a=d}}if(a===h){return -1}}else {a=e.indexOf(c)}return a>b?a:-1},updateKey:function(e,d){var f=this,c=f.map,a,b;if(c){a=c[d];if(a instanceof Array){b=Ext.Array.indexOf(a,e);if(b>=0){if(a.length>2){a.splice(b,1)}else {c[d]=a[1-b]}}}else {if(a){delete c[d]}}f.add([e])}},onCollectionAdd:function(b,a){if(this.map){this.add(a.items)}},onCollectionItemChange:function(a,b){this.map=null},onCollectionRefresh:function(){this.map=null},onCollectionRemove:function(g,h){var a=this,f=a.map,d=h.items,c=d.length,b,i,e;if(f){if(a.getUnique()&&cb?1:a0&&a.getAutoSort(),r=a.getSource(),q=0,g=!1,o=!1,e,l,k,m,b,d;if(r&&!r.updating){r.itemChanged(c,p,f,u)}else {l=a.getKey(c);if(s){b=a.indexOfKey(j?f:l);o=b<0;g=a.isItemFiltered(c);n=o!==g}if(n){if(g){q=[c];d=-1}else {m=[c];d=a.length}}else {if(v&&!g){if(!s){b=a.indexOfKey(j?f:l)}k=a.getSortFn();if(b!==-1){if(b&&k(i[b-1],i[b])>0){h=-1;d=Ext.Array.binarySearch(i,c,0,b,k)}else {if(b0){h=1;d=Ext.Array.binarySearch(i,c,b+1,k)}}if(h){m=[c]}}}}e={item:c,key:l,index:d,filterChanged:n,keyChanged:j,indexChanged:!!h,filtered:g,oldIndex:b,newIndex:d,wasFiltered:o,meta:u};if(j){e.oldKey=f}if(p){e.modified=p}a.beginUpdate();a.notify('beforeitemchange',[e]);if(j){a.updateKey(c,f)}if(m||q){a.splice(d,q,m)}if(h>0){e.newIndex--}else {if(h<0){e.oldIndex++}}a.notify(g?'filtereditemchange':'itemchange',[e]);a.endUpdate()}},remove:function(d){var a=this,c=a.decodeRemoveItems(arguments,0),b=a.length;a.splice(0,c);return b-a.length},removeAll:function(){var a=this,b=a.length;if(a.generation&&b){a.splice(0,b)}return a},removeAt:function(j,f){var a=this,e=a.length,i=Ext.Number,g=i.clipIndices(e,[j,f===undefined?1:f],i.Clip.COUNT),c=g[0],d=g[1]-c,h=d===1&&a.getAt(c),b;a.splice(c,d);b=a.length-e;return h&&b?h:b},removeByKey:function(b){var a=this.getByKey(b);if(!a||!this.remove(a)){return !1}return a},replace:function(a){var b=this.indexOf(a);if(b===-1){this.add(a)}else {this.insert(b,a)}},splice:function(K,E,L){var b=this,D=b.sorted&&b.getAutoSort(),F=b.map,o=b.items,r=b.length,n=E instanceof Array?b.decodeRemoveItems(E):null,G=!n,J=Ext.Number,I=J.clipIndices(r,[K,G?E:0],J.Clip.COUNT),m=I[0],v=I[1],x=v-m,p=b.decodeItems(arguments,2),h=p?p.length:0,c,A,C,d=m,k=b.indices||(h||n?b.getIndices():null),e=null,i=x?[m]:null,l=null,t=b.getSource(),j,B,z,a,u,g,w,f,s,q,y,H,v;if(t&&!t.updating){if(G){n=[];for(a=0;a1){if(!c.$cloned){p=c=c.slice(0)}b.sortData(c)}}for(a=0;a0;){f=b.getKey(n[a]);if((g=k[f])!==undefined){(i||(i=[])).push(g)}}if(!e&&!i){return b}b.beginUpdate();if(i){j=null;z=[];C={};if(i.length>1){i.sort(Ext.Array.numericSortFn)}for(a=0,q=i.length;aj.at+B.length){z.push(j={at:g,items:B=[],keys:s=[],map:C,next:j,replacement:e});if(e){e.replaced=j}}B.push(C[f]=u);s.push(f);if(g1&&g===m){--x;i[a--]=++m}}if(e){e.at=d}for(w=z.length;w-->0;){j=z[w];a=j.at;q=j.items.length;if(a+q1&&r){b.spliceMerge(c,l)}else {if(D){if(h>1){d=0;b.indices=k=null}else {d=H.findInsertionIndex(e.items[0],o,b.getSortFn())}}if(d===r){v=d;for(a=c.length-1;a>=0;--a){o[v+a]=c[a]}k=b.indices;if(k){for(a=0;a-1){c=e[b];a=this.indexOf(c);if(a>-1){return a+1}--b}return 0},onCollectionAdd:function(l,i){var a=this,j=i.atItem,d=i.items,h=a.requestedIndex,c,b,e,f,g,k;if(!a.sorted){if(h!==undefined){b=h}else {if(j){b=a.indexOf(j);if(b===-1){b=a.findInsertIndex(d[0])}else {++b}}else {b=0}}}if(a.getAutoFilter()&&a.filtered){for(f=0,k=d.length;fc)){c=a}}return [c,b]},count:function(a){return a.length},extremes:function(k,j,l,i,f){var e=null,d=null,c,b,g,h,a;for(c=j;ch)){h=a;d=b}}return [d,e]},max:function(c,b,e,a,d){var f=this._aggregators.bounds.call(this,c,b,e,a,d);return f[1]},maxItem:function(c,b,e,a,d){var f=this._aggregators.extremes.call(this,c,b,e,a,d);return f[1]},min:function(c,b,e,a,d){var f=this._aggregators.bounds.call(this,c,b,e,a,d);return f[0]},minItem:function(c,b,e,a,d){var f=this._aggregators.extremes.call(this,c,b,e,a,d);return f[0]},sum:function(g,f,h,e,c){for(var a,d=0,b=f;b1){Ext.Array.sort(a,b.prioritySortFn)}},prioritySortFn:function(a,b){var c=a.observerPriority||0,d=b.observerPriority||0;return c-d},applyExtraKeys:function(e,g){var d=this,f=g||{},b,c,a;for(c in e){a=e[c];if(!a.isCollectionKey){b={collection:d};if(Ext.isString(a)){b.property=a}else {b=Ext.apply(b,a)}a=new Ext.util.CollectionKey(b)}else {a.setCollection(d)}f[c]=d[c]=a;a.name=c}return f},applyGrouper:function(a){if(a){a=this.getSorters().decodeSorter(a,'Ext.util.Grouper')}return a},decodeItems:function(e,d){var g=this,a=d===undefined?e:e[d],b,f,c;if(!a||!a.$cloned){b=e.length>d+1||!Ext.isIterable(a);if(b){a=Ext.Array.slice(e,d);if(a.length===1&&a[0]===undefined){a.length=0}}f=g.getDecoder();if(f){if(!b){a=a.slice(0);b=!0}for(c=a.length;c-->0;){if((a[c]=f.call(g,a[c]))===!1){a.splice(c,1)}}}if(b){a.$cloned=!0}}return a},getIndices:function(){var a=this,c=a.indices,d=a.items,f=d.length,b,e;if(!c){a.indices=c={};++a.indexRebuilds;for(b=0;b0;if(d||c){b.filtered=c;b.onFilterChange(a)}},getSortFn:function(){return this._sortFn||this.createSortFn()},getSorters:function(b){var a=this._sorters;if(!a&&b!==!1){a=new Ext.util.SorterCollection();this.setSorters(a)}return a},onSortChange:function(){if(this.sorted){this.sortItems()}},sort:function(c,b,d){var a=this.getSorters();a.addSort.apply(a,arguments);return this},sortData:function(a){Ext.Array.sort(a,this.getSortFn());return a},sortItems:function(b){var a=this;if(a.sorted){b=a.getSortFn()}a.indices=null;a.notify('beforesort',[a.getSorters(!1)]);if(a.length){Ext.Array.sort(a.items,b)}a.notify('sort')},sortBy:function(a){return this.sortItems(a)},findInsertionIndex:function(c,b,a){if(!b){b=this.items}if(!a){a=this.getSortFn()}return Ext.Array.binarySearch(b,c,a)},applySorters:function(a,b){if(a==null||a&&a.isSorterCollection){return a}if(a){if(!b){b=this.getSorters()}b.splice(0,b.length,a)}return b},createSortFn:function(){var d=this,b=d.getGrouper(),c=d.getSorters(!1),a=c?c.getSortFn():null;if(!b){return a}return function(d,e){var c=b.sort(d,e);if(!c&&a){c=a(d,e)}return c}},updateGrouper:function(c){var a=this,b=a.getGroups(),e=a.getSorters(),d;a.onSorterChange();a.grouped=!!c;if(c){if(a.getTrackGroups()){if(!b){b=new Ext.util.GroupCollection({itemRoot:a.getRootProperty()});b.$groupable=a;a.setGroups(b)}b.setGrouper(c);d=!0}}else {if(b){a.removeObserver(b);b.destroy()}a.setGroups(null)}if(!e.updating){a.onEndUpdateSorters(e)}if(d){b.onCollectionRefresh(a)}},updateSorters:function(b,c){var a=this;if(c){c.un('endupdate','onEndUpdateSorters',a)}if(b){b.on({endupdate:'onEndUpdateSorters',scope:a,priority:a.$endUpdatePriority});b.$sortable=a}a.onSorterChange();a.onEndUpdateSorters(b)},onSorterChange:function(){this._sortFn=null},onEndUpdateSorters:function(b){var a=this,d=a.sorted,c=a.grouped&&a.getAutoGroup()||b&&b.length>0;if(d||c){a.sorted=!!c;a.onSortChange(b)}},removeObserver:function(b){var a=this.observers;if(a){Ext.Array.remove(a,b)}},spliceMerge:function(i,q){var f=this,r=f.map,k=i.length,g=0,n=f.items,m=n.length,h=[],c=0,a=[],p=f.getSortFn(),l,j,d,b,o,e;f.items=a;for(e=0;e1){h[c-2].next=h[c-1]}for(;e1){h[c-2].next=h[c-1]}a.push(b);for(j=e+1;j=0){break}a.push(b);l.push(b)}}for(;g0)}e=j.createAssociationStore(i,f,b,h);e.$source=q;if(!b&&(j.autoLoad||a)){n=!0}f[m]=e}if(a){if(n||e.isLoading()){e.on('load',function(h,i,e,g){d=[h,g];c=c||a.scope||f;if(e){Ext.callback(a.success,c,d)}else {Ext.callback(a.failure,c,d)}d.push(e);Ext.callback(a,c,d);Ext.callback(a.callback,c,d)},null,{single:!0})}else {d=[e,null];c=c||a.scope||f;Ext.callback(a.success,c,d);d.push(!0);Ext.callback(a,c,d);Ext.callback(a.callback,c,d)}}if(n&&!e.isLoading()){e.load()}return e},getAssociatedItem:function(b){var a=this.isMany?this.getStoreName():this.getInstanceName();return b[a]||null},onDrop:Ext.emptyFn,getReaderRoot:function(){var a=this;return a.associationKey||(a.associationKey=a.association.schema.getNamer().readerRoot(a.role))},getReader:function(){var b=this,a=b.reader,d=b.cls,c=!b.associationKey,e=this.getReaderRoot();if(a&&!a.isReader){if(Ext.isString(a)){a={type:a}}Ext.applyIf(a,{model:d,rootProperty:e,useSimpleAccessors:c,type:b.defaultReaderType});a=b.reader=Ext.createByAlias('reader.'+a.type,a)}return a},getInstanceName:function(){var a=this;return a.instanceName||(a.instanceName=a.association.schema.getNamer().instanceName(a.role))},getOldInstanceName:function(){return this.oldInstanceName||(this.oldInstanceName='$old'+this.getInstanceName())},getStoreName:function(){var a=this;return a.storeName||(a.storeName=a.association.schema.getNamer().storeName(a.role))},constructReader:function(h){var b=this,a=b.getReader(),e=b.cls,g=!b.associationKey,f=b.getReaderRoot(),c,d;if(!a){d=e.getProxy();if(d){c=d.getReader();a=new c.self();a.copyFrom(c);a.setRootProperty(f)}else {a=new h.self({model:e,useSimpleAccessors:g,rootProperty:f})}b.reader=a}return a},read:function(f,e,d,c){var a=this.constructReader(d),b=a.getRoot(e);if(b){return a.readRecords(b,c,this._internalReadOptions)}},getCallbackOptions:function(a,c,b){if(typeof a==='function'){a={callback:a,scope:c||b}}else {if(a){a=Ext.apply({},a);a.scope=c||a.scope||b}}return a},doGetFK:function(d,b,f){var i=this,l=i.cls,j=i.association.getFieldName(),h=i.getInstanceName(),a=d[h],m=b&&b.reload,e=a!==undefined&&!m,k=d.session,c,g;if(!e){if(k){c=d.get(j);if(c||c===0){e=k.peekRecord(l,c,!0)&&!m;a=k.getRecord(l,c,!1)}else {e=!0;d[h]=a=null}}else {if(j){c=d.get(j);if(!c&&c!==0){e=!0;d[h]=a=null}else {if(!a){a=l.createWithId(c)}}}else {e=!0}}}else {if(a){e=!a.isLoading()}}if(e){if(b){g=[a,null];f=f||b.scope||d;Ext.callback(b.success,f,g);g.push(!0);Ext.callback(b,f,g);Ext.callback(b.callback,f,g)}}else {d[h]=a;b=i.getCallbackOptions(b,f,d);a.load(b)}return a},doSetFK:function(a,c,e,l){var f=this,i=f.association.getFieldName(),h=f.getInstanceName(),b=a[h],d=f.inverse,j=d.setterName,m=a.session,k,g;if(c&&c.isEntity){if(b!==c){g=f.getOldInstanceName();a[g]=b;a[h]=c;if(b&&b.isEntity){b[d.getInstanceName()]=undefined}if(i){a.set(i,c.getId())}delete a[g];if(j){c[j](a)}}}else {k=a.changingKey&&!d.isMany||a.set(i,c);if(k&&b&&b.isEntity&&!b.isEqual(b.getId(),c)){a[h]=undefined;if(!d.isMany){b[d.getInstanceName()]=undefined}}}if(e){if(Ext.isFunction(e)){e={callback:e,scope:l||a}}return a.save(e)}}},1,0,0,0,0,0,[Ext.data.schema,'Role'],0);Ext.cmd.derive('Ext.data.schema.Association',Ext.Base,{isOneToOne:!1,isManyToOne:!1,isManyToMany:!1,owner:null,field:null,constructor:function(d){var a=this,c,b;Ext.apply(a,d);a.left=c=new a.Left(a,a.left);a.right=b=new a.Right(a,a.right);c.inverse=b;b.inverse=c},hasField:function(){return !!this.field},getFieldName:function(){var a=this.field;return a?a.name:''}},1,0,0,0,0,0,[Ext.data.schema,'Association'],0);Ext.cmd.derive('Ext.data.schema.OneToOne',Ext.data.schema.Association,{isOneToOne:!0,isToOne:!0,kind:'one-to-one',Left:Ext.define(null,{extend:'Ext.data.schema.Role',onDrop:function(a,c){var b=this.getAssociatedItem(a);a[this.getInstanceName()]=null;if(b){b[this.inverse.getInstanceName()]=null}},createGetter:function(){var a=this;return function(){return a.doGet(this)}},createSetter:function(){var a=this;return function(b){return a.doSet(this,b)}},doGet:function(a){var c=this.getInstanceName(),b=a[c],d=a.session;if(!b&&d){}return b||null},doSet:function(a,b){var d=this.getInstanceName(),e=a[d],c=this.inverse.setterName;if(e!==b){a[d]=b;if(c){b[c](a)}}return e},read:function(a,g,f,e){var c=this,d=c.callParent([a,g,f,e]),b;if(d){b=d[0];if(b){b[c.inverse.getInstanceName()]=a;a[c.getInstanceName()]=b;delete a.data[c.role]}}}}),Right:Ext.define(null,{extend:'Ext.data.schema.Role',left:!1,side:'right',createGetter:function(){var a=this;return function(b,c){return a.doGetFK(this,b,c)}},createSetter:function(){var a=this;return function(d,b,c){return a.doSetFK(this,d,b,c)}},onDrop:function(c,f){var b=this,e=b.association.field,a=b.getAssociatedItem(c),d;if(b.inverse.owner){if(f){d=c.get(e.name);if(d||d===0){a=f.getEntry(b.cls,d).record;if(a){a.drop()}}}else {if(a){a.drop()}}}if(e){c.set(e.name,null)}c[b.getInstanceName()]=null;if(a){a[b.inverse.getInstanceName()]=null}},onValueChange:function(b,f,c){var a=this,e=b[a.getOldInstanceName()]||a.getAssociatedItem(b),h=c||c===0,d=a.getInstanceName(),g=a.cls;b.changingKey=!0;a.doSetFK(b,c);if(!h){b[d]=null}else {if(f&&g){b[d]=f.peekRecord(g,c)||undefined}}if(a.inverse.owner&&e){a.association.schema.queueKeyCheck(e,a)}b.changingKey=!1},checkKeyForDrop:function(a){var b=this.inverse.getAssociatedItem(a);if(!b){a.drop()}},read:function(a,o,n,m){var f=this,l=f.callParent([a,o,n,m]),b,d,g,c,k,h,j,i,e;if(l){b=l[0];d=f.association.field;if(d){g=d.name}c=a.session;e=a.data;if(b){if(c){k=c.getRefs(b,this.inverse,!0);i=k&&k[a.id]||e[g]===undefined}else {i=!0}if(i){if(d){j=e[g];h=b.id;if(j!==h){e[g]=h;if(c){c.updateReference(a,d,h,j)}}}b[f.inverse.getInstanceName()]=a;a[f.getInstanceName()]=b}delete e[f.role]}}}})},0,0,0,0,0,0,[Ext.data.schema,'OneToOne'],0);Ext.cmd.derive('Ext.data.schema.ManyToOne',Ext.data.schema.Association,{isManyToOne:!0,isToOne:!0,kind:'many-to-one',Left:Ext.define(null,{extend:'Ext.data.schema.Role',isMany:!0,onDrop:function(d,f){var b=this,e=b.getAssociatedItem(d),a,g,c,i,h;if(e){a=e.removeAll();if(a&&b.inverse.owner){for(c=0,g=a.length;c0){a=c[h];e=!a.isEqual(l,a.get(i));b=f?null:d;if(e!==f){a.changingKey=!0;a[k](b);a.changingKey=!1}else {a[j]=b}}}}),Right:Ext.define(null,{extend:'Ext.data.schema.Role',left:!1,side:'right',onDrop:function(a,c){var b=this.association.field;if(b){a.set(b.name,null)}a[this.getInstanceName()]=null},createGetter:function(){var a=this;return function(b,c){return a.doGetFK(this,b,c)}},createSetter:function(){var a=this;return function(b,c,d){return a.doSetFK(this,b,c,d)}},checkMembership:function(c,b){var d=this.association.field,a;a=this.getSessionStore(c,b.get(d.name));if(a&&!a.contains(b)){a.add(b)}},onValueChange:function(b,f,d,l){var c=this,j=c.getInstanceName(),m=c.cls,i,g,a,h,n,e,k;if(!b.changingKey){i=d||d===0;if(!i){b[j]=null}if(f){a=c.getSessionStore(f,l);if(a){a.remove(b)}if(i){a=c.getSessionStore(f,d);if(a&&!a.isLoading()){a.add(b)}if(m){k=f.peekRecord(m,d)}b[j]=k||undefined}}else {g=b.joined;if(g){for(h=0,n=g.length;h=0){a.remove([b])}}else {if(b<0){d=a.getSession().getEntry(this.type,e);c=d&&d.record;if(c){a.add(c)}}}a.matrixUpdate=0}},adoptAssociated:function(e,d){var a=this.getAssociatedItem(e),c,b,f;if(a){a.setSession(d);this.onStoreCreate(a,d,e.getId());c=a.getData().items;for(b=0,f=c.length;b1){a[b]=this.apply('capitalize',a[b])}return a.join('')},getterName:function(a){var b=a.role;if(a&&a.isMany){return b}return 'get'+this.apply('capitalize',b)},inverseFieldRole:function(e,f,c,d){var a=this,b=a.apply(f?'uniRole':'multiRole',e),g=a.apply('pluralize',c),h=a.apply('undotted,pluralize',d);if(g.toLowerCase()!==h.toLowerCase()){b=c+a.apply('capitalize',b)}return b},manyToMany:function(c,e,d){var b=this,a=b.apply('undotted,capitalize,singularize',e)+b.apply('undotted,capitalize,pluralize',d);if(c){a=b.apply('capitalize',c+a)}return a},manyToOne:function(d,b,a,c){return this.apply('capitalize,singularize',a)+this.apply('capitalize',b)},matrixRole:function(a,c){var b=this.apply(a?'multiRole,capitalize':'multiRole',c);return a?a+b:b},oneToOne:function(d,b,a,c){return this.apply('undotted,capitalize,singularize',a)+this.apply('capitalize',b)},setterName:function(a){return 'set'+this.apply('capitalize',a.role)},endsWithIdRe:/(?:(_id)|[^A-Z](Id))$/,cache:{},apply:function(b,c){var e=this,h=e.cache,i=h[c]||(h[c]={}),a=i[b],d,g,f;if(!a){if(b.indexOf(',')<0){a=e[b](c)}else {g=(f=b.split(',')).length;a=c;for(d=0;d=Math.max(a,b)},find:function(g,h,d,e,b,c){var a=!e,f=!!(a&&c);return this.getData().findIndex(g,h,d,a,f,!b)},findRecord:function(){var a=this,b=a.find.apply(a,arguments);return b!==-1?a.getAt(b):null},findExact:function(a,c,b){return this.getData().findIndexBy(function(d){return d.isEqual(d.get(a),c)},this,b)},findBy:function(c,a,b){return this.getData().findIndexBy(c,a,b)},getAt:function(a){return this.getData().getAt(a)||null},getRange:function(d,b,a){var c=this.getData().getRange(d,Ext.isNumber(b)?b+1:b);if(a&&a.callback){a.callback.call(a.scope||this,c,d,b,a)}return c},getFilters:function(b){var a=(arguments.callee.$previous||Ext.Base.prototype.getFilters).call(this);if(!a&&b!==!1){this.setFilters([]);a=(arguments.callee.$previous||Ext.Base.prototype.getFilters).call(this)}return a},applyFilters:function(c,a){var b;if(!a){a=this.createFiltersCollection();b=!0}a.add(c);if(b){this.onRemoteFilterSet(a,this.getRemoteFilter())}return a},getSorters:function(b){var a=(arguments.callee.$previous||Ext.Base.prototype.getSorters).call(this);if(!a&&b!==!1){this.setSorters([]);a=(arguments.callee.$previous||Ext.Base.prototype.getSorters).call(this)}return a},applySorters:function(c,a){var b;if(!a){a=this.createSortersCollection();b=!0}a.add(c);if(b){this.onRemoteSortSet(a,this.getRemoteSort())}return a},filter:function(a,c,b){if(Ext.isString(a)){a={property:a,value:c}}this.suppressNextFilter=!!b;this.getFilters().add(a);this.suppressNextFilter=!1},removeFilter:function(a,d){var b=this,c=b.getFilters();b.suppressNextFilter=!!d;if(a instanceof Ext.util.Filter){c.remove(a)}else {c.removeByKey(a)}b.suppressNextFilter=!1},updateRemoteSort:function(a){this.onRemoteSortSet(this.getSorters(!1),a)},updateRemoteFilter:function(a){this.onRemoteFilterSet(this.getFilters(!1),a)},addFilter:function(b,a){this.suppressNextFilter=!!a;this.getFilters().add(b);this.suppressNextFilter=!1},filterBy:function(b,a){this.getFilters().add({filterFn:b,scope:a||this})},clearFilter:function(c){var b=this,a=b.getFilters(!1);if(!a||a.getCount()===0){return}b.suppressNextFilter=!!c;a.removeAll();b.suppressNextFilter=!1},isFiltered:function(){return this.getFilters().getCount()>0},isSorted:function(){var a=this.getSorters(!1);return !!(a&&a.length>0)||this.isGrouped()},addFieldTransform:function(b){if(b.getTransform()){return}var e=b.getProperty(),d=this.getModel(),c,a;if(d){c=d.getField(e);a=c?c.getSortType():null}if(a&&a!==Ext.identityFn){b.setTransform(a)}},beginUpdate:function(){if(!this.updating++){this.fireEvent('beginupdate')}},endUpdate:function(){if(this.updating&&!--this.updating){this.fireEvent('endupdate');this.onEndUpdate()}},getState:function(){var c=this,e=[],g=c.getFilters(),f=c.getGrouper(),a,d,b;c.getSorters().each(function(a){e[e.length]=a.getState();d=!0});if(c.statefulFilters&&c.saveStatefulFilters){d=!0;a=[];g.each(function(b){a[a.length]=b.getState()})}if(f){d=!0}if(d){b={};if(e.length){b.sorters=e}if(a){b.filters=a}if(f){b.grouper=f.getState()}}return b},applyState:function(b){var a=this,e=b.sorters,c=b.filters,d=b.grouper;if(e){a.getSorters().replaceAll(e)}if(c){a.saveStatefulFilters=!0;a.getFilters().replaceAll(c)}if(d){a.setGrouper(d)}},hasPendingLoad:Ext.emptyFn,isLoaded:Ext.emptyFn,isLoading:Ext.emptyFn,destroy:function(){var a=this;if(a.getStoreId()){Ext.data.StoreManager.unregister(a)}a.callParent();a.onDestroy()},sort:function(c,b,d){var a=this;if(arguments.length===0){if(a.getRemoteSort()){a.load()}else {a.forceLocalSort()}}else {a.getSorters().addSort(c,b,d)}},onBeforeCollectionSort:function(b,a){if(a){this.fireEvent('beforesort',this,a.getRange())}},onSorterEndUpdate:function(){var a=this,b;b=a.getSorters(!1);if(a.settingGroups||!b){return}b=b.getRange();if(b.length){if(a.getRemoteSort()){a.load({callback:function(){a.fireEvent('sort',a,b)}})}else {a.fireEvent('datachanged',a);a.fireEvent('refresh',a);a.fireEvent('sort',a,b)}}else {a.fireEvent('sort',a,b)}},onFilterEndUpdate:function(){var a=this,b=a.suppressNextFilter;if(a.getRemoteFilter()){a.currentPage=1;if(!b){a.load()}}else {if(!b){a.fireEvent('datachanged',a);a.fireEvent('refresh',a)}}if(a.trackStateChanges){a.saveStatefulFilters=!0}a.fireEvent('filterchange',a,a.getFilters().getRange())},updateGroupField:function(a){if(a){this.setGrouper({property:a,direction:this.getGroupDir()})}else {this.setGrouper(null)}},getGrouper:function(){return this.getData().getGrouper()},group:function(b,d){var a=this,c=a.getSorters(!1),e=b||c&&c.length;if(b&&typeof b==='string'){b={property:b,direction:d||a.getGroupDir()}}a.settingGroups=!0;a.getData().setGrouper(b);delete a.settingGroups;if(e){if(a.getRemoteSort()){a.load({scope:a,callback:a.fireGroupChange})}else {a.fireEvent('datachanged',a);a.fireEvent('refresh',a);a.fireGroupChange()}}else {a.fireGroupChange()}},fireGroupChange:function(){if(!this.destroyed){this.fireEvent('groupchange',this,this.getGrouper())}},clearGrouping:function(){this.group(null)},getGroupField:function(){var a=this.getGrouper(),b='';if(a){b=a.getProperty()}return b},isGrouped:function(){return !!this.getGrouper()},applyGrouper:function(a){this.group(a);return this.getData().getGrouper()},getGroups:function(){return this.getData().getGroups()},onEndUpdate:Ext.emptyFn,privates:{loadsSynchronously:Ext.privateFn,onRemoteFilterSet:function(a,b){if(a){a[b?'on':'un']('endupdate',this.onFilterEndUpdate,this)}},onRemoteSortSet:function(c,b){var a=this;if(c){c[b?'on':'un']('endupdate',a.onSorterEndUpdate,a);a.getData()[b?'un':'on']('beforesort',a.onBeforeCollectionSort,a)}}},deprecated:{5:{methods:{destroyStore:function(){this.destroy()}}}}},1,0,0,0,0,[[Ext.mixin.Observable.prototype.mixinId||Ext.mixin.Observable.$className,Ext.mixin.Observable],[Ext.mixin.Factoryable.prototype.mixinId||Ext.mixin.Factoryable.$className,Ext.mixin.Factoryable]],[Ext.data,'AbstractStore'],0);Ext.cmd.derive('Ext.data.Error',Ext.Base,{isError:!0,$configPrefixed:!1,config:{field:null,message:''},constructor:function(a){this.initConfig(a);this.msg=this.message}},1,0,0,0,0,0,[Ext.data,'Error'],0);Ext.cmd.derive('Ext.data.ErrorCollection',Ext.util.MixedCollection,{alternateClassName:'Ext.data.Errors',init:function(d){var b=this,h=d.fields,k=d.data,g,a,l,c,i,f,j,e;for(c=0,i=h.length;c]+>/gi,asText:function(a){return a!=null?String(a).replace(this.stripTagsRe,''):'\x00'},asUCText:function(a){return a!=null?String(a).toUpperCase().replace(this.stripTagsRe,''):'\x00'},asUCString:function(a){return a!=null?String(a).toUpperCase():'\x00'},asDate:function(a){if(!a){return 0}if(Ext.isDate(a)){return a.getTime()}return Date.parse(String(a))},asFloat:function(b){var a=parseFloat(String(b).replace(this.stripCommasRe,''));return isNaN(a)?0:a},asInt:function(b){var a=parseInt(String(b).replace(this.stripCommasRe,''),10);return isNaN(a)?0:a}},0,0,0,0,0,0,[Ext.data,'SortTypes'],0);Ext.cmd.derive('Ext.data.validator.Validator',Ext.Base,{isValidator:!0,type:'base',statics:{all:{},register:function(a,c){var b=this.all;b[a.toUpperCase()]=b[a.toLowerCase()]=b[a]=c.prototype}},onClassExtended:function(b,a){if(a.type){Ext.data.validator.Validator.register(a.type,b)}},constructor:function(a){if(typeof a==='function'){this.fnOnly=!0;this.validate=a}else {this.initConfig(a)}},validate:function(){return !0},clone:function(){var a=this;if(a.fnOnly){return new Ext.data.validator.Validator(a.validate)}return new a.self(a.getCurrentConfig())}},1,0,0,0,['data.validator.base'],[[Ext.mixin.Factoryable.prototype.mixinId||Ext.mixin.Factoryable.$className,Ext.mixin.Factoryable]],[Ext.data.validator,'Validator'],function(){this.register(this.prototype.type,this)});Ext.cmd.derive('Ext.data.field.Field',Ext.Base,{alternateClassName:'Ext.data.Field',aliasPrefix:'data.field.',type:'auto',factoryConfig:{defaultProperty:'name'},isDataField:!0,isField:!0,allowBlank:!0,allowNull:!1,critical:!1,defaultInvalidMessage:'This field is invalid',defaultValue:undefined,definedBy:null,depends:null,dependents:null,mapping:null,name:null,ordinal:undefined,persist:null,reference:null,unique:!1,rank:null,stripRe:/[\$,%]/g,calculated:!1,evil:!1,identifier:!1,onClassExtended:function(f,d){var b=d.sortType,c=f.prototype,e=c.validators,a=d.validators;if(b&&Ext.isString(b)){c.sortType=Ext.data.SortTypes[b]}if(a){if(!Ext.isArray(a)){a=[a]}delete d.validators;if(e){a=e.concat(a)}c.validators=a}},argumentNamesRe:/^function\s*\(\s*([^,\)\s]+)/,calculateRe:/[^\.a-z0-9_]([a-z_][a-z_0-9]*)\.([a-z_][a-z_0-9]*)/gi,constructor:function(d){var a=this,n=a.calculateRe,c,l,f,h,b,j,e,m,k,i,g;if(d){if(Ext.isString(d)){a.name=d}else {g=d.validators;if(g){delete d.validators;a.instanceValidators=g}Ext.apply(a,d)}}if(!a.allowNull){a.allowNull=!!a.reference}c=a.calculate;b=a.depends;if(c){a.convert=a.doCalculate;if(!b){if(!(b=c.$depends)){j={};k=c.toString();c.$depends=b=[];e=a.argumentNamesRe.exec(k);m=e?e[1]:'data';while(e=n.exec(k)){if(m===e[1]&&!j[i=e[2]]){j[i]=1;b.push(i)}}}a.depends=b}}f=a.defaultValue;if(a.convert){a.calculated=l=a.convert.length>1;a.evil=l&&!b}if(a.persist===null){a.persist=!c}h=a.sortType;if(!a.sortType){a.sortType=Ext.data.SortTypes.none}else {if(Ext.isString(h)){a.sortType=Ext.data.SortTypes[h]}}if(b&&typeof b==='string'){a.depends=[b]}a.cloneDefaultValue=f!==undefined&&(Ext.isDate(f)||Ext.isArray(f)||Ext.isObject(f))},setModelValidators:function(a){this._validators=null;this.modelValidators=a},compileValidators:function(){var a=this;a._validators=[];a.constructValidators(a.validators);a.constructValidators(a.modelValidators);a.constructValidators(a.instanceValidators)},constructValidators:function(a){if(a){if(!(a instanceof Array)){a=[a]}var d=a.length,e=this._validators,c,b;for(c=0;c0){(u=p[v]).dirty=!0;d=d?Math.min(d,u.rank):u.rank}if(!b||b.persist){if(f&&f.hasOwnProperty(c)){if(!y||o.isEqual(f[c],h)){delete f[c];a.dirty=-1}}else {if(y){if(!f){a.modified=f={}}a.dirty=!0;f[c]=j}}}if(c===a.idField.name){D=!0;z=j;s=h}}if(!d){break}b=l[d-1];b.dirty=!1;if(n){delete g[i]}else {g=a._singleProp;n=!0}i=b.name;g[i]=t[i];C=!0;for(;d0;){d=(b=g[i]).name;if(!(d in f)){c=h[d];if(j&&b.serialize){c=b.serialize(c,a)}f[d]=c}}}if(n){a.getAssociatedData(f,e)}return f},getTransientFields:function(){var a=this.self,b=a.transientFields;if(!b){a.rankFields();b=a.transientFields}return b},isLoading:function(){return !!this.loadOperation},abort:function(){var a=this.loadOperation;if(a){a.abort()}},load:function(a){a=Ext.apply({},a);var b=this,d=a.scope||b,g=b.getProxy(),f=a.callback,c=b.loadOperation,h=b.getId(),e;if(c){e=c.extraCalls;if(!e){e=c.extraCalls=[]}e.push(a);return c}a.id=h;a.recordCreator=function(e,f,c){var d=b.session;if(c){c.recordCreator=d?d.recordCreator:null}b.set(e,b._commitOptions);return b};a.internalCallback=function(e){var h=e.wasSuccessful()&&e.getRecords().length>0,l=b.loadOperation,i=l.extraCalls,c=[b,e],j=[b,e,h],g,k;b.loadOperation=null;if(h){Ext.callback(a.success,d,c)}else {Ext.callback(a.failure,d,c)}Ext.callback(f,d,j);if(i){for(g=0,k=i.length;g0;){b=i[a];if(b in e){delete e[b];delete j[b]}}for(a=0,h=f.length;a=a.getTotal()){a.setConfig({success:!1,records:[],total:0})}else {a.setRecords(Ext.Array.slice(d,e,e+i))}}b.setCompleted()}},clear:Ext.emptyFn},0,0,0,0,['proxy.memory'],0,[Ext.data.proxy,'Memory',Ext.data,'MemoryProxy'],0);Ext.cmd.derive('Ext.data.ProxyStore',Ext.data.AbstractStore,{config:{model:undefined,fields:null,proxy:undefined,autoLoad:undefined,autoSync:!1,batchUpdateMode:'operation',sortOnLoad:!0,trackRemoved:!0,asynchronousLoad:undefined},onClassExtended:function(e,d,b){var c=d.model,a;if(typeof c==='string'){a=b.onBeforeCreated;b.onBeforeCreated=function(){var g=this,f=arguments;Ext.require(c,function(){a.apply(g,f)})}}},implicitModel:'Ext.data.Model',autoSyncSuspended:0,constructor:function(b){var a=this;a.removed=[];Ext.data.AbstractStore.prototype.constructor.apply(this,arguments);if(a.getAsynchronousLoad()===!1){a.flushLoad()}},applyAsynchronousLoad:function(a){if(a==null){a=!this.loadsSynchronously()}return a},updateAutoLoad:function(a){this.getData();if(a){this.load(Ext.isObject(a)?a:undefined)}},getTotalCount:function(){return this.totalCount||0},applyFields:function(a){if(a){this.createImplicitModel(a)}},applyModel:function(a){if(a){a=Ext.data.schema.Schema.lookupEntity(a)}else {this.getFields();a=this.getModel()||this.createImplicitModel()}return a},applyProxy:function(a){var b=this.getModel();if(a!==null){if(a){if(a.isProxy){a.setModel(b)}else {if(Ext.isString(a)){a={type:a,model:b}}else {if(!a.model){a=Ext.apply({model:b},a)}}a=Ext.createByAlias('proxy.'+a.type,a);a.autoCreated=!0}}else {if(b){a=b.getProxy()}}if(!a){a=Ext.createByAlias('proxy.memory');a.autoCreated=!0}}return a},applyState:function(b){var a=this;Ext.data.AbstractStore.prototype.applyState.call(this,b);if(a.getAutoLoad()||a.isLoaded()){a.load()}},updateProxy:function(b,a){this.proxyListeners=Ext.destroy(this.proxyListeners)},updateTrackRemoved:function(a){this.cleanRemoved();this.removed=a?[]:null},onMetaChange:function(b,a){this.fireEvent('metachange',this,a)},create:function(f,a){var b=this,e=b.getModel(),d=new e(f),c;a=Ext.apply({},a);if(!a.records){a.records=[d]}a.internalScope=b;a.internalCallback=b.onProxyWrite;c=b.createOperation('create',a);return c.execute()},read:function(){return this.load.apply(this,arguments)},update:function(a){var b=this,c;a=Ext.apply({},a);if(!a.records){a.records=b.getUpdatedRecords()}a.internalScope=b;a.internalCallback=b.onProxyWrite;c=b.createOperation('update',a);return c.execute()},onProxyWrite:function(a){var b=this,c=a.wasSuccessful(),d=a.getRecords();switch(a.getAction()){case 'create':b.onCreateRecords(d,a,c);break;case 'update':b.onUpdateRecords(d,a,c);break;case 'destroy':b.onDestroyRecords(d,a,c);break;}if(c){b.fireEvent('write',b,a);b.fireEvent('datachanged',b)}},onCreateRecords:Ext.emptyFn,onUpdateRecords:Ext.emptyFn,onDestroyRecords:function(c,b,a){if(a){this.cleanRemoved()}},erase:function(a){var b=this,c;a=Ext.apply({},a);if(!a.records){a.records=b.getRemovedRecords()}a.internalScope=b;a.internalCallback=b.onProxyWrite;c=b.createOperation('destroy',a);return c.execute()},onBatchOperationComplete:function(b,a){return this.onProxyWrite(a)},onBatchComplete:function(e,f){var a=this,c=e.operations,d=c.length,b;if(a.batchUpdateMode!=='operation'){a.suspendEvents();for(b=0;b0){b.create=f;c=!0}if(g.length>0){b.update=g;c=!0}if(e.length>0){b.destroy=e;c=!0}if(c&&a.fireEvent('beforesync',b)!==!1){a.isSyncing=!0;d=d||{};a.proxy.batch(Ext.apply(d,{operations:b,listeners:a.getBatchListeners()}))}return a},getBatchListeners:function(){var a=this,b={scope:a,exception:a.onBatchException,complete:a.onBatchComplete};if(a.batchUpdateMode==='operation'){b.operationcomplete=a.onBatchOperationComplete}return b},save:function(){return this.sync.apply(this,arguments)},load:function(b){var a=this;if(typeof b==='function'){b={callback:b}}else {b=b?Ext.Object.chain(b):{}}a.pendingLoadOptions=b;if(a.getAsynchronousLoad()){if(!a.loadTimer){a.loadTimer=Ext.asap(a.flushLoad,a)}}else {a.flushLoad()}return a},flushLoad:function(){var a=this,c=a.pendingLoadOptions,b;a.clearLoadTask();if(!c){return}a.setLoadOptions(c);if(a.getRemoteSort()&&c.sorters){a.fireEvent('beforesort',a,c.sorters)}b=Ext.apply({internalScope:a,internalCallback:a.onProxyLoad,scope:a},c);a.lastOptions=b;b=a.createOperation('read',b);if(a.fireEvent('beforeload',a,b)!==!1){a.onBeforeLoad(b);a.loading=!0;b.execute()}},reload:function(a){var b=Ext.apply({},a,this.lastOptions);return this.load(b)},onEndUpdate:function(){var a=this;if(a.needsSync&&a.autoSync&&!a.autoSyncSuspended){a.sync()}},afterReject:function(b){var a=this;if(a.contains(b)){a.onUpdate(b,Ext.data.Model.REJECT,null);a.fireEvent('update',a,b,Ext.data.Model.REJECT,null)}},afterCommit:function(c,a){var b=this;if(!a){a=null}if(b.contains(c)){b.onUpdate(c,Ext.data.Model.COMMIT,a);b.fireEvent('update',b,c,Ext.data.Model.COMMIT,a)}},afterErase:function(a){this.onErase(a)},onErase:Ext.emptyFn,onUpdate:Ext.emptyFn,onDestroy:function(){var a=this,b=a.getProxy();a.clearLoadTask();a.getData().destroy();a.data=null;a.setProxy(null);if(b.autoCreated){b.destroy()}a.setModel(null)},hasPendingLoad:function(){return !!this.pendingLoadOptions||this.isLoading()},isLoading:function(){return !!this.loading},isLoaded:function(){return this.loadCount>0},suspendAutoSync:function(){++this.autoSyncSuspended},resumeAutoSync:function(b){var a=this;if(a.autoSyncSuspended&&!--a.autoSyncSuspended){if(b){a.sync()}}},removeAll:Ext.emptyFn,clearData:Ext.emptyFn,privates:{getRawRemovedRecords:function(){return this.removed},onExtraParamsChanged:function(){},clearLoadTask:function(){Ext.asapCancel(this.loadTimer);this.pendingLoadOptions=this.loadTimer=null},cleanRemoved:function(){var a=this.getRawRemovedRecords(),c,b;if(a){for(b=0,c=a.length;b-1},each:function(f,e){var c=this.data.items,d=c.length,b,a;for(a=0;a0){if(u){f=0;if(d.length>1&&h){f=1}b[i]=d[f].getProperty();b[t]=d[f].getDirection()}else {b[i]=a.encodeSorters(d)}}if(l&&j&&j.length>0){b[l]=a.encodeFilters(j)}return b},buildUrl:function(c){var b=this,a=b.getUrl(c);if(b.getNoCache()){a=Ext.urlAppend(a,Ext.String.format('{0}={1}',b.getCacheString(),Ext.Date.now()))}return a},getUrl:function(a){var b;if(a){b=a.getUrl()||this.getApi()[a.getAction()]}return b?b:(arguments.callee.$previous||Ext.data.proxy.Proxy.prototype.getUrl).call(this)},doRequest:function(a){},afterRequest:Ext.emptyFn,destroy:function(){Ext.data.proxy.Proxy.prototype.destroy.call(this);Ext.destroy(this.getReader(),this.getWriter());this.reader=this.writer=null}},0,0,0,0,['proxy.server'],0,[Ext.data.proxy,'Server',Ext.data,'ServerProxy'],0);Ext.cmd.derive('Ext.data.proxy.Ajax',Ext.data.proxy.Server,{alternateClassName:['Ext.data.HttpProxy','Ext.data.AjaxProxy'],isAjaxProxy:!0,defaultActionMethods:{create:'POST',read:'GET',update:'POST',destroy:'POST'},config:{binary:!1,headers:undefined,paramsAsJson:!1,withCredentials:!1,useDefaultXhrHeader:!0,username:null,password:null,actionMethods:{create:'POST',read:'GET',update:'POST',destroy:'POST'}},doRequest:function(e){var a=this,g=a.getWriter(),b=a.buildRequest(e),f=a.getMethod(b),c,d;if(g&&e.allowWrite()){b=g.write(b)}b.setConfig({binary:a.getBinary(),headers:a.getHeaders(),timeout:a.getTimeout(),scope:a,callback:a.createRequestCallback(b,e),method:f,useDefaultXhrHeader:a.getUseDefaultXhrHeader(),disableCaching:!1});if(f.toUpperCase()!=='GET'&&a.getParamsAsJson()){d=b.getParams();if(d){c=b.getJsonData();if(c){c=Ext.Object.merge({},c,d)}else {c=d}b.setJsonData(c);b.setParams(undefined)}}if(a.getWithCredentials()){b.setWithCredentials(!0);b.setUsername(a.getUsername());b.setPassword(a.getPassword())}return a.sendRequest(b)},sendRequest:function(a){a.setRawRequest(Ext.Ajax.request(a.getCurrentConfig()));this.lastRequest=a;return a},abort:function(a){a=a||this.lastRequest;if(a){Ext.Ajax.abort(a.getRawRequest())}},getMethod:function(d){var a=this.getActionMethods(),b=d.getAction(),c;if(a){c=a[b]}return c||this.defaultActionMethods[b]},createRequestCallback:function(b,c){var a=this;return function(f,e,d){if(b===a.lastRequest){a.lastRequest=null}a.processResponse(e,c,b,d)}},destroy:function(){this.lastRequest=null;Ext.data.proxy.Server.prototype.destroy.call(this)}},0,0,0,0,['proxy.ajax'],0,[Ext.data.proxy,'Ajax',Ext.data,'HttpProxy',Ext.data,'AjaxProxy'],0);Ext.cmd.derive('Ext.data.reader.Json',Ext.data.reader.Reader,{alternateClassName:'Ext.data.JsonReader',config:{record:null,metaProperty:'metaData',useSimpleAccessors:!1,preserveRawData:!1},updateRootProperty:function(){this.forceBuildExtractors()},updateMetaProperty:function(){this.forceBuildExtractors()},readRecords:function(a,e,d){var b=this,c;if(b.getMeta){c=b.getMeta(a);if(c){b.onMetaChange(c)}}else {if(a.metaData){b.onMetaChange(a.metaData)}}return Ext.data.reader.Reader.prototype.readRecords.call(this,a,e,d)},getResponseData:function(b){var a;try{return Ext.decode(b.responseText)}catch(c){a=this.createReadError(c.message);Ext.Logger.warn('Unable to parse the JSON returned by the server');this.fireEvent('exception',this,b,a);return a}},buildExtractors:function(){var a=this,b,c;if(Ext.data.reader.Reader.prototype.buildExtractors.apply(this,arguments)){b=a.getMetaProperty();c=a.getRootProperty();if(c){a.getRoot=a.getAccessor(c)}else {a.getRoot=Ext.identityFn}if(b){a.getMeta=a.getAccessor(b)}}},extractData:function(a,f){var e=this.getRecord(),d=[],c,b;if(e){c=a.length;if(!c&&Ext.isObject(a)){c=1;a=[a]}for(b=0;b1||e&&!g){b+=d}else {if(k){i=!1;if(l){++e}else {if(g){--e;i=!0}}if(b){if(i){b='['+b+']'}else {b='.'+b}j+=b;m.push(''+j);b=''}}}}f=m.join(' && ');f=Ext.functionFactory('raw','return '+f)}return f}}(),createFieldAccessor:function(b){var e=this,a=b.mapping,c=a||a===0,d=c?a:b.name;if(c){if(typeof d==='function'){return function(a){return b.mapping(a,e)}}else {return e.createAccessor(d)}}},getAccessorKey:function(b){var a=this.getUseSimpleAccessors()?'simple':'';return this.$className+a+b},privates:{copyFrom:function(a){Ext.data.reader.Reader.prototype.copyFrom.call(this,a);this.getRoot=a.getRoot}}},0,0,0,0,['reader.json'],0,[Ext.data.reader,'Json',Ext.data,'JsonReader'],0);Ext.cmd.derive('Ext.data.writer.Json',Ext.data.writer.Writer,{alternateClassName:'Ext.data.JsonWriter',config:{rootProperty:undefined,encode:!1,allowSingle:!0,expandData:!1},getExpandedData:function(f){var h=f.length,g=0,a,c,b,d,e,i=function(c,b){var a={};a[c]=b;return a};for(;g0){e=a[c];for(;d>0;d--){e=i(b[d],e)}a[b[0]]=a[b[0]]||{};Ext.Object.merge(a[b[0]],e);delete a[c]}}}}return f},writeRecords:function(b,a){var c=this,e=c.getRootProperty(),d,g,f;if(c.getExpandData()){a=c.getExpandedData(a)}if(c.getAllowSingle()&&a.length===1){a=a[0];g=!0}f=this.getTransform();if(f){a=f(a,b)}if(c.getEncode()){if(e){b.setParam(e,Ext.encode(a))}else {}}else {if(g||a&&a.length){d=b.getJsonData()||{};if(e){d[e]=a}else {d=a}b.setJsonData(d)}}return b}},0,0,0,0,['writer.json'],0,[Ext.data.writer,'Json',Ext.data,'JsonWriter'],0);Ext.cmd.derive('Ext.util.Group',Ext.util.Collection,{config:{groupKey:null},$endUpdatePriority:2001},0,0,0,0,0,0,[Ext.util,'Group'],0);Ext.cmd.derive('Ext.util.SorterCollection',Ext.util.Collection,{isSorterCollection:!0,$sortable:null,sortFn:null,config:{sorterOptionsFn:null,sorterOptionsScope:null},constructor:function(b){var a=this;a.sortFn=Ext.util.Sorter.createComparator(a);Ext.util.Collection.prototype.constructor.call(this,b);a.setDecoder(a.decodeSorter)},addSort:function(b,c,d){var a=this,f,j,k,g,h,i,e;if(!b){a.beginUpdate();a.endUpdate()}else {g=a.getOptions();if(b instanceof Array){e=b;d=c;c=null}else {if(Ext.isString(b)){if(!(i=a.get(b))){e=[{property:b,direction:c||g.getDefaultSortDirection()}]}else {e=[i]}}else {if(Ext.isFunction(b)){e=[{sorterFn:b,direction:c||g.getDefaultSortDirection()}]}else {e=[b];d=c;c=null}}}d=a._sortModes[d||'replace'];h=a.getAt(0);f=a.length;j=d.append?f:0;a.beginUpdate();a.splice(j,d.replace?f:0,e);if(d.multi){f=a.length;k=g.getMultiSortLimit();if(f>k){a.removeAt(k,f)}}if(i&&c){i.setDirection(c)}else {if(j===0&&h&&h===a.getAt(0)){h.toggle()}}a.endUpdate()}},clear:function(){this.beginUpdate();Ext.util.Collection.prototype.clear.call(this);this.endUpdate(this.items)},getSortFn:function(){return this.sortFn},getByProperty:function(d){var c=this.items,e=c.length,a,b;for(a=0;ad+1||!Ext.isIterable(b)){b=Ext.Array.slice(e,d)}var j=k.items,l=b.length,c=[],f,g,i,a,h;for(f=0;f0;){g=j[i];if(g.getSorterFn()===a){c.push(g)}}}}}}b=c;b.$cloned=!0}return b},getOptions:function(){return this.$sortable||this}},1,0,0,0,0,0,[Ext.util,'SorterCollection'],0);Ext.cmd.derive('Ext.util.FilterCollection',Ext.util.Collection,{isFilterCollection:!0,$filterable:null,filterFn:null,constructor:function(b){var a=this;a.filterFn=Ext.util.Filter.createFilterFn(a);Ext.util.Collection.prototype.constructor.call(this,b);a.setDecoder(a.decodeFilter)},filterData:function(a){return this.filtered?Ext.Array.filter(a,this.filterFn):a},getFilterFn:function(){return this.filterFn},isItemFiltered:function(a){return !this.filterFn(a)},decodeFilter:function(b){var d=this.getOptions(),c=d.getRootProperty(),a;if(b.isFilter){if(!b.getRoot()){b.setRoot(c)}}else {a={root:c};if(Ext.isFunction(b)){a.filterFn=b}else {a=Ext.apply(a,b);if(a.fn){a.filterFn=a.fn;delete a.fn}if(Ext.util.Filter.isInvalid(a)){return !1}}b=new Ext.util.Filter(a)}return b},decodeRemoveItems:function(f,e){var p=this,b=e===undefined?f:f[e];if(!b.$cloned){if(f.length>e+1||!Ext.isIterable(b)){b=Ext.Array.slice(f,e)}var k=p.items,o=b.length,h=[],a,g,l,n,m,c,d,j,i;for(g=0;g0;){c=k[j];d=!1;if(m){d=c.getProperty()===a}else {if(l){d=c.getFilterFn()===a}else {if(n){d=c.getProperty()===a.property&&c.getValue()===a.value}}}if(d){h.push(c)}}}}b=h;b.$cloned=!0}return b},getOptions:function(){return this.$filterable||this}},1,0,0,0,0,0,[Ext.util,'FilterCollection'],0);Ext.cmd.derive('Ext.util.GroupCollection',Ext.util.Collection,{isGroupCollection:!0,config:{grouper:null,itemRoot:null},observerPriority:-100,onCollectionAdd:function(b,a){this.addItemsToGroups(b,a.items)},onCollectionBeforeItemChange:function(b,a){this.changeDetails=a},onCollectionBeginUpdate:function(){this.beginUpdate()},onCollectionEndUpdate:function(){this.endUpdate()},onCollectionItemChange:function(b,a){var c=a.item;if(!a.indexChanged){this.syncItemGrouping(b,c,b.getKey(c),a.oldKey,a.oldIndex)}this.changeDetails=null},onCollectionRefresh:function(a){this.removeAll();this.addItemsToGroups(a,a.items)},onCollectionRemove:function(k,j){var d=this,g=d.changeDetails,b,h,a,e,i,c,f;if(g){f=g.item;a=d.findGroupForItem(f);b=[];if(a){b.push({group:a,items:[f]})}}else {b=d.groupItems(k,j.items,!1)}for(e=0,i=b.length;e0&&i.getSorters().getCount()===0){k=i.indexOf(a.items[0]);if(o-1){b=[c];d=1}else {d=0}}else {b=[];for(g=0,d=c.length;g=0;a--){d=c[a];d.reject();if(!g){b.insert(d.removedFrom||0,d)}}if(g){h.setAutoSort(i);b.add(c)}c.length=0}b.endUpdate();Ext.resumeLayouts(!0)},onDestroy:function(){var a=this,c=a.loadTask,d=a.getData(),b=d.getSource();a.clearData();Ext.data.ProxyStore.prototype.onDestroy.call(this);a.setSession(null);a.observers=null;if(c){c.cancel();a.loadTask=null}if(b){b.destroy()}},privates:{fetch:function(a){a=Ext.apply({},a);this.setLoadOptions(a);var b=this.createOperation('read',a);b.execute()},onBeforeLoad:function(a){this.callObservers('BeforeLoad',[a])},onRemoteFilterSet:function(a,b){if(a){this.getData().setFilters(b?null:a)}Ext.data.ProxyStore.prototype.onRemoteFilterSet.call(this,a,b)},onRemoteSortSet:function(b,a){var c=this.getData();if(b){c.setSorters(a?null:b)}c.setAutoGroup(!a);Ext.data.ProxyStore.prototype.onRemoteSortSet.call(this,b,a)},isMoving:function(a,f){var c=this.moveMap,b=0,e,d;if(c){if(a){if(Ext.isArray(a)){for(d=0,e=a.length;d-1}}}return b}},1,0,0,0,0,0,[Ext.app.domain,'Store'],0);Ext.cmd.derive('Ext.app.route.Queue',Ext.Base,{queue:null,token:null,constructor:function(a){Ext.apply(this,a);this.queue=new Ext.util.MixedCollection()},queueAction:function(a,b){this.queue.add({route:a,args:b})},clearQueue:function(){this.queue.removeAll()},runQueue:function(){var c=this.queue,a=c.removeAt(0),b;if(a){b=a&&a.route;b.execute(this.token,a.args,this.onActionExecute,this)}},onActionExecute:function(a){if(a){this.clearQueue()}else {this.runQueue()}}},1,0,0,0,0,0,[Ext.app.route,'Queue'],0);Ext.cmd.derive('Ext.app.route.Route',Ext.Base,{action:null,conditions:null,controller:null,allowInactive:!1,url:null,before:null,caseInsensitive:!1,matcherRegex:null,paramMatchingRegex:null,paramsInMatchString:null,constructor:function(c){var a=this,b;Ext.apply(a,c,{conditions:{}});b=a.url;a.paramMatchingRegex=new RegExp(/:([0-9A-Za-z\_]*)/g);a.paramsInMatchString=b.match(a.paramMatchingRegex)||[];a.matcherRegex=a.createMatcherRegex(b)},recognize:function(b){var a=this,d=a.controller,e,c;if((a.allowInactive||d.isActive())&&a.recognizes(b)){e=a.matchesFor(b);c=b.match(a.matcherRegex);c.shift();return Ext.applyIf(e,{controller:d,action:a.action,historyUrl:b,args:c})}return !1},recognizes:function(a){return this.matcherRegex.test(a)},execute:function(h,d,f,g){var e=d.args||[],a=this.before,c=this.controller,b=this.createCallback(d,f,g);if(a){e.push(b);if(Ext.isString(a)){a=this.before=c[a]}if(a){a.apply(c,e)}}else {b.resume()}},matchesFor:function(f){var b={},d=this.paramsInMatchString,c=f.match(this.matcherRegex),a=0,e=d.length;c.shift();for(;a0){c=a.substring(0,d);b=a.substring(d+1)+'.'+c}else {if(a.indexOf('.')>0&&(Ext.ClassManager.isCreated(a)||this.hasRegisteredPrefix(a))){b=a}else {if(f){b=f+'.'+g+'.'+(e?e+'.'+a:a);c=a}else {b=a}}}return {absoluteName:b,shortName:c}},hasRegisteredPrefix:function(a){var c=Ext.ClassManager,b=c.getPrefix(a);return b&&b!==a}},models:null,views:null,stores:null,controllers:null,config:{application:null,refs:null,active:!0,moduleClassName:null},onClassExtended:function(d,c,a){var b=a.onBeforeCreated;a.onBeforeCreated=function(j,i){var g=Ext.app.Controller,h=[],e,f;f=j.prototype;e=g.resolveNamespace(j,i);if(e){f.$namespace=e}g.processDependencies(f,h,e,'model',i.models);g.processDependencies(f,h,e,'view',i.views);g.processDependencies(f,h,e,'store',i.stores);g.processDependencies(f,h,e,'controller',i.controllers);Ext.require(h,Ext.Function.pass(b,arguments,this))}},constructor:function(a){this.initAutoGetters();Ext.app.BaseController.prototype.constructor.apply(this,arguments)},normalizeRefs:function(a){var c=this,b=[];if(a){if(Ext.isObject(a)){Ext.Object.each(a,function(d,c){if(Ext.isString(c)){c={selector:c}}c.ref=d;b.push(c)})}else {if(Ext.isArray(a)){b=Ext.Array.merge(b,a)}}}a=c.refs;if(a){c.refs=null;a=c.normalizeRefs(a);if(a){b=Ext.Array.merge(b,a)}}return b},getRefMap:function(){var e=this,a=e._refMap,b,d,f,c;if(!a){b=e.getRefs();a=e._refMap={};if(b){for(c=0,f=b.length;c0){d=c[b];a.map[a.getKey(d)]=b}++a.generation}}},1,0,0,0,0,0,[Ext.util,'Bag'],0);Ext.cmd.derive('Ext.util.Scheduler',Ext.Base,{busyCounter:0,lastBusyCounter:0,destroyed:!1,firing:null,notifyIndex:-1,nextId:0,orderedItems:null,passes:0,scheduledCount:0,validIdRe:null,config:{cycleLimit:5,preSort:null,tickDelay:5},suspendOnNotify:!0,constructor:function(a){this.mixins.observable.constructor.call(this,a);this.items=new Ext.util.Bag()},destroy:function(){var a=this,b=a.timer;if(b){window.clearTimeout(b);a.timer=null}a.items.destroy();a.items=a.orderedItems=null;a.callParent()},add:function(c){var a=this,b=a.items;if(b===a.firing){a.items=b=b.clone()}c.id=c.id||++a.nextId;c.scheduler=a;b.add(c);if(!a.sortMap){a.orderedItems=null}},remove:function(c){var a=this,b=a.items;if(a.destroyed){return}if(b===a.firing){a.items=b=b.clone()}if(c.scheduled){a.unscheduleItem(c);c.scheduled=!1}b.remove(c);a.orderedItems=null},sort:function(){var a=this,b=a.items,f={},e=a.getPreSort(),c,d;a.orderedItems=[];a.sortMap=f;if(e){b.sort(e)}b=b.items;for(c=0;c0;){c[d].stub=b}}return b},isDescendantOf:function(b){for(var a=this;a=a.parent;){if(a===b){return !0}}return !1},onSchedule:function(){for(var c,e,b,a,d=this.parent;d;d=d.parent){a=d.bindings;if(a){for(c=0,e=a.length;c '+a.binding.getFullName()+')')},getDataObject:function(){var a=this.binding;return a&&a.getDataObject()},getRawValue:function(){var a=this.binding;return a&&a.getRawValue()},getValue:function(){var a=this.binding;return a&&a.getValue()},getTargetStub:function(){var a=this.binding;return a&&a.stub},isLoading:function(){var a=this.binding;return a?a.isLoading():!1},link:function(c,b){var a=this,d=a.binding;if(d){d.destroy()}b=a.target=b||a.owner;a.linkDescriptor=c;a.binding=b.bind(c,a.onChange,a);a.binding.deep=!0},onChange:function(){this.invalidate(!0)},react:function(){var a=this,b=a.owner.linkData;b[a.name]=a.getValue();Ext.app.bind.Stub.prototype.react.call(this)},privates:{collect:function(){var c=this,b=Ext.app.bind.Stub.prototype.collect.call(this),a=c.binding?1:0;return b+a},sort:function(){var a=this.binding;if(a){this.scheduler.sortItem(a)}}}},0,0,0,0,0,0,[Ext.app.bind,'LinkStub'],0);Ext.cmd.derive('Ext.app.bind.RootStub',Ext.app.bind.AbstractStub,{isRootStub:!0,depth:0,createRootChild:function(a,j){var e=this,d=e.owner,i=d.getData(),g=e.children,c=g&&g[a],f=c?null:e,h,b;if(j||i.hasOwnProperty(a)||!(h=d.getParent())){b=new Ext.app.bind.Stub(d,a,f)}else {b=new Ext.app.bind.LinkStub(d,a,c?null:f);b.link('{'+a+'}',h)}if(c){c.graft(b)}return b},createStubChild:function(a){return this.createRootChild(a,!0)},descend:function(a,g){var f=this,d=f.children,b=g||0,e=a[b++],c=d&&d[e]||f.createRootChild(e);if(b0;){if(a[b].isLoading()){return !0}}return !1},isBindingStatic:function(a){return a.isTemplateBinding&&a.isStatic},isStatic:function(){var b=this.bindings,d=b.length,a,c;for(a=0;a-1}}}}return b}},1,0,0,0,0,0,[Ext.app.domain,'Controller'],0);Ext.cmd.derive('Ext.data.PageMap',Ext.util.LruCache,{config:{store:null,pageSize:0,rootProperty:''},clear:function(b){var a=this;a.pageMapGeneration=(a.pageMapGeneration||0)+1;a.indexMap={};Ext.util.LruCache.prototype.clear.call(this,b)},forEach:function(k,f){var d=this,b=Ext.Object.getKeys(d.map),h=b.length,j=d.getPageSize(),a,c,e,g,i;for(a=0;ad},hasPage:function(a){return !!this.get(a)},peekPage:function(a){return this.map[a]},getAt:function(a){return this.getRange(a,a+1)[0]},getRange:function(l,f){f--;if(!this.hasRange(l,f)){Ext.raise('PageMap asked for range which it does not have')}var c=this,k=Ext.Array,e=c.getPageSize(),g=c.getPageFromRecordIndex(l),h=c.getPageFromRecordIndex(f),m=(g-1)*e,n=h*e-1,a=g,j=[],d,i,b;for(;a<=h;a++){if(a===g){d=l-m;b=d>0}else {d=0;b=!1}if(a===h){i=e-(n-f);b=b||i=g){b=g-1;c=Math.max(b-h,0)}if(a.rangeCached(c,Math.min(b,a.totalCount))){a.loading=!1;f.un('pageadd',e);l=f.getRange(c,b+1);a.fireEvent('load',a,l,!0);a.fireEvent('refresh',a)}};h=Math.ceil((a.getLeadingBufferZone()+a.getTrailingBufferZone())/2);if(a.lastRequestStart&&a.preserveScrollOnReload){c=a.lastRequestStart;b=a.lastRequestEnd;i=a.getTotalCount()}else {c=d.start||0;b=c+(d.count||a.getPageSize())-1}f.clear(!0);delete a.totalCount;c=Math.max(c-h,0);b=Math.min(b+h,i);j=a.getPageFromRecordIndex(c);k=a.getPageFromRecordIndex(b);a.loading=!0;d.waitForReload=e;f.on('pageadd',e);for(g=j;g<=k;g++){a.prefetchPage(g,d)}},filter:function(){Ext.data.ProxyStore.prototype.filter.apply(this,arguments)},filterBy:function(b,a){},loadData:function(b,a){},loadPage:function(c,a){var b=this;a=a||{};a.page=b.currentPage=c;a.start=(c-1)*b.getPageSize();a.limit=b.getViewSize()||b.getDefaultViewSize();a.loadCallback=a.callback;a.callback=null;return b.loadToPrefetch(a)},clearData:function(c){var b=this,a=b.getData();if(a){a.clear()}},getCount:function(){return this.totalCount||0},getRange:function(c,b,f){var a=this,k=a.totalCount-1,m=a.lastRequestStart,l=[],h=a.getData(),g,d,e,i,j;f=Ext.apply({prefetchStart:c,prefetchEnd:b},f);b=b>=a.totalCount?k:b;d=c===0?0:c-1;e=b===k?b:b+1;a.lastRequestStart=c;a.lastRequestEnd=b;if(a.rangeCached(d,e)){a.onRangeAvailable(f);l=h.getRange(c,b+1)}else {a.fireEvent('cachemiss',a,c,b);i=a.getPageFromRecordIndex(d);j=a.getPageFromRecordIndex(e);g=function(l,k,m){if(k>=i&&k<=j&&a.rangeCached(d,e)){a.fireEvent('cachefilled',a,c,b);h.un('pageadd',g);a.onRangeAvailable(f)}};h.on('pageadd',g);a.prefetchRange(c,b)}a.primeCache(c,b,c-1},indexOf:function(a){return this.getData().indexOf(a)},indexOfId:function(a){return this.indexOf(this.getById(a))},group:function(b,d){var a=this,c;if(b&&typeof b==='string'){c=a.grouper;if(!c){a.grouper=new Ext.util.Grouper({property:b,direction:d||'ASC',root:'data'})}else {if(d===undefined){c.toggle()}else {c.setDirection(d)}}}else {a.grouper=b?a.getSorters().decodeSorter(b,'Ext.util.Grouper'):null}a.getData().clear();a.loadPage(1,{callback:function(){a.fireEvent('groupchange',a,a.getGrouper())}})},getPageFromRecordIndex:function(a){return Math.floor(a/this.getPageSize())+1},calculatePageCacheSize:function(c){var a=this,b=a.getPurgePageCount();return b?Math.max(a.getData().getMaxSize()||0,Math.ceil((c+a.getTrailingBufferZone()+a.getLeadingBufferZone())/a.getPageSize())*2+b):0},loadToPrefetch:function(b){var a=this,f=b,h,d,i,e=b.start,k=b.start+b.limit-1,m=a.getViewSize()||b.limit,c=Math.min(k,b.start+m-1),p=a.getPageFromRecordIndex(Math.max(e-a.getTrailingBufferZone(),0)),q=a.getPageFromRecordIndex(k+a.getLeadingBufferZone()),g=a.getData(),j=function(){d=d||[];if(b.loadCallback){b.loadCallback.call(b.scope||a,d,o,!0)}if(b.callback){b.callback.call(b.scope||a,d,e||0,k||0,b)}},n=function(){a.fireEvent('datachanged',a);a.fireEvent('refresh',a);a.fireEvent('load',a,d,!0)},l=function(){if(a.rangeCached(e,c)){a.loading=!1;d=g.getRange(e,c+1);g.un('pageadd',l);if(a.hasListeners.guaranteedrange){a.guaranteeRange(e,c,b.callback,b.scope)}j();n()}},o;g.setMaxSize(a.calculatePageCacheSize(m));if(a.fireEvent('beforeload',a,b)!==!1){delete a.totalCount;a.loading=!0;if(b.callback){f=Ext.apply({},b);delete f.callback}a.on('prefetch',function(m,e,d,k){o=k;if(d){if(i=a.getTotalCount()){g.on('pageadd',l);c=Math.min(c,i-1);q=a.getPageFromRecordIndex(Math.min(c+a.getLeadingBufferZone(),i-1));for(h=p+1;h<=q;++h){a.prefetchPage(h,f)}}else {j();n()}}else {a.loading=!1;j();a.fireEvent('load',a,e,!1)}},null,{single:!0});a.prefetchPage(p,f)}},prefetch:function(b){var a=this,c=a.getPageSize(),d=a.getData(),e,f;if(c){if(a.lastPageSize&&c!=a.lastPageSize){Ext.raise('pageSize cannot be dynamically altered')}if(!d.getPageSize()){d.setPageSize(c)}}else {a.pageSize=d.setPageSize(c=b.limit)}a.lastPageSize=c;if(!b.page){b.page=a.getPageFromRecordIndex(b.start);b.start=(b.page-1)*c;b.limit=Math.ceil(b.limit/c)*c}f=a.pageRequests[b.page];if(!f||f.getOperation().pageMapGeneration!==d.pageMapGeneration){b=Ext.apply({action:'read',filters:a.getFilters().items,sorters:a.getSorters().items,grouper:a.getGrouper(),internalCallback:a.onProxyPrefetch,internalScope:a},b);e=a.createOperation('read',b);e.pageMapGeneration=d.pageMapGeneration;if(a.fireEvent('beforeprefetch',a,e)!==!1){a.pageRequests[b.page]=e.execute();if(a.getProxy().isSynchronous){delete a.pageRequests[b.page]}}}return a},onPageMapClear:function(){var a=this,e=a.wasLoading,d=a.pageRequests,b=a.getData(),c;b.clearListeners();b.on('clear',a.onPageMapClear,a);a.relayEvents(b,['beforepageremove','pageadd','pageremove']);a.loading=!0;a.totalCount=0;for(c in d){if(d.hasOwnProperty(c)){d[c].getOperation().abort()}}a.fireEvent('clear',a);a.loading=e},prefetchPage:function(d,e){var a=this,b=a.getPageSize(),f=(d-1)*b,c=a.totalCount;if(c!==undefined&&a.data.getCount()===c){return}a.prefetch(Ext.applyIf({page:d,start:f,limit:b},e))},onProxyPrefetch:function(b){if(this.destroyed){return}var a=this,g=b.getResultSet(),e=b.getRecords(),d=b.wasSuccessful(),i=b.getPage(),c=b.waitForReload,k=a.totalCount,h=a.pageRequests,j,f;if(b.pageMapGeneration===a.getData().pageMapGeneration){if(g){a.totalCount=g.getTotal();if(a.totalCount!==k){a.fireEvent('totalcountchange',a.totalCount)}}if(i!==undefined){delete a.pageRequests[i]}a.loading=!1;a.fireEvent('prefetch',a,e,d,b);if(d){if(a.totalCount===0){if(c){for(j in h){f=h[j].getOperation();if(f.waitForReload===c){delete f.waitForReload}}a.getData().un('pageadd',c);a.fireEvent('load',a,[],!0);a.fireEvent('refresh',a)}}else {a.cachePage(e,b.getPage())}}Ext.callback(b.getCallback(),b.getScope()||a,[e,b,d])}},cachePage:function(b,d){var a=this,e=b.length,c;if(!Ext.isDefined(a.totalCount)){a.totalCount=b.length;a.fireEvent('totalcountchange',a.totalCount)}for(c=0;cf-1?f-1:a.prefetchEnd,d;b=Math.max(0,b);d=c.getData().getRange(e,b+1);if(a.fireEvent!==!1){c.fireEvent('guaranteedrange',d,e,b,a)}if(a.callback){a.callback.call(a.scope||c,d,e,b,a)}},guaranteeRange:function(d,e,b,c,a){a=Ext.apply({callback:b,scope:c},a);this.getRange(d,e+1,a)},prefetchRange:function(c,d){var a=this,e,f,b,g=a.getData();if(!a.rangeCached(c,d)){e=a.getPageFromRecordIndex(c);f=a.getPageFromRecordIndex(d);g.setMaxSize(a.calculatePageCacheSize(d-c+1));for(b=e;b<=f;b++){if(!a.pageCached(b)){a.prefetchPage(b)}}}},primeCache:function(a,b,g){var c=this,f=c.getLeadingBufferZone(),e=c.getTrailingBufferZone(),h=c.getPageSize(),d=c.totalCount;if(g===-1){a=Math.max(a-f,0);b=Math.min(b+e,d-1)}else {if(g===1){a=Math.max(Math.min(a-e,d-h),0);b=Math.min(b+f,d-1)}else {a=Math.min(Math.max(Math.floor(a-(f+e)/2),0),d-c.pageSize);b=Math.min(Math.max(Math.ceil(b+(f+e)/2),0),d-1)}}c.prefetchRange(a,b)},sort:function(b,a,c){if(arguments.length===0){this.clearAndLoad()}else {this.getSorters().addSort(b,a,c)}},onSorterEndUpdate:function(){var a=this,b=a.getSorters().getRange();if(b.length){a.fireEvent('beforesort',a,b);a.clearAndLoad({callback:function(){a.fireEvent('sort',a,b)}})}else {a.fireEvent('sort',a,b)}},clearAndLoad:function(a){this.getData().clear();this.loadPage(1,a)},privates:{isLast:function(a){return this.indexOf(a)===this.getTotalCount()-1},isMoving:function(){return !1}}},0,0,0,0,['store.buffered'],0,[Ext.data,'BufferedStore'],0);Ext.cmd.derive('Ext.data.NodeInterface',Ext.Base,{statics:{decorate:function(f){var a=Ext.data.schema.Schema.lookupEntity(f),e=a.prototype,c,b,d;if(!a.prototype.isObservable){a.mixin(Ext.mixin.Observable.prototype.mixinId,Ext.mixin.Observable)}if(e.isNode){return}c=e.idProperty;b=a.getField(c);d=b.type;a.override(this.getPrototypeBody());a.addFields([{name:'parentId',type:d,defaultValue:null,allowNull:b.allowNull},{name:'index',type:'int',defaultValue:-1,persist:!1,convert:null},{name:'depth',type:'int',defaultValue:0,persist:!1,convert:null},{name:'expanded',type:'bool',defaultValue:!1,persist:!1,convert:null},{name:'expandable',type:'bool',defaultValue:!0,persist:!1,convert:null},{name:'checked',type:'auto',defaultValue:null,persist:!1,convert:null},{name:'leaf',type:'bool',defaultValue:!1},{name:'cls',type:'string',defaultValue:'',persist:!1,convert:null},{name:'iconCls',type:'string',defaultValue:'',persist:!1,convert:null},{name:'icon',type:'string',defaultValue:'',persist:!1,convert:null},{name:'root',type:'boolean',defaultValue:!1,persist:!1,convert:null},{name:'isLast',type:'boolean',defaultValue:!1,persist:!1,convert:null},{name:'isFirst',type:'boolean',defaultValue:!1,persist:!1,convert:null},{name:'allowDrop',type:'boolean',defaultValue:!0,persist:!1,convert:null},{name:'allowDrag',type:'boolean',defaultValue:!0,persist:!1,convert:null},{name:'loaded',type:'boolean',defaultValue:!1,persist:!1,convert:null},{name:'loading',type:'boolean',defaultValue:!1,persist:!1,convert:null},{name:'href',type:'string',defaultValue:'',persist:!1,convert:null},{name:'hrefTarget',type:'string',defaultValue:'',persist:!1,convert:null},{name:'qtip',type:'string',defaultValue:'',persist:!1,convert:null},{name:'qtitle',type:'string',defaultValue:'',persist:!1,convert:null},{name:'qshowDelay',type:'int',defaultValue:0,persist:!1,convert:null},{name:'children',type:'auto',defaultValue:null,persist:!1,convert:null},{name:'visible',type:'boolean',defaultValue:!0,persist:!1},{name:'text',type:'string',persist:!1}])},getPrototypeBody:function(){var a={idchanged:!0,append:!0,remove:!0,move:!0,insert:!0,beforeappend:!0,beforeremove:!0,beforemove:!0,beforeinsert:!0,expand:!0,collapse:!0,beforeexpand:!0,beforecollapse:!0,sort:!0},b={silent:!0};return {isNode:!0,firstChild:null,lastChild:null,parentNode:null,previousSibling:null,nextSibling:null,constructor:function(){var a=this;a.mixins.observable.constructor.call(a);a.callParent(arguments);a.childNodes=[];return a},createNode:function(a){var b=this,j=b.childType,h,f,g,c,d,e,i=b.self;if(!a.isModel){if(j){i=b.schema.getEntity(j)}else {h=b.getTreeStore();f=h&&h.getProxy().getReader();g=b.getProxy();c=g?g.getReader():null;d=!f||c&&c.initialConfig.typeProperty?c:f;if(d){e=d.getTypeProperty();if(e){i=d.getChildType(b.schema,a,e)}}}a=new i(a)}if(!a.childNodes){a.firstChild=a.lastChild=a.parentNode=a.previousSibling=a.nextSibling=null;a.childNodes=[]}return a},isLeaf:function(){return this.get('leaf')===!0},setFirstChild:function(a){this.firstChild=a},setLastChild:function(a){this.lastChild=a},updateInfo:function(o,k){var a=this,i=a.data,r=i.depth,m={},n=a.childNodes,q=n.length,s=a.phantom,t=a.fields,c=a.modified||(a.modified={}),b,e,j,d,p,l=k.parentId,g,h,f;for(b in k){j=t[a.fieldOrdinals[b]];e=k[b];h=j&&j.persist;d=i[b];g=h&&b==='index'&&d!==-1&&(l&&l!==c.parentId);if(!g&&a.isEqual(d,e)){continue}i[b]=e;if(h){if(!g&&c.hasOwnProperty(b)){if(a.isEqual(c[b],e)){delete c[b];a.dirty=!1;for(p in c){if(c.hasOwnProperty(p)){a.dirty=!0;break}}}}else {a.dirty=!0;c[b]=d}}}if(o){a.commit();a.phantom=s}if(a.data.depth!==r){m={depth:a.data.depth+1};for(f=0;f0},isExpandable:function(){var a=this;if(a.get('expandable')){return !(a.isLeaf()||a.isLoaded()&&!a.phantom&&!a.hasChildNodes())}return !1},triggerUIUpdate:function(){this.callJoined('afterEdit',[])},appendChild:function(b,h,l){var a=this,j,m,c,e,f,k={isLast:!0,parentId:a.getId(),depth:(a.data.depth||0)+1},i,d=a.getTreeStore(),g=d&&d.bulkUpdate;Ext.suspendLayouts();if(Ext.isArray(b)){m=b.length;i=new Array(m);a.callTreeStore('beginFill');for(j=0;j0){if(!e){e=c.getTreeStore().getSortFn()}Ext.Array.sort(a,e);c.setFirstChild(a[0]);c.setLastChild(a[g-1]);for(b=0;b0){d.children=c=[];for(a=0;a1&&!a.getRemoteSort()&&a.getFolderSort()||j.length,e,h,c,d;if(a.needsLocalFilter()){d=a.getFilters().getFilterFn();b[0].set('visible',d(b[0]))}for(c=1;c')}else {b.push('>');if(c=a.tpl){c.applyOut(a.tplData,b)}if(c=a.html){b.push(c)}if(c=a.cn||a.children){e.generateMarkup(c,b)}h=e.closeTags;b.push(h[f]||(h[f]=''))}}}return b},generateStyles:function(c,d,f){var e=d||[],a,b;for(a in c){if(c.hasOwnProperty(a)){b=c[a];a=this.decamelizeName(a);if(f&&Ext.String.hasHtmlCharacters(b)){b=Ext.String.htmlEncode(b)}e.push(a,':',b,';')}}return d||e.join('')},markup:function(a){if(typeof a==='string'){return a}var b=this.generateMarkup(a,[]);return b.join('')},applyStyles:function(b,a){Ext.fly(b).applyStyles(a)},createContextualFragment:function(e){var d=this.detachedDiv,b=document.createDocumentFragment(),c,a;d.innerHTML=e;a=d.childNodes;c=a.length;while(c--){b.appendChild(a[0])}return b},createDom:function(e,f){var c=this,d=c.markup(e),b=c.detachedDiv,a;b.innerHTML=d;a=b.firstChild;return Ext.supports.ChildContentClearedWhenSettingInnerHTML?a.cloneNode(!0):a},insertHtml:function(g,f,j){var o=this,l,k,n,m,i;g=g.toLowerCase();if(f.insertAdjacentHTML){if(o.ieInsertHtml){i=o.ieInsertHtml(g,f,j);if(i){return i}}l=h[g];if(l){f.insertAdjacentHTML(l[0],j);return f[l[1]]}}else {if(f.nodeType===3){g=g===b?a:g;g=g===c?d:g}k=Ext.supports.CreateContextualFragment?f.ownerDocument.createRange():undefined;m='setStart'+(this.endRe.test(g)?'After':'Before');if(e[g]){if(k){k[m](f);i=k.createContextualFragment(j)}else {i=this.createContextualFragment(j)}f.parentNode.insertBefore(i,g===a?f:f.nextSibling);return f[(g===a?'previous':'next')+'Sibling']}else {n=(g===b?'first':'last')+'Child';if(f.firstChild){if(k){try{k[m](f[n]);i=k.createContextualFragment(j)}catch(p){i=this.createContextualFragment(j)}}else {i=this.createContextualFragment(j)}if(g===b){f.insertBefore(i,f.firstChild)}else {f.appendChild(i)}}else {f.innerHTML=j}return f[n]}}},insertBefore:function(c,d,b){return this.doInsert(c,d,b,a)},insertAfter:function(b,c,a){return this.doInsert(b,c,a,d)},insertFirst:function(c,d,a){return this.doInsert(c,d,a,b)},append:function(b,d,a){return this.doInsert(b,d,a,c)},overwrite:function(b,c,e){var d=this,a;b=Ext.getDom(b);c=d.markup(c);if(d.ieOverwrite){a=d.ieOverwrite(b,c)}if(!a){b.innerHTML=c;a=b.firstChild}return e?Ext.get(a):a},doInsert:function(f,j,k,g){var i=this,h;f=f.dom||Ext.getDom(f);if('innerHTML' in f){h=i.insertHtml(g,f,i.markup(j))}else {h=i.createDom(j,null);if(f.nodeType===3){g=g===b?a:g;g=g===c?d:g}if(e[g]){f.parentNode.insertBefore(h,g===a?f:f.nextSibling)}else {if(f.firstChild&&g===b){f.insertBefore(h,f.firstChild)}else {f.appendChild(h)}}}return k?Ext.get(h):h},createTemplate:function(b){var a=this.markup(b);return new Ext.Template(a)},createHtml:function(a){return this.markup(a)}}},0,0,0,0,0,0,[Ext.dom,'Helper',Ext,'DomHelper',Ext.core,'DomHelper'],0);Ext.define('Ext.overrides.dom.Helper',function(){var a=/^(?:table|thead|tbody|tr|td)$/i,f=/td|tr|tbody|thead/i,e='',d='
    ',c=e+'',b=''+d,h=c+'',g=''+b;return {override:'Ext.dom.Helper',ieInsertHtml:function(d,b,e){var c=null;if(Ext.isIE9m&&a.test(b.tagName)){c=this.insertIntoTable(b.tagName.toLowerCase(),d,b,e)}return c},ieOverwrite:function(b,c){if(Ext.isIE9m&&a.test(b.tagName)){while(b.firstChild){b.removeChild(b.firstChild)}if(c){return this.insertHtml('afterbegin',b,c)}}},ieTable:function(g,f,e,d){var h=-1,a=this.detachedDiv,b,c;a.innerHTML=[f,e,d].join('');while(++ha.interval){a.collect()}a.timerId=Ext.interval(a.collect,a.interval)}},1,0,0,0,0,0,[Ext.dom,'GarbageCollector'],0);Ext.cmd.derive('Ext.event.gesture.Recognizer',Ext.Base,{priority:0,handledEvents:[],config:{onRecognized:Ext.emptyFn,callbackScope:null},constructor:function(a){this.initConfig(a);Ext.event.publisher.Gesture.instance.registerRecognizer(this)},onStart:Ext.emptyFn,onEnd:Ext.emptyFn,onTouchStart:Ext.emptyFn,onTouchMove:Ext.emptyFn,onTouchEnd:Ext.emptyFn,onTouchCancel:Ext.emptyFn,fail:function(){return !1},fire:function(){this.getOnRecognized().apply(this.getCallbackScope(),arguments)},reset:Ext.emptyFn},1,0,0,0,0,[[Ext.mixin.Identifiable.prototype.mixinId||Ext.mixin.Identifiable.$className,Ext.mixin.Identifiable]],[Ext.event.gesture,'Recognizer'],0);Ext.cmd.derive('Ext.event.gesture.SingleTouch',Ext.event.gesture.Recognizer,{inheritableStatics:{NOT_SINGLE_TOUCH:'Not Single Touch',TOUCH_MOVED:'Touch Moved',EVENT_CANCELED:'Event Canceled'},onTouchStart:function(a){if(a.touches.length>1){return this.fail(this.self.NOT_SINGLE_TOUCH)}},onTouchCancel:function(){return !1}},0,0,0,0,0,0,[Ext.event.gesture,'SingleTouch'],0);Ext.cmd.derive('Ext.event.gesture.DoubleTap',Ext.event.gesture.SingleTouch,{priority:300,inheritableStatics:{DIFFERENT_TARGET:'Different Target'},config:{moveDistance:8,tapDistance:24,maxDuration:300},handledEvents:['singletap','doubletap'],singleTapTimer:null,startTime:0,lastTapTime:0,onTouchStart:function(c){var a=this,b;if(Ext.event.gesture.SingleTouch.prototype.onTouchStart.apply(this,arguments)===!1){return !1}b=a.lastStartPoint=c.changedTouches[0].point;a.startPoint=a.startPoint||b;a.startTime=c.time;clearTimeout(a.singleTapTimer)},onTouchMove:function(c){var a=this,b=c.changedTouches[0].point;if(Math.abs(b.getDistanceTo(a.lastStartPoint))>=a.getMoveDistance()){a.startPoint=null;return a.fail(a.self.TOUCH_MOVED)}},onTouchEnd:function(b){var a=this,f=a.getMaxDuration(),d=b.time,g=b.target,e=a.lastTapTime,h=a.lastTarget,i=b.changedTouches[0].point,c;a.lastTapTime=d;a.lastTarget=g;if(e){c=d-e;if(c<=f&&Math.abs(i.getDistanceTo(a.startPoint))<=a.getTapDistance()){if(g!==h){return a.fail(a.self.DIFFERENT_TARGET)}a.lastTarget=null;a.lastTapTime=0;a.fire('doubletap',b,{touch:b.changedTouches[0],duration:c});a.startPoint=null;return}}if(d-a.startTime>f){a.fireSingleTap(b)}else {a.setSingleTapTimer(b)}},setSingleTapTimer:function(b){var a=this;a.singleTapTimer=Ext.defer(function(){a.fireSingleTap(b)},a.getMaxDuration())},fireSingleTap:function(b,a){this.fire('singletap',b,{touch:a});this.startPoint=null},reset:function(){var a=this;a.startTime=a.lastTapTime=0;a.lastStartPoint=a.startPoint=a.singleTapTimer=null}},0,0,0,0,0,0,[Ext.event.gesture,'DoubleTap'],function(a){var b=Ext.manifest.gestures;a.instance=new a(b&&b.doubleTap)});Ext.cmd.derive('Ext.event.gesture.Drag',Ext.event.gesture.SingleTouch,{priority:100,isStarted:!1,startPoint:null,previousPoint:null,lastPoint:null,handledEvents:['dragstart','drag','dragend','dragcancel'],config:{minDistance:8},constructor:function(){Ext.event.gesture.SingleTouch.prototype.constructor.apply(this,arguments);this.initInfo()},initInfo:function(){this.info={touch:null,previous:{x:0,y:0},x:0,y:0,delta:{x:0,y:0},absDelta:{x:0,y:0},flick:{velocity:{x:0,y:0}},direction:{x:0,y:0},time:0,previousTime:{x:0,y:0}}},onTouchStart:function(a){if(Ext.event.gesture.SingleTouch.prototype.onTouchStart.apply(this,arguments)===!1){if(this.isStarted&&this.lastMoveEvent!==null){this.lastMoveEvent.isStopped=!1;this.onTouchEnd(this.lastMoveEvent)}return !1}this.startTime=a.time;this.startPoint=a.changedTouches[0].point},tryDragStart:function(a){var f=this.startPoint,b=a.changedTouches[0],c=b.point,e=this.getMinDistance(),d=this.info;if(Math.abs(c.getDistanceTo(f))>=e){this.isStarted=!0;this.previousPoint=this.lastPoint=c;this.resetInfo('x',a,b);this.resetInfo('y',a,b);d.time=a.time;this.fire('dragstart',a,d)}},onTouchMove:function(a){if(!this.isStarted){this.tryDragStart(a)}if(!this.isStarted){return}var b=a.changedTouches[0],c=b.point;if(this.lastPoint){this.previousPoint=this.lastPoint}this.lastPoint=c;this.lastMoveEvent=a;this.updateInfo('x',a,b);this.updateInfo('y',a,b);this.info.time=a.time;this.fire('drag',a,this.info)},onAxisDragEnd:function(b,a){var c=a.time-a.previousTime[b];if(c>0){a.flick.velocity[b]=(a[b]-a.previous[b])/c}},resetInfo:function(b,h,g){var f=this.lastPoint[b],d=this.startPoint[b],e=f-d,c=b.toUpperCase(),a=this.info;a.touch=g;a.delta[b]=e;a.absDelta[b]=Math.abs(e);a.previousTime[b]=this.startTime;a.previous[b]=d;a[b]=f;a.direction[b]=0;a['start'+c]=this.startPoint[b];a['previous'+c]=a.previous[b];a['page'+c]=a[b];a['delta'+c]=a.delta[b];a['absDelta'+c]=a.absDelta[b];a['previousDelta'+c]=0;a.startTime=this.startTime},updateInfo:function(b,l,k){var e=this,d=e.lastPoint[b],g=e.previousPoint[b],f=e.startPoint[b],i=d-f,a=e.info,h=a.direction,c=b.toUpperCase(),j=a.previous[b];a.touch=k;a.delta[b]=i;a.absDelta[b]=Math.abs(i);if(d!==j&&d!==a[b]){a.previous[b]=a[b];a.previousTime[b]=a.time}a[b]=d;if(d>g){h[b]=1}else {if(dthis.getMaxDuration()){return this.fail(this.self.MAX_DURATION_EXCEEDED)}if(this.isHorizontal&&d>this.getMaxOffset()){this.isHorizontal=!1}if(this.isVertical&&c>this.getMaxOffset()){this.isVertical=!1}if(!this.isVertical||!this.isHorizontal){if(this.isHorizontal&&cj){this.isVertical=!1}if(this.isHorizontal&&i>j){this.isHorizontal=!1}if(this.isVertical&&this.isHorizontal){if(i>h){this.isHorizontal=!1}else {this.isVertical=!1}}if(this.isHorizontal){a=f<0?'left':'right';b=f}else {if(this.isVertical){a=g<0?'up':'down';b=g}}a=this.direction||(this.direction=a);if(a==='up'){b=g*-1}else {if(a==='left'){b=f*-1}}this.distance=b;if(!b){return this.fail(this.self.DISTANCE_NOT_ENOUGH)}if(!this.started){if(a==='right'&&this.startX>d){return this.fail(this.self.NOT_NEAR_EDGE)}else {if(a==='down'&&this.startY>d){return this.fail(this.self.NOT_NEAR_EDGE)}else {if(a==='left'&&o-this.startX>d){return this.fail(this.self.NOT_NEAR_EDGE)}else {if(a==='up'&&n-this.startY>d){return this.fail(this.self.NOT_NEAR_EDGE)}}}}this.started=!0;this.startTime=c.time;this.fire('edgeswipestart',c,{touch:e,direction:a,distance:b,duration:k})}else {this.fire('edgeswipe',c,{touch:e,direction:a,distance:b,duration:k})}},onTouchEnd:function(a){var b;if(this.onTouchMove(a)!==!1){b=a.time-this.startTime;this.fire('edgeswipeend',a,{touch:a.changedTouches[0],direction:this.direction,distance:this.distance,duration:b})}},onTouchCancel:function(a){this.fire('edgeswipecancel',a,{touch:a.changedTouches[0]});return !1},reset:function(){var a=this;a.started=a.direction=a.isHorizontal=a.isVertical=a.startX=a.startY=a.startTime=a.distance=null}},0,0,0,0,0,0,[Ext.event.gesture,'EdgeSwipe'],function(a){var b=Ext.manifest.gestures;a.instance=new a(b&&b.edgeSwipe)});Ext.cmd.derive('Ext.event.gesture.LongPress',Ext.event.gesture.SingleTouch,{priority:400,inheritableStatics:{DURATION_NOT_ENOUGH:'Duration Not Enough'},config:{moveDistance:8,minDuration:1000},handledEvents:['longpress','taphold'],fireLongPress:function(a){this.fire('longpress',a,{touch:a.changedTouches[0],duration:this.getMinDuration()});this.isLongPress=!0},onTouchStart:function(a){if(Ext.event.gesture.SingleTouch.prototype.onTouchStart.apply(this,arguments)===!1){return !1}this.startPoint=a.changedTouches[0].point;this.isLongPress=!1;this.setLongPressTimer(a)},setLongPressTimer:function(b){var a=this;a.timer=Ext.defer(function(){a.fireLongPress(b)},a.getMinDuration())},onTouchMove:function(b){var a=b.changedTouches[0].point;if(Math.abs(a.getDistanceTo(this.startPoint))>=this.getMoveDistance()){return this.fail(this.self.TOUCH_MOVED)}},onTouchEnd:function(){if(!this.isLongPress){return this.fail(this.self.DURATION_NOT_ENOUGH)}},fail:function(){clearTimeout(this.timer);return Ext.event.gesture.SingleTouch.prototype.fail.apply(this,arguments)},reset:function(){this.isLongPress=this.startPoint=null},fire:function(b){if(b==='longpress'){var a=Array.prototype.slice.call(arguments);a[0]='taphold';this.fire.apply(this,a)}return Ext.event.gesture.SingleTouch.prototype.fire.apply(this,arguments)}},0,0,0,0,0,0,[Ext.event.gesture,'LongPress'],function(a){var b=Ext.manifest.gestures;a.instance=new a(b&&b.longPress)});Ext.cmd.derive('Ext.event.gesture.MultiTouch',Ext.event.gesture.Recognizer,{requiredTouchesCount:2,isTracking:!1,isStarted:!1,onTouchStart:function(a){var b=this.requiredTouchesCount,d=a.touches,c=d.length;if(c===b){this.start(a)}else {if(c>b){this.end(a)}}},onTouchEnd:function(a){this.end(a)},onTouchCancel:function(a){this.end(a,!0);return !1},start:function(){if(!this.isTracking){this.isTracking=!0;this.isStarted=!1}},end:function(b,a){if(this.isTracking){this.isTracking=!1;if(this.isStarted){this.isStarted=!1;this[a?'fireCancel':'fireEnd'](b)}}},reset:function(){this.isTracking=this.isStarted=!1}},0,0,0,0,0,0,[Ext.event.gesture,'MultiTouch'],0);Ext.cmd.derive('Ext.event.gesture.Pinch',Ext.event.gesture.MultiTouch,{priority:600,handledEvents:['pinchstart','pinch','pinchend','pinchcancel'],startDistance:0,lastTouches:null,onTouchMove:function(c){if(!this.isTracking){return}var b=c.touches,e,d,a;e=b[0].point;d=b[1].point;a=e.getDistanceTo(d);if(a===0){return}if(!this.isStarted){this.isStarted=!0;this.startDistance=a;this.fire('pinchstart',c,{touches:b,distance:a,scale:1})}else {this.fire('pinch',c,{touches:b,distance:a,scale:a/this.startDistance})}},fireEnd:function(a){this.fire('pinchend',a)},fireCancel:function(a){this.fire('pinchcancel',a)},fail:function(){return Ext.event.gesture.MultiTouch.prototype.fail.apply(this,arguments)},reset:function(){this.lastTouches=null;this.startDistance=0;Ext.event.gesture.MultiTouch.prototype.reset.call(this)}},0,0,0,0,0,0,[Ext.event.gesture,'Pinch'],function(b){var a=Ext.manifest.gestures;b.instance=new b(a&&a.pinch)});Ext.cmd.derive('Ext.event.gesture.Rotate',Ext.event.gesture.MultiTouch,{priority:700,handledEvents:['rotatestart','rotate','rotateend','rotatecancel'],startAngle:0,lastTouches:null,lastAngle:null,onTouchMove:function(g){if(!this.isTracking){return}var b=g.touches,c=this.lastAngle,i,h,a,e,d,f;i=b[0].point;h=b[1].point;a=i.getAngleTo(h);if(c!==null){f=Math.abs(c-a);e=a+360;d=a-360;if(Math.abs(e-c)=this.getMoveDistance()){this.fire('tapcancel',b,{touch:a});return this.fail(this.self.TOUCH_MOVED)}},onTouchEnd:function(a){this.fire('tap',a,{touch:a.changedTouches[0]})},onTouchCancel:function(a){this.fire('tapcancel',a,{touch:a.changedTouches[0]});return !1},reset:function(){this.startPoint=null}},0,0,0,0,0,0,[Ext.event.gesture,'Tap'],function(b){var a=Ext.manifest.gestures;b.instance=new b(a&&a.tap)});Ext.cmd.derive('Ext.event.publisher.Focus',Ext.event.publisher.Dom,{type:'focus',handledEvents:['focusenter','focusleave','focusmove'],handledDomEvents:['focusin','focusout'],doDelegatedEvent:function(a,c){var d=this,b;a=Ext.event.publisher.Dom.prototype.doDelegatedEvent.call(this,a,!1);if(a){if(a.type==='focusout'){if(a.relatedTarget==null){d.processFocusIn(a,a.target,document.body,c)}}else {b=a.relatedTarget;d.processFocusIn(a,b==null||!b.tagName?document.body:b,a.target,c)}}},processFocusIn:function(i,d,e,l){var c=this,h,a,b=[],f,g,j,k;j=Ext.fly(d);k=Ext.fly(e);if(j&&j.isFocusSuspended()||k&&k.isFocusSuspended()){return}for(a=d,h=Ext.dom.Element.getCommonAncestor(e,d,!0);a&&a!==h;a=a.parentNode){b.push(a)}if(b.length){f=c.createSyntheticEvent('focusleave',i,d,e);c.publish('focusleave',b,f);if(f.isStopped){return}}b.length=0;for(a=e;a!==h;a=a.parentNode){b.push(a)}g=c.createSyntheticEvent('focusenter',i,e,d);if(b.length){c.publish('focusenter',b,g);if(g.isStopped){return}}b=c.getPropagatingTargets(h);if(b.length){f=c.createSyntheticEvent('focusmove',i,e,d);c.publish('focusmove',b,f);if(f.isStopped){return}}if(l){c.afterEvent(i)}Ext.GlobalEvents.fireEvent('focus',{event:g,toElement:e,fromElement:d})},createSyntheticEvent:function(d,c,e,b){var a=new Ext.event.Event(c);a.type=d;a.relatedTarget=b;a.target=e;return a}},0,0,0,0,0,0,[Ext.event.publisher,'Focus'],function(a){var b;a.instance=new a();if(!Ext.supports.FocusinFocusoutEvents){this.override({handledDomEvents:['focus','blur'],doDelegatedEvent:function(c,e){var d=this;c=d.callSuper([c,!1]);if(c){clearTimeout(b);b=0;if(c.type==='blur'){var f=c.target===window?document.body:c.target;b=setTimeout(function(){b=0;d.processFocusIn(c,f,document.body,e);a.previousActiveElement=null},0);if(c.target===window||c.target===document){a.previousActiveElement=null}else {a.previousActiveElement=c.target}}else {d.processFocusIn(c,a.previousActiveElement||document.body,c.target===window?document.body:c.target,e)}}}})}});Ext.cmd.derive('Ext.fx.State',Ext.Base,{isAnimatable:{'background-color':!0,'background-image':!0,'background-position':!0,'border-bottom-color':!0,'border-bottom-width':!0,'border-color':!0,'border-left-color':!0,'border-left-width':!0,'border-right-color':!0,'border-right-width':!0,'border-spacing':!0,'border-top-color':!0,'border-top-width':!0,'border-width':!0,'bottom':!0,'color':!0,'crop':!0,'font-size':!0,'font-weight':!0,'height':!0,'left':!0,'letter-spacing':!0,'line-height':!0,'margin-bottom':!0,'margin-left':!0,'margin-right':!0,'margin-top':!0,'max-height':!0,'max-width':!0,'min-height':!0,'min-width':!0,'opacity':!0,'outline-color':!0,'outline-offset':!0,'outline-width':!0,'padding-bottom':!0,'padding-left':!0,'padding-right':!0,'padding-top':!0,'right':!0,'text-indent':!0,'text-shadow':!0,'top':!0,'vertical-align':!0,'visibility':!0,'width':!0,'word-spacing':!0,'z-index':!0,'zoom':!0,'transform':!0},constructor:function(a){this.data={};this.set(a)},setConfig:function(a){this.set(a);return this},setRaw:function(a){this.data=a;return this},clear:function(){return this.setRaw({})},setTransform:function(d,a){var g=this.data,e=Ext.isArray(a),b=g.transform,c,f;if(!b){b=g.transform={translateX:0,translateY:0,translateZ:0,scaleX:1,scaleY:1,scaleZ:1,rotate:0,rotateX:0,rotateY:0,rotateZ:0,skewX:0,skewY:0}}if(typeof d=='string'){switch(d){case 'translate':if(e){c=a.length;if(c==0){break}b.translateX=a[0];if(c==1){break}b.translateY=a[1];if(c==2){break}b.translateZ=a[2]}else {b.translateX=a};break;case 'rotate':if(e){c=a.length;if(c==0){break}b.rotateX=a[0];if(c==1){break}b.rotateY=a[1];if(c==2){break}b.rotateZ=a[2]}else {b.rotate=a};break;case 'scale':if(e){c=a.length;if(c==0){break}b.scaleX=a[0];if(c==1){break}b.scaleY=a[1];if(c==2){break}b.scaleZ=a[2]}else {b.scaleX=a;b.scaleY=a};break;case 'skew':if(e){c=a.length;if(c==0){break}b.skewX=a[0];if(c==1){break}b.skewY=a[1]}else {b.skewX=a};break;default:b[d]=a;}}else {for(f in d){if(d.hasOwnProperty(f)){a=d[f];this.setTransform(f,a)}}}},set:function(b,a){var d=this.data,c;if(typeof b!='string'){for(c in b){a=b[c];if(c==='transform'){this.setTransform(a)}else {d[c]=a}}}else {if(b==='transform'){this.setTransform(a)}else {d[b]=a}}return this},unset:function(b){var a=this.data;if(a.hasOwnProperty(b)){delete a[b]}return this},getData:function(){return this.data}},1,0,0,0,0,0,[Ext.fx,'State'],0);Ext.cmd.derive('Ext.fx.animation.Abstract',Ext.Evented,{isAnimation:!0,config:{name:'',element:null,before:null,from:{},to:{},after:null,states:{},duration:300,easing:'linear',iteration:1,direction:'normal',delay:0,onBeforeStart:null,callback:null,onEnd:null,onBeforeEnd:null,scope:null,reverse:null,preserveEndState:!1,replacePrevious:!0},STATE_FROM:'0%',STATE_TO:'100%',DIRECTION_UP:'up',DIRECTION_DOWN:'down',DIRECTION_LEFT:'left',DIRECTION_RIGHT:'right',stateNameRegex:/^(?:[\d\.]+)%$/,constructor:function(){this.states={};Ext.Evented.prototype.constructor.apply(this,arguments);return this},applyElement:function(a){return Ext.get(a)},applyBefore:function(a,b){if(a){return Ext.factory(a,Ext.fx.State,b)}},applyAfter:function(a,b){if(a){return Ext.factory(a,Ext.fx.State,b)}},setFrom:function(a){return this.setState(this.STATE_FROM,a)},setTo:function(a){return this.setState(this.STATE_TO,a)},getFrom:function(){return this.getState(this.STATE_FROM)},getTo:function(){return this.getState(this.STATE_TO)},setStates:function(b){var c=this.stateNameRegex,a;for(a in b){if(c.test(a)){this.setState(a,b[a])}}return this},getStates:function(){return this.states},updateCallback:function(a){if(a){this.setOnEnd(a)}},end:function(){this.stop()},stop:function(){this.fireEvent('stop',this)},destroy:function(){this.stop();Ext.Evented.prototype.destroy.call(this)},setState:function(c,d){var b=this.getStates(),a;a=Ext.factory(d,Ext.fx.State,b[c]);if(a){b[c]=a}return this},getState:function(a){return this.getStates()[a]},getData:function(){var a=this,b=a.getStates(),d={},e=a.getBefore(),f=a.getAfter(),k=b[a.STATE_FROM],l=b[a.STATE_TO],i=k.getData(),j=l.getData(),h,c,g;for(c in b){if(b.hasOwnProperty(c)){g=b[c];h=g.getData();d[c]=h}}return {before:e?e.getData():{},after:f?f.getData():{},states:d,from:i,to:j,duration:a.getDuration(),iteration:a.getIteration(),direction:a.getDirection(),easing:a.getEasing(),delay:a.getDelay(),onEnd:a.getOnEnd(),onBeforeEnd:a.getOnBeforeEnd(),onBeforeStart:a.getOnBeforeStart(),scope:a.getScope(),preserveEndState:a.getPreserveEndState(),replacePrevious:a.getReplacePrevious()}}},1,0,0,0,0,0,[Ext.fx.animation,'Abstract'],0);Ext.cmd.derive('Ext.fx.animation.Slide',Ext.fx.animation.Abstract,{alternateClassName:'Ext.fx.animation.SlideIn',config:{direction:'left',out:!1,offset:0,easing:'auto',containerBox:'auto',elementBox:'auto',isElementBoxFit:!0,useCssTransform:!0},reverseDirectionMap:{up:'down',down:'up',left:'right',right:'left'},applyEasing:function(a){if(a==='auto'){return 'ease-'+(this.getOut()?'in':'out')}return a},getContainerBox:function(){var a=this._containerBox;if(a==='auto'){a=this.getElement().getParent().getBox()}return a},getElementBox:function(){var a=this._elementBox;if(this.getIsElementBoxFit()){return this.getContainerBox()}if(a==='auto'){a=this.getElement().getBox()}return a},getData:function(){var o=this.getElementBox(),b=this.getContainerBox(),a=o?o:b,j=this.getFrom(),m=this.getTo(),d=this.getOut(),c=this.getOffset(),g=this.getDirection(),n=this.getUseCssTransform(),p=this.getReverse(),e=0,f=0,h,i,k,l;if(p){g=this.reverseDirectionMap[g]}switch(g){case this.DIRECTION_UP:if(d){f=b.top-a.top-a.height-c}else {f=b.bottom-a.bottom+a.height+c};break;case this.DIRECTION_DOWN:if(d){f=b.bottom-a.bottom+a.height+c}else {f=b.top-a.height-a.top-c};break;case this.DIRECTION_RIGHT:if(d){e=b.right-a.right+a.width+c}else {e=b.left-a.left-a.width-c};break;case this.DIRECTION_LEFT:if(d){e=b.left-a.left-a.width-c}else {e=b.right-a.right+a.width+c};break;}h=d?0:e;i=d?0:f;if(n){j.setTransform({translateX:h,translateY:i})}else {j.set('left',h);j.set('top',i)}k=d?e:0;l=d?f:0;if(n){m.setTransform({translateX:k,translateY:l})}else {m.set('left',k);m.set('top',l)}return Ext.fx.animation.Abstract.prototype.getData.apply(this,arguments)}},0,0,0,0,['animation.slide','animation.slideIn'],0,[Ext.fx.animation,'Slide',Ext.fx.animation,'SlideIn'],0);Ext.cmd.derive('Ext.fx.animation.SlideOut',Ext.fx.animation.Slide,{config:{out:!0}},0,0,0,0,['animation.slideOut'],0,[Ext.fx.animation,'SlideOut'],0);Ext.cmd.derive('Ext.fx.animation.Fade',Ext.fx.animation.Abstract,{alternateClassName:'Ext.fx.animation.FadeIn',config:{out:!1,before:{display:null,opacity:0},after:{opacity:null},reverse:null},updateOut:function(c){var b=this.getTo(),a=this.getFrom();if(c){a.set('opacity',1);b.set('opacity',0)}else {a.set('opacity',0);b.set('opacity',1)}}},0,0,0,0,['animation.fade','animation.fadeIn'],0,[Ext.fx.animation,'Fade',Ext.fx.animation,'FadeIn'],0);Ext.cmd.derive('Ext.fx.animation.FadeOut',Ext.fx.animation.Fade,{config:{out:!0,before:{}}},0,0,0,0,['animation.fadeOut'],0,[Ext.fx.animation,'FadeOut'],0);Ext.cmd.derive('Ext.fx.animation.Flip',Ext.fx.animation.Abstract,{config:{easing:'ease-in',direction:'right',half:!1,out:null},getData:function(){var c=this,k=c.getFrom(),m=c.getTo(),j=c.getDirection(),b=c.getOut(),l=c.getHalf(),a=l?90:180,h=1,i=1,d=0,e=0,f=0,g=0;if(b){i=0.8}else {h=0.8}switch(j){case this.DIRECTION_UP:if(b){f=a}else {d=-a};break;case this.DIRECTION_DOWN:if(b){f=-a}else {d=a};break;case this.DIRECTION_RIGHT:if(b){g=a}else {e=-a};break;case this.DIRECTION_LEFT:if(b){g=-a}else {e=a};break;}k.setTransform({rotateX:d,rotateY:e,scale:h});m.setTransform({rotateX:f,rotateY:g,scale:i});return Ext.fx.animation.Abstract.prototype.getData.call(this)}},0,0,0,0,['animation.flip'],0,[Ext.fx.animation,'Flip'],0);Ext.cmd.derive('Ext.fx.animation.Pop',Ext.fx.animation.Abstract,{alternateClassName:'Ext.fx.animation.PopIn',config:{out:!1,before:{display:null,opacity:0},after:{opacity:null}},getData:function(){var b=this.getTo(),a=this.getFrom(),c=this.getOut();if(c){a.set('opacity',1);a.setTransform({scale:1});b.set('opacity',0);b.setTransform({scale:0})}else {a.set('opacity',0);a.setTransform({scale:0});b.set('opacity',1);b.setTransform({scale:1})}return Ext.fx.animation.Abstract.prototype.getData.apply(this,arguments)}},0,0,0,0,['animation.pop','animation.popIn'],0,[Ext.fx.animation,'Pop',Ext.fx.animation,'PopIn'],0);Ext.cmd.derive('Ext.fx.animation.PopOut',Ext.fx.animation.Pop,{config:{out:!0,before:{}}},0,0,0,0,['animation.popOut'],0,[Ext.fx.animation,'PopOut'],0);Ext.cmd.derive('Ext.fx.Animation',Ext.Base,{constructor:function(a){var c=Ext.fx.animation.Abstract,b;if(typeof a=='string'){b=a;a={}}else {if(a&&a.type){b=a.type}}if(b){c=Ext.ClassManager.getByAlias('animation.'+b)}return Ext.factory(a,c)}},1,0,0,0,0,0,[Ext.fx,'Animation'],0);Ext.cmd.derive('Ext.fx.runner.Css',Ext.Evented,{prefixedProperties:{'transform':!0,'transform-origin':!0,'perspective':!0,'transform-style':!0,'transition':!0,'transition-property':!0,'transition-duration':!0,'transition-timing-function':!0,'transition-delay':!0,'animation':!0,'animation-name':!0,'animation-duration':!0,'animation-iteration-count':!0,'animation-direction':!0,'animation-timing-function':!0,'animation-delay':!0},lengthProperties:{'top':!0,'right':!0,'bottom':!0,'left':!0,'width':!0,'height':!0,'max-height':!0,'max-width':!0,'min-height':!0,'min-width':!0,'margin-bottom':!0,'margin-left':!0,'margin-right':!0,'margin-top':!0,'padding-bottom':!0,'padding-left':!0,'padding-right':!0,'padding-top':!0,'border-bottom-width':!0,'border-left-width':!0,'border-right-width':!0,'border-spacing':!0,'border-top-width':!0,'border-width':!0,'outline-width':!0,'letter-spacing':!0,'line-height':!0,'text-indent':!0,'word-spacing':!0,'font-size':!0,'translate':!0,'translateX':!0,'translateY':!0,'translateZ':!0,'translate3d':!0},durationProperties:{'transition-duration':!0,'transition-delay':!0,'animation-duration':!0,'animation-delay':!0},angleProperties:{rotate:!0,rotateX:!0,rotateY:!0,rotateZ:!0,skew:!0,skewX:!0,skewY:!0},lengthUnitRegex:/([a-z%]*)$/,DEFAULT_UNIT_LENGTH:'px',DEFAULT_UNIT_ANGLE:'deg',DEFAULT_UNIT_DURATION:'ms',formattedNameCache:{},transformMethods3d:['translateX','translateY','translateZ','rotate','rotateX','rotateY','rotateZ','skewX','skewY','scaleX','scaleY','scaleZ'],transformMethodsNo3d:['translateX','translateY','rotate','skewX','skewY','scaleX','scaleY'],constructor:function(){var a=this;a.transformMethods=Ext.feature.has.Css3dTransforms?a.transformMethods3d:a.transformMethodsNo3d;a.vendorPrefix=Ext.browser.getStyleDashPrefix();a.ruleStylesCache={};Ext.Evented.prototype.constructor.call(this)},getStyleSheet:function(){var c=this.styleSheet,a,b;if(!c){a=document.createElement('style');a.type='text/css';(document.head||document.getElementsByTagName('head')[0]).appendChild(a);b=document.styleSheets;this.styleSheet=c=b[b.length-1]}return c},applyRules:function(j){var i=this.getStyleSheet(),h=this.ruleStylesCache,k=i.cssRules,d,g,b,c,f,a,e;for(d in j){g=j[d];b=h[d];if(b===undefined){f=k.length;i.insertRule(d+'{}',f);b=h[d]=k.item(f).style}c=b.$cache;if(!c){c=b.$cache={}}for(a in g){e=this.formatValue(g[a],a);a=this.formatName(a);if(c[a]!==e){c[a]=e;if(e===null){b.removeProperty(a)}else {b.setProperty(a,e,'important')}}}}return this},applyStyles:function(f){var c,e,d,b,a,g;for(c in f){if(f.hasOwnProperty(c)){e=document.getElementById(c);if(!e){continue}d=e.style;b=f[c];for(a in b){if(b.hasOwnProperty(a)){g=this.formatValue(b[a],a);a=this.formatName(a);if(g===null){d.removeProperty(a)}else {d.setProperty(a,g,'important')}}}}}return this},formatName:function(b){var c=this.formattedNameCache,a=c[b];if(!a){if((Ext.os.is.Tizen||!Ext.feature.has.CssTransformNoPrefix)&&this.prefixedProperties[b]){a=this.vendorPrefix+b}else {a=b}c[b]=a}return a},formatValue:function(a,c){var j=typeof a,i=this.DEFAULT_UNIT_LENGTH,g,d,b,f,h,e,k;if(a===null){return ''}if(j=='string'){if(this.lengthProperties[c]){k=a.match(this.lengthUnitRegex)[1];if(k.length>0){}else {return a+i}}return a}else {if(j=='number'){if(a==0){return '0'}if(this.lengthProperties[c]){return a+i}if(this.angleProperties[c]){return a+this.DEFAULT_UNIT_ANGLE}if(this.durationProperties[c]){return a+this.DEFAULT_UNIT_DURATION}}else {if(c==='transform'){g=this.transformMethods;h=[];for(b=0,f=g.length;b0?e.join(', '):'none'}}}}return a}},1,0,0,0,0,0,[Ext.fx.runner,'Css'],0);Ext.cmd.derive('Ext.fx.runner.CssTransition',Ext.fx.runner.Css,{alternateClassName:'Ext.Animator',singleton:!0,listenersAttached:!1,constructor:function(){this.runningAnimationsData={};return this.callParent(arguments)},attachListeners:function(){this.listenersAttached=!0;Ext.getWin().on('transitionend','onTransitionEnd',this)},onTransitionEnd:function(c){var a=c.target,b=a.id;if(b&&this.runningAnimationsData.hasOwnProperty(b)){this.refreshRunningAnimationsData(Ext.get(a),[c.browserEvent.propertyName])}},onAnimationEnd:function(d,a,b,c,n){var l=d.getId(),j=this.runningAnimationsData[l],k={},h={},g,f,e,m,i;b.un('stop','onAnimationStop',this);if(j){g=j.nameMap}k[l]=h;if(a.onBeforeEnd){a.onBeforeEnd.call(a.scope||this,d,c)}b.fireEvent('animationbeforeend',b,d,c);this.fireEvent('animationbeforeend',this,b,d,c);if(n||!c&&!a.preserveEndState){f=a.toPropertyNames;for(e=0,m=f.length;e0},refreshRunningAnimationsData:function(i,m,f,g){var s=i.getId(),r=this.runningAnimationsData,e=r[s];if(!e){return}var o=e.nameMap,n=e.nameList,c=e.sessions,h,j,p,d,b,a,k,q,l=!1;f=Boolean(f);g=Boolean(g);if(!c){return this}h=c.length;if(h===0){return this}if(g){e.nameMap={};n.length=0;for(b=0;b');b.close();this.testElement=c=b.createElement('div');c.style.setProperty('position','absolute','important');b.body.appendChild(c);this.testElementComputedStyle=window.getComputedStyle(c)}return c},getCssStyleValue:function(b,a){var c=this.getTestElement(),e=this.testElementComputedStyle,d=c.style;d.setProperty(b,a);if(Ext.browser.is.Firefox){c.offsetHeight}a=e.getPropertyValue(b);d.removeProperty(b);return a},run:function(t){var a=this,H=a.lengthProperties,E={},j={},d={},i,f,m,k,F,g,e,u,v,s,r,w,x,G,c,o,y,C,h,b,l,D,n,z,q,p,A,B;if(!a.listenersAttached){a.attachListeners()}t=Ext.Array.from(t);for(w=0,G=t.length;w0){a.refreshRunningAnimationsData(i,Ext.Array.merge(g,e),!0,d.replacePrevious)}q=s.nameMap;p=s.nameList;y={};for(x=0;x0){g=Ext.Array.difference(p,g);e=Ext.Array.merge(g,e);r['transition-property']=g}E[f]=r;j[f]=Ext.apply({},k);j[f]['transition-property']=e;j[f]['transition-duration']=d.duration;j[f]['transition-timing-function']=d.easing;j[f]['transition-delay']=d.delay;c.startTime=Date.now()}v=a.$className;a.applyStyles(E);u=function(b){if(b.data===v&&b.source===window){window.removeEventListener('message',u,!1);a.applyStyles(j)}};if(window.requestAnimationFrame){window.requestAnimationFrame(function(){window.addEventListener('message',u,!1);window.postMessage(v,'*')})}else {Ext.defer(function(){window.addEventListener('message',u,!1);window.postMessage(v,'*')},1)}},onAnimationStop:function(h){var c=this.runningAnimationsData,e,f,d,b,g,a;for(e in c){if(c.hasOwnProperty(e)){f=c[e];d=f.sessions;for(b=0,g=d.length;b'){this.isParentReference=!0;a=a.substring(0,b)}return a}}},0,0,0,0,0,0,[Ext.mixin,'Container'],0);Ext.cmd.derive('Ext.mixin.Responsive',Ext.Mixin,function(a){return {mixinConfig:{id:'responsive',after:{destroy:'destroy'}},config:{responsiveConfig:{$value:undefined,merge:function(c,d,g,f){if(!c){return d}var e=d?Ext.Object.chain(d):{},b;for(b in c){if(!f||!(b in e)){e[b]={fn:null,config:c[b]}}}return e}},responsiveFormulas:{$value:0,merge:function(c,d,e,b){return this.mergeNew(c,d,e,b)}}},destroy:function(){a.unregister(this);this.callParent()},privates:{statics:{active:!1,all:{},context:Ext.Object.chain(Ext.platformTags),count:0,nextId:0,activate:function(){a.active=!0;a.updateContext();Ext.on('resize',a.onResize,a)},deactivate:function(){a.active=!1;Ext.un('resize',a.onResize,a)},notify:function(){var b=a.all,e=a.context,d=Ext.GlobalEvents,f=a.timer,c;if(f){a.timer=null;Ext.Function.cancelAnimationFrame(f)}a.updateContext();Ext.suspendLayouts();d.fireEvent('beforeresponsiveupdate',e);for(c in b){b[c].setupResponsiveContext()}d.fireEvent('beginresponsiveupdate',e);for(c in b){b[c].updateResponsiveState()}d.fireEvent('responsiveupdate',e);Ext.resumeLayouts(!0)},onResize:function(){if(!a.timer){a.timer=Ext.Function.requestAnimationFrame(a.onTimer)}},onTimer:function(){a.timer=null;a.notify()},processConfig:function(c,d,b){var g=d&&d[b],f=c.config,h,e;if(g){e=c.getConfigurator();h=e.configs[b];f[b]=h.merge(g,f[b],c)}},register:function(b){var c=b.$responsiveId;if(!c){b.$responsiveId=c=++a.nextId;a.all[c]=b;if(++a.count===1){a.activate()}}},unregister:function(b){var c=b.$responsiveId;if(c in a.all){b.$responsiveId=null;delete a.all[c];if(--a.count===0){a.deactivate()}}},updateContext:function(){var e=Ext.Element,d=e.getViewportWidth(),c=e.getViewportHeight(),b=a.context;b.width=d;b.height=c;b.tall=d','',' ({childCount} children)','','',' ({depth} deep)','','',', {type}: {[this.time(values.sum)]} msec (','avg={[this.time(values.sum / parent.count)]}',')','','
    '].join(''),{time:function(a){return Math.round(a*100)/100}})}var a=this.getData(b);a.name=this.name;a.pure.type='Pure';a.total.type='Total';a.times=[a.pure,a.total];return c.apply(a)},getData:function(b){var a=this;return {count:a.count,childCount:a.childCount,depth:a.maxDepth,pure:setToJSON(a.count,a.childCount,b,a.pure),total:setToJSON(a.count,a.childCount,b,a.total)}},enter:function(){var c=this,d={accum:c,leave:leaveFrame,childTime:0,parent:b};++c.depth;if(c.maxDepth0){d=a==='this'?this:typeof a==='string'?this[a]:typeof a==='number'?arguments[a]:null;if(d){f=d.id}if(f!=null){console.log(b+' for '+f+': '+c+'ms')}else {console.log(b+' for unknown: '+c+'ms')}if(console.trace){console.trace()}}return h}}(b,d[b])}Ext.override(f,c)}}}}},1,0,0,0,0,0,[Ext.perf,'Monitor',Ext,'Perf'],0);Ext.cmd.derive('Ext.plugin.Abstract',Ext.Base,{alternateClassName:'Ext.AbstractPlugin',isPlugin:!0,constructor:function(a){if(a){this.pluginConfig=a;this.initConfig(a)}},clonePlugin:function(a){return new this.self(Ext.apply({},a,this.pluginConfig))},setCmp:function(a){this.cmp=a},getCmp:function(){return this.cmp},init:Ext.emptyFn,destroy:function(){this.cmp=this.pluginConfig=null;this.callParent()},onClassExtended:function(c,b,d){var a=b.alias;if(a&&!b.ptype){if(Ext.isArray(a)){a=a[0]}c.prototype.ptype=a.split('plugin.')[1]}},resolveListenerScope:function(b){var a=this,d=a.getCmp(),c;if(d){c=d.resolveSatelliteListenerScope(a,b)}return c||a.mixins.observable.resolveListenerScope.call(a,b)}},1,0,0,0,0,0,[Ext.plugin,'Abstract',Ext,'AbstractPlugin'],0);Ext.define('Ext.overrides.plugin.Abstract',{override:'Ext.plugin.Abstract',$configStrict:!1,$configPrefixed:!1,disabled:!1,getState:null,applyState:null,enable:function(){this.disabled=!1},disable:function(){this.disabled=!0}});Ext.cmd.derive('Ext.util.ItemCollection',Ext.util.MixedCollection,{alternateClassName:'Ext.ItemCollection',getKey:function(a){return a.getItemId&&a.getItemId()},has:function(a){return this.map.hasOwnProperty(a.getId())}},0,0,0,0,0,0,[Ext.util,'ItemCollection',Ext,'ItemCollection'],0);Ext.cmd.derive('Ext.util.TaskManager',Ext.util.TaskRunner,{alternateClassName:['Ext.TaskManager'],singleton:!0},0,0,0,0,0,0,[Ext.util,'TaskManager',Ext,'TaskManager'],0);Ext.cmd.derive('Ext.util.TextMetrics',Ext.Base,{statics:{shared:null,measure:function(d,e,c){var b=this,a=b.shared;if(!a){a=b.shared=new b(d,c)}a.bind(d);a.setFixedWidth(c||'auto');return a.getSize(e)},destroy:function(){var a=this;Ext.destroy(a.shared);a.shared=null}},constructor:function(c,b){var d=this,a=Ext.getBody().createChild({role:'presentation',cls:'x-textmetrics'});a.setVisibilityMode(1);d.measure=a;if(c){d.bind(c)}a.position('absolute');a.setLocalXY(-1000,-1000);a.hide();if(b){a.setWidth(b)}},getSize:function(c){var a=this.measure,b;a.setHtml(c);b=a.getSize();a.setHtml('');return b},bind:function(b){var a=this;a.el=Ext.get(b);a.measure.setStyle(a.el.getStyle(['font-size','font-style','font-weight','font-family','line-height','text-transform','letter-spacing','word-break']))},setFixedWidth:function(a){this.measure.setWidth(a)},getWidth:function(a){this.measure.dom.style.width='auto';return this.getSize(a).width},getHeight:function(a){return this.getSize(a).height},destroy:function(){var a=this;a.el=a.measure=Ext.destroy(a.measure);a.callParent()}},1,0,0,0,0,0,[Ext.util,'TextMetrics'],function(){Ext.Element.override({getTextWidth:function(a,c,b){return Ext.Number.constrain(Ext.util.TextMetrics.measure(this.dom,Ext.valueFrom(a,this.dom.innerHTML,!0)).width,c||0,b||1000000)}})});Ext.define(null,{override:'Ext.event.publisher.Focus',compatibility:Ext.isIE10m,doDelegatedEvent:function(a,d){var c=document.body,b=Ext.synchronouslyFocusing;if(b&&(a.type==='focusout'&&a.srcElement===b&&a.toElement===c||a.type==='focusin'&&a.srcElement===c&&a.fromElement===b&&a.toElement===null)){return}return this.callParent([a,d])}});Ext.define(null,{override:'Ext.scroll.DomScroller',compatibility:Ext.isIE8,privates:{doScrollTo:function(a,b,j){var c=this,f=c.getElement(),e,d,i,g,h;if(f&&!f.destroyed){d=this.getElement().dom;g=a===Infinity;h=b===Infinity;if(g||h){e=c.getMaxPosition();if(g){a=e.x}if(h){b=e.y}}a=c.convertX(a);if(j){i={};if(b!=null){i.scrollTop=b}if(a!=null){i.scrollLeft=a}f.animate(Ext.mergeIf({to:{scrollTop:b,scrollLeft:a}},j))}else {if(a!=null&&b!=null){c.deferDomScroll=!0}if(b!=null){d.scrollTop=b}if(a!=null){d.scrollLeft=a}if(c.deferDomScroll){c.deferDomScroll=!1;+d.scrollLeft;d.scrollLeft=a}}c.positionDirty=!0}},onDomScroll:function(){var a=this;if(a.deferDomScroll){return}a.callParent()}}});Ext.cmd.derive('Ext.ElementLoader',Ext.Base,{statics:{Renderer:{Html:function(c,b,a){c.getTarget().setHtml(b.responseText,a.scripts===!0,a.rendererScope);return !0}}},url:null,params:null,baseParams:null,autoLoad:!1,target:null,loadMask:!1,ajaxOptions:null,scripts:!1,isLoader:!0,constructor:function(c){var a=this,b;a.mixins.observable.constructor.call(a,c);a.setTarget(a.target);if(a.autoLoad){b=a.autoLoad;if(b===!0){b=null}a.load(b)}},setTarget:function(a){var b=this;a=Ext.get(a);if(b.target&&b.target!==a){b.abort()}b.target=a},getTarget:function(){return this.target||null},abort:function(){var a=this.active;if(a!==undefined){Ext.Ajax.abort(a.request);if(a.mask){this.removeMask()}delete this.active}},removeMask:function(){this.target.unmask()},addMask:function(a){this.target.mask(a===!0?null:a)},load:function(b){b=Ext.apply({},b);var a=this,d=Ext.isDefined(b.loadMask)?b.loadMask:a.loadMask,c=Ext.apply({},b.params),e=Ext.apply({},b.ajaxOptions),f=b.callback||a.callback,g=b.scope||a.scope||a;Ext.applyIf(e,a.ajaxOptions);Ext.applyIf(b,e);Ext.applyIf(c,a.params);Ext.apply(c,a.baseParams);Ext.applyIf(b,{url:a.url});Ext.apply(b,{scope:a,params:c,callback:a.onComplete});if(a.fireEvent('beforeload',a,b)===!1){return}if(d){a.addMask(d)}a.active={options:b,mask:d,scope:g,callback:f,success:b.success||a.success,failure:b.failure||a.failure,renderer:b.renderer||a.renderer,scripts:Ext.isDefined(b.scripts)?b.scripts:a.scripts};a.active.request=Ext.Ajax.request(b);a.setOptions(a.active,b)},setOptions:function(b,a){b.rendererScope=a.rendererScope||this.rendererScope||this},onComplete:function(d,e,c){var a=this,b=a.active,g,f;if(b){f=b.scope;g=b.rendererScope;if(e){e=a.getRenderer(b.renderer).call(g,a,c,b)!==!1}if(e){Ext.callback(b.success,f,[a,c,d]);a.fireEvent('load',a,c,d)}else {Ext.callback(b.failure,f,[a,c,d]);a.fireEvent('exception',a,c,d)}Ext.callback(b.callback,f,[a,e,c,d]);if(b.mask){a.removeMask()}}delete a.active},getRenderer:function(a){if(Ext.isFunction(a)){return a}return this.statics().Renderer.Html},startAutoRefresh:function(b,c){var a=this;a.stopAutoRefresh();a.autoRefresh=Ext.interval(function(){a.load(c)},b)},stopAutoRefresh:function(){clearInterval(this.autoRefresh);delete this.autoRefresh},isAutoRefreshing:function(){return Ext.isDefined(this.autoRefresh)},destroy:function(){var a=this;a.stopAutoRefresh();delete a.target;a.abort();a.callParent()}},1,0,0,0,0,[[Ext.util.Observable.prototype.mixinId||Ext.util.Observable.$className,Ext.util.Observable]],[Ext,'ElementLoader'],0);Ext.cmd.derive('Ext.ComponentLoader',Ext.ElementLoader,{statics:{Renderer:{Data:function(c,b,d){var a=!0;try{c.getTarget().update(Ext.decode(b.responseText))}catch(e){a=!1}return a},Component:function(f,d,e){var b=!0,a=f.getTarget(),c=[];try{c=Ext.decode(d.responseText)}catch(g){b=!1}if(b){a.suspendLayouts();if(e.removeAll){a.removeAll()}a.add(c);a.resumeLayouts(!0)}return b}}},target:null,loadOnRender:!1,loadMask:!1,renderer:'html',setTarget:function(b){var a=this;if(Ext.isString(b)){b=Ext.getCmp(b)}if(a.target&&a.target!==b){a.abort()}a.target=b;if(b&&a.loadOnRender){if(b.rendered){a.doLoadOnRender()}else {a.mon(b,'render',a.doLoadOnRender,a)}}},doLoadOnRender:function(){var a=this.loadOnRender;this.load(Ext.isObject(a)?a:null)},removeMask:function(){this.target.setLoading(!1)},addMask:function(a){this.target.setLoading(a)},setOptions:function(b,a){b.removeAll=Ext.isDefined(a.removeAll)?a.removeAll:this.removeAll;b.rendererScope=a.rendererScope||this.rendererScope||this.target},getRenderer:function(a){if(Ext.isFunction(a)){return a}var b=this.statics().Renderer;switch(a){case 'component':return b.Component;case 'data':return b.Data;default:return Ext.ElementLoader.Renderer.Html;}}},0,0,0,0,0,0,[Ext,'ComponentLoader'],0);Ext.cmd.derive('Ext.layout.SizeModel',Ext.Base,{constructor:function(e){var a=this,b=a.self,d=b.sizeModelsArray,c;Ext.apply(a,e);a[c=a.name]=!0;a.fixed=!(a.auto=a.natural||a.shrinkWrap);d[a.ordinal=d.length]=b[c]=b.sizeModels[c]=a},statics:{sizeModelsArray:[],sizeModels:{}},calculated:!1,configured:!1,constrainedMax:!1,constrainedMin:!1,natural:!1,shrinkWrap:!1,calculatedFromConfigured:!1,calculatedFromNatural:!1,calculatedFromShrinkWrap:!1,names:null},1,0,0,0,0,0,[Ext.layout,'SizeModel'],function(){var a=this,d=a.sizeModelsArray,b,c,f,g,e;new a({name:'calculated'});new a({name:'configured',names:{width:'width',height:'height'}});new a({name:'natural'});new a({name:'shrinkWrap'});new a({name:'calculatedFromConfigured',configured:!0,calculatedFrom:!0,names:{width:'width',height:'height'}});new a({name:'calculatedFromNatural',natural:!0,calculatedFrom:!0});new a({name:'calculatedFromShrinkWrap',shrinkWrap:!0,calculatedFrom:!0});new a({name:'constrainedMax',configured:!0,constrained:!0,names:{width:'maxWidth',height:'maxHeight'}});new a({name:'constrainedMin',configured:!0,constrained:!0,names:{width:'minWidth',height:'minHeight'}});new a({name:'constrainedDock',configured:!0,constrained:!0,constrainedByMin:!0,names:{width:'dockConstrainedWidth',height:'dockConstrainedHeight'}});for(b=0,f=d.length;b-1&&e','
    role="presentation"','class="{innerCtCls}">','{%this.renderBody(out,values)%}','
    ',''],beginLayout:function(a){Ext.layout.container.Container.prototype.beginLayout.apply(this,arguments);this.initContextItems(a)},beforeLayoutCycle:function(d){var a=this.owner,c=a.inheritedState,b=a.inheritedStateInner;if(!c||c.invalid){c=a.getInherited();b=a.inheritedStateInner}if(d.widthModel.shrinkWrap){b.inShrinkWrapTable=!0}else {delete b.inShrinkWrapTable}},beginLayoutCycle:function(e){var a=this,g=a.outerCt,l=a.lastOuterCtWidth||'',k=a.lastOuterCtHeight||'',j=a.lastOuterCtTableLayout||'',i=e.state,f,d,c,b,h;Ext.layout.container.Container.prototype.beginLayoutCycle.apply(this,arguments);d=c=b='';if(!e.widthModel.shrinkWrap){d='100%';h=a.owner.inheritedStateInner;f=a.getOverflowXStyle(e);b=h.inShrinkWrapTable||f==='auto'||f==='scroll'?'':'fixed'}if(!e.heightModel.shrinkWrap&&!Ext.supports.PercentageHeightOverflowBug){c='100%'}if(d!==l||a.hasOuterCtPxWidth){g.setStyle('width',d);a.lastOuterCtWidth=d;a.hasOuterCtPxWidth=!1}if(b!==j){g.setStyle('table-layout',b);a.lastOuterCtTableLayout=b}if(c!==k||a.hasOuterCtPxHeight){g.setStyle('height',c);a.lastOuterCtHeight=c;a.hasOuterCtPxHeight=!1}if(a.hasInnerCtPxHeight){a.innerCt.setStyle('height','');a.hasInnerCtPxHeight=!1}i.overflowAdjust=i.overflowAdjust||a.lastOverflowAdjust},calculate:function(b){var a=this,d=b.state,c=a.getContainerSize(b,!0),e=d.calculatedItems||(d.calculatedItems=a.calculateItems?a.calculateItems(b,c):!0);a.setCtSizeIfNeeded(b,c);if(e&&b.hasDomProp('containerChildrenSizeDone')){a.calculateContentSize(b);if(c.gotAll){if(a.manageOverflow&&!b.state.secondPass&&!a.reserveScrollbar){a.calculateOverflow(b,c)}return}}a.done=!1},calculateContentSize:function(a){var b=this,f=(a.widthModel.shrinkWrap?1:0)|(a.heightModel.shrinkWrap?2:0),d=f&1||undefined,c=f&2||undefined,e=0,g=a.props;if(d){if(isNaN(g.contentWidth)){++e}else {d=undefined}}if(c){if(isNaN(g.contentHeight)){++e}else {c=undefined}}if(e){if(d&&!a.setContentWidth(b.measureContentWidth(a))){b.done=!1}if(c&&!a.setContentHeight(b.measureContentHeight(a))){b.done=!1}}},calculateOverflow:function(d){var c=this,g,f,e,a,h,i,b;h=c.getOverflowXStyle(d)==='auto';i=c.getOverflowYStyle(d)==='auto';if(h||i){e=Ext.getScrollbarSize();b=d.overflowContext.el.dom;a=0;if(b.scrollWidth>b.clientWidth){a|=1}if(b.scrollHeight>b.clientHeight){a|=2}g=i&&a&2?e.width:0;f=h&&a&1?e.height:0;if(g!==c.lastOverflowAdjust.width||f!==c.lastOverflowAdjust.height){c.done=!1;d.invalidate({state:{overflowAdjust:{width:g,height:f},overflowState:a,secondPass:!0}})}}},completeLayout:function(a){this.lastOverflowAdjust=a.state.overflowAdjust},doRenderBody:function(b,a){var c=a.$layout,d=Ext.XTemplate,e=c.beforeBodyTpl,f=c.afterBodyTpl;if(e){d.getTpl(c,'beforeBodyTpl').applyOut(a,b)}this.renderItems(b,a);this.renderContent(b,a);if(f){d.getTpl(c,'afterBodyTpl').applyOut(a,b)}},doRenderPadding:function(d,b){var e=b.$layout,a=b.$layout.owner,c=a[a.contentPaddingProperty];if(e.managePadding&&c){d.push('padding:',a.unitizeBox(c))}},finishedLayout:function(b){var a=this.innerCt;Ext.layout.container.Container.prototype.finishedLayout.apply(this,arguments);if(Ext.isIE8){a.repaint()}if(Ext.isOpera){a.setStyle('position','relative');a.dom.scrollWidth;a.setStyle('position','')}},getContainerSize:function(c,d){var b=Ext.layout.container.Container.prototype.getContainerSize.apply(this,arguments),a=c.state.overflowAdjust;if(a){b.width-=a.width;b.height-=a.height}return b},getRenderData:function(){var b=this,a=Ext.layout.container.Container.prototype.getRenderData.call(this);a.innerCtCls=b.innerCtCls;a.outerCtCls=b.outerCtCls;return a},getRenderTarget:function(){return this.innerCt},getElementTarget:function(){return this.innerCt},getOverflowXStyle:function(a){return a.overflowXStyle||(a.overflowXStyle=this.owner.scrollFlags.overflowX||a.overflowContext.getStyle('overflow-x'))},getOverflowYStyle:function(a){return a.overflowYStyle||(a.overflowYStyle=this.owner.scrollFlags.overflowY||a.overflowContext.getStyle('overflow-y'))},initContextItems:function(a){var b=this,d=a.target,c=b.owner.getOverflowEl();a.outerCtContext=a.getEl('outerCt',b);a.innerCtContext=a.getEl('innerCt',b);a.overflowContext=c===a.el?a:a.getEl(c);if(d[d.contentPaddingProperty]!==undefined){a.paddingContext=a.innerCtContext}},initLayout:function(){var a=this,b=Ext.getScrollbarSize().width,c=a.owner;Ext.layout.container.Container.prototype.initLayout.call(this);if(b&&a.manageOverflow&&!a.hasOwnProperty('lastOverflowAdjust')){if(c.scrollable||a.reserveScrollbar){a.lastOverflowAdjust={width:b,height:0}}}},measureContentHeight:function(b){var a=this.outerCt.getHeight(),c=b.target;if(this.managePadding&&c[c.contentPaddingProperty]===undefined){a+=b.targetContext.getPaddingInfo().height}return a},measureContentWidth:function(f){var a,b,e,c,d;if(this.chromeCellMeasureBug){a=this.innerCt.dom;b=a.style;e=b.display;if(e==='table-cell'){b.display='';a.offsetWidth;b.display=e}}if(Ext.isSafari){a=this.outerCt.dom;b=a.style;b.display='table-cell';a.offsetWidth;a.style.display=''}c=this.outerCt.getWidth();d=f.target;if(this.managePadding&&d[d.contentPaddingProperty]===undefined){c+=f.targetContext.getPaddingInfo().width}return c},setCtSizeIfNeeded:function(a,h){var c=this,b=h.height,k=a.paddingContext.getPaddingInfo(),g=c.getTarget(),f=c.getOverflowXStyle(a),j=f==='auto'||f==='scroll',i=Ext.getScrollbarSize(),e,d;if(b&&!a.heightModel.shrinkWrap){if(Ext.supports.PercentageHeightOverflowBug){e=!0}if(Ext.isIE8){d=!0}if((e||d)&&j&&g.dom.scrollWidth>g.dom.clientWidth){b=Math.max(b-i.height,0)}if(e){a.outerCtContext.setProp('height',b+k.height);c.hasOuterCtPxHeight=!0}if(d){a.innerCtContext.setProp('height',b);c.hasInnerCtPxHeight=!0}}},setupRenderTpl:function(a){Ext.layout.container.Container.prototype.setupRenderTpl.apply(this,arguments);a.renderPadding=this.doRenderPadding},getContentTarget:function(){return this.innerCt},getScrollerEl:function(){return this.outerCt}},0,0,0,0,['layout.auto','layout.autocontainer'],0,[Ext.layout.container,'Auto'],function(){this.prototype.chromeCellMeasureBug=Ext.isChrome&&Ext.chromeVersion>=26});Ext.cmd.derive('Ext.ZIndexManager',Ext.Base,{alternateClassName:'Ext.WindowGroup',statics:{zBase:9000,activeCounter:0},constructor:function(b){var a=this;a.id=Ext.id(null,'zindex-mgr-');a.zIndexStack=new Ext.util.Collection({sorters:{sorterFn:function(c,d){var a=(c.alwaysOnTop||0)-(d.alwaysOnTop||0);if(!a){a=c.getActiveCounter()-d.getActiveCounter()}return a}},filters:{filterFn:function(a){return a.isVisible()}}});a.zIndexStack.addObserver(a);a.front=null;a.globalListeners=Ext.GlobalEvents.on({beforehide:a.onComponentShowHide,show:a.onComponentShowHide,scope:a,destroyable:!0});if(b){if(b.isContainer){b.on('resize',a.onContainerResize,a);a.zseed=Ext.Number.from(a.rendered?b.getEl().getStyle('zIndex'):undefined,a.getNextZSeed());a.targetEl=b.getTargetEl();a.container=b}else {Ext.on('resize',a.onContainerResize,a);a.zseed=a.getNextZSeed();a.targetEl=Ext.get(b)}}else {a.zseed=a.getNextZSeed();Ext.onInternalReady(function(){Ext.on('resize',a.onContainerResize,a);a.targetEl=Ext.getBody()})}},getId:function(){return this.id},getNextZSeed:function(){return Ext.ZIndexManager.zBase+=10000},setBase:function(a){this.zseed=a;return this.onCollectionSort()},onCollectionSort:function(){var d=this,b=d.front,k=b&&b.containsFocus,g=d.zseed,i=d.zIndexStack.getRange(),j=i.length,e,c,f,a,h=!1;for(e=0;e0;){a=c[b];if(a.isComponent&&e.call(d||a,a)===!1){return}}},destroy:function(){var a=this,c=a.zIndexStack.getRange(),d=c.length,b;for(b=0;b1){b.refresh()}if(a.hasListeners.afterlayout){a.fireEvent('afterlayout',a,c)}},beforeDestroy:function(){var a=this,d=a.items,c=a.floatingItems,b;if(d){while(b=d.first()){a.doRemove(b,!0)}}if(c){while(b=c.first()){a.doRemove(b,!0)}}Ext.destroy(a.layout);Ext.Component.prototype.beforeDestroy.call(this)},destroy:function(){var a=this;Ext.Component.prototype.destroy.call(this);if(a.items){a.items.destroy()}if(a.floatingItems){a.floatingItems.destroy()}a.refs=a.items=a.floatingItems=a.layout=null},beforeRender:function(){var a=this,c=a.getLayout(),b;a.preventChildDisable=!0;Ext.Component.prototype.beforeRender.call(this);a.preventChildDisable=!1;if(!c.initialized){c.initLayout()}b=c.targetCls;if(b){a.applyTargetCls(b)}},cascade:function(f,e,d){var a=this,h=a.items?a.items.items:[],j=h.length,g=0,b,c=d?d.concat(a):[a],i=c.length-1;if(f.apply(e||a,c)!==!1){for(;g','
    ','
    {msg}
    ','
    ',''],maskOnDisable:!1,skipLayout:!0,constructor:function(c){var a=this,b;if(arguments.length===2){b=a.target=c;c=arguments[1]}else {b=c.target}Ext.Component.prototype.constructor.call(this,c);if(b.isComponent){a.ownerCt=b;a.hidden=!0;a.renderTo=a.getMaskTarget();a.external=a.renderTo===Ext.getBody();a.bindComponent(b)}else {b=Ext.get(b);a.isElement=!0;a.renderTo=a.target}a.render(a.renderTo);if(a.store){a.bindStore(a.store,!0)}},initRenderData:function(){var a=Ext.Component.prototype.initRenderData.apply(this,arguments);a.msg=this.msg||'';return a},onRender:function(){Ext.Component.prototype.onRender.apply(this,arguments);this.maskEl=this.el},bindComponent:function(b){var a=this,c={scope:this,resize:a.sizeMask};if(a.external){c.added=a.onComponentAdded;c.removed=a.onComponentRemoved;if(b.floating){c.move=a.sizeMask;a.activeOwner=b}else {if(b.ownerCt){a.onComponentAdded(b.ownerCt)}}}a.mon(b,c);if(a.external){a.mon(Ext.GlobalEvents,{show:a.onContainerShow,hide:a.onContainerHide,expand:a.onContainerExpand,collapse:a.onContainerCollapse,scope:a})}},onComponentAdded:function(b){var a=this;delete a.activeOwner;a.floatParent=b;if(!b.floating){b=b.up('[floating]')}if(b){a.activeOwner=b;a.mon(b,'move',a.sizeMask,a);a.mon(b,'tofront',a.onOwnerToFront,a)}else {a.preventBringToFront=!0}b=a.floatParent.ownerCt;if(a.rendered&&a.isVisible()&&b){a.floatOwner=b;a.mon(b,'afterlayout',a.sizeMask,a,{single:!0})}},onComponentRemoved:function(d){var a=this,b=a.activeOwner,c=a.floatOwner;if(b){a.mun(b,'move',a.sizeMask,a);a.mun(b,'tofront',a.onOwnerToFront,a)}if(c){a.mun(c,'afterlayout',a.sizeMask,a)}delete a.activeOwner;delete a.floatOwner},afterRender:function(){var a=this;Ext.Component.prototype.afterRender.apply(this,arguments);if(Ext.isIE){a.el.on('mousedown',a.onMouseDown,a)}this.el.skipGarbageCollection=!0},onMouseDown:function(b){var a=this.el;if(b.within(a)){b.preventDefault();a.focus()}},onOwnerToFront:function(b,a){this.el.setStyle('zIndex',a+1)},onContainerShow:function(a){if(!this.isHierarchicallyHidden()){this.onComponentShow()}},onContainerHide:function(a){if(this.isHierarchicallyHidden()){this.onComponentHide()}},onContainerExpand:function(a){if(!this.isHierarchicallyHidden()){this.onComponentShow()}},onContainerCollapse:function(a){if(this.isHierarchicallyHidden()){this.onComponentHide()}},onComponentHide:function(){var a=this;if(a.rendered&&a.isVisible()){a.hide();a.showNext=!0}},onComponentShow:function(){if(this.showNext){this.show()}delete this.showNext},sizeMask:function(){var a=this,b=a.activeOwner||a.target,c=a.external?a.getOwner().el:a.getMaskTarget();if(a.rendered&&a.isVisible()){if(a.external){if(!a.isElement&&b.floating){a.onOwnerToFront(b,b.el.getZIndex())}a.el.setSize(c.getSize()).alignTo(c,'tl-tl')}a.msgWrapEl.center(a.el)}},bindStore:function(a,c){var b=this;Ext.destroy(b.proxyListeners);b.mixins.storeholder.bindStore.apply(b,arguments);a=b.store;if(a){while(a.getSource){a=a.getSource()}if(!a.loadsSynchronously()){b.proxyListeners=a.getProxy().on({exception:b.onLoad,scope:b,destroyable:!0})}if(a.isLoading()){b.onBeforeLoad()}}},getStoreListeners:function(d){var c=this.onLoad,b=this.onBeforeLoad,a={cachemiss:b,cachefilled:{fn:c,buffer:100}};if(!d.loadsSynchronously()){a.beforeload=b;a.load=c}return a},onDisable:function(){Ext.Component.prototype.onDisable.apply(this,arguments);if(this.loading){this.onLoad()}},getOwner:function(){return this.ownerCt||this.ownerCmp||this.floatParent},getMaskTarget:function(){var a=this.getOwner();if(this.isElement){return this.target}return this.useTargetEl?a.getTargetEl():a.getMaskTarget()||Ext.getBody()},onBeforeLoad:function(){var b=this,a=b.getOwner(),c;if(!b.disabled){b.loading=!0;if(a.componentLayoutCounter){b.maybeShow()}else {c=a.afterComponentLayout;a.afterComponentLayout=function(){a.afterComponentLayout=c;c.apply(a,arguments);b.maybeShow()}}}},maybeShow:function(){var a=this,b=a.getOwner();if(!b.isVisible(!0)){a.showNext=!0}else {if(a.loading&&b.rendered){a.show()}}},hide:function(){var b=this,a=b.ownerCt;if(b.isElement){a.unmask();b.fireEvent('hide',this);return}if(a){a.enableTabbing();a.setMasked(!1)}delete b.showNext;return Ext.Component.prototype.hide.apply(this,arguments)},show:function(){var a=this;if(a.isElement){a.ownerCt.mask(this.useMsg?this.msg:'',this.msgCls);a.fireEvent('show',this);return}return Ext.Component.prototype.show.apply(this,arguments)},afterShow:function(){var a=this,b=a.ownerCt;a.loading=!0;Ext.Component.prototype.afterShow.apply(this,arguments);b.disableTabbing();b.setMasked(!0);a.el.restoreTabbableState();a.syncMaskState()},syncMaskState:function(){var a=this,c=a.ownerCt,b=a.el;if(a.isVisible()){if(a.hasOwnProperty('msgWrapCls')){b.dom.className=a.msgWrapCls}if(a.useMsg){a.msgTextEl.setHtml(a.msg)}else {a.msgEl.hide()}if(a.shim||Ext.useShims){b.enableShim(null,!0)}else {b.disableShim()}if(c.el.contains(Ext.Element.getActiveElement())){a.focus()}a.sizeMask()}},onLoad:function(){this.loading=!1;this.hide()},beforeDestroy:function(){this.ownerCt=null;this.bindStore(null);Ext.Component.prototype.beforeDestroy.call(this)},onDestroy:function(){var a=this;if(a.isElement){a.ownerCt.unmask()}Ext.Component.prototype.onDestroy.call(this)}},1,['loadmask'],['component','box','loadmask'],{'component':!0,'box':!0,'loadmask':!0},['widget.loadmask'],[[Ext.util.StoreHolder.prototype.mixinId||Ext.util.StoreHolder.$className,Ext.util.StoreHolder]],[Ext,'LoadMask'],0);Ext.cmd.derive('Ext.layout.component.Component',Ext.layout.Layout,{type:'component',isComponentLayout:!0,nullBox:{},usesContentHeight:!0,usesContentWidth:!0,usesHeight:!0,usesWidth:!0,widthCache:{},heightCache:{},beginLayoutCycle:function(a,j){var c=this,f=c.owner,p=a.ownerCtContext,g=a.heightModel,h=a.widthModel,o=f.el.dom===document.body,e=f.lastBox||c.nullBox,d=f.el.lastBox||c.nullBox,m=!o,k=a.isTopLevel,i,b,n,l;Ext.layout.Layout.prototype.beginLayoutCycle.call(this,a,j);if(j){if(c.usesContentWidth){++a.consumersContentWidth}if(c.usesContentHeight){++a.consumersContentHeight}if(c.usesWidth){++a.consumersWidth}if(c.usesHeight){++a.consumersHeight}if(p&&!p.hasRawContent){i=f.ownerLayout;if(i){if(i.usesWidth){++a.consumersWidth}if(i.usesHeight){++a.consumersHeight}}}}if(h.configured){n=f[h.names.width];if(k&&h.calculatedFrom){n=e.width}if(!o){m=c.setWidthInDom||(j?n!==d.width:h.constrained)}a.setWidth(n,m)}else {if(k){if(h.calculated){b=e.width;a.setWidth(b,b!==d.width)}b=e.x;a.setProp('x',b,b!==d.x)}}if(g.configured){l=f[g.names.height];if(k&&g.calculatedFrom){l=e.height}if(!o){m=j?l!==d.height:g.constrained}a.setHeight(l,m)}else {if(k){if(g.calculated){b=e.height;a.setHeight(b,b!==d.height)}b=e.y;a.setProp('y',b,b!==d.y)}}},finishedLayout:function(c){var h=this,e=c.children,g=h.owner,i,d,f,a,b;if(e){i=e.length;for(d=0;d','
    {text}
    ','
    ',''],componentLayout:'progressbar',ariaRole:'progressbar',initRenderData:function(){var a=this,b=a.value||0;return Ext.apply(Ext.Component.prototype.initRenderData.call(this),{internalText:!a.hasOwnProperty('textEl'),text:a.text||' ',percentage:b*100})},onRender:function(){var a=this;Ext.Component.prototype.onRender.apply(this,arguments);if(a.textEl){a.textEl=Ext.get(a.textEl);a.updateText(a.text)}else {a.textEl=a.el.select('.'+a.baseCls+'-text')}},updateValue:function(a){this.updateProgress(a,Math.round(a*100)+'%')},updateProgress:function(b,c,d){b=b||0;var a=this,f=a.value,e=a.getTextTpl();a.value=b||(b=0);if(c!=null){a.updateText(c)}else {if(e){a.updateText(e.apply({value:b,percent:b*100}))}}if(a.rendered&&!a.destroyed){if(d===!0||d!==!1&&a.animate){a.bar.stopAnimation();a.bar.animate(Ext.apply({from:{width:f*100+'%'},to:{width:b*100+'%'}},a.animate))}else {a.bar.setStyle('width',b*100+'%')}}a.fireEvent('update',a,b,c);return a},updateText:function(b){var a=this;a.text=b;if(a.rendered){a.textEl.setHtml(a.text)}return a},applyText:function(a){this.updateText(a)},getText:function(){return this.text},wait:function(a){var b=this,c;if(!b.waitTimer){c=b;a=a||{};b.updateText(a.text);b.waitTimer=Ext.TaskManager.start({run:function(d){var c=a.increment||10;d-=1;b.updateProgress(((d+c)%c+1)*(100/c)*0.01,null,a.animate)},interval:a.interval||1000,duration:a.duration,onStop:function(){if(a.fn){a.fn.apply(a.scope||b)}b.reset()},scope:c})}return b},isWaiting:function(){return this.waitTimer!==null},reset:function(b){var a=this;a.updateProgress(0);a.clearTimer();if(b===!0){a.hide()}return a},clearTimer:function(){var a=this;if(a.waitTimer){a.waitTimer.onStop=null;Ext.TaskManager.stop(a.waitTimer);a.waitTimer=null}},onDestroy:function(){var a=this,b=a.bar;a.clearTimer();if(a.rendered){if(a.textEl.isComposite){a.textEl.clear()}Ext.destroyMembers(a,'textEl','progressBar');if(b&&a.animate){b.stopAnimation()}}Ext.Component.prototype.onDestroy.call(this)}},0,['progressbar'],['component','box','progressbar'],{'component':!0,'box':!0,'progressbar':!0},['widget.progressbar'],[[Ext.ProgressBase.prototype.mixinId||Ext.ProgressBase.$className,Ext.ProgressBase]],[Ext,'ProgressBar'],0);Ext.cmd.derive('Ext.dom.ButtonElement',Ext.dom.Element,{setSize:function(b,a,e){var d=this,c=d.component;Ext.dom.Element.prototype.setSize.call(this,b,a,e);c.btnWrap.setStyle('table-layout',!b||b==='auto'?'':'fixed');c.btnEl.setStyle('height',!a||a==='auto'?'':'auto');return d},setStyle:function(a,c){var f=this,e=f.component,d,b;Ext.dom.Element.prototype.setStyle.call(this,a,c);if(a){if(a==='width'||typeof a!=='string'&&'width' in a){d=c||a.width;e.btnWrap.setStyle('table-layout',!d||d==='auto'?'':'fixed')}if(a==='height'||typeof a!=='string'&&'height' in a){b=c||a.height;e.btnEl.setStyle('height',!b||b==='auto'?'':'auto')}}return f},setHeight:function(a,b){Ext.dom.Element.prototype.setHeight.call(this,a,b);this.component.btnEl.setStyle('height',!a||a==='auto'?'':'auto');return this},setWidth:function(a,b){Ext.dom.Element.prototype.setWidth.call(this,a,b);this.component.btnWrap.setStyle('table-layout',!a||a==='auto'?'':'fixed');return this}},0,0,0,0,0,0,[Ext.dom,'ButtonElement'],0);Ext.cmd.derive('Ext.button.Manager',Ext.Base,{singleton:!0,alternateClassName:'Ext.ButtonToggleManager',groups:{},pressedButton:null,init:function(){var a=this;if(!a.initialized){Ext.getDoc().on({mouseup:a.onDocumentMouseUp,scope:a});a.initialized=!0}},onButtonMousedown:function(b,c){var a=this.pressedButton;if(a){a.onMouseUp(c)}this.pressedButton=b},onDocumentMouseUp:function(b){var a=this.pressedButton;if(a){a.onMouseUp(b);this.pressedButton=null}},toggleGroup:function(c,e){if(e){var b=this.groups[c.toggleGroup],d=b.length,a;for(a=0;a{[values.$comp.renderIcon(values)]}{text}{[values.$comp.renderIcon(values)]}{[values.$comp.getAfterMarkup ? values.$comp.getAfterMarkup(values) : ""]} {closeText} tabindex="{tabIndex}" {$}="{.}">{arrowElText}
    ',iconTpl:'background-image:url({iconUrl});
    font-family:{glyphFontFamily};">&#{glyph};',scale:'small',allowedScales:['small','medium','large'],arrowAlign:'right',arrowCls:'arrow',maskOnDisable:!1,shrinkWrap:3,frame:!0,autoEl:{tag:'a',hidefocus:'on',unselectable:'on'},hasFrameTable:function(){return this.href&&this.frameTable},frameTableListener:function(){if(!this.disabled){this.doNavigate()}},doNavigate:function(){if(this.hrefTarget==='_blank'){window.open(this.getHref(),this.hrefTarget)}else {location.href=this.getHref()}},_triggerRegion:{},initComponent:function(){var a=this;a.addCls('x-unselectable');Ext.Component.prototype.initComponent.call(this);if(a.menu){a.split=!0;a.setMenu(a.menu,!1,!0)}if(a.url){a.href=a.url}a.configuredWithPreventDefault=a.hasOwnProperty('preventDefault');if(a.href&&!a.configuredWithPreventDefault){a.preventDefault=!1}if(Ext.isString(a.toggleGroup)&&a.toggleGroup!==''){a.enableToggle=!0}if(a.html&&!a.text){a.text=a.html;delete a.html}},getElConfig:function(){var a=this,b=Ext.Component.prototype.getElConfig.call(this),d=a.getHref(),c=a.hrefTarget;if(b.tag==='a'){if(!a.disabled){b.tabIndex=a.tabIndex}if(d){if(!a.disabled){b.href=d;if(c){b.target=c}}}}if(!a.ariaStaticRoles[a.ariaRole]){if(a.menu&&!a.isSplitButton){b['aria-haspopup']=!0}if(a.enableToggle){b['aria-pressed']=!!a.pressed}}return b},beforeRender:function(){Ext.Component.prototype.beforeRender.call(this);if(this.pressed){this.addCls(this._pressedCls)}},initRenderData:function(){return Ext.apply(Ext.Component.prototype.initRenderData.call(this),this.getTemplateArgs())},getMenu:function(){return this.menu||null},setMenu:function(b,g,h){var a=this,e=a.menu,d=a.isSplitButton?a.arrowEl&&a.arrowEl.dom:a.ariaEl.dom,f,c;if(e&&!h){if(g!==!1&&a.destroyMenu){e.destroy()}e.ownerCmp=null}if(b){f=b.isMenu;b=Ext.menu.Manager.get(b,{ownerCmp:a});b.setOwnerCmp(a,f);b.menuClickBuffer=250;a.mon(b,{scope:a,show:a.onMenuShow,hide:a.onMenuHide});if(!e&&a.getArrowVisible()){a.split=!0;if(a.rendered){a._addSplitCls();a.updateLayout()}}a.menu=b;if(d){d.setAttribute('aria-haspopup',!0);d.setAttribute('aria-owns',b.id)}else {c=a.isSplitButton?a.ariaArrowElAttributes||(a.ariaArrowElAttributes={}):a.ariaRenderAttributes||(a.ariaRenderAttributes={});c['aria-haspopup']=!0;c['aria-owns']=b.id}}else {if(a.rendered){d.removeAttribute('aria-haspopup');d.removeAttribute('aria-owns');a._removeSplitCls();a.updateLayout()}else {c=a.isSplitButton?a.ariaArrowElAttributes:a.ariaRenderAttributes;if(c){delete c['aria-haspopup'];delete c['aria-owns']}}a.split=!1;a.menu=null}},onRender:function(){var a=this,d,c,b;Ext.Component.prototype.onRender.apply(this,arguments);c=a.el;if(a.tooltip){a.setTooltip(a.tooltip,!0)}if(a.handleMouseEvents){b={scope:a,mouseover:a.onMouseOver,mouseout:a.onMouseOut,mousedown:a.onMouseDown};if(a.split){b.mousemove=a.onMouseMove}}else {b={scope:a}}if(Ext.supports.Touch){b.touchstart=a.onTouchStart}if(a.repeat){a.mon(new Ext.util.ClickRepeater(c,Ext.isObject(a.repeat)?a.repeat:{}),'click',a.onRepeatClick,a)}else {if(b[a.clickEvent]){d=!0}else {b[a.clickEvent]=a.onClick}}a.mon(c,b);if(a.hasFrameTable()){a.mon(a.frameTable,'click',a.frameTableListener,a)}if(d){a.mon(c,a.clickEvent,a.onClick,a)}Ext.button.Manager.register(a)},onFocusLeave:function(a){Ext.Component.prototype.onFocusLeave.call(this,a);if(this.menu){this.menu.hide()}},getTemplateArgs:function(){var a=this,i=a._btnCls,j=a._baseIconCls,d=a.getIconAlign(),b=a.glyph,f=Ext._glyphFontFamily,e=a.text,h=a._hasIcon(),g=a._hasIconCls,c;if(typeof b==='string'){c=b.split('@');b=c[0];f=c[1]}return {split:a.isSplitButton,innerCls:a._innerCls,splitCls:a.getArrowVisible()?a.getSplitCls():'',iconUrl:a.icon,iconCls:a.iconCls,glyph:b,glyphCls:b?a._glyphCls:'',glyphFontFamily:f,text:e||' ',closeText:a.closeText,textCls:e?a._textCls:'',noTextCls:e?'':a._noTextCls,hasIconCls:h?g:'',btnWrapCls:a._btnWrapCls,btnWrapStyle:a.width?'table-layout:fixed;':'',btnElStyle:a.height?'height:auto;':'',btnCls:i,baseIconCls:j,iconBeforeText:d==='left'||d==='top',iconAlignCls:h?g+'-'+d:'',textAlignCls:i+'-'+a.getTextAlign(),arrowElCls:a._arrowElCls,tabIndex:a.tabIndex}},renderIcon:function(a){return this.getTpl('iconTpl').apply(a)},setHref:function(c){var a=this,d=a.hrefTarget,b;a.href=c;if(!a.configuredWithPreventDefault){a.preventDefault=!c}if(a.rendered){b=a.el.dom;if(!c||a.disabled){b.removeAttribute('href');b.removeAttribute('hrefTarget')}else {b.href=a.getHref();if(d){b.target=d}}}},getHref:function(){var a=this,b=a.href;return b?Ext.urlAppend(b,Ext.Object.toQueryString(Ext.apply({},a.params,a.baseParams))):!1},setParams:function(c){var a=this,b;a.params=c;if(a.rendered){b=a.el.dom;if(a.disabled){b.removeAttribute('href')}else {b.href=a.getHref()||''}}},getSplitCls:function(){var a=this;return a.split?a.baseCls+'-'+a.arrowCls+' '+(a.baseCls+'-'+a.arrowCls+'-'+a.arrowAlign):''},setIcon:function(b){b=b||'';var a=this,d=a.btnIconEl,c=a.icon||'';a.icon=b;if(b!==c){if(d){d.setStyle('background-image',b?'url('+b+')':'');a._syncHasIconCls();if(a.didIconStateChange(c,b)){a.updateLayout()}}a.fireEvent('iconchange',a,c,b)}return a},setIconCls:function(b){b=b||'';var a=this,d=a.btnIconEl,c=a.iconCls||'';a.iconCls=b;if(c!==b){if(d){d.removeCls(c);d.addCls(b);a._syncHasIconCls();if(a.didIconStateChange(c,b)){a.updateLayout()}}a.fireEvent('iconchange',a,c,b)}return a},setGlyph:function(b){b=b||0;var a=this,c=a.btnIconEl,f=a.glyph,g=a._glyphCls,d,e;a.glyph=b;if(c){if(typeof b==='string'){e=b.split('@');b=e[0];d=e[1]||Ext._glyphFontFamily}if(!b){c.dom.innerHTML='';c.removeCls(g)}else {if(f!==b){c.dom.innerHTML='&#'+b+';';c.addCls(g)}}if(d){c.setStyle('font-family',d)}a._syncHasIconCls();if(a.didIconStateChange(f,b)){a.updateLayout()}}a.fireEvent('glyphchange',a,a.glyph,f);return a},setTooltip:function(b,c){var a=this;if(a.rendered){if(!c||!b){a.clearTip()}if(b){if(Ext.quickTipsActive&&Ext.isObject(b)){Ext.tip.QuickTipManager.register(Ext.apply({target:a.el.id},b));a.tooltip=b}else {a.el.dom.setAttribute(a.getTipAttr(),b)}}}else {a.tooltip=b}return a},updateIconAlign:function(e,f){var b=this,a,d,c;if(b.rendered){a=b.btnEl;d=b.btnIconEl;c=b._hasIconCls;if(f){a.removeCls(c+'-'+f)}a.addCls(c+'-'+e);if(e==='top'||e==='left'){a.insertFirst(d)}else {a.appendChild(d)}b.updateLayout()}},updateTextAlign:function(e,d){var a=this,c=a.btnEl,b=a._btnCls;if(a.rendered){c.removeCls(b+'-'+d);c.addCls(b+'-'+e)}},getTipAttr:function(){return this.tooltipType==='qtip'?'data-qtip':'title'},getRefItems:function(c){var b=this.menu,a;if(b){a=b.getRefItems(c);a.unshift(b)}return a||[]},clearTip:function(){var a=this,b=a.el;if(Ext.quickTipsActive&&Ext.isObject(a.tooltip)){Ext.tip.QuickTipManager.unregister(b)}else {b.dom.removeAttribute(a.getTipAttr())}},beforeDestroy:function(){var a=this;if(a.rendered){a.clearTip()}Ext.destroy(a.repeater);Ext.Component.prototype.beforeDestroy.call(this)},onDestroy:function(){var a=this,b=a.menu;if(a.rendered){Ext.destroy(a.keyMap);delete a.keyMap}if(b&&a.destroyMenu){a.menu=Ext.destroy(b)}Ext.button.Manager.unregister(a);Ext.Component.prototype.onDestroy.call(this)},setHandler:function(a,b){this.handler=a;if(arguments.length>1){this.scope=b}return this},updateText:function(b,c){b=b==null?'':String(b);c=c||'';var a=this,e=a.btnInnerEl,d=a.btnEl;if(a.rendered){e.setHtml(b||' ');d[b?'addCls':'removeCls'](a._textCls);d[b?'removeCls':'addCls'](a._noTextCls);a.updateLayout()}a.fireEvent('textchange',a,c,b)},didIconStateChange:function(c,b){var a=Ext.isEmpty(b);return Ext.isEmpty(c)?!a:a},click:function(a){return this.onClick(a)},setPressed:function(a){return this.toggle(a!==!1)},toggle:function(b,d){var a=this,c=a.ariaEl.dom;b=b===undefined?!a.pressed:!!b;if(a.fireEvent('beforetoggle',a,b)!==!1){if(b!==a.pressed){a[b?'addCls':'removeCls'](a._pressedCls);a.pressed=b;if(c){c.setAttribute('aria-pressed',b)}if(!d){a.fireEvent('toggle',a,b);Ext.callback(a.toggleHandler,a.scope,[a,b],0,a);if(a.reference&&a.publishState){a.publishState('pressed',b)}}}}return a},maybeShowMenu:function(a){if(this.menu){this.showMenu(a)}},showMenu:function(c){var a=this,b=a.menu,d=!c||c.pointerType;if(b&&a.rendered){if(a.tooltip&&Ext.quickTipsActive&&a.getTipAttr()!=='title'){Ext.tip.QuickTipManager.getQuickTip().cancelShow(a.el)}if(b.isVisible()){if(d){b.hide()}else {b.focus()}}else {if(!c||a.showEmptyMenu||b.items.getCount()>0){b.autoFocus=!d;b.showBy(a.el,a.menuAlign)}}}return a},hideMenu:function(){if(this.hasVisibleMenu()){this.menu.hide()}return this},hasVisibleMenu:function(){var a=this.menu;return a&&a.rendered&&a.isVisible()},onRepeatClick:function(b,a){this.onClick(a)},onTouchStart:function(a){this.doPreventDefault(a)},onEnterKey:function(a){this.onClick(a);a.stopEvent();return !1},onClick:function(b){var a=this;a.doPreventDefault(b);if(b.type!=='keydown'&&b.button){return}if(!a.disabled){a.doToggle();a.maybeShowMenu(b);a.fireHandler(b)}},doPreventDefault:function(a){if(a&&(this.preventDefault||this.disabled&&this.getHref())){a.preventDefault()}},fireHandler:function(b){var a=this;if(a.fireEvent('click',a,b)!==!1&&!a.destroyed){Ext.callback(a.handler,a.scope,[a,b],0,a)}},doToggle:function(){var a=this;if(a.enableToggle&&(a.allowDepress!==!1||!a.pressed)){a.toggle()}},onMouseOver:function(b){var a=this;if(!a.disabled&&!b.within(a.el,!0,!0)){a.onMouseEnter(b)}},onMouseOut:function(b){var a=this;if(!b.within(a.el,!0,!0)){if(a.overMenuTrigger){a.onMenuTriggerOut(b)}a.onMouseLeave(b)}},onMouseMove:function(b){var a=this,c=a.overMenuTrigger;if(a.split){if(a.isWithinTrigger(b)){if(!c){a.onMenuTriggerOver(b)}}else {if(c){a.onMenuTriggerOut(b)}}}},isWithinTrigger:function(d){var a=this,e=a.el,c,b;c=a.arrowAlign==='right'?d.getX()-a.getX():d.getY()-e.getY();b=a.getTriggerRegion();return c>b.begin&&c{iconMarkup}
    role="{textElRole}">{text}
    {iconMarkup}',iconTpl:'',_textAlignClasses:{left:'x-title-align-left',center:'x-title-align-center',right:'x-title-align-right'},_iconAlignClasses:{top:'x-title-icon-top',right:'x-title-icon-right',bottom:'x-title-icon-bottom',left:'x-title-icon-left'},_rotationClasses:{0:'x-title-rotate-none',1:'x-title-rotate-right',2:'x-title-rotate-left'},_rotationAngles:{1:90,2:270},baseCls:'x-title',_titleSuffix:'-title',_glyphCls:'x-title-glyph',_iconWrapCls:'x-title-icon-wrap',_baseIconCls:'x-title-icon',_itemCls:'x-title-item',_textCls:'x-title-text',afterComponentLayout:function(){var b=this,c=b.getRotation(),a,d,e;if(c&&!Ext.isIE8){e=b.el;a=b.lastBox;d=a.x;e.setStyle(b._getVerticalAdjustDirection(),d+(c===1?a.width:-a.height)+'px')}Ext.Component.prototype.afterComponentLayout.call(this)},onRender:function(){var a=this,b=a.getRotation(),c=a.el;Ext.Component.prototype.onRender.call(this);if(b){c.setVertical(a._rotationAngles[b])}if(Ext.supports.FixedTableWidthBug){c._needsTableWidthFix=!0}},applyText:function(a){if(!a){a=' '}return a},beforeRender:function(){var a=this;Ext.Component.prototype.beforeRender.call(this);a.addCls(a._rotationClasses[a.getRotation()]);a.addCls(a._textAlignClasses[a.getTextAlign()])},getIconMarkup:function(){return this.getTpl('iconTpl').apply(this.getIconRenderData())},getIconRenderData:function(){var a=this,g=a.getIcon(),f=a.getIconCls(),b=a.getGlyph(),d=Ext._glyphFontFamily,e=a.getIconAlign(),c;if(typeof b==='string'){c=b.split('@');b=c[0];d=c[1]}return {id:a.id,ui:a.ui,itemCls:a._itemCls,iconUrl:g,iconCls:f,iconWrapCls:a._iconWrapCls,baseIconCls:a._baseIconCls,iconAlignCls:a._iconAlignClasses[e],glyph:b,glyphCls:b?a._glyphCls:'',glyphFontFamily:d}},initRenderData:function(){var a=this,c,b;b=Ext.apply({text:a.getText(),textElRole:a.textElRole,id:a.id,ui:a.ui,itemCls:a._itemCls,textCls:a._textCls,iconMarkup:null,iconBeforeTitle:null},Ext.Component.prototype.initRenderData.call(this));if(a._hasIcon()){c=a.getIconAlign();b.iconMarkup=a.getIconMarkup();b.iconBeforeTitle=c==='top'||c==='left'}return b},onAdded:function(a,f,e){var d=this,c=d._titleSuffix,b=a.baseCls;d.addCls([b+c,b+c+'-'+a.ui]);Ext.Component.prototype.onAdded.call(this,a,f,e)},updateGlyph:function(a,g){a=a||0;var b=this,f=b._glyphCls,c,d,e;b.glyph=a;if(b.rendered){b._syncIconVisibility();c=b.iconEl;if(typeof a==='string'){e=a.split('@');a=e[0];d=e[1]||Ext._glyphFontFamily}if(!a){c.dom.innerHTML='';c.removeCls(f)}else {if(g!==a){c.dom.innerHTML='&#'+a+';';c.addCls(f)}}if(d){c.setStyle('font-family',d)}if(b._didIconStateChange(g,a)){b.updateLayout()}}},updateIcon:function(a,c){a=a||'';var b=this,d;if(b.rendered&&a!==c){b._syncIconVisibility();d=b.iconEl;d.setStyle('background-image',a?'url('+a+')':'');if(b._didIconStateChange(c,a)){b.updateLayout()}}},updateIconAlign:function(d,f){var a=this,b=a.iconWrapEl,e,c;if(a.iconWrapEl){e=a.el;c=a._iconAlignClasses;if(f){b.removeCls(c[f])}b.addCls(c[d]);if(d==='top'||d==='left'){e.insertFirst(b)}else {e.appendChild(b)}a.updateLayout()}},updateIconCls:function(a,c){a=a||'';var b=this,d;if(b.rendered&&c!==a){b._syncIconVisibility();d=b.iconEl;if(c){d.removeCls(c)}d.addCls(a);if(b._didIconStateChange(c,a)){b.updateLayout()}}},updateRotation:function(d,e){var a=this,b,c;if(a.rendered){b=a.el;c=a._rotationClasses;a.removeCls(c[e]);a.addCls(c[d]);b.setHorizontal();if(d){b.setVertical(a._rotationAngles[d])}b.setStyle({right:'',left:'',top:'',height:'',width:''});a.lastBox=null;a.updateLayout()}},updateText:function(a){if(this.rendered){this.textEl.setHtml(a);this.updateLayout()}},updateTextAlign:function(d,c){var a=this,b=a._textAlignClasses;if(a.rendered){if(c){a.removeCls(b[c])}a.addCls(b[d]);a.updateLayout()}},privates:{_getVerticalAdjustDirection:function(){return 'left'},_didIconStateChange:function(c,b){var a=Ext.isEmpty(b);return Ext.isEmpty(c)?!a:a},_hasIcon:function(){return !!(this.getIcon()||this.getIconCls()||this.getGlyph())},_syncIconVisibility:function(){var a=this,f=a.el,e=a._hasIcon(),b=a.iconWrapEl,d,c;if(e&&!b){c=a.iconAlign;d=c==='left'||c==='top';f.dom.insertAdjacentHTML(d?'afterbegin':'beforeend',a.getIconMarkup());b=a.iconWrapEl=f[d?'first':'last']();a.iconEl=b.first()}if(b){b.setDisplayed(e)}}}},0,['title'],['component','box','title'],{'component':!0,'box':!0,'title':!0},['widget.title'],0,[Ext.panel,'Title'],0);Ext.cmd.derive('Ext.panel.Tool',Ext.Component,{isTool:!0,baseCls:'x-tool',disabledCls:'x-tool-disabled',toolPressedCls:'x-tool-pressed',toolOverCls:'x-tool-over',childEls:['toolEl'],renderTpl:[''],toolOwner:null,tooltipType:'qtip',stopEvent:!0,ariaRole:'button',focusable:!0,tabIndex:0,keyHandlers:{SPACE:'onClick',ENTER:'onClick'},cacheHeight:!0,cacheWidth:!0,initComponent:function(){var a=this;a.type=a.type||a.id;Ext.applyIf(a.renderData,{baseCls:a.baseCls,type:a.type});a.tooltip=a.tooltip||a.qtip;Ext.Component.prototype.initComponent.call(this)},afterRender:function(){var a=this,b;Ext.Component.prototype.afterRender.apply(this,arguments);a.el.on({click:a.onClick,mousedown:a.onMouseDown,mouseover:a.onMouseOver,mouseout:a.onMouseOut,scope:a});b=a.tooltip;if(b){a.setTooltip(b)}},tipAttrs:{qtip:'data-qtip'},setTooltip:function(b,d){var a=this,g=a.tooltip,f=a.tooltipType,h=a.id,e=a.el,c;if(g&&Ext.quickTipsActive&&Ext.isObject(g)){Ext.tip.QuickTipManager.unregister(h)}a.tooltip=b;if(d){a.tooltipType=d}if(b){if(Ext.quickTipsActive&&Ext.isObject(b)){Ext.tip.QuickTipManager.register(Ext.apply({target:h},b))}else {if(e){if(d&&f&&d!==f){c=a.tipAttrs[f]||'title';e.dom.removeAttribute(c)}c=a.tipAttrs[d||f]||'title';e.dom.setAttribute(c,b)}}if(c!=='title'&&a.ariaRole&&a.ariaRole!=='presentation'){if(e){e.dom.setAttribute('aria-label',b)}else {a.ariaRenderAttributes=a.ariaRenderAttributes||{};a.ariaRenderAttributes['aria-label']=b}}}},setType:function(b){var a=this,c=a.type;a.type=b;if(a.rendered){if(c){a.toolEl.removeCls(a.baseCls+'-'+c)}a.toolEl.addCls(a.baseCls+'-'+b)}else {a.renderData.type=b}return a},onDestroy:function(){var a=this,b=a.keyMap;a.setTooltip(null);delete a.toolOwner;Ext.Component.prototype.onDestroy.call(this)},privates:{onClick:function(b,c){var a=this;if(a.disabled){return !1}if(b.type!=='keydown'){a.el.removeCls(a.toolPressedCls+' '+a.toolOverCls)}if(a.stopEvent!==!1){b.stopEvent()}if(a.handler){Ext.callback(a.handler,a.scope,[b,c,a.ownerCt,a],0,a)}else {if(a.callback){Ext.callback(a.callback,a.scope,[a.toolOwner||a.ownerCt,a,b],0,a)}}a.fireEvent('click',a,b,a.toolOwner||a.ownerCt);return !0},onMouseDown:function(a){a.preventDefault();if(this.disabled){return !1}this.el.addCls(this.toolPressedCls)},onMouseOver:function(){if(this.disabled){return !1}this.el.addCls(this.toolOverCls)},onMouseOut:function(){this.el.removeCls(this.toolOverCls)}}},0,['tool'],['component','box','tool'],{'component':!0,'box':!0,'tool':!0},['widget.tool'],0,[Ext.panel,'Tool'],0);Ext.cmd.derive('Ext.util.KeyMap',Ext.Base,{alternateClassName:'Ext.KeyMap',eventName:'keydown',constructor:function(b){var a=this;if(arguments.length!==1||typeof b==='string'||b.dom||b.tagName||b===document||b.isComponent){a.legacyConstructor.apply(a,arguments);return}Ext.apply(a,b);a.bindings=[];if(!a.target.isComponent){a.target=Ext.get(a.target)}if(a.binding){a.addBinding(a.binding)}else {if(b.key){a.addBinding(b)}}a.enable()},legacyConstructor:function(d,b,c){var a=this;Ext.apply(a,{target:Ext.get(d),eventName:c||a.eventName,bindings:[]});if(b){a.addBinding(b)}a.enable()},addBinding:function(b){var a=this,e=b.key,c,d;if(a.processing){a.bindings=a.bindings.slice(0)}if(Ext.isArray(b)){for(c=0,d=b.length;c=i){return a}}}if(!g){return}a=c.findNextFocusableChild({beforeRender:h,items:b,step:!0});if(a){c.activateFocusable(a)}return a},clearFocusables:function(){var d=this,c=d.getFocusables(),e=c.length,a,b;for(b=0;b0?d0?d+b:e-1;for(;;a+=b){if(d<0&&(a>=e||a<0)){return null}else {if(a>=e){a=-1;continue}else {if(a<0){a=e;continue}else {if(a===d){return null}}}}c=g[a];if(!c||!c.focusable||c.disabled){continue}if(i||c.isFocusable&&c.isFocusable()){return c}}return null},getFocusableContainerEl:function(){return this.el},onFocusableChildAdd:function(a){if(this.enableFocusableContainer){return this.doFocusableChildAdd(a)}},activateFocusableContainerEl:function(a){a=a||this.getFocusableContainerEl();if(a){a.set({tabIndex:this.activeChildTabIndex})}},deactivateFocusableContainerEl:function(a){a=a||this.getFocusableContainerEl();if(a){a.set({tabIndex:undefined})}},isFocusableContainerActive:function(){var e=this,d=!1,c,b,a;c=e.getFocusableContainerEl();if(c&&c.isTabbable&&c.isTabbable()){d=!0}else {b=e.lastFocusedChild;a=b&&b.getFocusEl&&b.getFocusEl();if(a&&a.isTabbable&&a.isTabbable()){d=!0}}return d},doFocusableChildAdd:function(a){if(a.focusable){a.focusableContainer=this}},onFocusableChildRemove:function(a){if(this.enableFocusableContainer){return this.doFocusableChildRemove(a)}a.focusableContainer=null},doFocusableChildRemove:function(a){if(a===this.lastFocusedChild){this.lastFocusedChild=null;this.activateFocusableContainerEl()}},onFocusableContainerMousedown:function(c,b){var a=Ext.Component.fromElement(b);this.mousedownTimestamp=a===this?Ext.Date.now():0;if(a===this){c.preventDefault()}},onFocusEnter:function(f){var a=this,d=f.toComponent,c=a.mousedownTimestamp,e=50,b;if(!a.enableFocusableContainer){return null}a.mousedownTimestamp=0;if(d===a){if(!c||Ext.Date.now()-c>e){b=a.initDefaultFocusable();if(b){a.deactivateFocusableContainerEl();b.focus()}}}else {a.deactivateFocusableContainerEl()}return d},onFocusLeave:function(c){var a=this,b=a.lastFocusedChild;if(!a.enableFocusableContainer){return}if(!a.destroyed&&!a.destroying){a.clearFocusables();if(b&&!b.disabled){a.activateFocusable(b)}else {a.activateFocusableContainerEl()}}},beforeFocusableChildBlur:Ext.privateFn,afterFocusableChildBlur:Ext.privateFn,beforeFocusableChildFocus:function(b){var a=this;if(!a.enableFocusableContainer){return}a.clearFocusables();a.activateFocusable(b);if(b.needArrowKeys){a.guardFocusableChild(b)}},guardFocusableChild:function(c){var b=this,d=b.activeChildTabIndex,a;a=b.findNextFocusableChild({child:c,step:-1});if(a){a.setTabIndex(d)}a=b.findNextFocusableChild({child:c,step:1});if(a){a.setTabIndex(d)}},afterFocusableChildFocus:function(a){if(!this.enableFocusableContainer){return}this.lastFocusedChild=a},beforeFocusableChildEnable:Ext.privateFn,onFocusableChildEnable:function(b){var a=this;if(!a.enableFocusableContainer){return}if(b!==a.lastFocusedChild){a.deactivateFocusable(b);if(!a.isFocusableContainerActive()){a.activateFocusableContainerEl()}}},beforeFocusableChildDisable:function(c){var a=this,b;if(!a.enableFocusableContainer||a.destroying||a.destroyed){return}if(c.hasFocus){b=a.findNextFocusableChild({child:c})||c.findFocusTarget();if(b){b.focus()}}},onFocusableChildDisable:function(d){var a=this,c=a.lastFocusedChild,b;if(!a.enableFocusableContainer||a.destroying||a.destroyed){return}if(d===c){a.activateFocusableContainerEl()}b=a.findNextFocusableChild({step:1});if(!b){a.deactivateFocusableContainerEl()}},onFocusableChildShow:Ext.privateFn,onFocusableChildHide:Ext.privateFn,onFocusableChildMasked:Ext.privateFn,onFocusableChildDestroy:Ext.privateFn,onFocusableChildUpdate:Ext.privateFn}},0,0,0,0,0,0,[Ext.util,'FocusableContainer'],0);Ext.cmd.derive('Ext.panel.Header',Ext.panel.Bar,{isHeader:!0,defaultType:'tool',indicateDrag:!1,weight:-1,shrinkWrap:3,iconAlign:'left',titleAlign:'left',titlePosition:0,titleRotation:'default',autoEl:{role:'presentation'},beforeRenderConfig:{glyph:null,icon:null,iconCls:null,iconAlign:null,title:{$value:{xtype:'title',flex:1},merge:function(a,b){if(typeof a!=='object'){a={text:a}}return Ext.merge(b?Ext.Object.chain(b):{},a)}},titleAlign:null,titlePosition:null,titleRotation:null},headerCls:'x-header',initComponent:function(){var a=this,b=a.items,d=a.itemPosition,c=[a.headerCls];a.tools=a.tools||[];a.items=b=b?b.slice():[];if(d!==undefined){a._userItems=b.slice();a.items=b=[]}a.indicateDragCls=a.headerCls+'-draggable';if(a.indicateDrag){c.push(a.indicateDragCls)}a.addCls(c);a.syncNoBorderCls();a.enableFocusableContainer=!a.isAccordionHeader&&a.tools.length>0;if(a.enableFocusableContainer){a.ariaRole='toolbar'}Ext.Array.push(b,a.tools);a.tools.length=0;Ext.panel.Bar.prototype.initComponent.call(this);a.on({dblclick:a.onDblClick,click:a.onClick,element:'el',scope:a})},addTool:function(b){var a=this;a.add(Ext.ComponentManager.create(b,'tool'));if(!a.isAccordionHeader&&a.tools.length>0&&!a.enableFocusableContainer){a.enableFocusableContainer=!0;a.ariaRole='toolbar';if(a.rendered){a.ariaEl.dom.setAttribute('role','toolbar');a.initFocusableContainer(!0)}}},afterLayout:function(){var a=this,e,b,c,d;if(a.vertical){b=a.frameTR;if(b){e=a.frameBR;c=a.frameTL;d=a.getWidth()-b.getPadding('r')-(c?c.getPadding('l'):a.el.getBorderWidth('l'))+'px';e.setStyle('background-position-x',d);b.setStyle('background-position-x',d)}}Ext.panel.Bar.prototype.afterLayout.call(this)},applyTitle:function(a,d){var b=this,c,e;a=a||'';c=typeof a==='string';if(c){a={text:a}}if(d){Ext.suspendLayouts();d.setConfig(a);Ext.resumeLayouts(!0);a=d}else {if(c){a.xtype='title'}a.ui=b.ui;e='rotation' in a;a.id=b.id+'-title';if(b.isAccordionHeader){a.ariaRole='tab';a.textElRole=null;a.focusable=!0}a=Ext.create(a);if(!e&&b.vertical&&b.titleRotation==='default'){a.rotation=1}}return a},applyTitlePosition:function(b){var a=this.items.getCount();if(this._titleInItems){--a}return Math.max(Math.min(b,a),0)},beforeLayout:function(){Ext.panel.Bar.prototype.beforeLayout.call(this);this.syncBeforeAfterTitleClasses()},beforeRender:function(){var a=this,b=a.itemPosition;a.protoEl.unselectable();Ext.panel.Bar.prototype.beforeRender.call(this);if(b!==undefined){a.insert(b,a._userItems)}},getTools:function(){return this.tools.slice()},onAdd:function(a,c){var b=this.tools;Ext.panel.Bar.prototype.onAdd.call(this,a,c);if(a.isTool){b.push(a);b[a.type]=a}},onAdded:function(a,c,b){this.syncNoBorderCls();Ext.panel.Bar.prototype.onAdded.call(this,a,c,b)},onRemoved:function(a,c,b){this.syncNoBorderCls();Ext.panel.Bar.prototype.onRemoved.call(this,a,c,b)},setDock:function(e){var a=this,c=a.getTitle(),b=a.getTitleRotation(),d=c.getRotation();Ext.suspendLayouts();Ext.panel.Bar.prototype.setDock.call(this,e);if(b==='default'){b=a.vertical?1:0;if(b!==d){c.setRotation(b)}if(a.rendered){a.resetItemMargins()}}Ext.resumeLayouts(!0)},updateGlyph:function(a){this.getTitle().setGlyph(a)},updateIcon:function(a){this.getTitle().setIcon(a)},updateIconAlign:function(a,b){this.getTitle().setIconAlign(a)},updateIconCls:function(a){this.getTitle().setIconCls(a)},updateTitle:function(a,b){if(!b){this.insert(this.getTitlePosition(),a);this._titleInItems=!0}this.titleCmp=a},updateTitleAlign:function(a,b){this.getTitle().setTextAlign(a)},updateTitlePosition:function(a){this.insert(a,this.getTitle())},updateTitleRotation:function(a){if(a==='default'){a=this.vertical?1:0}this.getTitle().setRotation(a)},privates:{fireClickEvent:function(c,a){var b='.'+Ext.panel.Tool.prototype.baseCls;if(!a.getTarget(b)){this.fireEvent(c,this,a)}},getFramingInfoCls:function(){var a=this,c=Ext.panel.Bar.prototype.getFramingInfoCls.call(this),b=a.ownerCt;if(!a.expanding&&b&&(b.collapsed||a.isCollapsedExpander)){c+='-'+b.collapsedCls}return c+'-'+a.dock},onClick:function(a){this.fireClickEvent('click',a)},onDblClick:function(a){this.fireClickEvent('dblclick',a)},onFocusableContainerMousedown:function(c,b){var a=Ext.Component.fromElement(b);if(a===this){c.preventDefault()}else {this.mixins.focusablecontainer.onFocusableContainerMousedown.apply(this,arguments)}},syncBeforeAfterTitleClasses:function(l){var c=this,j=c.items,i=j.items,h=c.getTitlePosition(),k=i.length,g=j.generation,f=c.syncBeforeAfterGen,e,d,b,a;if(!l&&f===g){return}c.syncBeforeAfterGen=g;for(b=0;bh){if(f){a.removeCls(d)}a.addCls(e)}}}},syncNoBorderCls:function(){var a=this,b=this.ownerCt,c=a.headerCls+'-noborder';if(b?b.border===!1&&!b.frame:a.border===!1){a.addCls(c)}else {a.removeCls(c)}}}},0,['header'],['component','box','container','header'],{'component':!0,'box':!0,'container':!0,'header':!0},['widget.header'],[[Ext.util.FocusableContainer.prototype.mixinId||Ext.util.FocusableContainer.$className,Ext.util.FocusableContainer]],[Ext.panel,'Header'],0);Ext.cmd.derive('Ext.layout.container.boxOverflow.None',Ext.Base,{alternateClassName:'Ext.layout.boxOverflow.None',factoryConfig:{defaultType:'none'},isBoxOverflowHandler:!0,$configPrefixed:!1,$configStrict:!1,constructor:function(a){this.initConfig(a)},handleOverflow:Ext.emptyFn,clearOverflow:Ext.emptyFn,beginLayout:Ext.emptyFn,beginLayoutCycle:Ext.emptyFn,calculate:function(b){var c=this,d=b.state.boxPlan,a;if(d&&d.tooNarrow){a=c.handleOverflow(b);if(a){if(a.reservedSpace){c.layout.publishInnerCtSize(b,a.reservedSpace)}}}else {c.clearOverflow()}},completeLayout:Ext.emptyFn,finishedLayout:function(e){var b=this,d=b.layout.owner,c,a;if(d.hasListeners.overflowchange){c=d.query('>[hidden]');a=c.length;if(a!==b.lastHiddenCount){d.fireEvent('overflowchange',b.lastHiddenCount,a,c);b.lastHiddenCount=a}}},onRemove:Ext.emptyFn,getItem:function(a){return this.layout.owner.getComponent(a)},getOwnerType:function(b){var a;if(b.isToolbar){a='toolbar'}else {if(b.isTabBar){a='tab-bar'}else {if(b.isMenu){a='menu'}else {if(b.isBreadcrumb){a='breadcrumb'}else {a=b.getXType()}}}}return a},getPrefixConfig:Ext.emptyFn,getSuffixConfig:Ext.emptyFn,getOverflowCls:function(){return ''},setVertical:function(){var b=this,a=b.layout,c=a.innerCt;c.removeCls(b.getOverflowCls(a.oppositeDirection));c.addCls(b.getOverflowCls(a.direction))}},1,0,0,0,['box.overflow.None','box.overflow.none'],[[Ext.mixin.Factoryable.prototype.mixinId||Ext.mixin.Factoryable.$className,Ext.mixin.Factoryable]],[Ext.layout.container.boxOverflow,'None',Ext.layout.boxOverflow,'None'],0);Ext.cmd.derive('Ext.layout.container.boxOverflow.Scroller',Ext.layout.container.boxOverflow.None,{alternateClassName:'Ext.layout.boxOverflow.Scroller',animateScroll:!1,scrollIncrement:20,wheelIncrement:10,scrollRepeatInterval:60,scrollDuration:400,scrollerCls:'x-box-scroller',beforeSuffix:'-before-scroller',afterSuffix:'-after-scroller',constructor:function(b){var a=this;a.mixins.observable.constructor.call(a,b);a.scrollPosition=0;a.scrollSize=0},getPrefixConfig:function(){return {role:'presentation',id:this.layout.owner.id+this.beforeSuffix,cls:this.createScrollerCls('beforeX'),style:'display:none'}},getSuffixConfig:function(){return {role:'presentation',id:this.layout.owner.id+this.afterSuffix,cls:this.createScrollerCls('afterX'),style:'display:none'}},createScrollerCls:function(g){var c=this,d=c.layout,b=d.owner,e=c.getOwnerType(b),a=c.scrollerCls,f=a+' '+a+'-'+d.names[g]+' '+a+'-'+e+' '+a+'-'+e+'-'+b.ui;if(b.plain){f+=' '+a+'-plain'}return f},getOverflowCls:function(a){return this.scrollerCls+'-body-'+a},beginLayout:function(a){a.innerCtScrollPos=this.getScrollPosition();Ext.layout.container.boxOverflow.None.prototype.beginLayout.apply(this,arguments)},finishedLayout:function(a){var b=this,f=a.state.boxPlan,e=b.layout,d=e.names,g=Math.min(b.getMaxScrollPosition(),a.innerCtScrollPos),c;if(f&&f.tooNarrow){c=a.childItems[a.childItems.length-1].props;b.scrollSize=c[d.x]+c[d.width];b.updateScrollButtons();e.innerCt[d.setScrollLeft](g)}Ext.layout.container.boxOverflow.None.prototype.finishedLayout.call(this,a)},handleOverflow:function(i){var a=this,d=a.layout.names,h=d.getWidth,f=d.parallelMargins,g,e,b,c;a.showScrollers();b=a.getBeforeScroller();c=a.getAfterScroller();g=b[h]()+c[h]()+b.getMargin(f)+c.getMargin(f);e=i.targetContext.getPaddingInfo()[d.width];return {reservedSpace:Math.max(g-e,0)}},getBeforeScroller:function(){var a=this;return a._beforeScroller||(a._beforeScroller=a.createScroller(a.beforeSuffix,'beforeRepeater','scrollLeft'))},getAfterScroller:function(){var a=this;return a._afterScroller||(a._afterScroller=a.createScroller(a.afterSuffix,'afterRepeater','scrollRight'))},createScroller:function(g,f,e){var b=this,d=b.layout.owner,c=b.scrollerCls,a;a=d.el.getById(d.id+g);a.addClsOnOver(c+'-hover');a.addClsOnClick(c+'-pressed');a.setVisibilityMode(Ext.Element.DISPLAY);b[f]=new Ext.util.ClickRepeater(a,{interval:b.scrollRepeatInterval,handler:e,scope:b});return a},createWheelListener:function(){var a=this;a.wheelListener=a.layout.innerCt.on('mousewheel',a.onMouseWheel,a,{destroyable:!0})},onMouseWheel:function(a){a.stopEvent();this.scrollBy(this.getWheelDelta(a)*this.wheelIncrement*-1,!1)},getWheelDelta:function(a){return a.getWheelDelta()},clearOverflow:function(){this.hideScrollers()},showScrollers:function(){var a=this;if(!a.wheelListener){a.createWheelListener()}a.getBeforeScroller().show();a.getAfterScroller().show();a.layout.owner.addClsWithUI(a.layout.direction==='vertical'?'vertical-scroller':'scroller')},hideScrollers:function(){var a=this,b=a.getBeforeScroller(),c=a.getAfterScroller();if(b){b.hide();c.hide();a.layout.owner.removeClsWithUI(a.layout.direction==='vertical'?'vertical-scroller':'scroller')}},destroy:function(){Ext.destroyMembers(this,'beforeRepeater','afterRepeater','_beforeScroller','_afterScroller','wheelListener');this.callParent()},scrollBy:function(b,a){this.scrollTo(this.getScrollPosition()+b,a)},getScrollAnim:function(){return {duration:this.scrollDuration,callback:this.updateScrollButtons,scope:this}},updateScrollButtons:function(){var a=this,c=a.getBeforeScroller(),d=a.getAfterScroller(),b;if(!c||!d){return}b=a.scrollerCls+'-disabled';c[a.atExtremeBefore()?'addCls':'removeCls'](b);d[a.atExtremeAfter()?'addCls':'removeCls'](b);a.scrolling=!1},scrollLeft:function(){this.scrollBy(-this.scrollIncrement,!1)},scrollRight:function(){this.scrollBy(this.scrollIncrement,!1)},getScrollPosition:function(){var b=this,c=b.layout,a;if(isNaN(b.scrollPosition)){a=c.innerCt[c.names.getScrollLeft]()}else {a=b.scrollPosition}return a},getMaxScrollPosition:function(){var c=this,b=c.layout,a=c.scrollSize-b.innerCt.lastBox[b.names.width];return a<0?0:a},atExtremeBefore:function(){return !this.getScrollPosition()},atExtremeAfter:function(){return this.getScrollPosition()>=this.getMaxScrollPosition()},setVertical:function(){var c=this,d=c.getBeforeScroller(),e=c.getAfterScroller(),b=c.layout.names,a=c.scrollerCls;d.removeCls(a+'-'+b.beforeY);e.removeCls(a+'-'+b.afterY);d.addCls(a+'-'+b.beforeX);e.addCls(a+'-'+b.afterX);Ext.layout.container.boxOverflow.None.prototype.setVertical.call(this)},scrollTo:function(g,b){var a=this,d=a.layout,e=d.names,f=a.getScrollPosition(),c=Ext.Number.constrain(g,0,a.getMaxScrollPosition());if(c!==f&&!a.scrolling){a.scrollPosition=NaN;if(b===undefined){b=a.animateScroll}d.innerCt[e.scrollTo](e.beforeScrollX,c,b?a.getScrollAnim():!1);if(b){a.scrolling=!0}else {a.updateScrollButtons()}a.fireEvent('scroll',a,c,b?a.getScrollAnim():!1)}},scrollToItem:function(a,i){var c=this,e=c.layout,h=e.owner,f=e.names,j=e.innerCt,d,g,b;a=c.getItem(a);if(a!==undefined){if(a===h.items.first()){b=0}else {if(a===h.items.last()){b=c.getMaxScrollPosition()}else {d=c.getItemVisibility(a);if(!d.fullyVisible){g=a.getBox(!1,!0);b=g[f.x];if(d.hiddenEnd){b-=j[f.getWidth]()-g[f.width]}}}}if(b!==undefined){c.scrollTo(b,i)}}},getItemVisibility:function(i){var d=this,h=d.getItem(i).getBox(!0,!0),g=d.layout,c=g.names,b=h[c.x],f=b+h[c.width],a=d.getScrollPosition(),e=a+g.innerCt[c.getWidth]();return {hiddenStart:be,fullyVisible:b>=a&&f<=e}}},1,0,0,0,['box.overflow.Scroller','box.overflow.scroller'],[['observable',Ext.mixin.Observable]],[Ext.layout.container.boxOverflow,'Scroller',Ext.layout.boxOverflow,'Scroller'],0);Ext.cmd.derive('Ext.dd.DragDropManager',Ext.Base,{singleton:!0,alternateClassName:['Ext.dd.DragDropMgr','Ext.dd.DDM'],ids:{},handleIds:{},dragCurrent:null,dragOvers:{},deltaX:0,deltaY:0,preventDefault:!0,stopPropagation:!0,initialized:!1,locked:!1,init:function(){this.initialized=!0},POINT:0,INTERSECT:1,mode:0,notifyOccluded:!1,dragCls:'x-dd-drag-current',_execOnAll:function(f,g){var c=this.ids,d,e,b,a;for(d in c){if(c.hasOwnProperty(d)){a=c[d];for(e in a){if(a.hasOwnProperty(e)){b=a[e];if(!this.isTypeOfDD(b)){continue}b[f].apply(b,g)}}}}},addListeners:function(){var a=this;a.init();Ext.getDoc().on({mouseup:a.handleMouseUp,mousemove:{fn:a.handleMouseMove,capture:!1},dragstart:a.preventDrag,drag:a.preventDrag,dragend:a.preventDrag,capture:!0,scope:a});Ext.getWin().on({unload:a._onUnload,resize:a._onResize,scope:a})},preventDrag:function(a){if(this.isMouseDown){a.stopPropagation()}},_onResize:function(a){this._execOnAll('resetConstraints',[])},lock:function(){this.locked=!0},unlock:function(){this.locked=!1},isLocked:function(){return this.locked},locationCache:{},useCache:!0,clickPixelThresh:8,dragThreshMet:!1,clickTimeout:null,startX:0,startY:0,regDragDrop:function(b,a){if(!this.initialized){this.init()}if(!this.ids[a]){this.ids[a]={}}this.ids[a][b.id]=b},removeDDFromGroup:function(c,a){if(!this.ids[a]){this.ids[a]={}}var b=this.ids[a];if(b&&b[c.id]){delete b[c.id]}},_remove:function(b,f){var a=this,d=a.ids,e=b.groups,c;if(a.clearingAll){return}if(a.dragCurrent===b){a.dragCurrent=null}for(c in e){if(e.hasOwnProperty(c)){if(f){delete d[c]}else {if(d[c]){delete d[c][b.id]}}}}delete a.handleIds[b.id];delete a.locationCache[b.id]},regHandle:function(a,b){if(!this.handleIds[a]){this.handleIds[a]={}}this.handleIds[a][b]=b},isDragDrop:function(a){return this.getDDById(a)?!0:!1},getRelated:function(f,e){var b=[],c,d,a;for(c in f.groups){for(d in this.ids[c]){a=this.ids[c][d];if(!this.isTypeOfDD(a)){continue}if(!e||a.isTarget){b[b.length]=a}}}return b},isLegalTarget:function(e,d){var b=this.getRelated(e,!0),a,c;for(a=0,c=b.length;aa.clickPixelThresh||e>a.clickPixelThresh){a.startDrag(a.startX,a.startY)}}if(a.dragThreshMet){c.b4Drag(b);c.onDrag(b);if(!c.moveOnly){a.fireEvents(b,!1)}}a.stopEvent(b);return !0},fireEvents:function(e,t){var d=this,s=Ext.supports.Touch,c=d.dragCurrent,l=d.currentPoint,v=l.x,w=l.y,j=[],r=[],h=[],i=[],g=[],k=[],u=s?document.documentElement.clientWidth/window.innerWidth:1,p,b,o,q,a,f,n,m;if(!c||c.isLocked()){return}m=!(c.deltaX<0||c.deltaY<0);if(s||!d.notifyOccluded&&(!Ext.supports.CSSPointerEvents||Ext.isIE10m||Ext.isOpera)&&m){p=c.getDragEl();if(m){p.style.visibility='hidden'}e.target=document.elementFromPoint(v/u,w/u);if(m){p.style.visibility='visible'}}for(a in d.dragOvers){b=d.dragOvers[a];delete d.dragOvers[a];if(!d.isTypeOfDD(b)||b.destroyed){continue}if(d.notifyOccluded){if(!this.isOverTarget(l,b,d.mode)){h.push(b)}}else {if(!e.within(b.getEl())){h.push(b)}}r[a]=!0}for(n in c.groups){if('string'!==typeof n){continue}for(a in d.ids[n]){b=d.ids[n][a];if(d.isTypeOfDD(b)&&(o=b.getEl())&&b.isTarget&&!b.isLocked()&&Ext.fly(o).isVisible(!0)&&(b!==c||c.ignoreSelf===!1)){if(d.notifyOccluded){if((b.zIndex=d.getZIndex(o))!==-1){q=!0}j.push(b)}else {if(e.within(b.getEl())){j.push(b);break}}}}}if(q){Ext.Array.sort(j,d.byZIndex)}for(a=0,f=j.length;a','',''],isSplitter:!0,baseCls:'x-splitter',collapsedClsInternal:'x-splitter-collapsed',canResize:!0,collapsible:null,collapseOnDblClick:!0,defaultSplitMin:40,defaultSplitMax:1000,collapseTarget:'next',horizontal:!1,vertical:!1,size:5,tracker:null,ariaRole:'separator',focusable:!0,tabIndex:0,getTrackerConfig:function(){return Ext.apply({xclass:'Ext.resizer.SplitterTracker',el:this.el,splitter:this},this.tracker)},beforeRender:function(){var a=this,c=a.getCollapseTarget(),b=a.collapsible,d;Ext.Component.prototype.beforeRender.call(this);if(c.collapsed){a.addCls(a.collapsedClsInternal)}if(!a.canResize){a.addCls(a.baseCls+'-noresize')}Ext.applyIf(a.renderData,{collapseDir:a.getCollapseDirection(),collapsible:b!==null?b:c.collapsible});a.ariaRenderAttributes=a.ariaRenderAttributes||{};a.ariaRenderAttributes['aria-orientation']=a.orientation;a.protoEl.unselectable()},onRender:function(){var a=this,b;Ext.Component.prototype.onRender.apply(this,arguments);if(a.performCollapse!==!1){if(a.renderData.collapsible){a.mon(a.collapseEl,'click',a.toggleTargetCmp,a)}if(a.collapseOnDblClick){a.mon(a.el,'dblclick',a.toggleTargetCmp,a)}}a.getCollapseTarget().on({collapse:a.onTargetCollapse,expand:a.onTargetExpand,beforeexpand:a.onBeforeTargetExpand,beforecollapse:a.onBeforeTargetCollapse,scope:a});if(a.canResize){a.tracker=Ext.create(a.getTrackerConfig());a.relayEvents(a.tracker,['beforedragstart','dragstart','dragend'])}b=a.collapseEl;if(b){b.lastCollapseDirCls=a.collapseDirProps[a.collapseDirection].cls}},getCollapseDirection:function(){var b=this,a=b.collapseDirection,c,f,d,e;if(!a){c=b.collapseTarget;if(c.isComponent){a=c.collapseDirection}if(!a){e=b.ownerCt.layout.type;if(c.isComponent){d=b.ownerCt.items;f=Number(d.indexOf(c)===d.indexOf(b)-1)<<1|Number(e==='hbox')}else {f=Number(b.collapseTarget==='prev')<<1|Number(e==='hbox')}a=['bottom','right','top','left'][f]}b.collapseDirection=a}b.setOrientation(a==='top'||a==='bottom'?'horizontal':'vertical');return a},getCollapseTarget:function(){var a=this;return a.collapseTarget.isComponent?a.collapseTarget:a.collapseTarget==='prev'?a.previousSibling():a.nextSibling()},setCollapseEl:function(b){var a=this.collapseEl;if(a){a.setDisplayed(b)}},onBeforeTargetExpand:function(a){this.setCollapseEl('none')},onBeforeTargetCollapse:function(){this.setCollapseEl('none')},onTargetCollapse:function(b){var a=this;if(b===a.getCollapseTarget()&&b[a.orientation==='vertical'?'collapsedHorizontal':'collapsedVertical']()){a.el.addCls(a.collapsedClsInternal+' '+(a.collapsedCls||''))}a.setCollapseEl('')},onTargetExpand:function(b){var a=this;a.el.removeCls(a.collapsedClsInternal+' '+(a.collapsedCls||''));a.setCollapseEl('')},collapseDirProps:{top:{cls:'x-layout-split-top'},right:{cls:'x-layout-split-right'},bottom:{cls:'x-layout-split-bottom'},left:{cls:'x-layout-split-left'}},orientationProps:{horizontal:{opposite:'vertical',fixedAxis:'height',stretchedAxis:'width'},vertical:{opposite:'horizontal',fixedAxis:'width',stretchedAxis:'height'}},applyCollapseDirection:function(){var c=this,a=c.collapseEl,d=c.collapseDirProps[c.collapseDirection],b;if(a){b=a.lastCollapseDirCls;if(b){a.removeCls(b)}a.addCls(a.lastCollapseDirCls=d.cls)}},applyOrientation:function(){var a=this,e=a.orientation,b=a.orientationProps[e],f=a.size,d=b.fixedAxis,c=b.stretchedAxis,g=a.baseCls+'-';a[e]=!0;a[b.opposite]=!1;if(!a.hasOwnProperty(d)||a[d]==='100%'){a[d]=f}if(!a.hasOwnProperty(c)||a[c]===f){a[c]='100%'}a.removeCls(g+b.opposite);a.addCls(g+e)},setOrientation:function(b){var a=this;if(a.orientation!==b){a.orientation=b;a.applyOrientation()}},updateOrientation:function(){delete this.collapseDirection;this.getCollapseDirection();this.applyCollapseDirection()},toggleTargetCmp:function(d,e){var a=this.getCollapseTarget(),c=a.placeholder,b;if(Ext.isFunction(a.expand)&&Ext.isFunction(a.collapse)){if(c&&!c.hidden){b=!0}else {b=!a.hidden}if(b){if(a.collapsed){a.expand()}else {if(a.collapseDirection){a.collapse()}else {a.collapse(this.renderData.collapseDir)}}}}},setSize:function(){var a=this;Ext.Component.prototype.setSize.apply(this,arguments);if(Ext.isIE&&a.el){a.el.repaint()}},beforeDestroy:function(){Ext.destroy(this.tracker);Ext.Component.prototype.beforeDestroy.call(this)}},0,['splitter'],['component','box','splitter'],{'component':!0,'box':!0,'splitter':!0},['widget.splitter'],0,[Ext.resizer,'Splitter'],0);Ext.define('Ext.theme.neptune.resizer.Splitter',{override:'Ext.resizer.Splitter',size:8});Ext.cmd.derive('Ext.layout.container.Box',Ext.layout.container.Container,{alternateClassName:'Ext.layout.BoxLayout',type:'box',config:{align:'begin',constrainAlign:!1,enableSplitters:!0,overflowHandler:{$value:null,merge:function(a,b){if(typeof a==='string'){a={type:a}}return Ext.merge(b?Ext.Object.chain(b):{},a)}},padding:0,pack:'start',stretchMaxPartner:undefined,vertical:!1,alignRoundingMethod:'round'},itemCls:'x-box-item',targetCls:'x-box-layout-ct',targetElCls:'x-box-target',innerCls:'x-box-inner',manageMargins:!0,createsInnerCt:!0,childEls:['innerCt','targetEl'],renderTpl:['{%var oc,l=values.$comp.layout,oh=l.overflowHandler;if (oh && oh.getPrefixConfig!==Ext.emptyFn) {if(oc=oh.getPrefixConfig())dh.generateMarkup(oc, out)}%}{%if (oh && oh.getSuffixConfig!==Ext.emptyFn) {if(oc=oh.getSuffixConfig())dh.generateMarkup(oc, out)}%}',{disableFormats:!0,definitions:'var dh=Ext.DomHelper;'}],constructor:function(c){var a=this,b;Ext.layout.container.Container.prototype.constructor.apply(this,arguments);a.setVertical(a.vertical);a.flexSortFn=a.flexSort.bind(a);b=typeof a.padding;if(b==='string'||b==='number'){a.padding=Ext.util.Format.parseBox(a.padding);a.padding.height=a.padding.top+a.padding.bottom;a.padding.width=a.padding.left+a.padding.right}},_beginRe:/^(?:begin|left|top)$/,_centerRe:/^(?:center|middle)$/,_endRe:/^(?:end|right|bottom)$/,_percentageRe:/^\s*(\d+(?:\.\d*)?)\s*[%]\s*$/,getItemSizePolicy:function(h,b){var a=this,f=a.sizePolicy,g=a.align,p=h.flex,c=g,o=a.names,e=o.height,m=o.width,q=h[m],n=h[e],d=a._percentageRe,i=d.test(q),l=g==='stretch',j=g==='stretchmax',k=a.constrainAlign;if(!b&&(l||p||i||k&&!j)){b=a.owner.getSizeModel()}if(l){if(!d.test(n)&&b[e].shrinkWrap){c='stretchmax'}}else {if(!j){if(d.test(n)){c='stretch'}else {if(k&&!b[e].shrinkWrap){c='stretchmax'}else {c=''}}}}if(p||i){if(!b[m].shrinkWrap){f=f.flex}}return f[c]},flexSort:function(o,p){var k=this.names.maxWidth,l=this.names.minWidth,j=Infinity,c=o.target,d=p.target,m=c.flex,n=d.flex,a=0,g,i,f,h,e,b;f=c[k]||j;h=d[k]||j;g=c[l]||0;i=d[l]||0;e=isFinite(g)||isFinite(i);b=isFinite(f)||isFinite(h);if(e||b){if(b){a=f-h}if(a===0&&e){a=i-g}if(a===0){if(b){a=n-m}else {a=m-n}}}return a},isItemBoxParent:function(a){return !0},isItemShrinkWrap:function(a){return !0},roundFlex:function(a){return Math.floor(a)},beginCollapse:function(a){var b=this;if(b.direction==='vertical'&&a.collapsedVertical()){a.collapseMemento.capture(['flex']);delete a.flex}else {if(b.direction==='horizontal'&&a.collapsedHorizontal()){a.collapseMemento.capture(['flex']);delete a.flex}}},beginExpand:function(a){a.collapseMemento.restore(['flex'])},beginLayout:function(a){var c=this,f=c.owner,b=f.stretchMaxPartner,h=c.innerCt.dom.style,i=c.names,g=c.overflowHandler,e=f.getScrollable(),d;a.boxNames=i;if(g){g.beginLayout(a)}if(typeof b==='string'){b=Ext.getCmp(b)||f.query(b)[0]}a.stretchMaxPartner=b&&a.context.getCmp(b);Ext.layout.container.Container.prototype.beginLayout.apply(this,arguments);a.innerCtContext=a.getEl('innerCt',c);a.targetElContext=a.getEl('targetEl',c);if(e){a.ownerScrollable=e;d=e.getPosition();if(d.x||d.y){a.scrollRestore=d}}h.width=h.height=''},beginLayoutCycle:function(a,l){var c=this,i=a.state,g=a.ownerScrollable,b=c.align,e=a.boxNames,d=c.pack,k=c._centerRe,j=c.overflowHandler,m=a.state.canScroll,h,f;if(j){j.beginLayoutCycle(a,l)}Ext.layout.container.Container.prototype.beginLayoutCycle.apply(this,arguments);a.parallelSizeModel=h=a[e.widthModel];a.perpendicularSizeModel=f=a[e.heightModel];a.boxOptions={align:b={stretch:b==='stretch',stretchmax:b==='stretchmax',center:k.test(b),bottom:c._endRe.test(b)},pack:d={center:k.test(d),end:d==='end'}};if(g){if(!m){i.canScroll={parallel:!h.shrinkWrap&&g[e.getX](),perpendicular:!f.shrinkWrap&&g[e.getY]()}}if(!i.actualScroll){i.actualScroll={parallel:!1,perpendicular:!1}}}if(b.stretch&&f.shrinkWrap){b.stretchmax=!0;b.stretch=!1}b.nostretch=!(b.stretch||b.stretchmax);if(h.shrinkWrap){d.center=d.end=!1}c.cacheFlexes(a);c.targetEl.setWidth(20000)},cacheFlexes:function(a){var u=this,d=a.boxNames,x=d.widthModel,w=d.heightModel,z=a.boxOptions.align.nostretch,s=0,r=a.childItems,v=r.length,h=[],t=0,g=0,o=0,p=d.minWidth,y=d.minHeight,q=u._percentageRe,n=0,m=0,b,c,l,f,i,j,k,e;while(v--){c=r[v];b=c.target;j=c[x];if(j.calculated){c.flex=l=b.flex;if(l){s+=l;h.push(c);t+=b[p]||0}else {f=q.exec(b[d.width]);c.percentageParallel=parseFloat(f[1])/100;++n}}if(j.configured){k=b[d.width]}else {k=b[p]||0}o+=k;i=c[w];if(z&&i.calculated){f=q.exec(b[d.height]);c.percentagePerpendicular=parseFloat(f[1])/100;++m}if(i.configured){e=b[d.height]}else {e=b[y]||0}if(e>g){g=e}}a.flexedItems=h;a.flexedMinWidth=t;a.smallestWidth=o;a.smallestHeight=g;a.totalFlex=s;a.percentageWidths=n;a.percentageHeights=m;Ext.Array.sort(h,u.flexSortFn)},calculate:function(b){var c=this,f=b.boxNames,a=b.state,h=a.actualScroll,g=a.needsScroll,e=a.canScroll,d=a.boxPlan||(a.boxPlan={}),i=c.overflowHandler;d.targetSize=c.getContainerSize(b);if(e&&!g){a.needsScroll=g={parallel:e.parallel&&d.targetSize[f.width]j){a.invalidate({before:K,after:L,layout:l,childHeight:j,names:d});c.state.parallelDone=!1}if(isNaN(b=o(b,g+i,a.target[d.minHeight]||0))){return !1}}}if(v){b+=q;c[d.hasOverflowX]=!0;c.target.componentLayout[d.setHeightInDom]=!0;c[d.invalidateScrollX]=Ext.isIE8}p=c.stretchMaxPartner;if(p){c.setProp('maxChildHeight',b);w=p.childItems;if(w&&w.length){b=o(b,p.getProp('maxChildHeight'));if(isNaN(b)){return !1}}}c[d.setContentHeight](b+l.padding[e]+c.targetContext.getPaddingInfo()[e]);if(v){b-=q}if(b>y[e]&&H&&H.perpendicular){C.actualScroll.perpendicular=!0}t.maxSize=b;if(O){f=b}else {if(B||A||D){if(I){f=h?b:j}else {f=h?b:o(j,b)}f-=c.innerCtContext.getBorderInfo()[e]}}for(k=0;k0){n=u+Math[l.alignRoundingMethod](s/2)}}else {if(A){n=o(0,f-n-a.props[e])}}}a.setProp(M,n)}return !0},onBeforeConstrainInvalidateChild:function(b,c){var a=c.names.heightModel;if(!b[a].constrainedMin){b[a]=Ext.layout.SizeModel.calculated}},onAfterConstrainInvalidateChild:function(a,c){var b=c.names;a.setProp(b.beforeY,0);if(a[b.heightModel].calculated){a[b.setHeight](c.childHeight)}},calculateStretchMax:function(k,c,o){var f=this,h=c.height,l=c.width,g=k.childItems,n=g.length,m=o.maxSize,i=f.onBeforeStretchMaxInvalidateChild,j=f.onAfterStretchMaxInvalidateChild,a,b,d,e;for(d=0;d':{xtype:'tbfill',height:0}},1:{'->':{xtype:'tbfill',width:0}}}},initComponent:function(){var a=this,b=a.layout,c=a.vertical;if(c===undefined){a.vertical=c=a.dock==='right'||a.dock==='left'}a.layout=b=Ext.applyIf(Ext.isString(b)?{type:b}:b||{},{type:c?'vbox':'hbox',align:c?'stretchmax':'middle'});if(a.overflowHandler){b.overflowHandler=a.overflowHandler}else {if(a.enableOverflow){b.overflowHandler='menu'}}if(c){a.addClsWithUI('vertical')}if(a.ui==='footer'){a.ignoreBorderManagement=!0}Ext.container.Container.prototype.initComponent.call(this)},getRefItems:function(d){var c=this,b=Ext.container.Container.prototype.getRefItems.apply(this,arguments),e=c.layout,a;if(d&&(c.enableOverflow||c.overflowHandler==='menu')){a=e.overflowHandler;if(a&&a.menu){b=b.concat(a.menu.getRefItems(d))}}return b},lookupComponent:function(a){var d=arguments,b,c;if(typeof a==='string'){c=Ext.toolbar.Toolbar;b=c.shortcutsHV[this.vertical?1:0][a]||c.shortcuts[a];if(typeof b==='string'){a={xtype:b}}else {if(b){a=Ext.apply({},b)}else {a={xtype:'tbtext',text:a}}}this.applyDefaults(a);d=[a]}return Ext.container.Container.prototype.lookupComponent.apply(this,d)},onBeforeAdd:function(a){var b=this,d=b.ui==='footer',c=d?b.defaultFooterButtonUI:b.defaultButtonUI;if(a.isSegmentedButton){if(a.getDefaultUI()==='default'&&!a.config.hasOwnProperty('defaultUI')){a.setDefaultUI(c)}}else {if(a.ui==='default'&&!a.hasOwnProperty('ui')){if(a.isButton){a.ui=c}else {if(a.isFormField){a.ui=d?b.defaultFooterFieldUI:b.defaultFieldUI}}}}if(a instanceof Ext.toolbar.Separator){a.setUI(b.vertical?'vertical':'horizontal')}Ext.container.Container.prototype.onBeforeAdd.apply(this,arguments)},onAdd:function(a){if(a.needArrowKeys&&this.enableFocusableContainer){this.enableFocusableContainer=!1}Ext.container.Container.prototype.onAdd.apply(this,arguments);this.trackMenu(a)},onRemove:function(a){Ext.container.Container.prototype.onRemove.apply(this,arguments);this.trackMenu(a,!0)},privates:{applyDefaults:function(a){if(!Ext.isString(a)){a=Ext.container.Container.prototype.applyDefaults.apply(this,arguments)}return a},trackMenu:function(b,c){var a=this;if(a.trackMenus&&b.menu){b[c?'un':'on']({mouseover:a.onButtonOver,menushow:a.onButtonMenuShow,menuhide:a.onButtonMenuHide,scope:a})}},getChildItemsToDisable:function(){return this.items.getRange()},onButtonOver:function(a,c){var b=this.activeMenuBtn;if(b&&b!==a){b.hideMenu();a.focus();a.showMenu(c);this.activeMenuBtn=a}},onButtonMenuShow:function(a){this.activeMenuBtn=a},onButtonMenuHide:function(a){this.activeMenuBtn=null}}},0,['toolbar'],['component','box','container','toolbar'],{'component':!0,'box':!0,'container':!0,'toolbar':!0},['widget.toolbar'],[[Ext.util.FocusableContainer.prototype.mixinId||Ext.util.FocusableContainer.$className,Ext.util.FocusableContainer]],[Ext.toolbar,'Toolbar',Ext,'Toolbar'],0);Ext.define('Ext.theme.neptune.toolbar.Toolbar',{override:'Ext.toolbar.Toolbar',usePlainButtons:!1,border:!1});Ext.cmd.derive('Ext.dd.DragDrop',Ext.Base,{constructor:function(a,c,b){if(a){this.init(a,c,b)}},id:null,config:null,dragElId:null,handleElId:null,invalidHandleTypes:null,invalidHandleIds:null,invalidHandleClasses:null,startPageX:0,startPageY:0,groups:null,locked:!1,lock:function(){this.locked=!0},moveOnly:!1,unlock:function(){this.locked=!1},isTarget:!0,padding:null,_domRef:null,__ygDragDrop:!0,constrainX:!1,constrainY:!1,minX:0,maxX:0,minY:0,maxY:0,maintainOffset:!1,xTicks:null,yTicks:null,primaryButtonOnly:!0,available:!1,hasOuterHandles:!1,triggerEvent:'mousedown',b4StartDrag:function(a,b){},startDrag:function(a,b){},b4Drag:function(a){},onDrag:function(a){},onDragEnter:function(b,a){},b4DragOver:function(a){},onDragOver:function(b,a){},b4DragOut:function(a){},onDragOut:function(b,a){},b4DragDrop:function(a){},onDragDrop:function(b,a){},onInvalidDrop:function(a){},b4EndDrag:function(a){},endDrag:function(a){},b4MouseDown:function(a){},onMouseDown:function(a){},onMouseUp:function(a){},onAvailable:function(){},defaultPadding:{left:0,right:0,top:0,bottom:0},constrainTo:function(j,a,k){if(Ext.isNumber(a)){a={left:a,right:a,top:a,bottom:a}}a=a||this.defaultPadding;var c=Ext.get(this.getEl()).getBox(),e=Ext.get(j),i=e.getScroll(),b,d=e.dom,h,g,f;if(d===document.body){b={x:i.left,y:i.top,width:Ext.Element.getViewportWidth(),height:Ext.Element.getViewportHeight()}}else {h=e.getXY();b={x:h[0],y:h[1],width:d.clientWidth,height:d.clientHeight}}g=c.y-b.y;f=c.x-b.x;this.resetConstraints();this.setXConstraint(f-(a.left||0),b.width-f-c.width-(a.right||0),this.xTickSize);this.setYConstraint(g-(a.top||0),b.height-g-c.height-(a.bottom||0),this.yTickSize)},getEl:function(){if(!this._domRef){this._domRef=Ext.getDom(this.id)}return this._domRef},getDragEl:function(){return Ext.getDom(this.dragElId)},init:function(b,d,c){var a=this;a.el=a.el||Ext.get(b);a.initTarget(b,d,c);Ext.get(a.id).on(a.triggerEvent,a.handleMouseDown,a)},initTarget:function(a,b,c){this.config=c||{};this.DDMInstance=Ext.dd.DragDropManager;this.groups={};if(typeof a!=='string'){a=Ext.id(a)}this.id=a;this.addToGroup(b?b:'default');this.handleElId=a;this.setDragElId(a);this.invalidHandleTypes={A:'A'};this.invalidHandleIds={};this.invalidHandleClasses=[];this.applyConfig();this.handleOnAvailable()},applyConfig:function(){this.padding=this.config.padding||[0,0,0,0];this.isTarget=this.config.isTarget!==!1;this.maintainOffset=this.config.maintainOffset;this.primaryButtonOnly=this.config.primaryButtonOnly!==!1},handleOnAvailable:function(){this.available=!0;this.resetConstraints();this.onAvailable()},setPadding:function(a,b,c,d){if(!b&&0!==b){this.padding=[a,a,a,a]}else {if(!c&&0!==c){this.padding=[a,b,a,b]}else {this.padding=[a,b,c,d]}}},setInitPosition:function(e,f){var d=this.getEl(),b,c,a;if(!this.DDMInstance.verifyEl(d)){return}b=e||0;c=f||0;a=Ext.fly(d).getXY();this.initPageX=a[0]-b;this.initPageY=a[1]-c;this.lastPageX=a[0];this.lastPageY=a[1];this.setStartPosition(a)},setStartPosition:function(b){var a=b||Ext.fly(this.getEl()).getXY();this.deltaSetXY=null;this.startPageX=a[0];this.startPageY=a[1]},addToGroup:function(a){this.groups[a]=!0;this.DDMInstance.regDragDrop(this,a)},removeFromGroup:function(a){if(this.groups[a]){delete this.groups[a]}this.DDMInstance.removeDDFromGroup(this,a)},setDragElId:function(a){this.dragElId=a},setHandleElId:function(a){if(typeof a!=='string'){a=Ext.id(a)}this.handleElId=a;this.DDMInstance.regHandle(this.id,a)},setOuterHandleElId:function(a){if(typeof a!=='string'){a=Ext.id(a)}Ext.get(a).on(this.triggerEvent,this.handleMouseDown,this);this.setHandleElId(a);this.hasOuterHandles=!0},unreg:function(){var a=this,b;if(a._domRef){b=Ext.fly(a.id);if(b){b.un(a.triggerEvent,a.handleMouseDown,a)}}a._domRef=null;a.DDMInstance._remove(a,a.autoGroup)},destroy:function(){this.unreg();this.callParent()},isLocked:function(){return this.DDMInstance.isLocked()||this.locked},handleMouseDown:function(b,c){var a=this;if(a.primaryButtonOnly&&b.button||a.isLocked()){return}a.DDMInstance.refreshCache(a.groups);if(a.hasOuterHandles||a.DDMInstance.isOverTarget(b.getPoint(),a)){if(a.clickValidator(b)){a.setStartPosition();a.b4MouseDown(b);a.onMouseDown(b);a.DDMInstance.handleMouseDown(b,a);a.DDMInstance.stopEvent(b)}}},clickValidator:function(b){var a=b.getTarget();return this.isValidHandleChild(a)&&(this.id===this.handleElId||this.DDMInstance.handleWasClicked(a,this.id))},addInvalidHandleType:function(b){var a=b.toUpperCase();this.invalidHandleTypes[a]=a},addInvalidHandleId:function(a){if(typeof a!=='string'){a=Ext.id(a)}this.invalidHandleIds[a]=a},addInvalidHandleClass:function(a){this.invalidHandleClasses.push(a)},removeInvalidHandleType:function(a){var b=a.toUpperCase();delete this.invalidHandleTypes[b]},removeInvalidHandleId:function(a){if(typeof a!=='string'){a=Ext.id(a)}delete this.invalidHandleIds[a]},removeInvalidHandleClass:function(c){var b=this.invalidHandleClasses,d=b.length,a;for(a=0;a=this.minX;a=a-c){if(!b[a]){this.xTicks[this.xTicks.length]=a;b[a]=!0}}for(a=this.initPageX;a<=this.maxX;a=a+c){if(!b[a]){this.xTicks[this.xTicks.length]=a;b[a]=!0}}Ext.Array.sort(this.xTicks,this.DDMInstance.numericSort)},setYTicks:function(d,c){this.yTicks=[];this.yTickSize=c;var b={},a;for(a=this.initPageY;a>=this.minY;a=a-c){if(!b[a]){this.yTicks[this.yTicks.length]=a;b[a]=!0}}for(a=this.initPageY;a<=this.maxY;a=a+c){if(!b[a]){this.yTicks[this.yTicks.length]=a;b[a]=!0}}Ext.Array.sort(this.yTicks,this.DDMInstance.numericSort)},setXConstraint:function(c,b,a){this.leftConstraint=c;this.rightConstraint=b;this.minX=this.initPageX-c;this.maxX=this.initPageX+b;if(a){this.setXTicks(this.initPageX,a)}this.constrainX=!0},clearConstraints:function(){this.constrainX=!1;this.constrainY=!1;this.clearTicks()},clearTicks:function(){this.xTicks=null;this.yTicks=null;this.xTickSize=0;this.yTickSize=0},setYConstraint:function(c,b,a){this.topConstraint=c;this.bottomConstraint=b;this.minY=this.initPageY-c;this.maxY=this.initPageY+b;if(a){this.setYTicks(this.initPageY,a)}this.constrainY=!0},resetConstraints:function(){if(this.initPageX||this.initPageX===0){var a=this.maintainOffset?this.lastPageX-this.initPageX:0,b=this.maintainOffset?this.lastPageY-this.initPageY:0;this.setInitPosition(a,b)}else {this.setInitPosition()}if(this.constrainX){this.setXConstraint(this.leftConstraint,this.rightConstraint,this.xTickSize)}if(this.constrainY){this.setYConstraint(this.topConstraint,this.bottomConstraint,this.yTickSize)}},getTick:function(d,a){if(!a){return d}else {if(a[0]>=d){return a[0]}else {var b,g,c,e,f;for(b=0,g=a.length;b=d){e=d-a[b];f=a[c]-d;return f>e?a[b]:a[c]}}return a[a.length-1]}}},toString:function(){return 'DragDrop '+this.id}},3,0,0,0,0,0,[Ext.dd,'DragDrop'],0);Ext.cmd.derive('Ext.dd.DD',Ext.dd.DragDrop,{constructor:function(a,c,b){if(a){this.init(a,c,b)}},scroll:!0,autoOffset:function(a,b){var c=a-this.startPageX,d=b-this.startPageY;this.setDelta(c,d)},setDelta:function(a,b){this.deltaX=a;this.deltaY=b},setDragElPos:function(a,b){var c=this.getDragEl();this.alignElWithMouse(c,a,b)},alignElWithMouse:function(d,j,k){var a=this.getTargetCoord(j,k),c=d.dom?d:Ext.fly(d,'_dd'),e=c.getSize(),i=Ext.Element,b,g,f,h;if(!this.deltaSetXY){b=this.cachedViewportSize={width:i.getDocumentWidth(),height:i.getDocumentHeight()};g=[Math.max(0,Math.min(a.x,b.width-e.width)),Math.max(0,Math.min(a.y,b.height-e.height))];c.setXY(g);f=this.getLocalX(c);h=c.getLocalY();this.deltaSetXY=[f-a.x,h-a.y]}else {b=this.cachedViewportSize;this.setLocalXY(c,Math.max(0,Math.min(a.x+this.deltaSetXY[0],b.width-e.width)),Math.max(0,Math.min(a.y+this.deltaSetXY[1],b.height-e.height)))}this.cachePosition(a.x,a.y);this.autoScroll(a.x,a.y,d.offsetHeight,d.offsetWidth);return a},cachePosition:function(b,c){if(b){this.lastPageX=b;this.lastPageY=c}else {var a=Ext.fly(this.getEl()).getXY();this.lastPageX=a[0];this.lastPageY=a[1]}},autoScroll:function(e,f,m,n){if(this.scroll){var g=Ext.Element.getViewportHeight(),h=Ext.Element.getViewportWidth(),b=this.DDMInstance.getScrollTop(),a=this.DDMInstance.getScrollLeft(),l=m+f,j=n+e,k=g+b-f-this.deltaY,i=h+a-e-this.deltaX,d=40,c=document.all?80:30;if(l>g&&k0&&f-bh&&i0&&e-athis.maxX){a=this.maxX}}if(this.constrainY){if(bthis.maxY){b=this.maxY}}a=this.getTick(a,this.xTicks);b=this.getTick(b,this.yTicks);return {x:a,y:b}},applyConfig:function(){Ext.dd.DragDrop.prototype.applyConfig.call(this);this.scroll=this.config.scroll!==!1},b4MouseDown:function(b){var a=b.getXY();this.autoOffset(a[0],a[1])},b4Drag:function(b){var a=b.getXY();this.setDragElPos(a[0],a[1])},toString:function(){return 'DD '+this.id},getLocalX:function(a){return a.getLocalX()},setLocalXY:function(a,b,c){a.setLocalXY(b,c)}},3,0,0,0,0,0,[Ext.dd,'DD'],0);Ext.cmd.derive('Ext.dd.DDProxy',Ext.dd.DD,{statics:{dragElId:'ygddfdiv'},constructor:function(a,c,b){if(a){this.init(a,c,b);this.initFrame()}},resizeFrame:!0,centerFrame:!1,createFrame:function(){var d=this,c=document.body,a,b;if(!c||!c.firstChild){Ext.defer(function(){d.createFrame()},50);return}a=this.getDragEl();if(!a){a=document.createElement('div');a.id=this.dragElId;a.setAttribute('role','presentation');b=a.style;b.position='absolute';b.visibility='hidden';b.cursor='move';b.border='2px solid #aaa';b.zIndex=999;c.insertBefore(a,c.firstChild)}},initFrame:function(){this.createFrame()},applyConfig:function(){Ext.dd.DD.prototype.applyConfig.call(this);this.resizeFrame=this.config.resizeFrame!==!1;this.centerFrame=this.config.centerFrame;this.setDragElId(this.config.dragElId||Ext.dd.DDProxy.dragElId)},showFrame:function(d,e){var a=this,b=a.getDragEl(),c=b.style;a._resizeProxy();if(a.centerFrame){a.setDelta(Math.round(parseInt(c.width,10)/2),Math.round(parseInt(c.height,10)/2))}a.setDragElPos(d,e);Ext.fly(b).show()},_resizeProxy:function(){if(this.resizeFrame){var a=this.getEl();Ext.fly(this.getDragEl()).setSize(a.offsetWidth,a.offsetHeight)}},b4MouseDown:function(d){var a=d.getXY(),b=a[0],c=a[1];this.autoOffset(b,c);this.setDragElPos(b,c)},b4StartDrag:function(a,b){this.showFrame(a,b)},b4EndDrag:function(a){Ext.fly(this.getDragEl()).hide()},endDrag:function(c){var b=this.getEl(),a=this.getDragEl();a.style.visibility='';this.beforeMove();b.style.visibility='hidden';Ext.dd.DDM.moveToEl(b,a);a.style.visibility='hidden';b.style.visibility='';this.afterDrag()},beforeMove:function(){},afterDrag:function(){},toString:function(){return 'DDProxy '+this.id}},3,0,0,0,0,0,[Ext.dd,'DDProxy'],0);Ext.cmd.derive('Ext.dd.StatusProxy',Ext.Component,{animRepair:!1,childEls:['ghost'],renderTpl:[''],repairCls:'x-dd-drag-repair',ariaRole:'presentation',skipLayout:!0,constructor:function(a){var b=this;a=a||{};Ext.apply(b,{hideMode:'visibility',hidden:!0,floating:!0,id:b.id||Ext.id(),cls:'x-dd-drag-proxy '+this.dropNotAllowed,shadow:a.shadow||!1,renderTo:Ext.getDetachedBody()});Ext.Component.prototype.constructor.apply(this,arguments);this.dropStatus=this.dropNotAllowed},dropAllowed:'x-dd-drop-ok',dropNotAllowed:'x-dd-drop-nodrop',setStatus:function(a){a=a||this.dropNotAllowed;if(this.dropStatus!==a){this.el.replaceCls(this.dropStatus,a);this.dropStatus=a}},reset:function(c){var a=this,b='x-dd-drag-proxy ';a.el.replaceCls(b+a.dropAllowed,b+a.dropNotAllowed);a.dropStatus=a.dropNotAllowed;if(c){a.ghost.setHtml('')}},update:function(a){if(typeof a==='string'){this.ghost.setHtml(a)}else {this.ghost.setHtml('');a.style.margin='0';this.ghost.dom.appendChild(a)}var b=this.ghost.dom.firstChild;if(b){Ext.fly(b).setStyle('float','none')}},getGhost:function(){return this.ghost},hide:function(a){Ext.Component.prototype.hide.call(this);if(a){this.reset(!0)}},stop:function(){if(this.anim&&this.anim.isAnimated&&this.anim.isAnimated()){this.anim.stop()}},sync:function(){this.el.syncUnderlays()},repair:function(b,c,d){var a=this;a.callback=c;a.scope=d;if(b&&a.animRepair!==!1){a.el.addCls(a.repairCls);a.el.setUnderlaysVisible(!1);a.anim=a.el.animate({duration:a.repairDuration||500,easing:'ease-out',to:{x:b[0],y:b[1]},stopAnimation:!0,callback:a.afterRepair,scope:a})}else {a.afterRepair()}},afterRepair:function(){var a=this;a.hide(!0);a.el.removeCls(a.repairCls);if(typeof a.callback==='function'){a.callback.call(a.scope||a)}delete a.callback;delete a.scope}},1,0,['component','box'],{'component':!0,'box':!0},0,0,[Ext.dd,'StatusProxy'],0);Ext.cmd.derive('Ext.dd.DragSource',Ext.dd.DDProxy,{dropAllowed:'x-dd-drop-ok',dropNotAllowed:'x-dd-drop-nodrop',animRepair:!0,repairHighlightColor:'c3daf9',constructor:function(b,a){this.el=Ext.get(b);if(!this.dragData){this.dragData={}}Ext.apply(this,a);if(!this.proxy){this.proxy=new Ext.dd.StatusProxy({id:this.el.id+'-drag-status-proxy',animRepair:this.animRepair})}Ext.dd.DDProxy.prototype.constructor.call(this,this.el.dom,this.ddGroup||this.group,{dragElId:this.proxy.id,resizeFrame:!1,isTarget:!1,scroll:this.scroll===!0});this.dragging=!1},getDragData:function(a){return this.dragData},onDragEnter:function(c,b){var a=Ext.dd.DragDropManager.getDDById(b),d;this.cachedTarget=a;if(this.beforeDragEnter(a,c,b)!==!1){if(a.isNotifyTarget){d=a.notifyEnter(this,c,this.dragData);this.proxy.setStatus(d)}else {this.proxy.setStatus(this.dropAllowed)}if(this.afterDragEnter){this.afterDragEnter(a,c,b)}}},beforeDragEnter:function(a,c,b){return !0},onDragOver:function(c,b){var a=this.cachedTarget||Ext.dd.DragDropManager.getDDById(b),d;if(this.beforeDragOver(a,c,b)!==!1){if(a.isNotifyTarget){d=a.notifyOver(this,c,this.dragData);this.proxy.setStatus(d)}if(this.afterDragOver){this.afterDragOver(a,c,b)}}},beforeDragOver:function(a,c,b){return !0},onDragOut:function(c,b){var a=this.cachedTarget||Ext.dd.DragDropManager.getDDById(b);if(this.beforeDragOut(a,c,b)!==!1){if(a.isNotifyTarget){a.notifyOut(this,c,this.dragData)}this.proxy.reset();if(this.afterDragOut){this.afterDragOut(a,c,b)}}this.cachedTarget=null},beforeDragOut:function(a,c,b){return !0},onDragDrop:function(c,b){var a=this.cachedTarget||Ext.dd.DragDropManager.getDDById(b);if(this.beforeDragDrop(a,c,b)!==!1){if(a.isNotifyTarget){if(a.notifyDrop(this,c,this.dragData)!==!1){this.onValidDrop(a,c,b)}else {this.onInvalidDrop(a,c,b)}}else {this.onValidDrop(a,c,b)}if(this.afterDragDrop){this.afterDragDrop(a,c,b)}}delete this.cachedTarget},beforeDragDrop:function(a,c,b){return !0},onValidDrop:function(a,c,b){this.hideProxy();if(this.afterValidDrop){this.afterValidDrop(a,c,b)}},getRepairXY:function(b,a){return this.el.getXY()},onInvalidDrop:function(c,b,d){var a=this;if(!b){b=c;c=null;d=b.getTarget().id}if(a.beforeInvalidDrop(c,b,d)!==!1){if(a.cachedTarget){if(a.cachedTarget.isNotifyTarget){a.cachedTarget.notifyOut(a,b,a.dragData)}a.cacheTarget=null}a.proxy.repair(a.getRepairXY(b,a.dragData),a.afterRepair,a);if(a.afterInvalidDrop){a.afterInvalidDrop(b,d)}}},afterRepair:function(){var a=this;if(Ext.enableFx){a.el.highlight(a.repairHighlightColor)}a.dragging=!1},beforeInvalidDrop:function(a,c,b){return !0},handleMouseDown:function(b){if(this.dragging){return}var a=this.getDragData(b);if(a&&this.onBeforeDrag(a,b)!==!1){this.dragData=a;this.proxy.stop();Ext.dd.DDProxy.prototype.handleMouseDown.apply(this,arguments)}},onBeforeDrag:function(a,b){return !0},onStartDrag:Ext.emptyFn,alignElWithMouse:function(){this.proxy.ensureAttachedToBody(!0);return Ext.dd.DDProxy.prototype.alignElWithMouse.apply(this,arguments)},startDrag:function(a,b){this.proxy.reset();this.proxy.hidden=!1;this.dragging=!0;this.proxy.update('');this.onInitDrag(a,b);this.proxy.show()},onInitDrag:function(b,c){var a=this.el.dom.cloneNode(!0);a.id=Ext.id();this.proxy.update(a);this.onStartDrag(b,c);return !0},getProxy:function(){return this.proxy},hideProxy:function(){this.proxy.hide();this.proxy.reset(!0);this.dragging=!1},triggerCacheRefresh:function(){Ext.dd.DDM.refreshCache(this.groups)},b4EndDrag:function(a){},endDrag:function(a){this.onEndDrag(this.dragData,a)},onEndDrag:function(a,b){},autoOffset:function(a,b){this.setDelta(-12,-20)},destroy:function(){Ext.dd.DDProxy.prototype.destroy.call(this);Ext.destroy(this.proxy)}},1,0,0,0,0,0,[Ext.dd,'DragSource'],0);Ext.cmd.derive('Ext.panel.Proxy',Ext.Base,{alternateClassName:'Ext.dd.PanelProxy',moveOnDrag:!0,constructor:function(c,b){var a=this;a.panel=c;a.id=a.panel.id+'-ddproxy';Ext.apply(a,b)},insertProxy:!0,setStatus:Ext.emptyFn,reset:Ext.emptyFn,update:Ext.emptyFn,stop:Ext.emptyFn,sync:Ext.emptyFn,getEl:function(){return this.ghost.el},getGhost:function(){return this.ghost},getProxy:function(){return this.proxy},hide:function(){var a=this;if(a.ghost){if(a.proxy){a.proxy.destroy();delete a.proxy}a.panel.unghost(null,a.moveOnDrag);delete a.ghost}},show:function(){var a=this,b;if(!a.ghost){b=a.panel.getSize();a.panel.el.setVisibilityMode(Ext.Element.DISPLAY);a.ghost=a.panel.ghost();if(a.insertProxy){a.proxy=a.panel.el.insertSibling({role:'presentation',cls:'x-panel-dd-spacer'});a.proxy.setSize(b)}}},repair:function(c,a,b){this.hide();Ext.callback(a,b||this)},moveProxy:function(a,b){if(this.proxy){a.insertBefore(this.proxy.dom,b)}}},1,0,0,0,0,0,[Ext.panel,'Proxy',Ext.dd,'PanelProxy'],0);Ext.cmd.derive('Ext.panel.DD',Ext.dd.DragSource,{constructor:function(b,c){var a=this;a.panel=b;a.dragData={panel:b};a.panelProxy=new Ext.panel.Proxy(b,c);a.proxy=a.panelProxy.proxy;Ext.dd.DragSource.prototype.constructor.call(this,b.el,c);a.setupEl(b)},setupEl:function(c){var a=this,b=c.header,d=c.body;if(b){a.setHandleElId(b.id);d=b.el}if(d){d.setStyle('cursor','move');a.scroll=!1}else {c.on('boxready',a.setupEl,a,{single:!0})}},showFrame:Ext.emptyFn,startDrag:Ext.emptyFn,b4StartDrag:function(a,b){this.panelProxy.show()},b4MouseDown:function(b){var a=b.getXY(),c=a[0],d=a[1];this.autoOffset(c,d)},onInitDrag:function(a,b){this.onStartDrag(a,b);return !0},createFrame:Ext.emptyFn,getDragEl:function(b){var a=this.panelProxy.ghost;if(a){return a.el.dom}},endDrag:function(a){this.panelProxy.hide();this.panel.saveState()},autoOffset:function(a,b){a-=this.startPageX;b-=this.startPageY;this.setDelta(a,b)},onInvalidDrop:function(d,b,c){var a=this;if(a.beforeInvalidDrop(d,b,c)!==!1){if(a.cachedTarget){if(a.cachedTarget.isNotifyTarget){a.cachedTarget.notifyOut(a,b,a.dragData)}a.cacheTarget=null}if(a.afterInvalidDrop){a.afterInvalidDrop(b,c)}}}},1,0,0,0,0,0,[Ext.panel,'DD'],0);Ext.cmd.derive('Ext.layout.component.Dock',Ext.layout.component.Component,{alternateClassName:'Ext.layout.component.AbstractDock',type:'dock',horzAxisProps:{name:'horz',oppositeName:'vert',dockBegin:'left',dockEnd:'right',horizontal:!0,marginBegin:'margin-left',maxSize:'maxWidth',minSize:'minWidth',pos:'x',setSize:'setWidth',shrinkWrapDock:'shrinkWrapDockWidth',size:'width',sizeModel:'widthModel'},vertAxisProps:{name:'vert',oppositeName:'horz',dockBegin:'top',dockEnd:'bottom',horizontal:!1,marginBegin:'margin-top',maxSize:'maxHeight',minSize:'minHeight',pos:'y',setSize:'setHeight',shrinkWrapDock:'shrinkWrapDockHeight',size:'height',sizeModel:'heightModel'},initializedBorders:-1,horizontalCollapsePolicy:{width:!0,x:!0},verticalCollapsePolicy:{height:!0,y:!0},finishRender:function(){var a=this,b,c;Ext.layout.component.Component.prototype.finishRender.call(this);b=a.getRenderTarget();c=a.getDockedItems();a.finishRenderItems(b,c)},isItemBoxParent:function(a){return !0},isItemShrinkWrap:function(a){return !0},noBorderClasses:['x-docked-noborder-top','x-docked-noborder-right','x-docked-noborder-bottom','x-docked-noborder-left'],noBorderClassesSides:{top:'x-docked-noborder-top',right:'x-docked-noborder-right',bottom:'x-docked-noborder-bottom',left:'x-docked-noborder-left'},borderWidthProps:{top:'border-top-width',right:'border-right-width',bottom:'border-bottom-width',left:'border-left-width'},_itemCls:'x-docked',handleItemBorders:function(){var c=this,b=c.owner,a,l,k=c.lastDockedItems,j=c.borders,m=b.dockedItems.generation,i=c.noBorderClassesSides,n=c.borderWidthProps,f,h,d,g,e,o=c.collapsed;if(c.initializedBorders===m||b.border&&!b.manageBodyBorders||b.collapsed&&b.collapseMode==='mini'){return}c.initializedBorders=m;c.collapsed=!1;c.lastDockedItems=l=c.getLayoutItems();c.collapsed=o;a={top:[],right:[],bottom:[],left:[]};for(f=0,h=l.length;fj){b=i.constrainedMax;m=j}else {if(hj){c=i.constrainedMax;l=j}else {if(h',addDocked:function(c,d){var b=this,k=b.rendered,f=0,g=b.dockedItems,i=g.getCount(),e,h,a,j;c=b.prepareItems(c);j=c.length;if(k){Ext.suspendLayouts()}if(d===undefined){d=i}else {d=Math.min(d,i)}for(;f','
    ','{headingText}','
    ','','{% this.renderDockedItems(out,values,0); %}','
    {bodyCls}',' {baseCls}-body-{ui}',' {parent.baseCls}-body-{parent.ui}-{.}','{childElCls}"','',' {$}="{.}"','',' role="presentation"','',' style="{bodyStyle}">','{%this.renderContainer(out,values);%}','
    ','{% this.renderDockedItems(out,values,1); %}'],headerPosition:'top',iconAlign:'left',titleAlign:'left',titleRotation:'default',beforeRenderConfig:{glyph:null,headerPosition:null,icon:null,iconAlign:null,iconCls:null,title:null,titleAlign:null,titleRotation:null},animCollapse:Ext.enableFx,border:!0,closable:!1,closeAction:'destroy',closeToolText:'Close panel',collapsed:!1,collapsedCls:'collapsed',collapseFirst:!0,collapsible:undefined,collapseToolText:'Collapse panel',expandToolText:'Expand panel',constrain:!1,constrainHeader:!1,dockedItems:null,tbar:null,bbar:null,fbar:null,lbar:null,rbar:null,buttons:null,floatable:!0,frame:!1,frameHeader:!0,hideCollapseTool:!1,manageHeight:!0,maskElement:'el',minButtonWidth:75,preventHeader:!1,shrinkWrapDock:!1,titleCollapse:undefined,baseCls:'x-panel',bodyPosProps:{x:'x',y:'y'},componentLayout:'dock',contentPaddingProperty:'bodyPadding',emptyArray:[],isPanel:!0,defaultBindProperty:'title',addBodyCls:function(c){var a=this,b=a.rendered?a.body:a.getProtoBody();b.addCls(c);return a},addTool:function(b){if(!Ext.isArray(b)){b=[b]}var c=this,a=c.header,g=b.length,f=c.tools,e,d;if(!a||!a.isHeader){a=null;if(!f){c.tools=f=[]}}for(e=0;e=e||c[b]>0){if(b>=e){b=0;f=0;h++;for(a=0;a0){c[a]--}}}else {b++}}i.push({rowIdx:h,cellIdx:f});for(a=g.colspan||1;a;--a){c[b]=g.rowspan||1;++b}++f}return i},getRenderTree:function(){var a=this,h=a.getLayoutItems(),i=[],m=Ext.apply({tag:'table',id:a.owner.id+'-table','data-ref':'table',role:'presentation',cls:a.tableCls,cellspacing:0,cellpadding:0,cn:{tag:'tbody',id:a.owner.id+'-tbody','data-ref':'tbody',role:'presentation',cn:i}},a.tableAttrs),k=a.tdAttrs,d,n=h.length,b,f,c,g,j,e,l;l=a.calculateCells(h);for(d=0;d0){--this.disabled}},handleAdd:function(b,a){if(!this.disabled){if(a.is(this.selector)){this.onItemAdd(a.ownerCt,a)}if(a.isQueryable){this.onContainerAdd(a)}}},onItemAdd:function(e,b){var a=this,d=a.items,c=a.addHandler;if(!a.disabled){if(c){c.call(a.scope||b,b)}if(d){d.add(b)}}},onItemRemove:function(e,b){var a=this,d=a.items,c=a.removeHandler;if(!a.disabled){if(c){c.call(a.scope||b,b)}if(d){d.remove(b)}}},onContainerAdd:function(c,i){var a=this,d,e,h=a.handleAdd,g=a.handleRemove,b,f;if(c.isContainer){c.on('add',h,a);c.on('dockedadd',h,a);c.on('remove',g,a);c.on('dockedremove',g,a)}if(i!==!0){d=c.query(a.selector);for(b=0,e=d.length;bcontainer');for(b=0,e=d.length;ba.tolerance){a.triggerStart(b)}else {return}}if(a.fireEvent('mousemove',a,b)===!1){a.onMouseUp(b)}else {a.onDrag(b);a.fireEvent('drag',a,b)}},onMouseUp:function(b){var a=this;a.mouseIsDown=!1;if(a.mouseIsOut){a.mouseIsOut=!1;a.onMouseOut(b)}if(a.preventDefault!==!1){b.preventDefault()}if(Ext.isIE&&document.releaseCapture){document.releaseCapture()}a.fireEvent('mouseup',a,b);a.endDrag(b)},endDrag:function(b){var a=this,c=a.active;Ext.getDoc().un({mousemove:a.onMouseMove,mouseup:a.onMouseUp,selectstart:a.stopSelect,capture:!0,scope:a});a.clearStart();a.active=!1;if(c){a.dragEnded=!0;a.onEnd(b);a.fireEvent('dragend',a,b)}a._constrainRegion=null},triggerStart:function(b){var a=this;a.clearStart();a.active=!0;a.onStart(b);a.fireEvent('dragstart',a,b)},clearStart:function(){var a=this.timer;if(a){clearTimeout(a);this.timer=null}},stopSelect:function(a){a.stopEvent();return !1},onBeforeStart:function(a){},onStart:function(a){},onDrag:function(a){},onEnd:function(a){},getDragTarget:function(){return this.dragTarget},getDragCt:function(){return this.el},getConstrainRegion:function(){var a=this;if(a.constrainTo){if(a.constrainTo instanceof Ext.util.Region){return a.constrainTo}if(!a._constrainRegion){a._constrainRegion=Ext.fly(a.constrainTo).getViewRegion()}}else {if(!a._constrainRegion){a._constrainRegion=a.getDragCt().getViewRegion()}}return a._constrainRegion},getXY:function(a){return a?this.constrainModes[a](this,this.lastXY):this.lastXY},getOffset:function(c){var a=this.getXY(c),b=this.startXY;return [a[0]-b[0],a[1]-b[1]]},onDragStart:function(a){a.stopPropagation()},constrainModes:{point:function(d,b){var a=d.dragRegion,c=d.getConstrainRegion();if(!c){return b}a.x=a.left=a[0]=a.right=b[0];a.y=a.top=a[1]=a.bottom=b[1];a.constrainTo(c);return [a.left,a.top]},dragTarget:function(e,c){var f=e.startXY,a=e.startRegion.copy(),b=e.getConstrainRegion(),d;if(!b){return c}a.translateBy(c[0]-f[0],c[1]-f[1]);if(a.right>b.right){c[0]+=d=b.right-a.right;a.left+=d}if(a.leftb.bottom){c[1]+=d=b.bottom-a.bottom;a.top+=d}if(a.top[flex]'),o=j.length,h=n==='vertical',i=0,d=h?'width':'height',m=0,g,a;for(;i',tabGuardIndex:0},tabGuardPositionAttribute:'data-tabguardposition',privates:{initTabGuards:function(){var a=this,f=a.tabGuardPositionAttribute,c=a.tabGuardBeforeEl,d=a.tabGuardAfterEl,e=a.tabGuardIndex,b;if(!a.rendered||!a.tabGuard){return}b=a.el.findTabbableElements({skipSelf:!0});if(b[0]&&b[0].hasAttribute(f)){b.shift()}if(b.length&&b[b.length-1].hasAttribute(f)){b.pop()}if(b.length){c.dom.setAttribute('tabIndex',e);c.on('focusenter',a.onTabGuardFocusEnter,a);d.dom.setAttribute('tabIndex',e);d.on('focusenter',a.onTabGuardFocusEnter,a)}else {c.dom.removeAttribute('tabIndex');c.un('focusenter',a.onTabGuardFocusEnter,a);d.dom.removeAttribute('tabIndex');d.un('focusenter',a.onTabGuardFocusEnter,a)}},onTabGuardFocusEnter:function(j,i){var h=this,e=h.el,g=h.tabGuardPositionAttribute,f=i.getAttribute(g),d=j.relatedTarget,a,c,b;if(!d.hasAttribute(g)&&d!==e.dom&&e.contains(d)){c=f==='before'?!1:!0}else {c=f==='before'?!0:!1}a=e.findTabbableElements({skipSelf:!0});a.shift();a.pop();b=c?a[0]:a[a.length-1];if(b){b.focus()}}}},0,0,0,0,0,0,[Ext.util,'FocusTrap'],0);Ext.cmd.derive('Ext.window.Window',Ext.panel.Panel,{alternateClassName:'Ext.Window',baseCls:'x-window',resizable:!0,draggable:!0,constrain:!1,constrainHeader:!1,plain:!1,minimizable:!1,maximizable:!1,minHeight:50,minWidth:50,expandOnShow:!0,collapsible:!1,closable:!0,hidden:!0,autoRender:!0,hideMode:'offsets',floating:!0,itemCls:'x-window-item',overlapHeader:!0,ignoreHeaderBorderManagement:!0,alwaysFramed:!0,isRootCfg:{isRoot:!0},isWindow:!0,ariaRole:'dialog',initComponent:function(){var a=this;a.frame=!1;Ext.panel.Panel.prototype.initComponent.call(this);if(a.plain){a.addClsWithUI('plain')}a.addStateEvents(['maximize','restore','resize','dragend'])},getElConfig:function(){var b=this,a;a=Ext.panel.Panel.prototype.getElConfig.call(this);a.tabIndex=-1;return a},getFocusEl:function(){return this.getDefaultFocus()||this.el},getState:function(){var a=this,e=Ext.panel.Panel.prototype.getState.call(this)||{},c=!!a.maximized,d=a.ghostBox,b;e.maximized=c;if(c){b=a.restorePos}else {if(d){b=[d.x,d.y]}else {b=a.getPosition()}}Ext.apply(e,{size:c?a.restoreSize:a.getSize(),pos:b});return e},applyState:function(a){var b=this;if(a){b.maximized=a.maximized;if(b.maximized){b.hasSavedRestore=!0;b.restoreSize=a.size;b.restorePos=a.pos}else {Ext.apply(b,{width:a.size.width,height:a.size.height,x:a.pos[0],y:a.pos[1]})}}},onRender:function(c,b){var a=this;Ext.panel.Panel.prototype.onRender.apply(this,arguments);if(a.header){a.header.on({scope:a,click:a.onHeaderClick})}if(a.maximizable){a.header.on({scope:a,dblclick:a.toggleMaximize})}},afterRender:function(){var a=this,c=a.header,b;if(a.maximized){a.maximized=!1;a.maximize();if(c){c.removeCls(c.indicateDragCls)}}Ext.panel.Panel.prototype.afterRender.call(this);if(a.closable){b=a.getKeyMap();b.on(27,a.onEsc,a)}else {b=a.keyMap}if(b&&a.hidden){b.disable()}},onEsc:function(b,a){a.stopEvent();this.close()},beforeDestroy:function(){var a=this;if(a.rendered){Ext.un('resize',a.onWindowResize,a);delete a.animateTarget;a.hide();Ext.destroy(a.keyMap)}Ext.panel.Panel.prototype.beforeDestroy.call(this)},addTools:function(){var a=this,b=[];Ext.panel.Panel.prototype.addTools.call(this);if(a.minimizable){b.push({type:'minimize',handler:'minimize',scope:a})}if(a.maximizable){b.push({type:a.maximized?'restore':'maximize',handler:'toggleMaximize',scope:a})}if(b.length){a.addTool(b)}},onShow:function(){var a=this;Ext.panel.Panel.prototype.onShow.apply(this,arguments);if(a.expandOnShow){a.expand(!1)}a.syncMonitorWindowResize();if(a.keyMap){a.keyMap.enable()}},doClose:function(){var a=this;if(a.hidden){a.fireEvent('close',a);if(a.closeAction==='destroy'){a.destroy()}}else {a.hide(a.animateTarget,a.doClose,a)}},afterHide:function(){var a=this;a.syncMonitorWindowResize();if(a.keyMap){a.keyMap.disable()}Ext.panel.Panel.prototype.afterHide.apply(this,arguments)},onWindowResize:function(){var a=this,b;if(!a.destroyed){if(a.maximized){a.fitContainer()}else {b=a.getSizeModel();if(b.width.natural||b.height.natural){a.updateLayout()}a.doConstrain()}}},minimize:function(){this.fireEvent('minimize',this);return this},resumeHeaderLayout:function(a){this.header.resumeLayouts(a?this.isRootCfg:null)},afterCollapse:function(){var a=this,b=a.header,c=a.tools;if(b&&a.maximizable){b.suspendLayouts();c.maximize.hide();this.resumeHeaderLayout(!0)}if(a.resizer){a.resizer.disable()}Ext.panel.Panel.prototype.afterCollapse.apply(this,arguments)},afterExpand:function(){var a=this,c=a.header,d=a.tools,b;if(c){c.suspendLayouts();if(a.maximizable){d.maximize.show();b=!0}this.resumeHeaderLayout(b)}if(a.resizer){a.resizer.enable()}Ext.panel.Panel.prototype.afterExpand.apply(this,arguments)},maximize:function(c){var a=this,b=a.header,f=a.tools,g=a.width,e=a.height,h,d;if(!a.maximized){a.expand(!1);if(!a.hasSavedRestore){h=a.restoreSize={width:g?g:null,height:e?e:null};a.restorePos=a.getPosition()}if(b){b.suspendLayouts();if(f.maximize){f.maximize.setType('restore')}if(a.collapseTool){a.collapseTool.hide();d=!0}a.resumeHeaderLayout(d)}a.el.disableShadow();if(a.dd){a.dd.disable();if(b){b.removeCls(b.indicateDragCls)}}if(a.resizer){a.resizer.disable()}a.el.addCls('x-window-maximized');a.container.addCls('x-window-maximized-ct');a.syncMonitorWindowResize();a.fitContainer(c=c||!!a.animateTarget?{callback:function(){a.maximized=!0;a.fireEvent('maximize',a)}}:null);if(!c){a.maximized=!0;a.fireEvent('maximize',a)}}return a},restore:function(c){var a=this,f=a.tools,b=a.header,d=a.restoreSize,e;if(a.maximized){a.hasSavedRestore=null;a.removeCls('x-window-maximized');if(b){b.suspendLayouts();if(f.maximize){f.maximize.setType('maximize')}if(a.collapseTool){a.collapseTool.show();e=!0}a.resumeHeaderLayout(e)}d.x=a.restorePos[0];d.y=a.restorePos[1];a.setBox(d,c=c||!!a.animateTarget?{callback:function(){a.el.enableShadow(null,!0);a.maximized=!1;a.fireEvent('restore',a)}}:null);a.restorePos=a.restoreSize=null;if(a.dd){a.dd.enable();if(b){b.addCls(b.indicateDragCls)}}if(a.resizer){a.resizer.enable()}a.container.removeCls('x-window-maximized-ct');a.syncMonitorWindowResize();if(!c){a.el.enableShadow(null,!0);a.maximized=!1;a.fireEvent('restore',a)}}return a},syncMonitorWindowResize:function(){var a=this,b=a._monitoringResize,d=a.monitorResize||a.constrain||a.constrainHeader||a.maximized,c=a.hidden||a.destroying||a.destroyed;if(d&&!c){if(!b){Ext.on('resize',a.onWindowResize,a,{buffer:1});a._monitoringResize=!0}}else {if(b){Ext.un('resize',a.onWindowResize,a);a._monitoringResize=!1}}},toggleMaximize:function(){return this[this.maximized?'restore':'maximize']()},createGhost:function(){var a=Ext.panel.Panel.prototype.createGhost.apply(this,arguments);a.xtype='window';a.focusOnToFront=!1;return a},getDefaultFocus:function(){var d=this,b,a=d.defaultFocus,c;if(a!==undefined){if(Ext.isNumber(a)){b=d.query('button')[a]}else {if(Ext.isString(a)){c=a;if(Ext.validIdRe.test(c)){b=d.down(Ext.makeIdSelector(c))}if(!b){b=d.down(c)}}else {if(a.focus){b=a}}}}return b},privates:{initDraggable:function(){this.initSimpleDraggable()},onHeaderClick:function(b,c){var a;if(b.el.contains(c.getTarget())){a=this.getDefaultFocus();if(a){a.focus()}}},initResizable:function(){Ext.panel.Panel.prototype.initResizable.apply(this,arguments);if(this.maximized){this.resizer.disable()}}}},0,['window'],['component','box','container','panel','window'],{'component':!0,'box':!0,'container':!0,'panel':!0,'window':!0},['widget.window'],[[Ext.util.FocusTrap.prototype.mixinId||Ext.util.FocusTrap.$className,Ext.util.FocusTrap]],[Ext.window,'Window',Ext,'Window'],0);Ext.cmd.derive('Ext.form.Labelable',Ext.Mixin,{isLabelable:!0,mixinConfig:{id:'labelable',on:{beforeRender:'beforeLabelRender',onRender:'onLabelRender'}},config:{childEls:['labelEl','bodyEl','errorEl','errorWrapEl','ariaErrorEl']},labelableRenderTpl:['{beforeLabelTpl}','','{afterLabelTpl}','','','
    ','','
    ','
    ',{disableFormats:!0}],activeErrorsTpl:undefined,htmlActiveErrorsTpl:['','
      ','
    • {.}
    • ','
    ','
    '],plaintextActiveErrorsTpl:['','\n{.}',''],isFieldLabelable:!0,formItemCls:'x-form-item',labelCls:'x-form-item-label',topLabelCls:'x-form-item-label-top',rightLabelCls:'x-form-item-label-right',labelInnerCls:'x-form-item-label-inner',topLabelSideErrorCls:'x-form-item-label-top-side-error',errorMsgCls:'x-form-error-msg',errorWrapCls:'x-form-error-wrap',errorWrapSideCls:'x-form-error-wrap-side',errorWrapUnderCls:'x-form-error-wrap-under',errorWrapUnderSideLabelCls:'x-form-error-wrap-under-side-label',baseBodyCls:'x-form-item-body',invalidIconCls:'x-form-invalid-icon',invalidUnderCls:'x-form-invalid-under',noLabelCls:'x-form-item-no-label',fieldBodyCls:'',invalidCls:'x-form-invalid',fieldLabel:undefined,labelAlign:'left',labelWidth:100,labelPad:5,labelSeparator:':',hideLabel:!1,hideEmptyLabel:!0,preventMark:!1,autoFitErrors:!0,msgTarget:'qtip',msgTargets:{qtip:1,title:1,under:1,side:1,none:1},noWrap:!0,labelableInsertions:['beforeBodyEl','afterBodyEl','beforeLabelTpl','afterLabelTpl','beforeSubTpl','afterSubTpl','beforeLabelTextTpl','afterLabelTextTpl','labelAttrTpl'],statics:{initTip:function(){var b=this.tip,a,c;if(b){return}a={id:'ext-form-error-tip',ui:'form-invalid'};if(Ext.supports.Touch){a.dismissDelay=0;a.anchor='top';a.showDelay=0;a.listeners={beforeshow:function(){this.minWidth=Ext.fly(this.anchorTarget).getWidth()}}}b=this.tip=Ext.create('Ext.tip.QuickTip',a);c=Ext.apply({},b.tagConfig);c.attribute='errorqtip';b.setTagConfig(c)},destroyTip:function(){this.tip=Ext.destroy(this.tip)}},initLabelable:function(){var a=this,b=a.padding;if(b){a.padding=undefined;a.extraMargins=Ext.Element.parseBox(b)}if(Ext.isIE8){a.restoreDisplay=Ext.Function.createDelayed(a.doRestoreDisplay,0,a)}if(!a.activeErrorsTpl){if(a.msgTarget==='title'){a.activeErrorsTpl=a.plaintextActiveErrorsTpl}else {a.activeErrorsTpl=a.htmlActiveErrorsTpl}}a.addCls([a.formItemCls,a.formItemCls+'-'+a.ui]);a.lastActiveError='';a.enableBubble('errorchange')},trimLabelSeparator:function(){var b=this,c=b.labelSeparator,a=b.fieldLabel||'',d=a.substr(a.length-1);return d===c?a.slice(0,-1):a},getFieldLabel:function(){return this.trimLabelSeparator()},setFieldLabel:function(b){b=b||'';var a=this,f=a.labelSeparator,h=a.labelEl,c=a.errorWrapEl,g=a.labelAlign!=='top',e=a.noLabelCls,d=a.errorWrapUnderSideLabelCls;a.fieldLabel=b;if(a.rendered){if(Ext.isEmpty(b)&&a.hideEmptyLabel){a.addCls(e);if(g&&c){c.removeCls(d)}}else {if(f){b=a.trimLabelSeparator()+f}h.dom.firstChild.innerHTML=b;a.removeCls(e);if(g&&c){c.addCls(d)}}a.updateLayout()}},setHideLabel:function(b){var a=this;if(b!==a.hideLabel){a.hideLabel=b;if(a.rendered){a[b?'addCls':'removeCls'](a.noLabelCls);a.updateLayout()}}},setHideEmptyLabel:function(b){var a=this,c;if(b!==a.hideEmptyLabel){a.hideEmptyLabel=b;if(a.rendered&&!a.hideLabel){c=b&&!a.getFieldLabel();a[c?'addCls':'removeCls'](a.noLabelCls);a.updateLayout()}}},getInsertionRenderData:function(c,d){var e=d.length,b,a;while(e--){b=d[e];a=this[b];if(a){if(typeof a!=='string'){if(!a.isTemplate){a=Ext.XTemplate.getTpl(this,b)}a=a.apply(c)}}c[b]=a||''}return c},getLabelableRenderData:function(){var a=this,l=a.labelAlign,o=l==='top',r=l==='right',c=a.msgTarget==='side',h=a.msgTarget==='under',q=a.errorMsgCls,b=a.labelPad,m=a.labelWidth,d=a.labelClsExtra||'',j=c?a.errorWrapSideCls:a.errorWrapUnderCls,g='',f='',p=a.hasVisibleLabel(),k=a.autoFitErrors,e=a.defaultBodyWidth,n,i;if(o){d+=' '+a.topLabelCls;if(b){f='padding-bottom:'+b+'px;'}if(c&&!k){d+=' '+a.topLabelSideErrorCls}}else {if(r){d+=' '+a.rightLabelCls}if(b){g+=a.getHorizontalPaddingStyle()+b+'px;'}g+='width:'+(m+(b?b:0))+'px;';f='width:'+m+'px'}if(p){if(!o&&h){j+=' '+a.errorWrapUnderSideLabelCls}}if(e){n='min-width:'+e+'px;max-width:'+e+'px;'}i={id:a.id,inputId:a.getInputId(),labelCls:a.labelCls,labelClsExtra:d,labelStyle:g+(a.labelStyle||''),labelInnerStyle:f,labelInnerCls:a.labelInnerCls,unselectableCls:Ext.Element.unselectableCls,bodyStyle:n,baseBodyCls:a.baseBodyCls,fieldBodyCls:a.fieldBodyCls,extraFieldBodyCls:a.extraFieldBodyCls,errorWrapCls:a.errorWrapCls,errorWrapExtraCls:j,renderError:c||h,invalidMsgCls:c?a.invalidIconCls:h?a.invalidUnderCls:'',errorMsgCls:q,growCls:a.grow?a.growCls:'',tipAnchorTarget:a.id+'-inputEl',errorWrapStyle:c&&!k?'visibility:hidden':'display:none',fieldLabel:a.getFieldLabel(),labelSeparator:a.labelSeparator};a.getInsertionRenderData(i,a.labelableInsertions);return i},getHorizontalPaddingStyle:function(){return 'padding-right:'},beforeLabelRender:function(){var a=this;a.setFieldDefaults(a.getInherited().fieldDefaults);if(a.ownerLayout){a.addCls('x-'+a.ownerLayout.type+'-form-item')}if(!a.hasVisibleLabel()){a.addCls(a.noLabelCls)}},onLabelRender:function(){var a=this,f={},e=Ext.Element,d=a.errorWrapEl,c,b;if(d){d.setVisibilityMode(a.msgTarget==='side'&&!a.autoFitErrors?e.VISIBILITY:e.DISPLAY)}if(a.extraMargins){c=a.el.getMargin();for(b in c){if(c.hasOwnProperty(b)){f['margin-'+b]=c[b]+a.extraMargins[b]+'px'}}a.el.setStyle(f)}},hasVisibleLabel:function(){if(this.hideLabel){return !1}return !(this.hideEmptyLabel&&!this.getFieldLabel())},getSubTplMarkup:function(){return ''},getInputId:function(){return ''},getActiveError:function(){return this.activeError||''},hasActiveError:function(){return !!this.getActiveError()},setActiveError:function(a){this.setActiveErrors(a)},getActiveErrors:function(){return this.activeErrors||[]},setActiveErrors:function(c){var a=this,h=a.errorWrapEl,b=a.msgTarget,g=b==='side',i=b==='qtip',e,d,j,f;c=Ext.Array.from(c);j=a.getTpl('activeErrorsTpl');a.activeErrors=c;d=a.activeError=j.apply({fieldLabel:a.fieldLabel,errors:c,listCls:'x-list-plain'});a.renderActiveError();if(a.rendered){e=a.getActionEl();if(g){a.errorEl.dom.setAttribute('data-errorqtip',d)}else {if(i){e.dom.setAttribute('data-errorqtip',d)}else {if(b==='title'){e.dom.setAttribute('title',d)}}}if(b!=='title'){a.ariaErrorEl.dom.innerHTML=c.join('. ');e.dom.setAttribute('aria-describedby',a.ariaErrorEl.id)}if(g||i){Ext.form.Labelable.initTip()}if(!a.msgTargets[b]){f=Ext.get(b);if(f){f.dom.innerHTML=d}}}if(h){h.setVisible(c.length>0);if(g&&a.autoFitErrors){a.labelEl.addCls(a.topLabelSideErrorCls)}a.updateLayout()}},unsetActiveError:function(){var a=this,e=a.errorWrapEl,b=a.msgTarget,f=a.restoreDisplay,c,d;if(a.hasActiveError()){delete a.activeError;delete a.activeErrors;a.renderActiveError();if(a.rendered){c=a.getActionEl();if(b==='qtip'){c.dom.removeAttribute('data-errorqtip')}else {if(b==='title'){c.dom.removeAttribute('title')}}if(b!=='title'){a.ariaErrorEl.dom.innerHTML='';c.dom.removeAttribute('aria-describedby')}if(!a.msgTargets[b]){d=Ext.get(b);if(d){d.dom.innerHTML=''}}if(e){e.hide();if(b==='side'&&a.autoFitErrors){a.labelEl.removeCls(a.topLabelSideErrorCls)}a.updateLayout();if(f){a.el.dom.style.display='block';a.restoreDisplay()}}}}},doRestoreDisplay:function(){var a=this.el;if(a&&a.dom){a.dom.style.display=''}},renderActiveError:function(){var a=this,b=a.getActiveError(),c=!!b;if(b!==a.lastActiveError){a.lastActiveError=b;a.fireEvent('errorchange',a,b)}if(a.rendered&&!a.destroyed&&!a.preventMark){a.toggleInvalidCls(c);if(a.errorEl){a.errorEl.dom.innerHTML=b}}},toggleInvalidCls:function(a){this.el[a?'addCls':'removeCls'](this.invalidCls)},setFieldDefaults:function(b){var a;for(a in b){if(!this.hasOwnProperty(a)){this[a]=b[a]}}}},0,0,0,0,0,0,[Ext.form,'Labelable'],function(){if(Ext.supports.Touch){this.prototype.msgTarget='side'}});Ext.cmd.derive('Ext.form.field.Field',Ext.Base,{mixinId:'field',isFormField:!0,config:{validation:null,validationField:null},disabled:!1,submitValue:!0,validateOnChange:!0,valuePublishEvent:'change',suspendCheckChange:0,dirty:!1,initField:function(){var a=this,b=a.valuePublishEvent,d,c;a.initValue();if(Ext.isString(b)){a.on(b,a.publishValue,a)}else {for(c=0,d=b.length;c name="{name}"',' value="{[Ext.util.Format.htmlEncode(values.value)]}"',' placeholder="{placeholder}"','{%if (values.maxLength !== undefined){%} maxlength="{maxLength}"{%}%}',' readonly="readonly"',' disabled="disabled"',' tabindex="{tabIdx}"',' style="{fieldStyle}"',' {$}="{.}"',' class="{fieldCls} {typeCls} {typeCls}-{ui} {editableCls} {inputCls}" autocomplete="off"/>',{disableFormats:!0}],defaultBindProperty:'value',autoEl:{role:'presentation'},subTplInsertions:['inputAttrTpl'],childEls:['inputEl'],inputType:'text',isTextInput:!0,invalidText:'The value in this field is invalid',fieldCls:'x-form-field',focusCls:'form-focus',dirtyCls:'x-form-dirty',checkChangeEvents:Ext.isIE&&(!document.documentMode||document.documentMode<=9)?['change','propertychange','keyup']:['change','input','textInput','keyup','dragdrop'],ignoreChangeRe:/data\-errorqtip|style\.|className/,checkChangeBuffer:50,liquidLayout:!0,readOnly:!1,readOnlyCls:'x-form-readonly',validateOnBlur:!0,hasFocus:!1,baseCls:'x-field',fieldBodyCls:'x-field-body',maskOnDisable:!1,stretchInputElFixed:!0,ariaEl:'inputEl',initComponent:function(){var a=this;Ext.Component.prototype.initComponent.call(this);a.subTplData=a.subTplData||{};a.initLabelable();a.initField();a.initDefaultName();if(a.readOnly){a.addCls(a.readOnlyCls)}a.addCls('x-form-type-'+a.inputType)},initDefaultName:function(){var a=this;if(!a.name){a.name=a.getInputId()}},getInputId:function(){return this.inputId||(this.inputId=this.id+'-inputEl')},getSubTplData:function(f){var a=this,e=a.inputType,d=a.getInputId(),b,c;b=Ext.apply({ui:a.ui,id:d,cmpId:a.id,name:a.name||d,disabled:a.disabled,readOnly:a.readOnly,value:a.getRawValue(),type:e,fieldCls:a.fieldCls,fieldStyle:a.getFieldStyle(),childElCls:f.childElCls,tabIdx:a.tabIndex,inputCls:a.inputCls,typeCls:'x-form-'+(a.isTextInput?'text':e)},a.subTplData);if(a.ariaRole){c={role:a.ariaRole,'aria-hidden':!!a.hidden,'aria-disabled':!!a.disabled,'aria-readonly':!!a.readOnly,'aria-invalid':!1};if(a.ariaLabel){c['aria-label']=a.ariaLabel}if(a.format&&a.formatText&&!b.title){c.title=Ext.String.formatEncode(a.formatText,a.format)}b.inputElAriaAttributes=Ext.apply(c,a.getAriaAttributes())}a.getInsertionRenderData(b,a.subTplInsertions);return b},getSubTplMarkup:function(f){var b=this,c=b.getSubTplData(f),e=b.getTpl('preSubTpl'),d=b.getTpl('postSubTpl'),a='';if(e){a+=e.apply(c)}a+=b.getTpl('fieldSubTpl').apply(c);if(d){a+=d.apply(c)}return a},initRenderData:function(){return Ext.applyIf(Ext.Component.prototype.initRenderData.call(this),this.getLabelableRenderData())},setFieldStyle:function(b){var c=this,a=c.inputEl;if(a){a.applyStyles(b)}c.fieldStyle=b},getFieldStyle:function(){var a=this.fieldStyle;return Ext.isObject(a)?Ext.DomHelper.generateStyles(a,null,!0):a||''},onRender:function(){this.callParent(arguments);this.mixins.labelable.self.initTip();this.renderActiveError()},onFocusLeave:function(a){Ext.Component.prototype.onFocusLeave.call(this,a);this.completeEdit()},completeEdit:Ext.emptyFn,isFileUpload:function(){return this.inputType==='file'},getSubmitData:function(){var a=this,b=null,c;if(!a.disabled&&a.submitValue){c=a.getSubmitValue();if(c!==null){b={};b[a.getName()]=c}}return b},getSubmitValue:function(){return this.processRawValue(this.getRawValue())},getRawValue:function(){var a=this,b=a.inputEl?a.inputEl.getValue():Ext.valueFrom(a.rawValue,'');a.rawValue=b;return b},setRawValue:function(b){var a=this,c=a.rawValue;if(!a.transformRawValue.$nullFn){b=a.transformRawValue(b)}b=Ext.valueFrom(b,'');if(c===undefined||c!==b||a.valueContainsPlaceholder){a.rawValue=b;if(a.inputEl){a.bindChangeEvents(!1);a.inputEl.dom.value=b;a.bindChangeEvents(!0)}if(a.rendered&&a.reference){a.publishState('rawValue',b)}}return b},transformRawValue:Ext.identityFn,valueToRaw:function(a){return ''+Ext.valueFrom(a,'')},rawToValue:Ext.identityFn,processRawValue:Ext.identityFn,getValue:function(){var a=this,b=a.rawToValue(a.processRawValue(a.getRawValue()));a.value=b;return b},setValue:function(b){var a=this;a.setRawValue(a.valueToRaw(b));return a.mixins.field.setValue.call(a,b)},onBoxReady:function(){var a=this;Ext.Component.prototype.onBoxReady.apply(this,arguments);if(a.setReadOnlyOnBoxReady){a.setReadOnly(a.readOnly)}},onDisable:function(){var a=this,b=a.inputEl;Ext.Component.prototype.onDisable.call(this);if(b){b.dom.disabled=!0;if(a.hasActiveError()){a.clearInvalid();a.hadErrorOnDisable=!0}}if(a.wasValid===!1){a.checkValidityChange(!0)}},onEnable:function(){var a=this,b=a.inputEl,d=a.preventMark,c;Ext.Component.prototype.onEnable.call(this);if(b){b.dom.disabled=!1}if(a.wasValid!==undefined){a.forceValidation=!0;a.preventMark=!a.hadErrorOnDisable;c=a.isValid();a.forceValidation=!1;a.preventMark=d;a.checkValidityChange(c)}delete a.hadErrorOnDisable},setReadOnly:function(b){var a=this,c=a.inputEl,d=a.readOnly;b=!!b;a[b?'addCls':'removeCls'](a.readOnlyCls);a.readOnly=b;if(c){c.dom.readOnly=b;a.ariaEl.dom.setAttribute('aria-readonly',b)}else {if(a.rendering){a.setReadOnlyOnBoxReady=!0}}if(b!==d){a.fireEvent('writeablechange',a,b)}},fireKey:function(a){if(a.isSpecialKey()){this.fireEvent('specialkey',this,a)}},initEvents:function(){var a=this,d=a.inputEl,f=a.onFieldMutation,e=a.checkChangeEvents,g=e.length,c,b;if(d){a.mon(d,Ext.supports.SpecialKeyDownRepeat?'keydown':'keypress',a.fireKey,a);for(c=0;c style="{triggerStyle}">','{[values.$trigger.renderBody(values)]}',''],statics:{weightComparator:function(a,b){return a.weight-b.weight}},constructor:function(c){var a=this,b;Ext.apply(a,c);if(a.compat4Mode){b=a.cls;a.focusCls=[a.focusCls,b+'-focus'];a.overCls=[a.overCls,b+'-over'];a.clickCls=[a.clickCls,b+'-click']}},afterFieldRender:function(){this.initEvents()},destroy:function(){var a=this;a.clickRepeater=a.el=Ext.destroy(a.clickRepeater,a.el);a.callParent()},getBodyRenderData:Ext.emptyFn,getEl:function(){return this.el||null},getStateEl:function(){return this.el},hide:function(){var b=this,a=b.el;b.hidden=!0;if(a){a.hide()}},initEvents:function(){var a=this,b=a.isFieldEnabled,c=a.getStateEl(),d=a.el;c.addClsOnOver(a.overCls,b,a);c.addClsOnClick(a.clickCls,b,a);if(a.repeatClick){a.clickRepeater=new Ext.util.ClickRepeater(d,{preventDefault:!0,handler:a.onClick,listeners:{mousedown:a.onClickRepeaterMouseDown,scope:a},scope:a})}else {a.field.mon(d,{click:a.onClick,mousedown:a.onMouseDown,scope:a})}},isFieldEnabled:function(){return !this.field.disabled},isVisible:function(){var a=this,c=a.field,b=!1;if(a.hidden||!c||!a.rendered||a.destroyed){b=!0}return !b},onClick:function(){var a=this,c=arguments,e=a.clickRepeater?c[1]:c[0],d=a.handler,b=a.field;if(d&&!b.readOnly&&a.isFieldEnabled()){Ext.callback(a.handler,a.scope,[b,a,e],0,b)}},resolveListenerScope:function(a){return this.field.resolveSatelliteListenerScope(this,a)},onMouseDown:function(a){if(a.pointerType!=='touch'&&!this.field.owns(Ext.Element.getActiveElement())){this.field.inputEl.focus()}if(this.preventMouseDown){a.preventDefault()}},onClickRepeaterMouseDown:function(b,a){if(!a.parentEvent||a.parentEvent.type==='mousedown'){this.field.inputEl.focus()}a.preventDefault()},onFieldBlur:function(){this.getStateEl().removeCls(this.focusCls)},onFieldFocus:function(){this.getStateEl().addCls(this.focusCls)},onFieldRender:function(){var a=this,b=a.el=a.field.triggerWrap.selectNode('#'+a.domId,!1);b.setVisibilityMode(Ext.Element.DISPLAY);a.rendered=!0},renderBody:function(b){var a=this,c=a.bodyTpl;Ext.apply(b,a.getBodyRenderData());return c?Ext.XTemplate.getTpl(a,'bodyTpl').apply(b):''},renderTrigger:function(b){var a=this,d=a.width,c=a.hidden?'display:none;':'';if(d){c+='width:'+d}return Ext.XTemplate.getTpl(a,'renderTpl').apply({$trigger:a,fieldData:b,ui:b.ui,childElCls:b.childElCls,triggerId:a.domId=a.field.id+'-trigger-'+a.id,cls:a.cls,triggerStyle:c,extraCls:a.extraCls,baseCls:a.baseCls})},setHidden:function(a){if(a!==this.hidden){this[a?'hide':'show']()}},setVisible:function(a){this.setHidden(!a)},show:function(){var b=this,a=b.el;b.hidden=!1;if(a){a.show()}}},1,0,0,0,['trigger.trigger'],[[Ext.mixin.Factoryable.prototype.mixinId||Ext.mixin.Factoryable.$className,Ext.mixin.Factoryable]],[Ext.form.trigger,'Trigger'],0);Ext.cmd.derive('Ext.form.field.Text',Ext.form.field.Base,{alternateClassName:['Ext.form.TextField','Ext.form.Text'],config:{hideTrigger:!1,triggers:undefined},renderConfig:{editable:!0},growMin:30,growMax:800,growAppend:'W',allowBlank:!0,validateBlank:!1,allowOnlyWhitespace:!0,minLength:0,maxLength:Number.MAX_VALUE,minLengthText:'The minimum length for this field is {0}',maxLengthText:'The maximum length for this field is {0}',blankText:'This field is required',regexText:'',emptyText:'',emptyCls:'x-form-empty-field',requiredCls:'x-form-required-field',valueContainsPlaceholder:!1,ariaRole:'textbox',repeatTriggerClick:!1,triggerWrapCls:'x-form-trigger-wrap',triggerWrapFocusCls:'x-form-trigger-wrap-focus',triggerWrapInvalidCls:'x-form-trigger-wrap-invalid',fieldBodyCls:'x-form-text-field-body',inputWrapCls:'x-form-text-wrap',inputWrapFocusCls:'x-form-text-wrap-focus',inputWrapInvalidCls:'x-form-text-wrap-invalid',growCls:'x-form-text-grow',needArrowKeys:!0,squashMouseUp:{mouseup:function(){},translate:!1,single:!0,preventDefault:!0},childEls:['triggerWrap','inputWrap'],preSubTpl:[''],initComponent:function(){var a=this,b=a.emptyCls;if(a.allowOnlyWhitespace===!1){a.allowBlank=!1}if(a.size){a.defaultBodyWidth=a.size*6.5+20}if(!a.onTrigger1Click){a.onTrigger1Click=a.onTriggerClick}Ext.form.field.Base.prototype.initComponent.call(this);if(a.readOnly){a.setReadOnly(a.readOnly)}a.fieldFocusCls=a.baseCls+'-focus';a.emptyUICls=b+' '+b+'-'+a.ui;a.addStateEvents('change')},initEvents:function(){var a=this,b=a.inputEl;Ext.form.field.Base.prototype.initEvents.call(this);if(a.selectOnFocus||a.emptyText){a.mon(b,'mousedown',a.onMouseDown,a)}if(a.maskRe||a.vtype&&a.disableKeyFilter!==!0&&(a.maskRe=Ext.form.field.VTypes[a.vtype+'Mask'])){a.mon(b,'keypress',a.filterKeys,a)}if(a.enableKeyEvents){a.mon(b,{scope:a,keyup:a.onKeyUp,keydown:a.onKeyDown,keypress:a.onKeyPress})}},isEqual:function(a,b){return this.isEqualAsString(a,b)},onChange:function(a,b){Ext.form.field.Base.prototype.onChange.apply(this,arguments);this.autoSize()},getSubTplData:function(h){var a=this,c=a.getRawValue(),g=a.emptyText&&c.length<1,b=a.maxLength,e,f,d;if(a.enforceMaxLength){if(b===Number.MAX_VALUE){b=undefined}}else {b=undefined}if(g){if(Ext.supports.Placeholder){e=a.emptyText}else {c=a.emptyText;a.valueContainsPlaceholder=!0}}f=Ext.apply(Ext.form.field.Base.prototype.getSubTplData.call(this,h),{triggerWrapCls:a.triggerWrapCls,inputWrapCls:a.inputWrapCls,triggers:a.orderedTriggers,maxLength:b,readOnly:!a.editable||a.readOnly,placeholder:e,value:c,fieldCls:a.fieldCls+(g&&(e||c)?' '+a.emptyUICls:'')+(a.allowBlank?'':' '+a.requiredCls)});d=f.inputElAriaAttributes;if(d){d['aria-required']=!a.allowBlank}return f},onRender:function(){var a=this,b=a.getTriggers(),c=[],d,e;if(Ext.supports.FixedTableWidthBug){a.el._needsTableWidthFix=!0}(arguments.callee.$previous||Ext.form.field.Base.prototype.onRender).call(this);if(b){this.invokeTriggers('onFieldRender');for(d in b){c.push(b[d].el)}e=a.triggerEl=a.triggerCell=new Ext.CompositeElement(c,!0)}a.inputCell=a.inputWrap},afterRender:function(){var a=this;a.autoSize();Ext.form.field.Base.prototype.afterRender.call(this);a.invokeTriggers('afterFieldRender')},onMouseDown:function(){if(!this.hasFocus){Ext.getDoc().on(this.squashMouseUp)}},applyTriggers:function(c){var a=this,j=a.getHideTrigger(),k=a.readOnly,f=a.orderedTriggers=[],i=a.repeatTriggerClick,e,b,h,g,d;if(!c){c={};if(a.triggerCls&&!a.trigger1Cls){a.trigger1Cls=a.triggerCls}for(d=1;g=a['trigger'+d+'Cls'];d++){c['trigger'+d]={cls:g,extraCls:'x-trigger-index-'+d,handler:'onTrigger'+d+'Click',compat4Mode:!0,scope:a}}}for(e in c){if(c.hasOwnProperty(e)){b=c[e];b.field=a;b.id=e;if(k&&b.hideOnReadOnly!==!1||j&&b.hidden!==!1){b.hidden=!0}if(i&&b.repeatClick!==!1){b.repeatClick=!0}h=c[e]=Ext.form.trigger.Trigger.create(b);f.push(h)}}Ext.Array.sort(f,Ext.form.trigger.Trigger.weightComparator);return c},invokeTriggers:function(d,e){var f=this,a=f.getTriggers(),c,b;if(a){for(c in a){if(a.hasOwnProperty(c)){b=a[c];b[d].apply(b,e||[])}}}},getTrigger:function(a){return this.getTriggers()[a]},updateHideTrigger:function(a){this.invokeTriggers(a?'hide':'show')},updateEditable:function(a,b){this.setReadOnlyAttr(!a||this.readOnly)},setReadOnly:function(a){var b=this,d=b.getTriggers(),f=b.getHideTrigger(),c,e;a=!!a;Ext.form.field.Base.prototype.setReadOnly.call(this,a);if(b.rendered){b.setReadOnlyAttr(a||!b.editable)}if(d){for(e in d){c=d[e];if(c.hideOnReadOnly===!0||c.hideOnReadOnly!==!1&&!f){c.setVisible(!a)}}}},setReadOnlyAttr:function(c){var b=this,a='readonly',d=b.inputEl.dom;if(c){d.setAttribute(a,a)}else {d.removeAttribute(a)}if(b.ariaRole){b.ariaEl.dom.setAttribute('aria-readonly',!!c)}},processRawValue:function(c){var e=this,a=e.stripCharsRe,d,b;if(a){if(!a.global){d='g';d+=a.ignoreCase?'i':'';d+=a.multiline?'m':'';a=new RegExp(a.source,d)}b=c.replace(a,'');if(b!==c){e.setRawValue(b);c=b}}return c},onDisable:function(){Ext.form.field.Base.prototype.onDisable.call(this);if(Ext.isIE){this.inputEl.dom.unselectable='on'}},onEnable:function(){Ext.form.field.Base.prototype.onEnable.call(this);if(Ext.isIE){this.inputEl.dom.unselectable=''}},onKeyDown:function(a){this.fireEvent('keydown',this,a)},onKeyUp:function(a){this.fireEvent('keyup',this,a)},onKeyPress:function(a){this.fireEvent('keypress',this,a)},reset:function(){Ext.form.field.Base.prototype.reset.call(this);this.applyEmptyText()},applyEmptyText:function(){var a=this,b=a.emptyText,c;if(a.rendered&&b){c=a.getRawValue().length<1&&!a.hasFocus;if(Ext.supports.Placeholder){a.inputEl.dom.placeholder=b}else {if(c){a.setRawValue(b);a.valueContainsPlaceholder=!0}}if(c){a.inputEl.addCls(a.emptyUICls)}else {a.inputEl.removeCls(a.emptyUICls)}a.autoSize()}},getEmptyText:function(){return this.emptyText},setEmptyText:function(e){var a=this,c=a.inputEl,b=c&&c.dom,d=e||'';if(e){a.emptyText=d;a.applyEmptyText()}else {if(b){if(Ext.supports.Placeholder){b.removeAttribute('placeholder')}else {if(b.value!==a.getRawValue()){b.value='';c.removeCls(a.emptyUICls)}}a.valueContainsPlaceholder=!1}}a.emptyText=d;return a},afterFirstLayout:function(){Ext.form.field.Base.prototype.afterFirstLayout.call(this);if(Ext.isIE&&this.disabled){var a=this.inputEl;if(a){a.dom.unselectable='on'}}},toggleInvalidCls:function(b){var a=b?'addCls':'removeCls';Ext.form.field.Base.prototype.toggleInvalidCls.call(this);this.triggerWrap[a](this.triggerWrapInvalidCls);this.inputWrap[a](this.inputWrapInvalidCls)},beforeFocus:function(){var a=this,b=a.inputEl,c=a.emptyText,d;Ext.form.field.Base.prototype.beforeFocus.apply(this,arguments);if(c&&!Ext.supports.Placeholder&&(b.dom.value===a.emptyText&&a.valueContainsPlaceholder)){a.setRawValue('');d=!0;b.removeCls(a.emptyUICls);a.valueContainsPlaceholder=!1}else {if(Ext.supports.Placeholder){b.removeCls(a.emptyUICls)}}},onFocus:function(b){var a=this;Ext.form.field.Base.prototype.onFocus.apply(this,arguments);if(a.selectOnFocus){a.inputEl.dom.select()}if(a.emptyText){a.autoSize()}a.addCls(a.fieldFocusCls);a.triggerWrap.addCls(a.triggerWrapFocusCls);a.inputWrap.addCls(a.inputWrapFocusCls);a.invokeTriggers('onFieldFocus',[b])},onBlur:function(b){var a=this;Ext.form.field.Base.prototype.onBlur.apply(this,arguments);a.removeCls(a.fieldFocusCls);a.triggerWrap.removeCls(a.triggerWrapFocusCls);a.inputWrap.removeCls(a.inputWrapFocusCls);a.invokeTriggers('onFieldBlur',[b])},completeEdit:function(a){Ext.form.field.Base.prototype.completeEdit.call(this,a);this.applyEmptyText()},filterKeys:function(a){if(a.ctrlKey&&!a.altKey||a.isSpecialKey()){return}var b=String.fromCharCode(a.getCharCode());if(!this.maskRe.test(b)){a.stopEvent()}},getState:function(){return this.addPropertyToState(Ext.form.field.Base.prototype.getState.call(this),'value')},applyState:function(a){Ext.form.field.Base.prototype.applyState.apply(this,arguments);if(a.hasOwnProperty('value')){this.setValue(a.value)}},getRawValue:function(){var b=this,a=Ext.form.field.Base.prototype.getRawValue.call(this);if(a===b.emptyText&&b.valueContainsPlaceholder){a=''}return a},setValue:function(c){var a=this,b=a.inputEl;if(b&&a.emptyText&&!Ext.isEmpty(c)){b.removeCls(a.emptyUICls);a.valueContainsPlaceholder=!1}Ext.form.field.Base.prototype.setValue.apply(this,arguments);a.applyEmptyText();return a},getErrors:function(b){b=arguments.length?b==null?'':b:this.processRawValue(this.getRawValue());var a=this,c=Ext.form.field.Base.prototype.getErrors.call(this,b),f=a.validator,d=a.vtype,j=Ext.form.field.VTypes,k=a.regex,i=Ext.String.format,e,h,g;if(Ext.isFunction(f)){e=f.call(a,b);if(e!==!0){c.push(e)}}h=a.allowOnlyWhitespace?b:Ext.String.trim(b);if(h.length<1||b===a.emptyText&&a.valueContainsPlaceholder){if(!a.allowBlank){c.push(a.blankText)}if(!a.validateBlank){return c}g=!0}if(!g&&b.lengtha.maxLength){c.push(i(a.maxLengthText,a.maxLength))}if(d){if(!j[d](b,a)){c.push(a.vtypeText||j[d+'Text'])}}if(k&&!k.test(b)){c.push(a.regexText||a.invalidText)}return c},selectText:function(a,b){var f=this,g=f.getRawValue(),c=g.length,e=f.inputEl.dom,d;if(c>0){a=a===undefined?0:Math.min(a,c);b=b===undefined?c:Math.min(b,c);if(e.setSelectionRange){e.setSelectionRange(a,b)}else {if(e.createTextRange){d=e.createTextRange();d.moveStart('character',a);d.moveEnd('character',b-c);d.select()}}}},getGrowWidth:function(){return this.inputEl.dom.value},autoSize:function(){var a=this,d,f,c,g,b,e;if(a.grow&&a.rendered&&a.getSizeModel().width.auto){g=a.inputEl;d=a.getTriggers();c=0;e=Ext.util.Format.htmlEncode(a.getGrowWidth()||(a.hasFocus?'':a.emptyText)||'');e+=a.growAppend;for(f in d){c+=d[f].el.getWidth()}b=g.getTextWidth(e)+c+a.inputWrap.getBorderWidth('lr')+a.triggerWrap.getBorderWidth('lr');b=Math.min(Math.max(b,a.growMin),a.growMax);a.bodyEl.setWidth(b);a.updateLayout();a.fireEvent('autosize',a,b)}},onDestroy:function(){var a=this;a.invokeTriggers('destroy');Ext.destroy(a.triggerRepeater);Ext.form.field.Base.prototype.onDestroy.call(this)},onTriggerClick:Ext.emptyFn,privates:{getTdType:function(){return 'textfield'}},deprecated:{5:{methods:{getTriggerWidth:function(){var a=this.getTriggers(),c=0,b;if(a&&this.rendered){for(b in a){if(a.hasOwnProperty(b)){c+=a[b].el.getWidth()}}}return c}}}}},0,['textfield'],['component','box','field','textfield'],{'component':!0,'box':!0,'field':!0,'textfield':!0},['widget.textfield'],0,[Ext.form.field,'Text',Ext.form,'TextField',Ext.form,'Text'],0);Ext.cmd.derive('Ext.form.field.TextArea',Ext.form.field.Text,{alternateClassName:'Ext.form.TextArea',fieldSubTpl:['',{disableFormats:!0}],growMin:60,growMax:1000,growAppend:'\n-',enterIsSpecial:!1,preventScrollbars:!1,returnRe:/\r/g,inputCls:'x-form-textarea',extraFieldBodyCls:'x-form-textarea-body',ariaAttributes:{'aria-multiline':!0},getSubTplData:function(d){var a=this,c=a.getFieldStyle(),b=Ext.form.field.Text.prototype.getSubTplData.apply(this,arguments);if(a.grow){if(a.preventScrollbars){b.fieldStyle=(c||'')+';overflow:hidden;height:'+a.growMin+'px'}}return b},afterRender:function(){var a=this;Ext.form.field.Text.prototype.afterRender.apply(this,arguments);a.needsMaxCheck=a.enforceMaxLength&&a.maxLength!==Number.MAX_VALUE&&!Ext.supports.TextAreaMaxLength;if(a.needsMaxCheck){a.inputEl.on('paste',a.onPaste,a)}},transformRawValue:function(a){return this.stripReturns(a)},getValue:function(){return this.stripReturns(Ext.form.field.Text.prototype.getValue.call(this))},valueToRaw:function(a){a=this.stripReturns(a);return Ext.form.field.Text.prototype.valueToRaw.call(this,a)},stripReturns:function(a){if(a&&typeof a==='string'){a=a.replace(this.returnRe,'')}return a},onPaste:function(){var a=this;if(!a.pasteTask){a.pasteTask=new Ext.util.DelayedTask(a.pasteCheck,a)}a.pasteTask.delay(1)},pasteCheck:function(){var b=this,a=b.getValue(),c=b.maxLength;if(a.length>c){a=a.substr(0,c);b.setValue(a)}},fireKey:function(a){var b=this,c=a.getKey(),d;if(a.isSpecialKey()&&(b.enterIsSpecial||(c!==a.ENTER||a.hasModifier()))){b.fireEvent('specialkey',b,a)}if(b.needsMaxCheck&&c!==a.BACKSPACE&&c!==a.DELETE&&!a.isNavKeyPress()&&!b.isCutCopyPasteSelectAll(a,c)){d=b.getValue();if(d.length>=b.maxLength){a.stopEvent()}}},isCutCopyPasteSelectAll:function(a,b){if(a.ctrlKey){return b===a.A||b===a.C||b===a.V||b===a.X}return !1},autoSize:function(){var a=this,b,c,e,d;if(a.grow&&a.rendered&&a.getSizeModel().height.auto){b=a.inputEl;e=b.getWidth(!0);d=Ext.util.Format.htmlEncode(b.dom.value)||' ';d+=a.growAppend;d=d.replace(/\n/g,'
    ');c=Ext.util.TextMetrics.measure(b,d,e).height+b.getPadding('tb')+a.inputWrap.getBorderWidth('tb')+a.triggerWrap.getBorderWidth('tb');c=Math.min(Math.max(c,a.growMin),a.growMax);a.bodyEl.setHeight(c);a.updateLayout();a.fireEvent('autosize',a,c)}},beforeDestroy:function(){var a=this.pasteTask;if(a){a.cancel();this.pasteTask=null}Ext.form.field.Text.prototype.beforeDestroy.call(this)}},0,['textarea','textareafield'],['component','box','field','textfield','textareafield','textarea'],{'component':!0,'box':!0,'field':!0,'textfield':!0,'textareafield':!0,'textarea':!0},['widget.textarea','widget.textareafield'],0,[Ext.form.field,'TextArea',Ext.form,'TextArea'],0);Ext.cmd.derive('Ext.window.MessageBox',Ext.window.Window,{OK:1,YES:2,NO:4,CANCEL:8,OKCANCEL:9,YESNO:6,YESNOCANCEL:14,INFO:'x-message-box-info',WARNING:'x-message-box-warning',QUESTION:'x-message-box-question',ERROR:'x-message-box-error',hideMode:'offsets',closeAction:'hide',resizable:!1,scrollable:!0,title:' ',defaultMinWidth:250,defaultMaxWidth:600,defaultMinHeight:110,defaultMaxHeight:500,minWidth:null,maxWidth:null,minHeight:null,maxHeight:null,constrain:!0,cls:['x-message-box','x-hidden-offsets'],layout:{type:'vbox',align:'stretch'},shrinkWrapDock:!0,defaultTextHeight:75,minProgressWidth:250,minPromptWidth:250,buttonText:{ok:'OK',yes:'Yes',no:'No',cancel:'Cancel'},buttonIds:['ok','yes','no','cancel'],titleText:{confirm:'Confirm',prompt:'Prompt',wait:'Loading...',alert:'Attention'},baseIconCls:'x-message-box-icon',ariaRole:'alertdialog',makeButton:function(b){var a=this.buttonIds[b];return new Ext.button.Button({handler:this.btnCallback,itemId:a,scope:this,text:this.buttonText[a],minWidth:75})},btnCallback:function(e,b){var a=this,d,c;if(b&&b.type==='keydown'&&!b.isSpecialKey()){b.getTarget(null,null,!0).on({keyup:function(c){a.btnCallback(e,c)},single:!0});return}if(a.cfg.prompt||a.cfg.multiline){if(a.cfg.multiline){c=a.textArea}else {c=a.textField}d=c.getValue();c.reset()}a.hide();a.userCallback(e.itemId,d,a.cfg)},hide:function(){var a=this,b=a.cfg?a.cfg.cls:'';a.progressBar.reset();if(b){a.removeCls(b)}Ext.window.Window.prototype.hide.apply(this,arguments)},constructor:function(b){var a=this;Ext.window.Window.prototype.constructor.apply(this,arguments);a.minWidth=a.defaultMinWidth=a.minWidth||a.defaultMinWidth;a.maxWidth=a.defaultMaxWidth=a.maxWidth||a.defaultMaxWidth;a.minHeight=a.defaultMinHeight=a.minHeight||a.defaultMinHeight;a.maxHeight=a.defaultMaxHeight=a.maxHeight||a.defaultMaxHeight},initComponent:function(e){var a=this,b=a.id,d,c;a.title=a.title||' ';a.iconCls=a.iconCls||'';a.topContainer=new Ext.container.Container({layout:'hbox',padding:10,style:{overflow:'hidden'},items:[a.iconComponent=new Ext.Component({cls:a.baseIconCls}),a.promptContainer=new Ext.container.Container({flex:1,layout:{type:'vbox',align:'stretch'},items:[a.msg=new Ext.Component({id:b+'-msg',cls:a.baseCls+'-text'}),a.textField=new Ext.form.field.Text({id:b+'-textfield',enableKeyEvents:!0,listeners:{keydown:a.onPromptKey,scope:a}}),a.textArea=new Ext.form.field.TextArea({id:b+'-textarea',height:75})]})]});a.progressBar=new Ext.ProgressBar({id:b+'-progressbar',margin:'0 10 10 10'});a.items=[a.topContainer,a.progressBar];a.msgButtons=[];for(d=0;d<4;d++){c=a.makeButton(d);a.msgButtons[c.itemId]=c;a.msgButtons.push(c)}a.bottomTb=new Ext.toolbar.Toolbar({id:b+'-toolbar',ui:'footer',dock:'bottom',layout:{pack:'center'},items:[a.msgButtons[0],a.msgButtons[1],a.msgButtons[2],a.msgButtons[3]]});a.dockedItems=[a.bottomTb];a.on('close',a.onClose,a);Ext.window.Window.prototype.initComponent.call(this)},onClose:function(){var a=this.header.child('[type=close]');if(a){a.itemId='cancel';this.btnCallback(a);delete a.itemId}},onPromptKey:function(c,b){var a=this;if(b.keyCode===b.RETURN||b.keyCode===10){if(a.msgButtons.ok.isVisible()){a.msgButtons.ok.handler.call(a,a.msgButtons.ok)}else {if(a.msgButtons.yes.isVisible()){a.msgButtons.yes.handler.call(a,a.msgButtons.yes)}}}},reconfigure:function(b){var a=this,j=0,q=!0,t=a.buttonText,g=a.resizer,c=a.header,r=c&&!c.isHeader,s=b&&(b.message||b.msg),i,n,m,e,d,f,o,k,l,h,p;a.updateButtonText();a.cfg=b=b||{};h=b.wait;if(b.width){n=b.width}if(b.height){m=b.height}a.minWidth=b.minWidth||a.defaultMinWidth;a.maxWidth=b.maxWidth||a.defaultMaxWidth;a.minHeight=b.minHeight||a.defaultMinHeight;a.maxHeight=b.maxHeight||a.defaultMaxHeight;if(g){i=g.resizeTracker;g.minWidth=i.minWidth=a.minWidth;g.maxWidth=i.maxWidth=a.maxWidth;g.minHeight=i.minHeight=a.minHeight;g.maxHeight=i.maxHeight=a.maxHeight}delete a.defaultFocus;if(b.defaultFocus){a.defaultFocus=b.defaultFocus}a.animateTarget=b.animateTarget||undefined;a.modal=b.modal!==!1;a.setTitle(b.title||r&&c.title||a.title);a.setIconCls(b.iconCls||r&&c.iconCls||a.iconCls);if(Ext.isObject(b.buttons)){a.buttonText=b.buttons;j=0}else {a.buttonText=b.buttonText||a.buttonText;j=Ext.isNumber(b.buttons)?b.buttons:0}j=j|a.updateButtonText();a.buttonText=t;Ext.suspendLayouts();a.width=a.height=null;if(n||m){if(n){a.setWidth(n)}if(m){a.setHeight(m)}}a.hidden=!1;if(!a.rendered){a.render(Ext.getBody())}a.closable=b.closable!==!1&&!h;c=a.header;if(c){p=c.child('[type=close]');if(p){p.setVisible(a.closable)}if(!b.title&&!a.closable&&!b.iconCls){c.hide()}else {c.show()}}a.liveDrag=!b.proxyDrag;a.userCallback=Ext.Function.bindCallback(b.callback||b.fn||Ext.emptyFn,b.scope||Ext.global);a.setIcon(b.icon);o=a.msg;if(s){o.setHtml(s);o.show()}else {o.hide()}d=a.textArea;f=a.textField;if(b.prompt||b.multiline){a.multiline=b.multiline;if(b.multiline){d.setValue(b.value);d.setHeight(b.defaultTextHeight||a.defaultTextHeight);d.show();f.hide();a.defaultFocus=d}else {f.setValue(b.value);d.hide();f.show();a.defaultFocus=f}}else {d.hide();f.hide()}k=a.progressBar;if(b.progress||h){k.show();a.updateProgress(0,b.progressText);if(h){k.wait(h===!0?b.waitConfig:h)}}else {k.hide()}l=a.msgButtons;for(e=0;e<4;e++){if(j&Math.pow(2,e)){if(!a.defaultFocus){a.defaultFocus=l[e]}l[e].show();q=!1}else {l[e].hide()}}if(q){a.bottomTb.hide()}else {a.bottomTb.show()}Ext.resumeLayouts(!0)},updateButtonText:function(){var b=this,c=b.buttonText,e=0,a,d;for(a in c){if(c.hasOwnProperty(a)){d=b.msgButtons[a];if(d){if(b.cfg&&b.cfg.buttonText){e=e|Math.pow(2,Ext.Array.indexOf(b.buttonIds,a))}if(d.text!==c[a]){d.setText(c[a])}}}}return e},show:function(b){var a=this,c;b=b||{};if(Ext.Component.layoutSuspendCount){Ext.on({resumelayouts:function(){a.show(b)},single:!0});return a}a.reconfigure(b);if(b.cls){a.addCls(b.cls)}c=a.query('textfield:not([hidden]),textarea:not([hidden]),button:not([hidden])');a.preventFocusOnActivate=!c.length;a.hidden=!0;Ext.window.Window.prototype.show.call(this);return a},onShow:function(){Ext.window.Window.prototype.onShow.apply(this,arguments);this.center()},updateText:function(a){this.msg.setHtml(a)},setIcon:function(e,d,c){var b=this,a=b.iconComponent,f=b.messageIconCls;if(f){a.removeCls(f)}if(e){a.show();if(d||c){a.setSize(d||a.getWidth(),c||a.getHeight())}a.addCls('x-dlg-icon');a.addCls(b.messageIconCls=e)}else {a.removeCls('x-dlg-icon');a.hide()}return b},updateProgress:function(c,b,a){this.progressBar.updateProgress(c,b);if(a){this.updateText(a)}return this},onEsc:function(){if(this.closable!==!1){Ext.window.Window.prototype.onEsc.apply(this,arguments)}},confirm:function(a,b,d,c){if(Ext.isString(a)){a={title:a,icon:this.QUESTION,message:b,buttons:this.YESNO,callback:d,scope:c}}return this.show(a)},prompt:function(a,c,f,d,b,e){if(Ext.isString(a)){a={prompt:!0,title:a,minWidth:this.minPromptWidth,message:c,buttons:this.OKCANCEL,callback:f,scope:d,multiline:b,value:e}}return this.show(a)},wait:function(a,c,b){if(Ext.isString(a)){a={title:c,message:a,closable:!1,wait:!0,modal:!0,minWidth:this.minProgressWidth,waitConfig:b}}return this.show(a)},alert:function(a,b,d,c){if(Ext.isString(a)){a={title:a,message:b,buttons:this.OK,fn:d,scope:c,minWidth:this.minWidth}}return this.show(a)},progress:function(a,c,b){if(Ext.isString(a)){a={title:a,message:c,progress:!0,progressText:b}}return this.show(a)}},1,['messagebox'],['component','box','container','panel','window','messagebox'],{'component':!0,'box':!0,'container':!0,'panel':!0,'window':!0,'messagebox':!0},['widget.messagebox'],0,[Ext.window,'MessageBox'],function(a){Ext.onInternalReady(function(){Ext.MessageBox=Ext.Msg=new a()})});Ext.cmd.derive('Ext.form.Basic',Ext.util.Observable,{alternateClassName:'Ext.form.BasicForm',taskDelay:10,constructor:function(c,d){var a=this,b;a.owner=c;a.fieldMonitors={validitychange:a.checkValidityDelay,enable:a.checkValidityDelay,disable:a.checkValidityDelay,dirtychange:a.checkDirtyDelay,errorchange:a.checkErrorDelay,scope:a};a.checkValidityTask=new Ext.util.DelayedTask(a.checkValidity,a);a.checkDirtyTask=new Ext.util.DelayedTask(a.checkDirty,a);a.checkErrorTask=new Ext.util.DelayedTask(a.checkError,a);a.monitor=new Ext.container.Monitor({selector:'[isFormField]:not([excludeForm])',scope:a,addHandler:a.onFieldAdd,removeHandler:a.onFieldRemove,invalidateHandler:a.onMonitorInvalidate});a.monitor.bind(c);Ext.apply(a,d);if(Ext.isString(a.paramOrder)){a.paramOrder=a.paramOrder.split(/[\s,|]/)}b=a.reader;if(b&&!b.isReader){if(typeof b==='string'){b={type:b}}a.reader=Ext.createByAlias('reader.'+b.type,b)}b=a.errorReader;if(b&&!b.isReader){if(typeof b==='string'){b={type:b}}a.errorReader=Ext.createByAlias('reader.'+b.type,b)}Ext.util.Observable.prototype.constructor.call(this)},initialize:function(){this.initialized=!0;this.onValidityChange(!this.hasInvalidField())},timeout:30,paramsAsHash:!1,waitTitle:'Please Wait...',trackResetOnLoad:!1,wasDirty:!1,destroy:function(){var a=this,b=a.monitor;if(b){b.unbind();a.monitor=null}a.clearListeners();a.checkValidityTask.cancel();a.checkDirtyTask.cancel();a.checkErrorTask.cancel();a.checkValidityTask=a.checkDirtyTask=a.checkErrorTask=null;Ext.util.Observable.prototype.destroy.call(this)},onFieldAdd:function(a){a.on(this.fieldMonitors);this.onMonitorInvalidate()},onFieldRemove:function(a){a.un(this.fieldMonitors);this.onMonitorInvalidate()},onMonitorInvalidate:function(){if(this.initialized){this.checkValidityDelay()}},getFields:function(){return this.monitor.getItems()},getBoundItems:function(){var a=this._boundItems;if(!a||a.getCount()===0){a=this._boundItems=new Ext.util.MixedCollection();a.addAll(this.owner.query('[formBind]'))}return a},hasInvalidField:function(){return !!this.getFields().findBy(function(a){var c=a.preventMark,b;a.preventMark=!0;b=a.isValid();a.preventMark=c;return !b})},isValid:function(){var b=this,a;Ext.suspendLayouts();a=b.getFields().filterBy(function(a){return !a.validate()});Ext.resumeLayouts(!0);return a.length<1},checkValidity:function(){var a=this,b;if(a.destroyed){return}b=!a.hasInvalidField();if(b!==a.wasValid){a.onValidityChange(b);a.fireEvent('validitychange',a,b);a.wasValid=b}},checkValidityDelay:function(){var a=this.taskDelay;if(a){this.checkValidityTask.delay(a)}else {this.checkValidity()}},checkError:function(){this.fireEvent('errorchange',this)},checkErrorDelay:function(){var a=this.taskDelay;if(a){this.checkErrorTask.delay(a)}else {this.checkError()}},onValidityChange:function(e){var d=this.getBoundItems(),b,a,f,c;if(d){b=d.items;f=b.length;for(a=0;a',' {$}="{.}"','',' role="presentation"','','>','{%this.renderContainer(out,values)%}',''],initComponent:function(){var a=this;a.initLabelable();a.initFieldAncestor();Ext.container.Container.prototype.initComponent.call(this);a.initMonitor()},onAdd:function(b){var a=this;if(b.isLabelable&&Ext.isGecko&&Ext.firefoxVersion<37&&a.layout.type==='absolute'&&!a.hideLabel&&a.labelAlign!=='top'){b.x+=a.labelWidth+a.labelPad}Ext.container.Container.prototype.onAdd.apply(this,arguments);if(b.isLabelable&&a.combineLabels){b.oldHideLabel=b.hideLabel;b.hideLabel=!0}a.updateLabel()},onRemove:function(a,c){var b=this;Ext.container.Container.prototype.onRemove.apply(this,arguments);if(!c){if(a.isLabelable&&b.combineLabels){a.hideLabel=a.oldHideLabel}b.updateLabel()}},initRenderData:function(){var b=this,a=Ext.container.Container.prototype.initRenderData.call(this);a.containerElCls=b.containerElCls;a=Ext.applyIf(a,b.getLabelableRenderData());a.tipAnchorTarget=b.id+'-containerEl';return a},getFieldLabel:function(){var a=this.fieldLabel||'';if(!a&&this.combineLabels){a=Ext.Array.map(this.query('[isFieldLabelable]'),function(a){return a.getFieldLabel()}).join(this.labelConnector)}return a},getSubTplData:function(){var a=this.initRenderData();Ext.apply(a,this.subTplData);return a},getSubTplMarkup:function(d){var b=this,a=b.getTpl('fieldSubTpl'),c;if(!a.renderContent){b.setupRenderTpl(a)}c=a.apply(b.getSubTplData(d));return c},updateLabel:function(){var a=this,b=a.labelEl;if(b){a.setFieldLabel(a.getFieldLabel())}},onFieldErrorChange:function(){if(this.combineErrors){var a=this,d=a.getActiveError(),c=Ext.Array.filter(a.query('[isFormField]'),function(a){return a.hasActiveError()}),b=a.getCombinedErrors(c);if(b){a.setActiveErrors(b)}else {a.unsetActiveError()}if(d!==a.getActiveError()){a.updateLayout()}}},getCombinedErrors:function(f){var g=[],b,j=f.length,d,c,a,i,h,e;for(b=0;b','','{beforeBoxLabelTpl}','','{afterBoxLabelTpl}','',' tabindex="{tabIdx}"',' disabled="disabled"',' style="{fieldStyle}"',' class="{checkboxCls} {clipCls}" autocomplete="off" hidefocus="true" ',' {$}="{.}"','/>','','','{beforeBoxLabelTpl}','','{afterBoxLabelTpl}','','',{disableFormats:!0,compiled:!0}],publishes:{checked:1},subTplInsertions:['beforeBoxLabelTpl','afterBoxLabelTpl','beforeBoxLabelTextTpl','afterBoxLabelTextTpl','boxLabelAttrTpl','inputAttrTpl'],isCheckbox:!0,focusCls:'form-checkbox-focus',fieldBodyCls:'x-form-cb-wrap',checked:!1,checkedCls:'x-form-cb-checked',boxLabelCls:'x-form-cb-label',boxLabelAlign:'after',afterLabelCls:'x-form-cb-after',wrapInnerCls:'x-form-cb-wrap-inner',noBoxLabelCls:'x-form-cb-no-box-label',inputValue:'on',checkChangeEvents:[],inputType:'checkbox',isTextInput:!1,ariaRole:'checkbox',onRe:/^on$/i,inputCls:'x-form-cb',_checkboxCls:'x-form-cb-input',_clipCls:'x-hidden-clip',initComponent:function(){var a=this,b=a.value;if(b!==undefined){a.checked=a.isChecked(b,a.inputValue)}Ext.form.field.Base.prototype.initComponent.call(this);a.getManager().add(a)},initDefaultName:Ext.emptyFn,initValue:function(){var a=this,b=!!a.checked;a.originalValue=a.lastValue=b;a.setValue(b)},getElConfig:function(){var a=this;if(a.isChecked(a.rawValue,a.inputValue)){a.addCls(a.checkedCls)}return Ext.form.field.Base.prototype.getElConfig.call(this)},getSubTplData:function(g){var a=this,f=a.boxLabel,e=a.boxLabelAlign,d=e==='before',c,b;c=Ext.apply(Ext.form.field.Base.prototype.getSubTplData.call(this,g),{clipCls:a._clipCls,checkboxCls:a._checkboxCls,disabled:a.readOnly||a.disabled,wrapInnerCls:a.wrapInnerCls,boxLabel:f,boxLabelCls:a.boxLabelCls,boxLabelAlign:e,labelAlignedBefore:d,afterLabelCls:d?a.afterLabelCls:'',noBoxLabelCls:!f?a.noBoxLabelCls:'',inputName:a.name||a.id});b=c.inputElAriaAttributes;if(b){b['aria-checked']=!!a.checked;b['aria-labelledby']=a.id+'-boxLabelEl'}return c},initEvents:function(){var a=this;Ext.form.field.Base.prototype.initEvents.call(this);a.inputEl.on({click:'onBoxClick',scope:a,translate:!1});a.displayEl.on({click:'onBoxClick',mousedown:'_onDisplayElMouseDown',scope:a})},setBoxLabel:function(b){var a=this;a.boxLabel=b;if(a.rendered){a.boxLabelEl.setHtml(b);a.boxLabelEl[b?'removeCls':'addCls'](a.noBoxLabelCls);a.updateLayout()}},onBoxClick:function(){var a=this;if(!a.disabled&&!a.readOnly){a.setValue(!a.checked)}},getRawValue:function(){return this.checked},getValue:function(){return this.checked},getSubmitValue:function(){var a=this.uncheckedValue,b=Ext.isDefined(a)?a:null;return this.checked?this.inputValue:b},isChecked:function(a,b){return a===!0||a==='true'||a==='1'||a===1||((Ext.isString(a)||Ext.isNumber(a))&&b?a==b:this.onRe.test(a))},setRawValue:function(e){var a=this,d=a.inputEl,c=a.displayEl,b=a.isChecked(e,a.inputValue);if(d){a[b?'addCls':'removeCls'](a.checkedCls);if(a.ariaRole){a.ariaEl.dom.setAttribute('aria-checked',b)}}if(Ext.isIE8&&c&&b!==a.lastValue){c.repaint()}a.checked=a.rawValue=b;if(!a.duringSetValue){a.lastValue=b}return b},setValue:function(e){var a=this,c,b,f,d;if(Ext.isArray(e)){c=a.getManager().getByName(a.name,a.getFormId()).items;f=c.length;for(b=0;b style="{bodyStyle}">','{%this.renderContainer(out,values);%}',''],stateEvents:['collapse','expand'],maskOnDisable:!1,beforeDestroy:function(){var b=this,a=b.legend;if(a){delete a.ownerCt;a.destroy();b.legend=null}Ext.container.Container.prototype.beforeDestroy.call(this)},initComponent:function(){var a=this,b=a.baseCls;if(a.ariaRole&&!a.ariaLabel){a.ariaLabel=Ext.String.formatEncode(a.descriptionText,a.title||'')}a.ariaRenderAttributes=a.ariaRenderAttributes||{};a.ariaRenderAttributes['aria-expanded']=!a.collapsed;a.initFieldAncestor();Ext.container.Container.prototype.initComponent.call(this);a.layout.managePadding=a.layout.manageOverflow=!1;if(a.collapsed){a.addCls(b+'-collapsed');a.collapse()}if(a.title||a.checkboxToggle||a.collapsible){a.addTitleClasses();a.legend=a.createLegendCt()}a.initMonitor()},initRenderData:function(){var b=this,a=Ext.container.Container.prototype.initRenderData.call(this);a.bodyTargetCls=b.bodyTargetCls;b.protoBody.writeTo(a);delete b.protoBody;return a},getState:function(){var a=Ext.container.Container.prototype.getState.call(this);a=this.addPropertyToState(a,'collapsed');return a},afterCollapse:Ext.emptyFn,afterExpand:Ext.emptyFn,collapsedHorizontal:function(){return !0},collapsedVertical:function(){return !0},createLegendCt:function(){var a=this,c=[],d={baseCls:a.baseCls+'-header',layout:'container',ui:a.ui,id:a.id+'-legend',autoEl:'legend',ariaRole:null,items:c,ownerCt:a,shrinkWrap:!0,ownerLayout:a.componentLayout},b;if(a.checkboxToggle){c.push(a.createCheckboxCmp())}else {if(a.collapsible){c.push(a.createToggleCmp())}}c.push(a.createTitleCmp());b=new Ext.container.Container(d);b.collapseImmune=!0;b.getInherited().collapseImmune=!0;return b},createTitleCmp:function(){var a=this,b={html:a.title,ui:a.ui,cls:a.baseCls+'-header-text',id:a.id+'-legendTitle',ariaRole:'presentation'};if(a.collapsible&&a.toggleOnTitleClick){b.listeners={click:{element:'el',scope:a,fn:a.toggle}};b.cls+=' '+a.baseCls+'-header-text-collapsible'}a.titleCmp=new Ext.Component(b);return a.titleCmp},createCheckboxCmp:function(){var a=this,d='-checkbox',b=a.baseCls+'-header'+d,c;b+=' '+b+'-'+a.ui;a.checkboxCmp=c=new Ext.form.field.Checkbox({hideEmptyLabel:!0,name:a.checkboxName||a.id+d,cls:b,id:a.id+'-legendChk',ui:a.checkboxUI,checked:!a.collapsed,msgTarget:'none',listeners:{change:a.onCheckChange,scope:a},ariaLabel:a.expandText});return c},createToggleCmp:function(){var a=this,b;a.toggleCmp=b=new Ext.panel.Tool({cacheHeight:!1,cls:a.baseCls+'-header-tool-'+a.ui,type:'toggle',handler:a.toggle,id:a.id+'-legendToggle',scope:a,ariaRole:'checkbox',ariaLabel:a.expandText,ariaRenderAttributes:{'aria-checked':!a.collapsed}});return b},doRenderLegend:function(d,c){var e=c.$comp,a=e.legend,b;if(a){a.ownerLayout.configureItem(a);b=a.getRenderTree();Ext.DomHelper.generateMarkup(b,d)}},getCollapsed:function(){return this.collapsed?'top':!1},getCollapsedDockedItems:function(){var a=this.legend;return a?[a]:[]},setTitle:function(c){var a=this,b=a.legend;a.title=c;a.ariaLabel=Ext.String.formatEncode(a.descriptionText,c||'');if(a.rendered){if(!b){a.legend=b=a.createLegendCt();a.addTitleClasses();b.ownerLayout.configureItem(b);b.render(a.el,0)}a.titleCmp.update(c);a.ariaEl.dom.setAttribute('aria-label',a.ariaLabel)}else {if(b){a.titleCmp.update(c)}else {a.addTitleClasses();a.legend=a.createLegendCt()}}return a},addTitleClasses:function(){var a=this,c=a.title,b=a.baseCls;if(c){a.addCls(b+'-with-title')}if(c||a.checkboxToggle||a.collapsible){a.addCls(b+'-with-legend')}},expand:function(){return this.setExpanded(!0)},collapse:function(){return this.setExpanded(!1)},setExpanded:function(b){var a=this,d=a.checkboxCmp,c=a.toggleCmp,e=b?'expand':'collapse';if(!a.rendered||a.fireEvent('before'+e,a)!==!1){b=!!b;if(d){d.setValue(b)}else {if(c&&c.ariaEl.dom){c.ariaEl.dom.setAttribute('aria-checked',b)}}if(b){a.removeCls(a.baseCls+'-collapsed')}else {a.addCls(a.baseCls+'-collapsed')}if(a.ariaEl.dom){a.ariaEl.dom.setAttribute('aria-expanded',!!b)}a.collapsed=!b;if(b){delete a.getInherited().collapsed}else {a.getInherited().collapsed=!0}if(a.rendered){a.updateLayout({isRoot:!1});a.fireEvent(e,a)}}return a},getRefItems:function(c){var a=Ext.container.Container.prototype.getRefItems.apply(this,arguments),b=this.legend;if(b){a.unshift(b);if(c){a.unshift.apply(a,b.getRefItems(!0))}}return a},toggle:function(){this.setExpanded(!!this.collapsed)},privates:{applyTargetCls:function(a){this.bodyTargetCls=a},finishRender:function(){var a=this.legend;Ext.container.Container.prototype.finishRender.call(this);if(a){a.finishRender()}},getProtoBody:function(){var b=this,a=b.protoBody;if(!a){b.protoBody=a=new Ext.util.ProtoElement({styleProp:'bodyStyle',styleIsText:!0})}return a},getDefaultContentTarget:function(){return this.body},getTargetEl:function(){return this.body||this.frameBody||this.el},initPadding:function(d){var b=this,e=b.getProtoBody(),a=b.padding,c;if(a!==undefined){if(Ext.isIE8){a=b.parseBox(a);c=Ext.Element.parseBox(0);c.top=a.top;a.top=0;e.setStyle('padding',b.unitizeBox(c))}d.setStyle('padding',b.unitizeBox(a))}},onCheckChange:function(b,a){this.setExpanded(a)},setupRenderTpl:function(a){Ext.container.Container.prototype.setupRenderTpl.apply(this,arguments);a.renderLegend=this.doRenderLegend}}},0,['fieldset'],['component','box','container','fieldset'],{'component':!0,'box':!0,'container':!0,'fieldset':!0},['widget.fieldset'],[['fieldAncestor',Ext.form.FieldAncestor]],[Ext.form,'FieldSet'],0);Ext.cmd.derive('Ext.form.Label',Ext.Component,{autoEl:'label',maskOnDisable:!1,getElConfig:function(){var a=this;a.html=a.text?Ext.util.Format.htmlEncode(a.text):a.html||'';return Ext.apply(Ext.Component.prototype.getElConfig.call(this),{htmlFor:a.forId||''})},setText:function(c,b){var a=this;b=b!==!1;if(b){a.text=c;delete a.html}else {a.html=c;delete a.text}if(a.rendered){a.el.dom.innerHTML=b!==!1?Ext.util.Format.htmlEncode(c):c;a.updateLayout()}return a}},0,['label'],['component','box','label'],{'component':!0,'box':!0,'label':!0},['widget.label'],0,[Ext.form,'Label'],0);Ext.cmd.derive('Ext.form.Panel',Ext.panel.Panel,{alternateClassName:['Ext.FormPanel','Ext.form.FormPanel'],layout:'anchor',bodyAriaRole:'form',basicFormConfigs:['api','baseParams','errorReader','jsonSubmit','method','paramOrder','paramsAsHash','reader','standardSubmit','timeout','trackResetOnLoad','url','waitMsgTarget','waitTitle'],initComponent:function(){var a=this;if(a.frame){a.border=!1}a.initFieldAncestor();Ext.panel.Panel.prototype.initComponent.call(this);a.relayEvents(a.form,['beforeaction','actionfailed','actioncomplete','validitychange','dirtychange']);if(a.pollForChanges){a.startPolling(a.pollInterval||500)}},initItems:function(){Ext.panel.Panel.prototype.initItems.call(this);this.initMonitor();this.form=this.createForm()},afterFirstLayout:function(){Ext.panel.Panel.prototype.afterFirstLayout.apply(this,arguments);this.form.initialize()},createForm:function(){var d={},c=this.basicFormConfigs,e=c.length,b=0,a;for(;b150){delete a.lastDownArrow}if(!a.isExpanded){b.stopEvent();a.onTriggerClick();a.lastDownArrow=b.time}else {if(!b.isStopped&&b.time-a.lastDownArrow<150){delete a.lastDownArrow}}},expand:function(){var a=this,d,c,b,e;if(a.rendered&&!a.isExpanded&&!a.destroyed){d=a.bodyEl;b=a.getPicker();e=Ext.getDoc();b.setMaxHeight(b.initialConfig.maxHeight);if(a.matchFieldWidth){b.setWidth(a.bodyEl.getWidth())}b.show();a.isExpanded=!0;a.alignPicker();d.addCls(a.openCls);if(a.ariaRole){c=a.ariaEl.dom;c.setAttribute('aria-owns',b.listEl?b.listEl.id:b.el.id);c.setAttribute('aria-expanded',!0)}a.touchListeners=e.on({translate:!1,touchstart:a.collapseIf,scope:a,delegated:!1,destroyable:!0});a.scrollListeners=Ext.on({scroll:a.onGlobalScroll,scope:a,destroyable:!0});Ext.on('resize',a.alignPicker,a,{buffer:1});a.fireEvent('expand',a);a.onExpand()}},onExpand:Ext.emptyFn,alignPicker:function(){if(!this.destroyed){var a=this.getPicker();if(a.isVisible()&&a.isFloating()){this.doAlign()}}},doAlign:function(){var a=this,c=a.picker,d='-above',b;a.picker.alignTo(a.triggerWrap,a.pickerAlign,a.pickerOffset);b=c.el.getY()=g){a.deselectRange(j,g-1)}else {if(h!==c){a.selectRange(h,c,f)}}}a.lastSelected=c}else {if(e){if(!f){a.doSelect(c,!1)}}else {a.selectWithEvent(c,b)}}}};break;case 'SIMPLE':if(e===b.A&&f){a.selected.beginUpdate();a.selectRange(0,a.store.getCount()-1);a.selected.endUpdate()}else {if(k){a.doDeselect(c)}else {a.doSelect(c,!0)}};break;case 'SINGLE':if(!f){if(i){a.doSelect(c,!1)}else {if(m||!e){a.selectWithEvent(c,b)}}};}if(!b.shiftKey&&!a.destroyed&&a.isSelected(c)){a.selectionStart=c;a.selectionStartIdx=g}},selectRange:function(d,f,m){var b=this,i=b.store,l=b.selected.items,h,a,g,e,c,j,k;if(b.isLocked()){return}h=b.normalizeRowRange(d,f);d=h[0];f=h[1];e=[];for(a=d;a<=f;a++){if(!b.isSelected(i.getAt(a))){e.push(i.getAt(a))}}if(!m){c=[];b.suspendChanges();for(a=0,g=l.length;af){c.push(k)}}for(a=0,g=c.length;a0)}}}},deselectRange:function(d,e){var a=this,h=a.store,g,c,b,f;if(a.isLocked()){return}g=a.normalizeRowRange(d,e);d=g[0];e=g[1];b=[];for(c=d;c<=e;c++){f=h.getAt(c);if(a.isSelected(f)){b.push(f)}}if(b.length){a.doDeselect(b)}},normalizeRowRange:function(a,b){var c=this.store,d;if(!Ext.isNumber(a)){a=c.indexOf(a)}a=Math.max(0,a);if(!Ext.isNumber(b)){b=c.indexOf(b)}b=Math.min(b,c.getCount()-1);if(a>b){d=b;b=a;a=d}return [a,b]},select:function(a,c,b){if(Ext.isDefined(a)&&!(Ext.isArray(a)&&!a.length)){this.doSelect(a,c,b)}},deselect:function(b,a){this.doDeselect(b,a)},doSelect:function(a,e,d){var b=this,c;if(b.locked||a==null){return}if(typeof a==='number'){c=b.store.getAt(a);if(!c){return}a=[c]}if(b.selectionMode==='SINGLE'){if(a.isModel){a=[a]}if(a.length){b.doSingleSelect(a[0],d)}}else {b.doMultiSelect(a,e,d)}},doMultiSelect:function(b,k,d){var a=this,g=a.selected,h=!1,e,f,j,c,i;if(a.locked){return}b=!Ext.isArray(b)?[b]:b;j=b.length;if(!k&&g.getCount()>0){e=a.deselectDuringSelect(b,d);if(a.destroyed){return}if(e[0]){a.maybeFireSelectionChange(e[1]>0&&!d);return}else {h=e[1]>0}}i=function(){if(!g.getCount()){a.selectionStart=c}g.add(c);h=!0};for(f=0;f0&&!f);return d===g},doSingleSelect:function(b,c){var a=this,e=!1,d=a.selected,f;if(a.locked){return}if(a.isSelected(b)){return}f=function(){if(d.getCount()){a.suspendChanges();var f=a.deselectDuringSelect([b],c);if(a.destroyed){return}a.resumeChanges();if(f[0]){return !1}}a.lastSelected=b;if(!d.getCount()){a.selectionStart=b}d.add(b);e=!0};a.onSelectChange(b,!0,c,f);if(e&&!a.destroyed){a.maybeFireSelectionChange(!c)}},maybeFireSelectionChange:function(b){var a=this;if(b&&!a.suspendChange){a.fireEvent('selectionchange',a,a.getSelection())}},getLastSelected:function(){return this.lastSelected},getSelection:function(){return this.selected.getRange()},getSelectionMode:function(){return this.selectionMode},setSelectionMode:function(a){a=a?a.toUpperCase():'SINGLE';this.selectionMode=this.modes[a]?a:'SINGLE'},isLocked:function(){return this.locked},setLocked:function(a){this.locked=!!a},isRangeSelected:function(b,c){var e=this,f=e.store,a,d;d=e.normalizeRowRange(b,c);b=d[0];c=d[1];for(a=b;a<=c;a++){if(!e.isSelected(f.getAt(a))){return !1}}return !0},isSelected:function(a){a=Ext.isNumber(a)?this.store.getAt(a):a;return this.selected.contains(a)},hasSelection:function(){var a=this.getSelected();return !!(a&&a.getCount())},refresh:function(){var a=this,l=a.store,e=[],c=[],k=a.getSelection(),m=k.length,b=a.getSelected(),h,j,d,g,i,f;if(!l||!(b.isCollection||b.isRows)||!b.getCount()){return}d=l.getData();if(d.getSource){j=d.getSource();if(j){d=j}}a.refreshing=!0;b.beginUpdate();a.suspendChanges();for(f=0;f0);if(i){a.fireEvent('lastselectedchanged',a,a.getSelection(),a.lastSelected)}},pruneRemovedOnRefresh:function(){return this.pruneRemoved},onStoreLoad:Ext.emptyFn,onSelectChange:function(d,e,b,f){var a=this,c=e?'select':'deselect';if((b||a.fireEvent('before'+c,a,d))!==!1&&f()!==!1){if(!b){a.fireEvent(c,a,d)}}},onEditorKey:Ext.emptyFn,beforeViewRender:function(a){Ext.Array.include(this.views||(this.views=[]),a)},onHeaderClick:Ext.emptyFn,resolveListenerScope:function(a){var c=this.view,b;if(c){b=c.resolveSatelliteListenerScope(this,a)}return b||Ext.mixin.Observable.prototype.resolveListenerScope.call(this,a)},bindComponent:Ext.emptyFn,privates:{onBeforeNavigate:Ext.privateFn,selectWithEventMulti:function(b,l,e){var a=this,g=l.shiftKey,c=l.ctrlKey,j=g?a.getSelectionStart():null,i=a.getSelection(),k=i.length,f,d,h;if(g&&j){a.selectRange(j,b,c)}else {if(c&&e){if(a.allowDeselect){a.doDeselect(b,!1)}}else {if(c){a.doSelect(b,!0,!1)}else {if(e&&!g&&!c&&k>1){if(a.allowDeselect){f=[];for(d=0;dthis.view.all.getCount()-1){a=0}this.setPosition(a,b)},onKeyRight:function(b){var a=this.recordIndex+1;if(a>this.view.all.getCount()-1){a=0}this.setPosition(a,b)},onKeyLeft:function(b){var a=this.recordIndex-1;if(a<0){a=this.view.all.getCount()-1}this.setPosition(a,b)},onKeyPageDown:Ext.emptyFn,onKeyPageUp:Ext.emptyFn,onKeyHome:function(a){this.setPosition(0,a)},onKeyEnd:function(a){this.setPosition(this.view.all.getCount()-1,a)},onKeySpace:function(a){this.fireNavigateEvent(a)},onKeyEnter:function(a){a.stopEvent();a.view.fireEvent('itemclick',a.view,a.record,a.item,a.recordIndex,a)},onSelectAllKeyPress:function(a){this.fireNavigateEvent(a)},fireNavigateEvent:function(b){var a=this;a.fireEvent('navigate',{navigationModel:a,keyEvent:b,previousRecordIndex:a.previousRecordIndex,previousRecord:a.previousRecord,previousItem:a.previousItem,recordIndex:a.recordIndex,record:a.record,item:a.item})},destroy:function(){var a=this;a.setStore(null);Ext.destroy(a.viewListeners,a.keyNav);a.keyNav=a.viewListeners=a.dataSource=a.lastFocused=null;a.callParent()}},1,0,0,0,['view.navigation.default'],[[Ext.util.Observable.prototype.mixinId||Ext.util.Observable.$className,Ext.util.Observable],[Ext.mixin.Factoryable.prototype.mixinId||Ext.mixin.Factoryable.$className,Ext.mixin.Factoryable],[Ext.util.StoreHolder.prototype.mixinId||Ext.util.StoreHolder.$className,Ext.util.StoreHolder]],[Ext.view,'NavigationModel'],0);Ext.cmd.derive('Ext.view.AbstractView',Ext.Component,{inheritableStatics:{getRecord:function(a){return this.getBoundView(a).getRecord(a)},getBoundView:function(a){return Ext.getCmp(a.getAttribute('data-boundView'))}},defaultBindProperty:'store',renderBuffer:document.createElement('div'),statics:{updateDelay:200,queueRecordChange:function(n,o,d,m,f){var a=this,g=a.changeQueue||(a.changeQueue={}),i=d.internalId,h,b,l,e,c,j,k;h=g[i]||(g[i]={operation:m,record:d,data:{},views:[]});b=h.data;Ext.Array.include(h.views,n);if(f&&(l=f.length)){for(e=0;e
    {1}
    ',a.itemCls,b,a.itemAriaRole);a.tpl=new Ext.XTemplate(b,c)}Ext.Component.prototype.initComponent.call(this);a.tpl=a.getTpl('tpl');if(a.overItemCls){a.trackOver=!0}a.addCmpEvents();d=a.store=Ext.data.StoreManager.lookup(a.store||'ext-empty-store');if(!a.dataSource){a.dataSource=d}a.bindStore(d,!0);a.getNavigationModel().bindComponent(this);if(!a.all){a.all=new Ext.CompositeElementLite()}a.scrollState={top:0,left:0};a.savedTabIndexAttribute='data-savedtabindex-'+a.id},getElConfig:function(){var a=this.mixins.renderable.getElConfig.call(this);if(this.focusable){a.tabIndex=0}return a},onRender:function(){var a=this.loadMask;Ext.Component.prototype.onRender.apply(this,arguments);if(a){this.createMask(a)}},beforeLayout:function(){var a=this;Ext.Component.prototype.beforeLayout.apply(this,arguments);if(a.refreshNeeded&&!a.pendingRefresh){if(a.refreshCounter){a.refresh()}else {a.doFirstRefresh(a.dataSource)}}},onMaskBeforeShow:function(){var a=this,b=a.loadingHeight;if(b&&b>a.getHeight()){a.hasLoadingHeight=!0;a.oldMinHeight=a.minHeight;a.minHeight=b;a.updateLayout()}},onMaskHide:function(){var a=this;if(!a.destroying&&a.hasLoadingHeight){a.minHeight=a.oldMinHeight;a.updateLayout();delete a.hasLoadingHeight}},beforeRender:function(){Ext.Component.prototype.beforeRender.apply(this,arguments);this.getSelectionModel().beforeViewRender(this)},afterRender:function(){Ext.Component.prototype.afterRender.apply(this,arguments);if(this.focusable){this.focusEl=this.el}},getRefItems:function(){var a=this.loadMask,b=[];if(a&&a.isComponent){b.push(a)}return b},getSelection:function(){return this.getSelectionModel().getSelection()},updateSelection:function(c){var a=this,b;if(!a.ignoreNextSelection){a.ignoreNextSelection=!0;b=a.getSelectionModel();if(c){b.select(c)}else {b.deselectAll()}a.ignoreNextSelection=!1}},updateBindSelection:function(d,c){var a=this,b=null;if(!a.ignoreNextSelection){a.ignoreNextSelection=!0;if(c.length){b=d.getLastSelected();a.hasHadSelection=!0}if(a.hasHadSelection){a.setSelection(b)}a.ignoreNextSelection=!1}},applySelectionModel:function(b,e){var a=this,g=a.grid,c,f,d;if(e){e.un({scope:a,selectionchange:a.updateBindSelection,lastselectedchanged:a.updateBindSelection,select:a.ariaSelect,deselect:a.ariaDeselect});Ext.destroy(a.selModelRelayer);b=Ext.Factory.selection(b)}else {if(b&&b.isSelectionModel){b.locked=a.disableSelection}else {if(a.simpleSelect){c='SIMPLE'}else {if(a.multiSelect){c='MULTI'}else {c='SINGLE'}}if(typeof b==='string'){b={type:b}}b=Ext.Factory.selection(Ext.apply({allowDeselect:a.allowDeselect||a.multiSelect,mode:c,locked:a.disableSelection},b))}}if(b.mode!=='SINGLE'){d=(g||a).ariaEl.dom;if(d){d.setAttribute('aria-multiselectable',!0)}else {if(!g){f=a.ariaRenderAttributes||(a.ariaRenderAttributes={});f['aria-multiselectable']=!0}}}a.selModelRelayer=a.relayEvents(b,['selectionchange','beforeselect','beforedeselect','select','deselect','focuschange']);b.on({scope:a,lastselectedchanged:a.updateBindSelection,selectionchange:a.updateBindSelection,select:a.ariaSelect,deselect:a.ariaDeselect});return b},updateSelectionModel:function(a){this.selModel=a},applyNavigationModel:function(a){return Ext.Factory.viewNavigation(a)},onFocusEnter:function(d){var a=this,b=a.getNavigationModel(),c;a.toggleChildrenTabbability(!1);if(!a.itemFocused&&a.all.getCount()){c=b.getLastFocused();b.setPosition(c||0,d.event,null,!c);a.itemFocused=b.getPosition()!=null}if(a.itemFocused){this.el.dom.setAttribute('tabIndex','-1')}Ext.Component.prototype.onFocusEnter.call(this,d)},onFocusLeave:function(b){var a=this;if(a.itemFocused&&!a.refreshing){a.getNavigationModel().setPosition(null,b.event,null,!0);a.itemFocused=!1;a.el.dom.setAttribute('tabIndex',0)}Ext.Component.prototype.onFocusLeave.call(this,b)},ariaSelect:function(c,b){var a=this.getNode(b);if(a){a.setAttribute('aria-selected',!0)}},ariaDeselect:function(c,b){var a=this.getNode(b);if(a){a.removeAttribute('aria-selected')}},onRemoved:function(a){Ext.Component.prototype.onRemoved.call(this,a);if(!a){this.onFocusLeave({})}},refresh:function(){var a=this,c=a.all,i=c.getCount(),g=a.refreshCounter,e,k,f,j=a.getSelectionModel(),h,d=g&&c.getCount()&&a.preserveScrollOnRefresh&&a.getScrollable(),b;if(!a.rendered||a.destroyed){return}if(!a.hasListeners.beforerefresh||a.fireEvent('beforerefresh',a)!==!1){a.refreshing=!0;h=a.saveFocusState();e=a.getTargetEl();f=a.getViewRange();k=e.dom;if(d){b=d.getPosition();if(!(b.x||b.y)){b=null}}if(g){a.clearViewEl();a.refreshCounter++}else {a.refreshCounter=1}a.tpl.append(e,a.collectData(f,c.startIndex||0));if(f.length<1){a.addEmptyText();c.clear()}else {a.collectNodes(e.dom);a.updateIndexes(0)}h();if(a.refreshSelmodelOnRefresh!==!1){j.refresh()}a.refreshNeeded=!1;a.refreshSize(c.getCount()!==i);a.fireEvent('refresh',a,f);if(d){d.scrollTo(b)}if(!a.viewReady){a.viewReady=!0;a.fireEvent('viewready',a)}a.refreshing=!1;a.refreshScroll();a.cleanupData()}},addEmptyText:function(){var a=this,b=a.getStore();if(a.emptyText&&!b.isLoading()&&(!a.deferEmptyText||a.refreshCounter>1||b.isLoaded())){a.emptyEl=Ext.core.DomHelper.insertHtml('beforeEnd',a.getTargetEl().dom,a.emptyText)}},getViewRange:function(){return this.dataSource.getRange()},refreshSize:function(d){var a=this,b=a.getSizeModel(),c=a.getScrollable();if(b.height.shrinkWrap||b.width.shrinkWrap||d){a.updateLayout()}else {if(a.touchScroll&&!a.bufferedRenderer){if(c){c.refresh()}else {a.on({boxready:a.refreshScroll,scope:a,single:!0})}}}},afterFirstLayout:function(d,c){var a=this,b=a.getScrollable();if(b){b.on({scroll:a.onViewScroll,scrollend:a.onViewScrollEnd,scope:a,onFrame:!!Ext.global.requestAnimationFrame})}Ext.Component.prototype.afterFirstLayout.call(this,d,c)},clearViewEl:function(){var a=this,c=a.getTargetEl(),b=a.getNodeContainer()===c;a.clearEmptyEl();a.all.clear(!b);if(b){c.dom.innerHTML=''}},clearEmptyEl:function(){var a=this.emptyEl;if(a){Ext.removeNode(a)}this.emptyEl=null},onViewScroll:function(c,a,b){this.fireEvent('scroll',this,a,b)},onViewScrollEnd:function(c,a,b){this.fireEvent('scrollend',this,a,b)},saveScrollState:function(){var a=this,b=a.scrollState;if(a.rendered){b.left=a.getScrollX();b.top=a.getScrollY()}},restoreScrollState:function(){var a=this,b=a.scrollState;if(a.rendered){a.setScrollX(b.left);a.setScrollY(b.top)}},prepareData:function(c,f,e){var a,b,d;if(e){a=e.getAssociatedData();for(b in a){if(a.hasOwnProperty(b)){if(!d){c=Ext.Object.chain(c);d=!0}c[b]=a[b]}}}return c},collectData:function(c,e){var d=[],a=0,f=c.length,b;for(;a-1){if(a.getNode(b)){d=a.bufferRender([b],c).children[0];a.all.replaceElement(c,d,!0);a.updateIndexes(c,c);e.onUpdate(b);a.refreshSizePending=!0;if(e.isSelected(b)){a.onItemSelect(b)}if(a.hasListeners.itemupdate){a.fireEvent('itemupdate',b,c,d)}return d}}}},onReplace:function(o,b,e,d){var a=this,c=a.all,n=a.getSelectionModel(),j=b,h,m,g,f,l,k,i;if(a.rendered){h=a.bufferRender(d,b,!0);g=h.fragment;f=h.children;m=c.item(b);if(m){c.item(b).insertSibling(g,'before',!0)}else {a.appendNodes(g)}c.insert(b,f);if(e.length){i=a.saveFocusState()}b+=d.length;k=b+e.length-1;l=c.removeRange(b,k,!0);if(a.refreshSelmodelOnRefresh!==!1){n.refresh()}a.updateIndexes(b);if(a.hasListeners.itemremove){a.fireEvent('itemremove',e,j,l,a)}if(a.hasListeners.itemadd){a.fireEvent('itemadd',d,j,f)}i();a.refreshSize()}},onAdd:function(f,d,b){var a=this,c,e=a.getSelectionModel();if(a.rendered){if(a.all.getCount()===0){a.refresh();c=a.all.slice()}else {c=a.doAdd(d,b);if(a.refreshSelmodelOnRefresh!==!1){e.refresh()}a.updateIndexes(b);a.refreshSizePending=!0}if(a.hasListeners.itemadd){a.fireEvent('itemadd',d,b,c)}}},appendNodes:function(a){var b=this.all,c=b.getCount();if(this.nodeContainerSelector){this.getNodeContainer().appendChild(a)}else {b.item(c-1).insertSibling(a,'after')}},doAdd:function(j,b){var d=this,g=d.bufferRender(j,b,!0),f=g.fragment,c=g.children,a=d.all,h=a.getCount(),e=a.startIndex||0,i=a.endIndex||h-1;if(h===0||b>i){d.appendNodes(f)}else {if(b<=e){a.item(e).insertSibling(f,'before',!0)}else {a.item(b).insertSibling(c,'before',!0)}}a.insert(b,c);return c},onRemove:function(l,d,b){var a=this,i=a.all,g=a.hasListeners.itemremove,e,c,k,f,h,j;if(i.getCount()){if(a.dataSource.getCount()===0){if(g){a.fireEvent('itemremove',d,b,a.getNodes(b,b+d.length-1))}a.refresh()}else {j=a.saveFocusState();if(g){f=[]}for(c=d.length-1;c>=0;--c){k=d[c];e=b+c;if(f){h=i.item(e);f[c]=h?h.dom:undefined}if(i.item(e)){a.doRemove(k,e)}}if(g){a.fireEvent('itemremove',d,b,f,a)}j();a.updateIndexes(b)}a.refreshSizePending=!0}},doRemove:function(b,a){this.all.removeElement(a,!0)},saveFocusState:function(){var a=this,e=a.dataSource||a.store,c=a.getNavigationModel(),b=c.recordIndex,d=c.record;if(a.el.contains(Ext.Element.getActiveElement())){a.el.dom.focus();return function(){if(e.getCount()){b=Math.min(b,a.all.getCount()-1);c.setPosition(e.contains(d)?d:b,null,null,!0)}}}return Ext.emptyFn},refreshNode:function(a){if(Ext.isNumber(a)){a=this.store.getAt(a)}this.onUpdate(this.dataSource,a)},updateIndexes:function(d,b){var e=this.all.elements,c,f=this.getViewRange(),a,g=this.id;d=d||0;b=b||(b===0?0:e.length-1);for(a=d;a<=b;a++){c=e[a];c.setAttribute('data-recordIndex',a);c.setAttribute('data-recordId',f[a].internalId);c.setAttribute('data-boundView',g)}},bindStore:function(b,e){var a=this,c=a.getSelectionModel(),d=a.getNavigationModel();c.bindStore(b);c.bindComponent(b?a:null);a.mixins.storeholder.bindStore.apply(a,arguments);d.setStore(b);if(b&&a.componentLayoutCounter){a.doFirstRefresh(b,!e)}},doFirstRefresh:function(b,c){var a=this;if(a.deferInitialRefresh&&!c){Ext.defer(a.doFirstRefresh,1,a,[b,!0])}else {if(b&&!b.isLoading()){a.refresh()}}},onUnbindStore:function(a){this.setMaskBind(null);if(this.dataSource===a){this.dataSource=null}},onBindStore:function(c,b){var a=this;if(a.store.isBufferedStore){a.store.preserveScrollOnReload=a.preserveScrollOnReload}if(b&&b.isBufferedStore){delete b.preserveScrollOnReload}a.setMaskBind(c);if(!a.dataSource){a.dataSource=c}},setMaskBind:function(b){var a=this.loadMask;if(this.rendered&&a&&b&&!a.bindStore){a=this.createMask()}if(a&&a.bindStore){a.bindStore(b)}},getStoreListeners:function(){var a=this;return {refresh:a.onDataRefresh,replace:a.onReplace,add:a.onAdd,remove:a.onRemove,update:a.onUpdate,clear:a.onDataRefresh,beginupdate:a.onBeginUpdate,endupdate:a.onEndUpdate}},onBeginUpdate:function(){++this.updateSuspendCounter;Ext.suspendLayouts()},onEndUpdate:function(){var a=this;if(a.updateSuspendCounter){--a.updateSuspendCounter}Ext.resumeLayouts(!0);if(a.refreshSizePending){a.refreshSize(!0);a.refreshSizePending=!1}},onDataRefresh:function(b){var a=this,c=a.preserveScrollOnRefresh;if(b.loadCount>a.lastRefreshLoadCount){a.preserveScrollOnRefresh=a.preserveScrollOnReLoad}a.refreshView();a.preserveScrollOnRefresh=c;a.lastRefreshLoadCount=b.loadCount},refreshView:function(){var a=this,b=a.blockRefresh||!a.rendered||a.up('[collapsed],[isCollapsingOrExpanding],[hidden]');if(b){a.refreshNeeded=!0}else {if(a.bufferedRenderer){a.bufferedRenderer.refreshView()}else {a.refresh()}}},findItemByChild:function(a){return Ext.fly(a).findParent(this.getItemSelector(),this.getTargetEl())},findTargetByEvent:function(a){return a.getTarget(this.getItemSelector(),this.getTargetEl())},getSelectedNodes:function(){var c=[],b=this.getSelectionModel().getSelection(),d=b.length,a=0;for(;aa.bottom){d=b.bottom-a.bottom}}if(b.lefta.right){c=b.right-a.right}}if(c||d){g.scrollBy(c,d,!1)}e.set({tabIndex:-1});e.focus()}},privates:{repaintBorder:function(b){var a=this.getNode(b);if(a){a.className=a.className}}}},0,['dataview'],['component','box','dataview'],{'component':!0,'box':!0,'dataview':!0},['widget.dataview'],0,[Ext.view,'View',Ext,'DataView'],0);Ext.cmd.derive('Ext.view.BoundListKeyNav',Ext.view.NavigationModel,{navigateOnSpace:!0,initKeyNav:function(c){var a=this,b=c.pickerField;if(!a.keyNav){Ext.view.NavigationModel.prototype.initKeyNav.call(this,c);a.keyNav.map.addBinding({key:Ext.event.Event.ESC,fn:a.onKeyEsc,scope:a})}if(!b){return}if(!b.rendered){b.on('render',Ext.Function.bind(a.initKeyNav,a,[c],0),a,{single:!0});return}a.fieldKeyNav=new Ext.util.KeyNav({disabled:!0,target:b.inputEl,forceKeyDown:!0,up:a.onKeyUp,down:a.onKeyDown,right:a.onKeyRight,left:a.onKeyLeft,pageDown:a.onKeyPageDown,pageUp:a.onKeyPageUp,home:a.onKeyHome,end:a.onKeyEnd,tab:a.onKeyTab,space:a.onKeySpace,enter:a.onKeyEnter,A:{ctrl:!0,handler:a.onSelectAllKeyPress},priority:1001,scope:a})},processViewEvent:function(b,c,e,d,a){if(a.within(b.listWrap)){return a}if(a.getKey()===a.ESC){if(Ext.fly(a.target).isInputField()){a.target=a.target.parentNode}return a}},enable:function(){this.fieldKeyNav.enable();Ext.view.NavigationModel.prototype.enable.call(this)},disable:function(){this.fieldKeyNav.disable();Ext.view.NavigationModel.prototype.disable.call(this)},onItemMouseDown:function(e,b,d,c,a){Ext.view.NavigationModel.prototype.onItemMouseDown.call(this,e,b,d,c,a);a.preventDefault()},onKeyUp:function(g){var d=this,a=d.view,f=a.all,c=a.highlightedItem,b=c?a.indexOf(c):-1,e=b>0?b-1:f.getCount()-1;d.setPosition(e);g.preventDefault()},onKeyDown:function(g){var d=this,a=d.view,f=a.all,c=a.highlightedItem,b=c?a.indexOf(c):-1,e=b
    ',destroy:function(){var a=this;if(a.spinnerEl){a.spinnerEl.destroy();a.spinnerEl=a.upEl=a.downEl=null}Ext.form.trigger.Trigger.prototype.destroy.call(this)},getBodyRenderData:function(){var a=this;return {vertical:a.vertical,upDisabledCls:a.upEnabled?'':a.spinnerUpCls+'-disabled',downDisabledCls:a.downEnabled?'':a.spinnerDownCls+'-disabled',spinnerCls:a.spinnerCls,spinnerUpCls:a.spinnerUpCls,spinnerDownCls:a.spinnerDownCls}},getStateEl:function(){return this.spinnerEl},onClick:function(){var a=this,d=arguments,c=a.clickRepeater?d[1]:d[0],b=a.field;if(!b.readOnly&&!b.disabled){if(a.upEl.contains(c.target)){Ext.callback(a.upHandler,a.scope,[b,a,c],0,b)}else {if(a.downEl.contains(c.target)){Ext.callback(a.downHandler,a.scope,[b,a,c],0,b)}}}b.inputEl.focus()},onFieldRender:function(){var a=this,d=a.vertical,c,b;Ext.form.trigger.Trigger.prototype.onFieldRender.call(this);c=a.spinnerEl=a.el.select('.'+a.spinnerCls,!0);b=c.elements;a.upEl=d?b[0]:b[1];a.downEl=d?b[1]:b[0]},setUpEnabled:function(a){this.upEl[a?'removeCls':'addCls'](this.spinnerUpCls+'-disabled')},setDownEnabled:function(a){this.downEl[a?'removeCls':'addCls'](this.spinnerDownCls+'-disabled')}},0,0,0,0,['trigger.spinner'],0,[Ext.form.trigger,'Spinner'],0);Ext.cmd.derive('Ext.form.field.Spinner',Ext.form.field.Text,{alternateClassName:'Ext.form.Spinner',config:{triggers:{spinner:{type:'spinner',upHandler:'onSpinnerUpClick',downHandler:'onSpinnerDownClick',scope:'this'}}},spinUpEnabled:!0,spinDownEnabled:!0,keyNavEnabled:!0,mouseWheelEnabled:!0,repeatTriggerClick:!0,onSpinUp:Ext.emptyFn,onSpinDown:Ext.emptyFn,ariaRole:'spinbutton',applyTriggers:function(b){var c=this,a=b.spinner;a.upEnabled=c.spinUpEnabled;a.downEnabled=c.spinDownEnabled;return Ext.form.field.Text.prototype.applyTriggers.call(this,b)},onRender:function(){var a=this,b=a.getTrigger('spinner');(arguments.callee.$previous||Ext.form.field.Text.prototype.onRender).call(this);if(a.keyNavEnabled){a.spinnerKeyNav=new Ext.util.KeyNav(a.inputEl,{scope:a,up:a.spinUp,down:a.spinDown})}if(a.mouseWheelEnabled){a.mon(a.bodyEl,'mousewheel',a.onMouseWheel,a)}a.spinUpEl=b.upEl;a.spinDownEl=b.downEl},onSpinnerUpClick:function(){this.spinUp()},onSpinnerDownClick:function(){this.spinDown()},spinUp:function(){var a=this;if(a.spinUpEnabled&&!a.disabled){a.fireEvent('spin',a,'up');a.fireEvent('spinup',a);a.onSpinUp()}},spinDown:function(){var a=this;if(a.spinDownEnabled&&!a.disabled){a.fireEvent('spin',a,'down');a.fireEvent('spindown',a);a.onSpinDown()}},setSpinUpEnabled:function(b){var a=this,c=a.spinUpEnabled;a.spinUpEnabled=b;if(c!==b&&a.rendered){a.getTrigger('spinner').setUpEnabled(b)}},setSpinDownEnabled:function(b){var a=this,c=a.spinDownEnabled;a.spinDownEnabled=b;if(c!==b&&a.rendered){a.getTrigger('spinner').setDownEnabled(b)}},onMouseWheel:function(c){var b=this,a;if(b.hasFocus){a=c.getWheelDelta();if(a>0){b.spinUp()}else {if(a<0){b.spinDown()}}c.stopEvent()}},onDestroy:function(){Ext.destroyMembers(this,'spinnerKeyNav');Ext.form.field.Text.prototype.onDestroy.call(this)}},0,['spinnerfield'],['component','box','field','textfield','spinnerfield'],{'component':!0,'box':!0,'field':!0,'textfield':!0,'spinnerfield':!0},['widget.spinnerfield'],0,[Ext.form.field,'Spinner',Ext.form,'Spinner'],0);Ext.cmd.derive('Ext.form.field.Number',Ext.form.field.Spinner,{alternateClassName:['Ext.form.NumberField','Ext.form.Number'],allowExponential:!0,allowDecimals:!0,decimalSeparator:null,submitLocaleSeparator:!0,decimalPrecision:2,minValue:Number.NEGATIVE_INFINITY,maxValue:Number.MAX_VALUE,step:1,minText:'The minimum value for this field is {0}',maxText:'The maximum value for this field is {0}',nanText:'{0} is not a valid number',negativeText:'The value cannot be negative',baseChars:'0123456789',autoStripChars:!1,initComponent:function(){var a=this;if(a.decimalSeparator===null){a.decimalSeparator=Ext.util.Format.decimalSeparator}Ext.form.field.Spinner.prototype.initComponent.call(this);a.setMinValue(a.minValue);a.setMaxValue(a.maxValue)},getSubTplData:function(g){var f=this,e=f.minValue,d=f.maxValue,c,a,b;c=Ext.form.field.Spinner.prototype.getSubTplData.call(this,g);a=c.inputElAriaAttributes;if(a){if(e>Number.NEGATIVE_INFINITY){a['aria-valuemin']=e}if(d=e&&b<=d){a['aria-valuenow']=b}}return c},setValue:function(d){var a=this,c,b;if(a.hasFocus){c=a.getBind();b=c&&c.value;if(b&&b.syncing&&d===a.value){return a}}return Ext.form.field.Spinner.prototype.setValue.call(this,d)},getErrors:function(b){b=arguments.length>0?b:this.processRawValue(this.getRawValue());var a=this,c=Ext.form.field.Spinner.prototype.getErrors.call(this,b),e=Ext.String.format,d;if(b.length<1){return c}b=String(b).replace(a.decimalSeparator,'.');if(isNaN(b)){c.push(e(a.nanText,b))}d=a.parseValue(b);if(a.minValue===0&&d<0){c.push(this.negativeText)}else {if(da.maxValue){c.push(e(a.maxText,a.maxValue))}return c},rawToValue:function(b){var a=this.fixPrecision(this.parseValue(b));if(a===null){a=b||null}return a},valueToRaw:function(a){var b=this,c=b.decimalSeparator;a=b.parseValue(a);a=b.fixPrecision(a);a=Ext.isNumber(a)?a:parseFloat(String(a).replace(c,'.'));a=isNaN(a)?'':String(a).replace('.',c);return a},getSubmitValue:function(){var b=this,a=Ext.form.field.Spinner.prototype.getSubmitValue.call(this);if(!b.submitLocaleSeparator){a=a.replace(b.decimalSeparator,'.')}return a},onChange:function(a){var b=this.ariaEl.dom;this.toggleSpinners();Ext.form.field.Spinner.prototype.onChange.apply(this,arguments);if(b){if(Ext.isNumber(a)&&isFinite(a)){b.setAttribute('aria-valuenow',a)}else {b.removeAttribute('aria-valuenow')}}},toggleSpinners:function(){var a=this,c=a.getValue(),d=c===null,b;if(a.spinUpEnabled||a.spinUpDisabledByToggle){b=d||ca.minValue;a.setSpinDownEnabled(b,!0)}},setMinValue:function(e){var a=this,c=a.ariaEl.dom,d,b,c;a.minValue=d=Ext.Number.from(e,Number.NEGATIVE_INFINITY);a.toggleSpinners();if(c){if(d>Number.NEGATIVE_INFINITY){c.setAttribute('aria-valuemin',d)}else {c.removeAttribute('aria-valuemin')}}if(a.disableKeyFilter!==!0){b=a.baseChars+'';if(a.allowExponential){b+=a.decimalSeparator+'e+-'}else {if(a.allowDecimals){b+=a.decimalSeparator}if(a.minValue<0){b+='-'}}b=Ext.String.escapeRegex(b);a.maskRe=new RegExp('['+b+']');if(a.autoStripChars){a.stripCharsRe=new RegExp('[^'+b+']','gi')}}},setMaxValue:function(c){var b=this.ariaEl.dom,a;this.maxValue=a=Ext.Number.from(c,Number.MAX_VALUE);if(b){if(aa.maxLength){return}}a.setValue(b)}},0,['numberfield'],['component','box','field','textfield','spinnerfield','numberfield'],{'component':!0,'box':!0,'field':!0,'textfield':!0,'spinnerfield':!0,'numberfield':!0},['widget.numberfield'],0,[Ext.form.field,'Number',Ext.form,'NumberField',Ext.form,'Number'],0);Ext.cmd.derive('Ext.toolbar.Paging',Ext.toolbar.Toolbar,{alternateClassName:'Ext.PagingToolbar',displayInfo:!1,prependButtons:!1,displayMsg:'Displaying {0} - {1} of {2}',emptyMsg:'No data to display',beforePageText:'Page',afterPageText:'of {0}',firstText:'First Page',prevText:'Previous Page',nextText:'Next Page',lastText:'Last Page',refreshText:'Refresh',inputItemWidth:30,emptyPageData:{total:0,currentPage:0,pageCount:0,toRecord:0,fromRecord:0},defaultBindProperty:'store',getPagingItems:function(){var a=this,b={scope:a,blur:a.onPagingBlur};b[Ext.supports.SpecialKeyDownRepeat?'keydown':'keypress']=a.onPagingKeyDown;return [{itemId:'first',tooltip:a.firstText,overflowText:a.firstText,iconCls:'x-tbar-page-first',disabled:!0,handler:a.moveFirst,scope:a},{itemId:'prev',tooltip:a.prevText,overflowText:a.prevText,iconCls:'x-tbar-page-prev',disabled:!0,handler:a.movePrevious,scope:a},'-',a.beforePageText,{xtype:'numberfield',itemId:'inputItem',name:'inputItem',cls:'x-tbar-page-number',allowDecimals:!1,minValue:1,hideTrigger:!0,enableKeyEvents:!0,keyNavEnabled:!1,selectOnFocus:!0,submitValue:!1,isFormField:!1,width:a.inputItemWidth,margin:'-1 2 3 2',listeners:b},{xtype:'tbtext',itemId:'afterTextItem',html:Ext.String.format(a.afterPageText,1)},'-',{itemId:'next',tooltip:a.nextText,overflowText:a.nextText,iconCls:'x-tbar-page-next',disabled:!0,handler:a.moveNext,scope:a},{itemId:'last',tooltip:a.lastText,overflowText:a.lastText,iconCls:'x-tbar-page-last',disabled:!0,handler:a.moveLast,scope:a},'-',{itemId:'refresh',tooltip:a.refreshText,overflowText:a.refreshText,iconCls:'x-tbar-loading',disabled:a.store.isLoading(),handler:a.doRefresh,scope:a}]},initComponent:function(){var a=this,c=a.items||a.buttons||[],b;a.bindStore(a.store||'ext-empty-store',!0);b=a.getPagingItems();if(a.prependButtons){a.items=c.concat(b)}else {a.items=b.concat(c)}delete a.buttons;if(a.displayInfo){a.items.push('->');a.items.push({xtype:'tbtext',itemId:'displayItem'})}Ext.toolbar.Toolbar.prototype.initComponent.call(this)},beforeRender:function(){Ext.toolbar.Toolbar.prototype.beforeRender.apply(this,arguments);this.updateBarInfo()},updateBarInfo:function(){var a=this;if(!a.store.isLoading()){a.calledInternal=!0;a.onLoad();a.calledInternal=!1}},updateInfo:function(){var a=this,d=a.child('#displayItem'),f=a.store,b=a.getPageData(),e,c;if(d){e=f.getCount();if(e===0){c=a.emptyMsg}else {c=Ext.String.format(a.displayMsg,b.fromRecord,b.toRecord,b.total)}d.setText(c)}},onLoad:function(){var a=this,f,c,b,g,h,d,e;h=a.store.getCount();d=h===0;if(!d){f=a.getPageData();c=f.currentPage;b=f.pageCount;if(c>b){if(b>0){a.store.loadPage(b)}else {a.getInputItem().reset()}return}g=Ext.String.format(a.afterPageText,isNaN(b)?1:b)}else {c=0;b=0;g=Ext.String.format(a.afterPageText,0)}Ext.suspendLayouts();e=a.child('#afterTextItem');if(e){e.update(g)}e=a.getInputItem();if(e){e.setDisabled(d).setValue(c)}a.setChildDisabled('#first',c===1||d);a.setChildDisabled('#prev',c===1||d);a.setChildDisabled('#next',c===b||d);a.setChildDisabled('#last',c===b||d);a.setChildDisabled('#refresh',!1);a.updateInfo();Ext.resumeLayouts(!0);if(!a.calledInternal){a.fireEvent('change',a,f||a.emptyPageData)}},setChildDisabled:function(c,b){var a=this.child(c);if(a){a.setDisabled(b)}},getPageData:function(){var a=this.store,b=a.getTotalCount();return {total:b,currentPage:a.currentPage,pageCount:Math.ceil(b/a.pageSize),fromRecord:(a.currentPage-1)*a.pageSize+1,toRecord:Math.min(a.currentPage*a.pageSize,b)}},onLoadError:function(){this.setChildDisabled('#refresh',!1)},getInputItem:function(){return this.child('#inputItem')},readPageFromInput:function(d){var a=this.getInputItem(),b=!1,c;if(a){c=a.getValue();b=parseInt(c,10);if(!c||isNaN(b)){a.setValue(d.currentPage);return !1}}return b},onPagingBlur:function(c){var a=this.getInputItem(),b;if(a){b=this.getPageData().currentPage;a.setValue(b)}},onPagingKeyDown:function(a,b){this.processKeyEvent(a,b)},processKeyEvent:function(g,b){var e=this,c=b.getKey(),d=e.getPageData(),f=b.shiftKey?10:1,a;if(c===b.RETURN){b.stopEvent();a=e.readPageFromInput(d);if(a!==!1){a=Math.min(Math.max(1,a),d.pageCount);if(a!==d.currentPage&&e.fireEvent('beforechange',e,a)!==!1){e.store.loadPage(a)}}}else {if(c===b.HOME||c===b.END){b.stopEvent();a=c===b.HOME?1:d.pageCount;g.setValue(a)}else {if(c===b.UP||c===b.PAGE_UP||c===b.DOWN||c===b.PAGE_DOWN){b.stopEvent();a=e.readPageFromInput(d);if(a){if(c===b.DOWN||c===b.PAGE_DOWN){f*=-1}a+=f;if(a>=1&&a<=d.pageCount){g.setValue(a)}}}}}},beforeLoad:function(){this.setChildDisabled('#refresh',!0)},moveFirst:function(){if(this.fireEvent('beforechange',this,1)!==!1){this.store.loadPage(1);return !0}return !1},movePrevious:function(){var a=this,b=a.store,c=b.currentPage-1;if(c>0){if(a.fireEvent('beforechange',a,c)!==!1){b.previousPage();return !0}}return !1},moveNext:function(){var a=this,b=a.store,d=a.getPageData().pageCount,c=b.currentPage+1;if(c<=d){if(a.fireEvent('beforechange',a,c)!==!1){b.nextPage();return !0}}return !1},moveLast:function(){var a=this,b=a.getPageData().pageCount;if(a.fireEvent('beforechange',a,b)!==!1){a.store.loadPage(b);return !0}return !1},doRefresh:function(){var a=this,c=a.store,b=c.currentPage;if(a.fireEvent('beforechange',a,b)!==!1){c.loadPage(b);return !0}return !1},getStoreListeners:function(){return {beforeload:this.beforeLoad,load:this.onLoad,exception:this.onLoadError}},onBindStore:function(){if(this.rendered){this.updateBarInfo()}},onDestroy:function(){this.bindStore(null);Ext.toolbar.Toolbar.prototype.onDestroy.call(this)}},0,['pagingtoolbar'],['component','box','container','toolbar','pagingtoolbar'],{'component':!0,'box':!0,'container':!0,'toolbar':!0,'pagingtoolbar':!0},['widget.pagingtoolbar'],[[Ext.util.StoreHolder.prototype.mixinId||Ext.util.StoreHolder.$className,Ext.util.StoreHolder]],[Ext.toolbar,'Paging',Ext,'PagingToolbar'],0);Ext.define('Ext.theme.neptune.toolbar.Paging',{override:'Ext.toolbar.Paging',defaultButtonUI:'plain-toolbar',inputItemWidth:40});Ext.cmd.derive('Ext.view.BoundList',Ext.view.View,{alternateClassName:'Ext.BoundList',pageSize:0,baseCls:'x-boundlist',itemCls:'x-boundlist-item',listItemCls:'',shadow:!1,trackOver:!0,preserveScrollOnRefresh:!0,enableInitialSelection:!1,refreshSelmodelOnRefresh:!0,componentLayout:'boundlist',navigationModel:'boundlist',scrollable:!0,ariaEl:'listEl',tabIndex:-1,childEls:['listWrap','listEl'],renderTpl:['
    ','
      {$}="{.}"','>','
    ','
    ','{%','var pagingToolbar=values.$comp.pagingToolbar;','if (pagingToolbar) {','Ext.DomHelper.generateMarkup(pagingToolbar.getRenderTree(), out);','}','%}',{disableFormats:!0}],focusOnToFront:!1,initComponent:function(){var a=this,b=a.baseCls,c=a.itemCls;a.selectedItemCls=b+'-selected';if(a.trackOver){a.overItemCls=b+'-item-over'}a.itemSelector='.'+c;a.scrollerSelector='ul.x-list-plain';if(a.floating){a.addCls(b+'-floating')}if(!a.tpl){a.tpl=new Ext.XTemplate('','
  • '+a.getInnerTpl(a.displayField)+'
  • ','
    ')}else {if(!a.tpl.isTemplate){a.tpl=new Ext.XTemplate(a.tpl)}}if(a.pageSize){a.pagingToolbar=a.createPagingToolbar()}Ext.view.View.prototype.initComponent.call(this)},getRefOwner:function(){return this.pickerField||Ext.view.View.prototype.getRefOwner.call(this)},getRefItems:function(){var b=Ext.view.View.prototype.getRefItems.call(this),a=this.pagingToolbar;if(a){b.push(a)}return b},createPagingToolbar:function(){return Ext.widget('pagingtoolbar',{id:this.id+'-paging-toolbar',pageSize:this.pageSize,store:this.dataSource,border:!1,ownerCt:this,ownerLayout:this.getComponentLayout()})},getNodeContainer:function(){return this.listEl},refresh:function(){var b=this,a=b.tpl;a.field=b.pickerField;a.store=b.store;Ext.view.View.prototype.refresh.call(this);a.field=a.store=null},bindStore:function(c,b){var a=this.pagingToolbar;Ext.view.View.prototype.bindStore.apply(this,arguments);if(a){a.bindStore(c,b)}},getInnerTpl:function(a){return '{'+a+'}'},onShow:function(){var a=this.pickerField;Ext.view.View.prototype.onShow.call(this);if(a&&a.rendered&&!a.hasFocus){a.focus()}},afterComponentLayout:function(e,d,c,b){var a=this.pickerField;Ext.view.View.prototype.afterComponentLayout.call(this,e,d,c,b);if(a&&a.alignPicker){a.alignPicker()}},onItemClick:function(e){var d=this,b=d.pickerField,c,a;if(!b){return}c=b.valueField;a=d.getSelectionModel().getSelection();if(!b.multiSelect&&a.length){a=a[0];if(a&&b.isEqual(e.get(c),a.get(c))&&b.collapse){b.collapse()}}},onContainerClick:function(b){var a=this.pagingToolbar;if(a&&a.rendered&&b.within(a.el)){return !1}},onDestroy:function(){Ext.view.View.prototype.onDestroy.call(this);Ext.destroyMembers(this,'pagingToolbar','listWrap','listEl')},privates:{getTargetEl:function(){return this.listEl},getOverflowEl:function(){return this.listWrap},finishRenderChildren:function(){var a=this.pagingToolbar;Ext.view.View.prototype.finishRenderChildren.apply(this,arguments);if(a){a.finishRender()}}}},0,['boundlist'],['component','box','dataview','boundlist'],{'component':!0,'box':!0,'dataview':!0,'boundlist':!0},['widget.boundlist'],[[Ext.mixin.Queryable.prototype.mixinId||Ext.mixin.Queryable.$className,Ext.mixin.Queryable]],[Ext.view,'BoundList',Ext,'BoundList'],0);Ext.cmd.derive('Ext.form.field.ComboBox',Ext.form.field.Picker,{alternateClassName:'Ext.form.ComboBox',config:{filters:null,selection:null,valueNotFoundText:null,displayTpl:!1,delimiter:', ',displayField:'text'},publishes:['selection'],twoWayBindable:['selection'],triggerCls:'x-form-arrow-trigger',hiddenName:'',collapseOnSelect:!1,hiddenDataCls:'x-hidden-display x-form-data-hidden',ariaRole:'combobox',childEls:{'hiddenDataEl':!0},filtered:!1,afterRender:function(){var a=this;Ext.form.field.Picker.prototype.afterRender.apply(this,arguments);a.setHiddenValue(a.value)},multiSelect:!1,triggerAction:'all',allQuery:'',queryParam:'query',queryMode:'remote',queryCaching:!0,autoLoadOnValue:!1,pageSize:0,anyMatch:!1,caseSensitive:!1,autoSelect:!0,typeAhead:!1,typeAheadDelay:250,selectOnTab:!0,forceSelection:!1,growToLongestValue:!0,clearFilterOnBlur:!0,defaultListConfig:{loadingHeight:70,minWidth:70,maxHeight:300,shadow:'sides'},transformInPlace:!0,clearValueOnEmpty:!0,getGrowWidth:function(){var a=this,i=a.inputEl.dom.value,h,e,g,c,b,f,d;if(a.growToLongestValue){h=a.displayField;e=a.store;g=e.data.length;c=0;for(b=0;bc){c=d;i=f}}}return i},initComponent:function(){var a=this,d=Ext.isDefined,f=a.store,e=a.transform,b,c;if('pinList' in a){a.collapseOnSelect=!a.pinList}if(e){b=Ext.getDom(e);if(b){if(!a.store){f=Ext.Array.map(Ext.Array.from(b.options),function(a){return [a.value,a.text]})}if(!a.name){a.name=b.name}if(!('value' in a)){a.value=b.value}}}a.bindStore(f||'ext-empty-store',!0,!0);c=a.queryMode==='local';if(!d(a.queryDelay)){a.queryDelay=c?10:500}if(!d(a.minChars)){a.minChars=c?0:4}Ext.form.field.Picker.prototype.initComponent.call(this);a.doQueryTask=new Ext.util.DelayedTask(a.doRawQuery,a);if(b){if(a.transformInPlace){a.render(b.parentNode,b);delete a.renderTo}Ext.removeNode(b)}},getSubTplData:function(c){var b,a;b=Ext.form.field.Picker.prototype.getSubTplData.call(this,c);a=b.inputElAriaAttributes;if(a){a['aria-autocomplete']='list'}return b},getSubTplMarkup:function(c){var b=this,a='',d=Ext.form.field.Picker.prototype.getSubTplMarkup.apply(this,arguments);if(b.hiddenName){a=''}return a+d},applyDisplayTpl:function(a){var b=this;if(!a){a=new Ext.XTemplate('{[typeof values === "string" ? values : values["'+b.getDisplayField()+'"]]}'+b.getDelimiter()+'');a.auto=!0}else {if(!a.isTemplate){a=new Ext.XTemplate(a)}}return a},applyFilters:function(b,a){var c=this;if(b===null||b.isFilterCollection){return b}if(b){if(!a){a=this.getFilters()}a.beginUpdate();a.splice(0,a.length,b);a.each(function(d){d.ownerId=c.id});a.endUpdate()}return a},applyValueNotFoundText:function(b){var a=this,c=a.valueNotFoundRecord||(a.valueNotFoundRecord=new Ext.data.Model());c.set(a.displayField,b);if(a.valueField&&a.displayField!==a.valueField){c.set(a.valueField,b)}return b},getFilters:function(b){var a=this.filters;if(!a&&b!==!1){a=new Ext.util.FilterCollection();this.setFilters(a)}return a},updateFilters:function(a,c){var b=this;if(c){c.un('endupdate','onEndUpdateFilters',b)}if(a){a.on('endupdate','onEndUpdateFilters',b)}b.onEndUpdateFilters(a)},onEndUpdateFilters:function(a){var b=this,f=b.filtered,e=!!a&&a.length>0,d,c;if(f||e){b.filtered=e;d=[];c=b.store.getFilters();c.each(function(c){if(c.ownerId===b.id&&!a.contains(c)){d.push(c)}});c.splice(0,d,a.items)}},completeEdit:function(c){var a=this,b=a.queryFilter;Ext.form.field.Picker.prototype.completeEdit.call(this,c);a.doQueryTask.cancel();a.assertValue();if(b&&a.queryMode==='local'&&a.clearFilterOnBlur){a.getStore().getFilters().remove(b)}},onFocus:function(b){var a=this;Ext.form.field.Picker.prototype.onFocus.call(this,b);if(a.triggerAction!=='all'&&a.queryFilter&&a.queryMode==='local'&&a.clearFilterOnBlur){delete a.lastQuery;a.doRawQuery()}},assertValue:function(){var a=this,e=a.getRawValue(),c=a.getDisplayValue(),d=a.lastSelectedRecords,b;if(a.forceSelection){if(a.multiSelect){if(e!==c){a.setRawValue(c)}}else {b=a.findRecordByDisplay(e);if(b){if(a.getDisplayValue([a.getRecordDisplayData(b)])!==c){a.select(b,!0)}}else {if(d&&(!a.allowBlank||a.rawValue)){a.setValue(d)}else {if(d){delete a.lastSelectedRecords}a.setRawValue('')}}}}a.collapse()},onTypeAhead:function(){var a=this,e=a.displayField,d=a.store.findRecord(e,a.getRawValue()),f=a.getPicker(),b,g,c;if(d){b=d.get(e);g=b.length;c=a.getRawValue().length;f.highlightItem(f.getNode(d));if(c!==0&&c!==g){a.setRawValue(b);a.selectText(c,b.length)}}},resetToDefault:Ext.emptyFn,beforeReset:function(){var a=this.queryFilter;Ext.form.field.Picker.prototype.beforeReset.call(this);if(a){this.getStore().getFilters().remove(a)}},onUnbindStore:function(){var a=this,c=a.picker,b=a.queryFilter;if(b&&!a.store.destroyed){a.changingFilters=!0;a.getStore().removeFilter(b,!0);a.changingFilters=!1}a.pickerSelectionModel.destroy();if(c){c.bindStore(null)}},onBindStore:function(b,f){var a=this,d=a.picker,c,e;if(b){if(b.autoCreated){a.queryMode='local';a.valueField=a.displayField='field1';if(!b.expanded){a.displayField='field2'}if(a.getDisplayTpl().auto){a.setDisplayTpl(null)}}if(!Ext.isDefined(a.valueField)){a.valueField=a.displayField}c={byValue:{rootProperty:'data',unique:!1}};c.byValue.property=a.valueField;b.setExtraKeys(c);if(a.displayField===a.valueField){b.byText=b.byValue}else {c.byText={rootProperty:'data',unique:!1};c.byText.property=a.displayField;b.setExtraKeys(c)}e={rootProperty:'data',extraKeys:{byInternalId:{property:'internalId'},byValue:{property:a.valueField,rootProperty:'data'}},listeners:{beginupdate:a.onValueCollectionBeginUpdate,endupdate:a.onValueCollectionEndUpdate,scope:a}};a.valueCollection=new Ext.util.Collection(e);a.pickerSelectionModel=new Ext.selection.DataViewModel({mode:a.multiSelect?'SIMPLE':'SINGLE',deselectOnContainerClick:!1,enableInitialSelection:!1,pruneRemoved:!1,selected:a.valueCollection,store:b,listeners:{scope:a,lastselectedchanged:a.updateBindSelection}});if(!f){a.resetToDefault()}if(d){d.setSelectionModel(a.pickerSelectionModel);if(d.getStore()!==b){d.bindStore(b)}}}},bindStore:function(a,e,c){var b=this,d=b.queryFilter;b.mixins.storeholder.bindStore.call(b,a,c);a=b.getStore();if(a&&d&&!e){a.getFilters().add(d)}if(!c&&a&&!a.isEmptyStore){b.setValueOnData()}},getStoreListeners:function(c){if(!c.isEmptyStore){var a=this,b={datachanged:a.onDataChanged,load:a.onLoad,exception:a.onException,update:a.onStoreUpdate,remove:a.checkValueOnChange};if(!c.getRemoteFilter()){b.filterchange=a.checkValueOnChange}return b}},onDataChanged:function(){if(this.grow&&this.growToLongestValue){this.autoSize()}},checkValueOnChange:function(){var a=this;if(!a.destroying&&a.getStore().isLoaded()){if(a.multiSelect){}else {if(a.forceSelection&&!a.changingFilters&&!a.findRecordByValue(a.value)){a.setValue(null)}}}},onStoreUpdate:function(b,a){this.updateValue()},onException:function(){this.collapse()},onLoad:function(b,e,d){var a=this,c=!a.valueCollection.byValue.get(a.value);if(d&&c&&!(b.lastOptions&&'rawQuery' in b.lastOptions)){a.setValueOnData()}a.checkValueOnChange()},setValueOnData:function(){var a=this;a.setValue(a.value);if(a.isExpanded&&a.getStore().getCount()){a.doAutoSelect()}},doRawQuery:function(){var a=this,b=a.inputEl.dom.value;if(a.multiSelect){b=b.split(a.delimiter).pop()}a.doQuery(b,!1,!0)},doQuery:function(c,f,g){var a=this,d=a.getStore(),e=d.filters&&!d.filters.length&&!!c,b=a.beforeQuery({query:c||'',rawQuery:g,forceAll:f,combo:a,cancel:!1});if(b!==!1&&!b.cancel){if(a.queryCaching&&!e&&b.query===a.lastQuery){a.getPicker().refresh();a.expand()}else {a.lastQuery=b.query;if(a.queryMode==='local'){a.doLocalQuery(b)}else {a.doRemoteQuery(b)}}}return !0},beforeQuery:function(a){var b=this;if(b.fireEvent('beforequery',a)===!1){a.cancel=!0}else {if(!a.cancel){if(a.query.length0){a=b.picker.getSelectionModel();if(a.lastSelected&&a.selected.length){c=a.lastSelected}d.getNavigationModel().setPosition(c)}},doTypeAhead:function(){var a=this,b=Ext.event.Event;if(!a.typeAheadTask){a.typeAheadTask=new Ext.util.DelayedTask(a.onTypeAhead,a)}if(a.lastKey!==b.BACKSPACE&&a.lastKey!==b.DELETE){a.typeAheadTask.delay(a.typeAheadDelay)}},onTriggerClick:function(){var a=this;if(!a.readOnly&&!a.disabled){if(a.isExpanded){a.collapse()}else {if(a.triggerAction==='all'){a.doQuery(a.allQuery,!0)}else {if(a.triggerAction==='last'){a.doQuery(a.lastQuery,!0)}else {a.doQuery(a.getRawValue(),!1,!0)}}}}},onFieldMutation:function(b){var a=this,c=b.getKey(),d=c===b.BACKSPACE||c===b.DELETE,e=a.inputEl.dom.value,f=e.length;if(!a.readOnly&&(e!==a.lastMutatedValue||d)&&c!==b.TAB){a.lastMutatedValue=e;a.lastKey=c;if(f&&(b.type!=='keyup'||(!b.isSpecialKey()||d))){a.doQueryTask.delay(a.queryDelay)}else {if(!f&&(!c||d)){++a.suspendCheckChange;if(!a.multiSelect){a.value=null;a.displayTplData=undefined}if(a.clearValueOnEmpty){a.valueCollection.beginUpdate();a.pickerSelectionModel.deselectAll();a.valueCollection.removeAll();a.valueCollection.endUpdate()}a.collapse();if(a.queryFilter){a.changingFilters=!0;a.store.removeFilter(a.queryFilter,!0);a.changingFilters=!1}--a.suspendCheckChange}Ext.form.field.Picker.prototype.onFieldMutation.call(this,b)}}},onDestroy:function(){var a=this;a.doQueryTask.cancel();if(a.typeAheadTask){a.typeAheadTask.cancel();a.typeAheadTask=null}a.bindStore(null);a.valueCollection=Ext.destroy(a.valueCollection);Ext.form.field.Picker.prototype.onDestroy.call(this)},onAdded:function(){var a=this;Ext.form.field.Picker.prototype.onAdded.apply(this,arguments);if(a.picker){a.picker.ownerCt=a.up('[floating]');a.picker.registerWithOwnerCt()}},createPicker:function(){var a=this,b,c=Ext.apply({xtype:'boundlist',id:a.pickerId,pickerField:a,selectionModel:a.pickerSelectionModel,floating:!0,hidden:!0,store:a.getPickerStore(),displayField:a.displayField,preserveScrollOnRefresh:!0,pageSize:a.pageSize,tpl:a.tpl},a.listConfig,a.defaultListConfig);b=a.picker=Ext.widget(c);if(a.pageSize){b.pagingToolbar.on('beforechange',a.onPageChange,a)}if(!b.initialConfig.maxHeight){b.on({beforeshow:a.onBeforePickerShow,scope:a})}b.getSelectionModel().on({beforeselect:a.onBeforeSelect,beforedeselect:a.onBeforeDeselect,focuschange:a.onFocusChange,scope:a});b.getNavigationModel().navigateOnSpace=!1;return b},getPickerStore:function(){return this.store},onBeforePickerShow:function(d){var b=this,a=b.getPosition()[1]-Ext.getBody().getScroll().top,c=Ext.Element.getViewportHeight()-a-b.getHeight();d.maxHeight=Math.max(a,c)-5},onBeforeSelect:function(c,b,a){return this.fireEvent('beforeselect',this,b,a)},onBeforeDeselect:function(c,b,a){return this.fireEvent('beforedeselect',this,b,a)},onFocusChange:function(e,d,b){var c=this.picker,a;if(b){a=Ext.get(c.getNodeByRecord(b));if(a){this.ariaEl.dom.setAttribute('aria-activedescendant',a.id)}}},getSelection:function(){var a=this.getPicker().getSelectionModel(),b=a.getSelection();return b.length?a.getLastSelected():null},updateSelection:function(c){var a=this,b;if(!a.ignoreNextSelection){a.ignoreNextSelection=!0;b=a.getPicker().getSelectionModel();if(c){b.select(c);a.hasHadSelection=!0}else {b.deselectAll()}a.ignoreNextSelection=!1}},updateBindSelection:function(d,c){var a=this,b=null;if(!a.ignoreNextSelection){a.ignoreNextSelection=!0;if(c.length){b=d.getLastSelected();a.hasHadSelection=!0}if(a.hasHadSelection){a.setSelection(b)}a.ignoreNextSelection=!1}},onValueCollectionBeginUpdate:Ext.emptyFn,onValueCollectionEndUpdate:function(){var a=this,e=a.store,b=a.valueCollection.getRange(),d=b[0],c=b.length;a.updateBindSelection(a.pickerSelectionModel,b);if(a.isSelectionUpdating()){return}Ext.suspendLayouts();a.lastSelection=b;if(c){a.lastSelectedRecords=b}a.updateValue();if(c&&(!a.multiSelect&&e.contains(d)||a.collapseOnSelect||!e.getCount())){a.updatingValue=!0;a.collapse();a.updatingValue=!1}Ext.resumeLayouts(!0);if(c&&!a.suspendCheckChange){if(!a.multiSelect){b=d}a.fireEvent('select',a,b)}},isSelectionUpdating:function(){var a=this.pickerSelectionModel;return a.deselectingDuringSelect||a.refreshing},onExpand:function(){var a=this.getPicker().getNavigationModel();if(a){a.enable()}this.doAutoSelect()},onCollapse:function(){var a=this.getPicker().getNavigationModel();if(a){a.disable()}if(this.updatingValue){this.doQueryTask.cancel()}},select:function(b,e){var a=this,d=a.picker,c;if(b&&b.isModel&&e===!0&&d){c=!d.getSelectionModel().isSelected(b)}if(!c){a.suspendEvent('select')}a.setValue(b);a.resumeEvent('select')},findRecord:function(c,d){var b=this.store,a=b.findExact(c,d);return a!==-1?b.getAt(a):!1},getSelectedRecord:function(){return this.findRecordByValue(this.value)||null},findRecordByValue:function(c){var a=this.store.byValue.get(c),b=!1;if(a){b=a[0]||a}return b},findRecordByDisplay:function(c){var a=this.store.byText.get(c),b=!1;if(a){b=a[0]||a}return b},addValue:function(a){if(a!=null){return this.doSetValue(a,!0)}},setValue:function(b){var a=this;if(b!=null){return a.doSetValue(b)}else {a.suspendEvent('select');a.valueCollection.beginUpdate();a.pickerSelectionModel.deselectAll();a.valueCollection.endUpdate();a.lastSelectedRecords=null;a.resumeEvent('select')}},setRawValue:function(a){Ext.form.field.Picker.prototype.setRawValue.call(this,a);this.lastMutatedValue=a},doSetValue:function(c,p){var a=this,f=a.getStore(),v=f.getModel(),e=[],u=[],r=a.autoLoadOnValue,m=f.getCount()>0||f.isLoaded(),l=f.hasPendingLoad(),o=r&&!m&&!l,t=a.forceSelection,n=a.pickerSelectionModel,s=a.displayField===a.valueField,j=f.isEmptyStore,k=a.lastSelection,d,h,b,i,g,q;if(l||o||!m||j){if(!c.isModel){if(p){a.value=Ext.Array.from(a.value).concat(c)}else {a.value=c}a.setHiddenValue(a.value);a.setRawValue(s?c:'')}if(o&&!j){f.load()}if(!c.isModel||j){return a}}c=p?Ext.Array.from(a.value).concat(c):Ext.Array.from(c);for(d=0,h=c.length;d0){h.hiddenDataEl.setHtml(Ext.DomHelper.markup({tag:'input',type:'hidden',name:i}));a=1;g=d.firstChild}while(a>c){d.removeChild(b[0]);--a}while(am){if(a.anchorToTarget){a.defaultAlign='r-l';if(a.mouseOffset){a.mouseOffset[0]*=-1}}a.anchor='right';return a.getTargetXY()}if(b[1]l){if(a.anchorToTarget){a.defaultAlign='b-t';if(a.mouseOffset){a.mouseOffset[1]*=-1}}a.anchor='bottom';return a.getTargetXY()}}a.anchorCls='x-tip-anchor-'+a.getAnchorPosition();a.anchorEl.addCls(a.anchorCls);a.targetCounter=0;return b}else {c=a.getMouseOffset();return a.targetXY?[a.targetXY[0]+c[0],a.targetXY[1]+c[1]]:c}},calculateConstrainedPosition:function(e){var a=this,d,b,c;if(!e&&a.isContainedFloater()){d=a.isVisible();if(!d){a.el.show()}b=a.getTargetXY();if(!d){a.el.hide()}c=a.floatParent.getTargetEl().getViewRegion();b[0]-=c.left;b[1]-=c.top}else {b=a.callOverridden(arguments)}return b},getMouseOffset:function(){var a=this,b=a.anchor?[0,0]:[15,18];if(a.mouseOffset){b[0]+=a.mouseOffset[0];b[1]+=a.mouseOffset[1]}return b},fadeOut:function(){var a=this;a.el.fadeOut({duration:a.fadeOutDuration,callback:function(){a.hide();a.el.setOpacity('')}})},getAnchorPosition:function(){var a=this,b;if(a.anchor){a.tipAnchor=a.anchor.charAt(0)}else {b=a.defaultAlign.match(/^([a-z]+)-([a-z]+)(\?)?$/);a.tipAnchor=b[1].charAt(0)}switch(a.tipAnchor){case 't':return 'top';case 'b':return 'bottom';case 'r':return 'right';}return 'left'},getAnchorAlign:function(){switch(this.anchor){case 'top':return 'tl-bl';case 'left':return 'tl-tr';case 'right':return 'tr-tl';default:return 'bl-tl';}},getOffsets:function(){var b=this,c,a,d=b.getAnchorPosition().charAt(0);if(b.anchorToTarget&&!b.trackMouse){switch(d){case 't':a=[0,9];break;case 'b':a=[0,-13];break;case 'r':a=[-13,0];break;default:a=[9,0];break;}}else {switch(d){case 't':a=[-15-b.anchorOffset,30];break;case 'b':a=[-19-b.anchorOffset,-13-b.el.dom.offsetHeight];break;case 'r':a=[-15-b.el.dom.offsetWidth,-13-b.anchorOffset];break;default:a=[25,-13-b.anchorOffset];break;}}c=b.getMouseOffset();a[0]+=c[0];a[1]+=c[1];return a},onTargetOver:function(b){var a=this,d=a.delegate,c;if(a.disabled||b.within(a.target.dom,!0)){return}c=d?b.getTarget(d):!0;if(c){a.triggerElement=c;a.triggerEvent=b;a.clearTimer('hide');a.targetXY=b.getXY();a.delayShow()}},delayShow:function(c){var a=this,b=a.el&&(c===!1||!a.trackMouse)&&a.getTargetXY();if(a.hidden&&!a.showTimer){if(Ext.Date.getElapsed(a.lastActive)=b.length){a.colIdx=0}else {a.colIdx++}a.setColumn(a.colIdx)}while(!a.getCell(!0));break;}}},statics:{compare:function(a,b){return a.rowIdx-b.rowIdx||a.colIdx-b.colIdx}}},1,0,0,0,0,0,[Ext.grid,'CellContext'],0);Ext.cmd.derive('Ext.grid.ColumnComponentLayout',Ext.layout.component.Auto,{type:'columncomponent',setWidthInDom:!0,_paddingReset:{paddingTop:'',paddingBottom:''},columnAutoCls:'x-column-header-text-container-auto',beginLayout:function(a){Ext.layout.component.Auto.prototype.beginLayout.apply(this,arguments);a.titleContext=a.getEl('titleEl')},beginLayoutCycle:function(d){var b=this,a=b.owner,c=d.widthModel.shrinkWrap;Ext.layout.component.Auto.prototype.beginLayoutCycle.apply(this,arguments);if(c){a.el.setWidth('')}a.textContainerEl[c&&!a.isGroupHeader?'addCls':'removeCls'](b.columnAutoCls);a.titleEl.setStyle(b._paddingReset)},publishInnerHeight:function(a,e){var d=this,b=d.owner,c;if(b.getRootHeaderCt().hiddenHeaders){a.setProp('innerHeight',0);return}if(!a.hasRawContent){if(b.headerWrap&&!a.hasDomProp('width')){d.done=!1;return}c=e-a.getBorderInfo().height;a.setProp('innerHeight',c-b.titleEl.getHeight(),!1)}},measureContentHeight:function(a){return a.el.dom.offsetHeight},publishInnerWidth:function(a,b){if(!a.hasRawContent){a.setProp('innerWidth',b-a.getBorderInfo().width,!1)}},calculateOwnerHeightFromContentHeight:function(a,c){var d=Ext.layout.component.Auto.prototype.calculateOwnerHeightFromContentHeight.apply(this,arguments),b=this.owner;if(!a.hasRawContent){if(!b.headerWrap||a.hasDomProp('width')){return c+b.titleEl.getHeight()+a.getBorderInfo().height}return null}return d},calculateOwnerWidthFromContentWidth:function(a,d){var c=this.owner,f=a.getPaddingInfo().width,e=this.getTriggerOffset(c,a),b;if(c.isGroupHeader){b=d}else {b=Math.max(d,c.textEl.getWidth()+a.titleContext.getPaddingInfo().width)}return b+f+e},getTriggerOffset:function(a,c){var b=0;if(c.widthModel.shrinkWrap&&!a.menuDisabled){if(a.query('>:not([hidden])').length===0){b=a.getTriggerElWidth()}}return b}},0,0,0,0,['layout.columncomponent'],0,[Ext.grid,'ColumnComponentLayout'],0);Ext.cmd.derive('Ext.layout.container.Fit',Ext.layout.container.Container,{alternateClassName:'Ext.layout.FitLayout',itemCls:'x-fit-item',type:'fit',manageMargins:!0,sizePolicies:{0:{readsWidth:1,readsHeight:1,setsWidth:0,setsHeight:0},1:{readsWidth:0,readsHeight:1,setsWidth:1,setsHeight:0},2:{readsWidth:1,readsHeight:0,setsWidth:0,setsHeight:1},3:{readsWidth:0,readsHeight:0,setsWidth:1,setsHeight:1}},getItemSizePolicy:function(d,b){var a=b||this.owner.getSizeModel(),c=(a.width.shrinkWrap?0:1)|(a.height.shrinkWrap?0:2);return this.sizePolicies[c]},beginLayoutCycle:function(a,p){var f=this,j=f.lastHeightModel&&f.lastHeightModel.calculated,m=f.lastWidthModel&&f.lastWidthModel.calculated,l=m||j,h=0,i=0,b,k,g,e,q,n,c,d,o,r;Ext.layout.container.Container.prototype.beginLayoutCycle.apply(this,arguments);if(l&&a.targetContext.el.dom.tagName.toUpperCase()!=='TD'){l=m=j=!1}k=a.childItems;q=k.length;for(g=0;g0){for(g=0;g'+a.view.emptyText+''}a.view.getComponentLayout().headerCt=a.headerCt;a.mon(a.view,{uievent:a.processEvent,scope:a});a.headerCt.view=a.view;if(a.hasListeners.viewcreated){a.fireEvent('viewcreated',a,a.view)}}return a.view},getColumnManager:function(){return this.columnManager},getVisibleColumnManager:function(){return this.visibleColumnManager},getTopLevelColumnManager:function(){return this.ownerGrid.getColumnManager()},getTopLevelVisibleColumnManager:function(){return this.ownerGrid.getVisibleColumnManager()},setAutoScroll:Ext.emptyFn,applyScrollable:function(a){if(this.view){this.view.setScrollable(a)}return a},getScrollable:function(){return null},processEvent:function(g,h,f,c,d,b,e,i){var a=b.position.column;if(a){return a.processEvent.apply(a,arguments)}},ensureVisible:function(b,a){this.doEnsureVisible(b,a)},scrollByDeltaY:function(b,a){this.getView().scrollBy(0,b,a)},scrollByDeltaX:function(b,a){this.getView().scrollBy(b,0,a)},afterCollapse:function(){this.saveScrollPos();Ext.panel.Panel.prototype.afterCollapse.apply(this,arguments)},afterExpand:function(){Ext.panel.Panel.prototype.afterExpand.apply(this,arguments);this.restoreScrollPos()},saveScrollPos:Ext.emptyFn,restoreScrollPos:Ext.emptyFn,onHeaderResize:function(){var a=this.view.getScrollable(),b;if(a&&a.isTouchScroller){b=a.getSize();if(b){a.setSize({x:this.headerCt.getTableWidth(),y:b.y})}}},onHeaderMove:function(e,f,b,c,d){var a=this;if(a.optimizedColumnMove===!1){a.view.refreshView()}else {a.view.moveColumn(c,d,b)}a.delayScroll()},onHeaderHide:function(b,c){var a=this.view;if(!b.childHideCount&&a.refreshCounter){a.refreshView()}},onHeaderShow:function(b,c){var a=this.view;if(a.refreshCounter){a.refreshView()}},onHeadersChanged:function(b,c){var a=this;if(a.rendered&&!a.reconfiguring){a.view.refreshView();a.delayScroll()}},delayScroll:function(){var a=this.view;if(a){this.scrollTask.delay(10,null,null,[a])}},onViewReady:function(){this.fireEvent('viewready',this)},onRestoreHorzScroll:function(){var a=this,b=a.scrollXPos;if(b){a.syncHorizontalScroll(a,!0)}},getScrollerOwner:function(){var a=this;if(!this.scrollerOwner){a=this.up('[scrollerOwner]')}return a},getLhsMarker:function(){var a=this;return a.lhsMarker||(a.lhsMarker=Ext.DomHelper.append(a.el,{role:'presentation',cls:a.resizeMarkerCls},!0))},getRhsMarker:function(){var a=this;return a.rhsMarker||(a.rhsMarker=Ext.DomHelper.append(a.el,{role:'presentation',cls:a.resizeMarkerCls},!0))},getSelection:function(){return this.getSelectionModel().getSelection()},updateSelection:function(c){var a=this,b;if(!a.ignoreNextSelection){a.ignoreNextSelection=!0;b=a.getSelectionModel();if(c){b.select(c)}else {b.deselectAll()}a.ignoreNextSelection=!1}},updateBindSelection:function(d,c){var a=this,b=null;if(!a.ignoreNextSelection){a.ignoreNextSelection=!0;if(c.length){b=d.getLastSelected();a.hasHadSelection=!0}if(a.hasHadSelection){a.setSelection(b)}a.ignoreNextSelection=!1}},updateHeaderBorders:function(a){this[a?'removeCls':'addCls'](this.noHeaderBordersCls)},getNavigationModel:function(){return this.getView().getNavigationModel()},getSelectionModel:function(){return this.getView().getSelectionModel()},getScrollTarget:function(){var a=this.getScrollerOwner().query('tableview');return a[a.length-1]},syncHorizontalScroll:function(e,b){var a=this,c=a.view.getScrollX(),d;b=b===!0;if(a.rendered&&(b||c!==a.scrollXPos)){if(b){d=a.getScrollTarget();d.setScrollX(c)}a.headerCt.setScrollX(c);a.scrollXPos=c}},onStoreLoad:Ext.emptyFn,getEditorParent:function(){return this.body},bindStore:function(b,d){var a=this,c=a.getView();if(b){a.store=b;if(c.store!==b){c.bindStore(b,!1)}a.mon(b,{load:a.onStoreLoad,scope:a});a.storeRelayers=a.relayEvents(b,['filterchange','groupchange'])}else {a.unbindStore()}},unbindStore:function(){var a=this,b=a.store,c;if(b){b.trackStateChanges=!1;a.store=null;a.mun(b,{load:a.onStoreLoad,scope:a});Ext.destroy(a.storeRelayers);c=a.view;if(c.store){c.bindStore(null)}}},setColumns:function(a){if(a.length||this.getColumnManager().getColumns().length){this.reconfigure(undefined,a)}},setStore:function(a){this.reconfigure(a);if(this.autoLoad&&!a.isEmptyStore&&!(a.loading||a.isLoaded())){a.load()}},reconfigure:function(b,c){var a=this,f=a.store,e=a.headerCt,i=a.lockable,h=e?e.items.getRange():a.columns,d=a.getView(),j,g;if(arguments.length===1&&Ext.isArray(b)){c=b;b=null}if(c){c=Ext.Array.slice(c)}a.reconfiguring=!0;if(b){b=Ext.StoreManager.lookup(b)}a.fireEvent('beforereconfigure',a,b,c,f,h);Ext.suspendLayouts();if(i){a.reconfigureLockable(b,c)}else {j=d.blockRefresh;d.blockRefresh=!0;if(b&&b!==f){a.unbindStore();a.bindStore(b)}if(c){delete a.scrollXPos;e.removeAll();e.add(c)}d.blockRefresh=j;g=d.refreshCounter}Ext.resumeLayouts(!0);if(i){a.afterReconfigureLockable()}else {if(d.refreshCounter===g){d.refreshView()}}a.fireEvent('reconfigure',a,b,c,f,h);delete a.reconfiguring},beforeDestroy:function(){var a=this,b=a.scrollTask;if(b){b.cancel();a.scrollTask=null}Ext.destroy(a.focusEnterLeaveListeners);Ext.panel.Panel.prototype.beforeDestroy.call(this)},onDestroy:function(){var a=this;if(a.lockable){a.destroyLockable()}a.unbindStore();Ext.panel.Panel.prototype.onDestroy.call(this);a.columns=a.storeRelayers=a.columnManager=a.visibleColumnManager=null},destroy:function(){var a=this;Ext.panel.Panel.prototype.destroy.call(this);if(a.destroyed){a.view=a.selModel=a.headerCt=null}},privates:{initFocusableElement:function(){},doEnsureVisible:function(a,c){if(this.lockable){return this.ensureLockedVisible(a,c)}if(typeof a!=='number'&&!a.isEntity){a=this.store.getById(a)}var b=this,d=b.getView(),f=d.getNode(a),g,h,k,j,m,l,i,e,n;if(c){g=c.callback;h=c.scope;k=c.animate;j=c.highlight;m=c.select;l=c.focus;e=c.column}if(b.deferredEnsureVisible){b.deferredEnsureVisible.destroy()}if(!d.componentLayoutCounter){b.deferredEnsureVisible=d.on({resize:b.doEnsureVisible,args:Ext.Array.slice(arguments),scope:b,single:!0,destroyable:!0});return}if(typeof e==='number'){e=b.ownerGrid.getVisibleColumnManager().getColumns()[e]}if(f){i=d.getScrollable();if(e){n=Ext.fly(f).selectNode(e.getCellSelector())}if(i){i.scrollIntoView(n||f,!!e,k,j)}if(!a.isEntity){a=d.getRecord(f)}if(m){d.getSelectionModel().select(a)}if(l){d.getNavigationModel().setPosition(a,0)}Ext.callback(g,h||b,[!0,a,f])}else {if(d.bufferedRenderer){d.bufferedRenderer.scrollTo(a,{animate:k,highlight:j,select:m,focus:l,column:e,callback:function(f,e,d){Ext.callback(g,h||b,[!0,e,d])}})}else {Ext.callback(g,h||b,[!1,null])}}},getFocusEl:function(){return this.getView().getFocusEl()},setActionableMode:function(b,c){var a=this.ownerGrid;if(!a.destroying&&a.view.setActionableMode(b,c)!==!1){a.fireEvent('actionablemodechange',b);a[b?'addCls':'removeCls'](a.actionableModeCls);return !0}}}},1,['tablepanel'],['component','box','container','panel','tablepanel'],{'component':!0,'box':!0,'container':!0,'panel':!0,'tablepanel':!0},['widget.tablepanel'],0,[Ext.panel,'Table'],0);Ext.define('Ext.theme.neptune.panel.Table',{override:'Ext.panel.Table',lockableBodyBorder:!0,initComponent:function(){var a=this;(arguments.callee.$previous||Ext.panel.Panel.prototype.initComponent).call(this);if(!a.hasOwnProperty('bodyBorder')&&!a.hideHeaders&&(a.lockableBodyBorder||!a.lockable)){a.bodyBorder=!0}}});Ext.cmd.derive('Ext.grid.ColumnLayout',Ext.layout.container.HBox,{type:'gridcolumn',firstHeaderCls:'x-column-header-first',lastHeaderCls:'x-column-header-last',initLayout:function(){Ext.layout.container.HBox.prototype.initLayout.call(this);if(this.scrollbarWidth===undefined){this.self.prototype.scrollbarWidth=Ext.getScrollbarSize().width}},beginLayout:function(d){var b=this,j=b.owner,e=b.firstHeaderCls,f=b.lastHeaderCls,h=[e,f],i=b.getVisibleItems(),g=i.length,c,a;Ext.layout.container.HBox.prototype.beginLayout.call(this,d);for(c=0;c0){b=this.getColumns()[a-1]}return b},getNextSibling:function(c){var a=this.getHeaderIndex(c),b;if(a!==-1){b=this.getColumns()[a+1]}return b||null},getFirst:function(){var a=this.getColumns();return a.length>0?a[0]:null},getLast:function(){var a=this.getColumns(),b=a.length;return b>0?a[b-1]:null},getHeaderByDataIndex:function(d){var c=this.getColumns(),e=c.length,a,b;for(a=0;a=d.left&&e=n.getMaxPosition().y-c.all.last(!0).offsetHeight){b.rowIdx--}e=Math.min(b.rowIdx,h.getCount()-1);f=Math.min(f,j.getColumns().length);d=h.getAt(e);i=j.getColumns()[f]}}else {if(k){d=e=null}else {if(g==null){g=a.lastFocused?a.lastFocused.column:0}if(typeof b==='number'){e=Math.max(Math.min(b,h.getCount()-1),0);d=h.getAt(b)}else {if(b.isEntity){d=b;e=h.indexOf(d)}else {if(b.tagName){d=c.getRecord(b);e=h.indexOf(d);if(e===-1){d=null}}else {if(p){return}k=!0;d=e=null}}}}if(d){if(e===-1){a.recordIndex=-1;d=h.getAt(0);e=0;g=null}if(g==null){if(!(i=a.column)){f=0;i=j.getColumns()[0]}}else {if(typeof g==='number'){i=j.getColumns()[g];f=g}else {i=g;f=j.indexOf(g)}}}else {k=!0;i=f=null}}if(e===a.recordIndex&&f===a.columnIndex&&c===a.position.view){return a.focusPosition(a.position)}if(a.cell){a.cell.removeCls(a.focusCls)}a.previousRecordIndex=a.recordIndex;a.previousRecord=a.record;a.previousItem=a.item;a.previousCell=a.cell;a.previousColumn=a.column;a.previousColumnIndex=a.columnIndex;a.previousPosition=a.position.clone();a.selectionStart=m.selectionStart;a.position.setAll(c,a.recordIndex=e,a.columnIndex=f,a.record=d,a.column=i);if(k){a.item=a.cell=null}else {a.focusPosition(a.position,o)}if(!q){m.fireEvent('focuschange',m,a.previousRecord,a.record);c.fireEvent('rowfocus',a.record,a.item,a.recordIndex);c.fireEvent('cellfocus',a.record,a.cell,a.position)}if(l&&!o&&a.cell!==a.previousCell){a.fireNavigateEvent(l)}},focusPosition:function(b){var a=this,c,d;a.item=a.cell=null;if(b&&b.record&&b.column){c=b.view;if(b.rowElement){d=a.item=b.rowElement}else {d=c.getRowByRecord(b.record)}if(d){a.cell=b.cellElement||Ext.fly(d).down(b.column.getCellSelector(),!0);if(a.cell){a.cell=new Ext.dom.Fly(a.cell);c.lastFocused=a.lastFocused=a.position.clone();a.focusItem(a.cell);c.focusEl=a.cell}else {a.position.setAll();a.record=a.column=a.recordIndex=a.columnIndex=null}}else {d=c.dataSource.indexOf(b.record);a.position.setAll();a.record=a.column=a.recordIndex=a.columnIndex=null;if(d!==-1&&c.bufferedRenderer){a.lastKeyEvent=null;c.bufferedRenderer.scrollTo(d,!1,a.afterBufferedScrollTo,a)}}}},focusItem:function(a){a.addCls(this.focusCls);a.focus()},getCell:function(){return this.cell},getPosition:function(f){var c=this,a=c.position,b,e,d;if(a.record&&a.column){if(f){return a}e=a.view;d=e.dataSource;b=d.indexOf(a.record);if(b===-1){b=a.rowIdx;if(!(a.record=d.getAt(b))){b=-1}}if(b===-1||e.getVisibleColumnManager().indexOf(a.column)===-1){a.setAll();c.record=c.column=c.recordIndex=c.columnIndex=null}else {return a}}return null},getLastFocused:function(){var c=this,b,a=c.lastFocused;if(a&&a.record&&a.column){b=a.view;if(b.dataSource.indexOf(a.record)!==-1&&b.getVisibleColumnManager().indexOf(a.column)!==-1){return a}}},onKeyTab:function(a){var e=!a.shiftKey,d=a.position.clone(),g=d.view,f=a.position.cellElement,b=Ext.fly(f).findTabbableElements(),c,i=g.ownerGrid.actionables,j=i.length,h;a.preventDefault();c=b[Ext.Array.indexOf(b,a.target)+(e?1:-1)];while(!c&&(f=f[e?'nextSibling':'previousSibling'])){d.setColumn(g.getHeaderByCell(f));for(h=0;hj.height}a.setProp('viewOverflowY',i)}},measureContentHeight:function(e){var d=this.owner,b=d.body.dom,c=d.emptyEl,a=0;if(c){a+=c.offsetHeight}if(b){a+=b.offsetHeight}if(e.headerContext.state.boxPlan.tooNarrow){a+=Ext.getScrollbarSize().height}return a},flushColumnWidths:function(){var a=this,i=a.layout,d=a.ownerContext,g=a.columnsChanged,h=d.target,j=g.length,b,c,e,f;if(d.state.columnFlusher!==a){return}for(c=0;c0){h+=b;Ext.fly(f[c].el).setHeight(a)}else {g-=b}}a=i.rowHeight+g;if(Ext.isIE9&&d.view.ownerGrid.rowLines){a--}if(d.rowHeight+h=c+d;a--){e[a]=e[a-d];e[a].setAttribute('data-recordIndex',a)}}b.endIndex=b.endIndex+d}else {b.startIndex=c;b.endIndex=c+d-1}for(a=0;ab.endIndex){delete d[a]}}while(a!==f);delete d[a]},getCount:function(){return this.count},slice:function(e,a){var d=this.elements,c=[],b;if(!a){a=this.endIndex}else {a=Math.min(this.endIndex,a-1)}for(b=e||this.startIndex;b<=a;b++){c.push(d[b])}return c},replaceElement:function(a,b,d){var e=this.elements,c=typeof a==='number'?a:this.indexOf(a);if(c>-1){b=Ext.getDom(b);if(d){a=e[c];a.parentNode.insertBefore(b,a);Ext.removeNode(a);b.setAttribute('data-recordIndex',c)}this.elements[c]=b}return this},indexOf:function(b){var c=this.elements,a;b=Ext.getDom(b);for(a=this.startIndex;a<=this.endIndex;a++){if(c[a]===b){return a}}return -1},removeRange:function(g,c,j){var a=this,e=a.elements,i=[],d,b,h,f;if(c==null){c=a.endIndex+1}else {c=Math.min(a.endIndex+1,c+1)}if(g==null){g=a.startIndex}h=c-g;for(b=g,f=c;b<=a.endIndex;b++,f++){d=e[b];if(b=b.startIndex&&f<=b.endIndex){a[a.length]=f}}Ext.Array.sort(a);e=a.length}else {if(ab.endIndex){return}e=1;a=[a]}for(d=g=a[0],c=0;d<=b.endIndex;d++,g++){if(c=b.startIndex){j=h[d]=h[g];j.setAttribute('data-recordIndex',d)}else {delete h[d]}}b.endIndex-=e;b.count-=e},scroll:function(i,t,m){var b=this,e=b.view,p=e.store,c=b.elements,r=i.length,q=e.getNodeContainer(),k=e.hasListeners.itemremove,s=e.hasListeners.itemadd,h=b.statics().range,a,d,o,j,l,n,f,g;if(!i.length){return}if(t===-1){if(m){if(k){f=[];g=[]}n=b.endIndex-m+1;if(h){h.setStartBefore(c[n]);h.setEndAfter(c[b.endIndex]);h.deleteContents();for(a=n;a<=b.endIndex;a++){d=c[a];delete c[a];if(k){f.push(p.getByInternalId(d.getAttribute('data-recordId')));g.push(d)}}}else {for(a=n;a<=b.endIndex;a++){d=c[a];delete c[a];Ext.removeNode(d);if(k){f.push(p.getByInternalId(d.getAttribute('data-recordId')));g.push(d)}}}e.fireEvent('itemremove',f,n,g,e);b.endIndex-=m}if(i.length){l=e.bufferRender(i,b.startIndex-=r);j=l.children;for(a=0;a','{[view.renderTHead(values, out, parent)]}','{%','view.renderRows(values.rows, values.columns, values.viewStartIndex, out);','%}','{[view.renderTFoot(values, out, parent)]}','','{% ','view = columns = column = null;','%}',{definitions:'var view, tableCls, columns, i, len, column;',priority:0}],outerRowTpl:['','{%','this.nextTpl.applyOut(values, out, parent)','%}','',{priority:9999}],rowTpl:['{%','var dataRowCls = values.recordIndex === -1 ? "" : " x-grid-row";','%}','','{%','parent.view.renderCell(values, parent.record, parent.recordIndex, parent.rowIndex, xindex - 1, out, parent)','%}','','',{priority:0}],cellTpl:['{tdStyle}"',' tabindex="-1" data-columnid="{[values.column.getItemId()]}">','
    {style}" ','{cellInnerAttr:attributes}>{value}
    ','',{priority:0}],refreshSelmodelOnRefresh:!1,tableValues:{},rowValues:{itemClasses:[],rowClasses:[]},cellValues:{classes:['x-grid-cell x-grid-td']},constructor:function(a){if(a.grid.isTree){a.baseCls='x-tree-view'}Ext.view.View.prototype.constructor.call(this,a)},hasVariableRowHeight:function(b){var a=this;return a.variableRowHeight||a.store.isGrouped()||a.getVisibleColumnManager().hasVariableRowHeight()||!b&&a.lockingPartner&&a.lockingPartner.hasVariableRowHeight(!0)},initComponent:function(){var a=this;if(a.columnLines){a.addCls(a.grid.colLinesCls)}if(a.rowLines){a.addCls(a.grid.rowLinesCls)}a.body=new Ext.dom.Fly();a.body.id=a.id+'gridBody';if(!a.trackOver){a.overItemCls=null}a.headerCt.view=a;a.grid.view=a;a.initFeatures(a.grid);a.itemSelector=a.getItemSelector();a.all=new Ext.view.NodeCache(a);Ext.view.View.prototype.initComponent.call(this)},applySelectionModel:function(a,f){var d=this,b=d.ownerGrid,e=a.type,c=d.disableSelection||b.disableSelection;if(!f){if(!(a&&a.isSelectionModel)){a=b.selModel||a}}if(a){if(a.isSelectionModel){a.allowDeselect=b.allowDeselect||a.selectionMode!=='SINGLE';a.locked=c}else {if(typeof a==='string'){a={type:a}}else {a.type=b.selType||a.selType||a.type||e}if(!a.mode){if(b.simpleSelect){a.mode='SIMPLE'}else {if(b.multiSelect){a.mode='MULTI'}}}a=Ext.Factory.selection(Ext.apply({allowDeselect:b.allowDeselect,locked:c},a))}}return a},updateSelectionModel:function(b,c){var a=this;if(c){c.un({scope:a,lastselectedchanged:a.updateBindSelection,selectionchange:a.updateBindSelection});Ext.destroy(a.selModelRelayer)}a.selModelRelayer=a.relayEvents(b,['selectionchange','beforeselect','beforedeselect','select','deselect','focuschange']);b.on({scope:a,lastselectedchanged:a.updateBindSelection,selectionchange:a.updateBindSelection});a.selModel=b},getVisibleColumnManager:function(){return this.ownerCt.getVisibleColumnManager()},getColumnManager:function(){return this.ownerCt.getColumnManager()},getTopLevelVisibleColumnManager:function(){return this.ownerGrid.getVisibleColumnManager()},moveColumn:function(c,h,j){var b=this,m=j>1,e=m&&document.createRange?document.createRange():null,g=m&&!e?document.createDocumentFragment():null,l=h,p=b.getGridColumns().length,k=p-1,r=(b.firstCls||b.lastCls)&&(h===0||h===p||c===0||c===k),f,i,q,n,d,a,o;if(b.rendered&&h!==c){q=b.el.query(b.rowSelector);for(f=0,n=q.length;f=(a-1)*b&&d.endIndex<=a*b-1){c.get(a);return !1}},onViewScroll:function(a,b,c){if(!this.ignoreScroll){Ext.view.View.prototype.onViewScroll.call(this,a,b,c)}},createRowElement:function(e,f,d){var a=this,c=a.renderBuffer,b=a.collectData([e],f);b.columns=d;a.tpl.overwrite(c,b);a.cleanupData();return Ext.fly(c).down(a.getNodeContainerSelector(),!0).firstChild},bufferRender:function(e,f){var c=this,a=c.renderBuffer,b,d=document.createRange?document.createRange():null;c.tpl.overwrite(a,c.collectData(e,f));c.cleanupData();Ext.fly(a).saveTabbableState({skipSelf:!0,includeHidden:!0});a=Ext.fly(a).down(c.getNodeContainerSelector(),!0);if(d){d.selectNodeContents(a);b=d.extractContents()}else {b=document.createDocumentFragment();while(a.firstChild){b.appendChild(a.firstChild)}}return {fragment:b,children:Ext.Array.toArray(b.childNodes)}},collectData:function(c,b){var a=this;a.rowValues.view=a;a.tableValues.view=a;a.tableValues.rows=c;a.tableValues.columns=null;a.tableValues.viewStartIndex=b;a.tableValues.touchScroll=a.touchScroll;a.tableValues.tableStyle='width:'+a.headerCt.getTableWidth()+'px';return a.tableValues},cleanupData:function(){var a=this.tableValues;a.view=a.columns=a.rows=this.rowValues.view=null},refreshSize:function(c){var a=this,b=a.getBodySelector();if(b){a.body.attach(a.el.down(b,!0))}if(!a.hasLoadingHeight){Ext.suspendLayouts();Ext.view.View.prototype.refreshSize.apply(this,arguments);if(c||a.hasVariableRowHeight()&&a.dataSource.getCount()){a.grid.updateLayout()}Ext.resumeLayouts(!0)}},clearViewEl:function(g){var a=this,b=a.all,i=a.getStore(),d,c,f,h=b.slice(),e=[];if(a.hasListeners.itemremove){for(d=b.startIndex;d<=b.endIndex;d++){e.push(i.getByInternalId(b.item(d,!0).getAttribute('data-recordId')))}}a.fireEvent('itemremove',e,b.startIndex,h,a);Ext.view.View.prototype.clearViewEl.call(this);c=Ext.fly(a.getNodeContainer());if(c&&!g){f=a.getTargetEl();if(f.dom!==c.dom){c.destroy()}}},getMaskTarget:function(){return this.ownerCt.body},statics:{getBoundView:function(a){return Ext.getCmp(a.getAttribute('data-boundView'))}},getRecord:function(a){if(this.store.destroyed){return}if(a.isModel){return a}a=this.getNode(a);if(a){return this.dataSource.getByInternalId(a.getAttribute('data-recordId'))}},indexOf:function(a){a=this.getNode(a);if(!a&&a!==0){return -1}return this.all.indexOf(a)},indexInStore:function(a){return a?this.dataSource.indexOf(this.getRecord(a)):-1},indexOfRow:function(a){var c=this.dataSource,b;if(a.isCollapsedPlaceholder){b=c.indexOfPlaceholder(a)}else {b=c.indexOf(a)}return b},renderRows:function(e,g,d,h){var b=this,a=b.rowValues,f=e.length,c;a.view=b;a.columns=g;a.rowRole=b.rowAriaRole;b.cellValues.cellRole=b.cellAriaRole;for(c=0;c');for(a=0;a')}d.push('')},renderRow:function(c,e,j){var a=this,k=e===-1,h=a.selectionModel,b=a.rowValues,d=b.itemClasses,g=b.rowClasses,l=a.itemCls,f,i=a.rowTpl;b.rowAttr={};b.record=c;b.recordId=c.internalId;b.recordIndex=a.store.indexOf(c);b.rowIndex=e;b.rowId=a.getRowId(c);b.itemCls=b.rowCls='';if(!b.columns){b.columns=a.ownerCt.getVisibleColumnManager().getColumns()}d.length=g.length=0;if(!k){d[0]=l;if(!a.ownerCt.disableSelection&&h.isRowSelected){if(h.isRowSelected(c)){d.push(a.selectedItemCls)}}if(a.stripeRows&&e%2!==0){d.push(a.altRowCls)}if(a.getRowClass){f=a.getRowClass(c,e,null,a.dataSource);if(f){g.push(f)}}}if(j){i.applyOut(b,j,a.tableValues)}else {return i.apply(b,a.tableValues)}},renderCell:function(b,f,j,n,m,p){var c=this,l,h=c.selectionModel,a=c.cellValues,d=a.classes,k=f.data[b.dataIndex],o=c.cellTpl,g,e,i=c.navigationModel.getPosition();a.record=f;a.column=b;a.recordIndex=j;a.rowIndex=n;a.columnIndex=a.cellIndex=m;a.align=b.align;a.innerCls=b.innerCls;a.tdCls=a.tdStyle=a.tdAttr=a.style='';a.unselectableAttr=c.enableTextSelection?'':'unselectable="on"';d[1]=b.getCellId();e=2;if(b.renderer&&b.renderer.call){l=c.ownerCt.columnManager.getHeaderIndex(b);g=b.renderer.call(b.usingDefaultRenderer?b:b.scope||c.ownerCt,k,a,f,j,l,c.dataSource,c);if(a.css){f.cssWarning=!0;a.tdCls+=' '+a.css;a.css=null}if(a.tdCls){d[e++]=a.tdCls}}else {g=k}a.value=g==null||g===''?b.emptyCellText:g;if(b.tdCls){d[e++]=b.tdCls}if(c.markDirty&&f.dirty&&f.isModified(b.dataIndex)){d[e++]=c.dirtyCls}if(b.isFirstVisible){d[e++]=c.firstCls}if(b.isLastVisible){d[e++]=c.lastCls}if(!c.enableTextSelection){d[e++]=c.unselectableCls}if(h&&(h.isCellModel||h.isSpreadsheetModel)&&h.isCellSelected(c,j,b)){d[e++]=c.selectedCellCls}if(i&&i.record.id===f.id&&i.column===b){d[e++]=c.focusedItemCls}d.length=e;a.tdCls=d.join(' ');o.applyOut(a,p);a.column=a.record=null},getRow:function(a){var b;if(!a&&a!==0||!this.rendered){return null}if(a.target){a=a.target}if(Ext.isString(a)){return Ext.fly(a).down(this.rowSelector,!0)}if(Ext.isNumber(a)){b=this.all.item(a);return b&&b.down(this.rowSelector,!0)}if(a.isModel){return this.getRowByRecord(a)}b=Ext.fly(a);if(b.is(this.itemSelector)){return this.getRowFromItem(b)}return b.findParent(this.rowSelector,this.getTargetEl())},getRowId:function(a){return this.id+'-record-'+a.internalId},constructRowId:function(a){return this.id+'-record-'+a},getNodeById:function(a){a=this.constructRowId(a);return this.retrieveNode(a,!1)},getRowById:function(a){a=this.constructRowId(a);return this.retrieveNode(a,!0)},getNodeByRecord:function(a){return this.retrieveNode(this.getRowId(a),!1)},getRowByRecord:function(a){return this.retrieveNode(this.getRowId(a),!0)},getRowFromItem:function(c){var b=Ext.getDom(c).tBodies[0].childNodes,d=b.length,a;for(a=0;a1){A=c._extData;j=a.createRowElement(d,a.indexOfRow(d),f);if(Ext.fly(c,'_internal').hasCls(u)){Ext.fly(j).addCls(u)}if(Ext.isIE9m&&c.mergeAttributes){c.mergeAttributes(j,!0)}else {o=j.attributes;H=o.length;for(l=0;l0){if(Ext.supports.ScrollWidthInlinePaddingBug){e+=c.getCellPaddingAfter(d[0])}if(c.columnLines){e+=Ext.fly(d[0].parentNode).getBorderWidth('lr')}}g.setWidth(1);b.textEl.setStyle({'text-overflow':'clip',display:'table-cell'});a=b.textEl.dom.offsetWidth+b.titleEl.getPadding('lr');b.textEl.setStyle({'text-overflow':'',display:''});for(;fh){return !1}if(d){b.view=d}b.setPosition(a,0)}else {b.navigate(+1)};break;case 'left':if(e.isFirstColumn()){a=d&&c.isNormalView?a:a-1;if(a<0){return !1}if(d){b.view=d;f=d.getVisibleColumnManager().getColumns()}b.setPosition(a,f[f.length-1])}else {b.navigate(-1)};break;case 'up':if(a===0){return !1}else {b.setRow(a-1)};break;case 'down':if(a===h){return !1}else {b.setRow(a+1)};break;}if(g&&g.call(j||c,b)!==!0){return !1}return b},walkRows:function(f,e){var i=this,j=i.dataSource,g=0,d=f,h,b=e<0?0:j.getCount()-1,c=b?1:-1,a=f;do{if(b?a>=b:a<=b){return d||b}a+=c;if((h=Ext.fly(i.getRow(a)))&&h.isVisible(!0)){g+=c;d=a}}while(g!==e);return a},walkRecs:function(h,g){var k=this,a=k.dataSource,i=0,e=h,j,c=g<0?0:(a.isBufferedStore?a.getTotalCount():a.getCount())-1,f=c?1:-1,b=a.indexOf(h),d;do{if(c?b>=c:b<=c){return e}b+=f;d=a.getAt(b);if(!d.isCollapsedPlaceholder&&(j=Ext.fly(k.getNodeByRecord(d)))&&j.isVisible(!0)){i+=f;e=d}}while(i!==g);return e},getFirstVisibleRowIndex:function(){var a=this,c=a.dataSource.isBufferedStore?a.dataSource.getTotalCount():a.dataSource.getCount(),b=a.indexOf(a.all.first())-1;do{b+=1;if(b===c){return}}while(!Ext.fly(a.getRow(b)).isVisible(!0));return b},getLastVisibleRowIndex:function(){var b=this,a=b.indexOf(b.all.last());do{a-=1;if(a===-1){return}}while(!Ext.fly(b.getRow(a)).isVisible(!0));return a},getHeaderCt:function(){return this.headerCt},getPosition:function(b,a){return (new Ext.grid.CellContext(this)).setPosition(b,a)},onDestroy:function(){var a=this,c=a.featuresMC,d,b;if(c){for(b=0,d=c.getCount();b=a.viewSize)){a.onReplace(e,d,[],c)}else {Ext.view.View.prototype.onAdd.apply(this,arguments)}b.setPendingStripe(d)},onRemove:function(f,d,e){var a=this,b=a.bufferedRenderer,c;if(a.rendered&&b&&a.dataSource.getCount()+d.length>=b.viewSize){c=a.saveFocusState();b.onReplace(f,e,d,[]);c()}else {Ext.view.View.prototype.onRemove.apply(this,arguments)}a.setPendingStripe(e)},saveFocusState:function(){var b=this,g=b.dataSource,c=b.actionableMode,d=b.getNavigationModel(),a=c?b.actionPosition:d.getPosition(!0),f,e;if(a){a=a.clone();if(c){b.ownerGrid.setActionableMode(!1)}b.el.dom.focus();d.setPosition();return function(){if(g.getCount()){f=Math.min(a.rowIdx,b.all.getCount()-1);e=Math.min(a.colIdx,b.getVisibleColumnManager().getColumns().length-1);a=(new Ext.grid.CellContext(b)).setPosition(g.contains(a.record)?a.record:f,e);if(c){b.ownerGrid.setActionableMode(!0,a)}else {b.cellFocused=!0;d.setPosition(a,null,null,null,!0)}}else {a.column.focus()}}}return Ext.emptyFn},onDataRefresh:function(c){var b=this,a=b.ownerCt;if(a&&a.isCollapsingOrExpanding===2){a.on('expand',b.onDataRefresh,b,{single:!0});return}Ext.view.View.prototype.onDataRefresh.call(this,c)},getViewRange:function(){var a=this;if(a.bufferedRenderer){return a.bufferedRenderer.getViewRange()}return Ext.view.View.prototype.getViewRange.call(this)},setPendingStripe:function(b){var a=this.stripeOnUpdate;if(a===null){a=b}else {a=Math.min(a,b)}this.stripeOnUpdate=a},onEndUpdate:function(){var b=this,a=b.stripeOnUpdate,c=b.all.startIndex;if(b.rendered&&(a||a===0)){if(a-1)&&!g;b=b+(c?1:-1)){o=n[b];e.setColumn(o);k=Ext.fly(d).down(e.column.getCellSelector());for(h=0;h=0&&!(b.isGroupHeader&&(!b.items||!b.items.length))&&h!==c){i=a.isGroupHeader?a.query(':not([hidden]):not([isGroupHeader])').length:1;if(h<=c&&i>1){c-=i}d.getRootHeaderCt().grid.view.moveColumn(h,c,i)}p.fireEvent('columnmove',e,a,h,c);e.isDDMoveInGrid=d.isDDMoveInGrid=!1;if(d.isGroupHeader&&!e.isGroupHeader){if(e!==d){a.savedFlex=a.flex;delete a.flex;a.width=o}}else {if(!e.isGroupHeader){if(a.savedFlex){a.flex=a.savedFlex;delete a.width}}}Ext.resumeLayouts(!0)}}},1,0,0,0,0,0,[Ext.grid.header,'DropZone'],0);Ext.cmd.derive('Ext.grid.plugin.HeaderReorderer',Ext.plugin.Abstract,{init:function(a){this.headerCt=a;a.on({boxready:this.onHeaderCtRender,single:!0,scope:this})},destroy:function(){var a=this;a.headerCt.un('boxready',a.onHeaderCtRender,a);Ext.destroy(a.dragZone,a.dropZone);a.headerCt=a.dragZone=a.dropZone=null;Ext.plugin.Abstract.prototype.destroy.call(this)},onHeaderCtRender:function(){var a=this;a.dragZone=new Ext.grid.header.DragZone(a.headerCt);a.dropZone=new Ext.grid.header.DropZone(a.headerCt);if(a.disabled){a.dragZone.disable()}},enable:function(){this.disabled=!1;if(this.dragZone){this.dragZone.enable()}},disable:function(){this.disabled=!0;if(this.dragZone){this.dragZone.disable()}}},0,0,0,0,['plugin.gridheaderreorderer'],0,[Ext.grid.plugin,'HeaderReorderer'],0);Ext.cmd.derive('Ext.grid.header.Container',Ext.container.Container,{border:!0,baseCls:'x-grid-header-ct',dock:'top',weight:100,defaultType:'gridcolumn',detachOnRemove:!1,defaultWidth:100,sortAscText:'Sort Ascending',sortDescText:'Sort Descending',sortClearText:'Clear Sort',columnsText:'Columns',headerOpenCls:'x-column-header-open',menuSortAscCls:'x-hmenu-sort-asc',menuSortDescCls:'x-hmenu-sort-desc',menuColsIcon:'x-cols-icon',blockEvents:!1,dragging:!1,sortOnClick:!0,enableFocusableContainer:!1,childHideCount:0,sortable:!0,enableColumnHide:!0,initComponent:function(){var a=this;a.plugins=a.plugins||[];a.defaults=a.defaults||{};if(!a.isColumn){if(a.enableColumnResize){a.resizer=new Ext.grid.plugin.HeaderResizer();a.plugins.push(a.resizer)}if(a.enableColumnMove){a.reorderer=new Ext.grid.plugin.HeaderReorderer();a.plugins.push(a.reorderer)}}if(a.isColumn&&!a.isGroupHeader){if(!a.items||a.items.length===0){a.isContainer=a.isFocusableContainer=!1;a.focusable=!0;a.layout={type:'container',calculate:Ext.emptyFn}}}else {a.layout=Ext.apply({type:'gridcolumn',align:'stretch'},a.initialConfig.layout);a.defaults.columnLines=a.columnLines;if(!a.isGroupHeader){a.isRootHeader=!0;if(!a.hiddenHeaders){a.enableFocusableContainer=!0;a.ariaRole='rowgroup'}a.columnManager=new Ext.grid.ColumnManager(!1,a);a.visibleColumnManager=new Ext.grid.ColumnManager(!0,a);if(a.grid){a.grid.columnManager=a.columnManager;a.grid.visibleColumnManager=a.visibleColumnManager}}else {a.visibleColumnManager=new Ext.grid.ColumnManager(!0,a);a.columnManager=new Ext.grid.ColumnManager(!1,a)}}a.menuTask=new Ext.util.DelayedTask(a.updateMenuDisabledState,a);Ext.container.Container.prototype.initComponent.call(this)},insertNestedHeader:function(d){var b=this,e=d.ownerCt,f=b.ownerCt,c=f.layout.owner,a;if(e){if(b.isGroupHeader&&!f.isNestedParent){a=c.items.indexOf(b)}e.remove(d,!1)}if(a===undefined){a=c.items.indexOf(b)}c.insert(a,d)},isNested:function(){return !!this.getRootHeaderCt().down('[isNestedParent]')},isNestedGroupHeader:function(){var a=this,b=a.getRefOwner().query('>:not([hidden])');return b.length===1&&b[0]===a},maybeShowNestedGroupHeader:function(){var a=this.items,b;if(a&&a.length===1&&(b=a.getAt(0))&&b.hidden){b.show()}},setNestedParent:function(a){a.isNestedParent=!1;a.ownerCt.isNestedParent=!!(this.ownerCt.items.length===1&&a.ownerCt.items.length===1)},initEvents:function(){var a=this,b,c;Ext.container.Container.prototype.initEvents.call(this);if(!a.isColumn&&!a.isGroupHeader){b=a.onHeaderCtEvent;c={click:b,dblclick:b,contextmenu:b,mouseover:a.onHeaderCtMouseOver,mouseout:a.onHeaderCtMouseOut,scope:a};if(Ext.supports.Touch){c.longpress=a.onHeaderCtLongPress}a.mon(a.el,c)}},onHeaderCtEvent:function(a,g){var c=this,f=c.getHeaderElByEvent(a),b,e,d;if(c.longPressFired){c.longPressFired=!1;return}if(f&&!c.blockEvents){b=Ext.getCmp(f.id);if(b){e=b[b.clickTargetName];if(!b.isGroupHeader&&!b.isContainer||a.within(e)){if(a.type==='click'||a.type==='tap'){d=b.onTitleElClick(a,e,c.sortOnClick);if(d){c.onHeaderTriggerClick(d,a,a.pointerType==='touch'?d.el:d.triggerEl)}else {c.onHeaderClick(b,a,g)}}else {if(a.type==='contextmenu'){c.onHeaderContextMenu(b,a,g)}else {if(a.type==='dblclick'&&b.resizable){b.onTitleElDblClick(a,e.dom)}}}}}}},blockNextEvent:function(){this.blockEvents=!0;Ext.asap(this.unblockEvents,this)},unblockEvents:function(){this.blockEvents=!1},onHeaderCtMouseOver:function(b,e){var c,a,d;if(!b.within(this.el,!0)){c=b.getTarget('.'+Ext.grid.column.Column.prototype.baseCls);a=c&&Ext.getCmp(c.id);if(a){d=a[a.clickTargetName];if(b.within(d)){a.onTitleMouseOver(b,d.dom)}}}},onHeaderCtMouseOut:function(c,g){var f='.'+Ext.grid.column.Column.prototype.baseCls,d=c.getTarget(f),e=c.getRelatedTarget(f),a,b;if(d!==e){if(d){a=Ext.getCmp(d.id);if(a){b=a[a.clickTargetName];a.onTitleMouseOut(c,b.dom)}}if(e){a=Ext.getCmp(e.id);if(a){b=a[a.clickTargetName];a.onTitleMouseOver(c,b.dom)}}}},onHeaderCtLongPress:function(d){var a=this,b=a.getHeaderElByEvent(d),c=Ext.getCmp(b.id);if(!c.menuDisabled){a.longPressFired=!0;a.showMenuBy(d,b,c)}},getHeaderElByEvent:function(a){return a.getTarget('.'+Ext.grid.column.Column.prototype.baseCls)},isLayoutRoot:function(){if(this.hiddenHeaders){return !1}return Ext.container.Container.prototype.isLayoutRoot.call(this)},getRootHeaderCt:function(){var a=this;return a.isRootHeader?a:a.up('[isRootHeader]')},onDestroy:function(){var a=this;if(a.menu){a.menu.un('hide',a.onMenuHide,a)}a.menuTask.cancel();Ext.container.Container.prototype.onDestroy.call(this);Ext.destroy(a.visibleColumnManager,a.columnManager,a.menu);a.columnManager=a.visibleColumnManager=null},applyColumnsState:function(h,n){if(!h||!h.length){return}var f=this,m=f.items.items,o=m.length,b=0,i=h.length,g,e,a,d,k=!1,c=[],l={},j=[];for(g=0;g=a.visibleFromIdx){b++}Ext.container.Container.prototype.onMove.apply(this,arguments);if(a.isGroupHeader){c=a.visibleColumnManager.getColumns().length}d.onHeaderMoved(a,c,a.visibleFromIdx,b)},maybeContinueRemove:function(){var a=this;return a.isGroupHeader&&!a.applyingState&&!a.isNestedParent&&a.ownerCt&&!a.items.getCount()},onRemove:function(b,c){var a=this,d=a.ownerCt,e=b.lastHiddenHeader;Ext.container.Container.prototype.onRemove.call(this,b,c);if(!a.destroying){if(!a.isDDMoveInGrid){a.onHeadersChanged(b,!1)}if(a.maybeContinueRemove()){if(b.rendered){a.detachComponent(b)}Ext.suspendLayouts();d.remove(a);Ext.resumeLayouts(!0)}}},onHeadersChanged:function(c,d){var b,a=this.getRootHeaderCt();this.purgeHeaderCtCache(this);if(a){a.onColumnsChanged();if(!c.isGroupHeader){b=a.ownerCt;if(b&&!d){b.onHeadersChanged(a,c)}}}},onHeaderMoved:function(d,f,c,e){var a=this,b=a.ownerCt;if(a.rendered){if(b&&b.onHeaderMove){b.onHeaderMove(a,d,f,c,e)}a.fireEvent('columnmove',a,d,c,e)}},onColumnsChanged:function(){var a=this,b=a.menu,c,d;if(a.rendered){a.fireEvent('columnschanged',a);if(b&&(c=b.child('#columnItemSeparator'))){d=b.child('#columnItem');c.destroy();d.destroy()}}},lookupComponent:function(b){var a=Ext.container.Container.prototype.lookupComponent.apply(this,arguments);if(!a.isGroupHeader&&a.width===undefined&&!a.flex){a.width=this.defaultWidth}return a},setSortState:function(){var e=this.up('[store]').store,d=this.visibleColumnManager.getColumns(),f=d.length,c,b,a;for(c=0;cgridcolumn[hideable]'),g=e.length,d;for(;cj.el.dom.clientHeight?Ext.getScrollbarSize().width:0),n=0,e=k.getVisibleGridColumns(),o=b.hidden,f,c,a,g,d;function getTotalFlex(){for(c=0,f=e.length;cg){b.width=g;l=!0}else {b.width=d;h-=d+m;getTotalFlex()}applyWidth();Ext.resumeLayouts(!0)},autoSizeColumn:function(a){var b=this.view;if(b){b.autoSizeColumn(a);if(this.forceFit){this.applyForceFit(a)}}},getRefItems:function(b){var a=Ext.container.Container.prototype.getRefItems.call(this,b);if(this.menu){a.push(this.menu)}return a},privates:{beginChildHide:function(){++this.childHideCount},endChildHide:function(){--this.childHideCount},getFocusables:function(){return this.isRootHeader?this.getVisibleGridColumns():this.items.items},createFocusableContainerKeyNav:function(b){var a=this;return new Ext.util.KeyNav(b,{scope:a,down:a.showHeaderMenu,left:a.onFocusableContainerLeftKey,right:a.onFocusableContainerRightKey,home:a.onHomeKey,end:a.onEndKey,space:a.onHeaderActivate,enter:a.onHeaderActivate})},onHomeKey:function(a){return this.focusChild(null,!0,a)},onEndKey:function(a){return this.focusChild(null,!1,a)},showHeaderMenu:function(b){var a=this.getFocusableFromEvent(b);if(a&&a.isColumn&&a.triggerEl){this.onHeaderTriggerClick(a,b,a.triggerEl)}},onHeaderActivate:function(d){var a=this.getFocusableFromEvent(d),c,b;if(a&&a.isColumn){c=a.getView();if(a.sortable&&this.sortOnClick){b=c.getNavigationModel().getLastFocused();a.toggleSortState();if(b){c.ownerCt.ensureVisible(b.record)}}this.onHeaderClick(a,d,a.el)}},onFocusableContainerMousedown:function(c,b){var a=Ext.Component.fromElement(b);if(a===this){c.preventDefault()}else {a.focus()}}}},0,['headercontainer'],['component','box','container','headercontainer'],{'component':!0,'box':!0,'container':!0,'headercontainer':!0},['widget.headercontainer'],[[Ext.util.FocusableContainer.prototype.mixinId||Ext.util.FocusableContainer.$className,Ext.util.FocusableContainer]],[Ext.grid.header,'Container'],0);Ext.cmd.derive('Ext.grid.column.Column',Ext.grid.header.Container,{alternateClassName:'Ext.grid.Column',config:{triggerVisible:!1,sorter:null},baseCls:'x-column-header',hoverCls:'x-column-header-over',ariaRole:'columnheader',enableFocusableContainer:!1,sortState:null,possibleSortStates:['ASC','DESC'],ariaSortStates:{ASC:'ascending',DESC:'descending'},childEls:['titleEl','triggerEl','textEl','textContainerEl'],headerWrap:!1,renderTpl:['','{%this.renderContainer(out,values)%}'],dataIndex:null,text:' ',menuText:null,emptyCellText:' ',sortable:!0,resizable:!0,hideable:!0,menuDisabled:!1,renderer:!1,align:'left',draggable:!0,tooltipType:'qtip',initDraggable:Ext.emptyFn,tdCls:'',producesHTML:!0,ignoreExport:!1,isHeader:!0,isColumn:!0,tabIndex:-1,ascSortCls:'x-column-header-sort-ASC',descSortCls:'x-column-header-sort-DESC',componentLayout:'columncomponent',groupSubHeaderCls:'x-group-sub-header',groupHeaderCls:'x-group-header',clickTargetName:'titleEl',detachOnRemove:!0,initResizable:Ext.emptyFn,rendererNames:{column:'renderer',edit:'editRenderer',summary:'summaryRenderer'},formatterNames:{column:'formatter',edit:'editFormatter',summary:'summaryFormatter'},initComponent:function(){var a=this;if(!a.rendererScope){a.rendererScope=a.scope}if(a.header!=null){a.text=a.header;a.header=null}if(a.cellWrap){a.tdCls=(a.tdCls||'')+' x-wrap-cell'}if(a.columns!=null){a.isGroupHeader=!0;a.ariaRole='presentation';a.items=a.columns;a.columns=a.flex=a.width=null;a.cls=(a.cls||'')+' '+a.groupHeaderCls;a.sortable=a.resizable=!1;a.align='center'}else {if(a.flex){a.minWidth=a.minWidth||Ext.grid.plugin.HeaderResizer.prototype.minColWidth}}a.addCls('x-column-header-align-'+a.align);a.setupRenderer();a.setupRenderer('edit');a.setupRenderer('summary');Ext.grid.header.Container.prototype.initComponent.apply(this,arguments)},onAdded:function(e,g,f){var a=this,c,d,b;Ext.grid.header.Container.prototype.onAdded.call(this,e,g,f);if(!a.headerId){d=a.up('tablepanel');b=d?d.ownerGrid:a.getRootHeaderCt();b.headerCounter=(b.headerCounter||0)+1;a.headerId='h'+b.headerCounter}if(!a.stateId){a.stateId=a.initialConfig.id||a.headerId}c=a.getSorter();if(c&&!c.initialConfig.id){c.setId((a.dataIndex||a.stateId)+'-sorter')}},applySorter:function(a){return this.getRootHeaderCt().up('tablepanel').store.getData().getSorters().decodeSorter(a)},bindFormatter:function(a){var b=this;return function(c){return a.format(c,a.scope||b.rendererScope||b.resolveListenerScope())}},bindRenderer:function(b){var a=this;a.hasCustomRenderer=!0;return function(){return Ext.callback(b,a.rendererScope,arguments,0,a)}},setupRenderer:function(c){c=c||'column';var a=this,b=a[a.formatterNames[c]],d=a[a.rendererNames[c]],f=c==='column',e,g;if(!b){if(d){if(typeof d==='string'){d=a[a.rendererNames[c]]=a.bindRenderer(d);g=!0}if(f){a.hasCustomRenderer=g||d.length>1}}else {if(f&&a.defaultRenderer){a.renderer=a.defaultRenderer;a.usingDefaultRenderer=!0}}}else {e=b.indexOf('this.')===0;if(e){b=b.substring(5)}b=Ext.app.bind.Template.prototype.parseFormat(b);a[a.formatterNames[c]]=null;if(e){b.scope=null}a[a.rendererNames[c]]=a.bindFormatter(b)}},getView:function(){var a=this.getRootHeaderCt();if(a){return a.view}},onFocusLeave:function(a){Ext.grid.header.Container.prototype.onFocusLeave.call(this,a);if(this.activeMenu){this.activeMenu.hide()}},initItems:function(){var a=this;Ext.grid.header.Container.prototype.initItems.apply(this,arguments);if(a.isGroupHeader){if(a.config.hidden||!a.hasVisibleChildColumns()){a.hide()}}},hasVisibleChildColumns:function(){var c=this.items.items,d=c.length,a,b;for(a=0;agridcolumn:not([hidden]):not([menuDisabled])');c=a.length;if(Ext.Array.contains(a,b.hideCandidate)){c--}if(c){return !1}b.hideCandidate=this},isLockable:function(){var a={result:this.lockable!==!1};if(a.result){this.ownerCt.bubble(this.hasMultipleVisibleChildren,null,[a])}return a.result},isLocked:function(){return this.locked||!!this.up('[isColumn][locked]','[isRootHeader]')},hasMultipleVisibleChildren:function(a){if(!this.isXType('headercontainer')){a.result=!1;return !1}if(this.query('>gridcolumn:not([hidden])').length>1){return !1}},hide:function(){var a=this,b=a.getRootHeaderCt(),c=a.getRefOwner();if(c.constructing){Ext.grid.header.Container.prototype.hide.call(this);return a}if(a.rendered&&!a.isVisible()){return a}if(b.forceFit){a.visibleSiblingCount=b.getVisibleGridColumns().length-1;if(a.flex){a.savedWidth=a.getWidth();a.flex=null}}b.beginChildHide();Ext.suspendLayouts();if(c.isGroupHeader){if(a.isNestedGroupHeader()){c.hide()}if(a.isSubHeader&&!a.isGroupHeader&&c.query('>gridcolumn:not([hidden])').length===1){c.lastHiddenHeader=a}}Ext.grid.header.Container.prototype.hide.call(this);b.endChildHide();b.onHeaderHide(a);Ext.resumeLayouts(!0);return a},show:function(){var a=this,c=a.getRootHeaderCt(),b=a.getRefOwner();if(a.isVisible()){return a}if(b.isGroupHeader){b.lastHiddenHeader=null}if(a.rendered){if(c.forceFit){c.applyForceFit(a)}}Ext.suspendLayouts();if(a.isSubHeader&&b.hidden){b.show(!1,!0)}Ext.grid.header.Container.prototype.show.apply(this,arguments);if(a.isGroupHeader){a.maybeShowNestedGroupHeader()}b=a.getRootHeaderCt();if(b){b.onHeaderShow(a)}Ext.resumeLayouts(!0);return a},shouldUpdateCell:function(d,b){if(!this.preventUpdate){if(this.hasCustomRenderer){return 1}if(b){var e=b.length,a,c;for(a=0;aActions',ignoreExport:!0,sortable:!1,innerCls:'x-grid-cell-inner-action-col',actionIconCls:'x-action-col-icon',constructor:function(g){var a=this,b=Ext.apply({},g),d=b.items||a.items||[a],e,c,f;a.origRenderer=b.renderer||a.renderer;a.origScope=b.scope||a.scope;a.renderer=a.scope=b.renderer=b.scope=null;b.items=null;Ext.grid.column.Column.prototype.constructor.call(this,b);a.items=d;for(c=0,f=d.length;c':'>')}return h},updater:function(e,d,c,f,b){var a={};Ext.fly(e).addCls(a.tdCls).down(this.getView().innerSelector,!0).innerHTML=this.defaultRenderer(d,a,c,null,null,b,f)},enableAction:function(a,c){var b=this;if(!a){a=0}else {if(!Ext.isNumber(a)){a=Ext.Array.indexOf(b.items,a)}}b.items[a].disabled=!1;b.up('tablepanel').el.select('.x-action-col-'+a).removeCls(b.disabledCls);if(!c){b.fireEvent('enable',b)}},disableAction:function(a,c){var b=this;if(!a){a=0}else {if(!Ext.isNumber(a)){a=Ext.Array.indexOf(b.items,a)}}b.items[a].disabled=!0;b.up('tablepanel').el.select('.x-action-col-'+a).addCls(b.disabledCls);if(!c){b.fireEvent('disable',b)}},beforeDestroy:function(){this.renderer=this.items=null;return Ext.grid.column.Column.prototype.beforeDestroy.apply(this,arguments)},processEvent:function(f,g,n,h,i,d,l,o){var b=this,c=d.getTarget(),e=f==='keydown'&&d.getKey(),m,a,j,k=Ext.fly(n);d.stopSelection=!e&&b.stopSelection;if(e&&(c===n||!k.contains(c))){c=k.query('.'+b.actionIconCls,!0);if(c.length===1){c=c[0]}else {return}}if(c&&(m=c.className.match(b.actionIdRe))){a=b.items[parseInt(m[1],10)];j=a.disabled||(a.isDisabled?a.isDisabled.call(a.scope||b.origScope||b,g,h,i,a,l):!1);if(a&&!j){if(f==='mousedown'&&!b.getView().actionableMode){d.preventDefault()}else {if(f==='click'||(e===d.ENTER||e===d.SPACE)){Ext.callback(a.handler||b.handler,a.scope||b.origScope,[g,h,i,a,d,l,o],undefined,b);if(!g.el.contains(Ext.Element.getActiveElement())){return !1}}}}}return Ext.grid.column.Column.prototype.processEvent.apply(this,arguments)},cascade:function(b,a){b.call(a||this,this)},getRefItems:function(){return []},privates:{getFocusables:function(){return []},shouldUpdateCell:function(){return 2}}},1,['actioncolumn'],['component','box','container','headercontainer','gridcolumn','actioncolumn'],{'component':!0,'box':!0,'container':!0,'headercontainer':!0,'gridcolumn':!0,'actioncolumn':!0},['widget.actioncolumn'],0,[Ext.grid.column,'Action',Ext.grid,'ActionColumn'],0);Ext.cmd.derive('Ext.grid.column.Check',Ext.grid.column.Column,{alternateClassName:['Ext.ux.CheckColumn','Ext.grid.column.CheckColumn'],align:'center',ignoreExport:!0,stopSelection:!0,tdCls:'x-grid-cell-checkcolumn',innerCls:'x-grid-cell-inner-checkcolumn',clickTargetName:'el',defaultFilterType:'boolean',constructor:function(){this.scope=this;Ext.grid.column.Column.prototype.constructor.apply(this,arguments)},processEvent:function(h,n,k,e,m,b,g,l){var a=this,d=h==='keydown'&&b.getKey(),f=h==='mousedown',j=a.disabled,i,c;b.stopSelection=!d&&a.stopSelection;if(!j&&(f||(d===b.ENTER||d===b.SPACE))){c=!a.isRecordChecked(g);if(a.fireEvent('beforecheckchange',a,e,c)!==!1){a.setRecordCheck(g,c,k,l,b);a.fireEvent('checkchange',a,e,c);if(f&&!a.getView().actionableMode){b.preventDefault()}}}else {i=Ext.grid.column.Column.prototype.processEvent.apply(this,arguments)}return i},onEnable:function(){Ext.grid.column.Column.prototype.onEnable.apply(this,arguments);this._setDisabled(!1)},onDisable:function(){this._setDisabled(!0)},_setDisabled:function(d){var b=this,c=b.disabledCls,a;a=b.up('tablepanel').el.select(b.getCellSelector());if(d){a.addCls(c)}else {a.removeCls(c)}},defaultRenderer:function(d,c){var a='x-',b=a+'grid-checkcolumn';if(this.disabled){c.tdCls+=' '+this.disabledCls}if(d){b+=' '+a+'grid-checkcolumn-checked'}return '
    '},isRecordChecked:function(a){var b=this.property;if(b){return a[b]}return a.get(this.dataIndex)},setRecordCheck:function(c,a,e,f,g){var b=this,d=b.property;if(d){c[d]=a;b.updater(e,a)}else {c.set(b.dataIndex,a)}},updater:function(a,b){a=Ext.fly(a);a[this.disabled?'addCls':'removeCls'](this.disabledCls);Ext.fly(a.down(this.getView().innerSelector,!0).firstChild)[b?'addCls':'removeCls']('x-grid-checkcolumn-checked')}},1,['checkcolumn'],['component','box','container','headercontainer','gridcolumn','checkcolumn'],{'component':!0,'box':!0,'container':!0,'headercontainer':!0,'gridcolumn':!0,'checkcolumn':!0},['widget.checkcolumn'],0,[Ext.grid.column,'Check',Ext.ux,'CheckColumn',Ext.grid.column,'CheckColumn'],0);Ext.cmd.derive('Ext.grid.column.Number',Ext.grid.column.Column,{alternateClassName:'Ext.grid.NumberColumn',defaultFilterType:'number',format:'0,000.00',producesHTML:!1,defaultRenderer:function(a){return Ext.util.Format.number(a,this.format)},updater:function(b,a){Ext.fly(b).down(this.getView().innerSelector,!0).innerHTML=Ext.grid.column.Number.prototype.defaultRenderer.call(this,a)}},0,['numbercolumn'],['component','box','container','headercontainer','gridcolumn','numbercolumn'],{'component':!0,'box':!0,'container':!0,'headercontainer':!0,'gridcolumn':!0,'numbercolumn':!0},['widget.numbercolumn'],0,[Ext.grid.column,'Number',Ext.grid,'NumberColumn'],0);Ext.cmd.derive('Ext.grid.column.RowNumberer',Ext.grid.column.Column,{alternateClassName:'Ext.grid.RowNumberer',isRowNumberer:!0,text:' ',width:23,sortable:!1,draggable:!1,autoLock:!0,lockable:!1,align:'right',producesHTML:!1,ignoreExport:!0,constructor:function(b){var a=this;a.width=a.width;Ext.grid.column.Column.prototype.constructor.apply(this,arguments);a.sortable=!1;a.scope=a},resizable:!1,hideable:!1,menuDisabled:!0,dataIndex:'',cls:'x-row-numberer',tdCls:'x-grid-cell-row-numberer x-grid-cell-special',innerCls:'x-grid-cell-inner-row-numberer',rowspan:undefined,defaultRenderer:function(j,b,f,i,h,a,g){var c=this.rowspan,e=a.currentPage,d=g.store.indexOf(f);if(b&&c){b.tdAttr='rowspan="'+c+'"'}if(e>1){d+=(e-1)*a.pageSize}return d+1},updater:function(d,c,b,e,a){Ext.fly(d).down(this.getView().innerSelector,!0).innerHTML=this.defaultRenderer(c,null,b,null,null,a,e)}},1,['rownumberer'],['component','box','container','headercontainer','gridcolumn','rownumberer'],{'component':!0,'box':!0,'container':!0,'headercontainer':!0,'gridcolumn':!0,'rownumberer':!0},['widget.rownumberer'],0,[Ext.grid.column,'RowNumberer',Ext.grid,'RowNumberer'],0);Ext.define('Ext.theme.neptune.grid.column.RowNumberer',{override:'Ext.grid.column.RowNumberer',width:25});Ext.cmd.derive('Ext.grid.column.Widget',Ext.grid.column.Column,{config:{defaultWidgetUI:{}},ignoreExport:!0,sortable:!1,onWidgetAttach:null,preventUpdate:!0,stopSelection:!0,initComponent:function(){var b=this,a;Ext.grid.column.Column.prototype.initComponent.apply(this,arguments);a=b.widget;b.widget=a=Ext.apply({},a);if(!a.ui){a.ui=b.getDefaultWidgetUI()[a.xtype]||'default'}b.isFixedSize=Ext.isNumber(a.width)},processEvent:function(c,d,h,e,f,b,g,i){var a;if(this.stopSelection&&c==='click'){a=b.getTarget(d.innerSelector);if(a&&a!==b.target){b.stopSelection=!0}}},beforeRender:function(){var a=this,b=a.tdCls,c;a.listenerScopeFn=function(b){if(b==='this'){return this}return a.resolveListenerScope(b)};a.liveWidgets={};a.cachedStyles={};a.freeWidgetStack=[c=a.getFreeWidget()];b=b?b+' ':'';a.tdCls=b+c.getTdCls();a.setupViewListeners(a.getView());Ext.grid.column.Column.prototype.beforeRender.call(this)},afterRender:function(){var a=this.getView();Ext.grid.column.Column.prototype.afterRender.call(this);if(a&&a.viewReady&&!a.ownerGrid.reconfiguring){this.onViewRefresh(a,a.getViewRange())}},defaultRenderer:Ext.emptyFn,updater:function(c,b,a){this.updateWidget(a)},onResize:function(e){var a=this,d=a.liveWidgets,c=a.getView(),f,b;if(!a.isFixedSize&&a.rendered&&c&&c.viewReady){b=c.getEl().down(a.getCellInnerSelector());if(b){e-=parseInt(a.getCachedStyle(b,'padding-left'),10)+parseInt(a.getCachedStyle(b,'padding-right'),10);for(f in d){d[f].setWidth(e)}}}},onAdded:function(){var b=this,a;Ext.grid.column.Column.prototype.onAdded.apply(this,arguments);a=b.getView();if(a){b.setupViewListeners(a);if(a&&a.viewReady&&b.rendered&&a.getEl().down(b.getCellSelector())){b.onViewRefresh(a,a.getViewRange())}}},onRemoved:function(e){var a=this,c=a.liveWidgets,b=a.viewListeners,d;if(a.rendered){a.viewListeners=b&&Ext.destroy(b);if(!e){for(d in c){c[d].detachFromBody()}}}Ext.grid.column.Column.prototype.onRemoved.apply(this,arguments)},onDestroy:function(){var b=this,e=b.liveWidgets,d=b.freeWidgetStack,g,a,c,f;if(b.rendered){for(g in e){a=e[g];a.$widgetRecord=a.$widgetColumn=null;delete a.getWidgetRecord;delete a.getWidgetColumn;a.destroy()}for(c=0,f=d.length;c{text} {linkHrefCls}{childElCls}" href="{href}" target="{hrefTarget}" hidefocus="true" unselectable="on" tabindex="{tabIndex}" {$}="{.}">{text}',maskOnDisable:!1,iconAlign:'left',initComponent:function(){var a=this,b=a.cls?[a.cls]:[],c;if(a.hasOwnProperty('canActivate')){a.focusable=a.canActivate}if(a.plain){b.push('x-menu-item-plain')}if(b.length){a.cls=b.join(' ')}if(a.menu){c=a.menu;a.menu=null;a.setMenu(c)}Ext.Component.prototype.initComponent.apply(this,arguments)},canFocus:function(){var a=this;return a.focusable&&a.rendered&&a.canActivate!==!1&&!a.destroying&&!a.destroyed&&a.isVisible(!0)},onFocus:function(b){var a=this;Ext.Component.prototype.onFocus.call(this,b);if(!a.disabled){if(!a.plain){a.addCls(a.activeCls)}a.activated=!0;if(a.hasListeners.activate){a.fireEvent('activate',a)}}},onFocusLeave:function(b){var a=this;Ext.Component.prototype.onFocusLeave.call(this,b);if(a.activated){if(!a.plain){a.removeCls(a.activeCls)}a.doHideMenu();a.activated=!1;if(a.hasListeners.deactivate){a.fireEvent('deactivate',a)}}},doHideMenu:function(){var a=this.menu;this.cancelDeferExpand();if(a&&a.isVisible()){a.hide()}},deferHideParentMenus:function(){for(var a=this.getRefOwner();a&&(a.isMenu&&a.floating||a.isMenuItem);a=a.getRefOwner()){if(a.isMenu){a.hide()}}},expandMenu:function(c,b){var a=this;if(a.activated&&a.menu){a.hideOnClick=!1;a.cancelDeferHide();b=b==null?a.menuExpandDelay:b;if(b===0){a.doExpandMenu(c)}else {a.cancelDeferExpand();a.expandMenuTimer=Ext.defer(a.doExpandMenu,b,a,[c])}}},doExpandMenu:function(c){var b=this,a=b.menu;if(!a.isVisible()){b.parentMenu.activeChild=a;a.ownerCmp=b;a.parentMenu=b.parentMenu;a.constrainTo=document.body;a.autoFocus=!c||!c.pointerType;a.showBy(b,b.menuAlign)}},getRefItems:function(c){var b=this.menu,a;if(b){a=b.getRefItems(c);a.unshift(b)}return a||[]},getValue:function(){return this.value},hideMenu:function(b){var a=this;if(a.menu){a.cancelDeferExpand();a.hideMenuTimer=Ext.defer(a.doHideMenu,Ext.isNumber(b)?b:a.menuHideDelay,a)}},onClick:function(b){var a=this,e=a.clickHideDelay,f=b.browserEvent,d,c;if(!a.href||a.disabled){b.stopEvent();if(a.disabled){return !1}}if(a.disabled||a.handlingClick){return}if(a.hideOnClick){if(!e){a.deferHideParentMenus()}else {a.deferHideParentMenusTimer=Ext.defer(a.deferHideParentMenus,e,a)}}d=a.fireEvent('click',a,b);if(a.destroyed){return}if(d!==!1&&a.handler){Ext.callback(a.handler,a.scope,[a,b],0,a)}if(Ext.isIE9m){c=f.returnValue===!1?!0:!1}else {c=!!f.defaultPrevented}if(a.href&&b.type!=='click'&&!c){a.handlingClick=!0;a.itemEl.dom.click();a.handlingClick=!1}if(!a.hideOnClick){a.focus()}return d},onRemoved:function(){var a=this;if(a.activated&&a.parentMenu.activeItem===a){a.parentMenu.deactivateActiveItem()}Ext.Component.prototype.onRemoved.apply(this,arguments);a.parentMenu=a.ownerCmp=null},beforeDestroy:function(){var a=this;if(a.rendered){a.clearTip()}Ext.Component.prototype.beforeDestroy.call(this)},onDestroy:function(){var a=this;a.cancelDeferExpand();a.cancelDeferHide();clearTimeout(a.deferHideParentMenusTimer);a.setMenu(null);Ext.Component.prototype.onDestroy.apply(this,arguments)},beforeRender:function(){var a=this,c=a.glyph,j=Ext._glyphFontFamily,b=!!(a.icon||a.iconCls||c),f=!!a.menu,i=a.iconAlign==='right'&&!f,e=a.isMenuCheckItem,d=[],k=a.ownerCt,g=k.plain,h;if(a.plain){a.ariaEl='el'}Ext.Component.prototype.beforeRender.call(this);if(b){if(f&&a.showCheckbox){b=!1}}if(typeof c==='string'){h=c.split('@');c=h[0];j=h[1]}if(!g||b&&!i||e){if(k.showSeparator&&!g){d.push(a.indentCls)}else {d.push(a.indentNoSeparatorCls)}}if(f){d.push(a.indentRightArrowCls)}else {if(b&&(i||e)){d.push(a.indentRightIconCls)}}Ext.applyIf(a.renderData,{hasHref:!!a.href,href:a.href||'#',hrefTarget:a.hrefTarget,icon:a.icon,iconCls:a.iconCls,glyph:c,glyphCls:c?'x-menu-item-glyph':undefined,glyphFontFamily:j,hasIcon:b,hasMenu:f,indent:!g||b||e,isCheckItem:e,rightIcon:i,plain:a.plain,text:a.text,arrowCls:a.arrowCls,baseIconCls:a.baseIconCls,textCls:a.textCls,indentCls:d.join(' '),linkCls:a.linkCls,linkHrefCls:a.linkHrefCls,groupCls:a.group?a.groupCls:'',tabIndex:a.tabIndex})},onRender:function(){var a=this;Ext.Component.prototype.onRender.apply(this,arguments);if(a.tooltip){a.setTooltip(a.tooltip,!0)}},getMenu:function(){return this.menu||null},setMenu:function(b,f){var a=this,e=a.menu,h=a.arrowEl,d=a.ariaEl.dom,c,g;if(e){e.ownerCmp=e.parentMenu=null;if(f===!0||f!==!1&&a.destroyMenu){Ext.destroy(e)}if(d){d.removeAttribute('aria-haspopup');d.removeAttribute('aria-owns')}else {c=a.ariaRenderAttributes||(a.ariaRenderAttributes={});delete c['aria-haspopup'];delete c['aria-owns']}}if(b){g=b.isMenu;b=a.menu=Ext.menu.Manager.get(b,{ownerCmp:a,focusOnToFront:!1});b.setOwnerCmp(a,g);if(d){d.setAttribute('aria-haspopup',!0);d.setAttribute('aria-owns',b.id)}else {c=a.ariaRenderAttributes||(a.ariaRenderAttributes={});c['aria-haspopup']=!0;c['aria-owns']=b.id}}else {b=a.menu=null}if(b&&a.rendered&&!a.destroying&&h){h[b?'addCls':'removeCls'](a.arrowCls)}},setHandler:function(b,a){this.handler=b||null;this.scope=a},setIcon:function(a){var b=this.iconEl,c=this.icon;if(b){b.src=a||Ext.BLANK_IMAGE_URL}this.icon=a;this.fireEvent('iconchange',this,c,a)},setIconCls:function(b){var a=this,c=a.iconEl,d=a.iconCls;if(c){if(a.iconCls){c.removeCls(a.iconCls)}if(b){c.addCls(b)}}a.iconCls=b;a.fireEvent('iconchange',a,d,b)},setText:function(b){var a=this,d=a.textEl||a.el,c=a.text;a.text=b;if(a.rendered){d.setHtml(b||'');a.updateLayout()}a.fireEvent('textchange',a,c,b)},getTipAttr:function(){return this.tooltipType==='qtip'?'data-qtip':'title'},clearTip:function(){if(Ext.quickTipsActive&&Ext.isObject(this.tooltip)){Ext.tip.QuickTipManager.unregister(this.itemEl)}},setTooltip:function(b,c){var a=this;if(a.rendered){if(!c){a.clearTip()}if(Ext.quickTipsActive&&Ext.isObject(b)){Ext.tip.QuickTipManager.register(Ext.apply({target:a.itemEl.id},b));a.tooltip=b}else {a.itemEl.dom.setAttribute(a.getTipAttr(),b)}}else {a.tooltip=b}return a},privates:{cancelDeferExpand:function(){window.clearTimeout(this.expandMenuTimer)},cancelDeferHide:function(){window.clearTimeout(this.hideMenuTimer)},getFocusEl:function(){return this.plain?this.el:this.itemEl}}},0,['menuitem'],['component','box','menuitem'],{'component':!0,'box':!0,'menuitem':!0},['widget.menuitem'],[[Ext.mixin.Queryable.prototype.mixinId||Ext.mixin.Queryable.$className,Ext.mixin.Queryable]],[Ext.menu,'Item',Ext.menu,'TextItem'],0);Ext.cmd.derive('Ext.menu.CheckItem',Ext.menu.Item,{checkedCls:'x-menu-item-checked',uncheckedCls:'x-menu-item-unchecked',groupCls:'x-menu-group-icon',hideOnClick:!1,checkChangeDisabled:!1,submenuText:'{0} submenu',ariaRole:'menuitemcheckbox',childEls:['checkEl'],showCheckbox:!0,isMenuCheckItem:!0,checkboxCls:'x-menu-item-checkbox',initComponent:function(){var a=this;a.checked=!!a.checked;Ext.menu.Item.prototype.initComponent.apply(this,arguments);if(a.group){Ext.menu.Manager.registerCheckable(a);if(a.initialConfig.hideOnClick!==!1){a.hideOnClick=!0}}},beforeRender:function(){var a=this,b;Ext.menu.Item.prototype.beforeRender.call(this);Ext.apply(a.renderData,{checkboxCls:a.checkboxCls,showCheckbox:a.showCheckbox});b=a.ariaRenderAttributes||(a.ariaRenderAttributes={});b['aria-checked']=a.menu?'mixed':a.checked;if(a.menu){b['aria-label']=Ext.String.formatEncode(a.submenuText,a.text)}},afterRender:function(){var a=this;Ext.menu.Item.prototype.afterRender.call(this);a.checked=!a.checked;a.setChecked(!a.checked,!0);if(a.checkChangeDisabled){a.disableCheckChange()}if(Ext.isGecko&&a.checkEl){a.checkEl.on('mousedown',a.onMouseDownCheck)}},disableCheckChange:function(){var a=this,b=a.checkEl;if(b){b.addCls(a.disabledCls)}if(Ext.isIE8&&a.rendered){a.el.repaint()}a.checkChangeDisabled=!0},enableCheckChange:function(){var a=this,b=a.checkEl;if(b){b.removeCls(a.disabledCls)}a.checkChangeDisabled=!1},onMouseDownCheck:function(a){a.preventDefault()},onClick:function(b){var a=this;if(!(a.disabled||a.checkChangeDisabled||a.checked&&a.group||a.menu&&'touch'===b.pointerType&&!a.checkEl.contains(b.target))){a.setChecked(!a.checked);if(b.type==='keydown'&&a.menu){return !1}}Ext.menu.Item.prototype.onClick.call(this,b)},onDestroy:function(){Ext.menu.Manager.unregisterCheckable(this);Ext.menu.Item.prototype.onDestroy.apply(this,arguments)},setText:function(c){var a=this,b=a.ariaEl.dom;Ext.menu.Item.prototype.setText.call(this,c);if(b&&a.menu){b.setAttribute('aria-label',Ext.String.formatEncode(a.submenuText,c))}},setChecked:function(b,d){var a=this,f=a.checkedCls,e=a.uncheckedCls,c=a.el,g=a.ariaEl.dom;if(a.checked!==b&&(d||a.fireEvent('beforecheckchange',a,b)!==!1)){if(c){if(b){c.addCls(f);c.removeCls(e)}else {c.addCls(e);c.removeCls(f)}}if(g){g.setAttribute('aria-checked',a.menu?'mixed':!!b)}a.checked=b;Ext.menu.Manager.onCheckChange(a,b);if(!d){Ext.callback(a.checkHandler,a.scope,[a,b],0,a);a.fireEvent('checkchange',a,b)}}}},0,['menucheckitem'],['component','box','menuitem','menucheckitem'],{'component':!0,'box':!0,'menuitem':!0,'menucheckitem':!0},['widget.menucheckitem'],0,[Ext.menu,'CheckItem'],0);Ext.cmd.derive('Ext.menu.Separator',Ext.menu.Item,{focusable:!1,canActivate:!1,hideOnClick:!1,plain:!0,separatorCls:'x-menu-item-separator',text:' ',ariaRole:'separator',beforeRender:function(){this.addCls(this.separatorCls);Ext.menu.Item.prototype.beforeRender.call(this)}},0,['menuseparator'],['component','box','menuitem','menuseparator'],{'component':!0,'box':!0,'menuitem':!0,'menuseparator':!0},['widget.menuseparator'],0,[Ext.menu,'Separator'],0);Ext.define('Ext.theme.neptune.menu.Separator',{override:'Ext.menu.Separator',border:!0});Ext.cmd.derive('Ext.menu.Menu',Ext.panel.Panel,{enableKeyNav:!0,allowOtherMenus:!1,ariaRole:'menu',floating:!0,constrain:!0,hidden:!0,hideMode:'visibility',ignoreParentClicks:!1,isMenu:!0,showSeparator:!0,minWidth:undefined,defaultMinWidth:120,defaultAlign:'tl-bl?',focusOnToFront:!1,bringParentToFront:!1,defaultFocus:':focusable',menuClickBuffer:0,baseCls:'x-menu',_iconSeparatorCls:'x-menu-icon-separator',_itemCmpCls:'x-menu-item-cmp',layout:{type:'vbox',align:'stretchmax',overflowHandler:'Scroller'},initComponent:function(){var a=this,d=['x-menu'],c=a.bodyCls?[a.bodyCls]:[],e=a.floating!==!1,b={element:'el',click:a.onClick,mouseover:a.onMouseOver,scope:a};if(Ext.supports.Touch){b.pointerdown=a.onMouseOver}a.on(b);a.on({beforeshow:a.onBeforeShow,scope:a});if(a.plain){d.push('x-menu-plain')}a.cls=d.join(' ');c.push('x-menu-body',Ext.dom.Element.unselectableCls);a.bodyCls=c.join(' ');if(e){if(a.minWidth===undefined){a.minWidth=a.defaultMinWidth}}else {a.hidden=!!a.initialConfig.hidden;a.constrain=!1}Ext.panel.Panel.prototype.initComponent.apply(this,arguments);Ext.override(a.getLayout(),{configureItem:a.configureItem})},initFloatConstrain:Ext.emptyFn,getInherited:function(){var a=Ext.panel.Panel.prototype.getInherited.call(this);a.hidden=this.hidden;return a},beforeRender:function(){var a=this;Ext.panel.Panel.prototype.beforeRender.apply(this,arguments);if(!a.getSizeModel().width.shrinkWrap){a.layout.align='stretch'}if(a.floating){a.ariaRenderAttributes=a.ariaRenderAttributes||{};a.ariaRenderAttributes['aria-expanded']=!!a.autoShow}},onBoxReady:function(){var a=this,c=a._iconSeparatorCls,b=a.focusableKeyNav;if(b){b.map.processEventScope=a;b.map.processEvent=function(a){if(a.keyCode===a.ESC){a.target=this.el.dom}return a};b.map.addBinding([{key:Ext.event.Event.ESC,handler:a.onEscapeKey,scope:a},{key:/[\w]/,handler:a.onShortcutKey,scope:a,shift:!1,ctrl:!1,alt:!1}])}else {a.escapeKeyNav=new Ext.util.KeyNav(a.el,{eventName:'keydown',scope:a,esc:a.onEscapeKey})}Ext.panel.Panel.prototype.onBoxReady.apply(this,arguments);if(a.showSeparator){a.iconSepEl=a.body.insertFirst({role:'presentation',cls:c+' '+c+'-'+a.ui,html:' '})}if(Ext.supports.MSPointerEvents||Ext.supports.PointerEvents){a.el.on({scope:a,click:a.preventClick,translate:!1})}a.mouseMonitor=a.el.monitorMouseLeave(100,a.onMouseLeave,a)},onFocusLeave:function(b){var a=this;Ext.panel.Panel.prototype.onFocusLeave.call(this,b);a.mixins.focusablecontainer.onFocusLeave.call(a,b);if(a.floating){a.hide()}},canActivateItem:function(a){return a&&a.isFocusable()},deactivateActiveItem:function(){var b=this,a=b.lastFocusedChild;if(a){a.blur()}},getItemFromEvent:function(d){var c=this,b=c.layout.getRenderTarget().dom,a=d.getTarget();while(a.parentNode!==b){a=a.parentNode;if(!a){return}}return Ext.getCmp(a.id)},lookupComponent:function(a){var b=this;if(typeof a==='string'){a=b.lookupItemFromString(a)}else {if(Ext.isObject(a)){a=b.lookupItemFromObject(a)}}if(!a.dock){a.minWidth=a.minWidth||b.minWidth}return a},lookupItemFromObject:function(a){var b=this;if(!a.isComponent){if(!a.xtype){a=Ext.create('Ext.menu.'+(Ext.isBoolean(a.checked)?'Check':'')+'Item',a)}else {a=Ext.ComponentManager.create(a,a.xtype)}}if(a.isMenuItem){a.parentMenu=b}return a},lookupItemFromString:function(a){return a==='separator'||a==='-'?new Ext.menu.Separator():new Ext.menu.Item({canActivate:!1,hideOnClick:!1,plain:!0,text:a})},configureItem:function(a){var c=this.owner,f='x-',e=c.ui,b,d;if(a.isMenuItem){a.setUI(e)}else {if(c.items.getCount()>1&&!a.rendered&&!a.dock){d=c._itemCmpCls;b=[d+' '+d+'-'+e];if(!c.plain&&(a.indent!==!1||a.iconCls==='no-icon')){b.push(f+'menu-item-indent-'+e)}if(a.rendered){a.el.addCls(b)}else {a.cls=(a.cls||'')+' '+b.join(' ')}a.$extraMenuCls=b}}this.callParent(arguments)},onRemove:function(a){Ext.panel.Panel.prototype.onRemove.call(this,a);if(!a.destroyed&&a.$extraMenuCls){a.el.removeCls(a.$extraMenuCls)}},onClick:function(b){var c=this,f=b.type,a,d,e=f==='keydown';if(c.disabled){b.stopEvent();return}a=c.getItemFromEvent(b);if(a&&a.isMenuItem){if(!a.menu||!c.ignoreParentClicks){d=a.onClick(b)}else {b.stopEvent()}if(a.menu&&d!==!1&&e){a.expandMenu(b,0)}}if(!a||a.disabled){a=undefined}c.fireEvent('click',c,a,b)},onDestroy:function(){var a=this;if(a.escapeKeyNav){a.escapeKeyNav.destroy()}a.parentMenu=a.ownerCmp=a.escapeKeyNav=null;if(a.rendered){a.el.un(a.mouseMonitor);Ext.destroy(a.iconSepEl)}Ext.menu.Manager.onHide(a);Ext.panel.Panel.prototype.onDestroy.apply(this,arguments)},onMouseLeave:function(a){if(this.disabled){return}this.fireEvent('mouseleave',this,a)},onMouseOver:function(c){var a=this,g=c.getRelatedTarget(),e=!a.el.contains(g),b=a.getItemFromEvent(c),d=a.parentMenu,f=a.ownerCmp;if(e&&d){d.setActiveItem(f);f.cancelDeferHide();d.mouseMonitor.mouseenter()}if(a.disabled){return}if(b){if(!b.containsFocus){b.focus()}if(b.expandMenu){b.expandMenu(c)}}if(e){a.fireEvent('mouseenter',a,c)}a.fireEvent('mouseover',a,b,c)},setActiveItem:function(a){var b=this;if(a&&a!==b.lastFocusedChild){b.focusChild(a,1)}},onEscapeKey:function(){if(this.floating){this.hide()}},onShortcutKey:function(h,g){var e=String.fromCharCode(g.getCharCode()),c=this.query('>[text]'),f=c.length,a=this.lastFocusedChild,d=Ext.Array.indexOf(c,a),b=d;for(;;){if(++b===f){b=0}a=c[b];if(b===d){return}if(a.text&&a.text[0].toUpperCase()===e){a.focus();return}}},onFocusableContainerTabKey:function(a){if(this.floating){this.hide()}},onFocusableContainerEnterKey:function(a){this.onClick(a)},onFocusableContainerSpaceKey:function(a){this.onClick(a)},onFocusableContainerLeftKey:function(a){a.preventDefault();if(this.parentMenu){this.ownerCmp.focus();this.hide()}},onFocusableContainerRightKey:function(b){var c=this,a=c.lastFocusedChild;b.preventDefault();if(a&&a.expandMenu){a.expandMenu(b,0)}},onBeforeShow:function(){if(Ext.Date.getElapsed(this.lastHide)tablepanel:not(hidden)>tableview');if(a){a.focus()}},focusRow:function(c){var b,a=this.getNavigationModel().lastFocused;b=a?a.view:this.normalView;b.focusRow(c)},focusCell:function(a){a.view.focusCell(a)},onRowFocus:function(){this.relayFn('onRowFocus',arguments)},isVisible:function(a){return this.ownerGrid.isVisible(a)},getFocusEl:function(){var b,a=this.getNavigationModel().lastFocused;b=a?a.view:this.normalView;return b.getFocusEl()},getCellInclusive:function(a,c){var d=a.column,b=this.lockedGrid.getColumnManager().getColumns().length;if(d>=b){a=Ext.apply({},a);a.column-=b;return this.normalView.getCellInclusive(a,c)}else {return this.lockedView.getCellInclusive(a,c)}},getHeaderByCell:function(a){if(a){return this.getVisibleColumnManager().getHeaderById(a.getAttribute('data-columnId'))}return !1},onRowSelect:function(){this.relayFn('onRowSelect',arguments)},onRowDeselect:function(){this.relayFn('onRowDeselect',arguments)},onCellSelect:function(a){a.column.getView().onCellSelect({record:a.record,column:a.column})},onCellDeselect:function(a){a.column.getView().onCellDeselect({record:a.record,column:a.column})},getCellByPosition:function(a,c){var e=this,b=a.view,d=a.column;if(b===e){a=(new Ext.grid.CellContext(d.getView())).setPosition(a.record,a.column)}return b.getCellByPosition(a,c)},getRecord:function(b){var a=this.lockedView.getRecord(b);if(!a){a=this.normalView.getRecord(b)}return a},scrollBy:function(){var a=this.normalView;a.scrollBy.apply(a,arguments)},ensureVisible:function(){var a=this.normalView;a.ensureVisible.apply(a,arguments)},disable:function(){this.relayFn('disable',arguments)},enable:function(){this.relayFn('enable',arguments)},addElListener:function(){this.relayFn('addElListener',arguments)},refreshNode:function(){this.relayFn('refreshNode',arguments)},addRowCls:function(){this.relayFn('addRowCls',arguments)},removeRowCls:function(){this.relayFn('removeRowCls',arguments)},destroy:function(){var a=this;a.rendered=!1;a.bindStore(null,!1,'dataSource');Ext.destroy(a.lockedViewEventRelayers,a.normalViewEventRelayers);a.lockedViewEventRelayers=a.normalViewEventRelayers=null;a.callParent();Ext.destroy(a.loadMask,a.navigationModel,a.selModel);a.lockedView.lockingPartner=a.normalView.lockingPartner=null;a.lockedGrid=a.lockedView=a.normalGrid=a.normalView=null;a.loadMask=a.navigationModel=a.selModel=a.headerCt=null;a.ownerGrid=a.storeListeners=null}},1,0,0,0,0,[[Ext.util.Observable.prototype.mixinId||Ext.util.Observable.$className,Ext.util.Observable],[Ext.util.StoreHolder.prototype.mixinId||Ext.util.StoreHolder.$className,Ext.util.StoreHolder],[Ext.util.Focusable.prototype.mixinId||Ext.util.Focusable.$className,Ext.util.Focusable]],[Ext.grid.locking,'View',Ext.grid,'LockingView'],function(){this.borrow(Ext.Component,['up']);this.borrow(Ext.view.AbstractView,['doFirstRefresh','applyFirstRefresh']);this.borrow(Ext.view.Table,['cellSelector','selectedCellCls','selectedItemCls'])});Ext.cmd.derive('Ext.grid.locking.Lockable',Ext.Base,{alternateClassName:'Ext.grid.Lockable',syncRowHeight:!0,headerCounter:0,scrollDelta:40,lockedGridCls:'x-grid-inner-locked',normalGridCls:'x-grid-inner-normal',lockingBodyCls:'x-grid-locking-body',unlockText:'Unlock',lockText:'Lock',bothCfgCopy:['hideHeaders','enableColumnHide','enableColumnMove','enableColumnResize','sortableColumns','multiColumnSort','columnLines','rowLines','variableRowHeight','numFromEdge','trailingBufferZone','leadingBufferZone','scrollToLoadBuffer','syncRowHeight'],normalCfgCopy:['scroll'],lockedCfgCopy:[],determineXTypeToCreate:function(g){var f=this,a,b,d,e,c;if(f.subGridXType){a=f.subGridXType}else {if(!g){return 'gridpanel'}b=this.getXTypes().split('/');d=b.length;e=b[d-1];c=b[d-2];if(c!=='tablepanel'){a=c}else {a=e}}return a},injectLockable:function(){this.focusable=!1;this.lockable=!0;this.hasView=!0;var a=this,q=Ext.getScrollbarSize(),l=q.width,o=a.store=Ext.StoreManager.lookup(a.store),d=a.lockedViewConfig,g=a.normalViewConfig,s=Ext.Object,m,i,b,c,e,n,f,h,j=a.viewConfig,r=j&&j.loadMask,u=r!==undefined?r:a.loadMask,p=a.bufferedRenderer,k=l>0&&Ext.supports.touchScroll!==2,t=a.getInherited().rtl;m=a.constructLockableFeatures();a.features=null;i=a.constructLockablePlugins();a.plugins=i.topPlugins;b={id:a.id+'-locked',$initParent:a,isLocked:!0,bufferedRenderer:p,ownerGrid:a,ownerLockable:a,xtype:a.determineXTypeToCreate(!0),store:o,reserveScrollbar:k,scrollable:{indicators:{x:!0,y:!1}},scrollerOwner:!1,animate:!1,border:!1,cls:a.lockedGridCls,isLayoutRoot:function(){return this.floatedFromCollapse||a.normalGrid.floatedFromCollapse},features:m.lockedFeatures,plugins:i.lockedPlugins};c={id:a.id+'-normal',$initParent:a,isLocked:!1,bufferedRenderer:p,ownerGrid:a,ownerLockable:a,xtype:a.determineXTypeToCreate(),store:o,reserveScrollbar:a.reserveScrollbar,scrollerOwner:!1,border:!1,cls:a.normalGridCls,isLayoutRoot:function(){return this.floatedFromCollapse||a.lockedGrid.floatedFromCollapse},features:m.normalFeatures,plugins:i.normalPlugins};a.addCls('x-grid-locked');Ext.copy(c,a,a.bothCfgCopy,!0);Ext.copy(b,a,a.bothCfgCopy,!0);Ext.copy(c,a,a.normalCfgCopy,!0);Ext.copy(b,a,a.lockedCfgCopy,!0);Ext.apply(c,a.normalGridConfig);Ext.apply(b,a.lockedGridConfig);for(e=0;e>#normalHeaderCt',items:e},j={itemId:'normalHeaderCt',stretchMaxPartner:'^^>>#lockedHeaderCt',items:f},l={locked:i,normal:j},g;if(Ext.isObject(b)){Ext.applyIf(i,b);Ext.applyIf(j,b);g=Ext.apply({},b);delete g.items;Ext.apply(c,g);b=b.items}c.constructing=!0;for(d=0,k=b.length;d0&&f){h.stopEvent();a+=e;d.setScrollY(a);b.normalGrid.getView().setScrollY(a);b.onNormalViewScroll()}}},onLockedViewScroll:function(){var f=this,e=f.lockedGrid.getView(),a=f.normalGrid.getView(),c=e.getScrollY(),g=a.getScrollY(),b,d;if(g!==c){a.setScrollY(c);if(a.bufferedRenderer){d=e.body.dom;b=a.body.dom;b.style.position='absolute';b.style.top=d.style.top}}},onNormalViewScroll:function(){var e=this,b=e.lockedGrid.getView(),c=e.normalGrid.getView(),f=b.getScrollY(),d=c.getScrollY(),a;if(d!==f){b.setScrollY(d);if(c.bufferedRenderer){a=b.body;if(a.dom){a.dom.style.position='absolute';a.translate(null,c.bufferedRenderer.bodyTop)}}}},syncRowHeights:function(){if(!this.destroyed){var f=this,b=f.normalGrid.getView(),a=f.lockedGrid.getView(),d=b.syncRowHeightBegin(),c=a.syncRowHeightBegin(),e;b.syncRowHeightMeasure(d);a.syncRowHeightMeasure(c);b.syncRowHeightFinish(d,c);a.syncRowHeightFinish(c,d);e=b.getScrollY();a.setScrollY(e)}},modifyHeaderCt:function(){var a=this;a.lockedGrid.headerCt.getMenuItems=a.getMenuItems(a.lockedGrid.headerCt.getMenuItems,!0);a.normalGrid.headerCt.getMenuItems=a.getMenuItems(a.normalGrid.headerCt.getMenuItems,!1);a.lockedGrid.headerCt.showMenuBy=Ext.Function.createInterceptor(a.lockedGrid.headerCt.showMenuBy,a.showMenuBy);a.normalGrid.headerCt.showMenuBy=Ext.Function.createInterceptor(a.normalGrid.headerCt.showMenuBy,a.showMenuBy)},onUnlockMenuClick:function(){this.unlock()},onLockMenuClick:function(){this.lock()},showMenuBy:function(f,g,c){var d=this.getMenu(),a=d.down('#unlockItem'),b=d.down('#lockItem'),e=a.prev();if(c.lockable===!1){e.hide();a.hide();b.hide()}else {e.show();a.show();b.show();if(!a.initialConfig.disabled){a.setDisabled(c.lockable===!1)}if(!b.initialConfig.disabled){b.setDisabled(!c.isLockable())}}},getMenuItems:function(d,b){var a=this,f=a.unlockText,h=a.lockText,g='x-hmenu-unlock',i='x-hmenu-lock',c=a.onUnlockMenuClick.bind(a),e=a.onLockMenuClick.bind(a);return function(){var a=d.call(this);a.push('-',{itemId:'unlockItem',iconCls:g,text:f,handler:c,disabled:!b});a.push({itemId:'lockItem',iconCls:i,text:h,handler:e,disabled:b});return a}},delaySyncLockedWidth:function(){var a=this,b=a.syncLockedWidthTask;if(!a.view.all.getCount()){return}if(!b){b=a.syncLockedWidthTask=new Ext.util.DelayedTask(a.syncLockedWidth,a)}b.delay(1)},syncLockedWidth:function(){var b=this,c=b.rendered,a=b.lockedGrid,g=a.view,d=b.normalGrid,e=a.getVisibleColumnManager().getColumns().length,f=d.getVisibleColumnManager().getColumns().length,h=b.syncLockedWidthTask;if(h){h.cancel()}Ext.suspendLayouts();if(f){d.show();if(e){if(c&&a.shrinkWrapColumns&&!a.headerCt.forceFit){delete a.flex;a.setWidth(a.headerCt.getTableWidth()+a.gridPanelBorderWidth)}a.addCls(b.lockedGridCls);a.show();if(a.split){b.child('splitter').show();b.addCls('x-grid-locked-split')}}else {if(c){a.getView().clearViewEl(!0)}a.hide();if(a.split){b.child('splitter').hide();b.removeCls('x-grid-locked-split')}}if(Ext.supports.touchScroll!==2&&Ext.Component.pendingLayouts){g.getScrollable().setX(!0)}if(c){b.ignoreMousewheel=g.scrollFlags.y}}else {d.hide();a.flex=1;delete a.width;a.removeCls(b.lockedGridCls);a.show();b.ignoreMousewheel=!0}Ext.resumeLayouts(!0);return [e,f]},onLockedHeaderSortChange:Ext.emptyFn,onNormalHeaderSortChange:Ext.emptyFn,lock:function(a,l,g){var e=this,i=e.normalGrid,b=e.lockedGrid,d=i.view,c=b.view,m=i.headerCt,h,k,j,f;a=a||m.getMenu().activeHeader;j=a.hasFocus;g=g||b.headerCt;k=a.ownerCt;if(!a.isLockable()){return}if(a.flex&&b.shrinkWrapColumns){a.width=a.getWidth();a.flex=null}Ext.suspendLayouts();if(b.hidden){if(!b.componentLayoutCounter){if(c.bufferedRenderer){c.bufferedRenderer.onViewResize(c,0,d.getHeight())}f=d.getScrollY()}b.show()}d.blockRefresh=c.blockRefresh=!0;a.ownerCmp=a.ownerCt;k.remove(a,!1);a.locked=!0;if(Ext.isDefined(l)){g.insert(l,a)}else {g.add(a)}d.blockRefresh=c.blockRefresh=!1;a.ownerCmp=null;h=e.syncLockedWidth();if(h[0]){b.getView().refreshView()}if(h[1]){i.getView().refreshView()}e.fireEvent('lockcolumn',e,a);Ext.resumeLayouts(!0);if(f){c.setScrollY(f);d.setScrollY(f)}if(j){a.focus()}},unlock:function(a,f,g){var b=this,e=b.normalGrid,d=b.lockedGrid,i=e.view,h=d.view,k=d.headerCt,c,j;if(!Ext.isDefined(f)){f=0}a=a||k.getMenu().activeHeader;j=a.hasFocus;g=g||e.headerCt;Ext.suspendLayouts();i.blockRefresh=h.blockRefresh=!0;a.ownerCmp=a.ownerCt;a.ownerCt.remove(a,!1);a.locked=!1;g.insert(f,a);i.blockRefresh=h.blockRefresh=!1;a.ownerCmp=null;c=b.syncLockedWidth();if(c[0]){d.getView().refreshView()}if(c[1]){e.getView().refreshView()}b.fireEvent('unlockcolumn',b,a);Ext.resumeLayouts(!0);if(j){a.focus()}},reconfigureLockable:function(a,f){var d=this,h=d.store,c=d.lockedGrid,e=d.normalGrid,b,g;if(a&&a!==h){a=Ext.data.StoreManager.lookup(a);d.store=a;c.view.blockRefresh=e.view.blockRefresh=!0;c.bindStore(a);b=c.view;b.store=a;if(!b.dataSource.isFeatureStore){b.dataSource=a}if(b.bufferedRenderer){b.bufferedRenderer.bindStore(a)}e.bindStore(a);b=e.view;b.store=a;if(!b.dataSource.isFeatureStore){b.dataSource=a}if(b.bufferedRenderer){b.bufferedRenderer.bindStore(a)}d.view.store=a;g=d.view.loadMask;if(g&&g.isLoadMask){g.bindStore(a)}d.view.bindStore(e.view.dataSource,!1,'dataSource');c.view.blockRefresh=e.view.blockRefresh=!1}if(f){c.reconfiguring=e.reconfiguring=!0;c.headerCt.removeAll();e.headerCt.removeAll();f=d.processColumns(f,c);c.headerCt.add(f.locked.items);e.headerCt.add(f.normal.items);c.reconfiguring=e.reconfiguring=!1;d.syncLockedWidth()}d.refreshCounter=c.view.refreshCounter},afterReconfigureLockable:function(){var a=this.lockedGrid.getView();if(this.refreshCounter===a.refreshCounter){this.view.refresh()}},constructLockableFeatures:function(){var b=this.features,a,e,c,d,f=0,g;if(b){if(!Ext.isArray(b)){b=[b]}c=[];d=[];g=b.length;for(;f0){a.onViewResize(b,null,e);if(c&&d.getCount()!==c.length){c.length=0;c.push.apply(c,a.store.getRange(d.startIndex,d.endIndex))}}}},beforeTableLayout:function(b){var a=this.view.body.dom;if(a){b.bodyHeight=a.offsetHeight;b.bodyWidth=a.offsetWidth}},afterTableLayout:function(d){var a=this,b=a.view,c;if(d.bodyHeight&&b.body.dom){delete a.rowHeight;a.refreshSize();c=b.body.dom.offsetHeight;if(c!==d.bodyHeight){a.onViewResize(b,null,b.el.lastBox.height);if(c=a.store.getCount()){a.setBodyTop(0)}else {if(a.bodyTop>a.scrollTop||a.bodyTop+cb){a.position=a.scrollTop=Math.max(b-a.bodyHeight,0);c.setScrollY(a.scrollTop)}if(a.bodyTop>b){c.body.translate(null,a.bodyTop=a.position)}if(c.getScrollable()){a.refreshScroller(c,b)}},refreshScroller:function(b,c){var a=b.getScrollable();if(a){if(a.setElementSize){a.setElementSize()}a.setSize({x:b.headerCt.getTableWidth(),y:c})}},setViewSize:function(c,o){var a=this,h=a.store,g=a.view,d=g.all,j=d.getCount(),e,f,b=a.view.lockingPartner&&a.view.lockingPartner.bufferedRenderer,i=j-c,n,m,l,k;if(b&&!o&&b.view.componentLayoutCounter){if(b.viewSize>c){c=b.viewSize}else {b.setViewSize(c,!0)}}i=j-c;if(i){a.scrollTop=g.getScrollY();a.viewSize=c;if(h.isBufferedStore){h.setViewSize(c)}if(j){k=h.getCount();e=d.startIndex;f=Math.min(e+c-1,k-1);if(e===d.startIndex&&f===d.endIndex){if(i<0){a.handleViewScroll(-1)}}else {if(b){b.disable()}if(i<0){if(k>j){h.getRange(d.endIndex+1,f,{callback:function(b,d){l=g.doAdd(b,d);g.fireEvent('itemadd',b,d,l);a.setBodyTop(a.bodyTop)}})}else {a.refreshView(0)}}else {e=d.endIndex-(i-1);f=d.endIndex;m=d.slice(e,f+1);d.removeRange(e,f,!0);if(g.hasListeners.itemremove){n=h.getRange(e,f);g.fireEvent('itemremove',n,e,m)}a.setBodyTop(a.bodyTop)}if(b){b.enable()}}}}return c},getViewRange:function(){var d=this,c=d.view.all,a=d.store,b=0;if(c.getCount()){b=c.startIndex}else {if(a.isBufferedStore){if(!a.currentPage){a.currentPage=1}b=c.startIndex=(a.currentPage-1)*(a.pageSize||1);a.currentPage=1}}if(a.data.getCount()){return a.getRange(b,b+(d.viewSize||a.defaultViewSize)-1)}else {return []}},onReplace:function(l,d,j,k){var a=this,c=a.view,b=c.all,i,g=b.getCount(),h=d+j.length-1,e=k.length-j.length,f=e*a.rowHeight;if(d>=b.startIndex+a.viewSize){a.refreshSize();return}if(g&&h=a.viewSize){b.moveBlock(e);a.refreshSize();i=b.startIndex;if(e>0){a.doNotMirror=!0;a.handleViewScroll(-1);a.doNotMirror=!1}if(b.startIndex===i){if(b.startIndex){a.setBodyTop(a.bodyTop+=f);c.suspendEvent('scroll');c.scrollBy(0,f);c.resumeEvent('scroll');a.position=a.scrollTop=c.getScrollY()}}else {c.suspendEvent('scroll');c.scrollBy(0,(i-b.startIndex)*a.rowHeight);c.resumeEvent('scroll')}c.refreshSize(b.getCount()!==g);return}if(g&&d>b.endIndex){a.refreshSize();if(e>0){a.onRangeFetched(null,b.startIndex,Math.min(l.getCount(),b.startIndex+a.viewSize)-1,null,!0)}c.refreshSize(b.getCount()!==g);return}if(d0?1:-1;if(Math.abs(c)>=20||b!==a.lastScrollDirection){a.lastScrollDirection=b;a.handleViewScroll(a.lastScrollDirection)}}},onViewScrollEnd:function(){if(this.needsPointerEventsFix){this.view.body.dom.style.pointerEvents=''}},handleViewScroll:function(h){var a=this,d=a.view.all,g=a.store,f=a.viewSize,e=g.getCount()-1,b,c;if(h===-1){if(d.startIndex){if(a.topOfViewCloseToEdge()){b=Math.max(0,a.getLastVisibleRowIndex()+a.trailingBufferZone-f)}}}else {if(d.endIndexa.scrollTop-a.numFromEdge*a.rowHeight}else {return a.getFirstVisibleRowIndex()-a.view.all.startIndexd){a=c-d+1}}}if(a===0&&c===0&&e===0){b.doRefreshView([],0,0)}else {g.getRange(a,c,{callback:b.doRefreshView,scope:b})}},doRefreshView:function(i,h,p,q){var a=this,b=a.view,c=b.all,l=c.startIndex,m=c.endIndex,e,f,n=c.getCount(),o,k=h!==c.startIndex,g,d,j;if(b.refreshCounter){if(b.hasListeners.beforerefresh&&b.fireEvent('beforerefresh',b)===!1){return}b.refreshing=a.refreshing=!0;j=b.saveFocusState();b.clearViewEl(!0);b.refreshCounter++;if(i.length){o=b.doAdd(i,h);if(k){e=c.item(l,!0);f=c.item(m,!0);if(e){d=-e.offsetTop}else {if(f){d=c.last(!0).offsetTop-f.offsetTop}}if(d){a.bodyTop=Math.max(a.bodyTop+d,0);a.scrollTop=a.bodyTop?a.scrollTop+d:0}else {a.bodyTop=g=h*a.rowHeight;a.scrollTop=Math.max(g-a.rowHeight*(gc.endIndex){r=c.startIndex-e;b.clearViewEl(!0);g=b.doAdd(h,e);b.fireEvent('itemadd',h,e,g);for(o=0;oc.endIndex||jp){d=a.scrollTop-a.rowHeight*p}}b.clearViewEl(!0);a.teleported=!1}if(!c.getCount()){g=b.doAdd(h,e);b.fireEvent('itemadd',h,e,g)}else {if(j>c.endIndex){l=Math.max(e-c.startIndex,0);if(k){i=c.item(c.startIndex+l,!0).offsetTop}g=c.scroll(Ext.Array.slice(h,c.endIndex+1-e),1,l);if(k){d=a.bodyTop+i}else {d=m}}else {l=Math.max(c.endIndex-j,0);u=c.startIndex;g=c.scroll(Ext.Array.slice(h,0,c.startIndex-e),-1,l);if(k){d=a.bodyTop-c.item(u,!0).offsetTop;if(!c.startIndex){if(d){b.setScrollY(a.position=a.scrollTop-=d);d=0}}else {if(d<0){i=c.startIndex*a.rowHeight;b.setScrollY(a.position=a.scrollTop+=i);d=a.bodyTop+i}}}else {d=m}}}a.position=a.scrollTop}if(t&&!v.contains(q)){n=b.actionableMode?b.actionPosition:b.lastFocused;if(n&&n.column){b.onFocusLeave({});n.column.focus()}}d=Math.max(Math.floor(d),0);if(b.positionBody){a.setBodyTop(d)}if(g&&f&&!f.disabled){f.scrollTop=f.position=a.scrollTop;if(f.view.ownerCt.isVisible()){s=f.onRangeFetched(null,e,j,x,!0);if(b.ownerGrid.syncRowHeight||f.variableRowHeight!==k){a.syncRowHeights(g,s);a.bodyHeight=b.body.dom.offsetHeight}}if(f.bodyTop!==d){f.setBodyTop(d)}f.view.setScrollY(a.scrollTop)}return g},syncRowHeights:function(b,e){var d=this,c=0,f=1,i=[],h=[],j=Ext.grid.locking.RowSynchronizer,a,g;if(b&&e){c=b.length;f=e.length}if(c!==f){b=d.view.all.slice();e=d.view.lockingPartner.all.slice();c=f=b.length}for(a=0;ae||i+a.bodyHeightc||j+a.bodyHeightc){return a.getLastVisibleRowIndex(f,b-1,e,c)}k=i+l[b].offsetHeight;if(k>=c){return b}else {if(b!==d){return a.getLastVisibleRowIndex(b+1,d,e,c)}}}return a.getFirstVisibleRowIndex()+Math.ceil(h/a.rowHeight)},getScrollHeight:function(){var a=this,j=a.view,d=j.all,i=a.store,c=i.getCount(),g=d.getCount(),h,f,e,b;if(!c){return 0}if(!a.hasOwnProperty('rowHeight')){if(g){if(a.variableRowHeight){a.rowHeight=Math.floor(a.bodyHeight/g)}else {h=d.first();f=h.getHeight();if(Ext.isIE8){e=h.getBorderWidth('b');if(e>0){f-=e}}a.rowHeight=f}}else {delete a.rowHeight}}if(a.variableRowHeight){if(d.endIndex===c-1){b=a.bodyTop+a.bodyHeight-1}else {b=Math.floor((c-g)*a.rowHeight)+a.bodyHeight;b+=a.bodyTop-d.startIndex*a.rowHeight}}else {b=Math.floor(c*a.rowHeight)}return a.scrollHeight=b},attemptLoad:function(b,c){var a=this;if(a.scrollToLoadBuffer){if(!a.loadTask){a.loadTask=new Ext.util.DelayedTask(a.doAttemptLoad,a,[])}a.loadTask.delay(a.scrollToLoadBuffer,a.doAttemptLoad,a,[b,c])}else {a.doAttemptLoad(b,c)}},cancelLoad:function(){if(this.loadTask){this.loadTask.cancel()}},doAttemptLoad:function(b,c){var a=this;if(!a.destroyed){a.store.getRange(b,c,{loadId:++a.loadId,callback:function(e,f,g,d){if(d.loadId===a.loadId){a.onRangeFetched(e,f,g,d)}},fireEvent:!1})}},destroy:function(){var a=this,b=a.view;a.cancelLoad();if(b&&b.el){b.un('scroll',a.onViewScroll,a)}if(a.store){a.unbindStore()}a.viewListeners=a.gridListeners=a.view=a.grid=Ext.destroy(a.viewListeners,a.stretcher,a.gridListeners);Ext.plugin.Abstract.prototype.destroy.call(this)}},0,0,0,0,['plugin.bufferedrenderer'],0,[Ext.grid.plugin,'BufferedRenderer'],function(a){if(Ext.supports.Touch){a.prototype.leadingBufferZone=a.prototype.trailingBufferZone=2;a.prototype.numFromEdge=1}});Ext.cmd.derive('Ext.util.Queue',Ext.Base,{constructor:function(){this.clear()},add:function(b){var a=this,c=a.getKey(b);if(!a.map[c]){++a.length;a.items.push(b);a.map[c]=b}return b},clear:function(){var a=this,b=a.items;a.items=[];a.map={};a.length=0;return b},contains:function(b){var a=this.getKey(b);return this.map.hasOwnProperty(a)},getCount:function(){return this.length},getKey:function(a){return a.id},remove:function(b){var a=this,e=a.getKey(b),d=a.items,c;if(a.map[e]){c=Ext.Array.indexOf(d,b);Ext.Array.erase(d,c,1);delete a.map[e];--a.length}return b}},1,0,0,0,0,0,[Ext.util,'Queue'],0);Ext.cmd.derive('Ext.layout.ContextItem',Ext.Base,{heightModel:null,widthModel:null,sizeModel:null,optOut:!1,ownerSizePolicy:null,boxChildren:null,boxParent:null,children:[],dirty:null,dirtyCount:0,hasRawContent:!0,isContextItem:!0,isTopLevel:!1,consumersContentHeight:0,consumersContentWidth:0,consumersContainerHeight:0,consumersContainerWidth:0,consumersHeight:0,consumersWidth:0,ownerCtContext:null,remainingChildDimensions:0,props:null,state:null,wrapsComponent:!1,constructor:function(s){var a=this,o=Ext.layout.SizeModel.sizeModels,l=o.configured,g=o.shrinkWrap,r,c,f,d,k,i,b,p,m,q,n,h,e,j;Ext.apply(a,s);b=a.target;r=a.el;a.id=b.id;a.flushedProps={};a.props=k={};a.styles={};if(!b.isComponent){c=r.lastBox}else {a.wrapsComponent=!0;a.framing=b.frameSize||null;a.isComponentChild=b.ownerLayout&&b.ownerLayout.isComponentLayout;c=b.lastBox;f=b.ownerCt;if(f&&(d=f.el&&a.context.items[f.el.id])){a.ownerCtContext=d}a.sizeModel=i=b.getSizeModel(d&&d.widthModel.pairsByHeightOrdinal[d.heightModel.ordinal]);a.widthModel=h=i.width;a.heightModel=e=i.height;if(c&&c.invalid===!1){q=b.width===(p=c.width);n=b.height===(m=c.height);if(h===g&&e===g){j=!0}else {if(h===l&&q){j=e===g||e===l&&n}}if(j){a.optOut=!0;k.width=p;k.height=m}}}a.lastBox=c},init:function(r,i){var a=this,c=a.props,e=a.dirty,b=a.ownerCtContext,h=a.target.ownerLayout,j=!a.state,s=r||j,n,l,t,q,k,d,o=a.heightModel,p=a.widthModel,f,g,m=0;a.dirty=a.invalid=!1;a.props={};a.remainingChildDimensions=0;if(a.boxChildren){a.boxChildren.length=0}if(!j){a.clearAllBlocks('blocks');a.clearAllBlocks('domBlocks')}if(!a.wrapsComponent){return s}d=a.target;a.state={};if(j){if(d.beforeLayout&&d.beforeLayout!==Ext.emptyFn){d.beforeLayout()}if(!b&&(q=d.ownerCt)){b=a.context.items[q.el.id]}if(b){a.ownerCtContext=b;a.isBoxParent=h&&h.isItemBoxParent(a)}else {a.isTopLevel=!0}a.frameBodyContext=a.getEl('frameBody')}else {b=a.ownerCtContext;a.isTopLevel=!b;n=a.children;for(l=0,t=n.length;l0);if(r){a.widthModel=a.heightModel=null;k=d.getSizeModel(b&&b.widthModel.pairsByHeightOrdinal[b.heightModel.ordinal]);if(j){a.sizeModel=k}a.widthModel=k.width;a.heightModel=k.height;if(b&&!a.isComponentChild){if(h.needsItemSize||!d.liquidLayout){b.remainingChildDimensions+=2}else {if(a.widthModel.calculated){++b.remainingChildDimensions}if(a.heightModel.calculated){++b.remainingChildDimensions}}}}else {if(c){a.recoverProp('x',c,e);a.recoverProp('y',c,e);if(a.widthModel.calculated){a.recoverProp('width',c,e)}else {if('width' in c){++m}}if(a.heightModel.calculated){a.recoverProp('height',c,e)}else {if('height' in c){++m}}if(b&&!a.isComponentChild){b.remainingChildDimensions+=m}}}if(c&&h&&h.manageMargins){a.recoverProp('margin-top',c,e);a.recoverProp('margin-right',c,e);a.recoverProp('margin-bottom',c,e);a.recoverProp('margin-left',c,e)}if(i){f=i.heightModel;g=i.widthModel;if(g&&f&&p&&o){if(p.shrinkWrap&&o.shrinkWrap){if(g.constrainedMax&&f.constrainedMin){f=null}}}if(g){a.widthModel=g}if(f){a.heightModel=f}if(i.state){Ext.apply(a.state,i.state)}}return s},initContinue:function(f){var b=this,a=b.ownerCtContext,g=b.target,c=b.widthModel,e=g.getInherited(),d;if(c.fixed){e.inShrinkWrapTable=!1}else {delete e.inShrinkWrapTable}if(f){if(a&&c.shrinkWrap){d=a.isBoxParent?a:a.boxParent;if(d){d.addBoxChild(b)}}else {if(c.natural){b.boxParent=a}}}return f},initDone:function(d){var a=this,b=a.props,c=a.state;if(a.remainingChildDimensions===0){b.containerChildrenSizeDone=!0}if(d){b.containerLayoutDone=!0}if(a.boxChildren&&a.boxChildren.length&&a.widthModel.shrinkWrap){a.el.setWidth(10000);c.blocks=(c.blocks||0)+1}},initAnimation:function(){var a=this,b=a.target,c=a.ownerCtContext;if(c&&c.isTopLevel){a.animatePolicy=b.ownerLayout.getAnimatePolicy(a)}else {if(!c&&b.isCollapsingOrExpanding&&b.animCollapse){a.animatePolicy=b.componentLayout.getAnimatePolicy(a)}}if(a.animatePolicy){a.context.queueAnimation(a)}},addBlock:function(f,a,e){var b=this,d=b[f]||(b[f]={}),c=d[e]||(d[e]={});if(!c[a.id]){c[a.id]=a;++a.blockCount;++b.context.blockCount}},addBoxChild:function(a){var d=this,b,c=a.widthModel;a.boxParent=this;a.measuresBox=c.shrinkWrap?a.hasRawContent:c.natural;if(a.measuresBox){b=d.boxChildren;if(b){b.push(a)}else {d.boxChildren=[a]}}},addPositionStyles:function(b,c){var d=c.x,e=c.y,a=0;if(d!==undefined){b.left=d+'px';++a}if(e!==undefined){b.top=e+'px';++a}return a},addTrigger:function(c,e){var b=this,h=e?'domTriggers':'triggers',f=b[h]||(b[h]={}),g=b.context,a=g.currentLayout,d=f[c]||(f[c]={});if(!d[a.id]){d[a.id]=a;++a.triggerCount;d=g.triggers[e?'dom':'data'];(d[a.id]||(d[a.id]=[])).push({item:this,prop:c});if(b.props[c]!==undefined){if(!e||!(b.dirty&&c in b.dirty)){++a.firedTriggers}}}},boxChildMeasured:function(){var a=this,b=a.state,c=b.boxesMeasured=(b.boxesMeasured||0)+1;if(c===a.boxChildren.length){b.clearBoxWidth=1;++a.context.progressCount;a.markDirty()}},borderNames:['border-top-width','border-right-width','border-bottom-width','border-left-width'],marginNames:['margin-top','margin-right','margin-bottom','margin-left'],paddingNames:['padding-top','padding-right','padding-bottom','padding-left'],trblNames:['top','right','bottom','left'],cacheMissHandlers:{borderInfo:function(b){var a=b.getStyles(b.borderNames,b.trblNames);a.width=a.left+a.right;a.height=a.top+a.bottom;return a},marginInfo:function(b){var a=b.getStyles(b.marginNames,b.trblNames);a.width=a.left+a.right;a.height=a.top+a.bottom;return a},paddingInfo:function(b){var c=b.frameBodyContext||b,a=c.getStyles(b.paddingNames,b.trblNames);a.width=a.left+a.right;a.height=a.top+a.bottom;return a}},checkCache:function(a){return this.cacheMissHandlers[a](this)},clearAllBlocks:function(c){var a=this[c],b;if(a){for(b in a){this.clearBlocks(c,b)}}},clearBlocks:function(g,f){var c=this[g],b=c&&c[f],d,a,e;if(b){delete c[f];d=this.context;for(e in b){a=b[e];--d.blockCount;if(!--a.blockCount&&!a.pending&&!a.done){d.queueLayout(a)}}}},block:function(b,a){this.addBlock('blocks',b,a)},domBlock:function(b,a){this.addBlock('domBlocks',b,a)},fireTriggers:function(g,e){var c=this[g],b=c&&c[e],f=this.context,a,d;if(b){for(d in b){a=b[d];++a.firedTriggers;if(!a.done&&!a.blockCount&&!a.pending){f.queueLayout(a)}}}},flush:function(){var a=this,d=a.dirty,b=a.state,c=a.el;a.dirtyCount=0;if('attributes' in a){c.set(a.attributes);delete a.attributes}if('innerHTML' in a){c.innerHTML=a.innerHTML;delete a.innerHTML}if(b&&b.clearBoxWidth){b.clearBoxWidth=0;a.el.setStyle('width',null);if(!--b.blocks){a.context.queueItemLayouts(a)}}if(d){delete a.dirty;a.writeProps(d,!0)}},flushAnimations:function(){var b=this,k=b.previousSize,a,h,l,f,d,g,e,m,c,j,i;if(k){a=b.target;h=a.getAnimationProps();l=h.duration;f=Ext.Object.getKeys(b.animatePolicy);d=Ext.apply({},{from:{},to:{},duration:l||Ext.fx.Anim.prototype.duration},h);for(g=0,e=0,m=f.length;e0},runLayout:function(a){var b=this,c=b.getCmp(a.owner);a.pending=!1;if(c.state.blocks){return}a.done=!0;++a.calcCount;++b.calcCount;a.calculate(c);if(a.done){b.layoutDone(a);if(a.completeLayout){b.queueCompletion(a)}if(a.finalizeLayout){b.queueFinalize(a)}}else {if(!a.pending&&!a.invalid&&!(a.blockCount+a.triggerCount-a.firedTriggers)){b.queueLayout(a)}}},setItemSize:function(a,g,f){var b=a,c=1,e,d;if(a.isComposite){b=a.elements;c=b.length;a=b[0]}else {if(!a.dom&&!a.el){c=b.length;a=b[0]}}for(d=0;da){a=d.weight}}},this);return a},getSplitterTarget:function(b){var a=b.collapseTarget;if(a&&a.collapsed){return a.placeholder||a}return a},isItemBoxParent:function(a){return !0},isItemShrinkWrap:function(a){return !0},insertSplitter:function(a,f,e,d){var c=a.region,b=Ext.apply({xtype:'bordersplitter',collapseTarget:a,id:a.id+'-splitter',hidden:e,canResize:a.splitterResize!==!1,splitterFor:a,synthetic:!0},d),g=f+(c==='south'||c==='east'?0:1);if(a.collapseMode==='mini'){b.collapsedCls=a.collapsedCls}a.splitter=this.owner.add(g,b)},getMoveAfterIndex:function(b){var a=Ext.layout.container.Container.prototype.getMoveAfterIndex.apply(this,arguments);if(b.splitter){a++}return a},moveItemBefore:function(c,a){var b;if(a&&a.splitter){b=a.region;if(b==='south'||b==='east'){a=a.splitter}}return Ext.layout.container.Container.prototype.moveItemBefore.call(this,c,a)},onAdd:function(a,i){var b=this,d=a.placeholderFor,f=a.region,e,c,g,h;Ext.layout.container.Container.prototype.onAdd.apply(this,arguments);if(f){Ext.apply(a,b.regionFlags[f]);if(b.owner.isViewport){a.isViewportBorderChild=!0}if(a.initBorderRegion){a.initBorderRegion()}e=f==='center';if(e){b.centerRegion=a}else {c=a.split;g=!!a.hidden;if(typeof c==='object'){h=c;c=!0}if((a.isHorz||a.isVert)&&(c||a.collapseMode==='mini')){b.insertSplitter(a,i,g||!c,h)}}if(!e&&!a.hasOwnProperty('collapseMode')){a.collapseMode=b.panelCollapseMode}if(!a.hasOwnProperty('animCollapse')){if(a.collapseMode!=='placeholder'){a.animCollapse=!1}else {a.animCollapse=b.panelCollapseAnimate}}}else {if(d){Ext.apply(a,b.regionFlags[d.region]);a.region=d.region;a.weight=d.weight}}},onDestroy:function(){this.centerRegion=null;Ext.layout.container.Container.prototype.onDestroy.call(this)},onRemove:function(a,f){var d=this,h=a.region,e=a.splitter,c=d.owner,g=c.destroying,b;if(h){if(a.isCenter){d.centerRegion=null}delete a.isCenter;delete a.isHorz;delete a.isVert;if(e&&!c.destroying){c.doRemove(e,!0)}delete a.splitter}Ext.layout.container.Container.prototype.onRemove.apply(this,arguments);if(!g&&!f&&a.rendered){b=a.getEl();if(b){b.setStyle('top','');b.setStyle(d.horzPositionProp,'')}}},regionMeta:{center:{splitterDelta:0},north:{splitterDelta:1},south:{splitterDelta:-1},west:{splitterDelta:1},east:{splitterDelta:-1}},regionFlags:{center:{isCenter:!0,isHorz:!1,isVert:!1},north:{isCenter:!1,isHorz:!1,isVert:!0,collapseDirection:'top'},south:{isCenter:!1,isHorz:!1,isVert:!0,collapseDirection:'bottom'},west:{isCenter:!1,isHorz:!0,isVert:!1,collapseDirection:'left'},east:{isCenter:!1,isHorz:!0,isVert:!1,collapseDirection:'right'}},setupSplitterNeighbors:function(l){var i={},m=l.length,k=this.touchedRegions,h,b,j,g,d,a,f,e,c;for(h=0;h{%this.renderBody(out, values)%}'],targetElCls:'x-center-target',beginLayout:function(b){var h=this,f=h.percentRe,e,g,d,c,a,j,i;Ext.layout.container.Fit.prototype.beginLayout.call(this,b);e=b.childItems;for(d=0,g=e.length;dm){a=m}}if(a-d<2){return null}c=new Ext.util.Region(v,t,s,u);i.constraintAdjusters[i.getCollapseDirection()](c,d,a,e);i.dragInfo={minRange:d,maxRange:a,targetSize:q};return c},constraintAdjusters:{left:function(a,c,b,d){a[0]=a.x=a.left=a.right+c;a.right+=b+d.getWidth()},top:function(a,c,b,d){a[1]=a.y=a.top=a.bottom+c;a.bottom+=b+d.getHeight()},bottom:function(a,c,b,d){a.bottom=a.top-c;a.top-=b+d.getHeight()},right:function(a,c,b,d){a.right=a.left-c;a[0]=a.x=a.left=a.x-b+d.getWidth()}},onBeforeStart:function(h){var c=this,f=c.splitter,d=f.collapseTarget,e=f.neighbors,g=e.length,a,b;if(d.collapsed){return !1}for(a=0;ad){a.minWidth=a.el.getWidth()*c}else {a.minHeight=a.el.getHeight()*d}}if(a.throttle){e=Ext.Function.createThrottled(function(){Ext.resizer.ResizeTracker.prototype.resize.apply(a,arguments)},a.throttle);a.resize=function(f,d,c){if(c){Ext.resizer.ResizeTracker.prototype.resize.apply(a,arguments)}else {e.apply(null,arguments)}}}},onBeforeStart:function(a){this.startBox=this.target.getBox()},getProxy:function(){var a=this;if(!a.dynamic&&!a.proxy){a.proxy=a.createProxy(a.target||a.el);a.hideProxy=!0}if(a.proxy){a.proxy.show();return a.proxy}},createProxy:function(a){var b,c=this.proxyCls;if(a.isComponent){b=a.getProxy().addCls(c)}else {b=a.createProxy({tag:'div',role:'presentation',cls:c,id:a.id+'-rzproxy'},Ext.getBody())}b.removeCls('x-proxy-el');return b},onStart:function(a){this.activeResizeHandle=Ext.get(this.getDragTarget().id);if(!this.dynamic){this.resize(this.startBox)}},onMouseDown:function(c,b){var a=Ext.fly(b.parentNode);Ext.dd.DragTracker.prototype.onMouseDown.apply(this,arguments);if(a&&a.shim){a.maskIframes()}},onMouseUp:function(b){var a=Ext.fly(this.dragTarget.parentNode);Ext.dd.DragTracker.prototype.onMouseUp.apply(this,arguments);if(a&&a.shim){a.unmaskIframes()}},onDrag:function(a){if(this.dynamic||this.proxy){this.updateDimensions(a)}},updateDimensions:function(s,r){var c=this,h=c.activeResizeHandle.region,d=c.getOffset(c.constrainTo?'dragTarget':null),b=c.startBox,n,f=0,e=0,k,j,l=0,m=0,q,i,g,a,o,p;h=c.convertRegionName(h);switch(h){case 'south':e=d[1];g=2;break;case 'north':e=-d[1];m=-e;g=2;break;case 'east':f=d[0];g=1;break;case 'west':f=-d[0];l=-f;g=1;break;case 'northeast':e=-d[1];m=-e;f=d[0];i=[b.x,b.y+b.height];g=3;break;case 'southeast':e=d[1];f=d[0];i=[b.x,b.y];g=3;break;case 'southwest':f=-d[0];l=-f;e=d[1];i=[b.x+b.width,b.y];g=3;break;case 'northwest':e=-d[1];m=-e;f=-d[0];l=-f;i=[b.x+b.width,b.y+b.height];g=3;break;}a={width:b.width+f,height:b.height+e,x:b.x+l,y:b.y+m};k=Ext.Number.snap(a.width,c.widthIncrement);j=Ext.Number.snap(a.height,c.heightIncrement);if(k!==a.width||j!==a.height){switch(h){case 'northeast':a.y-=j-a.height;break;case 'north':a.y-=j-a.height;break;case 'southwest':a.x-=k-a.width;break;case 'west':a.x-=k-a.width;break;case 'northwest':a.x-=k-a.width;a.y-=j-a.height;}a.width=k;a.height=j}if(a.widthc.maxWidth){a.width=Ext.Number.constrain(a.width,c.minWidth,c.maxWidth);if(l){a.x=b.x+(b.width-a.width)}}else {c.lastX=a.x}if(a.heightc.maxHeight){a.height=Ext.Number.constrain(a.height,c.minHeight,c.maxHeight);if(m){a.y=b.y+(b.height-a.height)}}else {c.lastY=a.y}if(c.preserveRatio||s.shiftKey){n=c.startBox.width/c.startBox.height;o=Math.min(Math.max(c.minHeight,a.width/n),c.maxHeight);p=Math.min(Math.max(c.minWidth,a.height*n),c.maxWidth);if(g===1){a.height=o}else {if(g===2){a.width=p}else {q=Math.abs(i[0]-this.lastXY[0])/Math.abs(i[1]-this.lastXY[1]);if(q>n){a.height=o}else {a.width=p}if(h==='northeast'){a.y=b.y-(a.height-b.height)}else {if(h==='northwest'){a.y=b.y-(a.height-b.height);a.x=b.x-(a.width-b.width)}else {if(h==='southwest'){a.x=b.x-(a.width-b.width)}}}}}}c.setPosition=a.x!==c.startBox.x||a.y!==c.startBox.y;c.resize(a,r)},resize:function(b,e){var a=this,c,d=a.setPosition;if(a.dynamic||!a.dynamic&&e){if(d){a.target.setBox(b)}else {a.target.setSize(b.width,b.height)}}if(!e){c=a.getProxy();if(c&&c!==a.target){if(d||a.hideProxy){c.setBox(b)}else {c.setSize(b.width,b.height)}}}},onEnd:function(a){this.updateDimensions(a,!0);if(this.proxy&&this.hideProxy){this.proxy.hide()}},convertRegionName:function(a){return a}},1,0,0,0,0,0,[Ext.resizer,'ResizeTracker'],0);Ext.cmd.derive('Ext.resizer.Resizer',Ext.Base,{alternateClassName:'Ext.Resizable',handleCls:'x-resizable-handle',overCls:'x-resizable-handle-over',pinnedCls:'x-resizable-pinned',wrapCls:'x-resizable-wrap',wrappedCls:'x-resizable-wrapped',delimiterRe:/(?:\s*[,;]\s*)|\s+/,dynamic:!0,handles:'s e se',height:null,width:null,heightIncrement:0,widthIncrement:0,minHeight:20,minWidth:20,maxHeight:10000,maxWidth:10000,pinned:!1,preserveRatio:!1,transparent:!1,possiblePositions:{n:'north',s:'south',e:'east',w:'west',se:'southeast',sw:'southwest',nw:'northwest',ne:'northeast'},ariaRole:'presentation',constructor:function(e){var a=this,d=a.handles,q=Ext.dom.Element.unselectableCls,h=[],b,k,i,m,p,c,f,n,l,g,o,j;if(Ext.isString(e)||Ext.isElement(e)||e.dom){b=e;e=arguments[1]||{};e.target=b}a.mixins.observable.constructor.call(a,e);b=a.target;if(b){if(b.isComponent){b.addClsWithUI('resizable');if(b.minWidth){a.minWidth=b.minWidth}if(b.minHeight){a.minHeight=b.minHeight}if(b.maxWidth){a.maxWidth=b.maxWidth}if(b.maxHeight){a.maxHeight=b.maxHeight}if(b.floating){if(!a.hasOwnProperty('handles')){a.handles='n ne e se s sw w nw'}}a.el=b.getEl()}else {b=a.el=a.target=Ext.get(b)}}else {b=a.target=a.el=Ext.get(a.el)}a.el.addCls(Ext.Component.prototype.borderBoxCls);if(Ext.isNumber(a.width)){a.width=Ext.Number.constrain(a.width,a.minWidth,a.maxWidth)}if(Ext.isNumber(a.height)){a.height=Ext.Number.constrain(a.height,a.minHeight,a.maxHeight)}if(a.width!==null||a.height!==null){a.target.setSize(a.width,a.height)}m=a.el.dom.tagName.toUpperCase();if(m==='TEXTAREA'||m==='IMG'||m==='TABLE'){a.originalTarget=a.target;g=b.isComponent?b.getEl():b;a.el.addCls(a.wrappedCls);a.target=a.el=a.el.wrap({role:'presentation',cls:a.wrapCls,id:a.el.id+'-rzwrap',style:g.getStyle(['margin-top','margin-bottom'])});o=g.getPositioning();a.el.setPositioning(o);g.clearPositioning();l=g.getBox();if(o.position!=='absolute'){l.x=0;l.y=0}a.el.setBox(l);g.setStyle('position','absolute');a.isTargetWrapped=!0}a.el.position();if(a.pinned){a.el.addCls(a.pinnedCls)}a.resizeTracker=new Ext.resizer.ResizeTracker({disabled:a.disabled,target:b,el:a.el,constrainTo:a.constrainTo,handleCls:a.handleCls,overCls:a.overCls,throttle:a.throttle,proxy:a.originalTarget?a.el:null,dynamic:a.originalTarget?!0:a.dynamic,originalTarget:a.originalTarget,delegate:'.'+a.handleCls,preserveRatio:a.preserveRatio,heightIncrement:a.heightIncrement,widthIncrement:a.widthIncrement,minHeight:a.minHeight,maxHeight:a.maxHeight,minWidth:a.minWidth,maxWidth:a.maxWidth});a.resizeTracker.on({mousedown:a.onBeforeResize,drag:a.onResize,dragend:a.onResizeEnd,scope:a});if(a.handles==='all'){a.handles='n s e w ne nw se sw'}d=a.handles=a.handles.split(a.delimiterRe);i=a.possiblePositions;p=d.length;k=a.handleCls+' '+a.handleCls+'-{0}';if(a.target.isComponent){j=a.target.baseCls;k+=' '+j+'-handle '+j+'-handle-{0}';if(Ext.supports.CSS3BorderRadius){k+=' '+j+'-handle-{0}-br'}}for(c=0;c')}}Ext.DomHelper.append(a.el,h.join(''));h.length=0;for(c=0;c-1){this.doSelect(a.record,!1,b)}},onCellDeselect:function(a,b){if(a&&a.rowIdx!==undefined){this.doDeselect(a.record,b)}},onSelectChange:function(g,f,e,h){var b=this,a,c,d;if(f){a=b.nextSelection;c='select'}else {a=b.selection;c='deselect'}d=a.view||b.primaryView;if((e||b.fireEvent('before'+c,b,g,a.rowIdx,a.colIdx))!==!1&&h()!==!1){if(f){d.onCellSelect(a)}else {d.onCellDeselect(a);delete b.selection}if(!e){b.fireEvent(c,b,g,a.rowIdx,a.colIdx)}}},refresh:function(){var b=this.getPosition(),a;if(b&&(a=this.store.indexOf(this.selected.last()))!==-1){b.rowIdx=a}},onColumnMove:function(b,d,c,e){var a=b.up('tablepanel');if(a){this.onViewRefresh(a.view)}},onUpdate:function(c){var a=this,b;if(a.isSelected(c)){b=a.selecting?a.nextSelection:a.selection;a.view.onCellSelect(b)}},onViewRefresh:function(d){var f=this,b=f.getPosition(),g,c=d.headerCt,e,a;if(b&&b.view===d){e=b.record;a=b.column;if(!a.isDescendantOf(c)){a=c.queryById(a.id)||c.down('[text="'+a.text+'"]')||c.down('[dataIndex="'+a.dataIndex+'"]')}if(b.record){if(a&&d.store.indexOfId(e.getId())!==-1){g=(new Ext.grid.CellContext(d)).setPosition({row:e,column:a});f.setPosition(g)}}else {f.selection=null}}},selectByPosition:function(b,a){this.setPosition(b,a)}},0,0,0,0,['selection.cellmodel'],0,[Ext.selection,'CellModel'],0);Ext.cmd.derive('Ext.selection.RowModel',Ext.selection.DataViewModel,{enableKeyNav:!0,isRowModel:!0,deselectOnContainerClick:!1,onUpdate:function(b){var d=this,a=d.view,c;if(a&&d.isSelected(b)){c=a.indexOf(b);a.onRowSelect(c);if(b===d.lastFocused){a.onRowFocus(c,!0)}}},onSelectChange:function(c,g,e,j){var a=this,i=a.views||[a.view],k=i.length,b=a.store.indexOf(c),h=g?'select':'deselect',f,d;if((e||a.fireEvent('before'+h,a,c,b))!==!1&&j()!==!1){for(f=0;f '},selectByPosition:function(a,b){if(!a.isCellContext){a=(new Ext.grid.CellContext(this.view)).setPosition(a.row,a.column)}if(!this.checkOnly||a.column===this.column){Ext.selection.RowModel.prototype.selectByPosition.call(this,a,b)}},onSelectChange:function(){Ext.selection.RowModel.prototype.onSelectChange.apply(this,arguments);if(!this.suspendChange){this.updateHeaderState()}},onStoreLoad:function(){Ext.selection.RowModel.prototype.onStoreLoad.apply(this,arguments);this.updateHeaderState()},onStoreAdd:function(){Ext.selection.RowModel.prototype.onStoreAdd.apply(this,arguments);this.updateHeaderState()},onStoreRemove:function(){Ext.selection.RowModel.prototype.onStoreRemove.apply(this,arguments);this.updateHeaderState()},onStoreRefresh:function(){Ext.selection.RowModel.prototype.onStoreRefresh.apply(this,arguments);this.updateHeaderState()},maybeFireSelectionChange:function(a){if(a&&!this.suspendChange){this.updateHeaderState()}Ext.selection.RowModel.prototype.maybeFireSelectionChange.apply(this,arguments)},resumeChanges:function(){Ext.selection.RowModel.prototype.resumeChanges.call(this);if(!this.suspendChange){this.updateHeaderState()}},updateHeaderState:function(){var a=this,e=a.store,g=e.getCount(),h=a.views,c=!1,f=0,d,i,b;if(!e.isBufferedStore&&g>0){d=a.selected;c=!0;for(b=0,i=d.getCount();b style="{bodyStyle}">{%this.renderContainer(out,values)%}',_reverseDockNames:{left:'right',right:'left'},_layoutAlign:{top:'end',right:'begin',bottom:'begin',left:'end'},initComponent:function(){var a=this,b=a.initialConfig.layout,d=b&&b.align,c=b&&b.overflowHandler;if(a.plain){a.addCls(a.baseCls+'-plain')}Ext.panel.Bar.prototype.initComponent.call(this);a.setLayout({align:d||(a.getTabStretchMax()?'stretchmax':a._layoutAlign[a.dock]),overflowHandler:c||'scroller'});a.on({click:a.onClick,element:'el',scope:a})},ensureTabVisible:function(a){var b=this,d=b.tabPanel,c=b.layout.overflowHandler;if(b.rendered&&c&&b.tooNarrow&&c.scrollToItem){if(a||a===0){if(!a.isTab){if(Ext.isNumber(a)){a=this.items.getAt(a)}else {if(a.isComponent&&d&&d.items.contains(a)){a=a.tab}}}}if(!a){a=b.activeTab}if(a){c.scrollToItem(a)}}},initRenderData:function(){var a=this;return Ext.apply(Ext.panel.Bar.prototype.initRenderData.call(this),{bodyCls:a.bodyCls,baseBodyCls:a._baseBodyCls,bodyTargetCls:a.bodyTargetCls,stripCls:a._stripCls,dock:a.dock})},setDock:function(f){var b=this,a=b.items,d=b.ownerCt,e,c,g;a=a&&a.items;if(a){for(c=0,g=a.length;c1){if(a&&a!==b&&!a.disabled){c=a}else {c=b.next('tab[disabled=false]')||b.prev('tab[disabled=false]')}}return c||d.activeTab},setActiveTab:function(b,c){var a=this;if(!b.disabled&&b!==a.activeTab){if(a.activeTab){if(a.activeTab.destroyed){a.previousTab=null}else {a.previousTab=a.activeTab;a.activeTab.deactivate();a.deactivateFocusable(a.activeTab)}}b.activate();a.activateFocusable(b);a.activeTab=b;a.needsScroll=!0;if(!c){a.fireEvent('change',a,b,b.card);a.updateLayout()}}},privates:{adjustTabPositions:function(){var g=this,f=g.items.items,h=f.length,a,b,e,c,d;if(!Ext.isIE8){d=g._getTabAdjustProp();while(h--){a=f[h];e=a.el;b=a.lastBox;c=a.isTab?a.getActualRotation():0;if(c===1&&a.isVisible()){e.setStyle(d,b.x+b.width+'px')}else {if(c===2&&a.isVisible()){e.setStyle(d,b.x-b.height+'px')}}}}},applyTargetCls:function(a){this.bodyTargetCls=a},_getTabAdjustProp:function(){return 'left'},getTargetEl:function(){return this.body||this.frameBody||this.el},onClick:function(c,g){var f=this,e,a,b,d;if(c.getTarget('.x-box-scroller')){return}if(Ext.isIE8&&f.vertical){d=f.getTabInfoFromPoint(c.getXY());a=d.tab;b=d.close}else {e=c.getTarget('.'+Ext.tab.Tab.prototype.baseCls);a=e&&Ext.getCmp(e.id);b=a&&a.closeEl&&g===a.closeEl.dom}if(b){c.preventDefault()}if(a&&a.isDisabled&&!a.isDisabled()){a.beforeClick(b);if(a.closable&&b){a.onCloseClick()}else {f.doActivateTab(a)}}},doActivateTab:function(a){var b=this.tabPanel;if(b){if(!a.disabled){b.setActiveTab(a.card)}}else {this.setActiveTab(a)}},onFocusableContainerFocus:function(d){var b=this,c=b.mixins.focusablecontainer,a;a=c.onFocusableContainerFocus.call(b,d);if(a&&a.isTab){b.doActivateTab(a)}},onFocusableContainerFocusEnter:function(d){var b=this,c=b.mixins.focusablecontainer,a;a=c.onFocusableContainerFocusEnter.call(b,d);if(a&&a.isTab){b.doActivateTab(a)}},focusChild:function(d,c){var b=this,e=b.mixins.focusablecontainer,a;a=e.focusChild.call(b,d,c);if(b.activateOnFocus&&a&&a.isTab){b.doActivateTab(a)}}}},0,['tabbar'],['component','box','container','tabbar'],{'component':!0,'box':!0,'container':!0,'tabbar':!0},['widget.tabbar'],[[Ext.util.FocusableContainer.prototype.mixinId||Ext.util.FocusableContainer.$className,Ext.util.FocusableContainer]],[Ext.tab,'Bar'],0);Ext.cmd.derive('Ext.tab.Panel',Ext.panel.Panel,{alternateClassName:['Ext.TabPanel'],config:{tabBar:undefined,tabPosition:'top',tabRotation:'default',tabStretchMax:!0},removePanelHeader:!0,plain:!1,itemCls:'x-tabpanel-child',minTabWidth:undefined,maxTabWidth:undefined,deferredRender:!0,_defaultTabRotation:{top:0,right:1,bottom:0,left:2},initComponent:function(){var a=this,c=a.activeTab!==null?a.activeTab||0:null,d=a.dockedItems,b=a.header,f=a.tabBarHeaderPosition,e=a.getTabBar(),g;a.layout=new Ext.layout.container.Card(Ext.apply({owner:a,deferredRender:a.deferredRender,itemCls:a.itemCls,activeItem:c},a.layout));if(f!=null){b=a.header=Ext.apply({},b);g=b.items=b.items?b.items.slice():[];b.itemPosition=f;g.push(e);b.hasTabBar=!0}else {d=[].concat(a.dockedItems||[]);d.push(e);a.dockedItems=d}Ext.panel.Panel.prototype.initComponent.apply(this,arguments);c=a.activeTab=a.getComponent(c);if(c){e.setActiveTab(c.tab,!0)}},onRender:function(){var b=this.items.items,c=b.length,a;Ext.panel.Panel.prototype.onRender.apply(this,arguments);for(a=0;a','
    lineempty" role="presentation">
    ','','
    -end-plus {expanderCls}" role="presentation">
    ','','
    {checkboxCls}-checked">
    ','
    ','',' role="presentation" class="{childCls} {baseIconCls} {customIconCls} ','{baseIconCls}-leafparent-expandedparent {iconCls}" ','style="background-image:url({icon})"/>>','','{value}','','{value}',''],uiFields:{checked:1,icon:1,iconCls:1},rowFields:{expanded:1,loaded:1,expandable:1,leaf:1,loading:1,qtip:1,qtitle:1,cls:1},initComponent:function(){var a=this;a.rendererScope=a.scope;a.setupRenderer();a.innerRenderer=a.renderer;a.renderer=a.treeRenderer;Ext.grid.column.Column.prototype.initComponent.call(this);a.scope=a;a.hasCustomRenderer=a.innerRenderer&&a.innerRenderer.length>1},treeRenderer:function(i,a,c,g,f,h,j){var e=this,d=c.get('cls'),b;if(a&&d){a.tdCls+=' '+d}b=e.initTemplateRendererData(i,a,c,g,f,h,j);return e.getTpl('cellTpl').apply(b)},initTemplateRendererData:function(j,i,d,m,l,n,k){var a=this,f=a.innerRenderer,b=d.data,c=d.parentNode,g=k.rootVisible,h=[],e;while(c&&(g||c.data.depth>0)){e=c.data;h[g?e.depth:e.depth-1]=e.isLast?0:1;c=c.parentNode}return {record:d,baseIconCls:a.iconCls,customIconCls:b.icon||b.iconCls?a.customIconCls:'',iconCls:b.iconCls,icon:b.icon,checkboxCls:a.checkboxCls,checked:b.checked,elbowCls:a.elbowCls,expanderCls:a.expanderCls,textCls:a.textCls,leaf:b.leaf,expandable:d.isExpandable(),expanded:b.expanded,isLast:d.isLastVisible(),blankUrl:Ext.BLANK_IMAGE_URL,href:b.href,hrefTarget:b.hrefTarget,lines:h,metaData:i,childCls:a.getChildCls?a.getChildCls()+' ':'',value:f?f.apply(a.rendererScope,arguments):j}},shouldUpdateCell:function(f,a){var e=this,c=0,d,b;if(a){d=a.length;for(;c1;Ext.grid.NavigationModel.prototype.initKeyNav.call(this,e);for(b=0,d=a.keyNav.length;b1},onCellClick:function(f,e,c,d,g,b,a){Ext.grid.NavigationModel.prototype.onCellClick.call(this,f,e,c,d,g,b,a);return !a.nodeToggled},onKeyLeft:function(b){var c=this,d=b.view,a=c.record;if(c.isTreeGrid&&!b.ctrlKey){return Ext.grid.NavigationModel.prototype.onKeyLeft.call(this,b)}if(b.position.column.isTreeColumn&&a.isExpanded()){d.collapse(a)}else {a=a.parentNode;if(a&&!(a.isRoot()&&!d.rootVisible)){c.setPosition(a,null,b)}}},onKeyRight:function(b){var c=this,a=c.record;if(c.isTreeGrid&&!b.ctrlKey){return Ext.grid.NavigationModel.prototype.onKeyRight.call(this,b)}if(!a.isLeaf()){if(b.position.column.isTreeColumn&&!a.isExpanded()){b.view.expand(a)}else {if(a.isExpanded()){a=a.childNodes[0];if(a){c.setPosition(a)}}}}},onKeyEnter:function(a){if(this.record.data.checked!=null){this.toggleCheck(a)}else {Ext.grid.NavigationModel.prototype.onKeyEnter.call(this,a)}},onKeySpace:function(a){if(this.record.data.checked!=null){this.toggleCheck(a)}else {Ext.grid.NavigationModel.prototype.onKeySpace.call(this,a)}},toggleCheck:function(a){this.view.onCheckChange(a)},onAsterisk:function(a){this.view.ownerCt.expandAll()}},0,0,0,0,['view.navigation.tree'],0,[Ext.tree,'NavigationModel'],0);Ext.cmd.derive('Ext.tree.View',Ext.view.Table,{config:{selectionModel:{type:'treemodel'}},isTreeView:!0,loadingCls:'x-grid-tree-loading',expandedCls:'x-grid-tree-node-expanded',leafCls:'x-grid-tree-node-leaf',expanderSelector:'.x-tree-expander',checkboxSelector:'.x-tree-checkbox',expanderIconOverCls:'x-tree-expander-over',nodeAnimWrapCls:'x-tree-animator-wrap',ariaRole:'tree',loadMask:!1,rootVisible:!0,expandDuration:250,collapseDuration:250,toggleOnDblClick:!0,stripeRows:!1,treeRowTpl:['{%','this.processRowValues(values);','this.nextTpl.applyOut(values, out, parent);','%}',{priority:10,processRowValues:function(a){var b=a.record,c=a.view;a.rowAttr['data-qtip']=b.get('qtip')||'';a.rowAttr['data-qtitle']=b.get('qtitle')||'';if(b.isExpanded()){a.rowClasses.push(c.expandedCls)}if(b.isLeaf()){a.rowClasses.push(c.leafCls)}if(b.isLoading()){a.rowClasses.push(c.loadingCls)}}}],initComponent:function(){var a=this;if(a.bufferedRenderer){a.animate=!1}else {if(a.initialConfig.animate===undefined){a.animate=Ext.enableFx}}a.store=a.panel.getStore();a.onRootChange(a.store.getRoot());a.animQueue={};a.animWraps={};Ext.view.Table.prototype.initComponent.call(this);a.store.setRootVisible(a.rootVisible);a.addRowTpl(Ext.XTemplate.getTpl(a,'treeRowTpl'))},onFillComplete:function(f,d,b){var a=this,e=a.store,c=e.indexOf(b[0]);d.triggerUIUpdate();if(!b.length||c===-1){return}a.onAdd(a.store,b,c);a.refreshPartner()},refreshPartner:function(){var a=this.lockingPartner;if(a){a.refresh()}},afterComponentLayout:function(e,d,c,b){var a=this.getScrollable();Ext.view.Table.prototype.afterComponentLayout.call(this,e,d,c,b);if(a&&!this.bufferedRenderer){a.refresh()}},processUIEvent:function(a){if(a.getTarget('.'+this.nodeAnimWrapCls,this.el)){return !1}return Ext.view.Table.prototype.processUIEvent.call(this,a)},setRootNode:function(a){this.node=a},getChecked:function(){var a=[];this.node.cascadeBy(function(b){if(b.get('checked')){a.push(b)}});return a},isItemChecked:function(a){return a.get('checked')},createAnimWrap:function(b,e){var d=this,c=d.getNode(b),a;a=Ext.fly(c).insertSibling({role:'presentation',tag:'div',cls:d.nodeAnimWrapCls},'after');return {record:b,node:c,el:a,expanding:!1,collapsing:!1,animateEl:a,targetEl:a}},getAnimWrap:function(a,d){if(!this.animate){return null}var c=this.animWraps,b=c[a.internalId];if(d!==!1){while(!b&&a){a=a.parentNode;if(a){b=c[a.internalId]}}}return b},doAdd:function(h,c){var d=this,l=h[0],i=l.parentNode,m=d.all,e,a=d.getAnimWrap(i),g,f,k,j,b;if(!a||!a.expanding){return Ext.view.Table.prototype.doAdd.call(this,h,c)}j=d.bufferRender(h,c,!0);b=j.children;i=a.record;g=a.targetEl;f=g.dom.childNodes;k=f.length;e=c-d.indexInStore(i)-1;if(!k||e>=k){g.appendChild(j.fragment,!0)}else {Ext.fly(f[e]).insertSibling(b,'before',!0)}m.insert(c,b);return b},onRemove:function(h,c,b){var a=this,g,d,e=a.hasListeners.remove,f;if(a.viewReady){g=a.store.getCount()===0;if(a.bufferedRenderer){return Ext.view.Table.prototype.onRemove.call(this,h,c,b)}if(e){f=this.all.slice(b,b+c.length)}if(g){a.refresh()}else {for(d=c.length-1,b+=d;d>=0;--d,--b){a.doRemove(c[d],b)}a.refreshSizePending=!0}if(e){a.fireEvent('itemremove',c,b,f,a)}}},doRemove:function(c,b){var g=this,f=g.all,a=g.getAnimWrap(c),d=f.item(b),e=d?d.dom:null;if(!e||!a||!a.collapsing){return Ext.view.Table.prototype.doRemove.call(this,c,b)}a.targetEl.dom.insertBefore(e,a.targetEl.dom.firstChild);f.removeElement(b)},onBeforeExpand:function(c,d,e){var b=this,a;if(b.rendered&&b.all.getCount()&&b.animate){if(b.getNode(c)){a=b.getAnimWrap(c,!1);if(!a){a=b.animWraps[c.internalId]=b.createAnimWrap(c);a.animateEl.setHeight(0)}else {if(a.collapsing){a.targetEl.select(b.itemSelector).destroy()}}a.expanding=!0;a.collapsing=!1}}},onExpand:function(b){var a=this,h=a.animQueue,i=b.getId(),f=a.getNode(b),g=f?a.indexOf(f):-1,c,d,e;if(a.singleExpand){a.ensureSingleExpand(b)}if(g===-1){return}c=a.getAnimWrap(b,!1);if(!c){b.isExpandingOrCollapsing=!1;a.fireEvent('afteritemexpand',b,g,f);return}d=c.animateEl;e=c.targetEl;d.stopAnimation();h[i]=!0;Ext.on('idle',function(){d.dom.style.height='0px'},null,{single:!0});d.animate({from:{height:0},to:{height:e.dom.scrollHeight},duration:a.expandDuration,listeners:{afteranimate:function(){var f=e.dom.childNodes,d=Ext.Element.getActiveElement();if(f.length){if(!e.contains(d)){d=null}c.el.insertSibling(f,'before',!0);if(d){Ext.fly(d).focus()}}c.el.destroy();a.animWraps[c.record.internalId]=h[i]=null}},callback:function(){b.isExpandingOrCollapsing=!1;if(!a.destroyed){a.refreshSize(!0)}a.fireEvent('afteritemexpand',b,g,f)}})},onBeforeCollapse:function(c,g,f,d,e){var b=this,a;if(b.rendered&&b.all.getCount()){if(b.animate){if(c.isVisible()){a=b.getAnimWrap(c);if(!a){a=b.animWraps[c.internalId]=b.createAnimWrap(c,f)}else {if(a.expanding){a.targetEl.select(this.itemSelector).destroy()}}a.expanding=!1;a.collapsing=!0;a.callback=d;a.scope=e}}else {b.onCollapseCallback=d;b.onCollapseScope=e}}},onCollapse:function(c){var a=this,g=a.animQueue,h=c.getId(),d=a.getNode(c),f=d?a.indexOf(d):-1,b=a.getAnimWrap(c),e;if(!a.all.getCount()||!c.isVisible()){return}if(!b){c.isExpandingOrCollapsing=!1;a.fireEvent('afteritemcollapse',c,f,d);Ext.callback(a.onCollapseCallback,a.onCollapseScope);a.onCollapseCallback=a.onCollapseScope=null;return}e=b.animateEl;g[h]=!0;e.stopAnimation();e.animate({to:{height:0},duration:a.collapseDuration,listeners:{afteranimate:function(){b.el.destroy();a.animWraps[b.record.internalId]=g[h]=null}},callback:function(){c.isExpandingOrCollapsing=!1;if(!a.destroyed){a.refreshSize(!0)}a.fireEvent('afteritemcollapse',c,f,d);Ext.callback(b.callback,b.scope);b.callback=b.scope=null}})},isAnimating:function(a){return !!this.animQueue[a.getId()]},expand:function(a,f,d,e){var g=this,b=!!g.animate,c;if(!b||!a.isExpandingOrCollapsing){if(!a.isLeaf()){a.isExpandingOrCollapsing=b}Ext.suspendLayouts();c=a.expand(f,d,e);Ext.resumeLayouts(!0);return c}},collapse:function(a,e,c,d){var f=this,b=!!f.animate;if(!b||!a.isExpandingOrCollapsing){if(!a.isLeaf()){a.isExpandingOrCollapsing=b}return a.collapse(e,c,d)}},toggle:function(a,d,b,c){if(a.isExpanded()){this.collapse(a,d,b,c)}else {this.expand(a,d,b,c)}},onItemDblClick:function(a,e,d,f){var b=this,c=b.editingPlugin;Ext.view.Table.prototype.onItemDblClick.call(this,a,e,d,f);if(b.toggleOnDblClick&&a.isExpandable()&&!(c&&c.clicksToEdit===2)){b.toggle(a)}},onCellClick:function(d,g,c,i,h,a){var b=this,f=a.position.column,e;if(f.isTreeColumn){if(a.getTarget(b.checkboxSelector,d)&&Ext.isBoolean(e=c.get('checked'))&&b.fireEvent('beforecheckchange',c,e,a)!==!1){b.onCheckChange(a);if(f.stopSelection){a.stopSelection=!0}}else {if(a.getTarget(b.expanderSelector,d)&&c.isExpandable()){b.getNavigationModel().setPosition(a.position);b.toggle(c,a.ctrlKey);a.nodeToggled=!0}}return Ext.view.Table.prototype.onCellClick.call(this,d,g,c,i,h,a)}},onCheckChange:function(c){var a=c.record,b=!a.get('checked');a.set('checked',b);this.fireEvent('checkchange',a,b,c)},onItemMouseOver:function(c,b,d,a){if(a.getTarget(this.expanderSelector,b)){a.getTarget(this.cellSelector,null,!0).addCls(this.expanderIconOverCls)}},onItemMouseOut:function(c,b,d,a){if(a.getTarget(this.expanderSelector,b)){a.getTarget(this.cellSelector,null,!0).removeCls(this.expanderIconOverCls)}},getStoreListeners:function(){return Ext.apply(Ext.view.Table.prototype.getStoreListeners.call(this),{rootchange:this.onRootChange,fillcomplete:this.onFillComplete})},onBindStore:function(b,f,e,a){var d=a&&a.getRootNode(),c=b&&b.getRootNode();Ext.view.Table.prototype.onBindStore.call(this,b,f,e,a);if(c!==d){this.onRootChange(c,d)}},onRootChange:function(b,c){var a=this,d=a.grid;if(c){a.rootListeners.destroy();a.rootListeners=null}if(b){a.rootListeners=b.on({beforeexpand:a.onBeforeExpand,expand:a.onExpand,beforecollapse:a.onBeforeCollapse,collapse:a.onCollapse,destroyable:!0,scope:a});d.addRelayers(b)}},ensureSingleExpand:function(b){var a=b.parentNode;if(a){a.eachChild(function(a){if(a!==b&&a.isExpanded()){a.collapse()}})}}},0,['treeview'],['component','box','dataview','tableview','gridview','treeview'],{'component':!0,'box':!0,'dataview':!0,'tableview':!0,'gridview':!0,'treeview':!0},['widget.treeview'],0,[Ext.tree,'View'],0);Ext.cmd.derive('Ext.tree.Panel',Ext.panel.Table,{alternateClassName:['Ext.tree.TreePanel','Ext.TreePanel'],viewType:'treeview',treeCls:'x-tree-panel',rowLines:!1,lines:!0,useArrows:!1,singleExpand:!1,ddConfig:{enableDrag:!0,enableDrop:!0},rootVisible:!0,displayField:'text',root:null,normalCfgCopy:['displayField','root','singleExpand','useArrows','lines','rootVisible','scroll'],lockedCfgCopy:['displayField','root','singleExpand','useArrows','lines','rootVisible'],isTree:!0,arrowCls:'x-tree-arrows',linesCls:'x-tree-lines',noLinesCls:'x-tree-no-lines',autoWidthCls:'x-autowidth-table',constructor:function(a){a=a||{};if(a.animate===undefined){a.animate=Ext.isBoolean(this.animate)?this.animate:Ext.enableFx}this.enableAnimations=a.animate;delete a.animate;Ext.panel.Table.prototype.constructor.call(this,a)},initComponent:function(){var a=this,c=[a.treeCls],b,d;if(a.useArrows){c.push(a.arrowCls);a.lines=!1}if(a.lines){c.push(a.linesCls)}else {if(!a.useArrows){c.push(a.noLinesCls)}}b=a.applyStore(a.store);if(!b.getRoot()){b.setRoot({})}b.setRootVisible(a.rootVisible);a.viewConfig=Ext.apply({rootVisible:a.rootVisible,animate:a.enableAnimations,singleExpand:a.singleExpand,node:b.getRoot(),hideHeaders:a.hideHeaders,navigationModel:'tree'},a.viewConfig);if(!a.columns){if(a.initialConfig.hideHeaders===undefined){a.hideHeaders=!0}a.addCls(a.autoWidthCls);a.columns=[{xtype:'treecolumn',text:'Name',flex:1,dataIndex:a.displayField}]}if(a.cls){c.push(a.cls)}a.cls=c.join(' ');Ext.panel.Table.prototype.initComponent.call(this);d=a.getView();a.relayEvents(d,['beforecheckchange','checkchange','afteritemexpand','afteritemcollapse'])},applyStore:function(a){var b=this;if(Ext.isString(a)){a=b.store=Ext.StoreMgr.lookup(a)}else {if(!a||!a.isStore){a=Ext.apply({type:'tree',proxy:'memory'},a);if(b.root){a.root=b.root}if(b.fields){a.fields=b.fields}else {if(b.model){a.model=b.model}}if(b.folderSort){a.folderSort=b.folderSort}a=b.store=Ext.StoreMgr.lookup(a)}else {if(b.root){a=b.store=Ext.data.StoreManager.lookup(a);a.setRoot(b.root);if(b.folderSort!==undefined){a.folderSort=b.folderSort;a.sort()}}}}return a},setStore:function(a){var b=this;a=b.applyStore(a);if(!a.getRoot()){a.setRoot({})}a.setRootVisible(b.rootVisible);if(b.view){b.view.setRootNode(a.getRootNode())}b.bindStore(a)},bindStore:function(b,e){var a=this,c=b.getRoot(),d=a.bufferedRenderer;Ext.panel.Table.prototype.bindStore.apply(this,arguments);if(d){if(d.store){d.bindStore(b)}}b.singleExpand=a.singleExpand;a.storeListeners=a.mon(b,{destroyable:!0,rootchange:a.onRootChange,scope:a});a.storeRelayers=a.relayEvents(b,['beforeload','load']);if(!a.rootVisible&&!b.autoLoad&&!(c.isExpanded()||c.isLoading())){if(c.isLoaded()){c.data.expanded=!0;b.onNodeExpand(c,c.childNodes)}else {if(b.autoLoad!==!1){c.data.expanded=!1;c.expand()}}}b.ownerTree=a;if(!e){a.view.setRootNode(c)}},addRelayers:function(b){var a=this;if(a.rootRelayers){a.rootRelayers.destroy();a.rootRelayers=null}a.rootRelayers=a.mon(b,{destroyable:!0,append:a.createRelayer('itemappend'),remove:a.createRelayer('itemremove'),move:a.createRelayer('itemmove',[0,4]),insert:a.createRelayer('iteminsert'),beforeappend:a.createRelayer('beforeitemappend'),beforeremove:a.createRelayer('beforeitemremove'),beforemove:a.createRelayer('beforeitemmove'),beforeinsert:a.createRelayer('beforeiteminsert'),expand:a.createRelayer('itemexpand',[0,1]),collapse:a.createRelayer('itemcollapse',[0,1]),beforeexpand:a.createRelayer('beforeitemexpand',[0,1]),beforecollapse:a.createRelayer('beforeitemcollapse',[0,1]),scope:a})},unbindStore:function(){var a=this,b=a.store;if(b){Ext.panel.Table.prototype.unbindStore.call(this);Ext.destroy(a.storeListeners,a.storeRelayers,a.rootRelayers);delete b.ownerTree;b.singleExpand=null}},setRootNode:function(){return this.store.setRoot.apply(this.store,arguments)},getRootNode:function(){return this.store.getRoot()},onRootChange:function(a){this.view.setRootNode(a)},getChecked:function(){return this.getView().getChecked()},isItemChecked:function(a){return a.get('checked')},expandNode:function(b,d,a,c){return this.getView().expand(b,d,a,c||this)},collapseNode:function(b,d,a,c){return this.getView().collapse(b,d,a,c||this)},expandAll:function(c,d){var b=this,a=b.getRootNode();if(a){Ext.suspendLayouts();a.expand(!0,c,d||b);Ext.resumeLayouts(!0)}},collapseAll:function(d,a){var c=this,b=c.getRootNode(),e=c.getView();if(b){Ext.suspendLayouts();a=a||c;if(e.rootVisible){b.collapse(!0,d,a)}else {b.collapseChildren(!0,d,a)}Ext.resumeLayouts(!0)}},expandPath:function(p,a){var i=arguments,b=this,j=b.view,g=a&&a.field||b.store.model.idProperty,o,n,k=a&&a.separator||'/',c,e,d,h,f,m,l;if(a&&typeof a==='object'){g=a.field||b.store.model.idProperty;k=a.separator||'/';c=a.callback;e=a.scope;o=a.select;n=a.focus}else {g=i[1]||b.store.model.idProperty;k=i[2]||'/';c=i[3];e=i[4]}if(Ext.isEmpty(p)){return Ext.callback(c,e||b,[!1,null])}f=p.split(k);m=!f[0];if(m){d=b.getRootNode();h=1}else {d=b.store.findNode(g,f[0]);h=0}if(!d||m&&d.get(g)!==f[1]){return Ext.callback(c,e||b,[!1,d])}l=function(m){var d=this,q,k,i;if(++h===f.length){if(o){j.getSelectionModel().select(d)}if(n){j.getNavigationModel().setPosition(d,0)}return Ext.callback(c,e||b,[!0,d,j.getNode(d)])}for(k=0,q=m?m.length:0;k2?b[2]:null,e=a>3?b[3]:'/',d=a>4?b[4]:null,f=a>5?b[5]:!1;document.cookie=h+'='+escape(g)+(c===null?'':'; expires='+c.toUTCString())+(e===null?'':'; path='+e)+(d===null?'':'; domain='+d)+(f===!0?'; secure':'')},get:function(e){var d=document.cookie.split('; '),f=d.length,b,a,c;for(a=0;a'],childEls:['iframeEl'],initComponent:function(){Ext.Component.prototype.initComponent.call(this);this.frameName=this.frameName||this.id+'-frame'},initEvents:function(){var a=this;Ext.Component.prototype.initEvents.call(this);a.iframeEl.on('load',a.onLoad,a)},initRenderData:function(){return Ext.apply(Ext.Component.prototype.initRenderData.call(this),{src:this.src,frameName:this.frameName})},getBody:function(){var a=this.getDoc();return a.body||a.documentElement},getDoc:function(){try{return this.getWin().document}catch(b){return null}},getWin:function(){var a=this,b=a.frameName,c=Ext.isIE?a.iframeEl.dom.contentWindow:window.frames[b];return c},getFrame:function(){var a=this;return a.iframeEl.dom},beforeDestroy:function(){this.cleanupListeners(!0);Ext.Component.prototype.beforeDestroy.call(this)},cleanupListeners:function(c){var a,b;if(this.rendered){try{a=this.getDoc();if(a){Ext.get(a).un(this._docListeners);if(c){for(b in a){if(a.hasOwnProperty&&a.hasOwnProperty(b)){delete a[b]}}}}}catch(d){}}},onLoad:function(){var a=this,c=a.getDoc(),b=a.onRelayedEvent;if(c){try{Ext.get(c).on(a._docListeners={mousedown:b,mousemove:b,mouseup:b,click:b,dblclick:b,scope:a})}catch(d){}Ext.get(this.getWin()).on('beforeunload',a.cleanupListeners,a);this.el.unmask();this.fireEvent('load',this)}else {if(a.src){this.el.unmask();this.fireEvent('error',this)}}},onRelayedEvent:function(a){var b=this.iframeEl,c=b.getTrueXY(),e=a.getXY(),d=a.getTrueXY();a.xy=[c[0]+d[0],c[1]+d[1]];a.injectEvent(b);a.xy=e},load:function(c){var a=this,b=a.loadMask,d=a.getFrame();if(a.fireEvent('beforeload',a,c)!==!1){if(b&&a.el){a.el.mask(b)}d.src=a.src=c||a.src}}},0,['uxiframe'],['component','box','uxiframe'],{'component':!0,'box':!0,'uxiframe':!0},['widget.uxiframe'],0,[Ext.ux,'IFrame'],0);Ext.cmd.derive('Ext.ux.colorpick.Selection',Ext.Base,{mixinId:'colorselection',config:{format:'hex6',value:'FF0000',color:null,previousColor:null},applyColor:function(b){var a=b;if(Ext.isString(a)){a=Ext.ux.colorpick.ColorUtils.parseColor(b)}return a},applyValue:function(a){var b=Ext.ux.colorpick.ColorUtils.parseColor(a);return this.formatColor(b)},formatColor:function(a){return Ext.ux.colorpick.ColorUtils.formats[this.getFormat()](a)},updateColor:function(b){var a=this;if(!a.syncing){a.syncing=!0;a.setValue(a.formatColor(b));a.syncing=!1}},updateValue:function(b,c){var a=this;if(!a.syncing){a.syncing=!0;a.setColor(b);a.syncing=!1}this.fireEvent('change',a,b,c)}},0,0,0,0,0,0,[Ext.ux.colorpick,'Selection'],0);Ext.cmd.derive('Ext.ux.colorpick.ColorUtils',Ext.Base,function(a){var b=Ext.isIE&&Ext.ieVersion<10;return {singleton:!0,constructor:function(){a=this},backgroundTpl:b?"filter: progid:DXImageTransform.Microsoft.gradient(GradientType=0, startColorstr='#{alpha}{hex}', endColorstr='#{alpha}{hex}');":'background: {rgba};',setBackground:b?function(c,b){if(c){var f=Ext.XTemplate.getTpl(a,'backgroundTpl'),e={hex:a.rgb2hex(b.r,b.g,b.b),alpha:Math.floor(b.a*255).toString(16)},d=f.apply(e);c.applyStyles(d)}}:function(b,d){if(b){var f=Ext.XTemplate.getTpl(a,'backgroundTpl'),e={rgba:a.getRGBAString(d)},c=f.apply(e);b.applyStyles(c)}},formats:{HEX6:function(b){return a.rgb2hex(b.r,b.g,b.b)},HEX8:function(b){var c=a.rgb2hex(b.r,b.g,b.b),d=Math.round(b.a*255).toString(16);if(d.length<2){c+='0'}c+=d.toUpperCase();return c}},hexRe:/#?([0-9a-f]{3,8})/i,rgbaAltRe:/rgba\(\s*([\w#\d]+)\s*,\s*([\d\.]+)\s*\)/,rgbaRe:/rgba\(\s*([\d\.]+)\s*,\s*([\d\.]+)\s*,\s*([\d\.]+)\s*,\s*([\d\.]+)\s*\)/,rgbRe:/rgb\(\s*([\d\.]+)\s*,\s*([\d\.]+)\s*,\s*([\d\.]+)\s*\)/,parseColor:function(d){if(!d){return null}var e=this,f=e.colorMap[d],b,c,g;if(f){c={r:f[0],g:f[1],b:f[2],a:1}}else {if(d==='transparent'){c={r:0,g:0,b:0,a:0}}else {b=e.hexRe.exec(d);if(b){b=b[1];switch(b.length){default:return null;case 3:c={r:parseInt(b[0]+b[0],16),g:parseInt(b[1]+b[1],16),b:parseInt(b[2]+b[2],16),a:1};break;case 6:case 8:c={r:parseInt(b.substr(0,2),16),g:parseInt(b.substr(2,2),16),b:parseInt(b.substr(4,2),16),a:parseInt(b.substr(6,2)||'ff',16)/255};break;}}else {b=e.rgbaRe.exec(d);if(b){c={r:parseFloat(b[1]),g:parseFloat(b[2]),b:parseFloat(b[3]),a:parseFloat(b[4])}}else {b=e.rgbaAltRe.exec(d);if(b){c=e.parseColor(b[1]);c.a=parseFloat(b[2]);return c}b=e.rgbRe.exec(d);if(b){c={r:parseFloat(b[1]),g:parseFloat(b[2]),b:parseFloat(b[3]),a:1}}else {return null}}}}}g=this.rgb2hsv(c.r,c.g,c.b);return Ext.apply(c,g)},getRGBAString:function(b){return 'rgba('+b.r+','+b.g+','+b.b+','+b.a+')'},getRGBString:function(b){return 'rgb('+b.r+','+b.g+','+b.b+')'},hsv2rgb:function(e,i,h){e=e*360;if(e===360){e=0}var c=h*i;var g=e/60;var d=c*(1-Math.abs(g%2-1));var b=[0,0,0];switch(Math.floor(g)){case 0:b=[c,d,0];break;case 1:b=[d,c,0];break;case 2:b=[0,c,d];break;case 3:b=[0,d,c];break;case 4:b=[d,0,c];break;case 5:b=[c,0,d];break;default:break;}var f=h-c;b[0]+=f;b[1]+=f;b[2]+=f;b[0]=Math.round(b[0]*255);b[1]=Math.round(b[1]*255);b[2]=Math.round(b[2]*255);return {r:b[0],g:b[1],b:b[2]}},rgb2hsv:function(e,d,c){e=e/255;d=d/255;c=c/255;var g=Math.max(e,d,c);var k=Math.min(e,d,c);var f=g-k;var h=0;if(f!==0){if(g===e){h=(d-c)/f%6}else {if(g===d){h=(c-e)/f+2}else {if(g===c){h=(e-d)/f+4}}}}var b=h*60;if(b===360){b=0}var j=g;var i=0;if(f!==0){i=f/j}b=b/360;if(b<0){b=b+1}return {h:b,s:i,v:j}},rgb2hex:function(d,c,b){d=d.toString(16);c=c.toString(16);b=b.toString(16);if(d.length<2){d='0'+d}if(c.length<2){c='0'+c}if(b.length<2){b='0'+b}return (d+c+b).toUpperCase()},colorMap:{aliceblue:[240,248,255],antiquewhite:[250,235,215],aqua:[0,255,255],aquamarine:[127,255,212],azure:[240,255,255],beige:[245,245,220],bisque:[255,228,196],black:[0,0,0],blanchedalmond:[255,235,205],blue:[0,0,255],blueviolet:[138,43,226],brown:[165,42,42],burlywood:[222,184,135],cadetblue:[95,158,160],chartreuse:[127,255,0],chocolate:[210,105,30],coral:[255,127,80],cornflowerblue:[100,149,237],cornsilk:[255,248,220],crimson:[220,20,60],cyan:[0,255,255],darkblue:[0,0,139],darkcyan:[0,139,139],darkgoldenrod:[184,132,11],darkgray:[169,169,169],darkgreen:[0,100,0],darkgrey:[169,169,169],darkkhaki:[189,183,107],darkmagenta:[139,0,139],darkolivegreen:[85,107,47],darkorange:[255,140,0],darkorchid:[153,50,204],darkred:[139,0,0],darksalmon:[233,150,122],darkseagreen:[143,188,143],darkslateblue:[72,61,139],darkslategray:[47,79,79],darkslategrey:[47,79,79],darkturquoise:[0,206,209],darkviolet:[148,0,211],deeppink:[255,20,147],deepskyblue:[0,191,255],dimgray:[105,105,105],dimgrey:[105,105,105],dodgerblue:[30,144,255],firebrick:[178,34,34],floralwhite:[255,255,240],forestgreen:[34,139,34],fuchsia:[255,0,255],gainsboro:[220,220,220],ghostwhite:[248,248,255],gold:[255,215,0],goldenrod:[218,165,32],gray:[128,128,128],green:[0,128,0],greenyellow:[173,255,47],grey:[128,128,128],honeydew:[240,255,240],hotpink:[255,105,180],indianred:[205,92,92],indigo:[75,0,130],ivory:[255,255,240],khaki:[240,230,140],lavender:[230,230,250],lavenderblush:[255,240,245],lawngreen:[124,252,0],lemonchiffon:[255,250,205],lightblue:[173,216,230],lightcoral:[240,128,128],lightcyan:[224,255,255],lightgoldenrodyellow:[250,250,210],lightgray:[211,211,211],lightgreen:[144,238,144],lightgrey:[211,211,211],lightpink:[255,182,193],lightsalmon:[255,160,122],lightseagreen:[32,178,170],lightskyblue:[135,206,250],lightslategray:[119,136,153],lightslategrey:[119,136,153],lightsteelblue:[176,196,222],lightyellow:[255,255,224],lime:[0,255,0],limegreen:[50,205,50],linen:[250,240,230],magenta:[255,0,255],maroon:[128,0,0],mediumaquamarine:[102,205,170],mediumblue:[0,0,205],mediumorchid:[186,85,211],mediumpurple:[147,112,219],mediumseagreen:[60,179,113],mediumslateblue:[123,104,238],mediumspringgreen:[0,250,154],mediumturquoise:[72,209,204],mediumvioletred:[199,21,133],midnightblue:[25,25,112],mintcream:[245,255,250],mistyrose:[255,228,225],moccasin:[255,228,181],navajowhite:[255,222,173],navy:[0,0,128],oldlace:[253,245,230],olive:[128,128,0],olivedrab:[107,142,35],orange:[255,165,0],orangered:[255,69,0],orchid:[218,112,214],palegoldenrod:[238,232,170],palegreen:[152,251,152],paleturquoise:[175,238,238],palevioletred:[219,112,147],papayawhip:[255,239,213],peachpuff:[255,218,185],peru:[205,133,63],pink:[255,192,203],plum:[221,160,203],powderblue:[176,224,230],purple:[128,0,128],red:[255,0,0],rosybrown:[188,143,143],royalblue:[65,105,225],saddlebrown:[139,69,19],salmon:[250,128,114],sandybrown:[244,164,96],seagreen:[46,139,87],seashell:[255,245,238],sienna:[160,82,45],silver:[192,192,192],skyblue:[135,206,235],slateblue:[106,90,205],slategray:[119,128,144],slategrey:[119,128,144],snow:[255,255,250],springgreen:[0,255,127],steelblue:[70,130,180],tan:[210,180,140],teal:[0,128,128],thistle:[216,191,216],tomato:[255,99,71],turquoise:[64,224,208],violet:[238,130,238],wheat:[245,222,179],white:[255,255,255],whitesmoke:[245,245,245],yellow:[255,255,0],yellowgreen:[154,205,5]}}},1,0,0,0,0,0,[Ext.ux.colorpick,'ColorUtils'],function(c){var a=c.formats,b={};a['#HEX6']=function(b){return '#'+a.HEX6(b)};a['#HEX8']=function(b){return '#'+a.HEX8(b)};Ext.Object.each(a,function(a,d){b[a.toLowerCase()]=function(b){var e=d(b);return e.toLowerCase()}});Ext.apply(a,b)});Ext.cmd.derive('Ext.ux.colorpick.ColorMapController',Ext.app.ViewController,{onFirstBoxReady:function(){var a=this,c=a.getView(),d=c.down('#dragHandle'),b=d.dd;b.constrain=!0;b.constrainTo=c.getEl();b.initialConstrainTo=b.constrainTo;b.on('drag',Ext.bind(a.onHandleDrag,a));a.mon(c.getEl(),{mousedown:a.onMouseDown,dragstart:a.onDragStart,scope:a})},onHandleDrag:function(k,l){var h=this,a=h.getView(),e=a.down('#dragHandle'),i=e.getX()-a.getX(),j=e.getY()-a.getY(),d=a.getEl(),g=d.getWidth(),f=d.getHeight(),b=i/g,c=j/f;if(b>0.99){b=1}if(c>0.99){c=1}a.fireEvent('handledrag',b,c)},onMouseDown:function(b){var c=this,d=c.getView(),a=d.down('#dragHandle');a.setY(b.getY());a.setX(b.getX());c.onHandleDrag();a.dd.onMouseDown(b,a.dd.el)},onDragStart:function(d){var c=this,b=c.getView(),a=b.down('#dragHandle');a.dd.onDragStart(d,a.dd.el)},onMapClick:function(h){var f=this,a=f.getView(),g=a.down('#dragHandle'),c=a.getXY(),d=h.getXY(),b,e;b=d[0]-c[0];e=d[1]-c[1];g.getEl().setStyle({left:b+'px',top:e+'px'});f.onHandleDrag()},onColorBindingChanged:function(n){var i=this,m=i.getViewModel(),a=m.get('selectedColor'),b,d=i.getView(),l=d.down('#dragHandle'),c=d.getEl(),k=c.getWidth(),j=c.getHeight(),e,f,g,h;b=Ext.ux.colorpick.ColorUtils.rgb2hsv(a.r,a.g,a.b);e=b.s;g=k*e;f=1-b.v;h=j*f;l.getEl().setStyle({left:g+'px',top:h+'px'})},onHueBindingChanged:function(d){var c=this,e=c.getViewModel(),a,b;a=Ext.ux.colorpick.ColorUtils.hsv2rgb(d,1,1);b=Ext.ux.colorpick.ColorUtils.rgb2hex(a.r,a.g,a.b);c.getView().getEl().applyStyles({'background-color':'#'+b})}},0,0,0,0,['controller.colorpickercolormapcontroller'],0,[Ext.ux.colorpick,'ColorMapController'],0);Ext.cmd.derive('Ext.ux.colorpick.ColorMap',Ext.container.Container,{controller:'colorpickercolormapcontroller',cls:'x-colorpicker-colormap',items:[{xtype:'component',cls:'x-colorpicker-colormap-draghandle-container',itemId:'dragHandle',width:1,height:1,draggable:!0,html:'
    '}],listeners:{boxready:{single:!0,fn:'onFirstBoxReady',scope:'controller'},colorbindingchanged:{fn:'onColorBindingChanged',scope:'controller'},huebindingchanged:{fn:'onHueBindingChanged',scope:'controller'}},afterRender:function(){var c=this,a=c.mapGradientUrl,b=c.el;Ext.container.Container.prototype.afterRender.call(this);if(!a){a=b.getStyle('background-image');a=a.substring(4,a.length-1);if(a.indexOf('"')===0){a=a.substring(1,a.length-1)}Ext.ux.colorpick.ColorMap.prototype.mapGradientUrl=a}b.setStyle('background-image','none');b=c.layout.getElementTarget();b.createChild({tag:'img',cls:'x-colorpicker-colormap-blender',src:a})},setPosition:function(c){var b=this,a=b.down('#dragHandle');if(!a.dd||!a.dd.constrain){return}if(typeof a.dd.dragEnded!=='undefined'&&!a.dd.dragEnded){return}b.fireEvent('colorbindingchanged',c)},setHue:function(b){var a=this;if(!a.getEl()){return}a.fireEvent('huebindingchanged',b)}},0,['colorpickercolormap'],['component','box','container','colorpickercolormap'],{'component':!0,'box':!0,'container':!0,'colorpickercolormap':!0},['widget.colorpickercolormap'],0,[Ext.ux.colorpick,'ColorMap'],0);Ext.cmd.derive('Ext.ux.colorpick.SelectorModel',Ext.app.ViewModel,{data:{selectedColor:{r:255,g:255,b:255,h:0,s:1,v:1,a:1},previousColor:{r:0,g:0,b:0,h:0,s:1,v:1,a:1}},formulas:{hex:{get:function(a){var e=a('selectedColor.r').toString(16),d=a('selectedColor.g').toString(16),c=a('selectedColor.b').toString(16),b;b=Ext.ux.colorpick.ColorUtils.rgb2hex(e,d,c);return '#'+b},set:function(a){var b=Ext.ux.colorpick.ColorUtils.hex2rgb(a);this.changeRGB(b)}},red:{get:function(a){return a('selectedColor.r')},set:function(a){this.changeRGB({r:a})}},green:{get:function(a){return a('selectedColor.g')},set:function(a){this.changeRGB({g:a})}},blue:{get:function(a){return a('selectedColor.b')},set:function(a){this.changeRGB({b:a})}},hue:{get:function(a){return a('selectedColor.h')*360},set:function(a){this.changeHSV({h:a/360})}},saturation:{get:function(a){return a('selectedColor.s')*100},set:function(a){this.changeHSV({s:a/100})}},value:{get:function(a){var b=a('selectedColor.v');return b*100},set:function(a){this.changeHSV({v:a/100})}},alpha:{get:function(a){var b=a('selectedColor.a');return b*100},set:function(a){this.set('selectedColor',Ext.applyIf({a:a/100},this.data.selectedColor))}}},changeHSV:function(a){Ext.applyIf(a,this.data.selectedColor);var b=Ext.ux.colorpick.ColorUtils.hsv2rgb(a.h,a.s,a.v);a.r=b.r;a.g=b.g;a.b=b.b;this.set('selectedColor',a)},changeRGB:function(a){Ext.applyIf(a,this.data.selectedColor);var b=Ext.ux.colorpick.ColorUtils.rgb2hsv(a.r,a.g,a.b);a.h=b.h;a.s=b.s;a.v=b.v;this.set('selectedColor',a)}},0,0,0,0,['viewmodel.colorpick-selectormodel'],0,[Ext.ux.colorpick,'SelectorModel'],0);Ext.cmd.derive('Ext.ux.colorpick.SelectorController',Ext.app.ViewController,{initViewModel:function(){var b=this,a=b.getView();a.childViewModel.bind('{selectedColor}',function(b){a.setColor(b)})},destroy:function(){var c=this,b=c.getView(),a=b.childViewModel;if(a){a.destroy();b.childViewModel=null}Ext.app.ViewController.prototype.destroy.call(this)},changeHSV:function(a){var b=this.getView(),d=b.getColor(),c;Ext.applyIf(a,d);c=Ext.ux.colorpick.ColorUtils.hsv2rgb(a.h,a.s,a.v);Ext.apply(a,c);b.setColor(a)},onColorMapHandleDrag:function(a,b){this.changeHSV({s:a,v:1-b})},onValueSliderHandleDrag:function(a){this.changeHSV({v:1-a})},onSaturationSliderHandleDrag:function(a){this.changeHSV({s:1-a})},onHueSliderHandleDrag:function(a){this.changeHSV({h:1-a})},onAlphaSliderHandleDrag:function(c){var a=this.getView(),d=a.getColor(),b=Ext.applyIf({a:1-c},d);a.setColor(b);a.el.repaint()},onPreviousColorSelected:function(c,a){var b=this.getView();b.setColor(a)},onOK:function(){var b=this,a=b.getView();a.fireEvent('ok',a,a.getValue())},onCancel:function(){this.fireViewEvent('cancel',this.getView())},onResize:function(){var c=this,h=c.getView(),b=h.childViewModel,a=c.getReferences(),d,f,g,e;if(!c.hasResizedOnce){c.hasResizedOnce=!0;return}d=b.get('hue');f=b.get('saturation');g=b.get('value');e=b.get('alpha');console.log('h='+d);a.colorMap.setPosition(b.getData());a.hueSlider.setHue(d);a.satSlider.setSaturation(f);a.valueSlider.setValue(g);a.alphaSlider.setAlpha(e)}},0,0,0,0,['controller.colorpick-selectorcontroller'],0,[Ext.ux.colorpick,'SelectorController'],0);Ext.cmd.derive('Ext.ux.colorpick.ColorPreview',Ext.Component,{style:'position: relative',html:'
    ',cls:'x-colorpreview',height:256,onRender:function(){var a=this;Ext.Component.prototype.onRender.apply(this,arguments);a.mon(a.el.down('.btn'),'click',a.onClick,a)},onClick:function(){this.fireEvent('click',this,this.color)},setColor:function(b){var a=this,c=a.getEl();if(!c){return}a.color=b;a.applyBgStyle(b)},bgStyleTpl:Ext.create('Ext.XTemplate',Ext.isIE&&Ext.ieVersion<10?"filter: progid:DXImageTransform.Microsoft.gradient(GradientType=0, startColorstr='#{hexAlpha}{hex}', endColorstr='#{hexAlpha}{hex}');":'background: {rgba};'),applyBgStyle:function(a){var h=this,b=Ext.ux.colorpick.ColorUtils,g=h.getEl().down('.filter'),f,d,e,c;f=b.rgb2hex(a.r,a.g,a.b);d=Ext.util.Format.hex(Math.floor(a.a*255),2);e=b.getRGBAString(a);c=this.bgStyleTpl.apply({hex:f,hexAlpha:d,rgba:e});g.applyStyles(c)}},0,['colorpickercolorpreview'],['component','box','colorpickercolorpreview'],{'component':!0,'box':!0,'colorpickercolorpreview':!0},['widget.colorpickercolorpreview'],0,[Ext.ux.colorpick,'ColorPreview'],0);Ext.cmd.derive('Ext.ux.colorpick.SliderController',Ext.app.ViewController,{boxReady:function(e){var b=this,d=b.getDragContainer(),c=b.getDragHandle(),a=c.dd;a.constrain=!0;a.constrainTo=d.getEl();a.initialConstrainTo=a.constrainTo;a.on('drag',b.onHandleDrag,b)},getDragHandle:function(){return this.view.lookupReference('dragHandle')},getDragContainer:function(){return this.view.lookupReference('dragHandleContainer')},onHandleDrag:function(i){var b=this,g=b.getView(),c=b.getDragContainer(),f=b.getDragHandle(),h=f.getY()-c.getY(),e=c.getEl(),d=e.getHeight(),a=h/d;if(a>0.99){a=1}g.fireEvent('handledrag',a)},onMouseDown:function(c){var b=this,a=b.getDragHandle(),d=c.getY();a.setY(d);b.onHandleDrag();a.el.repaint();a.dd.onMouseDown(c,a.dd.el)},onDragStart:function(c){var b=this,a=b.getDragHandle();a.dd.onDragStart(c,a.dd.el)},onMouseUp:function(){var a=this.getDragHandle();a.dd.dragEnded=!0}},0,0,0,0,['controller.colorpick-slidercontroller'],0,[Ext.ux.colorpick,'SliderController'],0);Ext.cmd.derive('Ext.ux.colorpick.Slider',Ext.container.Container,{controller:'colorpick-slidercontroller',baseCls:'x-colorpicker-slider',layout:'center',referenceHolder:!0,listeners:{element:'el',mousedown:'onMouseDown',mouseup:'onMouseUp',dragstart:'onDragStart'},items:{xtype:'container',cls:'x-colorpicker-draghandle-container',reference:'dragHandleContainer',height:'100%',items:{xtype:'component',cls:'x-colorpicker-draghandle-outer',reference:'dragHandle',width:'100%',height:1,draggable:!0,html:'
    '}},getDragHandle:function(){return this.lookupReference('dragHandle')},getDragContainer:function(){return this.lookupReference('dragHandleContainer')}},0,['colorpickerslider'],['component','box','container','colorpickerslider'],{'component':!0,'box':!0,'container':!0,'colorpickerslider':!0},['widget.colorpickerslider'],0,[Ext.ux.colorpick,'Slider'],0);Ext.cmd.derive('Ext.ux.colorpick.SliderAlpha',Ext.ux.colorpick.Slider,{cls:'x-colorpicker-alpha',gradientStyleTpl:Ext.create('Ext.XTemplate',Ext.isIE&&Ext.ieVersion<10?"filter: progid:DXImageTransform.Microsoft.gradient(GradientType=0, startColorstr='#FF{hex}', endColorstr='#00{hex}');":'background: -mox-linear-gradient(top, rgba({r}, {g}, {b}, 1) 0%, rgba({r}, {g}, {b}, 0) 100%);background: -webkit-linear-gradient(top,rgba({r}, {g}, {b}, 1) 0%, rgba({r}, {g}, {b}, 0) 100%);background: -o-linear-gradient(top, rgba({r}, {g}, {b}, 1) 0%, rgba({r}, {g}, {b}, 0) 100%);background: -ms-linear-gradient(top, rgba({r}, {g}, {b}, 1) 0%, rgba({r}, {g}, {b}, 0) 100%);background: linear-gradient(to bottom, rgba({r}, {g}, {b}, 1) 0%, rgba({r}, {g}, {b}, 0) 100%);'),setAlpha:function(h){var d=this,g=d.getDragContainer(),a=d.getDragHandle(),f=g.getEl(),e=f.getHeight(),c,b;if(!a.dd||!a.dd.constrain){return}if(typeof a.dd.dragEnded!=='undefined'&&!a.dd.dragEnded){return}b=e*(1-h/100);c=a.getEl();c.setStyle({top:b})},setColor:function(a){var b=this,e=b.getDragContainer(),c,d;if(!b.getEl()){return}c=Ext.ux.colorpick.ColorUtils.rgb2hex(a.r,a.g,a.b);d=e.getEl().down('.x-autocontainer-innerCt');d.applyStyles(b.gradientStyleTpl.apply({hex:c,r:a.r,g:a.g,b:a.b}))}},0,['colorpickerslideralpha'],['component','box','container','colorpickerslider','colorpickerslideralpha'],{'component':!0,'box':!0,'container':!0,'colorpickerslider':!0,'colorpickerslideralpha':!0},['widget.colorpickerslideralpha'],0,[Ext.ux.colorpick,'SliderAlpha'],0);Ext.cmd.derive('Ext.ux.colorpick.SliderSaturation',Ext.ux.colorpick.Slider,{cls:'x-colorpicker-saturation',gradientStyleTpl:Ext.create('Ext.XTemplate',Ext.isIE&&Ext.ieVersion<10?"filter: progid:DXImageTransform.Microsoft.gradient(GradientType=0, startColorstr='#{hex}', endColorstr='#ffffff');":'background: -mox-linear-gradient(top, #{hex} 0%, #ffffff 100%);background: -webkit-linear-gradient(top, #{hex} 0%,#ffffff 100%);background: -o-linear-gradient(top, #{hex} 0%,#ffffff 100%);background: -ms-linear-gradient(top, #{hex} 0%,#ffffff 100%);background: linear-gradient(to bottom, #{hex} 0%,#ffffff 100%);'),setSaturation:function(g){var d=this,h=d.getDragContainer(),a=d.getDragHandle(),f=h.getEl(),e=f.getHeight(),b,c;if(!a.dd||!a.dd.constrain){return}if(typeof a.dd.dragEnded!=='undefined'&&!a.dd.dragEnded){return}b=1-g/100;c=e*b;a.getEl().setStyle({top:c+'px'})},setHue:function(e){var b=this,d=b.getDragContainer(),a,c;if(!b.getEl()){return}a=Ext.ux.colorpick.ColorUtils.hsv2rgb(e,1,1);c=Ext.ux.colorpick.ColorUtils.rgb2hex(a.r,a.g,a.b);d.getEl().applyStyles(b.gradientStyleTpl.apply({hex:c}))}},0,['colorpickerslidersaturation'],['component','box','container','colorpickerslider','colorpickerslidersaturation'],{'component':!0,'box':!0,'container':!0,'colorpickerslider':!0,'colorpickerslidersaturation':!0},['widget.colorpickerslidersaturation'],0,[Ext.ux.colorpick,'SliderSaturation'],0);Ext.cmd.derive('Ext.ux.colorpick.SliderValue',Ext.ux.colorpick.Slider,{cls:'x-colorpicker-value',gradientStyleTpl:Ext.create('Ext.XTemplate',Ext.isIE&&Ext.ieVersion<10?"filter: progid:DXImageTransform.Microsoft.gradient(GradientType=0, startColorstr='#{hex}', endColorstr='#000000');":'background: -mox-linear-gradient(top, #{hex} 0%, #000000 100%);background: -webkit-linear-gradient(top, #{hex} 0%,#000000 100%);background: -o-linear-gradient(top, #{hex} 0%,#000000 100%);background: -ms-linear-gradient(top, #{hex} 0%,#000000 100%);background: linear-gradient(to bottom, #{hex} 0%,#000000 100%);'),setValue:function(h){var d=this,g=d.getDragContainer(),a=d.getDragHandle(),f=g.getEl(),e=f.getHeight(),b,c;if(!a.dd||!a.dd.constrain){return}if(typeof a.dd.dragEnded!=='undefined'&&!a.dd.dragEnded){return}b=1-h/100;c=e*b;a.getEl().setStyle({top:c+'px'})},setHue:function(e){var b=this,d=b.getDragContainer(),a,c;if(!b.getEl()){return}a=Ext.ux.colorpick.ColorUtils.hsv2rgb(e,1,1);c=Ext.ux.colorpick.ColorUtils.rgb2hex(a.r,a.g,a.b);d.getEl().applyStyles(b.gradientStyleTpl.apply({hex:c}))}},0,['colorpickerslidervalue'],['component','box','container','colorpickerslider','colorpickerslidervalue'],{'component':!0,'box':!0,'container':!0,'colorpickerslider':!0,'colorpickerslidervalue':!0},['widget.colorpickerslidervalue'],0,[Ext.ux.colorpick,'SliderValue'],0);Ext.cmd.derive('Ext.ux.colorpick.SliderHue',Ext.ux.colorpick.Slider,{cls:'x-colorpicker-hue',afterRender:function(){var c=this,a=c.gradientUrl,b=c.el;Ext.ux.colorpick.Slider.prototype.afterRender.call(this);if(!a){a=b.getStyle('background-image');a=a.substring(4,a.length-1);if(a.indexOf('"')===0){a=a.substring(1,a.length-1)}Ext.ux.colorpick.SliderHue.prototype.gradientUrl=a}b.setStyle('background-image','none');b=c.getDragContainer().layout.getElementTarget();b.createChild({tag:'img',cls:'x-colorpicker-hue-gradient',src:a})},setHue:function(h){var d=this,g=d.getDragContainer(),a=d.getDragHandle(),f=g.getEl(),e=f.getHeight(),c,b;if(!a.dd||!a.dd.constrain){return}if(typeof a.dd.dragEnded!=='undefined'&&!a.dd.dragEnded){return}b=e*(360-h)/360;c=a.getEl();c.setStyle({top:b+'px'})}},0,['colorpickersliderhue'],['component','box','container','colorpickerslider','colorpickersliderhue'],{'component':!0,'box':!0,'container':!0,'colorpickerslider':!0,'colorpickersliderhue':!0},['widget.colorpickersliderhue'],0,[Ext.ux.colorpick,'SliderHue'],0);Ext.cmd.derive('Ext.ux.colorpick.Selector',Ext.container.Container,{controller:'colorpick-selectorcontroller',width:580,height:337,cls:'x-colorpicker',padding:10,layout:{type:'hbox',align:'stretch'},defaultBindProperty:'value',twoWayBindable:['value'],fieldWidth:50,fieldPad:5,showPreviousColor:!1,showOkCancelButtons:!1,listeners:{resize:'onResize'},constructor:function(c){var a=this,b=Ext.Factory.viewModel('colorpick-selectormodel');a.childViewModel=b;a.items=[a.getMapAndHexRGBFields(b),a.getSliderAndHField(b),a.getSliderAndSField(b),a.getSliderAndVField(b),a.getSliderAndAField(b),a.getPreviewAndButtons(b,c)];Ext.container.Container.prototype.constructor.apply(this,arguments)},updateColor:function(b){var a=this;a.mixins.colorselection.updateColor.call(a,b);a.childViewModel.set('selectedColor',b)},updatePreviousColor:function(a){this.childViewModel.set('previousColor',a)},getMapAndHexRGBFields:function(d){var c=this,a={top:0,right:c.fieldPad,bottom:0,left:0},b=c.fieldWidth;return {xtype:'container',viewModel:d,cls:'x-colorpicker-escape-overflow',flex:1,layout:{type:'vbox',align:'stretch'},margin:'0 10 0 0',items:[{xtype:'colorpickercolormap',reference:'colorMap',flex:1,bind:{position:{bindTo:'{selectedColor}',deep:!0},hue:'{selectedColor.h}'},listeners:{handledrag:'onColorMapHandleDrag'}},{xtype:'container',layout:'hbox',defaults:{labelAlign:'top',labelSeparator:'',allowBlank:!1,onChange:function(){if(this.isValid()){Ext.form.field.Base.prototype.onChange.apply(this,arguments)}}},items:[{xtype:'textfield',fieldLabel:'HEX',flex:1,bind:'{hex}',margin:a,readOnly:!0},{xtype:'numberfield',fieldLabel:'R',bind:'{red}',width:b,hideTrigger:!0,maxValue:255,minValue:0,margin:a},{xtype:'numberfield',fieldLabel:'G',bind:'{green}',width:b,hideTrigger:!0,maxValue:255,minValue:0,margin:a},{xtype:'numberfield',fieldLabel:'B',bind:'{blue}',width:b,hideTrigger:!0,maxValue:255,minValue:0,margin:0}]}]}},getSliderAndHField:function(b){var a=this;return {xtype:'container',viewModel:b,cls:'x-colorpicker-escape-overflow',width:a.fieldWidth,layout:{type:'vbox',align:'stretch'},items:[{xtype:'colorpickersliderhue',reference:'hueSlider',flex:1,bind:{hue:'{selectedColor.h}'},listeners:{handledrag:'onHueSliderHandleDrag'}},{xtype:'numberfield',fieldLabel:'H',labelAlign:'top',width:a.fieldWidth,labelSeparator:'',bind:'{hue}',hideTrigger:!0,maxValue:360,minValue:0,allowBlank:!1,margin:0}]}},getSliderAndSField:function(b){var a=this;return {xtype:'container',viewModel:b,cls:'x-colorpicker-escape-overflow',width:a.fieldWidth,layout:{type:'vbox',align:'stretch'},margin:{right:a.fieldPad,left:a.fieldPad},items:[{xtype:'colorpickerslidersaturation',reference:'satSlider',flex:1,bind:{saturation:'{saturation}',hue:'{selectedColor.h}'},listeners:{handledrag:'onSaturationSliderHandleDrag'}},{xtype:'numberfield',fieldLabel:'S',labelAlign:'top',labelSeparator:'',bind:'{saturation}',hideTrigger:!0,maxValue:100,minValue:0,allowBlank:!1,margin:0}]}},getSliderAndVField:function(a){var b=this;return {xtype:'container',viewModel:a,cls:'x-colorpicker-escape-overflow',width:b.fieldWidth,layout:{type:'vbox',align:'stretch'},items:[{xtype:'colorpickerslidervalue',reference:'valueSlider',flex:1,bind:{value:'{value}',hue:'{selectedColor.h}'},listeners:{handledrag:'onValueSliderHandleDrag'}},{xtype:'numberfield',fieldLabel:'V',labelAlign:'top',labelSeparator:'',bind:'{value}',hideTrigger:!0,maxValue:100,minValue:0,allowBlank:!1,margin:0}]}},getSliderAndAField:function(b){var a=this;return {xtype:'container',viewModel:b,cls:'x-colorpicker-escape-overflow',width:a.fieldWidth,layout:{type:'vbox',align:'stretch'},margin:{left:a.fieldPad},items:[{xtype:'colorpickerslideralpha',reference:'alphaSlider',flex:1,bind:{alpha:'{alpha}',color:{bindTo:'{selectedColor}',deep:!0}},listeners:{handledrag:'onAlphaSliderHandleDrag'}},{xtype:'numberfield',fieldLabel:'A',labelAlign:'top',labelSeparator:'',bind:'{alpha}',hideTrigger:!0,maxValue:100,minValue:0,allowBlank:!1,margin:0}]}},getPreviewAndButtons:function(c,b){var a=[{xtype:'colorpickercolorpreview',flex:1,bind:{color:{bindTo:'{selectedColor}',deep:!0}}}];if(b.showPreviousColor){a.push({xtype:'colorpickercolorpreview',flex:1,bind:{color:{bindTo:'{previousColor}',deep:!0}},listeners:{click:'onPreviousColorSelected'}})}if(b.showOkCancelButtons){a.push({xtype:'button',text:'OK',margin:'10 0 0 0',handler:'onOK'},{xtype:'button',text:'Cancel',margin:'10 0 0 0',handler:'onCancel'})}return {xtype:'container',viewModel:c,width:70,margin:'0 0 0 10',items:a,layout:{type:'vbox',align:'stretch'}}}},1,['colorselector'],['component','box','container','colorselector'],{'component':!0,'box':!0,'container':!0,'colorselector':!0},['widget.colorselector'],[[Ext.ux.colorpick.Selection.prototype.mixinId||Ext.ux.colorpick.Selection.$className,Ext.ux.colorpick.Selection]],[Ext.ux.colorpick,'Selector'],0);Ext.cmd.derive('Ext.ux.colorpick.ButtonController',Ext.app.ViewController,{afterRender:function(a){a.updateColor(a.getColor())},destroy:function(){var a=this.getView(),b=a.colorPickerWindow;if(b){b.destroy();a.colorPickerWindow=a.colorPicker=null}Ext.app.ViewController.prototype.destroy.call(this)},getPopup:function(){var b=this.getView(),a=b.colorPickerWindow,c;if(!a){a=Ext.create(b.getPopup());b.colorPickerWindow=a;a.colorPicker=b.colorPicker=c=a.lookupReference('selector');c.setFormat(b.getFormat());c.on({ok:'onColorPickerOK',cancel:'onColorPickerCancel',scope:this});a.on({close:'onColorPickerCancel',scope:this})}return a},onClick:function(){var e=this,d=e.getView(),b=d.getColor(),c=e.getPopup(),a=c.colorPicker;a.setColor(b);a.setPreviousColor(b);c.showBy(d,'tl-br?')},onColorPickerOK:function(b){var a=this.getView(),c=b.getColor(),d=a.colorPickerWindow;d.hide();a.setColor(c)},onColorPickerCancel:function(){var b=this.getView(),a=b.colorPickerWindow;a.hide()},syncColor:function(a){var b=this.getView();Ext.ux.colorpick.ColorUtils.setBackground(b.filterEl,a)}},0,0,0,0,['controller.colorpick-buttoncontroller'],0,[Ext.ux.colorpick,'ButtonController'],0);Ext.cmd.derive('Ext.ux.colorpick.Button',Ext.Component,{controller:'colorpick-buttoncontroller',baseCls:'x-colorpicker-button',width:20,height:20,childEls:['btnEl','filterEl'],config:{popup:{lazy:!0,$value:{xtype:'window',closeAction:'hide',referenceHolder:!0,minWidth:540,minHeight:200,layout:'fit',header:!1,resizable:!0,items:{xtype:'colorselector',reference:'selector',showPreviousColor:!0,showOkCancelButtons:!0}}}},defaultBindProperty:'value',twoWayBindable:'value',renderTpl:'
    ',listeners:{click:'onClick',element:'btnEl'},updateColor:function(b){var a=this,c=a.colorPicker;a.mixins.colorselection.updateColor.call(a,b);Ext.ux.colorpick.ColorUtils.setBackground(a.filterEl,b);if(c){c.setColor(b)}},updateFormat:function(b){var a=this.colorPicker;if(a){a.setFormat(b)}}},0,['colorbutton'],['component','box','colorbutton'],{'component':!0,'box':!0,'colorbutton':!0},['widget.colorbutton'],[[Ext.ux.colorpick.Selection.prototype.mixinId||Ext.ux.colorpick.Selection.$className,Ext.ux.colorpick.Selection]],[Ext.ux.colorpick,'Button'],0);Ext.cmd.derive('Ext.ux.colorpick.Field',Ext.form.field.Picker,{editable:!1,matchFieldWidth:!1,beforeBodyEl:['
    '],cls:'x-colorpicker-field',childEls:['swatchEl'],config:{popup:{lazy:!0,$value:{xtype:'window',closeAction:'hide',referenceHolder:!0,minWidth:540,minHeight:200,layout:'fit',header:!1,resizable:!0,items:{xtype:'colorselector',reference:'selector',showPreviousColor:!0,showOkCancelButtons:!0}}}},afterRender:function(){Ext.form.field.Picker.prototype.afterRender.call(this);this.updateValue(this.value)},createPicker:function(){var a=this,c=a.getPopup(),b;a.colorPickerWindow=c=Ext.create(c);a.colorPicker=b=c.lookupReference('selector');b.setFormat(a.getFormat());b.setColor(a.getColor());b.on({ok:'onColorPickerOK',cancel:'onColorPickerCancel',scope:a});c.on({close:'onColorPickerCancel',scope:a});return a.colorPickerWindow},onColorPickerOK:function(a){this.setColor(a.getColor());this.collapse()},onColorPickerCancel:function(){this.collapse()},onExpand:function(){var a=this.getColor();this.colorPicker.setPreviousColor(a)},setValue:function(c){var a=this,b=a.applyValue(c);(arguments.callee.$previous||Ext.form.field.Picker.prototype.setValue).call(this,b);a.updateValue(b)},updateFormat:function(b){var a=this.colorPicker;if(a){a.setFormat(b)}},updateValue:function(c){var a=this,b;if(!a.syncing){a.syncing=!0;a.setColor(c);a.syncing=!1}b=a.getColor();Ext.ux.colorpick.ColorUtils.setBackground(a.swatchEl,b);if(a.colorPicker){a.colorPicker.setColor(b)}}},0,['colorfield'],['component','box','field','textfield','pickerfield','colorfield'],{'component':!0,'box':!0,'field':!0,'textfield':!0,'pickerfield':!0,'colorfield':!0},['widget.colorfield'],[[Ext.ux.colorpick.Selection.prototype.mixinId||Ext.ux.colorpick.Selection.$className,Ext.ux.colorpick.Selection]],[Ext.ux.colorpick,'Field'],0);Ext.cmd.derive('Ext.ux.rating.Picker',Ext.Widget,{focusable:!0,cachedConfig:{family:'monospace',glyphs:'☆★',minimum:1,limit:5,overStyle:null,rounding:1,scale:'125%',selectedStyle:null,tooltip:null,trackOver:!0,value:null,tooltipText:null,trackingValue:null},config:{animate:null},element:{cls:'ux-rating-picker',reference:'element',children:[{reference:'innerEl',cls:'ux-rating-picker-inner',listeners:{click:'onClick',mousemove:'onMouseMove',mouseenter:'onMouseEnter',mouseleave:'onMouseLeave'},children:[{reference:'valueEl',cls:'ux-rating-picker-value'},{reference:'trackerEl',cls:'ux-rating-picker-tracker'}]}]},defaultBindProperty:'value',twoWayBindable:'value',overCls:'ux-rating-picker-over',trackOverCls:'ux-rating-picker-track-over',applyGlyphs:function(a){if(typeof a==='string'){a=[a.charAt(0),a.charAt(1)]}else {if(typeof a[0]==='number'){a=[String.fromCharCode(a[0]),String.fromCharCode(a[1])]}}return a},applyOverStyle:function(a){this.trackerEl.applyStyles(a)},applySelectedStyle:function(a){this.valueEl.applyStyles(a)},applyTooltip:function(a){if(a&&typeof a!=='function'){if(!a.isTemplate){a=new Ext.XTemplate(a)}a=a.apply.bind(a)}return a},applyTrackingValue:function(a){return this.applyValue(a)},applyValue:function(a){if(a!==null){var b=this.getRounding(),c=this.getLimit(),d=this.getMinimum();a=Math.round(Math.round(a/b)*b*1000)/1000;a=ac?c:a}return a},onClick:function(a){var b=this.valueFromEvent(a);this.setValue(b)},onMouseEnter:function(){this.element.addCls(this.overCls)},onMouseLeave:function(){this.element.removeCls(this.overCls)},onMouseMove:function(a){var b=this.valueFromEvent(a);this.setTrackingValue(b)},updateFamily:function(a){this.element.setStyle('fontFamily',"'"+a+"'")},updateGlyphs:function(){this.refreshGlyphs()},updateLimit:function(){this.refreshGlyphs()},updateScale:function(a){this.element.setStyle('fontSize',a)},updateTooltip:function(){this.refreshTooltip()},updateTooltipText:function(c){var e=this.innerEl,b=Ext.tip&&Ext.tip.QuickTipManager,d=b&&b.tip,a;if(b){e.dom.setAttribute('data-qtip',c);this.trackerEl.dom.setAttribute('data-qtip',c);a=d&&d.activeTarget;a=a&&a.el;if(a&&e.contains(a)){d.update(c)}}},updateTrackingValue:function(d){var a=this,b=a.trackerEl,c=a.valueToPercent(d);b.setStyle('width',c);a.refreshTooltip()},updateTrackOver:function(a){this.element[a?'addCls':'removeCls'](this.trackOverCls)},updateValue:function(e,g){var a=this,h=a.getAnimate(),c=a.valueEl,f=a.valueToPercent(e),b,d;if(a.isConfiguring||!h){c.setStyle('width',f)}else {c.stopAnimation();c.animate(Ext.merge({from:{width:a.valueToPercent(g)},to:{width:f}},h))}a.refreshTooltip();if(!a.isConfiguring){if(a.hasListeners.change){a.fireEvent('change',a,e,g)}b=a.getWidgetColumn&&a.getWidgetColumn();d=b&&a.getWidgetRecord&&a.getWidgetRecord();if(d&&b.dataIndex){d.set(b.dataIndex,e)}}},afterCachedConfig:function(){this.refresh();return Ext.Widget.prototype.afterCachedConfig.apply(this,arguments)},initConfig:function(a){this.isConfiguring=!0;this.callParent([a]);this.refresh()},setConfig:function(){var a=this;a.isReconfiguring=!0;a.callParent(arguments);a.isReconfiguring=!1;a.refresh();return a},destroy:function(){this.tip=Ext.destroy(this.tip);Ext.Widget.prototype.destroy.call(this)},privates:{getGlyphTextNode:function(b){var a=b.lastChild;if(!a||a.nodeType!==3){a=b.ownerDocument.createTextNode('');b.appendChild(a)}return a},getTooltipData:function(){var a=this;return {component:a,tracking:a.getTrackingValue(),trackOver:a.getTrackOver(),value:a.getValue()}},refresh:function(){var a=this;if(a.invalidGlyphs){a.refreshGlyphs(!0)}if(a.invalidTooltip){a.refreshTooltip(!0)}},refreshGlyphs:function(j){var a=this,g=!j&&(a.isConfiguring||a.isReconfiguring),i,c,h,b,d,e,f;if(!g){i=a.getGlyphTextNode(a.innerEl.dom);f=a.getGlyphTextNode(a.valueEl.dom);e=a.getGlyphTextNode(a.trackerEl.dom);c=a.getGlyphs();h=a.getLimit();for(b=d='';h--;){d+=c[0];b+=c[1]}i.nodeValue=d;f.nodeValue=b;e.nodeValue=b}a.invalidGlyphs=g},refreshTooltip:function(f){var a=this,c=!f&&(a.isConfiguring||a.isReconfiguring),b=a.getTooltip(),d,e;if(!c){b=a.getTooltip();if(b){d=a.getTooltipData();e=b(d);a.setTooltipText(e)}}a.invalidTooltip=c},valueFromEvent:function(g){var a=this,e=a.innerEl,j=g.getX(),d=a.getRounding(),i=e.getX(),c=j-i,f=e.getWidth(),h=a.getLimit(),b;if(a.getInherited().rtl){c=f-c}b=c/f*h;b=Math.ceil(b/d)*d;return b},valueToPercent:function(a){a=a/this.getLimit()*100;return a+'%'}}},0,['rating'],['widget','rating'],{'widget':!0,'rating':!0},['widget.rating'],0,[Ext.ux.rating,'Picker'],0);Ext.cmd.derive('common.BandFilter',Ext.container.ButtonGroup,{alternateClassName:['Portal.BandFilter'],filters:['g','r','i','z','Y','RGB'],defaultFilter:'rgb',buttonWidth:30,vertical:!1,config:{availableFilters:[]},initComponent:function(){var a=this;if(!a.filters){Ext.Error.raise('You must specify a filters config.')}a.items=this.createFilters();var b='bands';if(a.itemId){b='bands_'+a.itemId}if(a.vertical){a.layout={type:'vbox',align:'stretch'}}else {a.layout={type:'hbox',align:'stretch'}}a.defaults={allowDepress:!1,enableToggle:!0,toggleGroup:b,toggleHandler:function(b){if(b.pressed){var c=b.value;a.fireEvent('onfilter',c,b,a)}}};Ext.container.ButtonGroup.prototype.initComponent.apply(this,arguments)},createFilters:function(){var c=this,f=[],d,a,b;for(var e=0;e1){b.width=50}if(c.defaultFilter==a){b.pressed=!0}f.push(b)}return f},getFilter:function(){var g=this,a=null,b,e,c;b=this.filters;e=Array();c=this.items;for(var d=0;d0){a.getTrigger('clear').show();a.getTrigger('search').hide();if(this.getMinSearch()>0&&a.getValue().length>=this.getMinSearch()){if(a.isValid()&&a.getValue()!==''){this.fireEvent('search',a.getValue(),this)}}}else {a.getTrigger('clear').hide();a.getTrigger('search').show();this.fireEvent('cancel')}},buffer:500},triggers:{clear:{cls:'x-form-clear-trigger',handler:function(a){a.reset();this.getTrigger('clear').hide();this.getTrigger('search').show();this.fireEvent('cancel')},hidden:!0},search:{cls:'x-form-search-trigger',handler:function(){}}},config:{minSearch:null}},0,['common-searchfield'],['component','box','field','textfield','common-searchfield'],{'component':!0,'box':!0,'field':!0,'textfield':!0,'common-searchfield':!0},['widget.common-searchfield'],0,[common,'SearchField'],0);Ext.cmd.derive('common.data.proxy.CrsfToken',Ext.Base,{singleton:!0,constructor:function(){Ext.Ajax.on('beforerequest',function(b,a){if(!(/^http:.*/.test(a.url)||/^https:.*/.test(a.url))){if(typeof a.headers=='undefined'){a.headers={'Accept':'application/json','X-CSRFToken':Ext.util.Cookies.get('csrftoken')}}else {a.headers['Application']='application/json';a.headers['X-CSRFToken']=Ext.util.Cookies.get('csrftoken')}}},this)}},1,0,0,0,0,0,[common.data.proxy,'CrsfToken'],0);Ext.cmd.derive('common.data.proxy.Django',Ext.data.proxy.Rest,{headers:{'Accept':'application/json;'},startParam:'offset',sortParam:'ordering',reader:{type:'json',rootProperty:'results',totalProperty:'count'},writer:{},actionMethods:{create:'POST',read:'GET',update:'PATCH',destroy:'DELETE'},encodeSorters:function(b){var c=[],a,d;for(var e in b){a=b[e];d=(a.getDirection()=='DESC'?'-':'')+a.getProperty();c.push(d)}return c.join()},getParams:function(b){var a=Ext.data.proxy.Rest.prototype.getParams.apply(this,arguments);if(!b.isReadOperation){return a}var c=b.getFilters();delete a[this.getFilterParam()];Ext.each(c,function(f){var e=f.getProperty(),d=f.getValue(),c,g;switch(f.getOperator()){case '<':c=Ext.String.format('{0}__lt',e);a[c]=d;break;case '<=':c=Ext.String.format('{0}__lte',e);a[c]=d;break;case '>=':c=Ext.String.format('{0}__gte',e);a[c]=d;break;case '>':c=Ext.String.format('{0}__gt',e);a[c]=d;break;case '!=':c=Ext.String.format('{0}__ne',e);a[c]=d;break;case 'in':c=Ext.String.format('{0}__in',e);a[c]=d.join();break;case 'like':c=Ext.String.format('{0}__icontains',e);a[c]=d;break;case 'range':c=Ext.String.format('{0}__range',e);g=Ext.String.format('{0},{1}',d[0],d[1]);a[c]=g;break;default:a[e]=d;}});return a},buildUrl:function(c){var b=this,e=c.getOperation(),h=e.getRecords(),g=h?h[0]:null,i=b.getFormat(),a=b.getUrl(c),d,f;if(g&&!g.phantom){d=g.getId()}else {d=e.getId()}if(b.getAppendId()&&b.isValidId(d)||e.action==='update'){if(!a.match(b.slashRe)){a+='/'}a+=encodeURIComponent(d);f=c.getParams();if(f){delete f[b.getIdParam()]}a+='/'}if(i){if(!a.match(b.periodRe)){a+='.'}a+=i}c.setUrl(a);return Ext.data.RestProxy.superclass.buildUrl.apply(this,arguments)}},0,0,0,0,['proxy.django'],0,[common.data.proxy,'Django'],0);Ext.cmd.derive('common.store.MyStore',Ext.data.Store,{proxy:{type:'django'},listeners:{load:function(h,i,e,f){if(e===!1){var g=h.proxy;var d=g.reader;if(d.jsonData){var b=d.jsonData;if(b!='undefined'){console.log('Load Failure: %o',b);Ext.Msg.alert('Status',b.msg)}}else {var a=f.getError(),c;switch(a.status){case 403:c=JSON.parse(a.response.responseText);Ext.MessageBox.show({title:a.status+' - '+a.statusText,msg:c.detail,buttons:Ext.MessageBox.OK,icon:Ext.MessageBox.WARNING,closable:!1,scope:this,fn:function(){var c=window.location.pathname,b=window.location.hostname,a;a=Ext.String.format('http://{0}/dri/api/api-auth/login/?next={1}',b,c);window.location.assign(a)}});break;case 408:c=JSON.parse(a.response.responseText);Ext.MessageBox.show({title:a.status+' - '+a.statusText,msg:'Maximum execution time exceeded.',buttons:Ext.MessageBox.OK,icon:Ext.MessageBox.WARNING});break;}}}}}},0,0,0,0,0,0,[common.store,'MyStore'],0);Ext.cmd.derive('common.contact.ContactController',Ext.app.ViewController,{onFormCancel:function(){this.getView().lookupReference('windowForm').getForm().reset();this.getView().close()},onFormSubmit:function(){var c=this.getView(),d=c.lookupReference('windowForm'),b=d.getForm(),a=b.getValues();a.current_url=window.location.href;a.current_user=window.sessionStorage.dri_username;if(b.isValid()){Ext.Ajax.request({url:'/dri/api/contact/',method:'POST',params:a,success:function(){c.close();Ext.MessageBox.alert('Thank you!','Your inquiry has been sent. We will respond as soon as possible.')},failure:function(a,b){Ext.MessageBox.show({title:a.status+' - '+a.statusText,msg:'Sorry, message was not sent.',buttons:Ext.MessageBox.OK,icon:Ext.MessageBox.WARNING,scope:this})}})}}},0,0,0,0,['controller.contact'],0,[common.contact,'ContactController'],0);Ext.cmd.derive('common.contact.Contact',Ext.window.Window,{reference:'contactWindow',title:'Contact Us',controller:'contact',width:400,height:500,minWidth:300,minHeight:380,layout:'fit',resizable:!0,modal:!0,defaultFocus:'firstName',closeAction:'destroy',items:[{xtype:'form',reference:'windowForm',layout:{type:'vbox',align:'stretch'},border:!1,bodyPadding:10,fieldDefaults:{msgTarget:'side',labelAlign:'top',labelWidth:100,labelStyle:'font-weight:bold'},items:[{margin:'0 0 20 0',xtype:'component',html:['Thank you for visiting our site! We welcome your feedback; ','please click the button below to send us a message. We will ','respond to your inquiry as quickly as possible.']},{xtype:'textfield',fieldLabel:'Name',name:'name',allowBlank:!1},{xtype:'textfield',fieldLabel:'Your Email Address',vtype:'email',name:'from',allowBlank:!1},{xtype:'textfield',fieldLabel:'Subject',name:'subject',allowBlank:!1},{xtype:'textareafield',fieldLabel:'How can we help?',labelAlign:'top',flex:1,margin:'0',name:'message',allowBlank:!1,emptyText:'Describe the problem or share your ideas.'}],buttons:[{text:'Cancel',handler:'onFormCancel'},{text:'Send',handler:'onFormSubmit'}]}]},0,['form-contact-window'],['component','box','container','panel','window','form-contact-window'],{'component':!0,'box':!0,'container':!0,'panel':!0,'window':!0,'form-contact-window':!0},['widget.form-contact-window'],0,[common.contact,'Contact'],0);Ext.cmd.derive('common.footer.FooterController',Ext.app.ViewController,{onClickContact:function(){if(this.wincontact){this.wincontact=null}this.wincontact=Ext.create('common.contact.Contact',{});this.wincontact.show()}},0,0,0,0,['controller.footer'],0,[common.footer,'FooterController'],0);Ext.cmd.derive('common.footer.Footer',Ext.toolbar.Toolbar,{controller:'footer',cls:'des-portal-footer',height:28,layout:{pack:'center',align:'middle'},viewModel:{data:{}},items:[{xtype:'tbtext',html:'Powered by LIneA | Dark Energy Survey | NCSA',cls:'des-portal-footer-text'}]},0,['dri-footer'],['component','box','container','toolbar','dri-footer'],{'component':!0,'box':!0,'container':!0,'toolbar':!0,'dri-footer':!0},['widget.dri-footer'],0,[common.footer,'Footer'],0);Ext.cmd.derive('common.ToolbarController',Ext.app.ViewController,{listen:{component:{'dri-header':{afterrender:'onAfterRender'}}},logout:function(){var b=window.location.protocol,c=window.location.host,a=Ext.String.format('{0}//{1}/dri/api/api-auth/logout/?next=/dri/apps/',b,c);window.location.assign(a)},projectHome:function(){var b=window.location.protocol,c=window.location.host,a=Ext.String.format('{0}//{1}/',b,c);window.location.assign(a)},contact:function(){if(this.wincontact){this.wincontact=null}this.wincontact=Ext.create('common.contact.Contact',{});this.wincontact.show()},about:function(){window.open('http://www.linea.gov.br')},onAfterRender:function(){var a=this;a.loadUsername();a.loaddTutorials()},loaddTutorials:function(){var b=this,c=b.getViewModel(),a=c.getStore('tutorials');a.addFilter([{property:'app_name',value:c.get('internal_name')}]);a.load({scope:this,callback:b.onLoadTutorials})},onLoadTutorials:function(){var b=this,d=b.getViewModel(),c=d.getStore('tutorials'),a=b.lookupReference('headermenututorials');if(c.count()>0){a.enable()}else {a.disable()}},tutorials:function(){var b=this,c=b.getViewModel(),a=c.getStore('tutorials');if(this.wincontact){this.wincontact=null}this.wintutorials=Ext.create('common.help.Tutorials',{store:a});this.wintutorials.show()},loadUsername:function(){var a=this,b=a.getViewModel();Ext.Ajax.request({url:'/dri/api/logged/get_logged/?format=json',success:function(c){var a=JSON.parse(c.responseText);b.set('username',a.username);window.dri_username=a.username}})}},0,0,0,0,['controller.toolbar'],0,[common,'ToolbarController'],0);Ext.cmd.derive('common.help.TutorialsController',Ext.app.ViewController,{onSelect:function(e,c){var d=this,b=d.lookupReference('video'),a;a=Ext.create('Ext.ux.IFrame',{flex:1,src:c.get('ttr_src')});b.removeAll();b.add(a)}},0,0,0,0,['controller.tutorials'],0,[common.help,'TutorialsController'],0);Ext.cmd.derive('common.help.Tutorials',Ext.window.Window,{title:'Tutorials',controller:'tutorials',config:{store:null},initComponent:function(){var a=this;Ext.apply(this,{layout:'border',width:700,height:400,minWidth:300,minHeight:280,resizable:!0,modal:!0,closeAction:'destroy',items:[{xtype:'grid',reference:'tutorials_grid',region:'west',split:!0,hideHeaders:!0,width:200,store:a.getStore(),columns:[{dataIndex:'ttr_title',flex:1}],listeners:{select:'onSelect'}},{xtype:'panel',region:'center',reference:'video',split:!0,layout:{type:'vbox',pack:'start',align:'stretch'}}]});Ext.window.Window.prototype.initComponent.apply(this,arguments)}},0,['tutorials-window'],['component','box','container','panel','window','tutorials-window'],{'component':!0,'box':!0,'container':!0,'panel':!0,'window':!0,'tutorials-window':!0},['widget.tutorials-window'],0,[common.help,'Tutorials'],0);Ext.cmd.derive('common.header.Toolbar',Ext.toolbar.Toolbar,{controller:'toolbar',cls:'des-portal-headerbar toolbar-btn-shadow',layout:{type:'hbox',align:'middle'},viewModel:{data:{home:'',desPortalLogo:'resources/des-portal-logo.png',tooltip:'Home',username:''},stores:{tutorials:{fields:['id','application','application_display_name','ttr_title','ttr_src','ttr_description'],remoteSort:!0,remoteFilter:!0,autoLoad:!1,pageSize:0,proxy:{type:'django',url:'/dri/api/tutorial/'}}}},viewItems:function(){return [{xtype:'component',cls:'des-portal-logo',bind:{html:'Home'}},{xtype:'component',cls:'des-portal-appname',bind:{html:'{name}'},flex:1},'->',{xtype:'button',cls:'delete-focus-bg',ui:'white-toolbar',scale:'medium',itemId:'btnusername',bind:{text:'{username}'}},{xtype:'button',iconCls:'x-fa fa-home',ui:'white-toolbar',cls:'delete-focus-bg',scale:'medium',handler:'projectHome',tooltip:'Home of the Science Server'},{xtype:'button',reference:'headermenu',iconCls:'x-fa fa-bars',cls:'delete-focus-bg',ui:'white-toolbar',scale:'medium',arrowVisible:!1,menu:[{text:'About LIneA',handler:'about'},{text:'Contact Us',handler:'contact'},{text:'Help',iconCls:'x-fa fa-question-circle',reference:'headermenututorials',disabled:!0,handler:'tutorials'},'-',{text:'Log out',iconCls:'x-fa fa-sign-out',handler:'logout'}]}]},initComponent:function(){this.items=this.viewItems();Ext.toolbar.Toolbar.prototype.initComponent.call(this)},afterRender:function(){var c=this,b=window.location.href,a;a=b.split('#')[0];c.getViewModel().set('home',a);Ext.toolbar.Toolbar.prototype.afterRender.apply(this,arguments)}},0,['dri-header'],['component','box','container','toolbar','dri-header'],{'component':!0,'box':!0,'container':!0,'toolbar':!0,'dri-header':!0},['widget.dri-header'],0,[common.header,'Toolbar'],0);Ext.cmd.derive('common.model.Dataset',Ext.data.Model,{fields:[{name:'id',type:'int'},{name:'tag',type:'int'},{name:'tag_display_name',type:'string'},{name:'release',type:'int'},{name:'release_display_name',type:'string'},{name:'tite',type:'int'},{name:'run',type:'string'},{name:'date',type:'string'},{name:'tli_tilename',type:'string'},{name:'tli_ra',type:'float'},{name:'tli_ra',type:'float'},{name:'tli_dec',type:'float'},{name:'tli_urall',type:'float'},{name:'tli_udecll',type:'float'},{name:'tli_uraur',type:'float'},{name:'tli_udecur',type:'float'},{name:'release_tag',type:'string',convert:function(b,a){return Ext.String.format('{0} - {1}',a.get('release_display_name'),a.get('tag_display_name'))}},{name:'image_src_ptif',type:'string'},{name:'image_src_thumbnails',type:'string'},{name:'g',type:'string',convert:function(b,a){return Ext.String.format('{0}/{1}/{2}.png',a.get('image_src_thumbnails'),'g',a.get('tli_tilename'))}},{name:'r',type:'string',convert:function(b,a){return Ext.String.format('{0}/{1}/{2}.png',a.get('image_src_thumbnails'),'r',a.get('tli_tilename'))}},{name:'i',type:'string',convert:function(b,a){return Ext.String.format('{0}/{1}/{2}.png',a.get('image_src_thumbnails'),'i',a.get('tli_tilename'))}},{name:'z',type:'string',convert:function(b,a){return Ext.String.format('{0}/{1}/{2}.png',a.get('image_src_thumbnails'),'z',a.get('tli_tilename'))}},{name:'y',type:'string',convert:function(b,a){return Ext.String.format('{0}/{1}/{2}.png',a.get('image_src_thumbnails'),'y',a.get('tli_tilename'))}},{name:'irg',type:'string',convert:function(b,a){return Ext.String.format('{0}/{1}/{2}.png',a.get('image_src_thumbnails'),'irg',a.get('tli_tilename'))}}],isInsideTile:function(a,e){var d=this,a=parseFloat(a),e=parseFloat(e),b,c,f,g;if(a>180){a=a-360}b=d.get('tli_urall');c=d.get('tli_uraur');f=d.get('tli_udecll');g=d.get('tli_udecur');if(b>180){b=b-360}if(c>180){c=c-360}if(a>b&&af&&e180){value=value-360}value=Ext.util.Format.number(value,'0.0000');return parseFloat(value)}},{name:'decul',type:'float',convert:function(b,a){value=a.get('tli_decul');value=Ext.util.Format.number(value,'0.0000');return parseFloat(value)}},{name:'rall',type:'float',convert:function(b,a){value=a.get('tli_rall');if(value>180){value=value-360}value=Ext.util.Format.number(value,'0.0000');return parseFloat(value)}},{name:'decll',type:'float',convert:function(b,a){value=a.get('tli_decll');value=Ext.util.Format.number(value,'0.0000');return parseFloat(value)}},{name:'ralr',type:'float',convert:function(b,a){value=a.get('tli_ralr');if(value>180){value=value-360}value=Ext.util.Format.number(value,'0.0000');return parseFloat(value)}},{name:'declr',type:'float',convert:function(b,a){value=a.get('tli_declr');value=Ext.util.Format.number(value,'0.0000');return parseFloat(value)}},{name:'raur',type:'float',convert:function(b,a){value=a.get('tli_raur');if(value>180){value=value-360}value=Ext.util.Format.number(value,'0.0000');return parseFloat(value)}},{name:'decur',type:'float',convert:function(b,a){value=a.get('tli_decur');value=Ext.util.Format.number(value,'0.0000');return parseFloat(value)}}]},0,0,0,0,0,0,[common.model,'Footprint'],0);Ext.cmd.derive('common.model.Map',Ext.data.Model,{fields:[{name:'id',type:'int'},{name:'prd_name',type:'string'},{name:'prd_display_name',type:'string'},{name:'prd_user_display_name',type:'string'},{name:'prd_class',type:'int'},{name:'prd_is_public',type:'boolean'},{name:'pcl_display_name',type:'string'},{name:'pcl_is_system',type:'boolean'},{name:'pgr_group',type:'int'},{name:'pgr_display_name',type:'string'},{name:'epr_original_id',type:'string'},{name:'prd_filter',type:'string'},{name:'prl_related',type:'string'},{name:'prl_cross_identification',type:'string'},{name:'prl_cross_property',type:'string'},{name:'tablename',type:'string'},{name:'mpa_nside',type:'int'},{name:'mpa_ordering',type:'string'}]},0,0,0,0,0,0,[common.model,'Map'],0);Ext.cmd.derive('common.model.Survey',Ext.data.Model,{fields:[{name:'id',type:'int'},{name:'srv_release',type:'int'},{name:'srv_filter',type:'int'},{name:'filter',type:'string'},{name:'srv_project',type:'string'},{name:'srv_display_name',type:'string'},{name:'srv_url',type:'string'},{name:'srv_target',type:'string'},{name:'srv_fov',type:'string'}]},0,0,0,0,0,0,[common.model,'Survey'],0);Ext.cmd.derive('common.model.Tag',Ext.data.Model,{fields:[{name:'id',type:'int'},{name:'tag_release',type:'int'},{name:'tag_name',type:'string'},{name:'tag_display_name',type:'string'},{name:'tag_status',type:'boolean'},{name:'tag_install_date',type:'date'},{name:'is_new',type:'boolean',convert:function(e,b){if(b.get('tag_install_date')){var a=b.get('tag_install_date'),c=-2,d=Ext.Date.add(new Date(),Ext.Date.DAY,c);return Ext.Date.between(a,d,a)}}}]},0,0,0,0,0,0,[common.model,'Tag'],0);Ext.cmd.derive('common.store.Tiles',common.store.MyStore,{pageSize:100,remoteFilter:!0,remoteSort:!0,proxy:{type:'django',url:'/dri/api/tiles/'},filterByRaDec:function(a,d){var a=parseFloat(a),d=parseFloat(d),b,c,e;this.each(function(f){if(a>180){a=a-360}b=f.get('tli_urall');c=f.get('tli_uraur');if(b>180){b=b-360}if(c>180){c=c-360}if(ba&&f.get('tli_udecur')>d){e=f;return !1}},this);return e}},0,0,0,0,['store.tiles'],0,[common.store,'Tiles'],0);Ext.cmd.derive('common.store.Datasets',common.store.Tiles,{model:'common.model.Dataset',remoteFilter:!0,remoteSort:!0,pageSize:100,proxy:{type:'django',url:'/dri/api/dataset/'}},0,0,0,0,['store.datasets'],0,[common.store,'Datasets'],0);Ext.cmd.derive('common.store.Footprints',common.store.Tiles,{model:'common.model.Footprint',remoteFilter:!0,remoteSort:!0,pageSize:0,proxy:{type:'django',url:'/dri/api/footprints/',reader:{type:'array'}}},0,0,0,0,['store.footprints'],0,[common.store,'Footprints'],0);Ext.cmd.derive('common.store.Maps',common.store.MyStore,{model:'common.model.Map',autoLoad:!1,pageSize:0,remoteFilter:!0,proxy:{type:'django',url:'/dri/api/map/'}},0,0,0,0,['store.maps'],0,[common.store,'Maps'],0);Ext.cmd.derive('common.store.MyTreeStore',Ext.data.TreeStore,{proxy:{type:'django',appendId:!1,reader:{type:'json',rootProperty:'children'}},listeners:{load:function(h,i,e,f){if(e===!1){var g=h.proxy;var d=g.reader;if(d.jsonData){var b=d.jsonData;if(b!='undefined'){console.log('Load Failure: %o',b);Ext.Msg.alert('Status',b.msg)}}else {var a=f.getError(),c=JSON.parse(a.response.responseText);switch(a.status){case 403:Ext.MessageBox.show({title:a.status+' - '+a.statusText,msg:c.detail,buttons:Ext.MessageBox.OK,icon:Ext.MessageBox.WARNING,closable:!1,scope:this,fn:function(){var c=window.location.pathname,b=window.location.hostname,a;a=Ext.String.format('http://{0}/dri/api/api-auth/login/?next={1}',b,c);window.location.assign(a)}});break;default:Ext.MessageBox.show({title:a.status+' - '+a.statusText,msg:c.detail,buttons:Ext.MessageBox.OK,icon:Ext.MessageBox.WARNING,scope:this});}}}}}},0,0,0,0,0,0,[common.store,'MyTreeStore'],0);Ext.cmd.derive('common.store.Surveys',common.store.MyStore,{model:'common.model.Survey',autoLoad:!1,remoteFilter:!0,remoteSort:!0,pageSize:0,proxy:{type:'django',url:'/dri/api/surveys/'}},0,0,0,0,['store.surveys'],0,[common.store,'Surveys'],0);Ext.cmd.derive('common.store.Tags',common.store.MyStore,{model:'common.model.Tag',remoteFilter:!0,remoteSort:!0,proxy:{type:'django',url:'/dri/api/tags/'},sorters:[{property:'tag_display_name',direction:'ASC'}]},0,0,0,0,['store.tags'],0,[common.store,'Tags'],0);Ext.cmd.derive('visiomatic.Interface',Ext.Base,{makeToolbar:function(){return Ext.create('Ext.toolbar.Toolbar',{items:[]})},makeToolbarButtons:function(){var a=this,c=a.getAuxTools(),b=[];if(a.getEnableShift()){b.push({xtype:'button',tooltip:'Switch between Visiomatic / Aladdin.',iconCls:'x-fa fa-exchange',scope:a,handler:a.onShift})}if(a.getEnableLink()){b.push({xtype:'button',tooltip:'Get link',iconCls:'x-fa fa-link',scope:a,handler:a.getLinkToPosition})}if(c.length>0){Ext.each(c,function(a){b.push(a)})}return b},makeMousePosition:function(){var a=this.getMap();return Ext.DomHelper.append(a._controlCorners['topright'],{tag:'div',cls:'leaflet-right leaflet-control leaflet-control-wcs-dialog visiomatic-mouse-position',html:'
    Mouse RA, Dec (0,0)
    '})}},0,0,0,0,0,0,[visiomatic,'Interface'],0);Ext.cmd.derive('visiomatic.VisiomaticModel',Ext.app.ViewModel,{data:{release:null,tag:null,dataset:null}},0,0,0,0,['viewmodel.visiomatic'],0,[visiomatic,'VisiomaticModel'],0);Ext.cmd.derive('visiomatic.VisiomaticController',Ext.app.ViewController,{},0,0,0,0,['controller.visiomatic'],0,[visiomatic,'VisiomaticController'],0);Ext.cmd.derive('visiomatic.catalog.Catalogs',Ext.tree.Panel,{initComponent:function(){var a=this;Ext.apply(this,{emptyText:'No data to display.',hideHeaders:!0,rootVisible:!1,useArrows:!0,selModel:{mode:'SINGLE'},columns:[{xtype:'treecolumn',text:'Name',flex:2,sortable:!0,dataIndex:'text',renderer:a.getTooltipName}],tbar:[{xtype:'textfield',emptyText:'Search by name',reference:'SearchField',flex:1,triggers:{clear:{cls:'x-form-clear-trigger',handler:'cancelFilter',hidden:!0},search:{cls:' x-form-search-trigger'}},listeners:{change:'filterCatalogByname',buffer:500}}]});Ext.tree.Panel.prototype.initComponent.apply(this,arguments)},getTooltipName:function(d,e,b){var f=this,c,a;if(b.get('leaf')){c=new Ext.XTemplate('
    ','{prd_display_name}','','


    {description}

    ','
    ','
    ');a=c.apply(b.data);e.tdAttr='data-qtip="'+a+'"'}return d}},0,['visiomatic-catalogs-tree'],['component','box','container','panel','tablepanel','treepanel','visiomatic-catalogs-tree'],{'component':!0,'box':!0,'container':!0,'panel':!0,'tablepanel':!0,'treepanel':!0,'visiomatic-catalogs-tree':!0},['widget.visiomatic-catalogs-tree'],0,[visiomatic.catalog,'Catalogs'],0);Ext.cmd.derive('visiomatic.model.CatalogTree',Ext.data.Model,{fields:[{name:'id'},{name:'prd_name',type:'string'},{name:'prd_display_name',type:'string'},{name:'prd_class',type:'int'},{name:'pcl_display_name',type:'string'},{name:'pcl_is_system',type:'boolean'},{name:'pgr_group',type:'int'},{name:'pgr_display_name',type:'string'},{name:'epr_original_id',type:'string'},{name:'epr_name',type:'string'},{name:'epr_username',type:'string'},{name:'epr_start_date',type:'date'},{name:'epr_end_date',type:'date'},{name:'epr_readme',type:'string'},{name:'epr_comment',type:'string'},{name:'ctl_num_columns',type:'int'},{name:'ctl_num_tiles',type:'int'},{name:'ctl_num_objects',type:'int'},{name:'cds_source',type:'string'},{name:'cds_fieldnames',type:'string'},{name:'editable',type:'boolean',defaultValue:!1},{name:'markable',type:'boolean',defaultValue:!1},{name:'release_display_name',type:'string'},{name:'external_catalog',type:'boolean',defaultValue:!1}]},0,0,0,0,0,0,[visiomatic.model,'CatalogTree'],0);Ext.cmd.derive('visiomatic.store.CatalogsTree',common.store.MyTreeStore,{model:'visiomatic.model.CatalogTree',autoLoad:!1,remoteFilter:!0,proxy:{api:{read:'/dri/api/catalog/get_class_tree_by_group/'}}},0,0,0,0,['store.catalogs-overlay-tree'],0,[visiomatic.store,'CatalogsTree'],0);Ext.cmd.derive('visiomatic.store.Overlays',Ext.data.ArrayStore,{remoteFilter:!1,remoteSort:!1,autoLoad:!1,pageSize:0},0,0,0,0,['store.overlays'],0,[visiomatic.store,'Overlays'],0);Ext.cmd.derive('visiomatic.model.FilterCondition',Ext.data.Model,{fields:[{name:'id',type:'int','default':null,persist:!1},{name:'filterset',type:'int'},{name:'fcd_property',type:'int'},{name:'fcd_property_name',type:'string'},{name:'fcd_operation',type:'string'},{name:'fcd_value',type:'string'},{name:'operator_display_name',type:'string',persist:!1},{name:'property_display_name',type:'string',persist:!1,convert:function(a,c){var b=c.get('fcd_property_name');switch(b){case '_meta_rating':a='Rating';break;case '_meta_reject':a='Reject';break;}return a}}]},0,0,0,0,0,0,[visiomatic.model,'FilterCondition'],0);Ext.cmd.derive('visiomatic.store.FilterConditions',Ext.data.Store,{model:'visiomatic.model.FilterCondition',remoteFilter:!1,pageSize:0,sorters:[{property:'id',direction:'ASC'}]},0,0,0,0,['store.overlay-filter-conditions'],0,[visiomatic.store,'FilterConditions'],0);Ext.cmd.derive('visiomatic.catalog.CatalogViewModel',Ext.app.ViewModel,{stores:{catalogs:{type:'catalogs-overlay-tree'},overlays:{type:'overlays'}},data:{visiomatic:null,currentColor:'1dff00',currentFilters:null,pointType:0,pointSize:1},links:{currentCatalog:{type:'visiomatic.model.CatalogTree',create:!0},dataset:{type:'common.model.Dataset',create:!0}}},0,0,0,0,['viewmodel.catalogoverlay'],0,[visiomatic.catalog,'CatalogViewModel'],0);Ext.cmd.derive('visiomatic.model.Object',Ext.data.Model,{idProperty:'_meta_id',fields:[{name:'_meta_id'},{name:'_meta_catalog_id',type:'int'},{name:'_meta_is_system',type:'boolean'},{name:'_meta_ra',type:'float'},{name:'_meta_dec',type:'float'},{name:'_meta_radius',type:'float'}]},0,0,0,0,0,0,[visiomatic.model,'Object'],0);Ext.cmd.derive('visiomatic.store.Objects',common.store.MyStore,{remoteFilter:!0,remoteSort:!0,autoLoad:!1,model:'visiomatic.model.Object',pageSize:5000,proxy:{type:'django',timeout:90000,api:{read:'/dri/api/catalogobjects/'}}},0,0,0,0,['store.overlay-objects'],0,[visiomatic.store,'Objects'],0);Ext.cmd.derive('visiomatic.store.ExternalObjects',common.store.MyStore,{remoteFilter:!0,remoteSort:!1,autoLoad:!1,model:'visiomatic.model.Object',pageSize:10000,proxy:{type:'django',timeout:60000,api:{read:'/dri/api/vizier/'}}},0,0,0,0,['store.overlay-external-objects'],0,[visiomatic.store,'ExternalObjects'],0);Ext.cmd.derive('visiomatic.model.Overlay',Ext.data.Model,{idProperty:'id',fields:[{name:'id',type:'int'},{name:'name',type:'string'},{name:'color',type:'string'},{name:'visible',type:'boolean'},{name:'status',type:'string'},{name:'status_message',type:'string'},{name:'count',type:'int'},{name:'total_count',type:'int'},{name:'excess',type:'int'},{name:'catalog'},{name:'layers'},{name:'objects'},{name:'filters'},{name:'objectUrl'},{name:'pointSize',type:'float'}]},0,0,0,0,0,0,[visiomatic.model,'Overlay'],0);Ext.cmd.derive('visiomatic.filter.FiltersController',Ext.app.ViewController,{listen:{component:{'overlay-filters-window':{changecatalog:'onChangeCatalog'}}},onChangeCatalog:function(b){var a=this,d=a.getViewModel(),c=d.getStore('contents');a.clearImputs();c.addFilter({property:'pcn_product_id',value:b.get('id')})},onLoadContents:function(a){},onAddFilter:function(){var d=this,a=d.getViewModel(),b=a.get('content'),f=a.get('operator'),h=a.get('value'),g=a.getStore('filters'),e=a.get('afilters'),c;c=Ext.create('visiomatic.model.FilterCondition',{fcd_property:b.get('id'),fcd_property_name:b.get('column_name'),fcd_operation:f.get('name'),fcd_value:h,property_display_name:b.get('display_name'),operator_display_name:f.get('display_name')});e.push(c);g.add(c);a.set('afilters',e);d.clearImputs();d.checkHaveFilters()},onRemoveFilterClick:function(f,d,c,e,g,b){var a=this;Ext.MessageBox.confirm('','The Filter will be removed. Do you want continue?',function(h){if(h==='yes'){b.drop();a.createAFilters();a.checkHaveFilters()}},this)},createAFilters:function(){var c=this,e=c.getViewModel(),d=c.lookup('gridFilters'),b=d.getStore(),a=[];console.log(b);b.each(function(b){console.log(b);a.push(b)},this);e.set('afilters',a)},checkHaveFilters:function(){var b=this,a=b.getViewModel(),c=a.get('afilters'),d=b.lookup('BtnApply');if(c.length>0){a.set('haveFilters',!0)}else {a.set('haveFilters',!1)}},onSelectProperty:function(f,c){var a=this,b=a.getViewModel(),d=b.get('afilters'),e},onSelectOperator:function(b,a){},onCancelFilter:function(){this.getView().close()},onApplyFilter:function(){var a=this,e=a.getView(),c=a.getViewModel(),d=c.get('currentCatalog'),b=c.get('afilters');if(b.length>0){a.applyFilters(d,b)}},applyFilters:function(c,d){var b=this,a=b.getView();a.fireEvent('applyfilters',d,c,b);a.close()},clearImputs:function(){var e=this,a=e.getReferences(),c=a.cmbProperty,b=a.cmbOperator,d=a.txtValue;c.reset();b.reset();d.reset()}},0,0,0,0,['controller.overlay_filters'],0,[visiomatic.filter,'FiltersController'],0);Ext.cmd.derive('visiomatic.model.CatalogContent',Ext.data.Model,{fields:[{name:'id',type:'int'},{name:'product_id',type:'int'},{name:'setting_id',type:'int'},{name:'column_name',type:'string'},{name:'class_id',type:'int'},{name:'category',type:'string'},{name:'display_name',type:'string'},{name:'ucd',type:'string'},{name:'unit',type:'string'},{name:'reference',type:'string'},{name:'mandatory',type:'boolean'},{name:'content_setting',type:'int'},{name:'is_visible',type:'boolean'},{name:'order',type:'int'}]},0,0,0,0,0,0,[visiomatic.model,'CatalogContent'],0);Ext.cmd.derive('visiomatic.store.ProductDisplayContents',common.store.MyStore,{model:'visiomatic.model.CatalogContent',remoteFilter:!0,remoteSort:!1,pageSize:0,proxy:{url:'/dri/api/productcontent/get_display_content/'},sorters:[{property:'order',direction:'ASC'},{property:'display_name',direction:'ASC'}],ucds:['meta.id;meta.main','pos.eq.ra;meta.main','pos.eq.dec;meta.main'],check_ucds:function(){var a=this,b=[];a.each(function(c){if(a.ucds.indexOf(c.get('ucd'))!==-1){b.push(!0)}},a);if(b.length===a.ucds.length){return !0}else {return !1}}},0,0,0,0,['store.overlay-product-display-contents'],0,[visiomatic.store,'ProductDisplayContents'],0);Ext.cmd.derive('visiomatic.filter.FiltersModel',Ext.app.ViewModel,{stores:{contents:{type:'overlay-product-display-contents',storeId:'productContents',autoLoad:!1},filters:{type:'overlay-filter-conditions',storeId:'filterConditions',autoLoad:!1},operators:{fields:['name','display_name','type'],data:[{name:'=',display_name:'is equal to',type:'text'},{name:'!=',display_name:'is not equal to',type:'text'},{name:'>',display_name:'is greater than',type:'text'},{name:'>=',display_name:'is greater than or equal to',type:'text'},{name:'<',display_name:'is less than',type:'text'},{name:'<=',display_name:'is less than or equal to',type:'text'}]}},data:{operator:null,value:null,haveFilters:!1,afilters:[]},links:{currentCatalog:{type:'visiomatic.model.CatalogTree',create:!0}}},0,0,0,0,['viewmodel.overlay_filters'],0,[visiomatic.filter,'FiltersModel'],0);Ext.cmd.derive('visiomatic.filter.FiltersWindow',Ext.window.Window,{title:'Filters',width:500,height:300,modal:!0,autoShow:!0,controller:'overlay_filters',viewModel:'overlay_filters',closeAction:'destroy',bodyPadding:20,layout:{type:'vbox',align:'stretch'},config:{currentCatalog:null},items:[{xtype:'form',reference:'filterForm',layout:{type:'vbox',align:'stretch'},border:!1,fieldDefaults:{msgTarget:'side',labelAlign:'top',labelWidth:100,labelStyle:'font-weight:bold'},items:[{xtype:'fieldset',title:'Add condition',items:[{xtype:'fieldcontainer',layout:'hbox',defaults:{flex:1},items:[{xtype:'combobox',emptyText:'Property',itemId:'cmbProperty',reference:'cmbProperty',publishes:'id',displayField:'display_name',bind:{store:'{contents}',selection:'{content}'},listeners:{select:'onSelectProperty'},minChars:0,queryMode:'local',editable:!1,readOnly:!1,margin:'0 5 0 0'},{xtype:'combobox',itemId:'cmbOperator',reference:'cmbOperator',publishes:'name',displayField:'display_name',emptyText:'Operator',bind:{store:'{operators}',selection:'{operator}'},listeners:{select:'onSelectOperator'},minChars:0,queryMode:'local',editable:!1,readOnly:!1,forceSelection:!0,margin:'0 5 0 0'},{xtype:'textfield',reference:'txtValue',emptyText:'Value',bind:{value:'{value}'},margin:'0 5 0 0',allowBlank:!1},{xtype:'button',iconCls:'x-fa fa-plus',width:40,flex:!1,handler:'onAddFilter'}]}]}]},{xtype:'grid',reference:'gridFilters',layout:'fit',border:!0,framed:!0,hideHeaders:!0,flex:1,bind:{store:'{filters}'},viewConfig:{markDirty:!1},columns:[{text:'Property',dataIndex:'property_display_name',flex:1},{text:'Operator',dataIndex:'operator_display_name',flex:1},{text:'Value',dataIndex:'fcd_value',flex:1},{xtype:'actioncolumn',width:60,sortable:!1,menuDisabled:!0,align:'center',items:[{iconCls:'x-fa fa-minus-circle color-soft-red',tooltip:'Remove condition',handler:'onRemoveFilterClick'}]}]}],buttons:[{text:'Cancel',handler:'onCancelFilter'},{text:'Ok',reference:'BtnApply',handler:'onApplyFilter',bind:{disabled:'{!haveFilters}'}}],setCurrentCatalog:function(a){var b=this;if(a&&a.get('id')>0){b.currentCatalog=a;b.getViewModel().set('currentCatalog',a);b.fireEvent('changecatalog',a)}},setFilterSet:function(a){var d=this,c=d.getViewModel(),b=c.getStore('filters'),e=d.lookup('btnDeleteFilterSet'),f=d.lookup('txtFilter');if(a&&a.get('id')>0){c.set('filterSet',a);c.set('filterName',a.get('fst_name'));f.setReadOnly(!0);e.enable();b.addFilter({property:'filterset',value:a.get('id')});b.load()}else {c.set('filterName',null);f.setReadOnly(!1);e.disable();b.clearFilter();b.removeAll(!0)}}},0,['overlay-filters-window'],['component','box','container','panel','window','overlay-filters-window'],{'component':!0,'box':!0,'container':!0,'panel':!0,'window':!0,'overlay-filters-window':!0},['widget.overlay-filters-window'],0,[visiomatic.filter,'FiltersWindow'],0);Ext.cmd.derive('visiomatic.catalog.CatalogController',Ext.app.ViewController,{listen:{component:{'visiomatic-catalog-overlay':{changedataset:'onChangeDataset'}}},baseFilters:[],winFilter:null,onChangeDataset:function(d){var a=this,c=a.getViewModel(),b=c.getStore('overlays');b.removeAll();a.loadCatalogs()},loadCatalogs:function(){var c=this,d=c.getViewModel(),b=d.getStore('catalogs'),a;a=[{property:'group',operator:'in',value:['objects_catalog','targets','value_added_catalogs','external_catalogs']}];c.baseFilters=a;b.addFilter(a);b.load()},onSelectCatalog:function(){var a=this,d=a.getViewModel(),b=d.get('currentFilters'),c=a.lookup('CatalogsTree'),f=c.selection,e=a.lookup('btnFilter');b=[]},filterCatalogByname:function(){var a=this,h=a.lookup('CatalogsTree'),b=a.lookup('SearchField'),c=h.getStore(),d=b.getValue(),e=[],f;if(d.length>0){b.getTrigger('clear').show();if(c.isLoading()){console.log('Store is Loading: %o',c.isLoading());var g=c.getProxy();g.abort();console.log('Store proxy abort')}f={property:'search',value:d};e.push(f);a.filterCatalogs(e)}else {b.getTrigger('clear').hide();a.filterCatalogs()}},filterCatalogs:function(a){var d=this,g=d.getViewModel(),b=g.getStore('catalogs'),f=d.baseFilters,e,c=Ext.clone(f);b.clearFilter(!0);b.removeAll();if(a&&Array.isArray(a)){for(index in a){e=a[index];c.push(e)}}b.filter(c)},cancelFilter:function(){var b=this,a=b.lookup('SearchField');a.reset();b.filterCatalogs();a.getTrigger('clear').hide()},onClickOverlay:function(){var b=this,c=b.getViewModel(),k=b.lookup('CatalogsTree'),d=k.selection,j=c.get('currentColor'),i=c.get('currentFilters'),h=c.getStore('overlays'),e=b.lookup('cmbPointType'),g=e.getValue(),f=c.get('pointSize')/1000,a;c.set('currentCatalog',d);a=Ext.create('visiomatic.model.Overlay',{name:d.get('prd_display_name'),catalog:d,color:Ext.String.format('#{0}',j),visible:!0,count:null,layers:null,pointType:g,pointSize:f,status:'loading',filters:null});h.add(a);if(!d.get('external_catalog')){a.set('objects',Ext.create('visiomatic.store.Objects',{}));a.set('filters',i);b.loadObjects(a)}else {a.set('objects',Ext.create('visiomatic.store.ExternalObjects',{}));a.set('objectUrl',!0);b.loadExternalCatalogObjects(a)}},loadExternalCatalogObjects:function(b){var d=this,f=d.getViewModel(),e=f.get('visiomatic'),c=b.get('objects'),a;a=e.getBounds();c.addFilter([{property:'cds_source',value:b.get('catalog').get('cds_source')},{property:'cds_fieldnames',value:b.get('catalog').get('cds_fieldnames')},{property:'lat',value:a.lat},{property:'lng',value:a.lng},{property:'dlat',value:a.dlat},{property:'dlng',value:a.dlng}]);c.load({callback:function(e,c,a){d.onLoadObjects(b,c,a)}})},loadObjects:function(a){var f=this,h=f.getViewModel(),g=h.get('visiomatic'),b=a.get('objects'),d=a.get('filters'),c=[],e;e=g.getBox();b.addFilter([{property:'product',value:a.get('catalog').get('id')},{property:'coordinates',value:JSON.stringify(e)}]);if(d!==null){Ext.each(d,function(b){c.push({property:b.get('fcd_property_name'),operator:b.get('fcd_operation'),value:b.get('fcd_value')})});b.addFilter(c)}b.load({callback:function(d,c,b){f.onLoadObjects(a,c,b)}})},onLoadObjects:function(a,c,g){var i=this,j=i.getViewModel(),h=j.get('visiomatic'),b=a.get('objects'),d,e;a.set('count',b.count());if(!g){var f=c.error.statusText;if(c.error.status==0){f='Communication Failure or Time out'}d=Ext.String.format('Sorry, there was a server error, and this operation can not be performed.
    Error: {0} - {1}',c.error.status,f);a.set('status','error');a.set('status_message',d);console.log('Server Side ERROR: %o - %o',c.error.status,c.error.statusText)}else {if(b.count()>0){if(b.totalCount>b.pageSize){e=b.totalCount-b.pageSize;d=Ext.String.format('The query returned more objects than the limit.
    {0} objects are not being displayed.
    Limit: {1}
    Query returned: {2}
    ',e,b.pageSize,b.totalCount);a.set('total_count',b.totalCount);a.set('excess',e);a.set('status','alert');a.set('status_message',d)}else {a.set('status','ok')}}else {a.set('status','warning')}layers=h.overlayCatalog(a.get('name'),b,{color:a.get('color'),objectUrl:a.get('objectUrl'),pointType:a.get('pointType'),pointSize:a.get('pointSize')});a.set('layers',layers)}},onRemoveOverlay:function(i,f,h){var g=this,c=g.getViewModel(),e=c.getStore('overlays'),d=c.get('visiomatic'),b=e.getAt(f),a=b.get('layers');if(a!==null){d.showHideLayer(a,!1)}b.erase()},onChangeVisibility:function(i,e,g){var h=this,b=h.getViewModel(),d=b.getStore('overlays'),c=b.get('visiomatic'),f=d.getAt(e),a=f.get('layers');if(a!==null){c.showHideLayer(a,g)}},onClickBtnFilter:function(){var a=this,d=a.getViewModel(),c=a.lookup('CatalogsTree'),b=c.selection;if(b&&b.get('id')>0){a.winFilter=Ext.create('visiomatic.filter.FiltersWindow',{listeners:{scope:a,applyfilters:'onApplyFilters'}});a.winFilter.setCurrentCatalog(b);a.winFilter.show()}},onApplyFilters:function(a,d){var b=this,c=b.getViewModel();if(a.length>0){c.set('currentFilters',a)}}},0,0,0,0,['controller.catalogoverlay'],0,[visiomatic.catalog,'CatalogController'],0);Ext.cmd.derive('visiomatic.catalog.Submit',Ext.form.Panel,{initComponent:function(){var a=this;Ext.apply(this,{bodyPadding:5,layout:{type:'vbox',align:'stretch'},items:[{xtype:'fieldset',flex:1,border:!1,items:[{xtype:'fieldcontainer',layout:'hbox',items:[{xtype:'tbtext',html:'Color:',width:45},{xtype:'colorbutton',bind:'{currentColor}',width:55,margin:'0 20 0 5',tooltip:'Choose a color. Click on the color and then on ok.'}]},{xtype:'fieldcontainer',layout:'hbox',items:[{xtype:'combobox',labelWidth:45,flex:1,reference:'cmbPointType',fieldLabel:'Marker',displayField:'name',valueField:'name',queryMode:'local',store:{fields:['name'],data:[{'name':'circle'},{'name':'ellipse'},{'name':'square'},{'name':'triangle'}]},value:'circle'},{xtype:'numberfield',name:'pointsize',fieldLabel:'Size',labelWidth:40,width:100,bind:'{pointSize}',minValue:1,maxValue:10,margin:'0 0 0 5'}]},{xtype:'button',iconCls:'x-fa fa-filter',text:'Filters',tooltip:'Filters',handler:'onClickBtnFilter',reference:'btnFilter',width:100}]}],buttons:[{text:'Apply',handler:'onClickOverlay'}]});Ext.form.Panel.prototype.initComponent.apply(this,arguments)}},0,['visiomatic-catalogs-submit'],['component','box','container','panel','form','visiomatic-catalogs-submit'],{'component':!0,'box':!0,'container':!0,'panel':!0,'form':!0,'visiomatic-catalogs-submit':!0},['widget.visiomatic-catalogs-submit'],0,[visiomatic.catalog,'Submit'],0);Ext.cmd.derive('visiomatic.catalog.OverlayGrid',Ext.grid.Panel,{initComponent:function(){var a=this;Ext.apply(this,{hideHeaders:!0,viewConfig:{markDirty:!1,listeners:{scope:a,render:a.addTooltipToColumnName,destroy:function(a){delete a.tip}}},columns:[{text:'Visible',xtype:'checkcolumn',dataIndex:'visible',width:30,listeners:{checkchange:'onChangeVisibility'},align:'center'},{text:'Color',dataIndex:'color',width:30,align:'center',renderer:a.renderColumnColor},{text:'Name',dataIndex:'name',tdCls:'nameTdCls',flex:2,renderer:a.renderColumnName},{menuDisabled:!0,xtype:'actioncolumn',width:30,items:[{iconCls:'x-fa fa-trash-o color-overlay-grid-icon',tooltip:'Remove',handler:'onRemoveOverlay'}]}]});Ext.grid.Panel.prototype.initComponent.apply(this,arguments)},addTooltipToColumnName:function(a){var b=this;a.tip=Ext.create('Ext.tip.ToolTip',{target:a.getId(),delegate:a.itemSelector+' .nameTdCls',trackMouse:!0,listeners:{beforeshow:function updateTipBody(c){var d=c.target.component;var e=d.getRecord(c.triggerElement);c.update(b.getTooltipName(e))}}})},getTooltipName:function(a){var f=this,b=a.get('filters'),d,e,c;if(a.get('status')!=='error'){d=Ext.String.format('{0}
    Entries: {1}',a.get('name'),a.get('count'));if(b!==null&&b.length>0){c='
    Filters:
    ';Ext.each(b,function(b){e=Ext.String.format('{0} {1} {2}
    ',b.get('fcd_property_name'),b.get('operator_display_name'),b.get('fcd_value'));c+=e});d+=c}return d}else {return a.get('status_message')}},renderColumnName:function(a,d,b){var c=16;if(a.length>c){a=a.substr(0,c);a=a+'...'}if(b.get('status')!=='loading'&&b.get('status')!=='error'){return Ext.String.format('{0} ({1} entries)',a,b.get('count'))}else {return a}},renderColumnColor:function(a,c,b){switch(b.get('status')){case 'loading':a='';break;case 'ok':a=Ext.String.format('',a);break;case 'alert':msg=b.get('status_message');a='';c.tdAttr='data-qtip= "'+msg+'"';break;case 'warning':a='';break;case 'error':msg=b.get('status_message');a='';break;}return a}},0,['visiomatic-catalogs-overlays-grid'],['component','box','container','panel','tablepanel','gridpanel','grid','visiomatic-catalogs-overlays-grid'],{'component':!0,'box':!0,'container':!0,'panel':!0,'tablepanel':!0,'gridpanel':!0,'grid':!0,'visiomatic-catalogs-overlays-grid':!0},['widget.visiomatic-catalogs-overlays-grid'],0,[visiomatic.catalog,'OverlayGrid'],0);Ext.cmd.derive('visiomatic.catalog.CatalogOverlayWindow',Ext.window.Window,{controller:'catalogoverlay',viewModel:'catalogoverlay',config:{visiomatic:null,dataset:null},initComponent:function(){var a=this;Ext.apply(this,{title:'Catalog Overlay',width:600,height:450,closeAction:'hide',layout:{type:'hbox',align:'stretch'},items:[{xtype:'panel',split:!0,flex:1,framed:!0,layout:{type:'vbox',align:'stretch'},items:[{xtype:'visiomatic-catalogs-tree',reference:'CatalogsTree',flex:1,bind:{store:'{catalogs}'},listeners:{select:'onSelectCatalog'}},{xtype:'visiomatic-catalogs-submit',height:150,bind:{disabled:'{!CatalogsTree.selection.leaf}'}}]},{xtype:'visiomatic-catalogs-overlays-grid',split:!0,framed:!0,flex:1,bind:{store:'{overlays}'}}]});Ext.window.Window.prototype.initComponent.apply(this,arguments)},setVisiomatic:function(a){this.visiomatic=a;this.getViewModel().set('visiomatic',a)},setDataset:function(c){var a=this,d=a.getDataset(),b=!1;if(d!==null&&d.get('id')>0){if(d.get('id')===c.get('id')){b=!1}else {b=!0}}else {b=!0}if(b){a.dataset=c;a.getViewModel().set('dataset',c);a.fireEvent('changedataset',c,a)}}},0,['visiomatic-catalog-overlay'],['component','box','container','panel','window','visiomatic-catalog-overlay'],{'component':!0,'box':!0,'container':!0,'panel':!0,'window':!0,'visiomatic-catalog-overlay':!0},['widget.visiomatic-catalog-overlay'],0,[visiomatic.catalog,'CatalogOverlayWindow'],0);Ext.cmd.derive('visiomatic.download.FitsController',Ext.app.ViewController,{listen:{component:{'target-download-descut':{changeLoadFits:'onChangeLoadFits'}}},listen:{component:{'target-download-descut':{changeLoadFits:'onChangeLoadFits'}}},onChangeLoadFits:function(b,c){var f=this,e=f.getView(),a=e.getViewModel(),d=a.getStore('fitsFiles');a.set('catalog',c);a.set('tilename',b);d.filter([{property:'tilename',value:b},{property:'catalog',value:c}])}},0,0,0,0,['controller.fits-files'],0,[visiomatic.download,'FitsController'],0);Ext.cmd.derive('visiomatic.model.FitsFiles',Ext.data.Model,{proxy:{type:'django',url:'/dri/api/get_fits_by_tilename'},fields:[{name:'tilename',type:'string','default':null,persist:!1},{name:'band',type:'string','default':null,persist:!1},{name:'url',type:'string','default':null,persist:!1}]},0,0,0,0,0,0,[visiomatic.model,'FitsFiles'],0);Ext.cmd.derive('visiomatic.store.FitsFiles',common.store.MyStore,{model:'visiomatic.model.FitsFiles',remoteFilter:!0,pageSize:0,proxy:{url:'/dri/api/get_fits_by_tilename'},sorters:[{property:'tilename',direction:'ASC'}]},0,0,0,0,['store.fits-files'],0,[visiomatic.store,'FitsFiles'],0);Ext.cmd.derive('visiomatic.download.FitsModel',Ext.app.ViewModel,{stores:{fitsFiles:{type:'fits-files'}}},0,0,0,0,['viewmodel.fits-files'],0,[visiomatic.download,'FitsModel'],0);Ext.cmd.derive('visiomatic.download.DescutDownloadWindow',Ext.window.Window,{viewModel:'fits-files',controller:'fits-files',title:'Download',width:600,height:400,modal:!0,autoShow:!0,closeAction:'destroy',layout:{type:'vbox',align:'stretch'},initComponent:function(){var a=this;Ext.apply(this,{layout:'fit',items:[{xtype:'gridpanel',scrollable:!0,bind:{store:'{fitsFiles}'},columns:[{text:'Tile Name',dataIndex:'tilename',flex:1},{text:'Band',dataIndex:'band'},{text:'URL',dataIndex:'url',renderer:function(a,b,c){return ' '}}]}],buttons:[{xtype:'label',text:'Right click "Save link as" to download files',flex:1},{text:'Cancel',scope:a,handler:'onCancel'}]});Ext.window.Window.prototype.initComponent.apply(this,arguments)},onCancel:function(){this.close()},loadFits:function(a,b){var c=this;this.loadFits=a;c.fireEvent('changeLoadFits',a,b)}},0,['target-download-descut'],['component','box','container','panel','window','target-download-descut'],{'component':!0,'box':!0,'container':!0,'panel':!0,'window':!0,'target-download-descut':!0},['widget.target-download-descut'],0,[visiomatic.download,'DescutDownloadWindow'],0);Ext.cmd.derive('visiomatic.Visiomatic',Ext.panel.Panel,{controller:'visiomatic',viewModel:'visiomatic',height:'100%',width:'100%',libL:null,config:{map:null,mapOptions:{fullscreenControl:!0,zoom:1,enableLineaOverlay:!0},prefix:'',enableSidebar:!0,enableSmallCrosshair:!1,enableCatalogs:!1,availableCatalogs:['GALEX_AIS','2MASS','AllWISE','SDSS','PPMXL','Abell','NVSS','FIRST','GAIA_DR1'],enableMiniMap:!1,miniMapOptions:{position:'topright',width:128,height:128,zoomLevelOffset:-6,nativeCelsys:!0},miniMap:null,enableWcs:!0,wcsUnits:[{label:'RA, Dec (Deg)',units:'deg'},{label:'RA, Dec (HMS)',units:'HMS'}],enableScale:!0,image:null,imageLayer:null,imageOptions:{credentials:!0,center:!1,fov:!1,mixingMode:'color',defaultChannel:2,contrast:0.7,gamma:2.8,colorSat:2,channelLabelMatch:'[ugrizY]'},radiusOptions:{weight:2,opacity:0.8,fillOpacity:0.01,color:'#2db92d',dashArray:'5, 5, 1, 5',interactive:!1},catalogOptions:{weight:2,opacity:0.8,fillOpacity:0.01,color:'#2db92d',interactive:!0,pointType:'circle',pointSize:0.001},crosshairOptions:{color:'#90FA3A',weight:1,opacity:0.5,smoothFactor:1,centerPadding:0.001,size:0.005},release:null,tag:null,dataset:null,currentDataset:null,enableTools:!0,auxTools:[],enableLink:!0,enableShift:!0,ready:!1,lradius:null,lcrosshair:null,showCrosshair:!1,enableContextMenu:!0,mlocate:'',showComments:!1},_winCatalogOverlay:null,bind:{release:'{release}',tag:'{tag}',dataset:'{dataset}'},initComponent:function(){var a=this,e=window.location.host,b,d,c;if(window.L){a.libL=window.L}else {console.log('window.L ainda nao esta carregada, incluir no app.json a biblioteca Leaflet')}this.cmpVisiomatic=c=Ext.create('Ext.Component',{id:a.getMapContainer(),width:'100%',height:'100%',listeners:{deactivate:a.onDeactivate}});if(a.getEnableTools()){b=a.makeToolbar();tools=a.makeToolbarButtons();b.add(tools);a.tbar=b}Ext.apply(this,{items:[c]});Ext.panel.Panel.prototype.initComponent.apply(this,arguments)},afterRender:function(){var a=this,c=a.libL,d=a.getMapContainer(),e=a.getMapOptions(),b;Ext.panel.Panel.prototype.afterRender.apply(this,arguments);b=c.map(d,e);b.attributionControl.setPrefix(a.getPrefix());c.control.reticle().addTo(b);b.on('dblclick',a.onDblClick,a);b.on('contextmenu',a.onContextMenuClick,a);b.on('layeradd',a.onLayerAdd,a);b.on('move',a.onMove,a);b.on('mousemove',a.onMouseMove,a);b.on('overlaycatalog',a.showCatalogOverlayWindow,a);b.on('mouseup',a.savePreferences,a);b.on('keypress',a.savePreferences,a);a.setMap(b);if(a.getEnableSidebar()){a.createSidebar()}if(a.getEnableWcs()){a.addWcsController()}if(a.getEnableScale()){a.addScaleController()}a.cmpMousePosition=a.makeMousePosition()},savePreferences:function(){var c=this,a=c.getImageLayer();var b={credentials:!0,channelLabelMatch:'[ugrizY]',mixingMode:a.iipMode,contrast:a.iipContrast,gamma:a.iipGamma,invertCMap:a.iipInvertCMap,colorSat:a.iipColorSat,quality:a.iipQuality};localStorage.removeItem('imageOptions');localStorage.setItem('imageOptions',JSON.stringify(b))},onResize:function(){Ext.panel.Panel.prototype.onResize.apply(this,arguments);var a=this.getMap();if(a){a.invalidateSize()}},onDeactivate:function(){console.log('onDeactivate');var a=this;if(a._winCatalogOverlay){a._winCatalogOverlay.close()}},getMapContainer:function(){return this.getId()+'-placeholder'},createSidebar:function(){var c=this,b=c.libL,f=c.getMap(),e=c.getAvailableCatalogs(),a,d=[];a=b.control.sidebar().addTo(f);b.control.iip.channel().addTo(a);b.control.iip.image().addTo(a);if(c.getEnableCatalogs()){Ext.Array.each(e,function(a){d.push(b.Catalog[a])});b.control.iip.catalog(d).addTo(a)}b.control.iip.region([]).addTo(a);b.control.iip.profile().addTo(a);b.control.iip.snapshot().addTo(a);a.addTabList()},createSmallCrosshair:function(){var b=this,a=b.getRaDec(),c={color:'#90FA3A',weight:1,opacity:0.8,smoothFactor:1,centerPadding:5.0E-4,size:0.0015};b.drawSmallCrosshair(a.ra,a.dec,c)},addWcsController:function(){var a=this,c=a.libL,d=a.getMap(),b=a.getWcsUnits();c.control.wcs({coordinates:b,position:'topright'}).addTo(d)},addScaleController:function(){var a=this,b=a.libL,c=a.getMap();b.control.scale.wcs({pixels:!1}).addTo(c)},setCurrentDataset:function(a){var b=this;b.currentDataset=a},setImage:function(e,d){var a=this,i=a.libL,j=a.getMap(),h=a.getMiniMap(),b=a.getImageLayer(),c=a.getImageOptions(),f,k,g;a.setReady(!1);if(a._winCatalogOverlay!==null){a._winCatalogOverlay.close();a._winCatalogOverlay=null}d=d||{};if(b){c={credentials:c.credentials,channelLabelMatch:'[ugrizY]',mixingMode:b.iipMode,contrast:b.iipContrast,gamma:b.iipGamma,invertCMap:b.iipInvertCMap,colorSat:b.iipColorSat,quality:b.iipQuality}}f=Ext.Object.merge(c,d);a.image=e;if(!b){b=i.tileLayer.iip(e,f).addTo(j);a.setImageLayer(b)}else {a.removeImageLayer();g=i.tileLayer.iip(e,f).addTo(j);a.setImageLayer(g)}if(a.getEnableMiniMap()){if(h){h.remove()}a.createMiniMap()}},createMiniMap:function(){var a=this,e=a.libL,h=a.getMap(),g=a.getMiniMapOptions(),f=a.getImageOptions(),d=a.getImage(),c,b;if(d){b=e.tileLayer.iip(d,{credentials:f.credentials,mixingMode:'color',defaultChannel:2,contrast:0.7,gamma:2.8,colorSat:2,channelLabelMatch:'[ugrizY]'});c=e.control.extraMap(b,g).addTo(h);a.setMiniMap(c)}},setView:function(c,a,h,f){var b=this,g=b.libL,e=b.getMap(),d;c=parseFloat(parseFloat(c).toFixed(3));a=parseFloat(parseFloat(a).toFixed(3));d=g.latLng(a,c);e.setView(d,e.options.crs.fovToZoom(e,h,d));if(b.getShowCrosshair()){if(!f){b.drawCrosshair(c,a)}}},onLayerAdd:function(b){var a=this;if(b.layer.type==='tilelayer'){a.setReady(!0);a.fireEvent('changeimage',a)}},onDblClick:function(b){var a=this;a.fireEvent('dblclick',b,a)},onContextMenuClick:function(b){var a=this,c=a.getMap();if(!a.isObjectContextMenu){a.showContextMenuImage(b)}a.isObjectContextMenu=!1},removeImageLayer:function(){var b=this,a=b.getMap();if(a!==null){a.eachLayer(function(b){a.removeLayer(b)})}},getRaDec:function(){var c=this,d=c.libL,b=c.getMap(),e=b.options.crs,a=b.getCenter();return {'ra':parseFloat(a.lng),'dec':parseFloat(a.lat)}},getBounds:function(){var m=this,j=m.libL,c=m.getMap(),b=c.options.crs,k=b.forceNativeCelsys&&!this.options.nativeCelsys,e=k?b.celsysToEq(c.getCenter()):c.getCenter(),n=Math.abs(Math.cos(e.lat*Math.PI/180)),d=c.getPixelBounds(),f=c.getZoom(),a,g,l,i,h,o;a=k?[b.celsysToEq(c.unproject(d.min,f)),b.celsysToEq(c.unproject(j.point(d.min.x,d.max.y),f)),b.celsysToEq(c.unproject(d.max,f)),b.celsysToEq(c.unproject(libLpoint(d.max.x,d.min.y),f))]:[c.unproject(d.min,f),c.unproject(j.point(d.min.x,d.max.y),f),c.unproject(d.max,f),c.unproject(j.point(d.max.x,d.min.y),f)];g=parseFloat(e.lng.toFixed(6));l=parseFloat(e.lat.toFixed(6));i=(Math.max(b._deltaLng(a[0],e),b._deltaLng(a[1],e),b._deltaLng(a[2],e),b._deltaLng(a[3],e))-Math.min(b._deltaLng(a[0],e),b._deltaLng(a[1],e),b._deltaLng(a[2],e),b._deltaLng(a[3],e)))*n;h=Math.max(a[0].lat,a[1].lat,a[2].lat,a[3].lat)-Math.min(a[0].lat,a[1].lat,a[2].lat,a[3].lat);if(h<1.0E-4){h=1.0E-4}if(i<1.0E-4){i=1.0E-4}if(g>360){g=g-360}return {lat:parseFloat(l.toFixed(6)),lng:parseFloat(g.toFixed(6)),dlat:parseFloat(h.toFixed(6)),dlng:parseFloat(i.toFixed(6))}},getBox:function(){var h=this,e,d,b,c,a,g,f;bounding=h.getBounds();if(bounding.lng>360){bounding.lng=bounding.lng-360}d=parseFloat(bounding.lng+bounding.dlng/2).toFixed(6);b=parseFloat(bounding.lat+bounding.dlat/2).toFixed(6);c=parseFloat(bounding.lng-bounding.dlng/2).toFixed(6);a=parseFloat(bounding.lat-bounding.dlat/2).toFixed(6);g=[d,b];f=[c,a];e=[g,f];return e},getFov:function(){var e=this,a=e.getMap(),d=a.options.crs,c=a.getCenter(),b;b=d.zoomToFov(a,a.getZoom(),c);return b},onMove:function(){var a=this,b=a.getRaDec(),c=a.getFov();a.fireEvent('changeposition',b,c,a)},onMouseMove:function(b){var d=String(b.latlng.lng.toFixed(5)+', '+b.latlng.lat.toFixed(5)),a=this,c=a.getMap();this.cmpMousePosition.children[0].innerHTML='Mouse RA, Dec ('+d+')';a.currentPosition={radec:[b.latlng.lng.toFixed(5),b.latlng.lat.toFixed(5)],container:[b.containerPoint.x,b.containerPoint.y]};if(a.cropInit&&a.cropInit==a.cropEnd&&a.isCropping){if(a.cropRectangle){c.removeLayer(a.cropRectangle)}a.cropRectangle=a.drawRectangle(a.cropInit['radec'],a.currentPosition['radec'])}if(a.getEnableSmallCrosshair()){a.createSmallCrosshair()}},getLinkToPosition:function(){var b=this,e=b.getMap(),a=b.getRaDec(),c=b.getFov(),d;if(a.dec>0){d=a.ra.toFixed(3).replace('.',',')+'+'+a.dec.toFixed(3).replace('.',',')}else {d=a.ra.toFixed(3).replace('.',',')+a.dec.toFixed(3).replace('.',',')}if(c){c=c.toFixed(2).replace('.',',')}b.fireEvent('link',encodeURIComponent(d),c,a,b)},onShift:function(){this.fireEvent('shift',this.getRaDec(),this)},isReady:function(){return this.getReady()},panTo:function(a){var b=this.getMap();this.coordinatesToLatLng(a,function(c){if(c){b.panTo(c)}})},coordinatesToLatLng:function(a,b){visiomatic.Visiomatic.coordinatesToLatLng(a,b)},hmsToLatLng:function(a,b){visiomatic.Visiomatic.hmsToLatLng(a,b)},drawRadius:function(g,e,d,n,l){var a=this,b=a.libL,f=a.getMap(),j=f.options.crs,h=a.getRadiusOptions(),o=g+'_'+e,i,c,m;if(a.getLradius()){f.removeLayer(a.getLradius());a.setLradius(null)}m=Ext.Object.merge(h,l);if(n==='arcmin'){d=d/60}var k={type:'FeatureCollection',features:[{type:'Feature',id:o,properties:{},geometry:{type:'Point',coordinates:[g,e]}}]};c=b.geoJson(k,{coordsToLatLng:function(a){if(j.forceNativeCelsys){var c=j.eqToCelsys(b.latLng(a[1],a[0]));return new b.LatLng(c.lat,c.lng,a[2])}else {return new b.LatLng(a[1],a[0],a[2])}},pointToLayer:function(a,c){i=Ext.Object.merge(h,{majAxis:d,minAxis:d,posAngle:90});return b.ellipse(b.latLng(e,g),i)}});a.setLradius(c);f.addLayer(c);return c},showHideRadius:function(d){var c=this,b=c.getMap(),a=c.getLradius();if(a!==null){if(d){b.addLayer(a)}else {b.removeLayer(a)}}},overlayCatalog:function(l,j,k){var c=this,b=c.libL,g=c.getMap(),h=g.options.crs,i=c.getCatalogOptions(),a,d,f,e;a=Ext.Object.merge(i,k);d={type:'FeatureCollection',features:[]};j.each(function(a){if(c.isInsideTile(a.get('_meta_ra'),a.get('_meta_dec'))){f={type:'Feature',id:a.get('_meta_id'),title:l,properties:a.data,is_system:a.get('_meta_is_system'),geometry:{type:'Point',coordinates:[a.get('_meta_ra'),a.get('_meta_dec')]}};d.features.push(f)}},c);e=b.geoJson(d,{coordsToLatLng:function(a){if(h.forceNativeCelsys){var c=h.eqToCelsys(b.latLng(a[1],a[0]));return new b.LatLng(c.lat,c.lng,a[2])}else {return new b.LatLng(a[1],a[0],a[2])}},pointToLayer:function(e,d){if(e.is_system){if(e.properties._meta_radius){radius=e.properties._meta_radius/60;opts=c.getRadiusOptions()}}if(a.pointType==='ellipse'){var q=0.001,r=0.001,m=90;try{var o=e.properties._meta_a_image,p=e.properties._meta_b_image,f=e.properties._meta_theta_image;if(typeof o=='number'&&typeof p=='number'&&typeof f=='number'){q=o/3600;r=p/3600;m=f}}catch(x){}a.majAxis=q,a.minAxis=r,a.posAngle=m;return b.ellipse(d,a)}else {if(a.pointType==='square'){var w=[[d.lat-a.pointSize,d.lng-a.pointSize],[d.lat+a.pointSize,d.lng+a.pointSize]];var v=b.rectangle(w,a);return v}else {if(a.pointType==='triangle'){var h,i,g,n,s,t,u;h=[b.latLng(d.lat-a.pointSize,d.lng-a.pointSize),b.latLng(d.lat-a.pointSize,d.lng+a.pointSize)];g=[b.latLng(d.lat-a.pointSize,d.lng-a.pointSize),b.latLng(d.lat+a.pointSize,d.lng)];i=[b.latLng(d.lat-a.pointSize,d.lng+a.pointSize),b.latLng(d.lat+a.pointSize,d.lng)];s=b.polyline(h,a);u=b.polyline(g,a);t=b.polyline(i,a);n=new b.LayerGroup([s,u,t]);return n}else {a.majAxis=a.pointSize;a.minAxis=a.pointSize;a.posAngle=90;circle=b.ellipse(d,a);return circle}}}}}).bindPopup(c.createOverlayPopup).on('dblclick',function(){alert('TODO: OPEN IN EXPLORER!')}).on('contextmenu',c.onLayerContextMenu,c);g.addLayer(e);c.redraw();return e},redraw:function(){var d=this,c=d.getMap(),a=$(c.getContainer()),b=a.width();if(b>0){a.css({width:b+2});c.invalidateSize();a.css({width:'initial'})}},createOverlayPopup:function(i){var a=i.feature,h=a.properties,j=['_meta_mag_auto_g','_meta_mag_auto_r','_meta_mag_auto_i','_meta_mag_auto_z','_meta_mag_auto_y'],e=[],d=[],c=a.properties._meta_id,g=['RAJ2000','DEJ2000'],b=[],f;Ext.each(j,function(a){try{mag_name=a.slice(-1);if(mag_name=='y'){mag_name='Y'}mag_value=h[a];tag=''+mag_name+': '+mag_value.toFixed(2)+'';e.push(tag)}catch(k){}});if(a.properties._meta_is_system){c=''+a.properties._meta_id+''}else {if(a.properties._meta_catalog_class=='coadd_objects'){c=''+a.properties._meta_id+''}else {if(a.properties._meta_object_url){c=''+a.properties._meta_id+'';for(property in a.properties){if(!property.startsWith('_meta_')&&g.indexOf(property)==-1){b.push(property)}}if(b.length<=15){for(key in b.sort()){property=b[key];d.push(''+property+': '+a.properties[property]+'')}}}else {}}}f=''+a.title+'
    '+e.join('')+d.join('')+'
    ID: '+c+'
    RA, Dec (deg): '+a.properties._meta_ra.toFixed(5)+', '+a.properties._meta_dec.toFixed(5)+'
    ';return f},onDblClickOverlay:function(){console.log('onDblClickOverlay(%o)',arguments)},showHideLayer:function(a,c){var d=this,b=d.getMap();if(a!==null){if(c){b.addLayer(a)}else {b.removeLayer(a)}}},showHideComments:function(a,b){},onLayerContextMenu:function(a){var b=this;b.isObjectContextMenu=!0;if(a.target.targetPosition){b.showContextMenuImage(a)}else {if(a.target.targetObjet){a.layer={feature:a.target.targetObjet.feature}}b.showContextMenuObject(a)}},createCommentIcon:function(d,c){var b=this,e,a;a=b.markPosition(d,'mapmaker-comment comment-maker').on('contextmenu',b.onLayerContextMenu,b);if(c){c.commentMaker=a;a.targetObjet=c}else {a.targetPosition=d}a.getElement().style.display=b.getShowComments()?'':'none'},updateComment:function(b,a,c){},markPosition:function(i,g,e){var h=this,c=h.libL,j=h.getMap(),b,a,f,d;if(arguments.length==2){b=i;e=g;d=[12,25]}else {b=c.latLng(g,i);d=[8,44]}if(e){f=c.divIcon({className:'visiomatic-marker-position',iconAnchor:d,html:''});a=c.marker(b,{icon:f})}else {a=c.marker(b)}a.addTo(j);return a},setShowCrosshair:function(c){var b=this,d=b.getMap(),a=b.lcrosshair;b.showCrosshair=c;if(a!==null){if(c){d.addLayer(a)}else {d.removeLayer(a)}}},onToggleCrosshair:function(c,a,d){var b=this;if(d.pressed){b.drawCrosshair(c,a)}else {b.removeCrosshair(c,a)}},drawCrosshair:function(e,d,m){var c=this,a=c.libL,l=c.getMap(),o=c.getCrosshairOptions(),n=null,b,f,g,p,k,h,j,i;b=Ext.Object.merge({},o);if(m){b=Ext.Object.merge(b,m)}if(c.lcrosshair){if(l.hasLayer(c.lcrosshair)){l.removeLayer(c.lcrosshair);c.lsmallcrosshair=null}}p=a.latLng(d,e);f=b.centerPadding?b.centerPadding:0.001;g=b.size?b.size:0.005;k=[a.latLng(d+f,e),a.latLng(d+g,e)];h=[a.latLng(d-f,e),a.latLng(d-g,e)];j=[a.latLng(d,e+f),a.latLng(d,e+g)];i=[a.latLng(d,e-f),a.latLng(d,e-g)];k=a.polyline(k,b);h=a.polyline(h,b);j=a.polyline(j,b);i=a.polyline(i,b);n=new a.LayerGroup([k,h,j,i]);c.lcrosshair=n;if(c.getShowCrosshair()){l.addLayer(c.lcrosshair)}return c.lcrosshair},removeCrosshair:function(){var a=this,b=a.getMap();if(a.lcrosshair){if(b.hasLayer(a.lcrosshair)){b.removeLayer(a.lcrosshair);a.lsmallcrosshair=null}}},drawSmallCrosshair:function(d,c,e){var b=this,a=b.libL,h=b.getMap(),n=b.getCrosshairOptions(),p=null,m,f,g,o,l,i,k,j;m=Ext.Object.merge({},n);if(e){m=Ext.Object.merge(m,e)}if(b.lsmallcrosshair){if(h.hasLayer(b.lsmallcrosshair)){h.removeLayer(b.lsmallcrosshair);b.lsmallcrosshair=null}}o=a.latLng(c,d);f=0.005/h._zoom;g=0.01/h._zoom;l=[a.latLng(c+f,d),a.latLng(c+g,d)];i=[a.latLng(c-f,d),a.latLng(c-g,d)];k=[a.latLng(c,d+f),a.latLng(c,d+g)];j=[a.latLng(c,d-f),a.latLng(c,d-g)];l=a.polyline(l,e);i=a.polyline(i,e);k=a.polyline(k,e);j=a.polyline(j,e);layerSmall=new a.LayerGroup([l,i,k,j]);b.lsmallcrosshair=layerSmall;if(b.getEnableSmallCrosshair()&&e){h.addLayer(b.lsmallcrosshair)}return b.lsmallcrosshair},showCatalogOverlayWindow:function(){var b=this,c=b.getCurrentDataset(),a=b._winCatalogOverlay;if(c!==null&&c.get('id')>0){if(a!=null){a.show()}else {a=Ext.create('visiomatic.catalog.CatalogOverlayWindow',{visiomatic:b});b.add(a);a.show();b._winCatalogOverlay=a}b._winCatalogOverlay.setDataset(c)}else {console.log('Dataset nao foi definido, a funcao overlay precisa de um dataset.');return !1}},showDownloadWindow:function(){var d=this,a=d.getCurrentDataset(),c;if(a.get('tli_tilename')){c=a.get('tli_tilename');var b=Ext.create('visiomatic.download.DescutDownloadWindow');b.loadFits(c,'Y3A1_COADD');b.show()}else {alert('File not found.')}},showContextMenuImage:function(b){var a=this,c=b.target,d={x:b.originalEvent.clientX,y:b.originalEvent.clientY};if(!a.getEnableContextMenu()){return}if(b.originalEvent.target.classList.contains('comment-maker')&&!c.targetPosition){return a.showContextMenuObject(b)}if(!this.contextMenuImage){this.contextMenuImage=new Ext.menu.Menu({items:[{id:'comment-position',text:'Comment Position',handler:function(c){a.fireEvent('imageMenuItemClick',a.contextMenuImage.target,a.getCurrentDataset())}}]})}c.latlng=b.latlng;a.contextMenuImage.target=c;a.contextMenuImage.showAt(d)},initCrop:function(){var a=this,b=a.getMap();b.on('mousedown',a.startCrop,a);a.isCropping=!0;b.dragging.removeHooks()},startCrop:function(){var a=this,b=a.getMap();a.cropInit=a.currentPosition;a.cropEnd=a.cropInit;b.off('mousedown',a.startCrop,a);b.on('mouseup',a.endCrop,a)},endCrop:function(c){var a=this,b=a.getMap();a.cropEnd=a.currentPosition;b.off('mouseup',a.endCrop,a);a.downloadCrop(a.cropInit,a.cropEnd);if(a.cropRectangle){b.removeLayer(a.cropRectangle)}a.cropInit=null;a.isCropping=!1;b.dragging.addHooks()},downloadCrop:function(d,e){var i=this,p=i.libL,h=i.getMap(),g=document.createElement('a'),a=i.getImageLayer();var o=h.getCenter(),j=h.getPixelBounds(),c=h.getZoom(),b;if(c>a.iipMaxZoom){b=Math.pow(2,c-a.iipMaxZoom);c=a.iipMaxZoom}else {b=1}var l=a.iipImageSize[c].x*b,m=a.iipImageSize[c].y*b,f=Math.abs(d.container[0]-e.container[0]),n=Math.abs(d.container[1]-e.container[1]);var k={x:j.min.x+Math.min(d.container[0],e.container[0]),y:j.min.y+Math.min(d.container[1],e.container[1])};g.href=a.getTileUrl({x:1,y:1}).replace(/JTL\=\d+\,\d+/g,'RGN='+k.x/l+','+k.y/m+','+f/l+','+n/m+'&WID='+(this._snapType===0?Math.floor(f/b):Math.floor(f/b/a.wcs.scale(c)))+'&CVT=jpeg');g.download=a._title+'_'+p.IIPUtils.latLngToHMSDMS(o).replace(/[\s\:\.]/g,'')+'.jpg';var q=Ext.create('visiomatic.crop.CropWindow',{image:g,height:n+100,width:f+100})},showContextMenuObject:function(a){var c,b=this,d={x:a.originalEvent.clientX,y:a.originalEvent.clientY};if(!b.getEnableContextMenu()){return}if(!this.contextMenuObject){this.contextMenuObject=new Ext.menu.Menu({items:[{id:'comment-object',text:'Comment Object',handler:function(c){b.fireEvent('objectMenuItemClick',a,this.feature)}}]})}c=b.contextMenuObject.items.get('comment-object');c.feature=a.layer?a.layer.feature:null;b.contextMenuObject.showAt(d)},drawRectangle:function(h,j,q){var f=this,a=f.libL,r=f.getMap(),e=h[0],c=h[1],d=j[0],b=j[1],l,g,k,i,p,m,n,o;pathOptions=Ext.Object.merge(f.getCrosshairOptions(),q);l=[a.latLng(c,d),a.latLng(c,e)];g=[a.latLng(b,d),a.latLng(b,e)];k=[a.latLng(c,e),a.latLng(b,e)];i=[a.latLng(c,d),a.latLng(b,d)];p=a.polyline(l,pathOptions);m=a.polyline(g,pathOptions);n=a.polyline(k,pathOptions);o=a.polyline(i,pathOptions);layer=new a.LayerGroup([p,m,n,o]);r.addLayer(layer);return layer},isInsideTile:function(d,b){var c=this,a=c.getCurrentDataset();if(a!=null&&a.get('id')>0){return a.isInsideTile(d,b)}else {return !0}},statics:{coordinatesToLatLng:function(a,c){var d,b=visiomatic.Visiomatic.strToSystem(a);a=a.trim().replace(/( )+/g,' ');d=a.split(',');if(b&&b.system=='latlng'){return c(b.value)}else {if(b&&b.system=='HMS'){return visiomatic.Visiomatic.hmsToLatLng(a,c)}}c(null)},hmsToLatLng:function(b,a){var c='http://cdsweb.u-strasbg.fr/cgi-bin/nph-sesame/-oI/A?'+b;$.get(c,function(c){var d=visiomatic.Visiomatic.parseCoords(c,!0);if(a){a(d)}})},latLngToHMSDMS:function(f){var c=(f.lng+360)/360;c=(c-Math.floor(c))*24;var e=Math.floor(c),d=(c-e)*60,a=Math.floor(d),b=(d-a)*60;if(b>=60){a++;b=0}if(a===60){e++;a=0}var j=(e<10?'0':'')+e.toString()+':'+(a<10?'0':'')+a.toString()+':'+(b<10?'0':'')+b.toFixed(3),h=Math.abs(f.lat),i=f.lat<0?'-':'+',g=Math.floor(h);d=(h-g)*60;a=Math.floor(d);b=(d-a)*60;if(b>=60){a++;b=0}if(a===60){e++;a=0}return j+' '+i+(g<10?'0':'')+g.toString()+':'+(a<10?'0':'')+a.toString()+':'+(b<10?'0':'')+b.toFixed(2)},strToSystem:function(a){var b;if(a){a=a.trim().replace(/( )+/g,' ');b=a.split(',');if(b.length==2&&a.split(':').length==1){return {value:{lng:Number(b[0]),lat:Number(b[1])},system:'latlng'}}b=a.split(' ');if(b.length==2&&a.split(':').length==5){return {value:a,system:'HMS'}}}return null},parseCoords:function(b){var a=/J\s(\d+\.?\d*)\s*,?\s*\+?(-?\d+\.?\d*)/g.exec(b);if(a&&a.length>=3){return L.latLng(Number(a[2]),Number(a[1]))}return null}}},0,['visiomatic'],['component','box','container','panel','visiomatic'],{'component':!0,'box':!0,'container':!0,'panel':!0,'visiomatic':!0},['widget.visiomatic'],[['interface',visiomatic.Interface]],[visiomatic,'Visiomatic'],0);Ext.cmd.derive('visiomatic.crop.CropWindow',Ext.window.Window,{title:'Crop',width:400,height:400,modal:!0,autoShow:!0,closeAction:'destroy',layout:{type:'hbox'},initComponent:function(){var a=this,b=a.image;Ext.apply(this,{layout:'ux.center',items:[{xtype:'image',src:b.href,alt:b.download,height:a.height-100,width:a.width-100}],buttons:[{xtype:'label',text:'Right click "Save image as" to download the image',flex:1},{text:'Cancel',scope:a,handler:'onCancel'}]});Ext.window.Window.prototype.initComponent.apply(this,arguments)},onCancel:function(){this.close()},loadImage:function(a){var b=this;this.image=a}},0,['target-download-crop'],['component','box','container','panel','window','target-download-crop'],{'component':!0,'box':!0,'container':!0,'panel':!0,'window':!0,'target-download-crop':!0},['widget.target-download-crop'],0,[visiomatic.crop,'CropWindow'],0);Ext.cmd.derive('aladin.Events',Ext.Base,{mouseIsDown:!1,mouseInitialPosition:[],mouseLastPosition:[],addCustomEvents:function(){var a=this;a.addDblClickListener();a.addMouseDown();a.addMouseMoveListener();a.addMouseUP()},addDblClickListener:function(){var a=this,d=a.getAladin(),f=d.view,e=d.view.reticleCanvas,b,c;e.addEventListener('dblclick',function(d){c=f.imageCanvas.relMouseCoords(d);b=a.mousePositionToSky(c);if(b){a.updateLocation(b);a.fireEvent('ondblclick',b,a)}})},addMouseDown:function(){var a=this,f=a.getAladin(),d=f.view,e=d.reticleCanvas,b,c;e.addEventListener('mousedown',function(e){c=d.imageCanvas.relMouseCoords(e);b=a.mousePositionToSky(c);if(b){a.mouseIsDown=!0;a.mouseInitialPosition=b;a.mouseLastPosition=b}})},addMouseMoveListener:function(){var a=this,f=a.getAladin(),d=f.view,e=d.reticleCanvas,b,c;e.addEventListener('mousemove',function(e){c=d.imageCanvas.relMouseCoords(e);b=a.mousePositionToSky(c);if(b){a.updateLocation(a.getRaDec(),b);if(a.mouseIsDown){a.mouseLastPosition=b;a.fireEvent('reticlemove',a.getRaDec(),a)}}})},addMouseUP:function(){var a=this,f=a.getAladin(),d=f.view,e=d.reticleCanvas,c,b;e.addEventListener('mouseup',function(e){b=d.imageCanvas.relMouseCoords(e);c=a.mousePositionToSky(b);if(c){if(a.mouseIsDown){if(!Ext.Array.equals(a.mouseInitialPosition,a.mouseLastPosition)){a.fireEvent('onpanend',a.getRaDec(),a)}else {a.fireEvent('onclick',a.mouseLastPosition,a)}}a.mouseIsDown=!1;a.mouseInitialPosition=[];a.mouseLastPosition=[]}})},mousePositionToSky:function(e){var g=this,f=g.getAladin(),a=f.view,d,b,c=[];d=AladinUtils.viewToXy(e.x,e.y,a.width,a.height,a.largestDim,a.zoomFactor);try{b=a.projection.unproject(d.x,d.y)}catch(h){return}if(a.cooFrame==CooFrameEnum.GAL){c=CooConversion.GalacticToJ2000([b.ra,b.dec])}else {c=[parseFloat(b.ra.toFixed(5)),parseFloat(b.dec.toFixed(5))]}return c},skyToString:function(a){if(a&&a[0]&&a[1]){return String(a[0].toFixed(5)+', '+a[1].toFixed(5))}},updateLocation:function(e,d){var a=this,c,b;c=a.skyToString(e);b=a.skyToString(d);a.setLocation(c,b)},onClickBtnMap:function(){var a=this,c=a.getViewModel(),b=c.get('release');if(a.windowMapSelection==null){a.windowMapSelection=Ext.create('aladin.maps.MapSelectionWindow',{width:182,height:237,x:45,y:55,resizable:!1,aladin:a})}a.windowMapSelection.setRelease(b);if(a.windowMapSelection.isHidden()){a.windowMapSelection.show()}else {a.windowMapSelection.hide()}}},0,0,0,0,0,0,[aladin,'Events'],0);Ext.cmd.derive('aladin.model.Image',Ext.data.Model,{fields:[{name:'id',type:'int'},{name:'img_url',type:'string'},{name:'product',type:'int'}]},0,0,0,0,0,0,[aladin.model,'Image'],0);Ext.cmd.derive('aladin.store.Images',common.store.MyStore,{model:'aladin.model.Image',autoLoad:!1,pageSize:0,remoteFilter:!0,proxy:{type:'django',url:'/dri/api/aladin/image/'}},0,0,0,0,['store.aladin_images'],0,[aladin.store,'Images'],0);Ext.cmd.derive('aladin.maps.MapSelectionController',Ext.app.ViewController,{listen:{component:{'aladin-maps-mapselectionwindow':{changerelease:'onChangeRelease'}}},onChangeRelease:function(k){var a=this,h=a.getViewModel(),g=h.getView(),c=h.getStore('maps_store'),f=a.lookup('cmbType'),e=a.lookup('cmbClass'),b=f.getStore(),i=e.getStore(),d=a.lookup('cmbFilter'),j=d.getStore();g.setLoading(!0);c.addFilter([{property:'release_id',value:k},{property:'with_image',value:!0}]);c.load({callback:function(){f.reset();b.removeAll();e.reset();i.removeAll();d.reset();j.removeAll();c.each(function(a){if(b.findRecord('pgr_group',a.get('pgr_group'))==null){b.add(a)}},this);g.setLoading(!1)}})},onSelectMapType:function(h){var b=this,i=b.getViewModel(),f=h.selection,g=i.getStore('maps_store'),d=b.lookup('cmbClass'),a=d.getStore(),c=b.lookup('cmbFilter'),e=c.getStore();d.reset();a.removeAll();c.reset();e.removeAll();g.each(function(b){if(b.get('pgr_group')==f.get('pgr_group')&&a.findRecord('prd_class',b.get('prd_class'))==null){a.add(b)}},this)},onSelectMapClass:function(f){var d=this,g=d.getViewModel(),c=f.selection,e=g.getStore('maps_store'),b=d.lookup('cmbFilter'),a=b.getStore();b.reset();a.removeAll();e.each(function(b){if(b.get('pgr_group')==c.get('pgr_group')&&b.get('prd_class')==c.get('prd_class')){a.add(b)}},this)},onSelectMapFilter:function(g){var d=this,c=d.getViewModel(),f=c.getView(),e=f.getAladin(),b=g.selection,a=c.getStore('aladin_images_store');a.addFilter([{property:'product',value:b.get('id')}]);a.load({callback:function(){if(a.getCount()!=1){Ext.MessageBox.alert('Warning',a.getCount().toString()+' images found for same map!')}else {aladin_last_nonmap_survey=c.get('aladin_last_nonmap_survey');if(aladin_last_nonmap_survey==null){c.set('aladin_last_nonmap_survey',e.getImageSurvey())}var f=a.getAt(0).get('img_url');survey={'id':'map_'+b.get('id').toString(),'url':f,'name':b.get('pcl_display_name'),'filter':b.get('prd_filter'),'maxOrder':3,'frame':'equatorial','options':{'imgFormat':'png'}};e.readProperties(f,function(a){survey['maxOrder']=a['maxOrder'];d.setMapSurvey(survey)},function(a){console.log('aladin.readProperties() error: %o',a);d.setMapSurvey(survey)})}}})},setMapSurvey:function(c){var e=this,a=e.getViewModel(),d=a.getView(),b=d.getAladin();mapSurvey=b.createImageSurvey(c);b.setImageSurvey(mapSurvey);a.set('aladin_last_map_survey',mapSurvey);a.set('map_selected',!0)},onDisplayOnOff:function(f){var e=this,a=e.getViewModel(),d=a.getView(),c=d.getAladin(),b=null;if(a.get('map_selected')){b=a.get('aladin_last_map_survey')}else {b=a.get('aladin_last_nonmap_survey')}c.setImageSurvey(b)}},0,0,0,0,['controller.mapselection'],0,[aladin.maps,'MapSelectionController'],0);Ext.cmd.derive('aladin.maps.MapSelectionWindow',Ext.window.Window,{controller:'mapselection',viewModel:'mapselection',config:{aladin:null},initComponent:function(){var a=this,b=a.getViewModel();Ext.apply(this,{title:'Map viewer',closeAction:'hide',bodyPadding:5,items:[{xtype:'combobox',reference:'cmbType',fieldLabel:'Map Type:',labelAlign:'top',emptyText:'',displayField:'pgr_display_name',valueField:'pgr_group',store:{type:'maps',autoLoad:!1,remoteFilter:!1},listeners:{select:'onSelectMapType'},editable:!1,queryMode:'local'},{xtype:'combobox',reference:'cmbClass',fieldLabel:'Map Class:',labelAlign:'top',emptyText:'',displayField:'pcl_display_name',valueField:'prd_class',store:{type:'maps',autoLoad:!1,remoteFilter:!1},listeners:{select:'onSelectMapClass'},editable:!1,queryMode:'local'},{xtype:'combobox',reference:'cmbFilter',fieldLabel:'Filter:',labelAlign:'top',emptyText:'',displayField:'prd_filter',valueField:'id',store:{type:'maps',autoLoad:!1,remoteFilter:!1},listeners:{select:'onSelectMapFilter'},editable:!1,queryMode:'local'},{xtype:'checkbox',reference:'chkOnOff',boxLabel:'Display Map',handler:'onDisplayOnOff',bind:{disabled:'{!aladin_switchable}',value:'{map_selected}'}}]});Ext.window.Window.prototype.initComponent.apply(this,arguments)},setRelease:function(a){var b=this,c=b.getViewModel();if(a!=c.get('release')){c.set('release',a);b.fireEvent('changerelease',a)}}},0,['aladin-maps-mapselectionwindow'],['component','box','container','panel','window','aladin-maps-mapselectionwindow'],{'component':!0,'box':!0,'container':!0,'panel':!0,'window':!0,'aladin-maps-mapselectionwindow':!0},['widget.aladin-maps-mapselectionwindow'],0,[aladin.maps,'MapSelectionWindow'],0);Ext.cmd.derive('aladin.Interfaces',Ext.Base,{windowInfo:null,windowMapSelection:null,enableDisableInfo:function(d,c){var b=this,a=b.windowInfo;if(!a){a=b.createWindowInfo()}a.setVisible(c)},createWindowInfo:function(){var b=this,a;a=Ext.create('Ext.Component',{width:280,height:100,x:5,y:10,renderTo:b.body,header:!1,resizable:!1,constrain:!0,cls:'aladin-location-info',style:{position:'absolute',zIndex:29},tpl:['
    {image_survey}','
    {tilename}','
    RA, Dec (deg): {location}
    Mouse RA, Dec (deg): {mlocation}
    ']});b.windowInfo=a;return a},getInfoData:function(){var g=this,a=g.getViewModel(),e=a.get('tile'),f=a.get('tag'),k=a.get('release_name'),d,b,c='',j='',i='',h='';if(f){h=k;i=f.get('tag_display_name')}if(e){j=e.get('tli_tilename')}b=g.getImageSurvey();if(b&&b.id!='empty_survey'){c=b.name}d={image_survey:c,location:a.get('location'),mlocation:a.get('mlocation'),release:h,tag:i,tilename:j};return d},updateInfoData:function(){var a=this,c=a.windowInfo,b=a.getInfoData();if(a.windowInfo){c.setData(b)}},makeToolbar:function(){var c=this,a=c.getToolbarPosition(),b=!1;if(a==='left'||a==='right'){b=!0}return Ext.create('Ext.toolbar.Toolbar',{vertical:b,reference:'aladinToolbar'})},makeToolbarButtons:function(){var a=this,c,b=[],e=a.getToolbarPosition(),f=!1;if(e==='left'||e==='right'){f=!0}if(a.getEnableShift()){b.push({xtype:'button',tooltip:'Goto Visiomatic.',iconCls:'x-fa fa-exchange',scope:a,handler:a.onShift,bind:{disabled:'{!tile}'}})}if(a.getEnableLayersControl()){b.push({xtype:'button',scope:a,iconCls:'x-fa fa-picture-o',tooltip:'Image Layer',menu:a.createImageLayersMenuItems(),menuAlign:'tr',arrowVisible:!1,itemId:'BtnImageLayers'})}if(a.getShowFilters()){var d=Ext.create('common.BandFilter',{filters:['g','r','i','z','Y','irg'],defaultFilter:'irg',vertical:f,listeners:{scope:a,'onfilter':a.onFilter}});a.setBandFilter(d);b.push(d)}if(a.getEnableViewMenu()){b.push(a.createViewMenu())}if(a.getEnableMaps()){b.push({xtype:'button',tooltip:'Map Viewer',iconCls:'x-fa fa-th',scope:a,handler:a.onClickBtnMap})}if(a.getEnableGoto()){b.push({iconCls:'x-fa fa-search',tooltip:'Go To position. 356.0085, 0.5168 or 23 44 2.040 +00 31 0.48',menuAlign:'tr',arrowVisible:!1,menu:[{xtype:'textfield',emptyText:'RA (deg), Dec (deg)',triggers:{'goto':{cls:'x-form-search-trigger',scope:this,handler:a.submitGoToPosition,tooltip:'Go To position. 356.0085, 0.5168 or 23 44 2.040 +00 31 0.48'}},listeners:{scope:this,specialkey:function(b,a){if(a.getKey()==a.ENTER){this.submitGoToPosition(b)}}}}]})}if(a.getEnableExportPng()){if(Ext.firefoxVersion>0){b.push({xtype:'button',tooltip:'Snapshot',iconCls:'x-fa fa-camera',scope:a,handler:a.exportAsPng})}}c=a.getAuxTools();if(c.length>0){Ext.each(c,function(a){b.push(a)})}return b},createViewMenu:function(){var c=this,b,a;a=c.createViewMenuItems();if(a.length>0){b=Ext.create('Ext.button.Button',{iconCls:'x-fa fa-cog',tooltip:'Change view settings',itemId:'ViewMenu',menu:a,menuAlign:'tr',arrowVisible:!1})}return b},createViewMenuItems:function(){var a=this,b=[];b.push({xtype:'menucheckitem',text:'Tiles Grid',itemId:'TileGridMenu',menu:[],menuAlign:'tr',checkHandler:a.onCheckTileGridMenu,disabled:!0,checked:a.getTilesGridVisible()});b.push('-');if(a.getEnableColorMap()){b.push(a.createColorMapMenu())}b.push('-');if(a.getEnableFootprint()){var c=a.getHideFootprint();b.push({xtype:'menucheckitem',itemId:'DesFootprint',text:'Des Footprint',checked:!c,scope:a,checkHandler:a.showDesFootprint})}if(a.getEnableReticle()){b.push({xtype:'menucheckitem',text:'Reticle',checked:!0,scope:a,checkHandler:a.showReticle})}if(a.getEnableHealpixGrid()){b.push({xtype:'menucheckitem',text:'Healpix Grid',scope:a,checkHandler:a.showHealpixGrid})}if(a.getEnableHealpixGrid()){b.push({xtype:'menucheckitem',text:'Info',scope:a,checkHandler:a.enableDisableInfo,checked:a.getInfoEnabled()})}return b},createTileGridMenu:function(){var b=this,d=b.down('#ViewMenu'),c=b.createTileGridMenuItems(),a=b.down('#TileGridMenu');if(!a){a={text:'Tiles Grid',itemId:'TileGridMenu',menu:c};d.getMenu().add(a)}else {a.getMenu().removeAll();a.getMenu().add(c);a.enable()}},createTileGridMenuItems:function(){var a=this,c=a.getStoreTags(),b=[];if(c.count()>0){c.each(function(c){b.push({xtype:'menucheckitem',text:c.get('tag_display_name'),tag:c.get('id'),scope:a,checkHandler:a.onCheckTileGrid})},this)}return b},createColorMapMenu:function(){var c=this,b,a;a=c.createColorMapMenuItems();b={text:'Color Map',tooltip:'Change Color Map',reference:'BtnColorMap',itemId:'BtnColorMap',menu:a,menuAlign:'tr',arrowVisible:!1};return b},createColorMapMenuItems:function(){var a=this,c=a.getColorMaps(),b=[];for(var d in c){b.push({xtype:'menucheckitem',text:c[d],group:'colormaps',mapName:c[d],scope:a,checkHandler:a.changeColorMap})}b.push('-');b.push({text:'Reverse',scope:a,handler:a.reverseColor});return b},updateColorMapMenu:function(){var a=this,d=a.down('#BtnColorMap'),b,c;b=Ext.clone(ColorMap.MAPS_NAMES);a.setColorMaps(b);c=a.createColorMapMenuItems();d.setMenu(c)},createImageLayersMenuItems:function(){var a=this,f=a.getExternalSurveys(),b=a.getSurveys(),c=[],d,g;if(b!=null&&b.length>0){for(var e in b){desSurvey=b[e];if(desSurvey.id!='empty_survey'){c.push({xtype:'menucheckitem',text:desSurvey['name'],group:'imageSurveys',survey:desSurvey,scope:a,checked:!0,checkHandler:a.selectExternalSurvey})}}c.push('-')}for(var e in f){d=f[e];c.push({xtype:'menucheckitem',text:d['name'],group:'imageSurveys',survey:d,scope:a,checkHandler:a.selectExternalSurvey})}return c},updateImageLayersMenuItems:function(){var c=this,b=c.down('#BtnImageLayers'),a;if(b){a=c.createImageLayersMenuItems();b.setMenu(a)}}},0,0,0,0,0,0,[aladin,'Interfaces'],0);Ext.cmd.derive('aladin.Aladin',Ext.panel.Panel,{layout:'fit',libA:null,colorsDefault:['#A0F65A','#00BFFF','#FF0000','#FFFF00','#FF7F00','#7D26CD','#FF1493'],colorsAvailable:[],config:{aladinId:null,cmpAladin:null,aladin:null,aladinReady:!1,hipsDir:'/static/stripeHiPS',aladinOptions:{fov:180,target:'02 23 11.851 -09 40 21.59',cooFrame:'J2000',survey:'empty_survey',showReticle:!0,showZoomControl:!0,showFullscreenControl:!0,showLayersControl:!1,showGotoControl:!1,showShareControl:!1,showCatalog:!0,showFrame:!1,showCooGrid:!1,fullScreen:!1,reticleColor:'rgb(178, 50, 178)',reticleSize:28,log:!0,allowFullZoomout:!0},aladinWidth:300,aladinHeight:300,autoSize:!0,storeSurveys:null,storeMaps:null,surveys:[],maps:[],colorMaps:[],emptySurvey:{'id':'empty_survey','url':'','name':'','filter':'','maxOrder':11,'frame':'equatorial','options':{imgFormat:'png'}},enableLayersControl:!0,enableToolbar:!0,showFilters:!1,bandFilter:null,availableFilters:[],enableViewMenu:!0,enableExportPng:!0,enableReticle:!0,enableHealpixGrid:!0,enableColorMap:!0,enableFootprint:!0,hideFootprint:!0,enableGoto:!1,gotoSetPosition:!0,auxTools:[],storeTags:null,storeTiles:null,tilesGridVisible:!1,enableInfo:!0,infoEnabled:!0,location:'',mlocation:'',initialFov:null,enableMaps:!0,enableShift:!1,toolbarPosition:'left',externalSurveys:[{'id':'P/2MASS/color','url':'http://alasky.u-strasbg.fr/2MASS/Color','name':'2MASS colored','maxOrder':9,'frame':'equatorial','format':'jpeg'},{'id':'P/DSS2/color','url':'http://alasky.u-strasbg.fr/DSS/DSSColor','name':'DSS colored','maxOrder':9,'frame':'equatorial','format':'jpeg'},{'id':'P/DSS2/red','url':'http://alasky.u-strasbg.fr/DSS/DSS2Merged','name':'DSS2 Red (F+R)','maxOrder':9,'frame':'equatorial','format':'jpeg fits'},{'id':'P/Fermi/color','url':'http://alasky.u-strasbg.fr/Fermi/Color','name':'Fermi color','maxOrder':3,'frame':'equatorial','format':'jpeg'},{'id':'P/Finkbeiner','url':'http://alasky.u-strasbg.fr/FinkbeinerHalpha','maxOrder':3,'frame':'galactic','format':'jpeg fits','name':'Halpha'},{'id':'P/GALEXGR6/AIS/color','url':'http://alasky.u-strasbg.fr/GALEX/GR6-02-Color','name':'GALEX Allsky Imaging Survey colored','maxOrder':8,'frame':'equatorial','format':'jpeg'},{'id':'P/IRIS/color','url':'http://alasky.u-strasbg.fr/IRISColor','name':'IRIS colored','maxOrder':3,'frame':'galactic','format':'jpeg'},{'id':'P/Mellinger/color','url':'http://alasky.u-strasbg.fr/MellingerRGB','name':'Mellinger colored','maxOrder':4,'frame':'galactic','format':'jpeg'},{'id':'P/SDSS9/color','url':'http://alasky.u-strasbg.fr/SDSS/DR9/color','name':'SDSS9 colored','maxOrder':10,'frame':'equatorial','format':'jpeg'},{'id':'P/SPITZER/color','url':'http://alasky.u-strasbg.fr/SpitzerI1I2I4color','name':'IRAC color I1,I2,I4 - (GLIMPSE, SAGE, SAGE-SMC, SINGS)','maxOrder':9,'frame':'galactic','format':'jpeg'},{'id':'P/VTSS/Ha','url':'http://alasky.u-strasbg.fr/VTSS/Ha','maxOrder':3,'frame':'galactic','format':'png jpeg fits','name':'VTSS-Ha'},{'id':'P/XMM/EPIC','url':'http://saada.u-strasbg.fr/xmmallsky','name':'XMM-Newton stacked EPIC images (no phot. normalization)','maxOrder':7,'frame':'equatorial','format':'png fits'},{'id':'P/XMM/PN/color','url':'http://saada.unistra.fr/xmmpnsky','name':'XMM PN colored','maxOrder':7,'frame':'equatorial','format':'png jpeg'},{'id':'P/allWISE/color','url':'http://alasky.u-strasbg.fr/AllWISE/RGB-W4-W2-W1/','name':'AllWISE color','maxOrder':8,'frame':'equatorial','format':'jpeg'},{'id':'P/GLIMPSE360','url':'http://www.spitzer.caltech.edu/glimpse360/aladin/data','name':'GLIMPSE360','maxOrder':9,'frame':'equatorial','format':'jpeg'}]},isFirstSurvey:!0,viewModel:{data:{location:'',mlocation:'',tile:null,tag:null,release:null,release_name:''}},session:!0,initComponent:function(){var a=this,c,b,d;if(window.A){a.libA=window.A}else {console.log('window.A ainda nao esta carregada')}a.setAladinId(a.getId()+'-placeholder');c=Ext.create('Ext.Component',{id:a.getAladinId(),width:a.getAladinWidth(),height:a.getAladinHeight()});if(a.getEnableToolbar()){b=a.leftToolBar=a.makeToolbar();d=a.makeToolbarButtons();b.add(d);if(a.getToolbarPosition()==='left'){a.lbar=b}else {if(a.getToolbarPosition()==='top'){a.tbar=b}}}Ext.apply(this,{items:[c],listeners:{scope:a,afterrender:'onAfterrender'}});Ext.panel.Panel.prototype.initComponent.apply(this,arguments)},onAfterrender:function(){var a=this,d='#'+a.getAladinId(),e=a.libA,c=a.getAladinOptions(),b,f;b=e.aladin(d,c);b.view.setUnknownSurveyIfNeeded=function(){};b._setImageSurvey=b.setImageSurvey;b.setImageSurvey=function(d,c){return b._setImageSurvey(d,function(){a.onChangeImageSurvey();if(c){c()}})};a.setAladin(b);a.createImageSurveys();if(a.getEnableColorMap()){a.updateColorMapMenu()}if(a.getInfoEnabled()){a.enableDisableInfo(null,a.getInfoEnabled())}a.addCustomEvents();a.setAladinReady(!0);a.fireEvent('aladinready',a)},onChangeImageSurvey:function(){this.addCustomEvents()},aladinIsReady:function(){var a=this;return a.getAladinReady()},getRaDec:function(){var b=this,a=b.getAladin();return a.getRaDec()},getEmptySurvey:function(){return Ext.clone(this.emptySurvey)},readProperties:function(c,a,b){ProgressiveCat.readProperties(c,a,b)},onResize:function(){var a=this,b=a.getAladin();if(a.getAutoSize()){b.view.fixLayoutDimensions()}},setSurveys:function(a){this.surveys=null;this.surveys=a;if(this.getAladin()&&a.length>0){this.removeLayers();this.createImageSurveys()}},createImageSurvey:function(e){var c=this,f=c.getEmptySurvey(),d=c.getAladin(),a,b,g;a=Ext.Object.merge(f,e);b=d.createImageSurvey(String(a.id),a.name,a.url,a.cooFrame,a.maxOrder,a.options);return b},createImageSurveys:function(){var a=this,b=a.getSurveys(),d=a.getFilter(),f=a.getEmptySurvey(),e,c;if(b.length===0){b.push(f)}for(var g in b){e=b[g];a.createImageSurvey(e)}if(d){c=a.getSurveyByFilter(d)}else {c=b[0]}a.updateImageLayersMenuItems();a.setImageSurvey(c)},getSurveyByFilter:function(c){var d=this,b=d.getSurveys(),a;for(var e in b){a=b[e];if(a.filter.toLowerCase()==c.toLowerCase()){return a}}},getImageSurvey:function(){var b=this,a=b.getAladin();if(a){return a.getBaseImageLayer()}else {return null}},setImageSurvey:function(b){var a=this,c=a.getAladin(),d=a.getEmptySurvey();if(b){c.setImageSurvey(b.id);if(a.isFirstSurvey){if(b.target!==''){a.goToPosition(b.target)}if(a.getInitialFov()){a.setFov(a.getInitialFov())}else {if(b.fov){a.setFov(b.fov)}}a.isFirstSurvey=!1}a.showDesFootprint();a.addCustomEvents();a.fireEvent('changeimage',b,a)}else {c.setImageSurvey(d.id)}},setStoreSurveys:function(a){var b=this;if(a){a.on({scope:this,load:'onStoreSurveysLoad',beforeload:'onStoreSurveysBeforeLoad'});b.storeSurveys=a}},onStoreSurveysBeforeLoad:function(a){var b=this;b.setLoading({store:a})},onStoreSurveysLoad:function(d){var a=this,g=a.getAladin(),f=a.getEmptySurvey(),c=[],b=[],e;if(d.count()===0){console.log('NAO TEM SURVEY');a.setImageSurvey(f)}d.each(function(a){e={id:String(a.get('id')),url:a.get('srv_url'),name:a.get('srv_display_name'),filter:a.get('filter'),target:a.get('srv_target'),fov:a.get('srv_fov')};c.push(e);b.push(a.get('filter'))});a.setSurveys(c);a.setAvailableFilters(b)},setLocation:function(c,b){var a=this,d=a.getViewModel();a.location=c;a.mlocation=b;d.set('location',c);d.set('mlocation',b);if(a.getAladin()){a.onChangeLocation()}},onChangeLocation:function(a){var b=this;if(!a){a=b.getRaDec()}b.identifyTile(a);b.updateInfoData()},setAvailableFilters:function(a){var b=this,c=b.getBandFilter();if(a.length>0){if(b.getShowFilters()){c.setAvailableFilters(a)}}},setStoreTags:function(a){var b=this;if(a){b.storeTags=a;a.on('load','onLoadStoreTags',this)}},onLoadStoreTags:function(b){var a=this;if(a.getEnableViewMenu()){if(b.count()>0){a.createTileGridMenu()}}},setStoreTiles:function(a){var b=this;b.storeTiles=a;a.on('beforeload','onBeforeloadStoreTiles',this);a.on('load','onLoadStoreTiles',this)},onBeforeloadStoreTiles:function(){var a=this;a.setLoading(!0)},onLoadStoreTiles:function(){var a=this,b;a.setLoading(!1);if(a.getEnableViewMenu()){b=a.down('#TileGridMenu');if(b.checked){a.onCheckTileGridMenu(b,b.checked)}}a.identifyTile()},getTileByPosition:function(c){var e=this,b=e.getStoreTiles(),a=c,d;if(!c){a=e.getRaDec()}if(b&&b.count()){d=b.filterByRaDec(a[0],a[1])}return d},identifyTile:function(f){var b=this,c=b.getViewModel(),e=c.get('tileid'),a,d;a=b.getTileByPosition(f);if(a){if(a.get('id')!==e){d=b.getStoreTags().getById(a.get('tag'));c.set('release_name',a.get('release_display_name'));c.set('tile',a);c.set('tag',d);b.fireEvent('changetile',a,d,b)}}else {c.set('tile',null);c.set('tag',null);b.fireEvent('changetile',a,d,b)}},onFilter:function(b){var a=this,c;c=a.getSurveyByFilter(b);a.setImageSurvey(c);a.fireEvent('changefilter',b,a)},getFilter:function(){var a=this,b=a.getBandFilter();if(a.getShowFilters()){return b.getFilter()}},setFilter:function(b){var c=this,a=c.getBandFilter();a.setFilter(b)},changeMapSurvey:function(a){var c=this,d=c.getAladin(),b;b={id:String(a.map_id),url:a.map_url,name:a.map_name,filter:a.map_filter,maxOrder:3};mapSurvey=c.createImageSurvey(b);d.setImageSurvey(mapSurvey.id)},selectExternalSurvey:function(b){var d=this,c=d.getAladin(),a=b.survey;c.setImageSurvey(a.id)},exportAsPng:function(){var b=this,a=b.getAladin();a.exportAsPNG()},showReticle:function(d,b){var c=this,a=c.getAladin();a.showReticle(b)},showHealpixGrid:function(d,b){var c=this,a=c.getAladin();a.showHealpixGrid(b)},showDesFootprint:function(a,b){var c=this;if(!a){a=c.down('#DesFootprint');b=a.checked}c.plotDesFootprint(b)},reverseColor:function(){var b=this,a=b.getAladin();a.getBaseImageLayer().getColorMap().reverse()},changeColorMap:function(b){var c=this,a=c.getAladin();a.getBaseImageLayer().getColorMap().update(b.mapName)},plotDesFootprint:function(e){var d=this,c=d.getAladin();des=d.getDesFootprintCoordinates();if(c.view.overlays[0]!=undefined){overlays=c.view.overlays;plotDes=!1;for(var b=overlays.length-1;b>=0;b--){if(overlays[b].name=='des'){plotDes=!0;if(e){overlays[b].show()}else {overlays[b].hide()}}}if(plotDes==!1){var a=A.graphicOverlay({color:'#ee2345',lineWidth:2,name:'des'});c.addOverlay(a);a.add(A.polyline(des))}}else {var a=A.graphicOverlay({color:'#ee2345',lineWidth:2,name:'des'});c.addOverlay(a);a.add(A.polyline(des))}},onCheckTileGridMenu:function(b,a){var d=this,c=b.getMenu();c.items.each(function(c){c.setChecked(a)},d)},onCheckTileGrid:function(b,a){this.showTileGrid(b.tag,a)},showTileGrid:function(c,g){var a=this,e=a.getStoreTiles(),f=a.getStoreTags(),d=f.getById(c),b;if(g){b=e.query('tag',c);if(b.count()>0){a.plotFootprint(d,b)}}else {a.setVisibleFootprint(d.get('tag_name'),!1)}},plotFootprint:function(e,h){var c=this,f=c.getAladin(),b=c.libA,a,d,g;d=b.catalog({name:'Recent tiles',sourceSize:14,color:'#e67e22'});a=c.getFootprintByName(e.get('tag_name'));if(a){a.show()}else {a=b.graphicOverlay({color:c.getColor(),lineWidth:1,name:String(e.get('tag_name'))});f.addOverlay(a);h.each(function(c){var f=[[c.get('raul'),c.get('decul')],[c.get('rall'),c.get('decll')],[c.get('ralr'),c.get('declr')],[c.get('raur'),c.get('decur')]];a.addFootprints(b.polygon(f));if(c.get('is_new')){g=!0;d.addSources([b.marker(c.get('tli_ra'),c.get('tli_dec'),{popupTitle:'Tile Recently Added',popupDesc:'Creation date: '+c.get('date')})])}},this);if(g&&!e.get('is_new')){f.addCatalog(d)}}},parsePosition:function(a){var b,d,c;if(a){if(a.indexOf(',')!=-1){a=a.split(',');b=parseFloat(a[0].trim());d=parseFloat(a[1].trim());if(b<0){b=b+360}c=[b,d];a=c.join(', ')}else {a=c}return a}},goToPosition:function(b){var c=this,d=c.getAladin(),a;if(b){a=c.parsePosition(b);d.gotoObject(a)}},setFov:function(b){var d=this,c=d.getAladin(),a=parseFloat(b);if(a){c.setFoV(a)}},getFov:function(){var b=this,a=b.getAladin();return a.getFov()},getFootprintByName:function(d){var e=this,c=e.getAladin(),a=c.view.overlays,b=null;if(a.length>0){a.forEach(function(a){if(a.name==d){b=a}})}return b},setVisibleFootprint:function(c,b){var d=this,a;if(b=='undefined'){b=!0}a=d.getFootprintByName(c);if(a){if(b){a.show()}else {a.hide()}}},removeLayers:function(){var b=this,a=b.getAladin();a.removeLayers()},getColor:function(){var a=this,c=a.colorsDefault,b;if(a.colorsAvailable.length===0){a.colorsAvailable=Ext.clone(c)}b=a.colorsAvailable.shift();return b},onShift:function(){this.fireEvent('shift',this.getRaDec(),this)},onShowLayerBox:function(){var b=this,a=b.getViewModel().getView().getAladin();a.hideBoxes();a.showLayerBox();return !1},overlayDrawCircle:function(b,a,c){a.beginPath();a.arc(b.x,b.y,b.data['size']*2,0,2*Math.PI,!1);a.closePath();a.strokeStyle='#c38';a.lineWidth=3;a.globalAlpha=0.7,a.stroke();var d=Math.max(c['fov'][0],c['fov'][1]);return},getDesFootprintCoordinates:function(){var a=[[23,-7],[22,-7],[21,-7],[20,-7],[19,-7],[18,-7],[17,-7],[16,-7],[15,-7],[14,-7],[13,-7],[12,-7],[11,-7],[10,-7],[9,-7],[8,-7],[7,-7],[6,-7],[5,-7],[4,-7],[3,-7],[2,-7],[1,-7],[0,-7],[0,-6],[0,-5],[0,-4],[0,-3],[0,-2],[-1,-2],[-2,-2],[-3,-2],[-4,-2],[-5,-2],[-6,-2],[-7,-2],[-8,-2],[-9,-2],[-10,-2],[-11,-2],[-12,-2],[-13,-2],[-14,-2],[-15,-2],[-16,-2],[-17,-2],[-18,-2],[-19,-2],[-20,-2],[-21,-2],[-22,-2],[-23,-2],[-24,-2],[-25,-2],[-26,-2],[-27,-2],[-28,-2],[-29,-2],[-30,-2],[-31,-2],[-32,-2],[-33,-2],[-34,-2],[-35,-2],[-36,-2],[-37,-2],[-38,-2],[-39,-2],[-40,-2],[-41,-2],[-42,-2],[-43,-2],[-43,-1],[-43,0],[-43,1],[-43,2],[-42,2],[-41,2],[-40,2],[-39,2],[-38,2],[-37,2],[-36,2],[-35,2],[-34,2],[-33,2],[-32,2],[-31,2],[-30,2],[-29,2],[-28,2],[-27,2],[-26,2],[-25,2],[-24,2],[-23,2],[-22,2],[-21,2],[-20,2],[-19,2],[-18,2],[-17,2],[-16,2],[-15,2],[-14,2],[-13,2],[-12,2],[-11,2],[-10,2],[-9,2],[-8,2],[-7,2],[-6,2],[-5,2],[-4,2],[-3,2],[-2,2],[-1,2],[0,2],[0,2],[0,3],[0,4],[0,5],[1,5],[2,5],[3,5],[4,5],[5,5],[6,5],[7,5],[8,5],[9,5],[10,5],[11,5],[12,5],[13,5],[14,5],[15,5],[16,5],[17,5],[18,5],[19,5],[20,5],[21,5],[22,5],[23,5],[24,5],[25,5],[26,5],[27,5],[28,5],[29,5],[30,5],[31,5],[32,5],[33,5],[34,5],[35,5],[36,5],[37,5],[38,5],[39,5],[40,5],[41,5],[42,5],[43,5],[44,5],[45,5],[45,5],[45,4],[45,3],[45,2],[45,1],[45,0],[45,-1],[45,-2],[45,-3],[45,-4],[45,-5],[45,-6],[45,-7],[45,-8],[45,-9],[45.83584,-9.06842],[46.36744,-9.14567],[46.89697,-9.22888],[47.42429,-9.3181],[47.94928,-9.41337],[48.47183,-9.51474],[48.99181,-9.62226],[49.50912,-9.73598],[50.02364,-9.85594],[50.53529,-9.98221],[51.04396,-10.11482],[51.54955,-10.25382],[52.05199,-10.39926],[52.55118,-10.55119],[53.04706,-10.70965],[53.53954,-10.87467],[54.02856,-11.0463],[54.51405,-11.22457],[54.99596,-11.40952],[55.47423,-11.60118],[55.94881,-11.79957],[56.41965,-12.00471],[56.88672,-12.21663],[57.34998,-12.43534],[57.80939,-12.66086],[58.26493,-12.89318],[58.71657,-13.13232],[59.16429,-13.37827],[59.60807,-13.63102],[60.0479,-13.89057],[60.48377,-14.15689],[60.91568,-14.42997],[61.3436,-14.70979],[61.76755,-14.99631],[62.18753,-15.2895],[62.60354,-15.58931],[63.01557,-15.89572],[63.42365,-16.20866],[63.82778,-16.52808],[64.22797,-16.85393],[66,-18],[67,-18],[68,-18],[69,-18],[70,-18],[71,-18],[72,-18],[73,-18],[74,-18],[75,-18],[76,-18],[77,-18],[78,-18],[79,-18],[80,-18],[81,-18],[82,-18],[83,-18],[84,-18],[85,-18],[86,-18],[86.66667,-19],[87.33333,-20],[88,-21],[88.66667,-22],[89.41596,-23.1317],[89.68146,-24.3655],[89.95879,-25.59111],[90.24749,-26.80814],[90.54705,-28.01619],[90.8569,-29.21488],[91.17643,-30.40381],[91.50499,-31.58263],[91.84185,-32.75095],[92.18623,-33.90841],[92.53729,-35.05464],[92.89409,-36.18931],[93.25565,-37.31205],[93.62088,-38.42252],[93.98862,-39.5204],[94.35759,-40.60535],[94.72643,-41.67704],[95.09367,-42.73517],[95.45771,-43.77942],[95.81685,-44.80949],[96.16922,-45.82508],[96.51286,-46.8259],[96.84562,-47.81168],[97.16521,-48.78213],[97.46918,-49.73698],[97.75487,-50.67597],[98.01948,-51.59884],[98.25999,-52.50536],[98.47317,-53.39526],[98.65561,-54.26832],[98.80364,-55.1243],[98.91339,-55.96299],[98.98075,-56.78417],[99.00136,-57.58762],[98.97062,-58.37314],[98.88371,-59.14055],[98.73552,-59.88964],[98.52073,-60.62023],[98.23379,-61.33214],[98,-61.5],[97,-61.5],[96,-61.5],[95,-61.5],[94,-61.5],[93,-61.5],[92,-61.5],[91,-61.5],[90,-61.5],[89,-61.5],[88,-61.5],[87,-61.5],[86,-61.5],[85,-61.5],[84,-61.5],[83,-62],[78.66667,-63],[74.33333,-64],[69.1922,-65.62708],[68.293,-65.99135],[67.35218,-66.34555],[66.36917,-66.68914],[65.34355,-67.02152],[64.27503,-67.3421],[63.1635,-67.65026],[62.00905,-67.9454],[60.81197,-68.22686],[59.5728,-68.49402],[58.29235,-68.74623],[56.97169,-68.98287],[55.6122,-69.20331],[54.21558,-69.40695],[52.78381,-69.59321],[51.31925,-69.76152],[49.82454,-69.91137],[48.30265,-70.04227],[46.75683,-70.15381],[45.19062,-70.2456],[43.60779,-70.31734],[42.0123,-70.36875],[40.4083,-70.39968],[38.8,-70.41],[37.1917,-70.39968],[35.5877,-70.36875],[33.99221,-70.31734],[32.40938,-70.2456],[30.84317,-70.15381],[29.29735,-70.04227],[27.77546,-69.91137],[26.28075,-69.76152],[24.81619,-69.59321],[23.38442,-69.40695],[21.9878,-69.20331],[20.62831,-68.98287],[19.30765,-68.74623],[18.0272,-68.49402],[16.78803,-68.22686],[15.59095,-67.9454],[14.4365,-67.65026],[13.32497,-67.3421],[12.25645,-67.02152],[11.23083,-66.68914],[10.24782,-66.34555],[9.307,-65.99135],[8.4078,-65.62708],[7.54955,-65.2533],[4,-65],[3,-65],[2,-65],[1,-65],[0,-65],[-1,-65],[-2,-65],[-3,-65],[-4,-65],[-5,-65],[-6,-65],[-7,-65],[-8,-65],[-9,-65],[-10,-65],[-11,-65],[-12,-65],[-13,-65],[-14,-65],[-15,-65],[-16,-65],[-17,-65],[-18,-65],[-19,-65],[-20,-65],[-21,-65],[-22,-65],[-23,-65],[-24,-65],[-25,-65],[-26,-65],[-27,-65],[-28,-65],[-29,-65],[-30,-65],[-31,-65],[-32,-65],[-33,-65],[-34,-65],[-35,-65],[-36,-65],[-37,-65],[-38,-65],[-39,-65],[-40,-65],[-41,-65],[-42,-65],[-43,-65],[-44,-65],[-45,-65],[-46,-65],[-47,-65],[-48,-65],[-49,-65],[-50,-65],[-51,-65],[-52,-65],[-53,-65],[-54,-65],[-55,-65],[-56,-65],[-57,-65],[-56.8,-64],[-56.6,-63],[-56.4,-62],[-56.2,-61],[-56,-60],[-55.9,-59],[-55.8,-58],[-55.7,-57],[-55.6,-56],[-55.5,-55],[-55.4,-54],[-55.3,-53],[-55.2,-52],[-55.1,-51],[-55,-50],[-54.9,-49],[-54.8,-48],[-54.7,-47],[-54.6,-46],[-54.5,-45],[-54.4,-44],[-54.3,-43],[-54.2,-42],[-54.1,-41],[-54,-40],[-53,-40],[-52,-40],[-51,-40],[-50,-40],[-49,-40],[-48,-40],[-47,-40],[-46,-40],[-45,-40],[-44,-40],[-43,-40],[-42,-40],[-41,-40],[-40,-40],[-39,-40],[-38,-40],[-37,-40],[-36,-40],[-35,-40],[-34,-40],[-33,-40],[-32,-40],[-31,-40],[-30,-40],[-29,-40],[-28,-40],[-27,-40],[-26,-40],[-25,-40],[-24,-40],[-23,-40],[-22,-40],[-21,-40],[-20,-40],[-19,-40],[-18,-40],[-17,-40],[-16,-40],[-15,-40],[-14,-40],[-13,-40],[-12,-40],[-11,-40],[-10,-40],[-9,-40],[-8,-40],[-7,-40],[-6,-40],[-5,-40],[-4,-40],[-3,-40],[-1.47219,-38.64048],[-1.27518,-38.12814],[-1.07231,-37.61674],[-0.86376,-37.1064],[-0.6497,-36.59723],[-0.43028,-36.08933],[-0.20564,-35.58282],[0.02406,-35.07782],[0.25871,-34.57444],[0.49818,-34.0728],[0.74235,-33.57301],[0.99113,-33.0752],[1.24441,-32.5795],[1.50209,-32.08601],[1.7641,-31.59488],[2.03036,-31.10621],[2.30079,-30.62015],[2.57532,-30.13681],[2.85391,-29.65632],[3.13648,-29.17881],[3.423,-28.70441],[3.71342,-28.23325],[4.0077,-27.76546],[4.30581,-27.30116],[4.60772,-26.84048],[4.9134,-26.38355],[5.22284,-25.93051],[5.53601,-25.48147],[5.8529,-25.03656],[6.17351,-24.59591],[6.49782,-24.15964],[6.82584,-23.72788],[7.15756,-23.30074],[7.49299,-22.87835],[7.83212,-22.46081],[8.17498,-22.04826],[8.52155,-21.6408],[8.87186,-21.23855],[9.22592,-20.8416],[9.58374,-20.45008],[9.94533,-20.06407],[10.3107,-19.68369],[10.67989,-19.30903],[11.05289,-18.94018],[11.42973,-18.57723],[11.81042,-18.22027],[12.19498,-17.86938],[12.58343,-17.52465],[12.97577,-17.18614],[13.37203,-16.85393],[13.77222,-16.52808],[14.17635,-16.20866],[14.58443,-15.89572],[14.99646,-15.58931],[15.41247,-15.2895],[15.83245,-14.99631],[16.2564,-14.70979],[16.68432,-14.42997],[17.11623,-14.15689],[17.5521,-13.89057],[17.99193,-13.63102],[18.43571,-13.37827],[18.88343,-13.13232],[19.33507,-12.89318],[19.79061,-12.66086],[20.25002,-12.43534],[20.71328,-12.21663],[21.18035,-12.00471],[21.65119,-11.79957],[22.12577,-11.60118],[22.60404,-11.40952],[23.08595,-11.22457],[23,-10],[23,-9],[23,-8],[23,-7]];return a}},0,['aladin'],['component','box','container','panel','aladin'],{'component':!0,'box':!0,'container':!0,'panel':!0,'aladin':!0},['widget.aladin'],[['events',aladin.Events],['interface',aladin.Interfaces]],[aladin,'Aladin'],0);Ext.cmd.derive('aladin.maps.MapSelectionViewModel',Ext.app.ViewModel,{stores:{maps_store:{type:'maps',autoLoad:!1},aladin_images_store:{type:'aladin_images',autoLoad:!1}},data:{release:null,aladin_last_map_survey:null,aladin_last_nonmap_survey:null,map_selected:!1},formulas:{aladin_switchable:function(a){return a('aladin_last_nonmap_survey')!=null&&a('aladin_last_map_survey')!=null}}},0,0,0,0,['viewmodel.mapselection'],0,[aladin.maps,'MapSelectionViewModel'],0);Ext.cmd.derive('Ext.draw.ContainerBase',Ext.panel.Panel,{previewTitleText:'Chart Preview',previewAltText:'Chart preview',layout:'container',addElementListener:function(){var a=this,b=arguments;if(a.rendered){a.el.on.apply(a.el,b)}else {a.on('render',function(){a.el.on.apply(a.el,b)})}},removeElementListener:function(){var a=this,b=arguments;if(a.rendered){a.el.un.apply(a.el,b)}},afterRender:function(){Ext.panel.Panel.prototype.afterRender.apply(this,arguments);this.initAnimator()},getItems:function(){var a=this,b=a.items;if(!b||!b.isMixedCollection){a.initItems()}return a.items},onRender:function(){Ext.panel.Panel.prototype.onRender.apply(this,arguments);this.element=this.el;this.innerElement=this.body},setItems:function(a){this.items=a;return a},setSurfaceSize:function(b,a){this.resizeHandler({width:b,height:a});this.renderFrame()},onResize:function(b,a,d,c){var e=this;Ext.panel.Panel.prototype.onResize.call(this,b,a,d,c);e.setBodySize({width:b,height:a})},preview:function(){var a=this.getImage();new Ext.window.Window({title:this.previewTitleText,closeable:!0,renderTo:Ext.getBody(),autoShow:!0,maximizeable:!0,maximized:!0,border:!0,layout:{type:'hbox',pack:'center',align:'middle'},items:{xtype:'container',items:{xtype:'image',mode:'img',cls:'x-chart-image',alt:this.previewAltText,src:a.data,listeners:{afterrender:function(){var b=this,c=b.imgEl.dom,d=a.type==='svg'?1:window['devicePixelRatio']||1,e;if(!c.naturalWidth||!c.naturalHeight){c.onload=function(){var e=c.naturalWidth,a=c.naturalHeight;b.setWidth(Math.floor(e/d));b.setHeight(Math.floor(a/d))}}else {e=b.getSize();b.setWidth(Math.floor(e.width/d));b.setHeight(Math.floor(e.height/d))}}}}}})},privates:{getTargetEl:function(){return this.innerElement},reattachToBody:function(){var a=this;if(a.pendingDetachSize){a.onBodyResize()}a.pendingDetachSize=!1;Ext.panel.Panel.prototype.reattachToBody.call(this)}}},0,0,['component','box','container','panel'],{'component':!0,'box':!0,'container':!0,'panel':!0},0,0,[Ext.draw,'ContainerBase'],0);Ext.cmd.derive('Ext.draw.SurfaceBase',Ext.Widget,{getOwnerBody:function(){return this.ownerCt.body},destroy:function(){var a=this;if(a.hasListeners.destroy){a.fireEvent('destroy',a)}Ext.Widget.prototype.destroy.call(this)}},0,0,['widget'],{'widget':!0},0,0,[Ext.draw,'SurfaceBase'],0);Ext.cmd.derive('Ext.draw.Color',Ext.Base,{statics:{colorToHexRe:/(.*?)rgb\((\d+),\s*(\d+),\s*(\d+)\)/,rgbToHexRe:/\s*rgb\((\d+),\s*(\d+),\s*(\d+)\)/,rgbaToHexRe:/\s*rgba\((\d+),\s*(\d+),\s*(\d+),\s*([\.\d]+)\)/,hexRe:/\s*#([0-9a-fA-F][0-9a-fA-F]?)([0-9a-fA-F][0-9a-fA-F]?)([0-9a-fA-F][0-9a-fA-F]?)\s*/,NONE:'none',RGBA_NONE:'rgba(0, 0, 0, 0)'},isColor:!0,lightnessFactor:0.2,constructor:function(d,b,c,a){this.setRGB(d,b,c,a)},setRGB:function(e,c,d,b){var a=this;a.r=Math.min(255,Math.max(0,e));a.g=Math.min(255,Math.max(0,c));a.b=Math.min(255,Math.max(0,d));if(b===undefined){a.a=1}else {a.a=Math.min(1,Math.max(0,b))}},getGrayscale:function(){return this.r*0.3+this.g*0.59+this.b*0.11},getHSL:function(){var h=this,f=h.r/255,e=h.g/255,g=h.b/255,b=Math.max(f,e,g),d=Math.min(f,e,g),c=b-d,a,j=0,i=0.5*(b+d);if(d!==b){j=i<=0.5?c/(b+d):c/(2-b-d);if(f===b){a=60*(e-g)/c}else {if(e===b){a=120+60*(g-f)/c}else {a=240+60*(f-e)/c}}if(a<0){a+=360}if(a>=360){a-=360}}return [a,j,i]},getHSV:function(){var g=this,d=g.r/255,c=g.g/255,f=g.b/255,b=Math.max(d,c,f),i=Math.min(d,c,f),e=b-i,a,j=0,h=b;if(i!=b){j=h?e/h:0;if(d===b){a=60*(c-f)/e}else {if(c===b){a=60*(f-d)/e+120}else {a=60*(d-c)/e+240}}if(a<0){a+=360}if(a>=360){a-=360}}return [a,j,h]},setHSL:function(f,g,c){var d=this,h=Math.abs,b,e,a;f=(f%360+360)%360;g=g>1?1:g<0?0:g;c=c>1?1:c<0?0:c;if(g===0||f===null){c*=255;d.setRGB(c,c,c)}else {f/=60;b=g*(1-h(2*c-1));e=b*(1-h(f%2-1));a=c-b/2;a*=255;b*=255;e*=255;switch(Math.floor(f)){case 0:d.setRGB(b+a,e+a,a);break;case 1:d.setRGB(e+a,b+a,a);break;case 2:d.setRGB(a,b+a,e+a);break;case 3:d.setRGB(a,e+a,b+a);break;case 4:d.setRGB(e+a,a,b+a);break;case 5:d.setRGB(b+a,a,e+a);break;}}return d},setHSV:function(f,g,c){var d=this,b,e,a;f=(f%360+360)%360;g=g>1?1:g<0?0:g;c=c>1?1:c<0?0:c;if(g===0||f===null){c*=255;d.setRGB(c,c,c)}else {f/=60;b=c*g;e=b*(1-Math.abs(f%2-1));a=c-b;a*=255;b*=255;e*=255;switch(Math.floor(f)){case 0:d.setRGB(b+a,e+a,a);break;case 1:d.setRGB(e+a,b+a,a);break;case 2:d.setRGB(a,b+a,e+a);break;case 3:d.setRGB(a,e+a,b+a);break;case 4:d.setRGB(e+a,a,b+a);break;case 5:d.setRGB(b+a,a,e+a);break;}}return d},createLighter:function(b){if(!b&&b!==0){b=this.lightnessFactor}var a=this.getHSL();a[2]=Ext.Number.constrain(a[2]+b,0,1);return Ext.draw.Color.fromHSL(a[0],a[1],a[2])},createDarker:function(a){if(!a&&a!==0){a=this.lightnessFactor}return this.createLighter(-a)},toString:function(){var a=this,b=Math.round;if(a.a===1){var e=b(a.r).toString(16),d=b(a.g).toString(16),c=b(a.b).toString(16);e=e.length===1?'0'+e:e;d=d.length===1?'0'+d:d;c=c.length===1?'0'+c:c;return ['#',e,d,c].join('')}else {return 'rgba('+[b(a.r),b(a.g),b(a.b),a.a===0?0:a.a.toFixed(15)].join(', ')+')'}},toHex:function(a){if(Ext.isArray(a)){a=a[0]}if(!Ext.isString(a)){return ''}if(a.substr(0,1)==='#'){return a}var b=Ext.draw.Color.colorToHexRe.exec(a);if(Ext.isArray(b)){var e=parseInt(b[2],10),c=parseInt(b[3],10),d=parseInt(b[4],10),f=d|c<<8|e<<16;return b[1]+'#'+('000000'+f.toString(16)).slice(-6)}else {return ''}},setFromString:function(b){var a,c,e,d,g=1,f=parseInt;if(b===Ext.draw.Color.NONE){this.r=this.g=this.b=this.a=0;return this}if((b.length===4||b.length===7)&&b.substr(0,1)==='#'){a=b.match(Ext.draw.Color.hexRe);if(a){c=f(a[1],16)>>0;e=f(a[2],16)>>0;d=f(a[3],16)>>0;if(b.length===4){c+=c*16;e+=e*16;d+=d*16}}}else {if(a=b.match(Ext.draw.Color.rgbToHexRe)){c=+a[1];e=+a[2];d=+a[3]}else {if(a=b.match(Ext.draw.Color.rgbaToHexRe)){c=+a[1];e=+a[2];d=+a[3];g=+a[4]}else {if(Ext.draw.Color.ColorList.hasOwnProperty(b.toLowerCase())){return this.setFromString(Ext.draw.Color.ColorList[b.toLowerCase()])}}}}if(typeof c==='undefined'){return this}this.r=c;this.g=e;this.b=d;this.a=g;return this}},3,0,0,0,0,0,[Ext.draw,'Color'],function(){var a=new this();this.addStatics({fly:function(b,e,d,c){switch(arguments.length){case 1:a.setFromString(b);break;case 3:case 4:a.setRGB(b,e,d,c);break;default:return null;}return a},ColorList:{aliceblue:'#f0f8ff',antiquewhite:'#faebd7',aqua:'#00ffff',aquamarine:'#7fffd4',azure:'#f0ffff',beige:'#f5f5dc',bisque:'#ffe4c4',black:'#000000',blanchedalmond:'#ffebcd',blue:'#0000ff',blueviolet:'#8a2be2',brown:'#a52a2a',burlywood:'#deb887',cadetblue:'#5f9ea0',chartreuse:'#7fff00',chocolate:'#d2691e',coral:'#ff7f50',cornflowerblue:'#6495ed',cornsilk:'#fff8dc',crimson:'#dc143c',cyan:'#00ffff',darkblue:'#00008b',darkcyan:'#008b8b',darkgoldenrod:'#b8860b',darkgray:'#a9a9a9',darkgreen:'#006400',darkkhaki:'#bdb76b',darkmagenta:'#8b008b',darkolivegreen:'#556b2f',darkorange:'#ff8c00',darkorchid:'#9932cc',darkred:'#8b0000',darksalmon:'#e9967a',darkseagreen:'#8fbc8f',darkslateblue:'#483d8b',darkslategray:'#2f4f4f',darkturquoise:'#00ced1',darkviolet:'#9400d3',deeppink:'#ff1493',deepskyblue:'#00bfff',dimgray:'#696969',dodgerblue:'#1e90ff',firebrick:'#b22222',floralwhite:'#fffaf0',forestgreen:'#228b22',fuchsia:'#ff00ff',gainsboro:'#dcdcdc',ghostwhite:'#f8f8ff',gold:'#ffd700',goldenrod:'#daa520',gray:'#808080',green:'#008000',greenyellow:'#adff2f',honeydew:'#f0fff0',hotpink:'#ff69b4',indianred:'#cd5c5c',indigo:'#4b0082',ivory:'#fffff0',khaki:'#f0e68c',lavender:'#e6e6fa',lavenderblush:'#fff0f5',lawngreen:'#7cfc00',lemonchiffon:'#fffacd',lightblue:'#add8e6',lightcoral:'#f08080',lightcyan:'#e0ffff',lightgoldenrodyellow:'#fafad2',lightgray:'#d3d3d3',lightgrey:'#d3d3d3',lightgreen:'#90ee90',lightpink:'#ffb6c1',lightsalmon:'#ffa07a',lightseagreen:'#20b2aa',lightskyblue:'#87cefa',lightslategray:'#778899',lightsteelblue:'#b0c4de',lightyellow:'#ffffe0',lime:'#00ff00',limegreen:'#32cd32',linen:'#faf0e6',magenta:'#ff00ff',maroon:'#800000',mediumaquamarine:'#66cdaa',mediumblue:'#0000cd',mediumorchid:'#ba55d3',mediumpurple:'#9370d8',mediumseagreen:'#3cb371',mediumslateblue:'#7b68ee',mediumspringgreen:'#00fa9a',mediumturquoise:'#48d1cc',mediumvioletred:'#c71585',midnightblue:'#191970',mintcream:'#f5fffa',mistyrose:'#ffe4e1',moccasin:'#ffe4b5',navajowhite:'#ffdead',navy:'#000080',oldlace:'#fdf5e6',olive:'#808000',olivedrab:'#6b8e23',orange:'#ffa500',orangered:'#ff4500',orchid:'#da70d6',palegoldenrod:'#eee8aa',palegreen:'#98fb98',paleturquoise:'#afeeee',palevioletred:'#d87093',papayawhip:'#ffefd5',peachpuff:'#ffdab9',peru:'#cd853f',pink:'#ffc0cb',plum:'#dda0dd',powderblue:'#b0e0e6',purple:'#800080',red:'#ff0000',rosybrown:'#bc8f8f',royalblue:'#4169e1',saddlebrown:'#8b4513',salmon:'#fa8072',sandybrown:'#f4a460',seagreen:'#2e8b57',seashell:'#fff5ee',sienna:'#a0522d',silver:'#c0c0c0',skyblue:'#87ceeb',slateblue:'#6a5acd',slategray:'#708090',snow:'#fffafa',springgreen:'#00ff7f',steelblue:'#4682b4',tan:'#d2b48c',teal:'#008080',thistle:'#d8bfd8',tomato:'#ff6347',turquoise:'#40e0d0',violet:'#ee82ee',wheat:'#f5deb3',white:'#ffffff',whitesmoke:'#f5f5f5',yellow:'#ffff00',yellowgreen:'#9acd32'},fromHSL:function(a,c,b){return (new this(0,0,0,0)).setHSL(a,c,b)},fromHSV:function(a,b,c){return (new this(0,0,0,0)).setHSL(a,b,c)},fromString:function(a){return (new this(0,0,0,0)).setFromString(a)},create:function(a){if(a instanceof this){return a}else {if(Ext.isArray(a)){return new Ext.draw.Color(a[0],a[1],a[2],a[3])}else {if(Ext.isString(a)){return Ext.draw.Color.fromString(a)}else {if(arguments.length>2){return new Ext.draw.Color(arguments[0],arguments[1],arguments[2],arguments[3])}else {return new Ext.draw.Color(0,0,0,0)}}}}}})});Ext.cmd.derive('Ext.draw.sprite.AnimationParser',Ext.Base,function(){function compute(a,c,b){return a+(c-a)*b}return {singleton:!0,attributeRe:/^url\(#([a-zA-Z\-]+)\)$/,color:{parseInitial:function(a,b){if(Ext.isString(a)){a=Ext.draw.Color.create(a)}if(Ext.isString(b)){b=Ext.draw.Color.create(b)}if(a instanceof Ext.draw.Color&&b instanceof Ext.draw.Color){return [[a.r,a.g,a.b,a.a],[b.r,b.g,b.b,b.a]]}else {return [a||b,b||a]}},compute:function(a,b,c){if(!Ext.isArray(a)||!Ext.isArray(b)){return b||a}else {return [compute(a[0],b[0],c),compute(a[1],b[1],c),compute(a[2],b[2],c),compute(a[3],b[3],c)]}},serve:function(a){var b=Ext.draw.Color.fly(a[0],a[1],a[2],a[3]);return b.toString()}},number:{parse:function(a){return a===null?null:+a},compute:function(a,b,c){if(!Ext.isNumber(a)||!Ext.isNumber(b)){return b||a}else {return compute(a,b,c)}}},angle:{parseInitial:function(b,a){if(a-b>Math.PI){a-=Math.PI*2}else {if(a-b<-Math.PI){a+=Math.PI*2}}return [b,a]},compute:function(a,b,c){if(!Ext.isNumber(a)||!Ext.isNumber(b)){return b||a}else {return compute(a,b,c)}}},path:{parseInitial:function(m,l){var e=m.toStripes(),c=l.toStripes(),a,i,f=e.length,g=c.length,j,h,k,d=c[g-1],b=[d[d.length-2],d[d.length-1]];for(a=f;a=1){return b.path}var c=0,k=e.length,a=0,g,d,h,i=b.temp.params,j=0;for(;cMath.min(a.x+a.width,b.x+b.width)||Math.max(a.y,b.y)-c>Math.min(a.y+a.height,b.y+b.height)},isPointInBBox:function(b,c,a){return !!a&&b>=a.x&&b<=a.x+a.width&&c>=a.y&&c<=a.y+a.height},spline:function(c){var a,e,i=c.length,g,j,k,d,h=0,b=new Float32Array(c.length),f=new Float32Array(c.length*3-2);b[0]=0;b[i-1]=0;for(a=1;a0;a--){h=3.732050807568877+48.248711305964385/(-13.928203230275537+Math.pow(0.07179676972449123,a));b[a]-=b[a+1]*h}d=c[0];g=d-b[0];for(a=0,e=0;a=c&&a>=b||a<=c&&a<=b){d=e=q}else {d=t((f-s)/n(a-c));if(cq){i-=j}d+=i;e+=i;k=f-o*v(d);g=a+o*u(d);l=f+p*v(e);h=a+p*u(e);if(a>c&&gc){k+=n(c-g)*(k-f)/(g-a);g=c}if(a>b&&hb){l-=n(b-h)*(l-f)/(h-a);h=b}return {x1:k,y1:g,x2:l,y2:h}},smooth:function(i,j,p){var o=i.length,m,n,c,d,k,l,e,f,g=[],h=[],a,b;for(a=0;a=Math.PI){a-=Math.PI*2}}return a}},data:function(a){if(Ext.isArray(a)){return a.slice()}else {if(a instanceof Float32Array){return new Float32Array(a)}}},bool:function(a){return !!a},color:function(a){if(a instanceof Ext.draw.Color){return a.toString()}else {if(a instanceof Ext.draw.gradient.Gradient){return a}else {if(!a){return Ext.draw.Color.NONE}else {if(Ext.isString(a)){if(a.substr(0,3)==='url'){a=Ext.draw.gradient.GradientDefinition.get(a);if(Ext.isString(a)){return a}}else {return Ext.draw.Color.fly(a).toString()}}}}}if(a.type==='linear'){return Ext.create('Ext.draw.gradient.Linear',a)}else {if(a.type==='radial'){return Ext.create('Ext.draw.gradient.Radial',a)}else {if(a.type==='pattern'){return Ext.create('Ext.draw.gradient.Pattern',a)}else {return Ext.draw.Color.NONE}}}},limited:function(a,b){return function(c){c=+c;return Ext.isNumber(c)?Math.min(Math.max(c,a),b):undefined}},limited01:function(a){a=+a;return Ext.isNumber(a)?Math.min(Math.max(a,0),1):undefined},enums:function(){var b={},c=Array.prototype.slice.call(arguments,0),a,d;for(a=0,d=c.length;a=(7-4*c)/11){return a*a-b((11-6*c-11*d)/4,2)}}},elastic:function(a,c){return b(2,10*--a)*j(20*a*h*(c||1)/3)}},a={},e,g,c;function createPoly(a){return function(c){return b(c,a)}}function addEasing(c,b){a[c+'In']=function(a){return b(a)};a[c+'Out']=function(a){return 1-b(1-a)};a[c+'InOut']=function(a){return a<=0.5?b(2*a)/2:(2-b(2*(1-a)))/2}}for(c=0,g=f.length;c-1},empty:function(){return this.animations.length===0},step:function(e){var f=this,c=f.animations,a,b=0,d=c.length;for(;b0},applyEasing:function(a){if(typeof a==='string'){a=Ext.draw.TimingFunctions.easingMap[a]}return a},applyCustomEasings:function(g,b){b=b||{};var e,f,d,a,c,h;for(f in g){e=!0;a=g[f];d=f.split(',');if(typeof a==='string'){a=Ext.draw.TimingFunctions.easingMap[a]}for(c=0,h=d.length;c=1){d[b]=h[b];delete h[b];if(e[b].remove){d.removeFromInstance=d.removeFromInstance||{};d.removeFromInstance[b]=!0}delete e[b]}else {d[b]=a.serve(a.compute(a.source,a.target,a.easing(f),c[b]));i=!0}}c.lastUpdate=g;this.setAnimating(c,i);return d},pushDown:function(b,a){a=Ext.draw.modifier.Modifier.prototype.pushDown.call(this,b.animationOriginal,a);return this.setAttrs(b,a)},popUp:function(a,b){a=a.prototype;b=this.setAttrs(a,b);if(this._next){return this._next.popUp(a,b)}else {return Ext.apply(a,b)}},step:function(g){var a=this,e=a.animatingPool.slice(),f=e.length,d=0,c,b;for(;d=a.x&&c<=a.x+a.width&&d>=a.y&&d<=a.y+a.height;if(e){return {sprite:this}}}return null},isVisible:function(){var a=this.attr,b=this.getParent(),e=b&&(b.isSurface||b.isVisible()),h=e&&!a.hidden&&a.globalAlpha,c=Ext.draw.Color.NONE,d=Ext.draw.Color.RGBA_NONE,g=a.fillOpacity&&a.fillStyle!==c&&a.fillStyle!==d,f=a.strokeOpacity&&a.strokeStyle!==c&&a.strokeStyle!==d,i=h&&(g||f);return !!i},repaint:function(){var a=this.getSurface();if(a){a.renderFrame()}},remove:function(){var a=this.getSurface();if(a&&a.isSurface){return a.remove(this)}return null},destroy:function(){var a=this,b=a.topModifier,c;while(b){c=b;b=b.getPrevious();c.destroy()}delete a.attr;a.remove();if(a.fireEvent('beforedestroy',a)!==!1){a.fireEvent('destroy',a)}a.callParent()}},1,0,0,0,['sprite.sprite'],[['observable',Ext.mixin.Observable]],[Ext.draw.sprite,'Sprite'],function(){this.def=new Ext.draw.sprite.AttributeDefinition(this.def);this.def.spriteClass=this});Ext.cmd.derive('Ext.draw.Path',Ext.Base,{statics:{pathRe:/,?([achlmqrstvxz]),?/gi,pathRe2:/-/gi,pathSplitRe:/\s|,/g},svgString:'',constructor:function(b){var a=this;a.commands=[];a.params=[];a.cursor=null;a.startX=0;a.startY=0;if(b){a.fromSvgString(b)}},clear:function(){var a=this;a.params.length=0;a.commands.length=0;a.cursor=null;a.startX=0;a.startY=0;a.dirt()},dirt:function(){this.svgString=''},moveTo:function(b,c){var a=this;if(!a.cursor){a.cursor=[b,c]}a.params.push(b,c);a.commands.push('M');a.startX=b;a.startY=c;a.cursor[0]=b;a.cursor[1]=c;a.dirt()},lineTo:function(b,c){var a=this;if(!a.cursor){a.cursor=[b,c];a.params.push(b,c);a.commands.push('M')}else {a.params.push(b,c);a.commands.push('L')}a.cursor[0]=b;a.cursor[1]=c;a.dirt()},bezierCurveTo:function(b,c,f,g,d,e){var a=this;if(!a.cursor){a.moveTo(b,c)}a.params.push(b,c,f,g,d,e);a.commands.push('C');a.cursor[0]=d;a.cursor[1]=e;a.dirt()},quadraticCurveTo:function(b,c,d,e){var a=this;if(!a.cursor){a.moveTo(b,c)}a.bezierCurveTo((2*b+a.cursor[0])/3,(2*c+a.cursor[1])/3,(2*b+d)/3,(2*c+e)/3,d,e)},closePath:function(){var a=this;if(a.cursor){a.cursor=null;a.commands.push('Z');a.dirt()}},arcTo:function(l,m,e,f,d,b,n){var i=this;if(b===undefined){b=d}if(n===undefined){n=0}if(!i.cursor){i.moveTo(l,m);return}if(d===0||b===0){i.lineTo(l,m);return}e-=l;f-=m;var g=i.cursor[0]-l,h=i.cursor[1]-m,q=e*h-f*g,j,k,y,A,z,t,w=Math.sqrt(g*g+h*h),x=Math.sqrt(e*e+f*f),u,c,a;if(q===0){i.lineTo(l,m);return}if(b!==d){j=Math.cos(n);k=Math.sin(n);y=j/d;A=k/b;z=-k/d;t=j/b;var v=y*g+A*h;h=z*g+t*h;g=v;v=y*e+A*f;f=z*e+t*f;e=v}else {g/=d;h/=b;e/=d;f/=b}c=g*x+e*w;a=h*x+f*w;u=1/(Math.sin(Math.asin(Math.abs(q)/(w*x))*0.5)*Math.sqrt(c*c+a*a));c*=u;a*=u;var B=(c*g+a*h)/(g*g+h*h),C=(c*e+a*f)/(e*e+f*f);var r=g*B-c,s=h*B-a,D=e*C-c,E=f*C-a,o=Math.atan2(s,r),p=Math.atan2(E,D);if(q>0){if(p=Math.PI*2){b.ellipse(j,k,h,i,g,d,d+Math.PI,l);b.ellipse(j,k,h,i,g,d+Math.PI,e,l);return}if(!l){if(e=y){s.push(d+b*p+f,e+c*p+g,d*p+b+f,e*p+c+g,b+f,c+g);u+=6;a-=y;o=d;d=b;b=-o;o=e;e=c;c=-o}if(a){i=(0.3294738052815987+0.012120855841304373*a)*a;h=Math.cos(a);j=Math.sin(a);v=h+i*j;w=j-i*h;s.push(d+b*i+f,e+c*i+g,d*v+b*w+f,e*v+c*w+g,d*h+b*j+f,e*h+c*j+g);u+=6}return u},arcSvg:function(b,c,i,y,m,v,x){if(b<0){b=-b}if(c<0){c=-c}var n=this,u=n.cursor[0],w=n.cursor[1],q=(u-v)/2,r=(w-x)/2,g=Math.cos(i),h=Math.sin(i),o=q*g+r*h,p=-q*h+r*g,k=o/b,l=p/c,a=k*k+l*l,s=(u+v)*0.5,t=(w+x)*0.5,e=0,f=0;if(a>=1){a=Math.sqrt(a);b*=a;c*=a}else {a=Math.sqrt(1/a-1);if(y===m){a=-a}e=a*b*l;f=-a*c*k;s+=g*e-h*f;t+=h*e+g*f}var j=Math.atan2((p-f)/c,(o-e)/b),d=Math.atan2((-p-f)/c,(-o-e)/b)-j;if(m){if(d<=0){d+=Math.PI*2}}else {if(d>=0){d-=Math.PI*2}}n.ellipse(s,t,b,c,i,j,j+d,1-m)},fromSvgString:function(k){if(!k){return}var e=this,b,g={a:7,c:6,h:1,l:2,m:2,q:4,s:4,t:2,v:1,z:0,A:7,C:6,H:1,L:2,M:2,Q:4,S:4,T:2,V:1,Z:0},h='',i,j,c=0,d=0,l=!1,a,f,m;if(Ext.isString(k)){b=k.replace(Ext.draw.Path.pathRe,' $1 ').replace(Ext.draw.Path.pathRe2,' -').split(Ext.draw.Path.pathSplitRe)}else {if(Ext.isArray(k)){b=k.join(',').split(Ext.draw.Path.pathSplitRe)}}for(a=0,f=0;a=0){f=Math.sqrt(f);a=(f-i)/2/l;if(00){a-=f/l;if(0a.x){c=a.x}if(ha.y){d=a.y}if(f=e.length||!d.isVisible()){return c}a.attr=e[b];c=a.isVisible(point,options);a.attr=f;return c},render:function(h,c,g,d){var e=this,b=e.getTemplate(),k=e.attr.matrix,j=b.attr,f=e.instances,a,i=e.position;k.toContext(c);b.preRender(h,c,g,d);b.useAttributes(c,d);for(a=0;ac){a=e.substr(c,d-c)}else {continue}}f=a.indexOf('/');if(f>0){a=a.substr(0,f)}else {if(f===0){continue}}if(a!=='normal'&&a!=='inherit'){g=h[a];if(g){b[g]=a}else {if(a.match(Ext.dom.Element.unitRe)){b.fontSize=a}else {b.fontFamily=e.substr(c);break}}}c=d+1}if(!b.fontStyle){b.fontStyle=''}if(!b.fontVariant){b.fontVariant=''}if(!b.fontWeight){b.fontWeight=''}this.setAttributes(b,!0)},fontProperties:{fontStyle:!0,fontVariant:!0,fontWeight:!0,fontSize:!0,fontFamily:!0},setAttributes:function(a,d,e){var b,c;if(a&&a.font){c={};for(b in a){if(!(b in this.fontProperties)){c[b]=a[b]}}a=c}Ext.draw.sprite.Sprite.prototype.setAttributes.call(this,a,d,e)},getBBox:function(d){var b=this,a=b.attr.bbox.plain,c=b.getSurface();if(a.dirty){b.updatePlainBBox(a);a.dirty=!1}if(c.getInherited().rtl&&c.getFlipRtlText()){b.updatePlainBBox(a,!0)}return Ext.draw.sprite.Sprite.prototype.getBBox.call(this,d)},rtlAlignments:{start:'end',center:'center',end:'start'},updatePlainBBox:function(j,s){var e=this,b=e.attr,g=b.x,l=b.y,k=[],u=b.font,v=b.text,t=b.textBaseline,m=b.textAlign,o=s&&e.oldSize?e.oldSize:e.oldSize=Ext.draw.TextMeasurer.measureText(v,u),n=e.getSurface(),i=n.getInherited().rtl,r=i&&n.getFlipRtlText(),q=n.getRect(),f=o.sizes,h=o.height,c=o.width,p=f?f.length:0,d,a=0;switch(t){case 'hanging':case 'top':break;case 'ideographic':case 'bottom':l-=h;break;case 'alphabetic':l-=h*0.8;break;case 'middle':l-=h*0.5;break;}if(r){g=q[2]-q[0]-g;m=e.rtlAlignments[m]}switch(m){case 'start':if(i){for(;a0&&d>0){c=Math.sqrt(a*a+d*d)*Math.abs(Math.cos(g-Math.atan(a/d)))/2;f=m.createLinearGradient(i+k*c,j+l*c,i-k*c,j-l*c);for(b=0;b=0;a--){b[a].destroy()}}else {for(;a>=0;a--){c=b[a];c.setParent(null);c.setSurface(null)}}b.length=0;this.map={};this.dirtyZIndex=!0},applyItems:function(a){if(this.getItems()){this.removeAll(!0)}return Ext.Array.from(this.add(a))},createItem:function(a){return Ext.create(a.xclass||'sprite.'+a.type,a)},getBBox:function(b,j){var b=Ext.Array.from(b),c=Infinity,g=-Infinity,d=Infinity,f=-Infinity,h,a,e,i;for(e=0,i=b.length;ea.x){c=a.x}if(ga.y){d=a.y}if(f0){a.isPendingRenderFrame=!0;return}var g=a.getRect(),d=a.getBackground(),e=a.getItems(),c,b,f;if(!g){return}a.orderByZIndex();if(a.getDirty()){a.clear();a.clearTransform();if(d){a.renderSprite(d)}for(b=0,f=e.length;bthis.position){this.removeElement(c[c.length-1])}for(b=0;bthis.position){Ext.fly(a[a.length-1]).destroy()}return 'url(#'+this.element.getId()+')'},destroy:function(){var b=this.statics().map,a=this.element;if(a&&a.dom){delete b[a.dom.id];a.destroy()}this.callParent()}},3,0,0,0,0,0,[Ext.draw.engine.SvgContext,'Gradient'],0);Ext.cmd.derive('Ext.draw.engine.Svg',Ext.draw.Surface,{statics:{BBoxTextCache:{}},config:{highPrecision:!1},getElementConfig:function(){return {reference:'element',style:{position:'absolute'},children:[{reference:'innerElement',style:{width:'100%',height:'100%',position:'relative'},children:[{tag:'svg',reference:'svgElement',namespace:'http://www.w3.org/2000/svg',width:'100%',height:'100%',version:1.1}]}]}},constructor:function(b){var a=this;Ext.draw.Surface.prototype.constructor.call(this,b);a.mainGroup=a.createSvgNode('g');a.defElement=a.createSvgNode('defs');a.svgElement.appendChild(a.mainGroup);a.svgElement.appendChild(a.defElement);a.ctx=new Ext.draw.engine.SvgContext(a)},createSvgNode:function(b){var a=document.createElementNS('http://www.w3.org/2000/svg',b);return Ext.get(a)},getSvgElement:function(c,d,b){var a;if(c.dom.childNodes.length>b){a=c.dom.childNodes[b];if(a.tagName===d){return Ext.get(a)}else {Ext.destroy(a)}}a=Ext.get(this.createSvgNode(d));if(b===0){c.insertFirst(a)}else {a.insertAfter(Ext.fly(c.dom.childNodes[b-1]))}a.cache={};return a},setElementAttributes:function(d,c){var f=d.dom,e=d.cache,a,b;for(a in c){b=c[a];if(e[a]!==b){e[a]=b;f.setAttribute(a,b)}}},getNextDef:function(a){return this.getSvgElement(this.defElement,a,this.defPosition++)},clearTransform:function(){var a=this;a.mainGroup.set({transform:a.matrix.toSvg()})},clear:function(){this.ctx.clear();this.defPosition=0},renderSprite:function(a){var d=this,c=d.getRect(),b=d.ctx;if(a.attr.hidden||a.attr.globalAlpha===0){b.save();b.restore();return}a.element=b.save();a.preRender(this);a.useAttributes(b,c);if(!1===a.render(this,b,[0,0,c[2],c[3]])){return !1}a.setDirty(!1);b.restore()},flatten:function(f,e){var a='',g=Ext.getClassName(this),b,d,c;a+='';for(c=0;c';a+=this.serializeNode(b.svgElement.dom);a+=''}a+='';return {data:'data:image/svg+xml;utf8,'+encodeURIComponent(a),type:'svg'}},serializeNode:function(a){var c='',b,d,e,f;if(a.nodeType===document.TEXT_NODE){return a.nodeValue}c+='<'+a.nodeName;if(a.attributes.length){for(b=0,d=a.attributes.length;b';return c},destroy:function(){var a=this;a.ctx.destroy();a.mainGroup.destroy();delete a.mainGroup;delete a.ctx;Ext.draw.Surface.prototype.destroy.call(this)},remove:function(a,b){if(a&&a.element){if(this.ctx){this.ctx.removeElement(a.element)}else {a.element.destroy()}a.element=null}Ext.draw.Surface.prototype.remove.apply(this,arguments)}},1,0,['widget','surface'],{'widget':!0,'surface':!0},0,0,[Ext.draw.engine,'Svg'],0);Ext.draw||(Ext.draw={});Ext.draw.engine||(Ext.draw.engine={});Ext.draw.engine.excanvas=!0;if(!document.createElement('canvas').getContext){(function(){var f=Math;var b=f.round;var n=f.sin;var m=f.cos;var t=f.abs;var s=f.sqrt;var c=10;var e=c/2;var u=+navigator.userAgent.match(/MSIE ([\d.]+)?/)[1];function getContext(){return this.context_||(this.context_=new CanvasRenderingContext2D_(this))}var p=Array.prototype.slice;function bind(c,a,d){var b=p.call(arguments,2);return function(){return c.apply(a,b.concat(p.call(arguments)))}}function encodeHtmlAttribute(a){return String(a).replace(/&/g,'&').replace(/"/g,'"')}function addNamespace(b,a,c){Ext.onReady(function(){if(!b.namespaces[a]){b.namespaces.add(a,c,'#default#VML')}})}function addNamespacesAndStylesheet(a){addNamespace(a,'g_vml_','urn:schemas-microsoft-com:vml');addNamespace(a,'g_o_','urn:schemas-microsoft-com:office:office');if(!a.styleSheets['ex_canvas_']){var b=a.createStyleSheet();b.owningElement.id='ex_canvas_';b.cssText='canvas{display:inline-block;overflow:hidden;text-align:left;width:300px;height:150px}'}}addNamespacesAndStylesheet(document);var o={init:function(b){var a=b||document;a.createElement('canvas');a.attachEvent('onreadystatechange',bind(this.init_,this,a))},init_:function(c){var b=c.getElementsByTagName('canvas');for(var a=0;a1){a--}if(6*a<1){return b+(c-b)*6*a}else {if(2*a<1){return c}else {if(3*a<2){return b+(c-b)*(2/3-a)*6}else {return b}}}}var k={};function processStyle(a){if(a in k){return k[a]}var c,e=1;a=String(a);if(a.charAt(0)=='#'){c=a}else {if(/^rgb/.test(a)){var b=getRgbHslContent(a);var c='#',f;for(var d=0;d<3;d++){if(b[d].indexOf('%')!=-1){f=Math.floor(percent(b[d])*255)}else {f=+b[d]}c+=h[clamp(f,0,255)]}e=+b[3]}else {if(/^hsl/.test(a)){var b=getRgbHslContent(a);c=hslToRgb(b);e=b[3]}else {c=r[a]||a}}}return k[a]={color:c,alpha:e}}var g={style:'normal',variant:'normal',weight:'normal',size:10,family:'sans-serif'};var l={};function processFontStyle(b){if(l[b]){return l[b]}var c=document.createElement('div');var a=c.style;try{a.font=b}catch(v){}return l[b]={style:a.fontStyle||g.style,variant:a.fontVariant||g.variant,weight:a.fontWeight||g.weight,size:a.fontSize||g.size,family:a.fontFamily||g.family}}function getComputedStyle(b,f){var a={};for(var e in b){a[e]=b[e]}var d=parseFloat(f.currentStyle.fontSize),c=parseFloat(b.size);if(typeof b.size=='number'){a.size=b.size}else {if(b.size.indexOf('px')!=-1){a.size=c}else {if(b.size.indexOf('em')!=-1){a.size=d*c}else {if(b.size.indexOf('%')!=-1){a.size=d/100*c}else {if(b.size.indexOf('pt')!=-1){a.size=c/0.75}else {a.size=d}}}}}a.size*=0.981;return a}function buildStyle(a){return a.style+' '+a.variant+' '+a.weight+' '+a.size+'px '+a.family}var q={'butt':'flat','round':'round'};function processLineCap(a){return q[a]||'square'}function CanvasRenderingContext2D_(a){this.m_=createMatrixIdentity();this.mStack_=[];this.aStack_=[];this.currentPath_=[];this.strokeStyle='#000';this.fillStyle='#000';this.lineWidth=1;this.lineJoin='miter';this.lineDash=[];this.lineCap='butt';this.miterLimit=c*1;this.globalAlpha=1;this.font='10px sans-serif';this.textAlign='left';this.textBaseline='alphabetic';this.canvas=a;var e='width:'+a.clientWidth+'px;height:'+a.clientHeight+'px;overflow:hidden;position:absolute';var b=a.ownerDocument.createElement('div');b.style.cssText=e;a.appendChild(b);var d=b.cloneNode(!1);d.style.backgroundColor='red';d.style.filter='alpha(opacity=0)';a.appendChild(d);this.element_=b;this.arcScaleX_=1;this.arcScaleY_=1;this.lineScale_=1}var a=CanvasRenderingContext2D_.prototype;a.clearRect=function(){if(this.textMeasureEl_){this.textMeasureEl_.removeNode(!0);this.textMeasureEl_=null}this.element_.innerHTML=''};a.beginPath=function(){this.currentPath_=[]};a.moveTo=function(b,c){var a=getCoords(this,b,c);this.currentPath_.push({type:'moveTo',x:a.x,y:a.y});this.currentX_=a.x;this.currentY_=a.y};a.lineTo=function(b,c){var a=getCoords(this,b,c);this.currentPath_.push({type:'lineTo',x:a.x,y:a.y});this.currentX_=a.x;this.currentY_=a.y};a.bezierCurveTo=function(a,b,c,d,g,h){var i=getCoords(this,g,h);var e=getCoords(this,a,b);var f=getCoords(this,c,d);bezierCurveTo(this,e,f,i)};function bezierCurveTo(b,c,d,a){b.currentPath_.push({type:'bezierCurveTo',cp1x:c.x,cp1y:c.y,cp2x:d.x,cp2y:d.y,x:a.x,y:a.y});b.currentX_=a.x;b.currentY_=a.y}a.quadraticCurveTo=function(d,e,g,h){var c=getCoords(this,d,e);var b=getCoords(this,g,h);var a={x:this.currentX_+2/3*(c.x-this.currentX_),y:this.currentY_+2/3*(c.y-this.currentY_)};var f={x:a.x+(b.x-this.currentX_)/3,y:a.y+(b.y-this.currentY_)/3};bezierCurveTo(this,a,f,b)};a.arc=function(d,f,a,g,i,h){a*=c;var p=h?'at':'wa';var b=d+m(g)*a-e;var q=f+n(g)*a-e;var l=d+m(i)*a-e;var r=f+n(i)*a-e;if(b==l&&!h){b+=0.125}var o=getCoords(this,d,f);var j=getCoords(this,b,q);var k=getCoords(this,l,r);this.currentPath_.push({type:p,x:o.x,y:o.y,radius:a,xStart:j.x,yStart:j.y,xEnd:k.x,yEnd:k.y})};a.rect=function(a,b,d,c){this.moveTo(a,b);this.lineTo(a+d,b);this.lineTo(a+d,b+c);this.lineTo(a,b+c);this.closePath()};a.strokeRect=function(a,b,d,c){var e=this.currentPath_;this.beginPath();this.moveTo(a,b);this.lineTo(a+d,b);this.lineTo(a+d,b+c);this.lineTo(a,b+c);this.closePath();this.stroke();this.currentPath_=e};a.fillRect=function(a,b,d,c){var e=this.currentPath_;this.beginPath();this.moveTo(a,b);this.lineTo(a+d,b);this.lineTo(a+d,b+c);this.lineTo(a,b+c);this.closePath();this.fill();this.currentPath_=e};a.createLinearGradient=function(b,d,c,e){var a=new CanvasGradient_('gradient');a.x0_=b;a.y0_=d;a.x1_=c;a.y1_=e;return a};a.createRadialGradient=function(d,f,b,e,g,c){var a=new CanvasGradient_('gradientradial');a.x0_=d;a.y0_=f;a.r0_=b;a.x1_=e;a.y1_=g;a.r1_=c;return a};a.drawImage=function(a,u){var j,k,i,h,d,e,m,l;var t=a.runtimeStyle.width;var s=a.runtimeStyle.height;a.runtimeStyle.width='auto';a.runtimeStyle.height='auto';var g=a.width;var f=a.height;a.runtimeStyle.width=t;a.runtimeStyle.height=s;if(arguments.length==3){j=arguments[1];k=arguments[2];d=e=0;m=i=g;l=h=f}else {if(arguments.length==5){j=arguments[1];k=arguments[2];i=arguments[3];h=arguments[4];d=e=0;m=g;l=f}else {if(arguments.length==9){d=arguments[1];e=arguments[2];m=arguments[3];l=arguments[4];j=arguments[5];k=arguments[6];i=arguments[7];h=arguments[8]}else {throw Error('Invalid number of arguments')}}}var r=getCoords(this,j,k);var o=[];var q=10;var p=10;var n=this.m_;o.push(' ','','');this.element_.insertAdjacentHTML('BeforeEnd',o.join(''))};a.setLineDash=function(a){if(a.length===1){a=a.slice();a[1]=a[0]}this.lineDash=a};a.getLineDash=function(){return this.lineDash};a.stroke=function(g){var d=[];var j=10;var i=10;d.push('');if(!g){appendStroke(this,d)}else {appendFill(this,d,f,e)}d.push('');this.element_.insertAdjacentHTML('beforeEnd',d.join(''))};function appendStroke(a,e){var d=processStyle(a.strokeStyle);var f=d.color;var c=d.alpha*a.globalAlpha;var b=a.lineScale_*a.lineWidth;if(b<1){c*=b}e.push('')}function appendFill(b,m,g,v){var a=b.fillStyle;var h=b.arcScaleX_;var i=b.arcScaleY_;var k=v.x-g.x;var j=v.y-g.y;if(a instanceof CanvasGradient_){var e=0;var o={x:0,y:0};var p=0;var s=1;if(a.type_=='gradient'){var G=a.x0_/h;var I=a.y0_/i;var H=a.x1_/h;var J=a.y1_/i;var l=getCoords(b,G,I);var w=getCoords(b,H,J);var E=w.x-l.x;var F=w.y-l.y;e=Math.atan2(E,F)*180/Math.PI;if(e<0){e+=360}if(e<1.0E-6){e=0}}else {var l=getCoords(b,a.x0_,a.y0_);o={x:(l.x-g.x)/k,y:(l.y-g.y)/j};k/=h*c;j/=i*c;var r=f.max(k,j);p=2*a.r0_/r;s=2*a.r1_/r-p}var d=a.colors_;d.sort(function(a,c){return a.offset-c.offset});var n=d.length;var B=d[0].color;var C=d[n-1].color;var y=d[0].alpha*b.globalAlpha;var z=d[n-1].alpha*b.globalAlpha;var t=[];for(var q=0;q')}else {if(a instanceof CanvasPattern_){if(k&&j){var K=-g.x;var L=-g.y;m.push('')}}else {var x=processStyle(b.fillStyle);var D=x.color;var A=x.alpha*b.globalAlpha;m.push('')}}}a.fill=function(){this.$stroke(!0)};a.closePath=function(){this.currentPath_.push({type:'close'})};function getCoords(f,b,d){var a=f.m_;return {x:c*(b*a[0][0]+d*a[1][0]+a[2][0])-e,y:c*(b*a[0][1]+d*a[1][1]+a[2][1])-e}}a.save=function(){var a={};copyState(this,a);this.aStack_.push(a);this.mStack_.push(this.m_);this.m_=matrixMultiply(createMatrixIdentity(),this.m_)};a.restore=function(){if(this.aStack_.length){copyState(this.aStack_.pop(),this);this.m_=this.mStack_.pop()}};function matrixIsFinite(a){return isFinite(a[0][0])&&isFinite(a[0][1])&&isFinite(a[1][0])&&isFinite(a[1][1])&&isFinite(a[2][0])&&isFinite(a[2][1])}function setM(b,a,c){if(!matrixIsFinite(a)){return}b.m_=a;if(c){var d=a[0][0]*a[1][1]-a[0][1]*a[1][0];b.lineScale_=s(t(d))}}a.translate=function(a,b){var c=[[1,0,0],[0,1,0],[a,b,1]];setM(this,matrixMultiply(c,this.m_),!1)};a.rotate=function(a){var b=m(a);var c=n(a);var d=[[b,c,0],[-c,b,0],[0,0,1]];setM(this,matrixMultiply(d,this.m_),!1)};a.scale=function(a,b){this.arcScaleX_*=a;this.arcScaleY_*=b;var c=[[a,0,0],[0,b,0],[0,0,1]];setM(this,matrixMultiply(c,this.m_),!0)};a.transform=function(a,b,c,d,e,f){var g=[[a,b,0],[c,d,0],[e,f,1]];setM(this,matrixMultiply(g,this.m_),!0)};a.setTransform=function(a,b,c,d,e,f){var g=[[a,b,0],[c,d,0],[e,f,1]];setM(this,g,!0)};a.drawText_=function(q,r,s,t,j){var i=this.m_,k=1000,e=0,h=k,g={x:0,y:0},d=[];var f=getComputedStyle(processFontStyle(this.font),this.element_);var n=buildStyle(f);var l=this.element_.currentStyle;var a=this.textAlign.toLowerCase();switch(a){case 'left':case 'center':case 'right':break;case 'end':a=l.direction=='ltr'?'right':'left';break;case 'start':a=l.direction=='rtl'?'right':'left';break;default:a='left';}switch(this.textBaseline){case 'hanging':case 'top':g.y=f.size/1.75;break;case 'middle':break;default:case null:case 'alphabetic':case 'ideographic':case 'bottom':g.y=-f.size/3;break;}switch(a){case 'right':e=k;h=0.05;break;case 'center':e=h=k/2;break;}var m=getCoords(this,r+g.x,s+g.y);d.push('');if(j){appendStroke(this,d)}else {appendFill(this,d,{x:-e,y:0},{x:h,y:f.size})}var p=i[0][0].toFixed(3)+','+i[1][0].toFixed(3)+','+i[0][1].toFixed(3)+','+i[1][1].toFixed(3)+',0,0';var o=b(m.x/c)+','+b(m.y/c);d.push('','','');this.element_.insertAdjacentHTML('beforeEnd',d.join(''))};a.fillText=function(b,c,d,a){this.drawText_(b,c,d,a,!1)};a.strokeText=function(b,c,d,a){this.drawText_(b,c,d,a,!0)};a.measureText=function(a){if(!this.textMeasureEl_){var c='';this.element_.insertAdjacentHTML('beforeEnd',c);this.textMeasureEl_=this.element_.lastChild}var b=this.element_.ownerDocument;this.textMeasureEl_.innerHTML='';this.textMeasureEl_.style.font=this.font;this.textMeasureEl_.appendChild(b.createTextNode(a));return {width:this.textMeasureEl_.offsetWidth}};a.clip=function(){};a.arcTo=function(){};a.createPattern=function(b,a){return new CanvasPattern_(b,a)};function CanvasGradient_(a){this.type_=a;this.x0_=0;this.y0_=0;this.r0_=0;this.x1_=0;this.y1_=0;this.r1_=0;this.colors_=[]}CanvasGradient_.prototype.addColorStop=function(b,a){a=processStyle(a);this.colors_.push({offset:b,color:a.color,alpha:a.alpha})};function CanvasPattern_(a,b){assertImageIsValid(a);switch(b){case 'repeat':case null:case '':this.repetition_='repeat';break;case 'repeat-x':case 'repeat-y':case 'no-repeat':this.repetition_=b;break;default:throwException('SYNTAX_ERR');}this.src_=a.src;this.width_=a.width;this.height_=a.height}function throwException(a){throw new DOMException_(a)}function assertImageIsValid(a){if(!a||a.nodeType!=1||a.tagName!='IMG'){throwException('TYPE_MISMATCH_ERR')}if(a.readyState!='complete'){throwException('INVALID_STATE_ERR')}}function DOMException_(a){this.code=this[a];this.message=a+': DOM Exception '+this.code}var d=DOMException_.prototype=new Error();d.INDEX_SIZE_ERR=1;d.DOMSTRING_SIZE_ERR=2;d.HIERARCHY_REQUEST_ERR=3;d.WRONG_DOCUMENT_ERR=4;d.INVALID_CHARACTER_ERR=5;d.NO_DATA_ALLOWED_ERR=6;d.NO_MODIFICATION_ALLOWED_ERR=7;d.NOT_FOUND_ERR=8;d.NOT_SUPPORTED_ERR=9;d.INUSE_ATTRIBUTE_ERR=10;d.INVALID_STATE_ERR=11;d.SYNTAX_ERR=12;d.INVALID_MODIFICATION_ERR=13;d.NAMESPACE_ERR=14;d.INVALID_ACCESS_ERR=15;d.VALIDATION_ERR=16;d.TYPE_MISMATCH_ERR=17;G_vmlCanvasManager=o;CanvasRenderingContext2D=CanvasRenderingContext2D_;CanvasGradient=CanvasGradient_;CanvasPattern=CanvasPattern_;DOMException=DOMException_})()}Ext.cmd.derive('Ext.draw.engine.Canvas',Ext.draw.Surface,{config:{highPrecision:!1},statics:{contextOverrides:{setGradientBBox:function(a){this.bbox=a},fill:function(){var d=this.fillStyle,b=this.fillGradient,a=this.fillOpacity,e=this.globalAlpha,c=this.bbox;if(d!==Ext.draw.Color.RGBA_NONE&&a!==0){if(b&&c){this.fillStyle=b.generateGradient(this,c)}if(a!==1){this.globalAlpha=e*a}this.$fill();if(a!==1){this.globalAlpha=e}if(b&&c){this.fillStyle=d}}},stroke:function(){var d=this.strokeStyle,b=this.strokeGradient,a=this.strokeOpacity,e=this.globalAlpha,c=this.bbox;if(d!==Ext.draw.Color.RGBA_NONE&&a!==0){if(b&&c){this.strokeStyle=b.generateGradient(this,c)}if(a!==1){this.globalAlpha=e*a}this.$stroke();if(a!==1){this.globalAlpha=e}if(b&&c){this.strokeStyle=d}}},fillStroke:function(d,b){var a=this,j=this.fillStyle,f=this.fillOpacity,h=this.strokeStyle,e=this.strokeOpacity,g=a.shadowColor,i=a.shadowBlur,c=Ext.draw.Color.RGBA_NONE;if(b===undefined){b=d.transformFillStroke}if(!b){d.inverseMatrix.toContext(a)}if(j!==c&&f!==0){a.fill();a.shadowColor=c;a.shadowBlur=0}if(h!==c&&e!==0){a.stroke()}a.shadowColor=g;a.shadowBlur=i},setLineDash:function(a){if(this.$setLineDash){this.$setLineDash(a)}},getLineDash:function(){if(this.$getLineDash){return this.$getLineDash()}},ellipse:function(e,f,c,d,g,i,j,h){var a=Math.cos(g),b=Math.sin(g);this.transform(a*c,b*c,-b*d,a*d,e,f);this.arc(0,0,1,i,j,h);this.transform(a/c,-b/d,b/c,a/d,-(a*e+b*f)/c,(b*e-a*f)/d)},appendPath:function(f){var c=this,d=0,a=0,e=f.commands,b=f.params,g=e.length;c.beginPath();for(;d=g.length){a.createCanvas()}b=g[c].dom;b.style.left=h+'px';b.style.top=i+'px';j=Math.min(e,p-i);if(j*f!==b.height){b.height=j*f;b.style.height=j+'px'}k=Math.min(e,q-h);if(k*f!==b.width){b.width=k*f;b.style.width=k+'px'}a.applyDefaults(a.contexts[c])}}for(c+=1;cs||a.x+a.widthr||a.y+a.height=0},filename:Ext.isString,width:Ext.isNumber,height:Ext.isNumber,scale:Ext.isNumber,pdf:Ext.isObject,jpeg:Ext.isObject},initAnimator:function(){this.frameCallbackId=Ext.draw.Animator.addFrameCallback('renderFrame',this)},applyGradients:function(d){var b=[],c,f,a,e;if(!Ext.isArray(d)){return b}for(c=0,f=d.length;c=0&&g[a[c].type]>i){a[c+1]=a[c];c--}a[c+1]=f}b=a[0].flatten(j,a);if(h==='image'){e=new Image();e.src=b.data;b.data=e;return b}if(h==='stream'){b.data=b.data.replace(/^data:image\/[^;]+/,'data:application/octet-stream');return b}return b},download:function(a){var d=this,e=[],f,b,c;a=Ext.apply({version:2,data:d.getImage().data},a);for(b in a){if(a.hasOwnProperty(b)){c=a[b];if(b in d.supportedOptions){if(d.supportedOptions[b].call(d,c)){e.push({tag:'input',type:'hidden',name:b,value:Ext.String.htmlEncode(Ext.isObject(c)?Ext.JSON.encode(c):c)})}}}}f=Ext.dom.Helper.markup({tag:'html',children:[{tag:'head'},{tag:'body',children:[{tag:'form',method:'POST',action:a.url||d.defaultDownloadServerUrl,children:e},{tag:'script',type:'text/javascript',children:'document.getElementsByTagName("form")[0].submit();'}]}]});window.open('','ImageDownload_'+Date.now()).document.write(f)},destroy:function(){var a=this.frameCallbackId;if(a){Ext.draw.Animator.removeFrameCallback(a)}Ext.draw.ContainerBase.prototype.destroy.call(this)}},0,['draw'],['component','box','container','panel','draw'],{'component':!0,'box':!0,'container':!0,'panel':!0,'draw':!0},['widget.draw'],0,[Ext.draw,'Container',Ext.draw,'Component'],function(){if(location.search.match('svg')){Ext.draw.Container.prototype.engine='Ext.draw.engine.Svg'}else {if(Ext.os.is.BlackBerry&&Ext.os.version.getMajor()===10||Ext.browser.is.AndroidStock4&&(Ext.os.version.getMinor()===1||Ext.os.version.getMinor()===2||Ext.os.version.getMinor()===3)){Ext.draw.Container.prototype.engine='Ext.draw.engine.Svg'}}});Ext.cmd.derive('Ext.chart.theme.Base',Ext.Base,{factoryConfig:{type:'chart.theme'},isTheme:!0,config:{baseColor:null,colors:undefined,gradients:null,chart:{defaults:{background:'white'}},axis:{defaults:{label:{x:0,y:0,textBaseline:'middle',textAlign:'center',fontSize:'default',fontFamily:'default',fontWeight:'default',fillStyle:'black'},title:{fillStyle:'black',fontSize:'default*1.23',fontFamily:'default',fontWeight:'default'},style:{strokeStyle:'black'},grid:{strokeStyle:'rgb(221, 221, 221)'}},top:{style:{textPadding:5}},bottom:{style:{textPadding:5}}},series:{defaults:{label:{fillStyle:'black',strokeStyle:'none',fontFamily:'default',fontWeight:'default',fontSize:'default*1.077',textBaseline:'middle',textAlign:'center'},labelOverflowPadding:5}},sprites:{text:{fontSize:'default',fontWeight:'default',fontFamily:'default',fillStyle:'black'}},seriesThemes:undefined,markerThemes:{type:['circle','cross','plus','square','triangle','diamond']},useGradients:!1,background:null},colorDefaults:['#94ae0a','#115fa6','#a61120','#ff8809','#ffd13e','#a61187','#24ad9a','#7c7474','#a66111'],constructor:function(a){this.initConfig(a);this.resolveDefaults()},defaultRegEx:/^default([+\-/\*]\d+(?:\.\d+)?)?$/,defaultOperators:{'*':function(a,b){return a*b},'+':function(a,b){return a+b},'-':function(a,b){return a-b}},resolveDefaults:function(){var a=this;Ext.onReady(function(){var g=Ext.clone(a.getSprites()),f=Ext.clone(a.getAxis()),e=Ext.clone(a.getSeries()),b,d,c;if(!a.superclass.defaults){b=Ext.getBody().createChild({tag:'div',cls:'x-component'});a.superclass.defaults={fontFamily:b.getStyle('fontFamily'),fontWeight:b.getStyle('fontWeight'),fontSize:parseFloat(b.getStyle('fontSize')),fontVariant:b.getStyle('fontVariant'),fontStyle:b.getStyle('fontStyle')};b.destroy()}a.replaceDefaults(g.text);a.setSprites(g);for(d in f){c=f[d];a.replaceDefaults(c.label);a.replaceDefaults(c.title)}a.setAxis(f);for(d in e){c=e[d];a.replaceDefaults(c.label)}a.setSeries(e)})},replaceDefaults:function(d){var e=this,g=e.superclass.defaults,h=e.defaultRegEx,c,b,a,f;if(Ext.isObject(d)){for(c in g){a=h.exec(d[c]);if(a){b=g[c];a=a[1];if(a){f=e.defaultOperators[a.charAt(0)];b=Math.round(f(b,parseFloat(a.substr(1))))}d[c]=b}}}},applyBaseColor:function(b){var a,c;if(b){a=b.isColor?b:Ext.draw.Color.fromString(b);c=a.getHSL()[2];if(c<0.15){a=a.createLighter(0.3)}else {if(c<0.3){a=a.createLighter(0.15)}else {if(c>0.85){a=a.createDarker(0.3)}else {if(c>0.7){a=a.createDarker(0.15)}}}}this.setColors([a.createDarker(0.3).toString(),a.createDarker(0.15).toString(),a.toString(),a.createLighter(0.12).toString(),a.createLighter(0.24).toString(),a.createLighter(0.31).toString()])}return b},applyColors:function(a){return a||this.colorDefaults},updateUseGradients:function(a){if(a){this.updateGradients({type:'linear',degrees:90})}},updateBackground:function(a){if(a){var b=this.getChart();b.defaults.background=a;this.setChart(b)}},updateGradients:function(d){var c=this.getColors(),g=[],e,a,f,b,h;if(Ext.isObject(d)){for(b=0,h=c&&c.length||0;bMath.PI){c-=Math.PI*2}if(p){c=c*(1-b)-Math.PI/2*b;m=h;h=g;g=m}else {c=c*(1-b)}a.rotationRads=c;a.x=n*(1-b)+j*b;a.y=o*(1-b)+k*b;d=j-n;e=k-o;if(Math.abs(e*h)>Math.abs(d*g)){if(e>0){a.calloutEndX=a.x-g/2*(d/e)*b;a.calloutEndY=a.y-g/2*b}else {a.calloutEndX=a.x+g/2*(d/e)*b;a.calloutEndY=a.y+g/2*b}}else {if(d>0){a.calloutEndX=a.x-h/2;a.calloutEndY=a.y-h/2*(e/d)*b}else {a.calloutEndX=a.x+h/2;a.calloutEndY=a.y+h/2*(e/d)*b}}if(a.calloutStartX&&a.calloutStartY){a.calloutHasLine=d>0&&a.calloutStartXa.calloutEndX||e>0&&a.calloutStartYa.calloutEndY}else {a.calloutHasLine=!0}}return a},pushDown:function(b,a){a=Ext.draw.modifier.Modifier.prototype.pushDown.call(this,b.calloutOriginal,a);return this.setAttrs(b,a)},popUp:function(a,b){a=a.prototype;b=this.setAttrs(a,b);if(this._next){return this._next.popUp(a,b)}else {return Ext.apply(a,b)}}},0,0,0,0,0,0,[Ext.chart.label,'Callout'],0);Ext.cmd.derive('Ext.chart.label.Label',Ext.draw.sprite.Text,{inheritableStatics:{def:{processors:{callout:'limited01',calloutHasLine:'bool',calloutPlaceX:'number',calloutPlaceY:'number',calloutStartX:'number',calloutStartY:'number',calloutEndX:'number',calloutEndY:'number',calloutColor:'color',calloutWidth:'number',calloutVertical:'bool',labelOverflowPadding:'number',display:'enums(none,under,over,rotate,insideStart,insideEnd,inside,outside)',orientation:'enums(horizontal,vertical)',renderer:'default'},defaults:{callout:0,calloutHasLine:!0,calloutPlaceX:0,calloutPlaceY:0,calloutStartX:0,calloutStartY:0,calloutEndX:0,calloutEndY:0,calloutWidth:1,calloutVertical:!1,calloutColor:'black',labelOverflowPadding:5,display:'none',orientation:'',renderer:null},triggers:{callout:'transform',calloutPlaceX:'transform',calloutPlaceY:'transform',labelOverflowPadding:'transform',calloutRotation:'transform',display:'hidden'},updaters:{hidden:function(a){a.hidden=a.display==='none'}}}},config:{fx:{customDurations:{callout:200}},field:null,calloutLine:!0},applyCalloutLine:function(a){if(a){return Ext.apply({},a)}},prepareModifiers:function(){Ext.draw.sprite.Text.prototype.prepareModifiers.apply(this,arguments);this.calloutModifier=new Ext.chart.label.Callout({sprite:this});this.fx.setNext(this.calloutModifier);this.calloutModifier.setNext(this.topModifier)},render:function(e,a){var b=this,d=b.attr,c=d.calloutColor;a.save();a.globalAlpha*=d.callout;if(a.globalAlpha>0&&d.calloutHasLine){if(c&&c.isGradient){c=c.getStops()[0].color}a.strokeStyle=c;a.fillStyle=c;a.lineWidth=d.calloutWidth;a.beginPath();a.moveTo(b.attr.calloutStartX,b.attr.calloutStartY);a.lineTo(b.attr.calloutEndX,b.attr.calloutEndY);a.stroke();a.beginPath();a.arc(b.attr.calloutStartX,b.attr.calloutStartY,1*d.calloutWidth,0,2*Math.PI,!0);a.fill();a.beginPath();a.arc(b.attr.calloutEndX,b.attr.calloutEndY,1*d.calloutWidth,0,2*Math.PI,!0);a.fill()}a.restore();Ext.draw.sprite.Text.prototype.render.apply(b,arguments)}},0,0,0,0,0,0,[Ext.chart.label,'Label'],0);Ext.cmd.derive('Ext.chart.series.Series',Ext.Base,{isSeries:!0,defaultBindProperty:'store',type:null,seriesType:'sprite',identifiablePrefix:'ext-line-',observableType:'series',darkerStrokeRatio:0.15,config:{chart:null,title:null,renderer:null,showInLegend:!0,triggerAfterDraw:!1,style:{},subStyle:{},themeStyle:{},colors:null,useDarkerStrokeColor:!0,store:null,label:{},labelOverflowPadding:null,showMarkers:!0,marker:null,markerSubStyle:null,itemInstancing:null,background:null,highlightItem:null,surface:null,overlaySurface:null,hidden:!1,highlight:!1,highlightCfg:{merge:function(a){return a},$value:{fillStyle:'yellow',strokeStyle:'red'}},animation:null,tooltip:null},directions:[],sprites:null,themeColorCount:function(){return 1},isStoreDependantColorCount:!1,themeMarkerCount:function(){return 0},getFields:function(d){var f=this,b=[],a,c,e;for(c=0,e=d.length;c0){if(!Ext.isBoolean(k)||!k){for(b=0;bd){d=a}}b.min=e;b.max=d},updateLabelData:function(){var h=this,l=h.getStore(),i=l.getData().items,e=h.getSprites(),k=h.getLabel().getTemplate(),d=Ext.Array.from(k.getField()),a,c,j,f,g,b;if(!e.length||!d.length){return}for(a=0;a=0){return a}}}}}},onChartDetached:function(b){var a=this;a.fireEvent('chartdetached',b,a);b.un('storechange','onStoreChange',a)},onChartAttached:function(b){var a=this;a.setBackground(a.getBackground());a.fireEvent('chartattached',b,a);b.on('storechange','onStoreChange',a);a.processData()},updateOverlaySurface:function(b){var a=this;if(b){if(a.getLabel()){a.getOverlaySurface().add(a.getLabel())}}},applyLabel:function(b,a){if(!a){a=new Ext.chart.Markers({zIndex:10});a.setTemplate(new Ext.chart.label.Label(b))}else {a.getTemplate().setAttributes(b)}return a},createItemInstancingSprite:function(f,e){var d=this,a=new Ext.chart.Markers(),c,b;a.setAttributes({zIndex:Number.MAX_VALUE});c=Ext.apply({},e);if(d.getHighlight()){c.highlight=d.getHighlight();c.modifiers=['highlight']}a.setTemplate(c);b=a.getTemplate();b.setAttributes(d.getStyle());b.fx.on('animationstart','onSpriteAnimationStart',this);b.fx.on('animationend','onSpriteAnimationEnd',this);f.bindMarker('items',a);d.getSurface().add(a);return a},getDefaultSpriteConfig:function(){return {type:this.seriesType,renderer:this.getRenderer()}},updateRenderer:function(d){var c=this,a=c.getChart(),b;if(a&&a.isInitializing){return}b=c.getSprites();if(b.length){b[0].setAttributes({renderer:d||null});if(a&&!a.isInitializing){a.redraw()}}},updateShowMarkers:function(d){var b=this.getSprites(),c=b&&b[0],a=c&&c.getMarker('markers');if(a){a.getTemplate().setAttributes({hidden:!d})}},createSprite:function(){var a=this,g=a.getSurface(),e=a.getItemInstancing(),b=g.add(a.getDefaultSpriteConfig()),f=a.getMarker(),c,d;b.setAttributes(a.getStyle());b.setSeries(a);if(e){b.itemsMarker=a.createItemInstancingSprite(b,e)}if(b.bindMarker){if(f){c=new Ext.chart.Markers();d=Ext.Object.merge({},f);if(a.getHighlight()){d.highlight=a.getHighlight();d.modifiers=['highlight']}c.setTemplate(d);c.getTemplate().fx.setCustomDurations({translationX:0,translationY:0});b.dataMarker=c;b.bindMarker('markers',c);a.getOverlaySurface().add(c)}if(a.getLabel().getTemplate().getField()){b.bindMarker('labels',a.getLabel())}}if(b.setStore){b.setStore(a.getStore())}b.fx.on('animationstart','onSpriteAnimationStart',a);b.fx.on('animationend','onSpriteAnimationEnd',a);a.sprites.push(b);return b},getSprites:Ext.emptyFn,onDataChanged:function(){var a=this,b=a.getChart(),d=b&&b.getStore(),c=a.getStore();if(c!==d){a.processData()}},isXType:function(a){return a==='series'},getItemId:function(){return this.getId()},applyThemeStyle:function(a,e){var d=this,b,c;b=a&&a.subStyle&&a.subStyle.fillStyle;c=b&&a.subStyle.strokeStyle;if(b&&!c){a.subStyle.strokeStyle=d.getStrokeColorsFromFillColors(b)}b=a&&a.markerSubStyle&&a.markerSubStyle.fillStyle;c=b&&a.markerSubStyle.strokeStyle;if(b&&!c){a.markerSubStyle.strokeStyle=d.getStrokeColorsFromFillColors(b)}return Ext.apply(e||{},a)},applyStyle:function(a,c){var b=Ext.ClassManager.get(Ext.ClassManager.getNameByAlias('sprite.'+this.seriesType));if(b&&b.def){a=b.def.normalize(a)}return Ext.apply({},a,c)},applySubStyle:function(a,c){var b=Ext.ClassManager.get(Ext.ClassManager.getNameByAlias('sprite.'+this.seriesType));if(b&&b.def){a=b.def.batchedNormalize(a,!0)}return Ext.merge({},c,a)},applyMarker:function(a,b){var d=a&&a.type||b&&b.type||'circle',c=Ext.ClassManager.get(Ext.ClassManager.getNameByAlias('sprite.'+d));if(c&&c.def){a=c.def.normalize(Ext.isObject(a)?a:{},!0);a.type=d}return Ext.merge(b||{},a)},applyMarkerSubStyle:function(a,b){var d=a&&a.type||b&&b.type||'circle',c=Ext.ClassManager.get(Ext.ClassManager.getNameByAlias('sprite.'+d));if(c&&c.def){a=c.def.batchedNormalize(a,!0)}return Ext.merge(b||{},a)},updateHidden:function(b){var a=this;a.getColors();a.getSubStyle();a.setSubStyle({hidden:b});a.processData();a.doUpdateStyles();if(!Ext.isArray(b)){a.updateLegendStore(b)}},updateLegendStore:function(c,g){var e=this,f=e.getChart(),b=f.getLegendStore(),d=e.getId(),a;if(b){if(arguments.length>1){a=b.findBy(function(a){return a.get('series')===d&&a.get('index')===g});if(a!==-1){a=b.getAt(a)}}else {a=b.findRecord('series',d)}if(a&&a.get('disabled')!==c){a.set('disabled',c)}}},setHiddenByIndex:function(c,b){var a=this;if(Ext.isArray(a.getHidden())){a.getHidden()[c]=b;a.updateHidden(a.getHidden());a.updateLegendStore(b,c)}else {a.setHidden(b)}},getStrokeColorsFromFillColors:function(c){var d=this,b=d.getUseDarkerStrokeColor(),e=Ext.isNumber(b)?b:d.darkerStrokeRatio,a;if(b){a=Ext.Array.map(c,function(a){a=Ext.isString(a)?a:a.stops[0].color;a=Ext.draw.Color.fromString(a);return a.createDarker(e).toString()})}else {a=Ext.Array.clone(c)}return a},updateThemeColors:function(d){var b=this,a=b.getThemeStyle(),f=Ext.Array.clone(d),e=b.getStrokeColorsFromFillColors(d),c={fillStyle:f,strokeStyle:e};a.subStyle=Ext.apply(a.subStyle||{},c);a.markerSubStyle=Ext.apply(a.markerSubStyle||{},c);b.doUpdateStyles()},themeOnlyIfConfigured:{},updateTheme:function(o){var c=this,d=o.getSeries(),m=c.getInitialConfig(),l=c.defaultConfig,n=c.getConfigurator().configs,k=d.defaults,j=d[c.type],i=c.themeOnlyIfConfigured,b,a,g,e,f,h;d=Ext.merge({},k,j);for(b in d){a=d[b];h=n[b];if(a!==null&&a!==undefined&&h){f=m[b];g=Ext.isObject(a);e=f===l[b];if(g){if(e&&i[b]){continue}a=Ext.merge({},a,f)}if(e||g){c[h.names.set](a)}}}},updateChartColors:function(b){var a=this;if(!a.getColors()){a.updateThemeColors(b)}},updateColors:function(a){this.updateThemeColors(a)},updateStyle:function(){this.doUpdateStyles()},updateSubStyle:function(){this.doUpdateStyles()},updateThemeStyle:function(){this.doUpdateStyles()},doUpdateStyles:function(){var c=this,b=c.sprites,e=c.getItemInstancing(),a=0,g=b&&b.length,h=c.getConfig('showMarkers',!0),f=c.getMarker(),d;for(;aa.to){c.call(this,a.max,a.getLabel(a.max),a.steps+1,a)}}else {var f=function(b){return !d.length||k(d,function(d){return l(d-b)>i})};h=this.getAxis();g=h.floatingAxes;d=[];i=(a.to-a.from)/(a.steps+1);if(h.getFloating()){for(j in g){d.push(g[j])}}if(a.mina.to&&f(a.max)){c.call(this,a.max,a.max,a.steps+1,a)}}},renderTicks:function(j,b,p,i){var c=this,a=c.attr,v=a.position,k=a.matrix,g=0.5*a.lineWidth,s=k.getXX(),q=k.getDX(),t=k.getYY(),r=k.getDY(),f=p.majorTicks,d=a.majorTickSize,e=p.minorTicks,h=a.minorTickSize;if(f){switch(v){case 'right':var m=function(a){return function(c,d,e){c=j.roundPixel(c*t+r)+g;b.moveTo(0,c);b.lineTo(a,c)}};c.iterate(f,m(d));e&&c.iterate(e,m(h));break;case 'left':var n=function(a){return function(c,d,e){c=j.roundPixel(c*t+r)+g;b.moveTo(i[2]-a,c);b.lineTo(i[2],c)}};c.iterate(f,n(d));e&&c.iterate(e,n(h));break;case 'bottom':var l=function(a){return function(c,d,e){c=j.roundPixel(c*s+q)-g;b.moveTo(c,0);b.lineTo(c,a)}};c.iterate(f,l(d));e&&c.iterate(e,l(h));break;case 'top':var o=function(a){return function(c,d,e){c=j.roundPixel(c*s+q)-g;b.moveTo(c,i[3]);b.lineTo(c,i[3]-a)}};c.iterate(f,o(d));e&&c.iterate(e,o(h));break;case 'angular':c.iterate(f,function(c,e,f){c=c/(a.max+1)*Math.PI*2+a.baseRotation;b.moveTo(a.centerX+a.length*Math.cos(c),a.centerY+a.length*Math.sin(c));b.lineTo(a.centerX+(a.length+d)*Math.cos(c),a.centerY+(a.length+d)*Math.sin(c))});break;case 'gauge':var u=c.getGaugeAngles();c.iterate(f,function(c,e,f){c=(c-a.min)/(a.max-a.min+1)*a.totalAngle-a.totalAngle+u.start;b.moveTo(a.centerX+a.length*Math.cos(c),a.centerY+a.length*Math.sin(c));b.lineTo(a.centerX+(a.length+d)*Math.cos(c),a.centerY+(a.length+d)*Math.sin(c))});break;}}},renderLabels:function(e,G,i,s){var h=this,a=h.attr,q=0.5*a.lineWidth,t=a.position,A=a.matrix,F=a.textPadding,J=A.getXX(),v=A.getDX(),K=A.getYY(),I=A.getDY(),m=0,w=i.majorTicks,k=Math.max(a.majorTickSize,a.minorTickSize)+a.lineWidth,y=Ext.draw.Draw.isBBoxIntersect,b=h.getLabel(),E,C,f=null,p=0,u=0,z=i.segmenter,o=h.getRenderer(),l=h.getAxis(),D=l.getTitle(),n=D&&D.attr.text!==''&&D.getBBox(),B,g=null,c,x,d,j,r;if(w&&b&&!b.attr.hidden){E=b.attr.font;if(G.font!==E){G.font=E}b.setAttributes({translationX:0,translationY:0},!0);b.applyTransformations();B=b.attr.inverseMatrix.elements.slice(0);switch(t){case 'left':j=n?n.x+n.width:0;switch(b.attr.textAlign){case 'start':r=e.roundPixel(j+v)-q;break;case 'end':r=e.roundPixel(s[2]-k+v)-q;break;default:r=e.roundPixel(j+(s[2]-j-k)/2+v)-q;};b.setAttributes({translationX:r},!0);break;case 'right':j=n?s[2]-n.x:0;switch(b.attr.textAlign){case 'start':r=e.roundPixel(k+v)+q;break;case 'end':r=e.roundPixel(s[2]-j+v)+q;break;default:r=e.roundPixel(k+(s[2]-k-j)/2+v)+q;};b.setAttributes({translationX:r},!0);break;case 'top':j=n?n.y+n.height:0;b.setAttributes({translationY:e.roundPixel(j+(s[3]-j-k)/2)-q},!0);break;case 'bottom':j=n?s[3]-n.y:0;b.setAttributes({translationY:e.roundPixel(k+(s[3]-k-j)/2)+q},!0);break;case 'radial':b.setAttributes({translationX:a.centerX},!0);break;case 'angular':b.setAttributes({translationY:a.centerY},!0);break;case 'gauge':b.setAttributes({translationY:a.centerY},!0);break;}if(t==='left'||t==='right'){h.iterate(w,function(j,a,n){if(a===undefined){return}if(o){d=Ext.callback(o,null,[l,a,i,f],0,l)}else {d=z.renderer(a,i,f)}f=a;b.setAttributes({text:String(d),translationY:e.roundPixel(j*K+I)},!0);b.applyTransformations();m=Math.max(m,b.getBBox().width+k);if(m<=h.thickness){x=Ext.draw.Matrix.fly(b.attr.matrix.elements.slice(0));c=x.prepend.apply(x,B).transformBBox(b.getBBox(!0));if(g&&!y(c,g,F)){return}e.renderSprite(b);g=c;p+=c.height;u++}})}else {if(t==='top'||t==='bottom'){h.iterate(w,function(j,a,n){if(a===undefined){return}if(o){d=Ext.callback(o,null,[l,a,i,f],0,l)}else {d=z.renderer(a,i,f)}f=a;b.setAttributes({text:String(d),translationX:e.roundPixel(j*J+v)},!0);b.applyTransformations();m=Math.max(m,b.getBBox().height+k);if(m<=h.thickness){x=Ext.draw.Matrix.fly(b.attr.matrix.elements.slice(0));c=x.prepend.apply(x,B).transformBBox(b.getBBox(!0));if(g&&!y(c,g,F)){return}e.renderSprite(b);g=c;p+=c.width;u++}})}else {if(t==='radial'){h.iterate(w,function(j,h,k){if(h===undefined){return}if(o){d=Ext.callback(o,null,[l,h,i,f],0,l)}else {d=z.renderer(h,i,f)}f=h;if(typeof d!=='undefined'){b.setAttributes({text:String(d),translationX:a.centerX-e.roundPixel(j)/a.max*a.length*Math.cos(a.baseRotation+Math.PI/2),translationY:a.centerY-e.roundPixel(j)/a.max*a.length*Math.sin(a.baseRotation+Math.PI/2)},!0);b.applyTransformations();c=b.attr.matrix.transformBBox(b.getBBox(!0));if(g&&!y(c,g)){return}e.renderSprite(b);g=c;p+=c.width;u++}})}else {if(t==='angular'){C=a.majorTickSize+a.lineWidth*0.5+(parseInt(b.attr.fontSize,10)||10)/2;h.iterate(w,function(k,h,n){if(h===undefined){return}if(o){d=Ext.callback(o,null,[l,h,i,f],0,l)}else {d=z.renderer(h,i,f)}f=h;m=Math.max(m,Math.max(a.majorTickSize,a.minorTickSize)+(a.lineCap!=='butt'?a.lineWidth*0.5:0));if(typeof d!=='undefined'){var j=k/(a.max+1)*Math.PI*2+a.baseRotation;b.setAttributes({text:String(d),translationX:a.centerX+(a.length+C)*Math.cos(j),translationY:a.centerY+(a.length+C)*Math.sin(j)},!0);b.applyTransformations();c=b.attr.matrix.transformBBox(b.getBBox(!0));if(g&&!y(c,g)){return}e.renderSprite(b);g=c;p+=c.width;u++}})}else {if(t==='gauge'){var H=h.getGaugeAngles();h.iterate(w,function(k,h,m){if(h===undefined){return}if(o){d=Ext.callback(o,null,[l,h,i,f],0,l)}else {d=z.renderer(h,i,f)}f=h;if(typeof d!=='undefined'){var j=(k-a.min)/(a.max-a.min+1)*a.totalAngle-a.totalAngle+H.start;b.setAttributes({text:String(d),translationX:a.centerX+(a.length+10)*Math.cos(j),translationY:a.centerY+(a.length+10)*Math.sin(j)},!0);b.applyTransformations();c=b.attr.matrix.transformBBox(b.getBBox(!0));if(g&&!y(c,g)){return}e.renderSprite(b);g=c;p+=c.width;u++}})}}}}}if(a.enlargeEstStepSizeByText&&u){p/=u;p+=k;p*=2;if(a.estStepSize1){h.thickness=m;a.bbox.plain.dirty=!0;a.bbox.transform.dirty=!0;h.doThicknessChanged();return !1}}},renderAxisLine:function(g,b,j,f){var h=this,a=h.attr,c=a.lineWidth*0.5,i=a.position,d,e;if(a.axisLine&&a.length){switch(i){case 'left':d=g.roundPixel(f[2])-c;b.moveTo(d,-a.endGap);b.lineTo(d,a.length+a.startGap+1);break;case 'right':b.moveTo(c,-a.endGap);b.lineTo(c,a.length+a.startGap+1);break;case 'bottom':b.moveTo(-a.startGap,c);b.lineTo(a.length+a.endGap,c);break;case 'top':d=g.roundPixel(f[3])-c;b.moveTo(-a.startGap,d);b.lineTo(a.length+a.endGap,d);break;case 'angular':b.moveTo(a.centerX+a.length,a.centerY);b.arc(a.centerX,a.centerY,a.length,0,Math.PI*2,!0);break;case 'gauge':e=h.getGaugeAngles();b.moveTo(a.centerX+Math.cos(e.start)*a.length,a.centerY+Math.sin(e.start)*a.length);b.arc(a.centerX,a.centerY,a.length,e.start,e.end,!0);break;}}},getGaugeAngles:function(){var c=this,b=c.attr.totalAngle,a;if(b<=Math.PI){a=(Math.PI-b)*0.5}else {a=-(Math.PI*2-b)*0.5}a=Math.PI*2-a;return {start:a,end:a-b}},renderGridLines:function(s,t,p,r){var c=this,q=c.getAxis(),b=c.attr,j=b.matrix,i=b.startGap,k=b.endGap,n=j.getXX(),o=j.getYY(),l=j.getDX(),m=j.getDY(),g=b.position,f=q.getGridAlignment(),h=p.majorTicks,a,e,d;if(b.grid){if(h){if(g==='left'||g==='right'){d=b.min*o+m+k+i;c.iterate(h,function(g,h,b){a=g*o+m+k;c.putMarker(f+'-'+(b%2?'odd':'even'),{y:a,height:d-a},e=b,!0);d=a});e++;a=0;c.putMarker(f+'-'+(e%2?'odd':'even'),{y:a,height:d-a},e,!0)}else {if(g==='top'||g==='bottom'){d=b.min*n+l+i;if(i){c.putMarker(f+'-even',{x:0,width:d},-1,!0)}c.iterate(h,function(g,h,b){a=g*n+l+i;c.putMarker(f+'-'+(b%2?'odd':'even'),{x:a,width:d-a},e=b,!0);d=a});e++;a=b.length+b.startGap+b.endGap;c.putMarker(f+'-'+(e%2?'odd':'even'),{x:a,width:d-a},e,!0)}else {if(g==='radial'){c.iterate(h,function(e,h,g){if(!e){return}a=e/b.max*b.length;c.putMarker(f+'-'+(g%2?'odd':'even'),{scalingX:a,scalingY:a},g,!0);d=a})}else {if(g==='angular'){c.iterate(h,function(g,h,e){if(!b.length){return}a=g/(b.max+1)*Math.PI*2+b.baseRotation;c.putMarker(f+'-'+(e%2?'odd':'even'),{rotationRads:a,rotationCenterX:0,rotationCenterY:0,scalingX:b.length,scalingY:b.length},e,!0);d=a})}}}}}}},renderLimits:function(u){var k=this,i=k.getAxis(),t=i.getChart(),s=t.getInnerPadding(),h=Ext.Array.from(i.getLimits());if(!h.length){return}var m=i.limits.surface.getRect(),c=k.attr,o=c.matrix,g=c.position,p=Ext.Object.chain,d=i.limits.titles,f,l,n,a,b,e,j,q,r;d.instances=[];d.position=0;if(g==='left'||g==='right'){for(e=0,j=h.length;ec.max){continue}b=b/c.max*c.length;a.line.cx=c.centerX;a.line.cy=c.centerY;a.line.scalingX=b;a.line.scalingY=b;a.line.strokeStyle=a.line.strokeStyle||c.strokeStyle;k.putMarker('circular-limit-lines',a.line,e,!0);if(a.line.title){d.createInstance(a.line.title);f=d.getBBoxFor(d.position-1);d.setAttributesFor(d.position-1,{x:c.centerX,y:c.centerY-b-f.height/2,fillStyle:a.line.title.fillStyle||a.line.strokeStyle})}}}else {if(g==='angular'){for(e=0,j=h.length;e-0.5*Math.PI&&b<0.5*Math.PI||b>1.5*Math.PI&&b<2*Math.PI?1:-1;d.setAttributesFor(d.position-1,{x:c.centerX+0.5*c.length*Math.cos(b)+n*f.height/2*Math.sin(b),y:c.centerY+0.5*c.length*Math.sin(b)-n*f.height/2*Math.cos(b),rotationRads:n===1?b:b-Math.PI,fillStyle:a.line.title.fillStyle||a.line.strokeStyle})}}}else {if(g==='gauge'){}}}}}},doThicknessChanged:function(){var a=this.getAxis();if(a){a.onThicknessChanged()}},render:function(e,a,d){var b=this,c=b.getLayoutContext();if(c){if(!1===b.renderLabels(e,a,c,d)){return !1}a.beginPath();b.renderTicks(e,a,c,d);b.renderAxisLine(e,a,c,d);b.renderGridLines(e,a,c,d);b.renderLimits(d);a.stroke()}}},0,0,0,0,['sprite.axis'],[['markerHolder',Ext.chart.MarkerHolder]],[Ext.chart.axis.sprite,'Axis'],0);Ext.cmd.derive('Ext.chart.axis.segmenter.Segmenter',Ext.Base,{config:{axis:null},constructor:function(a){this.initConfig(a)},renderer:function(a,b){return String(a)},from:function(a){return a},diff:Ext.emptyFn,align:Ext.emptyFn,add:Ext.emptyFn,preferredStep:Ext.emptyFn},1,0,0,0,0,0,[Ext.chart.axis.segmenter,'Segmenter'],0);Ext.cmd.derive('Ext.chart.axis.segmenter.Names',Ext.chart.axis.segmenter.Segmenter,{renderer:function(a,b){return a},diff:function(b,a,c){return Math.floor(a-b)},align:function(a,b,c){return Math.floor(a)},add:function(a,b,c){return a+b},preferredStep:function(d,a,b,c){return {unit:1,step:1}}},0,0,0,0,['segmenter.names'],0,[Ext.chart.axis.segmenter,'Names'],0);Ext.cmd.derive('Ext.chart.axis.segmenter.Numeric',Ext.chart.axis.segmenter.Segmenter,{isNumeric:!0,renderer:function(b,a){return b.toFixed(Math.max(0,a.majorTicks.unit.fixes))},diff:function(c,b,a){return Math.floor((b-c)/a.scale)},align:function(c,a,b){return Math.floor(c/(b.scale*a))*b.scale*a},add:function(a,b,c){return a+b*c.scale},preferredStep:function(d,a){var b=Math.floor(Math.log(a)*Math.LOG10E),c=Math.pow(10,b);a/=c;if(a<2){a=2}else {if(a<5){a=5}else {if(a<10){a=10;b++}}}return {unit:{fixes:-b,scale:c},step:a}},exactStep:function(d,a){var b=Math.floor(Math.log(a)*Math.LOG10E),c=Math.pow(10,b);return {unit:{fixes:-b+(a%c===0?0:1),scale:1},step:a}},adjustByMajorUnit:function(g,f,c){var e=c[0],d=c[1],b=g*f,a=e%b;if(a!==0){c[0]=e-a+(e<0?-b:0)}a=d%b;if(a!==0){c[1]=d-a+(d>0?b:0)}}},0,0,0,0,['segmenter.numeric'],0,[Ext.chart.axis.segmenter,'Numeric'],0);Ext.cmd.derive('Ext.chart.axis.segmenter.Time',Ext.chart.axis.segmenter.Segmenter,{config:{step:null},renderer:function(b,c){var a=Ext.Date;switch(c.majorTicks.unit){case 'y':return a.format(b,'Y');case 'mo':return a.format(b,'Y-m');case 'd':return a.format(b,'Y-m-d');}return a.format(b,'Y-m-d\nH:i:s')},from:function(a){return new Date(a)},diff:function(b,a,c){if(isFinite(b)){b=new Date(b)}if(isFinite(a)){a=new Date(a)}return Ext.Date.diff(b,a,c)},align:function(a,b,c){if(c==='d'&&b>=7){a=Ext.Date.align(a,'d',b);a.setDate(a.getDate()-a.getDay()+1);return a}else {return Ext.Date.align(a,c,b)}},add:function(a,b,c){return Ext.Date.add(new Date(a),c,b)},stepUnits:[[Ext.Date.YEAR,1,2,5,10,20,50,100,200,500],[Ext.Date.MONTH,1,3,6],[Ext.Date.DAY,1,7,14],[Ext.Date.HOUR,1,6,12],[Ext.Date.MINUTE,1,5,15,30],[Ext.Date.SECOND,1,5,15,30],[Ext.Date.MILLI,1,2,5,10,20,50,100,200,500]],preferredStep:function(g,h){if(this.getStep()){return this.getStep()}var i=new Date(+g),j=new Date(+g+Math.ceil(h)),c=this.stepUnits,b,f,e,a,d;for(a=0;a0){for(d=1;dg){a.max=a.to}if(a.fromf){a.max=a.to}if(a.from0){a.from=a.from+d*a.step*b;while(a.from0?a:b},applyLabel:function(b,a){if(!a){a=new Ext.draw.sprite.Text({})}if(this.limitTitleTpl){this.limitTitleTpl.setAttributes(b)}a.setAttributes(b);return a},applyLayout:function(a,b){a=Ext.factory(a,null,b,'axisLayout');a.setAxis(this);return a},applySegmenter:function(a,b){a=Ext.factory(a,null,b,'segmenter');a.setAxis(this);return a},updateMinimum:function(){this.range=null},updateMaximum:function(){this.range=null},hideLabels:function(){this.getSprites()[0].setDirty(!0);this.setLabel({hidden:!0})},showLabels:function(){this.getSprites()[0].setDirty(!0);this.setLabel({hidden:!1})},renderFrame:function(){this.getSurface().renderFrame()},updateChart:function(c,b){var a=this,d;if(b){b.unregister(a);b.un('serieschange',a.onSeriesChange,a);b.un('redraw',a.renderLimits,a);a.linkAxis();a.fireEvent('chartdetached',b,a)}if(c){c.on('serieschange',a.onSeriesChange,a);a.surface=null;d=a.getSurface();a.getLabel().setSurface(d);d.add(a.getSprites());d.add(a.getTitle());c.register(a);a.fireEvent('chartattached',c,a)}},applyBackground:function(a){var b=Ext.ClassManager.getByAlias('sprite.rect');return b.def.normalize(a)},processData:function(){this.getLayout().processData();this.range=null},getDirection:function(){return this.getChart().getDirectionForAxis(this.getPosition())},isSide:function(){var a=this.getPosition();return a==='left'||a==='right'},applyFields:function(a){return Ext.Array.from(a)},applyVisibleRange:function(a,b){this.getChart();if(a[0]>a[1]){var c=a[0];a[0]=a[1];a[0]=c}if(a[1]===a[0]){a[1]+=1/this.getMaxZoom()}if(a[1]>a[0]+1){a[0]=0;a[1]=1}else {if(a[0]<0){a[1]-=a[0];a[0]=0}else {if(a[1]>1){a[0]-=a[1]-1;a[1]=1}}}if(b&&a[0]===b[0]&&a[1]===b[1]){return undefined}return a},updateVisibleRange:function(a){this.fireEvent('visiblerangechange',this,a)},onSeriesChange:function(g){var a=this,e=g.getSeries(),h='get'+a.getDirection()+'Axis',f=[],b,i=e.length,d,c;for(b=0;bb){b=g[1]}}}if(!isFinite(b)){b=a.prevMax}if(!isFinite(c)){c=a.prevMin}if(a.getLabelInSpan()||c===b){b+=a.getIncrement();c-=a.getIncrement()}if(Ext.isNumber(a.getMinimum())){c=a.getMinimum()}else {a.prevMin=c}if(Ext.isNumber(a.getMaximum())){b=a.getMaximum()}else {a.prevMax=b}a.range=[Ext.Number.correctFloat(c),Ext.Number.correctFloat(b)];if(a.getReconcileRange()){a.reconcileRange()}if(a.getAdjustByMajorUnit()&&h.adjustByMajorUnit&&!a.getMajorTickSteps()){d=Ext.Object.chain(a.getSprites()[0].attr);d.min=a.range[0];d.max=a.range[1];d.visibleMin=j[0];d.visibleMax=j[1];f={attr:d,segmenter:h};l.calculateLayout(f);e=f.majorTicks;if(e){h.adjustByMajorUnit(e.step,e.unit.scale,a.range);d.min=a.range[0];d.max=a.range[1];delete f.majorTicks;l.calculateLayout(f);e=f.majorTicks;h.adjustByMajorUnit(e.step,e.unit.scale,a.range)}else {if(!a.hasClearRangePending){a.hasClearRangePending=!0;a.getChart().on('layout','clearRange',a)}}}if(!Ext.Array.equals(a.range,a.oldRange||[])){a.fireEvent('rangechange',a,a.range);a.oldRange=a.range}return a.range},clearRange:function(){delete this.hasClearRangePending;this.range=null},reconcileRange:function(){var a=this,e=a.getChart().getAxes(),g=a.getDirection(),d,f,c,b;if(!e){return}for(d=0,f=e.length;da.range[1]){a.range[1]=b[1]}}},applyStyle:function(b,a){var c=Ext.ClassManager.getByAlias('sprite.'+this.seriesType);if(c&&c.def){b=c.def.normalize(b)}a=Ext.apply(a||{},b);return a},themeOnlyIfConfigured:{grid:!0},updateTheme:function(p){var c=this,d=p.getAxis(),n=c.getPosition(),m=c.getInitialConfig(),l=c.defaultConfig,o=c.getConfigurator().configs,k=d.defaults,j=d[n],i=c.themeOnlyIfConfigured,b,a,g,e,f,h;d=Ext.merge({},k,j);for(b in d){a=d[b];h=o[b];if(a!==null&&a!==undefined&&h){f=m[b];g=Ext.isObject(a);e=f===l[b];if(g){if(e&&i[b]){continue}a=Ext.merge({},a,f)}if(e||g){c[h.names.set](a)}}}},updateCenter:function(d){var e=this.getSprites(),c=e[0],a=d[0],b=d[1];if(c){c.setAttributes({centerX:a,centerY:b})}if(this.gridSpriteEven){this.gridSpriteEven.getTemplate().setAttributes({translationX:a,translationY:b,rotationCenterX:a,rotationCenterY:b})}if(this.gridSpriteOdd){this.gridSpriteOdd.getTemplate().setAttributes({translationX:a,translationY:b,rotationCenterX:a,rotationCenterY:b})}},getSprites:function(){if(!this.getChart()){return}var a=this,e=a.getRange(),g=a.getPosition(),i=a.getChart(),d=i.getAnimation(),b,f,h=a.getLength(),c=a.superclass;if(d===!1){d={duration:0}}if(e){f=Ext.applyIf({position:g,axis:a,min:e[0],max:e[1],length:h,grid:a.getGrid(),hidden:a.getHidden(),titleOffset:a.titleOffset,layout:a.getLayout(),segmenter:a.getSegmenter(),totalAngle:a.getTotalAngle(),label:a.getLabel()},a.getStyle());if(!a.sprites.length){while(!c.xtype){c=c.superclass}b=Ext.create('sprite.'+c.xtype,f);b.fx.setCustomDurations({baseRotation:0});b.fx.on('animationstart','onAnimationStart',a);b.fx.on('animationend','onAnimationEnd',a);b.setLayout(a.getLayout());b.setSegmenter(a.getSegmenter());b.setLabel(a.getLabel());a.sprites.push(b);a.updateTitleSprite()}else {b=a.sprites[0];b.setAnimation(d);b.setAttributes(f)}if(a.getRenderer()){b.setRenderer(a.getRenderer())}}return a.sprites},updateTitleSprite:function(){var b=this,g=b.getLength();if(!b.sprites[0]||!Ext.isNumber(g)){return}var f=this.sprites[0].thickness,i=b.getSurface(),a=b.getTitle(),h=b.getPosition(),e=b.getMargin(),c=b.getTitleMargin(),d=i.roundPixel(g/2);if(a){switch(h){case 'top':a.setAttributes({x:d,y:e+c/2,textBaseline:'top',textAlign:'center'},!0);a.applyTransformations();b.titleOffset=a.getBBox().height+c;break;case 'bottom':a.setAttributes({x:d,y:f+c/2,textBaseline:'top',textAlign:'center'},!0);a.applyTransformations();b.titleOffset=a.getBBox().height+c;break;case 'left':a.setAttributes({x:e+c/2,y:d,textBaseline:'top',textAlign:'center',rotationCenterX:e+c/2,rotationCenterY:d,rotationRads:-Math.PI/2},!0);a.applyTransformations();b.titleOffset=a.getBBox().width+c;break;case 'right':a.setAttributes({x:f-e+c/2,y:d,textBaseline:'bottom',textAlign:'center',rotationCenterX:f+c/2,rotationCenterY:d,rotationRads:Math.PI/2},!0);a.applyTransformations();b.titleOffset=a.getBBox().width+c;break;}}},onThicknessChanged:function(){this.getChart().onThicknessChanged()},getThickness:function(){if(this.getHidden()){return 0}return (this.sprites[0]&&this.sprites[0].thickness||1)+this.titleOffset+this.getMargin()},onAnimationStart:function(){this.spriteAnimationCount++;if(this.spriteAnimationCount===1){this.fireEvent('animationstart',this)}},onAnimationEnd:function(){this.spriteAnimationCount--;if(this.spriteAnimationCount===0){this.fireEvent('animationend',this)}},getItemId:function(){return this.getId()},getAncestorIds:function(){return [this.getChart().getId()]},isXType:function(a){return a==='axis'},resolveListenerScope:function(d){var c=this,e=Ext._namedScopes[d],a=c.getChart(),b;if(!e){b=a?a.resolveListenerScope(d,!1):d||c}else {if(e.isThis){b=c}else {if(e.isController){b=a?a.resolveListenerScope(d,!1):c}else {if(e.isSelf){b=a?a.resolveListenerScope(d,!1):c;if(b===a&&!a.getInheritedConfig('defaultListenerScope')){b=c}}}}}return b},destroy:function(){var a=this;a.setChart(null);a.surface.destroy();a.surface=null;a.callParent()}},1,['axis'],['axis'],{'axis':!0},['widget.axis'],[['observable',Ext.mixin.Observable]],[Ext.chart.axis,'Axis'],0);Ext.cmd.derive('Ext.chart.LegendBase',Ext.view.View,{config:{tpl:['
    ','','
    ','','{name}','
    ','
    ','
    '],nodeContainerSelector:'div.x-legend-container',itemSelector:'div.x-legend-item',docked:'bottom'},setDocked:function(b){var a=this,d=a.ownerCt,c;a.docked=b;switch(b){case 'top':case 'bottom':a.addCls('x-horizontal');c='hbox';break;case 'left':case 'right':a.removeCls('x-horizontal');c='vbox';break;}if(d){d.setDocked(b)}},setStore:function(a){this.bindStore(a)},clearViewEl:function(){Ext.view.View.prototype.clearViewEl.apply(this,arguments);Ext.removeNode(this.getNodeContainer())},onItemClick:function(b,c,a,d){Ext.view.View.prototype.onItemClick.apply(this,arguments);this.toggleItem(a)}},0,0,['component','box','dataview'],{'component':!0,'box':!0,'dataview':!0},0,0,[Ext.chart,'LegendBase'],0);Ext.cmd.derive('Ext.chart.Legend',Ext.chart.LegendBase,{config:{baseCls:'x-legend',padding:5,rect:null,disableSelection:!0,toggleable:!0},toggleItem:function(h){if(!this.getToggleable()){return}var b=this.getStore(),f=0,d,g=!0,c,e,a;if(b){e=b.getCount();for(c=0;c1;a=b.getAt(h);if(a){d=a.get('disabled');if(d||g){a.set('disabled',!d)}}}}},0,['legend'],['component','box','dataview','legend'],{'component':!0,'box':!0,'dataview':!0,'legend':!0},['widget.legend'],0,[Ext.chart,'Legend'],0);Ext.cmd.derive('Ext.chart.AbstractChart',Ext.draw.Container,{isChart:!0,defaultBindProperty:'store',config:{store:'ext-empty-store',theme:'default',style:null,animation:!Ext.isIE8,series:[],axes:[],legend:null,colors:null,insetPadding:{top:10,left:10,right:10,bottom:10},background:null,interactions:[],mainRect:null,resizeHandler:null,highlightItem:null},animationSuspendCount:0,chartLayoutSuspendCount:0,axisThicknessSuspendCount:0,isThicknessChanged:!1,surfaceZIndexes:{background:0,main:1,grid:2,series:3,axis:4,chart:5,overlay:6,events:7},constructor:function(b){var a=this;a.itemListeners={};a.surfaceMap={};a.chartComponents={};a.isInitializing=!0;a.suspendChartLayout();a.animationSuspendCount++;Ext.draw.Container.prototype.constructor.apply(this,arguments);delete a.isInitializing;a.getSurface('main');a.getSurface('chart').setFlipRtlText(a.getInherited().rtl);a.getSurface('overlay').waitFor(a.getSurface('series'));a.animationSuspendCount--;a.resumeChartLayout()},applyAnimation:function(a,b){if(!a){a={duration:0}}else {if(a===!0){a={easing:'easeInOut',duration:500}}}return b?Ext.apply({},a,b):a},getAnimation:function(){if(this.animationSuspendCount){return {duration:0}}else {return (arguments.callee.$previous||Ext.draw.Container.prototype.getAnimation).call(this)}},applyInsetPadding:function(a,b){if(!Ext.isObject(a)){return Ext.util.Format.parseBox(a)}else {if(!b){return a}else {return Ext.apply(b,a)}}},suspendAnimation:function(){var b=this,c=b.getSeries(),e=c.length,d=-1,a;b.animationSuspendCount++;if(b.animationSuspendCount===1){while(++d0){this.axisThicknessSuspendCount--;if(this.axisThicknessSuspendCount===0&&this.isThicknessChanged){this.onThicknessChanged()}}},onThicknessChanged:function(){if(this.axisThicknessSuspendCount===0){this.isThicknessChanged=!1;this.performLayout()}else {this.isThicknessChanged=!0}},applySprites:function(a){var b=this.getSurface('chart');a=Ext.Array.from(a);b.removeAll(!0);b.add(a);return a},initItems:function(){var a=this.items,b,d,c;if(a&&!a.isMixedCollection){this.items=[];a=Ext.Array.from(a);for(b=0,d=a.length;b=0){a.splice(c,1)}},applyAxes:function(d,h){var b=this,l={left:'right',right:'left'},f=[],a,j,g,i,c,k,e;b.animationSuspendCount++;b.getStore();if(!h){h=[];h.map={}}e=h.map;f.map={};d=Ext.Array.from(d,!0);for(c=0,k=d.length;c0){a=b.applyColors(a)}return a||c&&c.getColors()},applyColors:function(a){a=Ext.Array.map(a,function(b){if(Ext.isString(b)){return b}else {return b.toString()}});return a},updateColors:function(k){var a=this,i=a.getTheme(),h=k||i&&i.getColors(),g=0,e=a.getSeries(),j=e&&e.length,b,d,f,c;if(h.length){for(b=0;b=0&&e<=a[2]&&f>=0&&f<=a[3])){return null}for(;d>=0;d--){h=g[d];b=h.getItemForPoint(e,f);if(b){return b}}return null},getItemsForPoint:function(h,i){var f=this,c=f.getSeries(),g=c.length,b=f.hasFirstLayout?g-1:-1,e=[],d,a;for(;b>=0;b--){d=c[b];a=d.getItemForPoint(h,i);if(a){e.push(a)}}return e},onAnimationStart:function(){this.fireEvent('animationstart',this)},onAnimationEnd:function(){this.fireEvent('animationend',this)},onDataChanged:function(){var a=this;if(a.isInitializing){return}var e=a.getMainRect(),c=a.getStore(),b=a.getSeries(),d=a.getAxes();if(!c||!d||!b){return}if(!e){a.on({redraw:a.onDataChanged,scope:a,single:!0});return}a.processData();a.redraw()},recordCount:0,processData:function(){var a=this,e=a.getStore().getCount(),f=a.getSeries(),g=f.length,b=!1,d=0,c;for(;da.recordCount){a.updateColors(a.getColors());a.recordCount=e}},bindStore:function(a){this.setStore(a)},applyHighlightItem:function(a,d){if(a===d){return}if(Ext.isObject(a)&&Ext.isObject(d)){var b=a,c=d,e=b.sprite&&(b.sprite[0]||b.sprite),f=c.sprite&&(c.sprite[0]||c.sprite);if(e===f&&b.index===c.index){return}}return a},updateHighlightItem:function(a,b){if(b){b.series.setAttributesForItem(b,{highlighted:!1})}if(a){a.series.setAttributesForItem(a,{highlighted:!0});this.fireEvent('itemhighlight',this,a,b)}this.fireEvent('itemhighlightchange',this,a,b)},destroyChart:function(){var a=this,f=a.getLegend(),h=a.getAxes(),g=a.getSeries(),e=a.getInteractions(),d=[],b,c;a.surfaceMap=null;for(b=0,c=e.length;bf&&bg&&ch){b=h}}if(ci){c=i}}a.selectionRect.setAttributes({width:b-a.startX,height:c-a.startY});if(Math.abs(a.startX-b)<11||Math.abs(a.startY-c)<11){a.selectionRect.setAttributes({globalAlpha:0.5})}else {a.selectionRect.setAttributes({globalAlpha:1})}l.renderFrame();return !1}},onGestureEnd:function(o){var a=this;if(a.zoomAnimationInProgress){return}if(a.getLocks()[a.gestureEvent]===a){var d=a.getChart(),e=a.getSurface(),f=d.getInnerRect(),k=d.getInnerPadding(),i=k.left,l=i+f[2],j=k.top,m=j+f[3],h=f[2],g=f[3],n=d.getEventXY(o),b=n[0],c=n[1];if(bl){b=l}}if(cm){c=m}}if(Math.abs(a.startX-b)<11||Math.abs(a.startY-c)<11){e.remove(a.selectionRect)}else {a.zoomBy([Math.min(a.startX,b)/h,1-Math.max(a.startY,c)/g,Math.max(a.startX,b)/h,1-Math.min(a.startY,c)/g]);a.selectionRect.setAttributes({x:Math.min(a.startX,b),y:Math.min(a.startY,c),width:Math.abs(a.startX-b),height:Math.abs(a.startY-c)});a.selectionRect.setAnimation(d.getAnimation()||{duration:0});a.selectionRect.setAttributes({globalAlpha:0,x:0,y:0,width:h,height:g});a.zoomAnimationInProgress=!0;d.suspendThicknessChanged();a.selectionRect.fx.on('animationend',function(){d.resumeThicknessChanged();e.remove(a.selectionRect);a.selectionRect=null;a.zoomAnimationInProgress=!1})}e.renderFrame();a.sync();a.unlockEvents(a.gestureEvent);a.setSeriesOpacity(1);if(!a.zoomAnimationInProgress){e.remove(a.selectionRect);a.selectionRect=null}}},zoomBy:function(b){var d=this,l=d.getAxes(),j=d.getChart(),k=j.getAxes(),n=j.getInherited().rtl,e,i={},f,g;if(n){b=b.slice();f=1-b[0];g=1-b[2];b[0]=Math.min(f,g);b[2]=Math.max(f,g)}for(var h=0;h=e[b-1]){return b-1}while(a+1>1,f=e[d];if(f===c){return d}else {if(ft&&cv&&dDec: '+a._meta_dec})]);console.log(a);e.addCatalog(b)}},0,['coadd-aladin'],['component','box','container','panel','aladin','coadd-aladin'],{'component':!0,'box':!0,'container':!0,'panel':!0,'aladin':!0,'coadd-aladin':!0},['widget.coadd-aladin'],0,[Explorer.view.coadd,'Aladin'],0);Ext.cmd.derive('Explorer.view.coadd.CoaddController',Ext.app.ViewController,{listen:{component:{'coadd-objects':{loadpanel:'onLoadPanel'},'coadd-visiomatic':{changedataset:'onChangeDataset',changeimage:'onChangeImage'}},store:{'#datasets':{load:'onLoadDatasets'}}},onLoadPanel:function(a,b){this.loadProduct(a)},loadProduct:function(d){var a=this,c=a.getView(),e=a.getViewModel(),b=e.getStore('products');c.setLoading(!0);b.addFilter({property:'prd_name',value:d});b.load({callback:function(){if(this.count()===1){a.onLoadProduct(this.first());c.setLoading(!1)}}})},onLoadProduct:function(b){var a=this,d=a.getViewModel(),e=a.getView(),c=a.lookup('detailPanel');d.set('currentProduct',b);c.setTitle(b.get('prd_display_name'));a.loadAssociations(b)},loadAssociations:function(e){var a=this,c=a.getView(),d=a.getViewModel(),b=d.getStore('associations');c.setLoading(!0);b.addFilter({property:'pca_product',value:e.get('id')});b.load({callback:function(){if(this.count()>0){this.each(function(a){if(a.get('pcc_ucd')==='meta.id;meta.main'){d.set('property_id',a.get('pcn_column_name'))}},a);c.setLoading(!1);a.loadObject()}}})},loadObject:function(){var b=this,a=b.getViewModel(),d=b.getView(),g=a.get('currentProduct'),c=a.getStore('objects'),f=a.get('object_id'),e=a.get('property_id');d.setLoading(!0);c.addFilter([{property:'product',value:g.get('id')},{property:e,value:f}]);c.load({callback:function(){if(this.count()===1){b.onLoadObject(this.first());d.setLoading(!1)}}})},onLoadObject:function(h){var b=this,c=b.getViewModel(),i=b.lookupReference('properties-grid'),d=c.getStore('properties'),g=c.getStore('datasets'),l=b.lookupReference('aladin'),k=b.getView(),a,e;d.removeAll();a=h.data;for(var f in a){var j=f.toLowerCase();if(j.indexOf('_meta_')===-1){d.add([[f.toLowerCase(),a[f]]])}}c.set('object_data',a);i.setStore(d);e=String(a._meta_ra)+','+String(a._meta_dec);g.addFilter([{property:'position',value:e}]);c.set('position',e);b.loadSpectralDistribution();k.setLoading(!1)},onLoadDatasets:function(a){var c=this,d=c.lookupReference('visiomatic'),b=d.lookupReference('cmbCurrentDataset');if(a.count()==1){c.changeImage(a.first());b.select(a.first());b.setReadOnly(!0)}else {if(a.count()>1){c.changeImage(a.first());b.select(a.first());b.setReadOnly(!1)}else {console.log('Nenhuma tile encontrada para o objeto')}}},changeImage:function(b){var d=this,a=d.lookupReference('visiomatic'),c=b.get('image_src_ptif');if(b){if(c!==''){a.setImage(c)}else {a.removeImageLayer()}}else {console.log('dataset nao encontrado')}},onChangeDataset:function(a){var b=this;b.changeImage(a);b.loadSurveys(a.get('release'));b.loadTags(a.get('release'))},onChangeImage:function(){var b=this,e=b.getViewModel(),a=e.get('object_data'),c=b.lookupReference('visiomatic'),d=0.03;c.setView(a._meta_ra,a._meta_dec,d)},loadSurveys:function(c){var b=this,d=b.getViewModel(),a=d.getStore('surveys');a.addFilter([{property:'srv_project',value:'DES'},{property:'srv_release',value:c}]);a.load({callback:function(){b.onLoadSurvey(this)}})},onLoadSurvey:function(e){var b=this,a=b.lookupReference('aladin'),c=b.getViewModel().get('position'),d=b.getViewModel().get('object_data');a.goToPosition(c);a.setFov(180);a.plotObject(d)},onSearch:function(a){var b=this,d=b.getViewModel(),c=d.getStore('properties');if(a!==''){c.filter([{property:'property',value:a}])}else {b.onSearchCancel()}},onSearchCancel:function(){var b=this,c=b.getViewModel(),a=c.getStore('properties');a.clearFilter()},loadTags:function(a){var c=this,d=c.getViewModel(),b=d.getStore('tags');if(a>0){b.addFilter([{property:'tag_release',value:a}]);b.load({callback:function(){c.onLoadTags(this)}})}},onLoadTags:function(a){var b=this;if(a.count()>0){b.loadTiles()}},loadTiles:function(){var e=this,b=e.getViewModel(),d=b.getStore('tags'),c=b.getStore('tiles'),a=[];d.each(function(b){a.push(b.get('id'))},this);c.filter([{property:'tag',operator:'in',value:a}])},onClickSimbad:function(){console.log('onClickSimbad()');var e=this,g=e.getViewModel(),a=g.get('object_data'),f=parseFloat(a._meta_ra).toFixed(4),d=parseFloat(a._meta_dec).toFixed(4),c=0.1,b;b=Ext.String.format('http://simbad.u-strasbg.fr/simbad/sim-coo?Coord={0}+{1}&CooFrame=FK5&CooEpoch=2000&Radius={2}&Radius.unit=arcmin&submit=submit+query',f,d,c);window.open(b,'_blank')},onClickNed:function(){console.log('onClickNed');var e=this,g=e.getViewModel(),a=g.get('object_data'),c=0.1,f=parseFloat(a._meta_ra).toFixed(4),d=parseFloat(a._meta_dec).toFixed(4),b;b=Ext.String.format('https://ned.ipac.caltech.edu/cgi-bin/objsearch?search_type=Near+Position+Search&in_csys=Equatorial&in_equinox=J2000.0&lon={0}d&lat={1}d&radius={2}',f,d,c);window.open(b,'_blank')},onClickVizier:function(){console.log('onClickVizier');var d=this,e=d.getViewModel(),a=e.get('object_data'),c=0.01,b;b=Ext.String.format('http://vizier.u-strasbg.fr/viz-bin/VizieR-5?-source=II/246&-c={0},{1},eq=J2000&-c.rs={2}',a._meta_ra,a._meta_dec,c);window.open(b,'_blank')},loadSpectralDistribution:function(){var k=this,g=k.getViewModel(),e=g.get('object_data'),j=g.getStore('spectral'),f=['mag_auto_g','mag_auto_r','mag_auto_i','mag_auto_z','mag_auto_y'],h=[474,645.5,783.5,926,1008],d,a,b,m,l;for(var i in e){var c=i.toLowerCase();if(f.indexOf(c)!==-1){a=parseFloat(parseFloat(e[c]).toFixed(2));if(parseInt(a)!==99&&parseInt(a)!==0){b=-0.4*a;b=parseFloat(b.toFixed(1))}d=h[f.indexOf(c)];j.add({flux:b,mag_auto:a,wavelength:d,property:c})}}}},0,0,0,0,['controller.coadd'],0,[Explorer.view.coadd,'CoaddController'],0);Ext.cmd.derive('Explorer.view.coadd.CoaddModel',Ext.app.ViewModel,{data:{source:null,object_id:null,object_data:null,property_id:null,position:null},links:{currentProduct:{type:'Explorer.model.Product',create:!0},currentDataset:{type:'common.model.Dataset',create:!0}},stores:{products:{type:'products'},associations:{type:'association'},objects:{type:'objects'},properties:{type:'array',fields:['property','value'],remoteSort:!1,remoteFilter:!1,sorters:[{property:'property',direction:'ASC'}]},datasets:{type:'datasets',storeId:'datasets',remoteSort:!1,sorters:[{property:'id',direction:'DESC'}]},surveys:{type:'surveys'},tags:{type:'tags',storeId:'Tags'},tiles:{type:'footprints',pageSize:0},spectral:{type:'spectral-distribution'}}},0,0,0,0,['viewmodel.coadd'],0,[Explorer.view.coadd,'CoaddModel'],0);Ext.cmd.derive('Explorer.view.coadd.Form',Ext.form.Panel,{initComponent:function(){var a=this;Ext.apply(this,{fieldDefaults:{labelAlign:'top',readOnly:!0},items:[{xtype:'fieldset',defaultType:'textfield',defaults:{anchor:'100%'},items:[{fieldLabel:'Source',bind:{value:'{currentProduct.tablename}'}},{fieldLabel:'Object ID',bind:{value:'{object_data._meta_id}'}},{fieldLabel:'RA, Dec (deg)',bind:{value:'{object_data._meta_ra}, {object_data._meta_dec}'}}]}]});Ext.form.Panel.prototype.initComponent.apply(this,arguments)}},0,['coadd-form'],['component','box','container','panel','form','coadd-form'],{'component':!0,'box':!0,'container':!0,'panel':!0,'form':!0,'coadd-form':!0},['widget.coadd-form'],0,[Explorer.view.coadd,'Form'],0);Ext.cmd.derive('Explorer.view.coadd.Properties',Ext.grid.Panel,{initComponent:function(){var a=this;Ext.apply(this,{columns:[{text:'Property',dataIndex:'property',width:200},{text:'Value',dataIndex:'value',renderer:this.formatNumber,flex:1}],tbar:[{xtype:'common-searchfield',minSearch:1,listeners:{'search':'onSearch','cancel':'onSearchCancel'},flex:1}]});Ext.grid.Panel.prototype.initComponent.apply(this,arguments)},formatNumber:function(a){if(typeof a==='number'){if(!isNaN(a)&&a.toString().indexOf('.')!=-1){a=a.toFixed(4)}}return a}},0,['coadd-properties'],['component','box','container','panel','tablepanel','gridpanel','grid','coadd-properties'],{'component':!0,'box':!0,'container':!0,'panel':!0,'tablepanel':!0,'gridpanel':!0,'grid':!0,'coadd-properties':!0},['widget.coadd-properties'],0,[Explorer.view.coadd,'Properties'],0);Ext.cmd.derive('Explorer.view.coadd.Visiomatic',visiomatic.Visiomatic,{enableTools:!0,enableLink:!1,enableShift:!1,showCrosshair:!0,mapOptions:{fullscreenControl:!0,zoom:1,enableLineaOverlay:!1},initComponent:function(){var a=this;Ext.apply(this,{auxTools:[{xtype:'combobox',reference:'cmbCurrentDataset',publishes:'id',width:250,displayField:'release_tag',bind:{store:'{datasets}',disabled:'{!coadd.COADD_OBJECT_ID}',selection:'{!currentDataset}'},queryMode:'local',listConfig:{itemTpl:['
    {release_display_name} - {tag_display_name}
    ']},listeners:{scope:this,change:'changeDataset'}},{xtype:'textfield',width:120,readOnly:!0,bind:{value:'{currentDataset.tli_tilename}'}},{xtype:'button',iconCls:'x-fa fa-crosshairs',tooltip:'Show/Hide Crosshair',enableToggle:!0,pressed:!0,scope:this,toggleHandler:'onShowHideCrosshair'}]});visiomatic.Visiomatic.prototype.initComponent.apply(this,arguments)},changeDataset:function(a){this.fireEvent('changedataset',a.getSelectedRecord(),this)},onShowHideCrosshair:function(c,a){var b=this;b.setShowCrosshair(a)}},0,['coadd-visiomatic'],['component','box','container','panel','visiomatic','coadd-visiomatic'],{'component':!0,'box':!0,'container':!0,'panel':!0,'visiomatic':!0,'coadd-visiomatic':!0},['widget.coadd-visiomatic'],0,[Explorer.view.coadd,'Visiomatic'],0);Ext.cmd.derive('Explorer.view.coadd.SpectralDistribution',Ext.chart.CartesianChart,{innerPadding:20,insetPadding:{top:40,right:20,bottom:20,left:20},sprites:[{type:'text',text:'Spectral Distribution',fontSize:22,width:100,height:30,x:40,y:20}],axes:[{type:'numeric',fields:['flux'],title:'log(Flux) [counts]',position:'left',grid:!0},{id:'wavelength-axis',type:'category',title:'Wavelength [nm]',fields:'wavelength',position:'bottom',grid:!0}],series:[{type:'scatter',xField:'wavelength',yField:'flux',marker:{type:'circle',fill:'#3333ff',radius:8,lineWidth:0},highlight:{radius:12,lineWidth:2},tooltip:{trackMouse:!0,renderer:function(b,a,c){b.setHtml(a.get('property')+': '+a.get('mag_auto'))}}}]},0,['coadd-spectral-distribution'],['component','box','container','panel','draw','cartesian','chart','coadd-spectral-distribution'],{'component':!0,'box':!0,'container':!0,'panel':!0,'draw':!0,'cartesian':!0,'chart':!0,'coadd-spectral-distribution':!0},['widget.coadd-spectral-distribution'],0,[Explorer.view.coadd,'SpectralDistribution'],0);Ext.cmd.derive('Explorer.view.coadd.Coadd',Ext.panel.Panel,{controller:'coadd',viewModel:'coadd',layout:'fit',initComponent:function(){var a=this;Ext.apply(this,{layout:{type:'hbox',pack:'start',align:'stretch'},defaults:{frame:!0},items:[{xtype:'panel',reference:'detailPanel',width:300,margin:'0 10 0 0',layout:{type:'vbox',pack:'start',align:'stretch'},items:[{xtype:'coadd-form',reference:'properties-form',split:!0,bbar:[{xtype:'button',text:'SIMBAD',handler:'onClickSimbad'},{xtype:'button',text:'NED',handler:'onClickNed'}]},{xtype:'coadd-properties',reference:'properties-grid',split:!0,flex:1}]},{xtype:'panel',flex:1,layout:{type:'vbox',pack:'start',align:'stretch'},margin:'0 0 10 0',defaults:{frame:!0},items:[{xtype:'panel',height:500,layout:{type:'hbox',pack:'start',align:'stretch'},defaults:{frame:!0},items:[{xtype:'coadd-visiomatic',reference:'visiomatic',margin:'0 10 0 0',split:!0,flex:1},{xtype:'coadd-aladin',reference:'aladin',split:!0,flex:1,bind:{storeSurveys:'{surveys}',storeTags:'{tags}',storeTiles:'{tiles}'}}]},{xtype:'panel',flex:1,layout:{type:'hbox',pack:'start',align:'stretch'},items:[{xtype:'coadd-spectral-distribution',reference:'SpectralChart',flex:1,bind:{store:'{spectral}'}},{xtype:'panel',flex:1}]}]}]});Ext.panel.Panel.prototype.initComponent.apply(this,arguments)},loadPanel:function(b){var a=this,e=a.getViewModel(),d=b[1],c=b[2];e.set('source',d);e.set('object_id',c);a.fireEvent('loadpanel',d,c,a)},updatePanel:function(a){}},0,['coadd-objects'],['component','box','container','panel','coadd-objects'],{'component':!0,'box':!0,'container':!0,'panel':!0,'coadd-objects':!0},['widget.coadd-objects'],0,[Explorer.view.coadd,'Coadd'],0);Ext.cmd.derive('Explorer.view.system.SystemController',Ext.app.ViewController,{listen:{component:{'system':{loadpanel:'onLoadPanel'},'system-visiomatic':{changedataset:'onChangeDataset',changeimage:'onChangeImage'}},store:{'#datasets':{load:'onLoadDatasets'}}},onLoadPanel:function(a,b){this.load(a)},load:function(a){var b=this;b.loadProduct(a)},loadProduct:function(d){var a=this,c=a.getView(),e=a.getViewModel(),b=e.getStore('products');c.setLoading(!0);b.addFilter({property:'prd_name',value:d});b.load({callback:function(){if(this.count()===1){a.onLoadProduct(this.first());c.setLoading(!1)}}})},onLoadProduct:function(b){var a=this,d=a.getViewModel(),e=a.getView(),c=a.lookup('detailPanel');d.set('currentProduct',b);c.setTitle(b.get('prd_display_name'));a.loadAssociations(b);a.loadMembersContent(b)},loadAssociations:function(e){var a=this,c=a.getView(),d=a.getViewModel(),b=d.getStore('associations');c.setLoading(!0);b.addFilter({property:'pca_product',value:e.get('id')});b.load({callback:function(){if(this.count()>0){this.each(function(a){if(a.get('pcc_ucd')==='meta.id;meta.main'){d.set('property_id',a.get('pcn_column_name'))}},a);c.setLoading(!1);a.loadObject()}}})},loadObject:function(){var b=this,a=b.getViewModel(),d=b.getView(),g=a.get('currentProduct'),c=a.getStore('objects'),f=a.get('object_id'),e=a.get('property_id');d.setLoading(!0);c.addFilter([{property:'product',value:g.get('id')},{property:e,value:f}]);c.load({callback:function(){if(this.count()===1){b.onLoadObject(this.first());d.setLoading(!1)}}})},onLoadObject:function(g){var c=this,b=c.getViewModel(),i=c.getView(),k=c.lookupReference('properties-grid'),d=b.getStore('properties'),h=b.get('currentProduct'),j=b.getStore('datasets'),m=c.lookupReference('aladin'),a,e;i.setLoading(!0);b.set('object',g);d.removeAll();a=g.data;b.set('object_data',a);for(var f in a){var l=f.toLowerCase();if(l.indexOf('_meta_')===-1){d.add([[f.toLowerCase(),a[f]]])}}k.setStore(d);e=String(a._meta_ra)+','+String(a._meta_dec);j.addFilter([{property:'position',value:e}]);b.set('position',e);i.setLoading(!1);if(h.get('prl_related')>0){c.loadSystemMembers(h,g)}},onLoadDatasets:function(a){var c=this,d=c.lookupReference('visiomatic'),b=d.lookupReference('cmbCurrentDataset');if(a.count()==1){c.changeImage(a.first());b.select(a.first());b.setReadOnly(!0)}else {if(a.count()>1){c.changeImage(a.first());b.select(a.first());b.setReadOnly(!1)}else {console.log('Nenhuma tile encontrada para o objeto')}}},changeImage:function(b){var d=this,a=d.lookupReference('visiomatic'),c=b.get('image_src_ptif');if(b){if(c!==''){a.setImage(c)}else {a.removeImageLayer()}}else {console.log('dataset nao encontrado')}},onChangeDataset:function(a){var b=this;b.changeImage(a);b.loadSurveys(a.get('release'));b.loadTags(a.get('release'))},onChangeImage:function(){var b=this,d=b.getViewModel(),f=d.get('currentProduct'),a=d.get('object'),c=b.lookupReference('visiomatic'),g=b.lookupReference('aladin'),e=d.getStore('members');fov=0.07;c.setView(a.get('_meta_ra'),a.get('_meta_dec'),fov);c.drawRadius(a.get('_meta_ra'),a.get('_meta_dec'),a.get('_meta_radius'),'arcmin');c.showHideRadius(!0);b.onLoadSystemMembers(e)},loadSurveys:function(c){var b=this,d=b.getViewModel(),a=d.getStore('surveys');a.addFilter([{property:'srv_project',value:'DES'},{property:'srv_release',value:c}]);a.load({callback:function(){b.onLoadSurvey(this)}})},onLoadSurvey:function(e){var c=this,a=c.lookupReference('aladin'),d=c.getViewModel().get('position'),b=c.getViewModel().get('object_data');a.goToPosition(d);a.setFov(180);a.drawRadius(b._meta_ra,b._meta_dec,b._meta_radius,'arcmin')},onSearch:function(a){var b=this,d=b.getViewModel(),c=d.getStore('properties');if(a!==''){c.filter([{property:'property',value:a}])}else {b.onSearchCancel()}},onSearchCancel:function(){var b=this,c=b.getViewModel(),a=c.getStore('properties');a.clearFilter()},loadMembersContent:function(d){var b=this,e=b.getViewModel(),a=e.getStore('displayContents'),c=b.lookupReference('members-grid');a.addFilter({'property':'pcn_product_id',value:d.get('prl_related')});a.load({callback:function(){if(this.check_ucds()){c.reconfigureGrid(this)}}})},loadSystemMembers:function(b,d){var c=this,e=c.getViewModel(),a=e.getStore('members');a.addFilter([{property:'product',value:b.get('prl_related')},{property:b.get('prl_cross_property'),value:d.get('id')}]);a.load({callback:function(){c.onLoadSystemMembers(this)}})},onLoadSystemMembers:function(d){var b=this,e=b.getViewModel(),c=b.lookupReference('visiomatic'),f=b.lookupReference('aladin'),a;a=c.overlayCatalog('sytem_members',d);c.showHideLayer(a,!0);e.set('overlayMembers',a);f.plotSystemMembers('system_members',d);e.set('have_members',!0)},onSelectSystemMember:function(b,a){this.highlightSystemMember(a)},highlightSystemMember:function(a,i){var e=this,b=e.getViewModel(),j=b.get('currentProduct'),k=b.get('object'),c=b.get('lMarkPosition'),d=e.lookupReference('visiomatic'),g=e.lookupReference('aladin'),h=d.getFov(),l=e.lookup('members-grid'),f;d.setView(a.get('_meta_ra'),a.get('_meta_dec'),h,!0);if(c){d.showHideLayer(c,!1)}c=d.markPosition(a.get('_meta_ra'),a.get('_meta_dec'),'x-fa fa-sort-desc fa-2x');b.set('lMarkPosition',c);f=String(a.get('_meta_ra'))+','+String(a.get('_meta_dec'));g.goToPosition(f);b.set('selected_member',a)},loadTags:function(a){var c=this,d=c.getViewModel(),b=d.getStore('tags');if(a>0){b.addFilter([{property:'tag_release',value:a}]);b.load({callback:function(){c.onLoadTags(this)}})}},onLoadTags:function(a){var b=this;if(a.count()>0){b.loadTiles()}},loadTiles:function(){var e=this,b=e.getViewModel(),d=b.getStore('tags'),c=b.getStore('tiles'),a=[];d.each(function(b){a.push(b.get('id'))},this);c.filter([{property:'tag',operator:'in',value:a}])},parseRA:function(a){if(a<0){return a+360}return a},onClickSimbad:function(){var c=this,g=c.getViewModel(),a=g.get('object_data'),f=parseFloat(c.parseRA(a._meta_ra)).toFixed(4),e=parseFloat(a._meta_dec).toFixed(4),d=2,b;b=Ext.String.format('http://simbad.u-strasbg.fr/simbad/sim-coo?Coord={0}+{1}&CooFrame=FK5&CooEpoch=2000&Radius={2}&Radius.unit=arcmin&submit=submit+query',f,e,d);window.open(b,'_blank')},onClickNed:function(){var c=this,g=c.getViewModel(),a=g.get('object_data'),f=parseFloat(c.parseRA(a._meta_ra)).toFixed(2),e=parseFloat(a._meta_dec).toFixed(2),d=2,b;b=Ext.String.format('https://ned.ipac.caltech.edu/cgi-bin/objsearch?search_type=Near+Position+Search&in_csys=Equatorial&in_equinox=J2000.0&lon={0}d&lat={1}d&radius={2}',f,e,d);window.open(b,'_blank')},onClickVizier:function(){var c=this,e=c.getViewModel(),a=e.get('object_data'),d=2,b;b=Ext.String.format('http://vizier.u-strasbg.fr/viz-bin/VizieR-5?-source=II/246&-c={0},{1},eq=J2000&-c.rs={2}',c.parseRA(a._meta_ra),a._meta_dec,d);window.open(b,'_blank')},onCmdClickPoint:function(a,b){this.highlightSystemMember(a,!0)}},0,0,0,0,['controller.system'],0,[Explorer.view.system,'SystemController'],0);Ext.cmd.derive('Explorer.view.system.SystemModel',Ext.app.ViewModel,{data:{source:null,object_id:null,object:null,object_data:null,property_id:null,overlayMembers:null,position:null,have_members:!1,selected_member:null},links:{currentProduct:{type:'Explorer.model.Product',create:!0},currentDataset:{type:'common.model.Dataset',create:!0}},stores:{products:{type:'products'},associations:{type:'association'},objects:{type:'objects'},members:{type:'objects'},displayContents:{type:'product-display-contents'},properties:{type:'array',fields:['property','value'],remoteSort:!1,remoteFilter:!1,sorters:[{property:'property',direction:'ASC'}]},datasets:{type:'datasets',storeId:'datasets',remoteSort:!1,sorters:[{property:'id',direction:'DESC'}]},surveys:{type:'surveys'},tags:{type:'tags',storeId:'Tags'},tiles:{type:'footprints',pageSize:0}}},0,0,0,0,['viewmodel.system'],0,[Explorer.view.system,'SystemModel'],0);Ext.cmd.derive('Explorer.view.system.Form',Ext.form.Panel,{initComponent:function(){var a=this;Ext.apply(this,{fieldDefaults:{labelAlign:'top',readOnly:!0},items:[{xtype:'fieldset',defaultType:'textfield',defaults:{anchor:'100%'},items:[{fieldLabel:'Source',bind:{value:'{currentProduct.tablename}'}},{fieldLabel:'Object ID',bind:{value:'{object_data._meta_id}'}},{fieldLabel:'RA, Dec (deg)',bind:{value:'{object_data._meta_ra}, {object_data._meta_dec}'}},{fieldLabel:'Radius (arcmin)',bind:{value:'{object_data._meta_radius}'}}]}]});Ext.form.Panel.prototype.initComponent.apply(this,arguments)}},0,['system-form'],['component','box','container','panel','form','system-form'],{'component':!0,'box':!0,'container':!0,'panel':!0,'form':!0,'system-form':!0},['widget.system-form'],0,[Explorer.view.system,'Form'],0);Ext.cmd.derive('Explorer.view.system.Properties',Ext.grid.Panel,{initComponent:function(){var a=this;Ext.apply(this,{columns:[{text:'Property',dataIndex:'property',flex:1},{text:'Value',dataIndex:'value',renderer:this.formatNumber,flex:1}],tbar:[{xtype:'common-searchfield',minSearch:1,listeners:{'search':'onSearch','cancel':'onSearchCancel'},flex:1}]});Ext.grid.Panel.prototype.initComponent.apply(this,arguments)},formatNumber:function(a){if(typeof a==='number'){if(!isNaN(a)&&a.toString().indexOf('.')!=-1){a=a.toFixed(4)}}return a}},0,['system-properties'],['component','box','container','panel','tablepanel','gridpanel','grid','system-properties'],{'component':!0,'box':!0,'container':!0,'panel':!0,'tablepanel':!0,'gridpanel':!0,'grid':!0,'system-properties':!0},['widget.system-properties'],0,[Explorer.view.system,'Properties'],0);Ext.cmd.derive('Explorer.view.system.Visiomatic',visiomatic.Visiomatic,{enableTools:!0,enableLink:!1,enableShift:!1,showCrosshair:!0,mapOptions:{fullscreenControl:!0,zoom:1,enableLineaOverlay:!1},initComponent:function(){var a=this;Ext.apply(this,{auxTools:[{xtype:'combobox',reference:'cmbCurrentDataset',publishes:'id',width:250,displayField:'release_tag',bind:{store:'{datasets}',disabled:'{!coadd.COADD_OBJECT_ID}',selection:'{!currentDataset}'},queryMode:'local',listConfig:{itemTpl:['
    {release_display_name} - {tag_display_name}
    ']},listeners:{scope:this,change:'changeDataset'}},{xtype:'textfield',width:120,readOnly:!0,bind:{value:'{currentDataset.tli_tilename}'}},{xtype:'button',iconCls:'x-fa fa-crosshairs',tooltip:'Show/Hide Crosshair',enableToggle:!0,pressed:!0,scope:this,toggleHandler:'onShowHideCrosshair'}]});visiomatic.Visiomatic.prototype.initComponent.apply(this,arguments)},changeDataset:function(a){this.fireEvent('changedataset',a.getSelectedRecord(),this)},onShowHideCrosshair:function(c,a){var b=this;b.setShowCrosshair(a)}},0,['system-visiomatic'],['component','box','container','panel','visiomatic','system-visiomatic'],{'component':!0,'box':!0,'container':!0,'panel':!0,'visiomatic':!0,'system-visiomatic':!0},['widget.system-visiomatic'],0,[Explorer.view.system,'Visiomatic'],0);Ext.cmd.derive('Explorer.view.system.Aladin',aladin.Aladin,{initComponent:function(){var a=this;Ext.apply(this,{hideFootprint:!1,enableGoto:!1,enableShift:!1,infoEnabled:!1,enableLayersControl:!1,toolbarPosition:'top',showFilters:!1});aladin.Aladin.prototype.initComponent.apply(this,arguments)},plotObject:function(a,e){var d=this,f=d.getAladin(),c=d.libA,b;b=c.catalog({name:e,sourceSize:12,color:'#A0F65A'});b.addSources([c.marker(a._meta_ra,a._meta_dec,{popupTitle:'ID: '+a._meta_id,popupDesc:'RA: '+a._meta_ra+'
    Dec: '+a._meta_dec})]);f.addCatalog(b)},plotSystemMembers:function(e,f){var b=this,g=b.getAladin(),d=b.libA,c=[],a;a=d.catalog({name:e,sourceSize:12,color:'#A0F65A'});f.each(function(a){var b=d.marker(a.get('_meta_ra'),a.get('_meta_dec'),{popupTitle:'ID: '+a.get('_meta_id'),popupDesc:'J2000: '+a.get('_meta_ra')+', '+a.get('_meta_dec')});c.push(b)},b);a.addSources(c);g.addCatalog(a)},drawRadius:function(a,d,c,h,i){var f=this,g=f.getAladin(),e=f.libA,b;a=parseFloat(a);d=parseFloat(d);if(a<0){a=a+360}b=e.graphicOverlay({color:'#ee2345',lineWidth:3});g.addOverlay(b);if(h==='arcmin'){c=c/60}b.add(e.circle(a,d,c))}},0,['system-aladin'],['component','box','container','panel','aladin','system-aladin'],{'component':!0,'box':!0,'container':!0,'panel':!0,'aladin':!0,'system-aladin':!0},['widget.system-aladin'],0,[Explorer.view.system,'Aladin'],0);Ext.cmd.derive('Explorer.view.system.MembersGrid',Ext.grid.Panel,{config:{ready:!1,columnRating:!1,columnAccept:!1,columnComments:!1},emptyText:'No data to dysplay.',initComponent:function(){var a=this;Ext.apply(this,{enableLocking:!0,syncRowHeight:!0,columns:[Ext.create('Ext.grid.RowNumberer'),{text:'',dataIndex:'',width:50},{text:'',dataIndex:'',flex:!0}],viewConfig:{stripeRows:!0,markDirty:!1,getRowClass:function(a){return a.get('_meta_reject')===!0?'rejected-row':''}}});Ext.grid.Panel.prototype.initComponent.apply(this,arguments)},reconfigureGrid:function(d){var a=this,b=[],c;b.push(Ext.create('Ext.grid.RowNumberer',{width:50,resizable:!0,locked:!0}));if(d.count()>0){c=!1;d.each(function(f){if(f.get('is_visible')){var e={text:a.createColumnText(f),dataIndex:f.get('column_name').toLowerCase(),tooltip:a.createColumnTooltip(f),renderer:a.formatNumber,lockable:!0};if(f.get('ucd')=='meta.id;meta.main'){e.locked=!0;e.lockable=!0;e.renderer=null;c=!0}if(f.get('column_name').toLowerCase()=='tilename'){e.width=120}if(f.get('ucd')==='pos.eq.ra;meta.main'||f.get('ucd')==='pos.eq.dec;meta.main'){e.width=90;e.xtype='numbercolumn';e.format='0.000';e.renderer=null;e.locked=!0;e.lockable=!0}if(f.get('ucd')==='phys.angSize;src'){e.width=80;e.xtype='numbercolumn';e.format='0.000';e.renderer=null;e.lockable=!0}b.push(e)}},this);if(a.getColumnRating()&&c===!0){b.push({xtype:'widgetcolumn',width:90,sortable:!0,text:'Rating',dataIndex:'_meta_rating',tooltip:'Rating',widget:{xtype:'rating',minimum:0,scale:'115%',selectedStyle:'color: rgb(96, 169, 23);',style:{'color':'#777777'}}})}if(a.getColumnAccept()&&c===!0){b.push({xtype:'checkcolumn',text:'Reject',dataIndex:'_meta_reject',tooltip:'Reject',sortable:!0,width:80})}if(a.getColumnComments()&&c===!0){b.push({text:'Comments',dataIndex:'_meta_comments',tooltip:'Comments',align:'center',flex:1,sortable:!1,minWidth:80,renderer:function(b,c,e){var a='';if(b>0){if(b==1){a=' '}else {a=''}}return a}})}}else {b.push({text:'Placeholder',dataIndex:'',hidden:!0})}a.reconfigure(null,b);a.setReady(!0);this.fireEvent('ready',this)},getTypeColumn:function(a){switch(a){case 'integer':case 'real':case 'double precision':case 'bigint':case 'smallint':return 'number';break;case 'text':return 'string';break;}},createColumnText:function(a){var c=a.get('unit'),b=a.get('display_name');var d=c!=''?Ext.String.format('{0} ( {1} )',b,c):b;return d},createColumnTooltip:function(a){var b=new Ext.XTemplate('
    ','

    {display_name}

    ','','

    Name: {column_name}

    ','
    ','','

    Unit: {unit}

    ','
    ','','

    ucd: {ucd}

    ','
    ','','

    Reference: {reference}

    ','
    ','
    ');return b.apply(a.data)},formatNumber:function(a){var b=3,d,c;if(typeof a==='number'){if(a>10000){a=a.toExponential(1)}else {if(a.toString().indexOf('.')!=-1){d=a.toString().split('.');c=d[1];if(c.length>b){a=a.toFixed(b)}}}}return a}},0,['system-members-grid'],['component','box','container','panel','tablepanel','gridpanel','grid','system-members-grid'],{'component':!0,'box':!0,'container':!0,'panel':!0,'tablepanel':!0,'gridpanel':!0,'grid':!0,'system-members-grid':!0},['widget.system-members-grid'],0,[Explorer.view.system,'MembersGrid'],0);Ext.cmd.derive('Explorer.view.system.D3SvgComponent',Ext.Component,{title:'D3 Js',config:{baseCls:'x-d3',svgMargin:{top:50,left:50,right:50,bottom:50},legend:{width:0,height:0,y:20,iconSize:20},store:null,xAxisTitle:null,yAxisTitle:null,plotTitle:null,ready:!1},d3:null,resizeDelay:250,resizeTimerId:0,size:null,defs:null,wrapper:null,wrapperClipRect:null,wrapperClipId:'wrapper-clip',svg:null,defaultCls:{wrapper:'x-d3-wrapper',scene:'x-d3-scene',hidden:'x-d3-hidden'},proportionalSize:!0,scene:null,sceneRect:null,initComponent:function(){var a=this;Ext.Component.prototype.initComponent.apply(this,arguments);if(window.d3){a.d3=window.d3;a.on('resize','onElementResize',a)}else {console.log('window.d3 ainda nao esta carregada, incluir no app.json a biblioteca D3JS')}},onElementResize:function(a,b){this.handleResize(this.getSize())},handleResize:function(b,d){var a=this,c=a.getEl();if(!(c&&(b=b||c.getSize())&&b.width&&b.height)){return}clearTimeout(a.resizeTimerId);if(d){a.resizeTimerId=0}else {a.resizeTimerId=Ext.defer(a.handleResize,a.resizeDelay,a,[b,!0]);return}a.resizeHandler(b);a.size=b},resizeHandler:function(f){var a=this,l=a.getSvg(),c=a.getSvgMargin(),k=a.getInherited().rtl,j=a.getWrapper(),i=a.getWrapperClipRect(),h=a.getScene(),e=f&&f.width,d=f&&f.height,g=a.getLegend(),b;if(!(e&&d)){return}a.clearScene();if(a.proportionalSize){e=d+g.width}l.attr('width',e).attr('height',d);b=a.sceneRect||(a.sceneRect={});b.x=k?c.right:c.left;b.y=c.top;b.width=e-c.left-c.right-g.width;b.height=d-c.top-c.bottom;j.attr('transform','translate('+b.x+','+b.y+')');i.attr('width',b.width).attr('height',b.height);a.sceneRect=b;a.onSceneResize(h,b);a.fireEvent('sceneresize',a,h,b)},getSvg:function(){var a=this,b=a.getEl();return a.svg||(a.svg=a.d3.select(b.dom).append('svg').attr('version','1.1'))},getWrapper:function(){var a=this,b=a.wrapper;if(!b){b=a.wrapper=a.getSvg().append('g').classed(a.defaultCls.wrapper,!0)}return b},getWrapperClipRect:function(){var a=this,b=a.wrapperClipRect;if(!b){b=a.wrapperClipRect=a.getDefs().append('clipPath').attr('id',a.wrapperClipId).append('rect').attr('fill','white')}return b},getDefs:function(){var a=this.defs;if(!a){a=this.defs=this.getSvg().append('defs')}return a},getScene:function(){var a=this,c=a.getWrapper(),b=a.scene;if(!b){a.scene=b=c.append('g').classed(a.defaultCls.scene,!0);a.setupScene(b);a.fireEvent('scenesetup',a,b)}return b},setupScene:Ext.emptyFn,destroy:function(){this.getSvg().remove();Ext.Component.prototype.destroy.call(this)},clearScene:function(){var c=this,a=c.scene,b=c.defs;if(a){a=a.node();a.removeAttribute('transform');while(a.firstChild){a.removeChild(a.firstChild)}}if(b){b=b.node();while(b.firstChild){b.removeChild(b.firstChild)}}},onSceneResize:function(b,c){var a=this;a.setReady(!0);a.performLayout(b,c)},performLayout:Ext.emptyFn,showScene:function(){this.scene&&this.scene.classed(this.defaultCls.hidden,!1)},hideScene:function(){this.scene&&this.scene.classed(this.defaultCls.hidden,!0)},applyPadding:function(a,c){var b;if(!Ext.isObject(a)){b=Ext.util.Format.parseBox(a)}else {if(!c){b=a}else {b=Ext.apply(c,a)}}return b},setStore:function(a){this.store=a},setPlotTitle:function(b){var a=this;a.plotTitle=b;if(a.getReady()){a.createPlotTitle()}},setXAxisTitle:function(b){var a=this;a.xAxisTitle=b;if(a.getReady()){a.createAxisTitles()}},setYAxisTitle:function(b){var a=this;a.yAxisTitle=b;if(a.getReady()){a.createAxisTitles()}},createAxisTitles:function(){var a=this,f=a.getScene(),e=a.getSvgMargin(),b=a.sceneRect,c=a.getXAxisTitle(),d=a.getYAxisTitle(),g='xAxisTitle-'+a.getId(),h='yAxisTitle-'+a.getId();a.d3.select('#'+g).remove();a.d3.select('#'+h).remove();if(c){f.append('text').attr('id',g).attr('transform','translate('+b.width/2+' ,'+(b.height+e.bottom/2)+')').attr('dy','1em').style('text-anchor','middle').text(c)}if(d){f.append('text').attr('id',h).attr('transform','rotate(-90)').attr('y',0-e.left).attr('x',0-b.height/2).attr('dy','1em').style('text-anchor','middle').text(d)}},createPlotTitle:function(){var a=this,e=a.getScene(),d=a.getSvgMargin(),f=a.sceneRect,b=a.getPlotTitle(),c='plotTitle-'+a.getId();title=a.d3.select('#'+c);if(title){title.remove()}if(b){e.append('text').attr('id',c).attr('x',f.width/2).attr('y',0-d.top/2).attr('text-anchor','middle').style('font-size','1.2em').text(b)}}},0,0,['component','box'],{'component':!0,'box':!0},0,0,[Explorer.view.system,'D3SvgComponent'],0);Ext.cmd.derive('Explorer.view.system.SpatialDistribution',Explorer.view.system.D3SvgComponent,{},0,['system-spatial-distribution'],['component','box','system-spatial-distribution'],{'component':!0,'box':!0,'system-spatial-distribution':!0},['widget.system-spatial-distribution'],0,[Explorer.view.system,'SpatialDistribution'],0);Ext.cmd.derive('Explorer.view.system.ZDistribution',Explorer.view.system.D3SvgComponent,{plotTitle:'z Distribution',xAxisTitle:'Redshift',yAxisTitle:'N',proportionalSize:!1,performLayout:function(b,e){console.log('performLayout(%o, %o)',b,e);var a=this,i=e.width,f=e.height,d=a.processData(a.getStore()),k=a.getSvgMargin();var c=d3.scaleLinear().domain([d3.min(d),d3.max(d)]).range([0,i]);var g=d3.histogram().domain(c.domain()).thresholds(c.ticks(15))(d);var h=d3.scaleLinear().domain([0,d3.max(g,function(a){return a.length})]).range([f,0]);var j=d3.line().x(function(a,d){return c(a.x0)}).y(function(a,c){return h(a.length)}).curve(d3.curveStepAfter);b.append('g').attr('class','axis axis--x').attr('transform','translate(0,'+f+')').call(d3.axisBottom(c));b.append('g').attr('class','axis axis--y').call(d3.axisLeft(h).ticks(5).tickFormat(d3.format('d')));b.append('path').attr('class','line').attr('d',j(g)).attr('fill','none').attr('stroke','steelblue').attr('stroke-width','2px');a.createAxisTitles();a.createPlotTitle()},processData:function(b){var c=this,a=[];b.each(function(c){a.push(c.get('zp'))});return a}},0,['system-z-distribution'],['component','box','system-z-distribution'],{'component':!0,'box':!0,'system-z-distribution':!0},['widget.system-z-distribution'],0,[Explorer.view.system,'ZDistribution'],0);Ext.cmd.derive('Explorer.view.system.MagDistribution',Explorer.view.system.ZDistribution,{plotTitle:'Mag Distribution',xAxisTitle:'Mag',yAxisTitle:'N',processData:function(b){var c=this,a=[];b.each(function(c){a.push(c.get('mag'))});return a}},0,['system-mag-distribution'],['component','box','system-z-distribution','system-mag-distribution'],{'component':!0,'box':!0,'system-z-distribution':!0,'system-mag-distribution':!0},['widget.system-mag-distribution'],0,[Explorer.view.system,'MagDistribution'],0);Ext.cmd.derive('Explorer.view.system.Cmd',Explorer.view.system.D3SvgComponent,{config:{dataSeries:{gr:{id:'g-r',title:'(g-r) vs. r',xAxisTitle:'r',yAxisTitle:'g-r',values:[]},ri:{id:'r-i',title:'(r-i) vs. i',xAxisTitle:'i',yAxisTitle:'r-i',values:[]},iz:{id:'i-z',title:'(i-z) vs. z',xAxisTitle:'z',yAxisTitle:'i-z',values:[]},zy:{id:'z-y',title:'(z-y) vs. Y',xAxisTitle:'Y',yAxisTitle:'z-Y',values:[]}},plotData:[],svgMargin:{top:50,left:50,right:100,bottom:50},legend:{width:0,height:0,y:20,iconSize:20,iconPadding:5},colorScale:null},idleTimeout:null,idleDelay:350,proportionalSize:!1,performLayout:function(d,f){var a=this,h=f.width,e=f.height,i=a.getDataSeries(),b=a.loadData(a.getStore(),i),c=0.2;var g=d3.scaleOrdinal(d3['schemeCategory10']);a.setColorScale(g);a.x=d3.scaleLinear().range([0,h]).domain([d3.min(b,function(a){return d3.min(a.values,function(b){return b.x-c})}),d3.max(b,function(a){return d3.max(a.values,function(b){return b.x+c})})]);a.xAxis=d3.axisBottom(a.x);a.y=d3.scaleLinear().range([e,0]).domain([d3.min(b,function(a){return d3.min(a.values,function(b){return b.y-c})}),d3.max(b,function(a){return d3.max(a.values,function(b){return b.y+c})})]);a.yAxis=d3.axisLeft(a.y);a.brush=d3.brush().extent([[0,0],[h,e]]).on('end',function(){a.onBrushendend()});a.gx=d.append('g').attr('class','axis axis--x').attr('id','axis--x').attr('transform','translate(0,'+e+')').call(a.xAxis);a.gy=d.append('g').attr('class','axis axis--y').attr('id','axis--y').call(a.yAxis);a.scene.append('g').attr('class','brush').call(a.brush);a.scatter=d.append('g').attr('id','scatterplot');a.scatter.selectAll('.series').data(b).enter().append('g').attr('class','series').attr('id',function(a){return 'serie-'+a.id}).attr('active',!1).style('fill',function(b,a){return g(a)}).style('opacity',1).style('display','none').selectAll('.dot').data(function(a){return a.values}).enter().append('circle').attr('class','dot').attr('r',3.5).attr('cx',function(b){return a.x(b.x)}).attr('cy',function(b){return a.y(b.y)}).on('mouseover',function(b){a.onMouseOverPoint(b,this)}).on('mouseout',function(b){a.onMouseOutPoint(b,this)}).on('click',function(b){a.onClickPoint(b,this)});a.createAxisTitles();a.createPlotTitle();a.createLegendBox(d,f,b);a.deactiveAllSeries();a.activeSerie(b[0])},loadData:function(c,a){var d=this,b=[];c.each(function(b){var h=parseFloat(b.get('mag_g')),e=parseFloat(b.get('mag_r')),d=parseFloat(b.get('mag_i')),f=parseFloat(b.get('mag_r')),g=parseFloat(b.get('mag_y'));a.gr.values.push({'id':b.get('_meta_id'),'x':e,'y':h-e,'serie':'g-r'});a.ri.values.push({'id':b.get('_meta_id'),'x':d,'y':e-d,'serie':'r-i'});a.iz.values.push({'id':b.get('_meta_id'),'x':f,'y':d-f,'serie':'i-z'});a.zy.values.push({'id':b.get('_meta_id'),'x':g,'y':f-g,'serie':'z-y'})});b.push(a.gr);b.push(a.ri);b.push(a.iz);b.push(a.zy);d.setPlotData(b);return b},createLegendBox:function(d,f,e){var b=this,a=b.getLegend(),c=b.getColorScale();var h=d.selectAll('.legend').data(e).enter().append('g').attr('class','legend').attr('id',function(a){return 'legendItem-'+a.id}).attr('transform',function(g,c){var b=a.iconSize+a.iconPadding;return 'translate('+f.width+','+c*b+')'}).on('click',function(a){b.changeSerie(a)}).each(function(b,h){g=d3.select(this);g.append('rect').attr('width',a.iconSize).attr('height',a.iconSize).style('fill',c(h));g.append('text').attr('x',a.iconSize+5).attr('y',10).attr('dy','.35em').text(b.title)})},showHideSerie:function(c,d){var a=d3.select('#legendItem-'+c.id),b=d3.select('#serie-'+c.id);if(d){b.attr('active',!0).transition().duration(1000).style('opacity',1).style('display','block');a.transition().duration(1000).style('opacity',1)}else {b.attr('active',!1).transition().duration(1000).style('opacity',0).style('display','none');a.transition().duration(1000).style('opacity',0.3)}},changeSerie:function(a){var b=this,d=d3.select('#serie-'+a.id),c=d.attr('active')==='true'?!0:!1;if(c){b.deactiveSerie(a)}else {b.deactiveAllSeries();b.activeSerie(a)}},activeSerie:function(a){var b=this;b.showHideSerie(a,!0);b.setPlotTitle(a.title);b.setXAxisTitle(a.xAxisTitle);b.setYAxisTitle(a.yAxisTitle)},deactiveAllSeries:function(){var a=this,b=a.getPlotData();Ext.each(b,function(b){a.deactiveSerie(b)})},deactiveSerie:function(a){var b=this;b.showHideSerie(a,!1)},onMouseOverPoint:function(d,c){var e=this,a=d3.select(c),b=d3.select('#serie-'+d.serie);b.transition().duration(300).attr('fill-opacity',0.2);a.attr('r',6).attr('fill-opacity',1).style('cursor','pointer')},onMouseOutPoint:function(d,c){var e=this,a=d3.select(c),b=d3.select('#serie-'+d.serie);b.transition().duration(300).attr('fill-opacity',null);a.attr('r',3.5).attr('fill-opacity',null).style('cursor','default')},onClickPoint:function(d,e){var a=this,c=a.getStore(),b;b=c.findRecord('_meta_id',d.id);a.fireEvent('clickpoint',b,a)},onBrushendend:function(){var a=this,d=a.getScene(),b=a.plotData,c=0.2;a.s=d3.event.selection;if(!a.s){if(!a.idleTimeout){return a.idleTimeout=setTimeout(function(){a.idleTimeout=null},a.idleDelay)}a.y.domain(d3.extent(b,function(a){return a.y})).nice();a.x.domain([d3.min(b,function(a){return d3.min(a.values,function(b){return b.x-c})}),d3.max(b,function(a){return d3.max(a.values,function(b){return b.x+c})})]);a.y.domain([d3.min(b,function(a){return d3.min(a.values,function(b){return b.y-c})}),d3.max(b,function(a){return d3.max(a.values,function(b){return b.y+c})})])}else {a.x.domain([a.s[0][0],a.s[1][0]].map(a.x.invert,a.x));a.y.domain([a.s[1][1],a.s[0][1]].map(a.y.invert,a.y));d.select('.brush').call(a.brush.move,null)}a.zoom()},zoom:function(){var a=this,c=a.getScene(),b;b=a.scatter.transition().duration(750);d3.select('#axis--x').transition(b).call(a.xAxis);d3.select('#axis--y').transition(b).call(a.yAxis);a.scatter.selectAll('circle').transition(b).attr('cx',function(b){return a.x(b.x)}).attr('cy',function(b){return a.y(b.y)})}},0,['system-cmd'],['component','box','system-cmd'],{'component':!0,'box':!0,'system-cmd':!0},['widget.system-cmd'],0,[Explorer.view.system,'Cmd'],0);Ext.cmd.derive('Explorer.view.system.System',Ext.panel.Panel,{controller:'system',viewModel:'system',layout:'fit',initComponent:function(){var a=this;Ext.apply(this,{layout:'border',defaults:{frame:!0},items:[{xtype:'panel',region:'west',width:300,margin:'0 10 0 0',collapsible:!0,reference:'detailPanel',layout:{type:'vbox',pack:'start',align:'stretch'},items:[{xtype:'system-form',reference:'properties-form',split:!0,bbar:[{xtype:'button',text:'SIMBAD',handler:'onClickSimbad'},{xtype:'button',text:'NED',handler:'onClickNed'}]},{xtype:'system-properties',reference:'properties-grid',split:!0,flex:1}]},{xtype:'panel',region:'center',flex:1,split:!0,layout:{type:'vbox',pack:'start',align:'stretch'},margin:'0 0 10 0',defaults:{frame:!0},items:[{xtype:'panel',flex:1,split:!0,layout:{type:'hbox',pack:'start',align:'stretch'},defaults:{frame:!0},items:[{xtype:'system-visiomatic',reference:'visiomatic',margin:'0 10 0 0',split:!0,flex:1},{xtype:'system-aladin',reference:'aladin',split:!0,flex:1,bind:{storeSurveys:'{surveys}',storeTags:'{tags}',storeTiles:'{tiles}'}}]},{xtype:'tabpanel',flex:1,split:!0,items:[{xtype:'system-members-grid',title:'System Members',reference:'members-grid',bind:{store:'{members}',selection:'{selected_member}'},listeners:{select:'onSelectSystemMember'}},{xtype:'panel',title:'z and Mag Distribution',layout:{type:'hbox',pack:'start',align:'stretch'},bind:{disabled:'{!have_members}'},items:[{xtype:'system-z-distribution',flex:1,bind:{store:'{members}'}},{xtype:'system-mag-distribution',flex:1,bind:{store:'{members}'}}]},{xtype:'system-spatial-distribution',title:'Spatial Distribution',disabled:!0},{xtype:'system-cmd',title:'CMD',bind:{store:'{members}',disabled:'{!have_members}'},listeners:{clickpoint:'onCmdClickPoint'}}]}]}]});Ext.panel.Panel.prototype.initComponent.apply(this,arguments)},loadPanel:function(b){var a=this,e=a.getViewModel(),d=b[1],c=b[2];e.set('source',d);e.set('object_id',c);a.fireEvent('loadpanel',d,c,a)},updatePanel:function(a){}},0,['system'],['component','box','container','panel','system'],{'component':!0,'box':!0,'container':!0,'panel':!0,'system':!0},['widget.system'],0,[Explorer.view.system,'System'],0);Ext.cmd.derive('Explorer.view.main.MainController',Ext.app.ViewController,{routes:{'coadd/:source/:object':{action:'onCoadd'},'system/:source/:object':{action:'onSystem'}},setActivePanel:function(e){var h=this,g=h.getReferences(),b=g.mainCardPanel,d=b.getLayout(),f=e.routeId,c=b.child('component[routeId='+f+']'),a=null;if(!c){a=b.add(e);a.loadPanel(arguments);d.setActiveItem(a)}else {a=c;a.updatePanel(arguments);d.setActiveItem(a)}},onCoadd:function(c,a){var b=Ext.create('Explorer.view.coadd.Coadd',{hideMode:'offsets',routeId:'coadd',layout:'fit'});this.setActivePanel(b,c,a)},onSystem:function(c,a){var b=Ext.create('Explorer.view.system.System',{hideMode:'offsets',routeId:'sytem',layout:'fit'});this.setActivePanel(b,c,a)}},0,0,0,0,['controller.main'],0,[Explorer.view.main,'MainController'],0);Ext.cmd.derive('Explorer.view.main.MainModel',Ext.app.ViewModel,{data:{name:'Explorer',internal_name:'explorer',loremIpsum:'Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum.'}},0,0,0,0,['viewmodel.main'],0,[Explorer.view.main,'MainModel'],0);Ext.cmd.derive('Explorer.view.main.Main',Ext.container.Container,{controller:'main',viewModel:'main',layout:{type:'vbox',align:'stretch'},items:[{xtype:'dri-header'},{xtype:'container',flex:1,reference:'mainCardPanel',layout:{type:'card',anchor:'100%'}},{xtype:'dri-footer'}]},0,['app-main'],['component','box','container','app-main'],{'component':!0,'box':!0,'container':!0,'app-main':!0},['widget.app-main'],0,[Explorer.view.main,'Main'],0);Ext.application({name:'Explorer',extend:Explorer.Application,mainView:'Explorer.view.main.Main'}); \ No newline at end of file diff --git a/frontend/build/production/Explorer/app.json b/frontend/build/production/Explorer/app.json index 93790dc5e..92a610def 100644 --- a/frontend/build/production/Explorer/app.json +++ b/frontend/build/production/Explorer/app.json @@ -1 +1 @@ -{"packages":{"aladin":{"css":true,"included":true,"required":true,"requires":["ext","core","classic","ux","common"],"version":"1.0.0"},"charts":{"css":true,"included":true,"namespace":"Ext","required":true,"requires":["ext","core","classic"],"version":"6.0.1.250"},"classic":{"css":true,"included":true,"namespace":"Ext","required":true,"requires":["ext","core"],"version":"6.0.1.250"},"cmd":{"current":"6.5.1.240","version":"6.5.1.240"},"common":{"css":true,"included":true,"required":true,"requires":["ext","core","classic","ux"],"version":"1.0.0"},"core":{"css":true,"included":true,"required":true,"requires":["ext","classic"],"version":"6.0.1.250"},"ext":{"css":true,"included":true,"license":"gpl","namespace":"Ext","required":true,"requires":[],"version":"6.0.1.250"},"font-awesome":{"css":true,"included":true,"namespace":"Ext","required":true,"requires":["ext","core","classic","theme-base","theme-neutral","theme-neptune"],"theme":"theme-neptune","version":"6.0.1.250"},"theme-base":{"css":true,"included":true,"namespace":"Ext","required":true,"requires":["ext","core","classic"],"version":"6.0.1.250"},"theme-crisp":{"css":true,"extend":"theme-neptune","included":true,"namespace":"Ext","required":true,"requires":["ext","core","classic","theme-base","theme-neutral","theme-neptune"],"version":"6.0.1.250"},"theme-neptune":{"css":true,"extend":"theme-neutral","included":true,"namespace":"Ext","required":true,"requires":["ext","core","classic","theme-base","theme-neutral"],"version":"6.0.1.250"},"theme-neutral":{"css":true,"extend":"theme-base","included":true,"namespace":"Ext","required":true,"requires":["ext","core","classic","theme-base"],"version":"6.0.1.250"},"ux":{"css":true,"included":true,"namespace":"Ext","required":true,"requires":["ext","core","classic"],"version":"6.0.1.250"},"visiomatic":{"css":true,"included":true,"namespace":"visiomatic","required":true,"requires":["ext","core","classic"],"version":"1.0.0"}},"js":[{"remote":true,"path":"https://d3js.org/d3.v4.min.js"},{"path":"packages/local/visiomatic/src/Leaflet/dist/leaflet.js"},{"path":"packages/local/visiomatic/src/visiomatic/dist/jquery-min.js"},{"path":"packages/local/visiomatic/src/visiomatic/dist/jqplot-min.js"},{"path":"packages/local/visiomatic/src/visiomatic/dist/spectrum-min.js"},{"path":"packages/local/visiomatic/src/visiomatic/dist/visiomatic-src.js"},{"path":"packages/local/aladin/src/aladin/aladin-min.js"},{"path":"app.js"}],"css":[{"path":"packages/local/visiomatic/src/Leaflet/dist/leaflet.css"},{"path":"packages/local/visiomatic/src/visiomatic/dist/visiomatic.css"},{"path":"packages/local/visiomatic/src/visiomatic/dist/spectrum.css"},{"path":"packages/local/visiomatic/src/visiomatic/dist/jqplot.css"},{"path":"packages/local/aladin/src/aladin/aladin-min.css"},{"exclude":["fashion"],"path":"resources/Explorer-all.css"}],"cache":{"enable":true,"deltas":true},"fashion":{"inliner":{"enable":false}},"name":"Explorer","version":"1.0.0.0","framework":"ext","toolkit":"classic","theme":"theme-crisp","loader":{"cache":"20171130170710","cacheParam":"_dc"},"id":"1739eae9-ca05-49a0-800a-3c2bd487fa19","hash":"1f657c7a60a9918cad2babe434b1079312b1e385","profile":"","resources":{"path":"resources"}} \ No newline at end of file +{"packages":{"aladin":{"css":true,"included":true,"required":true,"requires":["ext","core","classic","ux","common"],"version":"1.0.0"},"charts":{"css":true,"included":true,"namespace":"Ext","required":true,"requires":["ext","core","classic"],"version":"6.0.1.250"},"classic":{"css":true,"included":true,"namespace":"Ext","required":true,"requires":["ext","core"],"version":"6.0.1.250"},"cmd":{"current":"6.5.1.240","version":"6.5.1.240"},"common":{"css":true,"included":true,"required":true,"requires":["ext","core","classic","ux"],"version":"1.0.0"},"core":{"css":true,"included":true,"required":true,"requires":["ext","classic"],"version":"6.0.1.250"},"ext":{"css":true,"included":true,"license":"gpl","namespace":"Ext","required":true,"requires":[],"version":"6.0.1.250"},"font-awesome":{"css":true,"included":true,"namespace":"Ext","required":true,"requires":["ext","core","classic","theme-base","theme-neutral","theme-neptune"],"theme":"theme-neptune","version":"6.0.1.250"},"theme-base":{"css":true,"included":true,"namespace":"Ext","required":true,"requires":["ext","core","classic"],"version":"6.0.1.250"},"theme-crisp":{"css":true,"extend":"theme-neptune","included":true,"namespace":"Ext","required":true,"requires":["ext","core","classic","theme-base","theme-neutral","theme-neptune"],"version":"6.0.1.250"},"theme-neptune":{"css":true,"extend":"theme-neutral","included":true,"namespace":"Ext","required":true,"requires":["ext","core","classic","theme-base","theme-neutral"],"version":"6.0.1.250"},"theme-neutral":{"css":true,"extend":"theme-base","included":true,"namespace":"Ext","required":true,"requires":["ext","core","classic","theme-base"],"version":"6.0.1.250"},"ux":{"css":true,"included":true,"namespace":"Ext","required":true,"requires":["ext","core","classic"],"version":"6.0.1.250"},"visiomatic":{"css":true,"included":true,"namespace":"visiomatic","required":true,"requires":["ext","core","classic"],"version":"1.0.0"}},"js":[{"remote":true,"path":"https://d3js.org/d3.v4.min.js"},{"path":"packages/local/visiomatic/src/Leaflet/dist/leaflet.js"},{"path":"packages/local/visiomatic/src/visiomatic/dist/jquery-min.js"},{"path":"packages/local/visiomatic/src/visiomatic/dist/jqplot-min.js"},{"path":"packages/local/visiomatic/src/visiomatic/dist/spectrum-min.js"},{"path":"packages/local/visiomatic/src/visiomatic/dist/visiomatic-src.js"},{"path":"packages/local/aladin/src/aladin/aladin-min.js"},{"path":"app.js"}],"css":[{"path":"packages/local/visiomatic/src/Leaflet/dist/leaflet.css"},{"path":"packages/local/visiomatic/src/visiomatic/dist/visiomatic.css"},{"path":"packages/local/visiomatic/src/visiomatic/dist/spectrum.css"},{"path":"packages/local/visiomatic/src/visiomatic/dist/jqplot.css"},{"path":"packages/local/aladin/src/aladin/aladin-min.css"},{"exclude":["fashion"],"path":"resources/Explorer-all.css"}],"cache":{"enable":true,"deltas":true},"fashion":{"inliner":{"enable":false}},"name":"Explorer","version":"1.0.0.0","framework":"ext","toolkit":"classic","theme":"theme-crisp","loader":{"cache":"20171201165551","cacheParam":"_dc"},"id":"1739eae9-ca05-49a0-800a-3c2bd487fa19","hash":"a51f038d09a13c585a123d7a9c8e0406ddd6e6bc","profile":"","resources":{"path":"resources"}} \ No newline at end of file diff --git a/frontend/build/production/Explorer/app.jsonp b/frontend/build/production/Explorer/app.jsonp index d53a0aa02..63a1326ee 100644 --- a/frontend/build/production/Explorer/app.jsonp +++ b/frontend/build/production/Explorer/app.jsonp @@ -1 +1 @@ -Ext.Microloader.setManifest({"packages":{"aladin":{"css":true,"included":true,"required":true,"requires":["ext","core","classic","ux","common"],"version":"1.0.0"},"charts":{"css":true,"included":true,"namespace":"Ext","required":true,"requires":["ext","core","classic"],"version":"6.0.1.250"},"classic":{"css":true,"included":true,"namespace":"Ext","required":true,"requires":["ext","core"],"version":"6.0.1.250"},"cmd":{"current":"6.5.1.240","version":"6.5.1.240"},"common":{"css":true,"included":true,"required":true,"requires":["ext","core","classic","ux"],"version":"1.0.0"},"core":{"css":true,"included":true,"required":true,"requires":["ext","classic"],"version":"6.0.1.250"},"ext":{"css":true,"included":true,"license":"gpl","namespace":"Ext","required":true,"requires":[],"version":"6.0.1.250"},"font-awesome":{"css":true,"included":true,"namespace":"Ext","required":true,"requires":["ext","core","classic","theme-base","theme-neutral","theme-neptune"],"theme":"theme-neptune","version":"6.0.1.250"},"theme-base":{"css":true,"included":true,"namespace":"Ext","required":true,"requires":["ext","core","classic"],"version":"6.0.1.250"},"theme-crisp":{"css":true,"extend":"theme-neptune","included":true,"namespace":"Ext","required":true,"requires":["ext","core","classic","theme-base","theme-neutral","theme-neptune"],"version":"6.0.1.250"},"theme-neptune":{"css":true,"extend":"theme-neutral","included":true,"namespace":"Ext","required":true,"requires":["ext","core","classic","theme-base","theme-neutral"],"version":"6.0.1.250"},"theme-neutral":{"css":true,"extend":"theme-base","included":true,"namespace":"Ext","required":true,"requires":["ext","core","classic","theme-base"],"version":"6.0.1.250"},"ux":{"css":true,"included":true,"namespace":"Ext","required":true,"requires":["ext","core","classic"],"version":"6.0.1.250"},"visiomatic":{"css":true,"included":true,"namespace":"visiomatic","required":true,"requires":["ext","core","classic"],"version":"1.0.0"}},"js":[{"remote":true,"path":"https://d3js.org/d3.v4.min.js"},{"path":"packages/local/visiomatic/src/Leaflet/dist/leaflet.js"},{"path":"packages/local/visiomatic/src/visiomatic/dist/jquery-min.js"},{"path":"packages/local/visiomatic/src/visiomatic/dist/jqplot-min.js"},{"path":"packages/local/visiomatic/src/visiomatic/dist/spectrum-min.js"},{"path":"packages/local/visiomatic/src/visiomatic/dist/visiomatic-src.js"},{"path":"packages/local/aladin/src/aladin/aladin-min.js"},{"path":"app.js"}],"css":[{"path":"packages/local/visiomatic/src/Leaflet/dist/leaflet.css"},{"path":"packages/local/visiomatic/src/visiomatic/dist/visiomatic.css"},{"path":"packages/local/visiomatic/src/visiomatic/dist/spectrum.css"},{"path":"packages/local/visiomatic/src/visiomatic/dist/jqplot.css"},{"path":"packages/local/aladin/src/aladin/aladin-min.css"},{"exclude":["fashion"],"path":"resources/Explorer-all.css"}],"cache":{"enable":true,"deltas":true},"fashion":{"inliner":{"enable":false}},"name":"Explorer","version":"1.0.0.0","framework":"ext","toolkit":"classic","theme":"theme-crisp","loader":{"cache":"20171130170710","cacheParam":"_dc"},"id":"1739eae9-ca05-49a0-800a-3c2bd487fa19","hash":"1f657c7a60a9918cad2babe434b1079312b1e385","profile":"","resources":{"path":"resources"}}); \ No newline at end of file +Ext.Microloader.setManifest({"packages":{"aladin":{"css":true,"included":true,"required":true,"requires":["ext","core","classic","ux","common"],"version":"1.0.0"},"charts":{"css":true,"included":true,"namespace":"Ext","required":true,"requires":["ext","core","classic"],"version":"6.0.1.250"},"classic":{"css":true,"included":true,"namespace":"Ext","required":true,"requires":["ext","core"],"version":"6.0.1.250"},"cmd":{"current":"6.5.1.240","version":"6.5.1.240"},"common":{"css":true,"included":true,"required":true,"requires":["ext","core","classic","ux"],"version":"1.0.0"},"core":{"css":true,"included":true,"required":true,"requires":["ext","classic"],"version":"6.0.1.250"},"ext":{"css":true,"included":true,"license":"gpl","namespace":"Ext","required":true,"requires":[],"version":"6.0.1.250"},"font-awesome":{"css":true,"included":true,"namespace":"Ext","required":true,"requires":["ext","core","classic","theme-base","theme-neutral","theme-neptune"],"theme":"theme-neptune","version":"6.0.1.250"},"theme-base":{"css":true,"included":true,"namespace":"Ext","required":true,"requires":["ext","core","classic"],"version":"6.0.1.250"},"theme-crisp":{"css":true,"extend":"theme-neptune","included":true,"namespace":"Ext","required":true,"requires":["ext","core","classic","theme-base","theme-neutral","theme-neptune"],"version":"6.0.1.250"},"theme-neptune":{"css":true,"extend":"theme-neutral","included":true,"namespace":"Ext","required":true,"requires":["ext","core","classic","theme-base","theme-neutral"],"version":"6.0.1.250"},"theme-neutral":{"css":true,"extend":"theme-base","included":true,"namespace":"Ext","required":true,"requires":["ext","core","classic","theme-base"],"version":"6.0.1.250"},"ux":{"css":true,"included":true,"namespace":"Ext","required":true,"requires":["ext","core","classic"],"version":"6.0.1.250"},"visiomatic":{"css":true,"included":true,"namespace":"visiomatic","required":true,"requires":["ext","core","classic"],"version":"1.0.0"}},"js":[{"remote":true,"path":"https://d3js.org/d3.v4.min.js"},{"path":"packages/local/visiomatic/src/Leaflet/dist/leaflet.js"},{"path":"packages/local/visiomatic/src/visiomatic/dist/jquery-min.js"},{"path":"packages/local/visiomatic/src/visiomatic/dist/jqplot-min.js"},{"path":"packages/local/visiomatic/src/visiomatic/dist/spectrum-min.js"},{"path":"packages/local/visiomatic/src/visiomatic/dist/visiomatic-src.js"},{"path":"packages/local/aladin/src/aladin/aladin-min.js"},{"path":"app.js"}],"css":[{"path":"packages/local/visiomatic/src/Leaflet/dist/leaflet.css"},{"path":"packages/local/visiomatic/src/visiomatic/dist/visiomatic.css"},{"path":"packages/local/visiomatic/src/visiomatic/dist/spectrum.css"},{"path":"packages/local/visiomatic/src/visiomatic/dist/jqplot.css"},{"path":"packages/local/aladin/src/aladin/aladin-min.css"},{"exclude":["fashion"],"path":"resources/Explorer-all.css"}],"cache":{"enable":true,"deltas":true},"fashion":{"inliner":{"enable":false}},"name":"Explorer","version":"1.0.0.0","framework":"ext","toolkit":"classic","theme":"theme-crisp","loader":{"cache":"20171201165551","cacheParam":"_dc"},"id":"1739eae9-ca05-49a0-800a-3c2bd487fa19","hash":"a51f038d09a13c585a123d7a9c8e0406ddd6e6bc","profile":"","resources":{"path":"resources"}}); \ No newline at end of file diff --git a/frontend/explorer/app/view/coadd/CoaddController.js b/frontend/explorer/app/view/coadd/CoaddController.js index d94922375..5a32dd195 100644 --- a/frontend/explorer/app/view/coadd/CoaddController.js +++ b/frontend/explorer/app/view/coadd/CoaddController.js @@ -395,12 +395,14 @@ Ext.define('Explorer.view.coadd.CoaddController', { var me = this, vm = me.getViewModel(), object = vm.get('object_data'), + ra = parseFloat(object._meta_ra).toFixed(4), + dec = parseFloat(object._meta_dec).toFixed(4), radius = .1, url; // Arcmin url = Ext.String.format( "http://simbad.u-strasbg.fr/simbad/sim-coo?Coord={0}+{1}&CooFrame=FK5&CooEpoch=2000&Radius={2}&Radius.unit=arcmin&submit=submit+query", - object._meta_ra, object._meta_dec, radius) + ra, dec, radius) window.open(url, '_blank') @@ -413,11 +415,13 @@ Ext.define('Explorer.view.coadd.CoaddController', { vm = me.getViewModel(), object = vm.get('object_data'), radius = .1, + ra = parseFloat(object._meta_ra).toFixed(4), + dec = parseFloat(object._meta_dec).toFixed(4), url; // Arcmin url = Ext.String.format( "https://ned.ipac.caltech.edu/cgi-bin/objsearch?search_type=Near+Position+Search&in_csys=Equatorial&in_equinox=J2000.0&lon={0}d&lat={1}d&radius={2}", - object._meta_ra, object._meta_dec, radius) + ra, dec, radius) window.open(url, '_blank') }, diff --git a/frontend/explorer/app/view/coadd/Visiomatic.js b/frontend/explorer/app/view/coadd/Visiomatic.js index f333c8b0b..15e6b7d25 100644 --- a/frontend/explorer/app/view/coadd/Visiomatic.js +++ b/frontend/explorer/app/view/coadd/Visiomatic.js @@ -7,17 +7,25 @@ Ext.define('Explorer.view.coadd.Visiomatic', { xtype: 'coadd-visiomatic', - // controller: 'coadd', + enableTools: true, - // viewModel: 'coadd', + enableLink: false, - enableTools: false, + enableShift: false, + + showCrosshair: true, + + mapOptions: { + fullscreenControl: true, + zoom: 1, + enableLineaOverlay: false + }, initComponent: function () { var me = this; Ext.apply(this, { - tbar: [ + auxTools:[ { xtype: 'combobox', reference: 'cmbCurrentDataset', @@ -47,6 +55,15 @@ Ext.define('Explorer.view.coadd.Visiomatic', { bind: { value: '{currentDataset.tli_tilename}' } + }, + { + xtype: 'button', + iconCls: 'x-fa fa-crosshairs', + tooltip: 'Show/Hide Crosshair', + enableToggle: true, + pressed: true, + scope: this, + toggleHandler: 'onShowHideCrosshair' } ] }); @@ -57,6 +74,12 @@ Ext.define('Explorer.view.coadd.Visiomatic', { changeDataset: function (combo) { this.fireEvent('changedataset', combo.getSelectedRecord(), this); + }, + + onShowHideCrosshair: function (btn, state) { + var me = this; + + me.setShowCrosshair(state); } }); diff --git a/frontend/explorer/app/view/system/SystemController.js b/frontend/explorer/app/view/system/SystemController.js index 72fb4e519..56e27c933 100644 --- a/frontend/explorer/app/view/system/SystemController.js +++ b/frontend/explorer/app/view/system/SystemController.js @@ -548,12 +548,14 @@ Ext.define('Explorer.view.system.SystemController', { var me = this, vm = me.getViewModel(), object = vm.get('object_data'), - radius = 2, - url; // Arcmin + ra = parseFloat(me.parseRA(object._meta_ra)).toFixed(4), + dec = parseFloat(object._meta_dec).toFixed(4), + radius = 2, // Arcmin + url; url = Ext.String.format( "http://simbad.u-strasbg.fr/simbad/sim-coo?Coord={0}+{1}&CooFrame=FK5&CooEpoch=2000&Radius={2}&Radius.unit=arcmin&submit=submit+query", - me.parseRA(object._meta_ra), object._meta_dec, radius) + ra, dec, radius) window.open(url, '_blank') @@ -565,12 +567,14 @@ Ext.define('Explorer.view.system.SystemController', { var me = this, vm = me.getViewModel(), object = vm.get('object_data'), - radius = 2, - url; // Arcmin + ra = parseFloat(me.parseRA(object._meta_ra)).toFixed(2), + dec = parseFloat(object._meta_dec).toFixed(2), + radius = 2, // Arcmin + url; url = Ext.String.format( "https://ned.ipac.caltech.edu/cgi-bin/objsearch?search_type=Near+Position+Search&in_csys=Equatorial&in_equinox=J2000.0&lon={0}d&lat={1}d&radius={2}", - me.parseRA(object._meta_ra), object._meta_dec, radius) + ra, dec, radius) window.open(url, '_blank') }, diff --git a/frontend/explorer/app/view/system/Visiomatic.js b/frontend/explorer/app/view/system/Visiomatic.js index ae9ab54be..b00d9235f 100644 --- a/frontend/explorer/app/view/system/Visiomatic.js +++ b/frontend/explorer/app/view/system/Visiomatic.js @@ -15,6 +15,12 @@ Ext.define('Explorer.view.system.Visiomatic', { showCrosshair: true, + mapOptions: { + fullscreenControl: true, + zoom: 1, + enableLineaOverlay: false + }, + initComponent: function () { var me = this; @@ -60,49 +66,6 @@ Ext.define('Explorer.view.system.Visiomatic', { toggleHandler: 'onShowHideCrosshair' } ] - - // tbar: [ - // { - // xtype: 'combobox', - // reference: 'cmbCurrentDataset', - // publishes: 'id', - // width: 250, - // displayField: 'release_tag', - // bind: { - // store: '{datasets}', - // disabled: '{!coadd.COADD_OBJECT_ID}', - // selection: '{!currentDataset}' - // }, - // queryMode: 'local', - // listConfig: { - // itemTpl: [ - // '
    {release_display_name} - {tag_display_name}
    ' - // ] - // }, - // listeners: { - // scope: this, - // change: 'changeDataset' - // } - // }, - // { - // xtype: 'textfield', - // width: 120, - // readOnly: true, - // bind: { - // value: '{currentDataset.tli_tilename}' - // } - // }, - // { - // xtype: 'button', - // iconCls: 'x-fa fa-crosshairs', - // tooltip: 'Show/Hide Crosshair', - // enableToggle: true, - // pressed: true, - // scope: this, - // toggleHandler: 'onShowHideCrosshair' - // } - // ] - }); me.callParent(arguments);