/*
 * Ext - JS Library 1.0 Alpha 3 - Rev 1
 * Copyright(c) 2006-2007, Jack Slocum.
 * 
 * http://www.extjs.com/license.txt
 */


Ext={};window["undefined"]=window["undefined"];Ext.apply=function(o,c,_3){if(_3){Ext.apply(o,_3);}if(o&&c){for(var p in c){o[p]=c[p];}}return o;};(function(){var _5=0;var ua=navigator.userAgent.toLowerCase();var _7=document.compatMode=="CSS1Compat",_8=ua.indexOf("opera")>-1,_9=ua.indexOf("webkit")>-1,_a=ua.indexOf("msie")>-1,_b=ua.indexOf("msie 7")>-1,_c=!_9&&ua.indexOf("gecko")>-1,_d=_a&&!_7,_e=(ua.indexOf("windows")!=-1||ua.indexOf("win32")!=-1),_f=(ua.indexOf("macintosh")!=-1||ua.indexOf("mac os x")!=-1);if(_a&&!_b){try{document.execCommand("BackgroundImageCache",false,true);}catch(e){}}Ext.apply(Ext,{isStrict:_7,SSL_SECURE_URL:"javascript:false",BLANK_IMAGE_URL:"http:/"+"/www.yui-ext.com/s.gif",emptyFn:function(){},applyIf:function(o,c){if(o&&c){for(var p in c){if(typeof o[p]=="undefined"){o[p]=c[p];}}}return o;},id:function(el,_14){_14=_14||"ext-gen";el=Ext.getDom(el);var id=_14+(++_5);return el?(el.id?el.id:(el.id=id)):id;},extend:function(){var io=function(o){for(var m in o){this[m]=o[m];}};return function(sc,sp,_1b){var F=function(){},scp,spp=sp.prototype;F.prototype=spp;scp=sc.prototype=new F();scp.constructor=sc;sc.superclass=spp;if(spp.constructor==Object.prototype.constructor){spp.constructor=sp;}sc.override=function(o){Ext.override(sc,o);};scp.override=io;Ext.override(sc,_1b);return sc;};}(),override:function(_20,_21){if(_21){var p=_20.prototype;for(var _23 in _21){p[_23]=_21[_23];}}},namespace:function(){var a=arguments,o=null,i,j,d,rt;for(i=0;i<a.length;++i){d=a[i].split(".");rt=d[0];eval("if (typeof "+rt+" == \"undefined\"){"+rt+" = {};} o = "+rt+";");for(j=1;j<d.length;++j){o[d[j]]=o[d[j]]||{};o=o[d[j]];}}},urlEncode:function(o){if(!o){return "";}var buf=[];for(var key in o){var _2d=typeof o[key];if(_2d!="function"&&_2d!="object"){buf.push(encodeURIComponent(key),"=",encodeURIComponent(o[key]),"&");}}buf.pop();return buf.join("");},each:function(_2e,fn,_30){if(typeof _2e.length=="undefined"||typeof _2e=="string"){_2e=[_2e];}for(var i=0,len=_2e.length;i<len;i++){if(fn.call(_30||_2e[i],_2e[i],i,_2e)===false){return i;}}},combine:function(){var as=arguments,l=as.length,r=[];for(var i=0;i<l;i++){var a=as[i];if(a instanceof Array){r=r.concat(a);}else{if(a.length!==undefined&&!a.substr){r=r.concat(Array.prototype.slice.call(a,0));}else{r.push(a);}}}return r;},escapeRe:function(s){return s.replace(/([.*+?^${}()|[\]\/\\])/g,"\\$1");},callback:function(cb,_3a,_3b,_3c){if(typeof cb=="function"){if(_3c){cb.defer(_3c,_3a,_3b||[]);}else{cb.apply(_3a,_3b||[]);}}},getDom:function(el){if(!el){return null;}return el.dom?el.dom:(typeof el=="string"?document.getElementById(el):el);},isOpera:_8,isSafari:_9,isIE:_a,isIE7:_b,isGecko:_c,isBorderBox:_d,isWindows:_e,isMac:_f,useShims:((_a&&!_b)||(_c&&_f))});})();Ext.namespace("Ext","Ext.util","Ext.grid","Ext.dd","Ext.tree","Ext.data","Ext.form","Ext.menu","Ext.state","Ext.lib");Ext.apply(Function.prototype,{createCallback:function(){var _3e=arguments;var _3f=this;return function(){return _3f.apply(window,_3e);};},createDelegate:function(obj,_41,_42){var _43=this;return function(){var _44=_41||arguments;if(_42===true){_44=Array.prototype.slice.call(arguments,0);_44=_44.concat(_41);}else{if(typeof _42=="number"){_44=Array.prototype.slice.call(arguments,0);var _45=[_42,0].concat(_41);Array.prototype.splice.apply(_44,_45);}}return _43.apply(obj||window,_44);};},defer:function(_46,obj,_48,_49){var fn=this.createDelegate(obj,_48,_49);if(_46){return setTimeout(fn,_46);}fn();return 0;},createSequence:function(fcn,_4c){if(typeof fcn!="function"){return this;}var _4d=this;return function(){var _4e=_4d.apply(this||window,arguments);fcn.apply(_4c||this||window,arguments);return _4e;};},createInterceptor:function(fcn,_50){if(typeof fcn!="function"){return this;}var _51=this;return function(){fcn.target=this;fcn.method=_51;if(fcn.apply(_50||this||window,arguments)===false){return;}return _51.apply(this||window,arguments);};}});Ext.applyIf(String,{escape:function(_52){return _52.replace(/('|\\)/g,"\\$1");},leftPad:function(val,_54,ch){var _56=new String(val);if(ch==null){ch=" ";}while(_56.length<_54){_56=ch+_56;}return _56;},format:function(_57){var _58=Array.prototype.slice.call(arguments,1);return _57.replace(/\{(\d+)\}/g,function(m,i){return _58[i];});}});String.prototype.toggle=function(_5b,_5c){return this==_5b?_5c:_5b;};Ext.applyIf(Number.prototype,{constrain:function(min,max){return Math.min(Math.max(this,min),max);}});Ext.applyIf(Array.prototype,{indexOf:function(o){for(var i=0,len=this.length;i<len;i++){if(this[i]==o){return i;}}return -1;},remove:function(o){var _63=this.indexOf(o);if(_63!=-1){this.splice(_63,1);}}});Date.prototype.getElapsed=function(_64){return Math.abs((_64||new Date()).getTime()-this.getTime());};

(function(){var libFlyweight;Ext.lib.Dom={getViewWidth:function(full){return full?this.getDocumentWidth():this.getViewportWidth();},getViewHeight:function(full){return full?this.getDocumentHeight():this.getViewportHeight();},getDocumentHeight:function(){var scrollHeight=Window.getScrollHeight();return Math.max(scrollHeight,this.getViewportHeight());},getDocumentWidth:function(){var scrollWidth=Window.getScrollWidth();return Math.max(scrollWidth,this.getViewportWidth());},getViewportHeight:function(){var height=self.innerHeight;var mode=document.compatMode;if((mode||Ext.isIE)&&!Ext.isOpera){height=(mode=="CSS1Compat")?document.documentElement.clientHeight:document.body.clientHeight;}return height;},getViewportWidth:function(){var width=self.innerWidth;var mode=document.compatMode;if(mode||Ext.isIE){width=(mode=="CSS1Compat")?document.documentElement.clientWidth:document.body.clientWidth;}return width;},isAncestor:function(p,c){p=Ext.getDom(p);c=Ext.getDom(c);if(!p||!c){return false;}if(p.contains&&!Ext.isSafari){return p.contains(c);}else if(p.compareDocumentPosition){return!!(p.compareDocumentPosition(c)&16);}else{var parent=c.parentNode;while(parent){if(parent==p){return true;}else if(!parent.tagName||parent.tagName.toUpperCase()=="HTML"){return false;}parent=parent.parentNode;}return false;}},getRegion:function(el){return Ext.lib.Region.getRegion(el);},getY:function(el){return this.getXY(el)[1];},getX:function(el){return this.getXY(el)[0];},getXY:function(el){var p,pe,b,scroll,bd=document.body;el=Ext.getDom(el);if(el.getBoundingClientRect){b=el.getBoundingClientRect();scroll=fly(document).getScroll();return[b.left+scroll.left,b.top+scroll.top];}else{var x=el.offsetLeft,y=el.offsetTop;p=el.offsetParent;var hasAbsolute=false;if(p!=el){while(p){x+=p.offsetLeft;y+=p.offsetTop;if(Ext.isSafari&&!hasAbsolute&&fly(p).getStyle("position")=="absolute"){hasAbsolute=true;}if(Ext.isGecko){pe=fly(p);var bt=parseInt(pe.getStyle("borderTopWidth"),10)||0;var bl=parseInt(pe.getStyle("borderLeftWidth"),10)||0;x+=bl;y+=bt;if(p!=el&&pe.getStyle('overflow')!='visible'){x+=bl;y+=bt;}}p=p.offsetParent;}}if(Ext.isSafari&&(hasAbsolute||fly(el).getStyle("position")=="absolute")){x-=bd.offsetLeft;y-=bd.offsetTop;}}p=el.parentNode;while(p&&p!=bd){if(!Ext.isOpera||(Ext.isOpera&&p.tagName!='TR'&&fly(p).getStyle("display")!="inline")){x-=p.scrollLeft;y-=p.scrollTop;}p=p.parentNode;}return[x,y];},setXY:function(el,xy){el=Ext.fly(el,'_setXY');el.position();var pts=el.translatePoints(xy);if(xy[0]!==false){el.dom.style.left=pts.left+"px";}if(xy[1]!==false){el.dom.style.top=pts.top+"px";}},setX:function(el,x){this.setXY(el,[x,false]);},setY:function(el,y){this.setXY(el,[false,y]);}};Ext.lib.Event={getPageX:function(e){e=e.browserEvent||e;return(new Event(e)).page.x;},getPageY:function(e){e=e.browserEvent||e;return(new Event(e)).page.y;},getXY:function(e){e=e.browserEvent||e;var ev=new Event(e);if(ev.client){return[ev.page.x,ev.page.y];}return[0,0];},getTarget:function(e){e=e.browserEvent||e;return(new Event(e)).target;},resolveTextNode:function(node){if(node&&3==node.nodeType){return node.parentNode;}else{return node;}},getRelatedTarget:function(e){e=e.browserEvent||e;var ev=new Event(e);var t=ev.relatedTarget;return this.resolveTextNode(t);},on:function(el,eventName,fn){var doGarbage=(el==window&&eventName=='unload');if(doGarbage){window.removeEvent('unload',Garbage.trash);}$(el).addEvent(eventName,fn);if(doGarbage){window.addEvent('unload',Garbage.trash);}},un:function(el,eventName,fn){$(el).removeEvent(eventName,fn);},purgeElement:function(el){},preventDefault:function(e){e=e.browserEvent||e;var ev=new Event(e);ev.preventDefault();},stopPropagation:function(e){e=e.browserEvent||e;var ev=new Event(e);if(ev.stopPropogation)ev.stopPropogation();},stopEvent:function(e){e=e.browserEvent||e;new Event(e).stop();},onAvailable:function(el,fn,scope,override){var start=new Date(),iid;var f=function(){if(start.getElapsed()>10000){clearInterval(iid);}var el=document.getElementById(id);if(el){clearInterval(iid);fn.call(scope||window,el);}};iid=setInterval(f,50);}};Ext.lib.Ajax=function(){var createSuccess=function(cb){return cb.success?function(text,xml){cb.success.call(cb.scope||window,{responseText:text,responseXML:xml,argument:cb.argument});}:Ext.emptyFn;};var createFailure=function(cb){return cb.failure?function(xhr){cb.failure.call(cb.scope||window,{responseText:xhr.responseText,responseXML:xhr.responseXML,argument:cb.argument});}:Ext.emptyFn;};return{request:function(method,uri,cb,data){if(method=='GET'){uri+=(uri.indexOf('?')==-1)?('?'+data):((data.length==0)?'':('&'+data));}new Ajax(uri,{method:method,postBody:method=='GET'?'':data,timeout:cb.timeout,onSuccess:createSuccess(cb),onFailure:createFailure(cb)}).request();},formRequest:function(form,uri,cb,data,isUpload,sslUri){new Ajax(uri,{method:'POST',postBody:$(form).toQueryString(),timeout:cb.timeout,onSuccess:createSuccess(cb),onFailure:createFailure(cb)}).request();},isCallInProgress:function(trans){return false;},abort:function(trans){return false;}};}();Ext.lib.Anim=function(){var createAnim=function(cb,scope){return{stop:function(skipToLast){this.effect.cancel();},isAnimated:function(){return this.state=='running';},proxyCallback:function(){Ext.callback(cb,scope);}};};return{scroll:function(el,args,duration,easing,cb,scope){var anim=createAnim(cb,scope);anim.effect=new Fx.Scroll(Ext.id(el),{duration:duration,easing:Fx.Transitions[easing]||Fx.Trasitions.linear,onComplete:anim.proxyCallback}).scrollTo(args[x],args[y]);return anim;},motion:function(el,args,duration,easing,cb,scope){return this.run(el,args,duration,easing,cb,scope);},color:function(el,args,duration,easing,cb,scope){return this.run(el,args,duration,easing,cb,scope);},run:function(el,args,duration,easing,cb,scope,type){var o={};el=Ext.fly(el);for(var k in args){switch(k){case'points':var by,pts;if(by=args.points.by){var xy=Ext.lib.Dom.getXY(el);pts=el.translatePoints([xy[0]+by[0],xy[1]+by[1]]);}else{pts=el.translatePoints(args.points.to);}o.left=pts.left+'px';o.top=pts.top+'px';break;case'width':o.width=args.width.to+'px';break;case'height':o.height=args.height.to+'px';break;case'opacity':o.opacity=String(args.opacity.to);break;default:o[k]=String(args[k].to);break;}}var anim=createAnim(cb,scope);anim.state='running';anim.effect=new Fx.Styles(Ext.id(el),{duration:duration*1000,onComplete:anim.proxyCallback,transition:Fx.Transitions[easing]||Fx.Transitions.linear}).start(o);anim.effect.addEvent('onComplete',function(){this.state='complete';}.bind(anim));return anim;}};}();function fly(el){if(!libFlyweight){libFlyweight=new Ext.Element.Flyweight();}libFlyweight.dom=el;return libFlyweight;}Ext.lib.Region=function(t,r,b,l){this.top=t;this[1]=t;this.right=r;this.bottom=b;this.left=l;this[0]=l;};Ext.lib.Region.prototype={contains:function(region){return(region.left>=this.left&&region.right<=this.right&&region.top>=this.top&&region.bottom<=this.bottom);},getArea:function(){return((this.bottom-this.top)*(this.right-this.left));},intersect:function(region){var t=Math.max(this.top,region.top);var r=Math.min(this.right,region.right);var b=Math.min(this.bottom,region.bottom);var l=Math.max(this.left,region.left);if(b>=t&&r>=l){return new Ext.lib.Region(t,r,b,l);}else{return null;}},union:function(region){var t=Math.min(this.top,region.top);var r=Math.max(this.right,region.right);var b=Math.max(this.bottom,region.bottom);var l=Math.min(this.left,region.left);return new Ext.lib.Region(t,r,b,l);},adjust:function(t,l,b,r){this.top+=t;this.left+=l;this.right+=r;this.bottom+=b;return this;}};Ext.lib.Region.getRegion=function(el){var p=Ext.lib.Dom.getXY(el);var t=p[1];var r=p[0]+el.offsetWidth;var b=p[1]+el.offsetHeight;var l=p[0];return new Ext.lib.Region(t,r,b,l);};Ext.lib.Point=function(x,y){if(x instanceof Array){y=x[1];x=x[0];}this.x=this.right=this.left=this[0]=x;this.y=this.top=this.bottom=this[1]=y;};Ext.lib.Point.prototype=new Ext.lib.Region();if(Ext.isIE){window.addEvent("unload",function(){var p=Function.prototype;delete p.createSequence;delete p.defer;delete p.createDelegate;delete p.createCallback;delete p.createInterceptor;});}})();
