Commit 35770032397a099935fd5d89304e5fad0f31a21b

Authored by Edmar Moretti
1 parent 2f4f2398

Teste de customização da barra de rolagem. Remoção da carga de arquivos javascri…

…pt da biblioteca YUI (buttons e treeview)
Showing 63 changed files with 24 additions and 44 deletions   Show diff stats
css/default.css
... ... @@ -801,10 +801,14 @@ td {
801 801 }
802 802  
803 803  
804   -/* JANELAS FLUTUANTES */
  804 +/* JANELAS FLUTUANTES
805 805 .yui-panel div {
806 806 background: none !IMPORTANT;
807 807 }
  808 +*/
  809 +.yui-panel div {
  810 + background: none;
  811 +}
808 812  
809 813 .container-minimiza {
810 814 background:
... ...
css/i3geo7.css.php 100755 → 100644
ferramentas/atalhoscamada/index.js
... ... @@ -94,6 +94,12 @@ i3GEOF.atalhoscamada =
94 94 return;
95 95 }
96 96 $i(iddiv).innerHTML = i3GEOF.atalhoscamada.html(idjanela);
  97 + $("#" + idjanela + " .container-fluid").mCustomScrollbar({
  98 + theme: "inset-2",
  99 + axis: "y",
  100 + scrollbarPosition: "inside",
  101 + scrollButtons:{ enable: false }
  102 + });
97 103 },
98 104 /*
99 105 * Function: html
... ...
ferramentas/atalhoscamada/template_mst.html
1   -<div class='container-fluid'>
  1 +<div class='container-fluid' style="height: 100%; overflow: auto; padding-right: 1px;">
2 2 <div class="form-group label-static" >
3 3 <label class="control-label">{{{opacidade}}}</label>
4 4 <form onsubmit='i3GEOF.atalhoscamada.mudaOpacidade(this,{{{idjanelaA}}});return false;'>
... ... @@ -20,7 +20,6 @@
20 20 <input class="form-control input-lg" type='text' value='' />
21 21 </form>
22 22 </div>
23   -
24 23 <a href='javascript:void(0)' onclick="i3GEO.tema.dialogo.procuraratrib('{{tema}}')" class='{{procurarHidden}} btn btn-primary btn-lg btn-block btn-raised'>{{{procurar}}}</a>
25 24 <a href='javascript:void(0)' onclick="i3GEO.tema.copia('{{tema}}')" class='btn btn-primary btn-lg btn-block btn-raised'>{{{copia}}}</a>
26 25 <a href='javascript:void(0)' onclick="i3GEO.tema.dialogo.toponimia('{{tema}}')" class='{{topoHidden}} btn btn-primary btn-lg btn-block btn-raised'>{{{topo}}}</a>
... ...
ferramentas/editorgm/editorgm_compacto.js 100755 → 100644
ferramentas/editorol/editorol_compacto.js 100755 → 100644
interface/openlayersdebug.htm
... ... @@ -13,6 +13,9 @@
13 13 <!-- configuracoes default tipo pode ser OL (openLayers) ou GM (googlemaps) -->
14 14 <script src="config.php?tipo=OL"></script>
15 15  
  16 +<script src="https://cdnjs.cloudflare.com/ajax/libs/malihu-custom-scrollbar-plugin/3.1.5/jquery.mCustomScrollbar.concat.min.js"></script>
  17 +<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/malihu-custom-scrollbar-plugin/3.1.5/jquery.mCustomScrollbar.min.css" />
  18 +
16 19 <link rel="stylesheet" type="text/css" href="../pacotes/ol3/ol.css">
17 20 <link rel="stylesheet" type="text/css" href="../pacotes/bootstrap/css/bootstrap.min.css">
18 21 <link rel="stylesheet" type="text/css" href="../pacotes/bootstrap-material-design/dist/css/bootstrap-material-design.min.css">
... ...
js/compactados/ajuda_compacto.js 100755 → 100644
js/compactados/analise_compacto.js 100755 → 100644
js/compactados/arvoredecamadas_compacto.js 100755 → 100644
js/compactados/arvoredetemas_compacto.js 100755 → 100644
js/compactados/base64_compacto.js 100755 → 100644
js/compactados/busca_compacto.js 100755 → 100644
js/compactados/caixaDeFerramentas_compacto.js 100755 → 100644
js/compactados/calculo_compacto.js 100755 → 100644
js/compactados/catalogoDir_compacto.js 100755 → 100644
js/compactados/catalogoEstrelas_compacto.js 100755 → 100644
js/compactados/catalogoInde_compacto.js 100755 → 100644
js/compactados/catalogoMapas_compacto.js 100755 → 100644
js/compactados/catalogoMenus_compacto.js 100755 → 100644
js/compactados/catalogoMetaestat_compacto.js 100755 → 100644
js/compactados/catalogoOgc_compacto.js 100755 → 100644
js/compactados/catalogoRegioes_compacto.js 100755 → 100644
js/compactados/catalogoSistemas_compacto.js 100755 → 100644
js/compactados/configura_compacto.js 100755 → 100644
js/compactados/coordenadas_compacto.js 100755 → 100644
js/compactados/desenho_compacto.js 100755 → 100644
js/compactados/dicionario_ajuda_compacto.js 100755 → 100644
js/compactados/dicionario_compacto.js 100755 → 100644
js/compactados/editor_compacto.js 100755 → 100644
js/compactados/eventos_compacto.js 100755 → 100644
js/compactados/guias_compacto.js 100755 → 100644
js/compactados/idioma_compacto.js 100755 → 100644
js/compactados/ini_i3geo_compacto.js 100755 → 100644
js/compactados/interface_compacto.js 100755 → 100644
js/compactados/janela_compacto.js 100755 → 100644
js/compactados/legenda_compacto.js 100755 → 100644
js/compactados/login_compacto.js 100755 → 100644
js/compactados/mapa_compacto.js 100755 → 100644
js/compactados/maparef_compacto.js 100755 → 100644
js/compactados/marcador_compacto.js 100755 → 100644
js/compactados/mustache.js 100755 → 100644
js/compactados/navega_compacto.js 100755 → 100644
js/compactados/php_compacto.js 100755 → 100644
js/compactados/plugini3geo_compacto.js 100755 → 100644
js/compactados/proj4js.js 100755 → 100644
js/compactados/social_compacto.js 100755 → 100644
js/compactados/tema_compacto.js 100755 → 100644
js/compactados/util_compacto.js 100755 → 100644
js/compactados/wicket.js 100755 → 100644
js/compactajs.php
... ... @@ -195,8 +195,8 @@ $jsfiles = array(
195 195 "../pacotes/yui290/build/container/container_compacto.js",
196 196 "../pacotes/yui290/build/element/element-min.js",
197 197 "../pacotes/yui290/build/tabview/tabview-min.js",
198   -"../pacotes/yui290/build/treeview/treeview_compacto.js",
199   -"../pacotes/yui290/build/button/button-min.js",
  198 +//"../pacotes/yui290/build/treeview/treeview_compacto.js",
  199 +//"../pacotes/yui290/build/button/button-min.js",
200 200 //"../pacotes/yui290/build/carousel/carousel_compacto.js",
201 201 "../pacotes/yui290/build/json/json-min.js",
202 202 "../pacotes/yui290/build/storage/storage-min.js",
... ...
js/i3geo_tudo_compacto7.js
... ... @@ -138,22 +138,6 @@ version: 2.9.0
138 138 (function(){var b=YAHOO.util,c=b.Dom,i=b.Event,g=window.document,k="active",d="activeIndex",f="activeTab",e="disabled",a="contentEl",h="element",j=function(m,l){l=l||{};if(arguments.length==1&&!YAHOO.lang.isString(m)&&!m.nodeName){l=m;m=l.element||null;}if(!m&&!l.element){m=this._createTabViewElement(l);}j.superclass.constructor.call(this,m,l);};YAHOO.extend(j,b.Element,{CLASSNAME:"yui-navset",TAB_PARENT_CLASSNAME:"yui-nav",CONTENT_PARENT_CLASSNAME:"yui-content",_tabParent:null,_contentParent:null,addTab:function(n,o){var p=this.get("tabs"),s=this._tabParent,q=this._contentParent,l=n.get(h),m=n.get(a),t=this.get(d),r;if(!p){this._queue[this._queue.length]=["addTab",arguments];return false;}r=this.getTab(o);o=(o===undefined)?p.length:o;p.splice(o,0,n);if(r){s.insertBefore(l,r.get(h));if(m){q.appendChild(m);}}else{s.appendChild(l);if(m){q.appendChild(m);}}if(!n.get(k)){n.set("contentVisible",false,true);if(o<=t){this.set(d,t+1,true);}}else{this.set(f,n,true);this.set("activeIndex",o,true);}this._initTabEvents(n);},_initTabEvents:function(l){l.addListener(l.get("activationEvent"),l._onActivate,this,l);l.addListener("activationEventChange",l._onActivationEventChange,this,l);},_removeTabEvents:function(l){l.removeListener(l.get("activationEvent"),l._onActivate,this,l);l.removeListener("activationEventChange",l._onActivationEventChange,this,l);},DOMEventHandler:function(q){var r=i.getTarget(q),t=this._tabParent,s=this.get("tabs"),n,m,l;if(c.isAncestor(t,r)){for(var o=0,p=s.length;o<p;o++){m=s[o].get(h);l=s[o].get(a);if(r==m||c.isAncestor(m,r)){n=s[o];break;}}if(n){n.fireEvent(q.type,q);}}},getTab:function(l){return this.get("tabs")[l];},getTabIndex:function(p){var m=null,o=this.get("tabs");for(var n=0,l=o.length;n<l;++n){if(p==o[n]){m=n;break;}}return m;},removeTab:function(o){var n=this.get("tabs").length,l=this.get(d),m=this.getTabIndex(o);if(o===this.get(f)){if(n>1){if(m+1===n){this.set(d,m-1);}else{this.set(d,m+1);}}else{this.set(f,null);}}else{if(m<l){this.set(d,l-1,true);}}this._removeTabEvents(o);this._tabParent.removeChild(o.get(h));this._contentParent.removeChild(o.get(a));this._configs.tabs.value.splice(m,1);o.fireEvent("remove",{type:"remove",tabview:this});},toString:function(){var l=this.get("id")||this.get("tagName");return"TabView "+l;},contentTransition:function(m,l){if(m){m.set("contentVisible",true);}if(l){l.set("contentVisible",false);}},initAttributes:function(l){j.superclass.initAttributes.call(this,l);if(!l.orientation){l.orientation="top";}var n=this.get(h);if(!this.hasClass(this.CLASSNAME)){this.addClass(this.CLASSNAME);}this.setAttributeConfig("tabs",{value:[],readOnly:true});this._tabParent=this.getElementsByClassName(this.TAB_PARENT_CLASSNAME,"ul")[0]||this._createTabParent();this._contentParent=this.getElementsByClassName(this.CONTENT_PARENT_CLASSNAME,"div")[0]||this._createContentParent();this.setAttributeConfig("orientation",{value:l.orientation,method:function(o){var p=this.get("orientation");this.addClass("yui-navset-"+o);if(p!=o){this.removeClass("yui-navset-"+p);}if(o==="bottom"){this.appendChild(this._tabParent);}}});this.setAttributeConfig(d,{value:l.activeIndex,validator:function(q){var o=true,p;if(q){p=this.getTab(q);if(p&&p.get(e)){o=false;}}return o;}});this.setAttributeConfig(f,{value:l[f],method:function(p){var o=this.get(f);if(p){p.set(k,true);}if(o&&o!==p){o.set(k,false);}if(o&&p!==o){this.contentTransition(p,o);}else{if(p){p.set("contentVisible",true);}}},validator:function(p){var o=true;if(p&&p.get(e)){o=false;}return o;}});this.on("activeTabChange",this._onActiveTabChange);this.on("activeIndexChange",this._onActiveIndexChange);if(this._tabParent){this._initTabs();}this.DOM_EVENTS.submit=false;this.DOM_EVENTS.focus=false;this.DOM_EVENTS.blur=false;this.DOM_EVENTS.change=false;for(var m in this.DOM_EVENTS){if(YAHOO.lang.hasOwnProperty(this.DOM_EVENTS,m)){this.addListener.call(this,m,this.DOMEventHandler);}}},deselectTab:function(l){if(this.getTab(l)===this.get(f)){this.set(f,null);}},selectTab:function(l){this.set(f,this.getTab(l));},_onActiveTabChange:function(n){var l=this.get(d),m=this.getTabIndex(n.newValue);if(l!==m){if(!(this.set(d,m))){this.set(f,n.prevValue);}}},_onActiveIndexChange:function(l){if(l.newValue!==this.getTabIndex(this.get(f))){if(!(this.set(f,this.getTab(l.newValue)))){this.set(d,l.prevValue);}}},_initTabs:function(){var q=c.getChildren(this._tabParent),o=c.getChildren(this._contentParent),n=this.get(d),r,m,s;for(var p=0,l=q.length;p<l;++p){m={};if(o[p]){m.contentEl=o[p];}r=new YAHOO.widget.Tab(q[p],m);this.addTab(r);if(r.hasClass(r.ACTIVE_CLASSNAME)){s=r;}}if(n!=undefined){this.set(f,this.getTab(n));}else{this._configs[f].value=s;this._configs[d].value=this.getTabIndex(s);}},_createTabViewElement:function(l){var m=g.createElement("div");if(this.CLASSNAME){m.className=this.CLASSNAME;}return m;},_createTabParent:function(l){var m=g.createElement("ul");if(this.TAB_PARENT_CLASSNAME){m.className=this.TAB_PARENT_CLASSNAME;}this.get(h).appendChild(m);return m;},_createContentParent:function(l){var m=g.createElement("div");if(this.CONTENT_PARENT_CLASSNAME){m.className=this.CONTENT_PARENT_CLASSNAME;}this.get(h).appendChild(m);return m;}});YAHOO.widget.TabView=j;})();(function(){var d=YAHOO.util,i=d.Dom,l=YAHOO.lang,m="activeTab",j="label",g="labelEl",q="content",c="contentEl",o="element",p="cacheData",b="dataSrc",h="dataLoaded",a="dataTimeout",n="loadMethod",f="postData",k="disabled",e=function(s,r){r=r||{};if(arguments.length==1&&!l.isString(s)&&!s.nodeName){r=s;s=r.element;}if(!s&&!r.element){s=this._createTabElement(r);}this.loadHandler={success:function(t){this.set(q,t.responseText);},failure:function(t){}};e.superclass.constructor.call(this,s,r);this.DOM_EVENTS={};};YAHOO.extend(e,YAHOO.util.Element,{LABEL_TAGNAME:"em",ACTIVE_CLASSNAME:"selected",HIDDEN_CLASSNAME:"yui-hidden",ACTIVE_TITLE:"active",DISABLED_CLASSNAME:k,LOADING_CLASSNAME:"loading",dataConnection:null,loadHandler:null,_loading:false,toString:function(){var r=this.get(o),s=r.id||r.tagName;
139 139 return"Tab "+s;},initAttributes:function(r){r=r||{};e.superclass.initAttributes.call(this,r);this.setAttributeConfig("activationEvent",{value:r.activationEvent||"click"});this.setAttributeConfig(g,{value:r[g]||this._getLabelEl(),method:function(s){s=i.get(s);var t=this.get(g);if(t){if(t==s){return false;}t.parentNode.replaceChild(s,t);this.set(j,s.innerHTML);}}});this.setAttributeConfig(j,{value:r.label||this._getLabel(),method:function(t){var s=this.get(g);if(!s){this.set(g,this._createLabelEl());}s.innerHTML=t;}});this.setAttributeConfig(c,{value:r[c]||document.createElement("div"),method:function(s){s=i.get(s);var t=this.get(c);if(t){if(t===s){return false;}if(!this.get("selected")){i.addClass(s,this.HIDDEN_CLASSNAME);}t.parentNode.replaceChild(s,t);this.set(q,s.innerHTML);}}});this.setAttributeConfig(q,{value:r[q]||this.get(c).innerHTML,method:function(s){this.get(c).innerHTML=s;}});this.setAttributeConfig(b,{value:r.dataSrc});this.setAttributeConfig(p,{value:r.cacheData||false,validator:l.isBoolean});this.setAttributeConfig(n,{value:r.loadMethod||"GET",validator:l.isString});this.setAttributeConfig(h,{value:false,validator:l.isBoolean,writeOnce:true});this.setAttributeConfig(a,{value:r.dataTimeout||null,validator:l.isNumber});this.setAttributeConfig(f,{value:r.postData||null});this.setAttributeConfig("active",{value:r.active||this.hasClass(this.ACTIVE_CLASSNAME),method:function(s){if(s===true){this.addClass(this.ACTIVE_CLASSNAME);this.set("title",this.ACTIVE_TITLE);}else{this.removeClass(this.ACTIVE_CLASSNAME);this.set("title","");}},validator:function(s){return l.isBoolean(s)&&!this.get(k);}});this.setAttributeConfig(k,{value:r.disabled||this.hasClass(this.DISABLED_CLASSNAME),method:function(s){if(s===true){this.addClass(this.DISABLED_CLASSNAME);}else{this.removeClass(this.DISABLED_CLASSNAME);}},validator:l.isBoolean});this.setAttributeConfig("href",{value:r.href||this.getElementsByTagName("a")[0].getAttribute("href",2)||"#",method:function(s){this.getElementsByTagName("a")[0].href=s;},validator:l.isString});this.setAttributeConfig("contentVisible",{value:r.contentVisible,method:function(s){if(s){i.removeClass(this.get(c),this.HIDDEN_CLASSNAME);if(this.get(b)){if(!this._loading&&!(this.get(h)&&this.get(p))){this._dataConnect();}}}else{i.addClass(this.get(c),this.HIDDEN_CLASSNAME);}},validator:l.isBoolean});},_dataConnect:function(){if(!d.Connect){return false;}i.addClass(this.get(c).parentNode,this.LOADING_CLASSNAME);this._loading=true;this.dataConnection=d.Connect.asyncRequest(this.get(n),this.get(b),{success:function(r){this.loadHandler.success.call(this,r);this.set(h,true);this.dataConnection=null;i.removeClass(this.get(c).parentNode,this.LOADING_CLASSNAME);this._loading=false;},failure:function(r){this.loadHandler.failure.call(this,r);this.dataConnection=null;i.removeClass(this.get(c).parentNode,this.LOADING_CLASSNAME);this._loading=false;},scope:this,timeout:this.get(a)},this.get(f));},_createTabElement:function(r){var v=document.createElement("li"),s=document.createElement("a"),u=r.label||null,t=r.labelEl||null;s.href=r.href||"#";v.appendChild(s);if(t){if(!u){u=this._getLabel();}}else{t=this._createLabelEl();}s.appendChild(t);return v;},_getLabelEl:function(){return this.getElementsByTagName(this.LABEL_TAGNAME)[0];},_createLabelEl:function(){var r=document.createElement(this.LABEL_TAGNAME);return r;},_getLabel:function(){var r=this.get(g);if(!r){return undefined;}return r.innerHTML;},_onActivate:function(u,t){var s=this,r=false;d.Event.preventDefault(u);if(s===t.get(m)){r=true;}t.set(m,s,r);},_onActivationEventChange:function(s){var r=this;if(s.prevValue!=s.newValue){r.removeListener(s.prevValue,r._onActivate);r.addListener(s.newValue,r._onActivate,this,r);}}});YAHOO.widget.Tab=e;})();YAHOO.register("tabview",YAHOO.widget.TabView,{version:"2.9.0",build:"2800"});
140 140 //
141   -//../pacotes/yui290/build/treeview/treeview_compacto.js
142   -(function(){var Dom=YAHOO.util.Dom,Event=YAHOO.util.Event,Lang=YAHOO.lang,Widget=YAHOO.widget;YAHOO.widget.TreeView=function(id,oConfig){if(id){this.init(id)}if(oConfig){this.buildTreeFromObject(oConfig)}else if(Lang.trim(this._el.innerHTML)){this.buildTreeFromMarkup(id)}};var TV=Widget.TreeView;TV.prototype={id:null,_el:null,_nodes:null,locked:false,_expandAnim:null,_collapseAnim:null,_animCount:0,maxAnim:2,_hasDblClickSubscriber:false,_dblClickTimer:null,currentFocus:null,singleNodeHighlight:false,_currentlyHighlighted:null,setExpandAnim:function(type){this._expandAnim=(Widget.TVAnim.isValid(type))?type:null},setCollapseAnim:function(type){this._collapseAnim=(Widget.TVAnim.isValid(type))?type:null},animateExpand:function(el,node){if(this._expandAnim&&this._animCount<this.maxAnim){var tree=this;var a=Widget.TVAnim.getAnim(this._expandAnim,el,function(){tree.expandComplete(node)});if(a){++this._animCount;this.fireEvent("animStart",{"node":node,"type":"expand"});a.animate()}return true}return false},animateCollapse:function(el,node){if(this._collapseAnim&&this._animCount<this.maxAnim){var tree=this;var a=Widget.TVAnim.getAnim(this._collapseAnim,el,function(){tree.collapseComplete(node)});if(a){++this._animCount;this.fireEvent("animStart",{"node":node,"type":"collapse"});a.animate()}return true}return false},expandComplete:function(node){--this._animCount;this.fireEvent("animComplete",{"node":node,"type":"expand"})},collapseComplete:function(node){--this._animCount;this.fireEvent("animComplete",{"node":node,"type":"collapse"})},init:function(id){this._el=Dom.get(id);this.id=Dom.generateId(this._el,"yui-tv-auto-id-");this.createEvent("animStart",this);this.createEvent("animComplete",this);this.createEvent("collapse",this);this.createEvent("collapseComplete",this);this.createEvent("expand",this);this.createEvent("expandComplete",this);this.createEvent("enterKeyPressed",this);this.createEvent("clickEvent",this);this.createEvent('focusChanged',this);var self=this;this.createEvent("dblClickEvent",{scope:this,onSubscribeCallback:function(){self._hasDblClickSubscriber=true}});this.createEvent("labelClick",this);this.createEvent("highlightEvent",this);this._nodes=[];TV.trees[this.id]=this;this.root=new Widget.RootNode(this);var LW=Widget.LogWriter;if(this._initEditor){this._initEditor()}},buildTreeFromObject:function(oConfig){var build=function(parent,oConfig){var i,item,node,children,type,NodeType,ThisType;for(i=0;i<oConfig.length;i++){item=oConfig[i];if(Lang.isString(item)){node=new Widget.TextNode(item,parent)}else if(Lang.isObject(item)){children=item.children;delete item.children;type=item.type||'text';delete item.type;switch(Lang.isString(type)&&type.toLowerCase()){case'text':node=new Widget.TextNode(item,parent);break;case'menu':node=new Widget.MenuNode(item,parent);break;case'html':node=new Widget.HTMLNode(item,parent);break;default:if(Lang.isString(type)){NodeType=Widget[type]}else{NodeType=type}if(Lang.isObject(NodeType)){for(ThisType=NodeType;ThisType&&ThisType!==Widget.Node;ThisType=ThisType.superclass.constructor){}if(ThisType){node=new NodeType(item,parent)}else{}}else{}}if(children){build(node,children)}}else{}}};if(!Lang.isArray(oConfig)){oConfig=[oConfig]}build(this.root,oConfig)},buildTreeFromMarkup:function(id){var build=function(markup){var el,child,branch=[],config={},label,yuiConfig;for(el=Dom.getFirstChild(markup);el;el=Dom.getNextSibling(el)){switch(el.tagName.toUpperCase()){case'LI':label='';config={expanded:Dom.hasClass(el,'expanded'),title:el.title||el.alt||null,className:Lang.trim(el.className.replace(/\bexpanded\b/,''))||null};child=el.firstChild;if(child.nodeType==3){label=Lang.trim(child.nodeValue.replace(/[\n\t\r]*/g,''));if(label){config.type='text';config.label=label}else{child=Dom.getNextSibling(child)}}if(!label){if(child.tagName.toUpperCase()=='A'){config.type='text';config.label=child.innerHTML;config.href=child.href;config.target=child.target;config.title=child.title||child.alt||config.title}else{config.type='html';var d=document.createElement('div');d.appendChild(child.cloneNode(true));config.html=d.innerHTML;config.hasIcon=true}}child=Dom.getNextSibling(child);switch(child&&child.tagName.toUpperCase()){case'UL':case'OL':config.children=build(child);break}if(YAHOO.lang.JSON){yuiConfig=el.getAttribute('yuiConfig');if(yuiConfig){yuiConfig=YAHOO.lang.JSON.parse(yuiConfig);config=YAHOO.lang.merge(config,yuiConfig)}}branch.push(config);break;case'UL':case'OL':config={type:'text',label:'',children:build(child)};branch.push(config);break}}return branch};var markup=Dom.getChildrenBy(Dom.get(id),function(el){var tag=el.tagName.toUpperCase();return tag=='UL'||tag=='OL'});if(markup.length){this.buildTreeFromObject(build(markup[0]))}else{}},_getEventTargetTdEl:function(ev){var target=Event.getTarget(ev);while(target&&!(target.tagName.toUpperCase()=='TD'&&Dom.hasClass(target.parentNode,'ygtvrow'))){target=Dom.getAncestorByTagName(target,'td')}if(Lang.isNull(target)){return null}if(/\bygtv(blank)?depthcell/.test(target.className)){return null}if(target.id){var m=target.id.match(/\bygtv([^\d]*)(.*)/);if(m&&m[2]&&this._nodes[m[2]]){return target}}return null},_onClickEvent:function(ev){var self=this,td=this._getEventTargetTdEl(ev),node,target,toggle=function(force){node.focus();if(force||!node.href){node.toggle();try{Event.preventDefault(ev)}catch(e){}}};if(!td){return}node=this.getNodeByElement(td);if(!node){return}target=Event.getTarget(ev);if(Dom.hasClass(target,node.labelStyle)||Dom.getAncestorByClassName(target,node.labelStyle)){this.fireEvent('labelClick',node)}if(this._closeEditor){this._closeEditor(false)}if(/\bygtv[tl][mp]h?h?/.test(td.className)){toggle(true)}else{if(this._dblClickTimer){window.clearTimeout(this._dblClickTimer);this._dblClickTimer=null}else{if(this._hasDblClickSubscriber){this._dblClickTimer=window.setTimeout(function(){self._dblClickTimer=null;if(self.fireEvent('clickEvent',{event:ev,node:node})!==false){toggle()}},200)}else{if(self.fireEvent('clickEvent',{event:ev,node:node})!==false){if(node.enableHighlight==true){toggle()}}}}}},_onDblClickEvent:function(ev){if(!this._hasDblClickSubscriber){return}var td=this._getEventTargetTdEl(ev);if(!td){return}if(!(/\bygtv[tl][mp]h?h?/.test(td.className))){this.fireEvent('dblClickEvent',{event:ev,node:this.getNodeByElement(td)});if(this._dblClickTimer){window.clearTimeout(this._dblClickTimer);this._dblClickTimer=null}}},_onMouseOverEvent:function(ev){var target;if((target=this._getEventTargetTdEl(ev))&&(target=this.getNodeByElement(target))&&(target=target.getToggleEl())){target.className=target.className.replace(/\bygtv([lt])([mp])\b/gi,'ygtv$1$2h')}},_onMouseOutEvent:function(ev){var target;if((target=this._getEventTargetTdEl(ev))&&(target=this.getNodeByElement(target))&&(target=target.getToggleEl())){target.className=target.className.replace(/\bygtv([lt])([mp])h\b/gi,'ygtv$1$2')}},_onKeyDownEvent:function(ev){var target=Event.getTarget(ev),node=this.getNodeByElement(target),newNode=node,KEY=YAHOO.util.KeyListener.KEY;switch(ev.keyCode){case KEY.UP:do{if(newNode.previousSibling){newNode=newNode.previousSibling}else{newNode=newNode.parent}}while(newNode&&!newNode._canHaveFocus());if(newNode){newNode.focus()}Event.preventDefault(ev);break;case KEY.DOWN:do{if(newNode.nextSibling){newNode=newNode.nextSibling}else{newNode.expand();newNode=(newNode.children.length||null)&&newNode.children[0]}}while(newNode&&!newNode._canHaveFocus);if(newNode){newNode.focus()}Event.preventDefault(ev);break;case KEY.LEFT:do{if(newNode.parent){newNode=newNode.parent}else{newNode=newNode.previousSibling}}while(newNode&&!newNode._canHaveFocus());if(newNode){newNode.focus()}Event.preventDefault(ev);break;case KEY.RIGHT:var self=this,moveFocusRight,focusOnExpand=function(newNode){self.unsubscribe('expandComplete',focusOnExpand);moveFocusRight(newNode)};moveFocusRight=function(newNode){do{if(newNode.isDynamic()&&!newNode.childrenRendered){self.subscribe('expandComplete',focusOnExpand);newNode.expand();newNode=null;break}else{newNode.expand();if(newNode.children.length){newNode=newNode.children[0]}else{newNode=newNode.nextSibling}}}while(newNode&&!newNode._canHaveFocus());if(newNode){newNode.focus()}};moveFocusRight(newNode);Event.preventDefault(ev);break;case KEY.ENTER:if(node.href){if(node.target){window.open(node.href,node.target)}else{window.location(node.href)}}else{node.toggle()}this.fireEvent('enterKeyPressed',node);Event.preventDefault(ev);break;case KEY.HOME:newNode=this.getRoot();if(newNode.children.length){newNode=newNode.children[0]}if(newNode._canHaveFocus()){newNode.focus()}Event.preventDefault(ev);break;case KEY.END:newNode=newNode.parent.children;newNode=newNode[newNode.length-1];if(newNode._canHaveFocus()){newNode.focus()}Event.preventDefault(ev);break;case 107:case 187:if(ev.shiftKey){node.parent.expandAll()}else{node.expand()}break;case 109:case 189:if(ev.shiftKey){node.parent.collapseAll()}else{node.collapse()}break;default:break}},render:function(){var html=this.root.getHtml(),el=this.getEl();el.innerHTML=html;if(!this._hasEvents){Event.on(el,'click',this._onClickEvent,this,true);Event.on(el,'dblclick',this._onDblClickEvent,this,true);Event.on(el,'mouseover',this._onMouseOverEvent,this,true);Event.on(el,'mouseout',this._onMouseOutEvent,this,true);Event.on(el,'keydown',this._onKeyDownEvent,this,true)}this._hasEvents=true},getEl:function(){if(!this._el){this._el=Dom.get(this.id)}return this._el},regNode:function(node){this._nodes[node.index]=node},getRoot:function(){return this.root},setDynamicLoad:function(fnDataLoader,iconMode){this.root.setDynamicLoad(fnDataLoader,iconMode)},expandAll:function(){if(!this.locked){this.root.expandAll()}},collapseAll:function(){if(!this.locked){this.root.collapseAll()}},getNodeByIndex:function(nodeIndex){var n=this._nodes[nodeIndex];return(n)?n:null},getNodeByProperty:function(property,value){for(var i in this._nodes){if(this._nodes.hasOwnProperty(i)){var n=this._nodes[i];if((property in n&&n[property]==value)||(n.data&&value==n.data[property])){return n}}}return null},getNodesByProperty:function(property,value){var values=[];for(var i in this._nodes){if(this._nodes.hasOwnProperty(i)){var n=this._nodes[i];if((property in n&&n[property]==value)||(n.data&&value==n.data[property])){values.push(n)}}}return(values.length)?values:null},getNodesBy:function(fn){var values=[];for(var i in this._nodes){if(this._nodes.hasOwnProperty(i)){var n=this._nodes[i];if(fn(n)){values.push(n)}}}return(values.length)?values:null},getNodeByElement:function(el){var p=el,m,re=/ygtv([^\d]*)(.*)/;do{if(p&&p.id){m=p.id.match(re);if(m&&m[2]){return this.getNodeByIndex(m[2])}}p=p.parentNode;if(!p||!p.tagName){break}}while(p.id!==this.id&&p.tagName.toLowerCase()!=="body");return null},getHighlightedNode:function(){return this._currentlyHighlighted},removeNode:function(node,autoRefresh){if(node.isRoot()){return false}var p=node.parent;if(p.parent){p=p.parent}this._deleteNode(node);if(autoRefresh&&p&&p.childrenRendered){p.refresh()}return true},_removeChildren_animComplete:function(o){this.unsubscribe(this._removeChildren_animComplete);this.removeChildren(o.node)},removeChildren:function(node){if(node.expanded){if(this._collapseAnim){this.subscribe("animComplete",this._removeChildren_animComplete,this,true);Widget.Node.prototype.collapse.call(node);return}node.collapse()}while(node.children.length){this._deleteNode(node.children[0])}if(node.isRoot()){Widget.Node.prototype.expand.call(node)}node.childrenRendered=false;node.dynamicLoadComplete=false;node.updateIcon()},_deleteNode:function(node){this.removeChildren(node);this.popNode(node)},popNode:function(node){var p=node.parent;var a=[];for(var i=0,len=p.children.length;i<len;++i){if(p.children[i]!=node){a[a.length]=p.children[i]}}p.children=a;p.childrenRendered=false;if(node.previousSibling){node.previousSibling.nextSibling=node.nextSibling}if(node.nextSibling){node.nextSibling.previousSibling=node.previousSibling}if(this.currentFocus==node){this.currentFocus=null}if(this._currentlyHighlighted==node){this._currentlyHighlighted=null}node.parent=null;node.previousSibling=null;node.nextSibling=null;node.tree=null;delete this._nodes[node.index]},destroy:function(){if(this._destroyEditor){this._destroyEditor()}var el=this.getEl();Event.removeListener(el,'click');Event.removeListener(el,'dblclick');Event.removeListener(el,'mouseover');Event.removeListener(el,'mouseout');Event.removeListener(el,'keydown');for(var i=0;i<this._nodes.length;i++){var node=this._nodes[i];if(node&&node.destroy){node.destroy()}}el.innerHTML='';this._hasEvents=false},toString:function(){return"TreeView "+this.id},getNodeCount:function(){return this.getRoot().getNodeCount()},getTreeDefinition:function(){return this.getRoot().getNodeDefinition()},onExpand:function(node){},onCollapse:function(node){},setNodesProperty:function(name,value,refresh){this.root.setNodesProperty(name,value);if(refresh){this.root.refresh()}},onEventToggleHighlight:function(oArgs){var node;if('node'in oArgs&&oArgs.node instanceof Widget.Node){node=oArgs.node}else if(oArgs instanceof Widget.Node){node=oArgs}else{return false}node.toggleHighlight();return false}};var PROT=TV.prototype;PROT.draw=PROT.render;YAHOO.augment(TV,YAHOO.util.EventProvider);TV.nodeCount=0;TV.trees=[];TV.getTree=function(treeId){var t=TV.trees[treeId];return(t)?t:null};TV.getNode=function(treeId,nodeIndex){var t=TV.getTree(treeId);return(t)?t.getNodeByIndex(nodeIndex):null};TV.FOCUS_CLASS_NAME='ygtvfocus'})();(function(){var Dom=YAHOO.util.Dom,Lang=YAHOO.lang,Event=YAHOO.util.Event;YAHOO.widget.Node=function(oData,oParent,expanded){if(oData){this.init(oData,oParent,expanded)}};YAHOO.widget.Node.prototype={index:0,children:null,tree:null,data:null,parent:null,depth:-1,expanded:false,multiExpand:true,renderHidden:false,childrenRendered:false,dynamicLoadComplete:false,previousSibling:null,nextSibling:null,_dynLoad:false,dataLoader:null,isLoading:false,hasIcon:true,iconMode:0,nowrap:false,isLeaf:false,contentStyle:"",contentElId:null,enableHighlight:true,highlightState:0,propagateHighlightUp:false,propagateHighlightDown:false,className:null,_type:"Node",init:function(oData,oParent,expanded){this.data={};this.children=[];this.index=YAHOO.widget.TreeView.nodeCount;++YAHOO.widget.TreeView.nodeCount;this.contentElId="ygtvcontentel"+this.index;if(Lang.isObject(oData)){for(var property in oData){if(oData.hasOwnProperty(property)){if(property.charAt(0)!='_'&&!Lang.isUndefined(this[property])&&!Lang.isFunction(this[property])){this[property]=oData[property]}else{this.data[property]=oData[property]}}}}if(!Lang.isUndefined(expanded)){this.expanded=expanded}this.createEvent("parentChange",this);if(oParent){oParent.appendChild(this)}},applyParent:function(parentNode){if(!parentNode){return false}this.tree=parentNode.tree;this.parent=parentNode;this.depth=parentNode.depth+1;this.tree.regNode(this);parentNode.childrenRendered=false;for(var i=0,len=this.children.length;i<len;++i){this.children[i].applyParent(this)}this.fireEvent("parentChange");return true},appendChild:function(childNode){if(this.hasChildren()){var sib=this.children[this.children.length-1];sib.nextSibling=childNode;childNode.previousSibling=sib}this.children[this.children.length]=childNode;childNode.applyParent(this);if(this.childrenRendered&&this.expanded){this.getChildrenEl().style.display=""}return childNode},appendTo:function(parentNode){return parentNode.appendChild(this)},insertBefore:function(node){var p=node.parent;if(p){if(this.tree){this.tree.popNode(this)}var refIndex=node.isChildOf(p);p.children.splice(refIndex,0,this);if(node.previousSibling){node.previousSibling.nextSibling=this}this.previousSibling=node.previousSibling;this.nextSibling=node;node.previousSibling=this;this.applyParent(p)}return this},insertAfter:function(node){var p=node.parent;if(p){if(this.tree){this.tree.popNode(this)}var refIndex=node.isChildOf(p);if(!node.nextSibling){this.nextSibling=null;return this.appendTo(p)}p.children.splice(refIndex+1,0,this);node.nextSibling.previousSibling=this;this.previousSibling=node;this.nextSibling=node.nextSibling;node.nextSibling=this;this.applyParent(p)}return this},isChildOf:function(parentNode){if(parentNode&&parentNode.children){for(var i=0,len=parentNode.children.length;i<len;++i){if(parentNode.children[i]===this){return i}}}return-1},getSiblings:function(){var sib=this.parent.children.slice(0);for(var i=0;i<sib.length&&sib[i]!=this;i++){}sib.splice(i,1);if(sib.length){return sib}return null},showChildren:function(){if(!this.tree.animateExpand(this.getChildrenEl(),this)){if(this.hasChildren()){this.getChildrenEl().style.display=""}}},hideChildren:function(){if(!this.tree.animateCollapse(this.getChildrenEl(),this)){this.getChildrenEl().style.display="none"}},getElId:function(){return"ygtv"+this.index},getChildrenElId:function(){return"ygtvc"+this.index},getToggleElId:function(){return"ygtvt"+this.index},getEl:function(){return Dom.get(this.getElId())},getChildrenEl:function(){return Dom.get(this.getChildrenElId())},getToggleEl:function(){return Dom.get(this.getToggleElId())},getContentEl:function(){return Dom.get(this.contentElId)},collapse:function(){if(!this.expanded){return}var ret=this.tree.onCollapse(this);if(false===ret){return}ret=this.tree.fireEvent("collapse",this);if(false===ret){return}if(!this.getEl()){this.expanded=false}else{this.hideChildren();this.expanded=false;this.updateIcon()}ret=this.tree.fireEvent("collapseComplete",this)},expand:function(lazySource){if(this.isLoading||(this.expanded&&!lazySource)){return}var ret=true;if(!lazySource){ret=this.tree.onExpand(this);if(false===ret){return}ret=this.tree.fireEvent("expand",this)}if(false===ret){return}if(!this.getEl()){this.expanded=true;return}if(!this.childrenRendered){this.getChildrenEl().innerHTML=this.renderChildren()}else{}this.expanded=true;this.updateIcon();if(this.isLoading){this.expanded=false;return}if(!this.multiExpand){var sibs=this.getSiblings();for(var i=0;sibs&&i<sibs.length;++i){if(sibs[i]!=this&&sibs[i].expanded){sibs[i].collapse()}}}this.showChildren();ret=this.tree.fireEvent("expandComplete",this)},updateIcon:function(){if(this.hasIcon){var el=this.getToggleEl();if(el){el.className=el.className.replace(/\bygtv(([tl][pmn]h?)|(loading))\b/gi,this.getStyle())}}el=Dom.get('ygtvtableel'+this.index);if(el){if(this.expanded){Dom.replaceClass(el,'ygtv-collapsed','ygtv-expanded')}else{Dom.replaceClass(el,'ygtv-expanded','ygtv-collapsed')}}},getStyle:function(){if(this.isLoading){return"ygtvloading"}else{var loc=(this.nextSibling)?"t":"l";var type="n";if(this.hasChildren(true)||(this.isDynamic()&&!this.getIconMode())){type=(this.expanded)?"m":"p"}return"ygtv"+loc+type}},getHoverStyle:function(){var s=this.getStyle();if(this.hasChildren(true)&&!this.isLoading){s+="h"}return s},expandAll:function(){var l=this.children.length;for(var i=0;i<l;++i){var c=this.children[i];if(c.isDynamic()){break}else if(!c.multiExpand){break}else{c.expand();c.expandAll()}}},collapseAll:function(){for(var i=0;i<this.children.length;++i){this.children[i].collapse();this.children[i].collapseAll()}},setDynamicLoad:function(fnDataLoader,iconMode){if(fnDataLoader){this.dataLoader=fnDataLoader;this._dynLoad=true}else{this.dataLoader=null;this._dynLoad=false}if(iconMode){this.iconMode=iconMode}},isRoot:function(){return(this==this.tree.root)},isDynamic:function(){if(this.isLeaf){return false}else{return(!this.isRoot()&&(this._dynLoad||this.tree.root._dynLoad))}},getIconMode:function(){return(this.iconMode||this.tree.root.iconMode)},hasChildren:function(checkForLazyLoad){if(this.isLeaf){return false}else{return(this.children.length>0||(checkForLazyLoad&&this.isDynamic()&&!this.dynamicLoadComplete))}},toggle:function(){if(!this.tree.locked&&(this.hasChildren(true)||this.isDynamic())){if(this.expanded){this.collapse()}else{this.expand()}}},getHtml:function(){this.childrenRendered=false;return['<div class="ygtvitem" id="',this.getElId(),'">',this.getNodeHtml(),this.getChildrenHtml(),'</div>'].join("")},getChildrenHtml:function(){var sb=[];sb[sb.length]='<div class="ygtvchildren" id="'+this.getChildrenElId()+'"';if(!this.expanded||!this.hasChildren()){sb[sb.length]=' style="display:none;"'}sb[sb.length]='>';if((this.hasChildren(true)&&this.expanded)||(this.renderHidden&&!this.isDynamic())){sb[sb.length]=this.renderChildren()}sb[sb.length]='</div>';return sb.join("")},renderChildren:function(){var node=this;if(this.isDynamic()&&!this.dynamicLoadComplete){this.isLoading=true;this.tree.locked=true;if(this.dataLoader){setTimeout(function(){node.dataLoader(node,function(){node.loadComplete()})},10)}else if(this.tree.root.dataLoader){setTimeout(function(){node.tree.root.dataLoader(node,function(){node.loadComplete()})},10)}else{return"Error: data loader not found or not specified."}return""}else{return this.completeRender()}},completeRender:function(){var sb=[];for(var i=0;i<this.children.length;++i){sb[sb.length]=this.children[i].getHtml()}this.childrenRendered=true;return sb.join("")},loadComplete:function(){this.getChildrenEl().innerHTML=this.completeRender();if(this.propagateHighlightDown){if(this.highlightState===1&&!this.tree.singleNodeHighlight){for(var i=0;i<this.children.length;i++){this.children[i].highlight(true)}}else if(this.highlightState===0||this.tree.singleNodeHighlight){for(i=0;i<this.children.length;i++){this.children[i].unhighlight(true)}}}this.dynamicLoadComplete=true;this.isLoading=false;this.expand(true);this.tree.locked=false},getAncestor:function(depth){if(depth>=this.depth||depth<0){return null}var p=this.parent;while(p.depth>depth){p=p.parent}return p},getDepthStyle:function(depth){return(this.getAncestor(depth).nextSibling)?"ygtvdepthcell":"ygtvblankdepthcell"},getNodeHtml:function(){var sb=[];sb[sb.length]='<table id="ygtvtableel'+this.index+'" border="0" cellpadding="0" cellspacing="0" class="ygtvtable ygtvdepth'+this.depth;sb[sb.length]=' ygtv-'+(this.expanded?'expanded':'collapsed');if(this.enableHighlight){sb[sb.length]=' ygtv-highlight'+this.highlightState}if(this.className){sb[sb.length]=' '+this.className}sb[sb.length]='"><tr class="ygtvrow">';for(var i=0;i<this.depth;++i){sb[sb.length]='<td class="ygtvcell '+this.getDepthStyle(i)+'"><div class="ygtvspacer"></div></td>'}if(this.hasIcon){sb[sb.length]='<td id="'+this.getToggleElId();sb[sb.length]='" class="ygtvcell ';sb[sb.length]=this.getStyle();sb[sb.length]='"><a href="#" class="ygtvspacer">&#160;</a></td>'}sb[sb.length]='<td id="'+this.contentElId;sb[sb.length]='" class="ygtvcell ';sb[sb.length]=this.contentStyle+' ygtvcontent" ';sb[sb.length]=(this.nowrap)?' nowrap="nowrap" ':'';sb[sb.length]=' >';sb[sb.length]=this.getContentHtml();sb[sb.length]='</td></tr></table>';return sb.join("")},getContentHtml:function(){return""},refresh:function(){this.getChildrenEl().innerHTML=this.completeRender();if(this.hasIcon){var el=this.getToggleEl();if(el){el.className=el.className.replace(/\bygtv[lt][nmp]h*\b/gi,this.getStyle())}}},toString:function(){return this._type+" ("+this.index+")"},_focusHighlightedItems:[],_focusedItem:null,_canHaveFocus:function(){return this.getEl().getElementsByTagName('a').length>0},_removeFocus:function(){if(this._focusedItem){Event.removeListener(this._focusedItem,'blur');this._focusedItem=null}var el;while((el=this._focusHighlightedItems.shift())){Dom.removeClass(el,YAHOO.widget.TreeView.FOCUS_CLASS_NAME)}},focus:function(){var focused=false,self=this;if(this.tree.currentFocus){this.tree.currentFocus._removeFocus()}var expandParent=function(node){if(node.parent){expandParent(node.parent);node.parent.expand()}};expandParent(this);Dom.getElementsBy(function(el){return(/ygtv(([tl][pmn]h?)|(content))/).test(el.className)},'td',self.getEl().firstChild,function(el){Dom.addClass(el,YAHOO.widget.TreeView.FOCUS_CLASS_NAME);if(!focused){var aEl=el.getElementsByTagName('a');if(aEl.length){aEl=aEl[0];aEl.focus();self._focusedItem=aEl;Event.on(aEl,'blur',function(){self.tree.fireEvent('focusChanged',{oldNode:self.tree.currentFocus,newNode:null});self.tree.currentFocus=null;self._removeFocus()});focused=true}}self._focusHighlightedItems.push(el)});if(focused){this.tree.fireEvent('focusChanged',{oldNode:this.tree.currentFocus,newNode:this});this.tree.currentFocus=this}else{this.tree.fireEvent('focusChanged',{oldNode:self.tree.currentFocus,newNode:null});this.tree.currentFocus=null;this._removeFocus()}return focused},getNodeCount:function(){for(var i=0,count=0;i<this.children.length;i++){count+=this.children[i].getNodeCount()}return count+1},getNodeDefinition:function(){if(this.isDynamic()){return false}var def,defs=Lang.merge(this.data),children=[];if(this.expanded){defs.expanded=this.expanded}if(!this.multiExpand){defs.multiExpand=this.multiExpand}if(this.renderHidden){defs.renderHidden=this.renderHidden}if(!this.hasIcon){defs.hasIcon=this.hasIcon}if(this.nowrap){defs.nowrap=this.nowrap}if(this.className){defs.className=this.className}if(this.editable){defs.editable=this.editable}if(!this.enableHighlight){defs.enableHighlight=this.enableHighlight}if(this.highlightState){defs.highlightState=this.highlightState}if(this.propagateHighlightUp){defs.propagateHighlightUp=this.propagateHighlightUp}if(this.propagateHighlightDown){defs.propagateHighlightDown=this.propagateHighlightDown}defs.type=this._type;for(var i=0;i<this.children.length;i++){def=this.children[i].getNodeDefinition();if(def===false){return false}children.push(def)}if(children.length){defs.children=children}return defs},getToggleLink:function(){return'return false;'},setNodesProperty:function(name,value,refresh){if(name.charAt(0)!='_'&&!Lang.isUndefined(this[name])&&!Lang.isFunction(this[name])){this[name]=value}else{this.data[name]=value}for(var i=0;i<this.children.length;i++){this.children[i].setNodesProperty(name,value)}if(refresh){this.refresh()}},toggleHighlight:function(){if(this.enableHighlight){if(this.highlightState==1){this.unhighlight()}else{this.highlight()}}},highlight:function(_silent){if(this.enableHighlight){if(this.tree.singleNodeHighlight){if(this.tree._currentlyHighlighted){this.tree._currentlyHighlighted.unhighlight(_silent)}this.tree._currentlyHighlighted=this}this.highlightState=1;this._setHighlightClassName();if(!this.tree.singleNodeHighlight){if(this.propagateHighlightDown){for(var i=0;i<this.children.length;i++){this.children[i].highlight(true)}}if(this.propagateHighlightUp){if(this.parent){this.parent._childrenHighlighted()}}}if(!_silent){this.tree.fireEvent('highlightEvent',this)}}},unhighlight:function(_silent){if(this.enableHighlight){this.tree._currentlyHighlighted=null;this.highlightState=0;this._setHighlightClassName();if(!this.tree.singleNodeHighlight){if(this.propagateHighlightDown){for(var i=0;i<this.children.length;i++){this.children[i].unhighlight(true)}}if(this.propagateHighlightUp){if(this.parent){this.parent._childrenHighlighted()}}}if(!_silent){this.tree.fireEvent('highlightEvent',this)}}},_childrenHighlighted:function(){var yes=false,no=false;if(this.enableHighlight){for(var i=0;i<this.children.length;i++){switch(this.children[i].highlightState){case 0:no=true;break;case 1:yes=true;break;case 2:yes=no=true;break}}if(yes&&no){this.highlightState=2}else if(yes){this.highlightState=1}else{this.highlightState=0}this._setHighlightClassName();if(this.propagateHighlightUp){if(this.parent){this.parent._childrenHighlighted()}}}},_setHighlightClassName:function(){var el=Dom.get('ygtvtableel'+this.index);if(el){el.className=el.className.replace(/\bygtv-highlight\d\b/gi,'ygtv-highlight'+this.highlightState)}}};YAHOO.augment(YAHOO.widget.Node,YAHOO.util.EventProvider)})();YAHOO.widget.RootNode=function(oTree){this.init(null,null,true);this.tree=oTree};YAHOO.extend(YAHOO.widget.RootNode,YAHOO.widget.Node,{_type:"RootNode",getNodeHtml:function(){return""},toString:function(){return this._type},loadComplete:function(){this.tree.draw()},getNodeCount:function(){for(var i=0,count=0;i<this.children.length;i++){count+=this.children[i].getNodeCount()}return count},getNodeDefinition:function(){for(var def,defs=[],i=0;i<this.children.length;i++){def=this.children[i].getNodeDefinition();if(def===false){return false}defs.push(def)}return defs},collapse:function(){},expand:function(){},getSiblings:function(){return null},focus:function(){}});(function(){var Dom=YAHOO.util.Dom,Lang=YAHOO.lang,Event=YAHOO.util.Event;YAHOO.widget.TextNode=function(oData,oParent,expanded){if(oData){if(Lang.isString(oData)){oData={label:oData}}this.init(oData,oParent,expanded);this.setUpLabel(oData)}};YAHOO.extend(YAHOO.widget.TextNode,YAHOO.widget.Node,{labelStyle:"ygtvlabel",labelElId:null,label:null,title:null,href:null,target:"_self",_type:"TextNode",setUpLabel:function(oData){if(Lang.isString(oData)){oData={label:oData}}else{if(oData.style){this.labelStyle=oData.style}}this.label=oData.label;this.labelElId="ygtvlabelel"+this.index},getLabelEl:function(){return Dom.get(this.labelElId)},getContentHtml:function(){var sb=[];sb[sb.length]=this.href?'<a':'<span';sb[sb.length]=' id="'+Lang.escapeHTML(this.labelElId)+'"';sb[sb.length]=' class="'+Lang.escapeHTML(this.labelStyle)+'"';if(this.href){sb[sb.length]=' href="'+Lang.escapeHTML(this.href)+'"';sb[sb.length]=' target="'+Lang.escapeHTML(this.target)+'"'}if(this.title){sb[sb.length]=' title="'+Lang.escapeHTML(this.title)+'"'}sb[sb.length]=' >';sb[sb.length]=Lang.escapeHTML(this.label);sb[sb.length]=this.href?'</a>':'</span>';return sb.join("")},getNodeDefinition:function(){var def=YAHOO.widget.TextNode.superclass.getNodeDefinition.call(this);if(def===false){return false}def.label=this.label;if(this.labelStyle!='ygtvlabel'){def.style=this.labelStyle}if(this.title){def.title=this.title}if(this.href){def.href=this.href}if(this.target!='_self'){def.target=this.target}return def},toString:function(){return YAHOO.widget.TextNode.superclass.toString.call(this)+": "+this.label},onLabelClick:function(){return false},refresh:function(){YAHOO.widget.TextNode.superclass.refresh.call(this);var label=this.getLabelEl();label.innerHTML=this.label;if(label.tagName.toUpperCase()=='A'){label.href=this.href;label.target=this.target}}})})();YAHOO.widget.MenuNode=function(oData,oParent,expanded){YAHOO.widget.MenuNode.superclass.constructor.call(this,oData,oParent,expanded);this.multiExpand=false};YAHOO.extend(YAHOO.widget.MenuNode,YAHOO.widget.TextNode,{_type:"MenuNode"});(function(){var Dom=YAHOO.util.Dom,Lang=YAHOO.lang,Event=YAHOO.util.Event;var HN=function(oData,oParent,expanded,hasIcon){if(oData){this.init(oData,oParent,expanded);this.initContent(oData,hasIcon)}};YAHOO.widget.HTMLNode=HN;YAHOO.extend(HN,YAHOO.widget.Node,{contentStyle:"ygtvhtml",html:null,_type:"HTMLNode",initContent:function(oData,hasIcon){this.setHtml(oData);this.contentElId="ygtvcontentel"+this.index;if(!Lang.isUndefined(hasIcon)){this.hasIcon=hasIcon}},setHtml:function(o){this.html=(Lang.isObject(o)&&'html'in o)?o.html:o;var el=this.getContentEl();if(el){if(o.nodeType&&o.nodeType==1&&o.tagName){el.innerHTML=""}else{el.innerHTML=this.html}}},getContentHtml:function(){if(typeof this.html==="string"){return this.html}else{HN._deferredNodes.push(this);if(!HN._timer){HN._timer=window.setTimeout(function(){var n;while((n=HN._deferredNodes.pop())){n.getContentEl().appendChild(n.html)}HN._timer=null},0)}return""}},getNodeDefinition:function(){var def=HN.superclass.getNodeDefinition.call(this);if(def===false){return false}def.html=this.html;return def}});HN._deferredNodes=[];HN._timer=null})();(function(){var Dom=YAHOO.util.Dom,Lang=YAHOO.lang,Event=YAHOO.util.Event,Calendar=YAHOO.widget.Calendar;YAHOO.widget.DateNode=function(oData,oParent,expanded){YAHOO.widget.DateNode.superclass.constructor.call(this,oData,oParent,expanded)};YAHOO.extend(YAHOO.widget.DateNode,YAHOO.widget.TextNode,{_type:"DateNode",calendarConfig:null,fillEditorContainer:function(editorData){var cal,container=editorData.inputContainer;if(Lang.isUndefined(Calendar)){Dom.replaceClass(editorData.editorPanel,'ygtv-edit-DateNode','ygtv-edit-TextNode');YAHOO.widget.DateNode.superclass.fillEditorContainer.call(this,editorData);return}if(editorData.nodeType!=this._type){editorData.nodeType=this._type;editorData.saveOnEnter=false;editorData.node.destroyEditorContents(editorData);editorData.inputObject=cal=new Calendar(container.appendChild(document.createElement('div')));if(this.calendarConfig){cal.cfg.applyConfig(this.calendarConfig,true);cal.cfg.fireQueue()}cal.selectEvent.subscribe(function(){this.tree._closeEditor(true)},this,true)}else{cal=editorData.inputObject}editorData.oldValue=this.label;cal.cfg.setProperty("selected",this.label,false);var delim=cal.cfg.getProperty('DATE_FIELD_DELIMITER');var pageDate=this.label.split(delim);cal.cfg.setProperty('pagedate',pageDate[cal.cfg.getProperty('MDY_MONTH_POSITION')-1]+delim+pageDate[cal.cfg.getProperty('MDY_YEAR_POSITION')-1]);cal.cfg.fireQueue();cal.render();cal.oDomContainer.focus()},getEditorValue:function(editorData){if(Lang.isUndefined(Calendar)){return editorData.inputElement.value}else{var cal=editorData.inputObject,date=cal.getSelectedDates()[0],dd=[];dd[cal.cfg.getProperty('MDY_DAY_POSITION')-1]=date.getDate();dd[cal.cfg.getProperty('MDY_MONTH_POSITION')-1]=date.getMonth()+1;dd[cal.cfg.getProperty('MDY_YEAR_POSITION')-1]=date.getFullYear();return dd.join(cal.cfg.getProperty('DATE_FIELD_DELIMITER'))}},displayEditedValue:function(value,editorData){var node=editorData.node;node.label=value;node.getLabelEl().innerHTML=value},getNodeDefinition:function(){var def=YAHOO.widget.DateNode.superclass.getNodeDefinition.call(this);if(def===false){return false}if(this.calendarConfig){def.calendarConfig=this.calendarConfig}return def}})})();(function(){var Dom=YAHOO.util.Dom,Lang=YAHOO.lang,Event=YAHOO.util.Event,TV=YAHOO.widget.TreeView,TVproto=TV.prototype;TV.editorData={active:false,whoHasIt:null,nodeType:null,editorPanel:null,inputContainer:null,buttonsContainer:null,node:null,saveOnEnter:true,oldValue:undefined};TVproto.validator=null;TVproto._initEditor=function(){this.createEvent("editorSaveEvent",this);this.createEvent("editorCancelEvent",this)};TVproto._nodeEditing=function(node){if(node.fillEditorContainer&&node.editable){var ed,topLeft,buttons,button,editorData=TV.editorData;editorData.active=true;editorData.whoHasIt=this;if(!editorData.nodeType){editorData.editorPanel=ed=this.getEl().appendChild(document.createElement('div'));Dom.addClass(ed,'ygtv-label-editor');ed.tabIndex=0;buttons=editorData.buttonsContainer=ed.appendChild(document.createElement('div'));Dom.addClass(buttons,'ygtv-button-container');button=buttons.appendChild(document.createElement('button'));Dom.addClass(button,'ygtvok');button.innerHTML=' ';button=buttons.appendChild(document.createElement('button'));Dom.addClass(button,'ygtvcancel');button.innerHTML=' ';Event.on(buttons,'click',function(ev){var target=Event.getTarget(ev),editorData=TV.editorData,node=editorData.node,self=editorData.whoHasIt;if(Dom.hasClass(target,'ygtvok')){Event.stopEvent(ev);self._closeEditor(true)}if(Dom.hasClass(target,'ygtvcancel')){Event.stopEvent(ev);self._closeEditor(false)}});editorData.inputContainer=ed.appendChild(document.createElement('div'));Dom.addClass(editorData.inputContainer,'ygtv-input');Event.on(ed,'keydown',function(ev){var editorData=TV.editorData,KEY=YAHOO.util.KeyListener.KEY,self=editorData.whoHasIt;switch(ev.keyCode){case KEY.ENTER:Event.stopEvent(ev);if(editorData.saveOnEnter){self._closeEditor(true)}break;case KEY.ESCAPE:Event.stopEvent(ev);self._closeEditor(false);break}})}else{ed=editorData.editorPanel}editorData.node=node;if(editorData.nodeType){Dom.removeClass(ed,'ygtv-edit-'+editorData.nodeType)}Dom.addClass(ed,' ygtv-edit-'+node._type);Dom.setStyle(ed,'display','block');Dom.setXY(ed,Dom.getXY(node.getContentEl()));ed.focus();node.fillEditorContainer(editorData);return true}};TVproto.onEventEditNode=function(oArgs){if(oArgs instanceof YAHOO.widget.Node){oArgs.editNode()}else if(oArgs.node instanceof YAHOO.widget.Node){oArgs.node.editNode()}return false};TVproto._closeEditor=function(save){var ed=TV.editorData,node=ed.node,close=true;if(!node||!ed.active){return}if(save){close=ed.node.saveEditorValue(ed)!==false}else{this.fireEvent('editorCancelEvent',node)}if(close){Dom.setStyle(ed.editorPanel,'display','none');ed.active=false;node.focus()}};TVproto._destroyEditor=function(){var ed=TV.editorData;if(ed&&ed.nodeType&&(!ed.active||ed.whoHasIt===this)){Event.removeListener(ed.editorPanel,'keydown');Event.removeListener(ed.buttonContainer,'click');ed.node.destroyEditorContents(ed);document.body.removeChild(ed.editorPanel);ed.nodeType=ed.editorPanel=ed.inputContainer=ed.buttonsContainer=ed.whoHasIt=ed.node=null;ed.active=false}};var Nproto=YAHOO.widget.Node.prototype;Nproto.editable=false;Nproto.editNode=function(){this.tree._nodeEditing(this)};Nproto.fillEditorContainer=null;Nproto.destroyEditorContents=function(editorData){Event.purgeElement(editorData.inputContainer,true);editorData.inputContainer.innerHTML=''};Nproto.saveEditorValue=function(editorData){var node=editorData.node,value,validator=node.tree.validator;value=this.getEditorValue(editorData);if(Lang.isFunction(validator)){value=validator(value,editorData.oldValue,node);if(Lang.isUndefined(value)){return false}}if(this.tree.fireEvent('editorSaveEvent',{newValue:value,oldValue:editorData.oldValue,node:node})!==false){this.displayEditedValue(value,editorData)}};Nproto.getEditorValue=function(editorData){};Nproto.displayEditedValue=function(value,editorData){};var TNproto=YAHOO.widget.TextNode.prototype;TNproto.fillEditorContainer=function(editorData){var input;if(editorData.nodeType!=this._type){editorData.nodeType=this._type;editorData.saveOnEnter=true;editorData.node.destroyEditorContents(editorData);editorData.inputElement=input=editorData.inputContainer.appendChild(document.createElement('input'))}else{input=editorData.inputElement}editorData.oldValue=this.label;input.value=this.label;input.focus();input.select()};TNproto.getEditorValue=function(editorData){return editorData.inputElement.value};TNproto.displayEditedValue=function(value,editorData){var node=editorData.node;node.label=value;node.getLabelEl().innerHTML=value};TNproto.destroyEditorContents=function(editorData){editorData.inputContainer.innerHTML=''}})();YAHOO.widget.TVAnim=function(){return{FADE_IN:"TVFadeIn",FADE_OUT:"TVFadeOut",getAnim:function(type,el,callback){if(YAHOO.widget[type]){return new YAHOO.widget[type](el,callback)}else{return null}},isValid:function(type){return(YAHOO.widget[type])}}}();YAHOO.widget.TVFadeIn=function(el,callback){this.el=el;this.callback=callback};YAHOO.widget.TVFadeIn.prototype={animate:function(){var tvanim=this;var s=this.el.style;s.opacity=0.1;s.filter="alpha(opacity=10)";s.display="";var dur=0.4;var a=new YAHOO.util.Anim(this.el,{opacity:{from:0.1,to:1,unit:""}},dur);a.onComplete.subscribe(function(){tvanim.onComplete()});a.animate()},onComplete:function(){this.callback()},toString:function(){return"TVFadeIn"}};YAHOO.widget.TVFadeOut=function(el,callback){this.el=el;this.callback=callback};YAHOO.widget.TVFadeOut.prototype={animate:function(){var tvanim=this;var dur=0.4;var a=new YAHOO.util.Anim(this.el,{opacity:{from:1,to:0.1,unit:""}},dur);a.onComplete.subscribe(function(){tvanim.onComplete()});a.animate()},onComplete:function(){var s=this.el.style;s.display="none";s.opacity=1;s.filter="alpha(opacity=100)";this.callback()},toString:function(){return"TVFadeOut"}};YAHOO.register("treeview",YAHOO.widget.TreeView,{version:"2.9.0",build:"2800"});
143   -//
144   -//../pacotes/yui290/build/button/button-min.js
145   -/*
146   -Copyright (c) 2011, Yahoo! Inc. All rights reserved.
147   -Code licensed under the BSD License:
148   -http://developer.yahoo.com/yui/license.html
149   -version: 2.9.0
150   -*/
151   -(function(){var G=YAHOO.util.Dom,M=YAHOO.util.Event,I=YAHOO.lang,L=YAHOO.env.ua,B=YAHOO.widget.Overlay,J=YAHOO.widget.Menu,D={},K=null,E=null,C=null;function F(O,N,R,P){var S,Q;if(I.isString(O)&&I.isString(N)){if(L.ie&&(L.ie<9)){Q='<input type="'+O+'" name="'+N+'"';if(P){Q+=" checked";}Q+=">";S=document.createElement(Q);S.value=R;}else{S=document.createElement("input");S.name=N;S.type=O;S.value=R;if(P){S.checked=true;}}}return S;}function H(O,V){var N=O.nodeName.toUpperCase(),S=(this.CLASS_NAME_PREFIX+this.CSS_CLASS_NAME),T=this,U,P,Q;function W(X){if(!(X in V)){U=O.getAttributeNode(X);if(U&&("value" in U)){V[X]=U.value;}}}function R(){W("type");if(V.type=="button"){V.type="push";}if(!("disabled" in V)){V.disabled=O.disabled;}W("name");W("value");W("title");}switch(N){case"A":V.type="link";W("href");W("target");break;case"INPUT":R();if(!("checked" in V)){V.checked=O.checked;}break;case"BUTTON":R();P=O.parentNode.parentNode;if(G.hasClass(P,S+"-checked")){V.checked=true;}if(G.hasClass(P,S+"-disabled")){V.disabled=true;}O.removeAttribute("value");O.setAttribute("type","button");break;}O.removeAttribute("id");O.removeAttribute("name");if(!("tabindex" in V)){V.tabindex=O.tabIndex;}if(!("label" in V)){Q=N=="INPUT"?O.value:O.innerHTML;if(Q&&Q.length>0){V.label=Q;}}}function A(P){var O=P.attributes,N=O.srcelement,R=N.nodeName.toUpperCase(),Q=this;if(R==this.NODE_NAME){P.element=N;P.id=N.id;G.getElementsBy(function(S){switch(S.nodeName.toUpperCase()){case"BUTTON":case"A":case"INPUT":H.call(Q,S,O);break;}},"*",N);}else{switch(R){case"BUTTON":case"A":case"INPUT":H.call(this,N,O);break;}}}YAHOO.widget.Button=function(R,O){if(!B&&YAHOO.widget.Overlay){B=YAHOO.widget.Overlay;}if(!J&&YAHOO.widget.Menu){J=YAHOO.widget.Menu;}var Q=YAHOO.widget.Button.superclass.constructor,P,N;if(arguments.length==1&&!I.isString(R)&&!R.nodeName){if(!R.id){R.id=G.generateId();}Q.call(this,(this.createButtonElement(R.type)),R);}else{P={element:null,attributes:(O||{})};if(I.isString(R)){N=G.get(R);if(N){if(!P.attributes.id){P.attributes.id=R;}P.attributes.srcelement=N;A.call(this,P);if(!P.element){P.element=this.createButtonElement(P.attributes.type);}Q.call(this,P.element,P.attributes);}}else{if(R.nodeName){if(!P.attributes.id){if(R.id){P.attributes.id=R.id;}else{P.attributes.id=G.generateId();}}P.attributes.srcelement=R;A.call(this,P);if(!P.element){P.element=this.createButtonElement(P.attributes.type);}Q.call(this,P.element,P.attributes);}}}};YAHOO.extend(YAHOO.widget.Button,YAHOO.util.Element,{_button:null,_menu:null,_hiddenFields:null,_onclickAttributeValue:null,_activationKeyPressed:false,_activationButtonPressed:false,_hasKeyEventHandlers:false,_hasMouseEventHandlers:false,_nOptionRegionX:0,CLASS_NAME_PREFIX:"yui-",NODE_NAME:"SPAN",CHECK_ACTIVATION_KEYS:[32],ACTIVATION_KEYS:[13,32],OPTION_AREA_WIDTH:20,CSS_CLASS_NAME:"button",_setType:function(N){if(N=="split"){this.on("option",this._onOption);}},_setLabel:function(O){this._button.innerHTML=O;var P,N=L.gecko;if(N&&N<1.9&&G.inDocument(this.get("element"))){P=(this.CLASS_NAME_PREFIX+this.CSS_CLASS_NAME);this.removeClass(P);I.later(0,this,this.addClass,P);}},_setTabIndex:function(N){this._button.tabIndex=N;},_setTitle:function(N){if(this.get("type")!="link"){this._button.title=N;}},_setDisabled:function(N){if(this.get("type")!="link"){if(N){if(this._menu){this._menu.hide();}if(this.hasFocus()){this.blur();}this._button.setAttribute("disabled","disabled");this.addStateCSSClasses("disabled");this.removeStateCSSClasses("hover");this.removeStateCSSClasses("active");this.removeStateCSSClasses("focus");}else{this._button.removeAttribute("disabled");this.removeStateCSSClasses("disabled");}}},_setHref:function(N){if(this.get("type")=="link"){this._button.href=N;}},_setTarget:function(N){if(this.get("type")=="link"){this._button.setAttribute("target",N);}},_setChecked:function(N){var O=this.get("type");if(O=="checkbox"||O=="radio"){if(N){this.addStateCSSClasses("checked");}else{this.removeStateCSSClasses("checked");}}},_setMenu:function(U){var P=this.get("lazyloadmenu"),R=this.get("element"),N,W=false,X,O,Q;function V(){X.render(R.parentNode);this.removeListener("appendTo",V);}function T(){X.cfg.queueProperty("container",R.parentNode);this.removeListener("appendTo",T);}function S(){var Y;if(X){G.addClass(X.element,this.get("menuclassname"));G.addClass(X.element,this.CLASS_NAME_PREFIX+this.get("type")+"-button-menu");X.showEvent.subscribe(this._onMenuShow,null,this);X.hideEvent.subscribe(this._onMenuHide,null,this);X.renderEvent.subscribe(this._onMenuRender,null,this);if(J&&X instanceof J){if(P){Y=this.get("container");if(Y){X.cfg.queueProperty("container",Y);}else{this.on("appendTo",T);}}X.cfg.queueProperty("clicktohide",false);X.keyDownEvent.subscribe(this._onMenuKeyDown,this,true);X.subscribe("click",this._onMenuClick,this,true);this.on("selectedMenuItemChange",this._onSelectedMenuItemChange);Q=X.srcElement;if(Q&&Q.nodeName.toUpperCase()=="SELECT"){Q.style.display="none";Q.parentNode.removeChild(Q);}}else{if(B&&X instanceof B){if(!K){K=new YAHOO.widget.OverlayManager();}K.register(X);}}this._menu=X;if(!W&&!P){if(G.inDocument(R)){X.render(R.parentNode);}else{this.on("appendTo",V);}}}}if(B){if(J){N=J.prototype.CSS_CLASS_NAME;}if(U&&J&&(U instanceof J)){X=U;W=true;S.call(this);}else{if(B&&U&&(U instanceof B)){X=U;W=true;X.cfg.queueProperty("visible",false);S.call(this);}else{if(J&&I.isArray(U)){X=new J(G.generateId(),{lazyload:P,itemdata:U});this._menu=X;this.on("appendTo",S);}else{if(I.isString(U)){O=G.get(U);if(O){if(J&&G.hasClass(O,N)||O.nodeName.toUpperCase()=="SELECT"){X=new J(U,{lazyload:P});S.call(this);}else{if(B){X=new B(U,{visible:false});S.call(this);}}}}else{if(U&&U.nodeName){if(J&&G.hasClass(U,N)||U.nodeName.toUpperCase()=="SELECT"){X=new J(U,{lazyload:P});S.call(this);}else{if(B){if(!U.id){G.generateId(U);}X=new B(U,{visible:false});S.call(this);}}}}}}}}},_setOnClick:function(N){if(this._onclickAttributeValue&&(this._onclickAttributeValue!=N)){this.removeListener("click",this._onclickAttributeValue.fn);
152   -this._onclickAttributeValue=null;}if(!this._onclickAttributeValue&&I.isObject(N)&&I.isFunction(N.fn)){this.on("click",N.fn,N.obj,N.scope);this._onclickAttributeValue=N;}},_isActivationKey:function(N){var S=this.get("type"),O=(S=="checkbox"||S=="radio")?this.CHECK_ACTIVATION_KEYS:this.ACTIVATION_KEYS,Q=O.length,R=false,P;if(Q>0){P=Q-1;do{if(N==O[P]){R=true;break;}}while(P--);}return R;},_isSplitButtonOptionKey:function(P){var O=(M.getCharCode(P)==40);var N=function(Q){M.preventDefault(Q);this.removeListener("keypress",N);};if(O){if(L.opera){this.on("keypress",N);}M.preventDefault(P);}return O;},_addListenersToForm:function(){var T=this.getForm(),S=YAHOO.widget.Button.onFormKeyPress,R,N,Q,P,O;if(T){M.on(T,"reset",this._onFormReset,null,this);M.on(T,"submit",this._onFormSubmit,null,this);N=this.get("srcelement");if(this.get("type")=="submit"||(N&&N.type=="submit")){Q=M.getListeners(T,"keypress");R=false;if(Q){P=Q.length;if(P>0){O=P-1;do{if(Q[O].fn==S){R=true;break;}}while(O--);}}if(!R){M.on(T,"keypress",S);}}}},_showMenu:function(R){if(YAHOO.widget.MenuManager){YAHOO.widget.MenuManager.hideVisible();}if(K){K.hideAll();}var N=this._menu,Q=this.get("menualignment"),P=this.get("focusmenu"),O;if(this._renderedMenu){N.cfg.setProperty("context",[this.get("element"),Q[0],Q[1]]);N.cfg.setProperty("preventcontextoverlap",true);N.cfg.setProperty("constraintoviewport",true);}else{N.cfg.queueProperty("context",[this.get("element"),Q[0],Q[1]]);N.cfg.queueProperty("preventcontextoverlap",true);N.cfg.queueProperty("constraintoviewport",true);}this.focus();if(J&&N&&(N instanceof J)){O=N.focus;N.focus=function(){};if(this._renderedMenu){N.cfg.setProperty("minscrollheight",this.get("menuminscrollheight"));N.cfg.setProperty("maxheight",this.get("menumaxheight"));}else{N.cfg.queueProperty("minscrollheight",this.get("menuminscrollheight"));N.cfg.queueProperty("maxheight",this.get("menumaxheight"));}N.show();N.focus=O;N.align();if(R.type=="mousedown"){M.stopPropagation(R);}if(P){N.focus();}}else{if(B&&N&&(N instanceof B)){if(!this._renderedMenu){N.render(this.get("element").parentNode);}N.show();N.align();}}},_hideMenu:function(){var N=this._menu;if(N){N.hide();}},_onMouseOver:function(O){var Q=this.get("type"),N,P;if(Q==="split"){N=this.get("element");P=(G.getX(N)+(N.offsetWidth-this.OPTION_AREA_WIDTH));this._nOptionRegionX=P;}if(!this._hasMouseEventHandlers){if(Q==="split"){this.on("mousemove",this._onMouseMove);}this.on("mouseout",this._onMouseOut);this._hasMouseEventHandlers=true;}this.addStateCSSClasses("hover");if(Q==="split"&&(M.getPageX(O)>P)){this.addStateCSSClasses("hoveroption");}if(this._activationButtonPressed){this.addStateCSSClasses("active");}if(this._bOptionPressed){this.addStateCSSClasses("activeoption");}if(this._activationButtonPressed||this._bOptionPressed){M.removeListener(document,"mouseup",this._onDocumentMouseUp);}},_onMouseMove:function(N){var O=this._nOptionRegionX;if(O){if(M.getPageX(N)>O){this.addStateCSSClasses("hoveroption");}else{this.removeStateCSSClasses("hoveroption");}}},_onMouseOut:function(N){var O=this.get("type");this.removeStateCSSClasses("hover");if(O!="menu"){this.removeStateCSSClasses("active");}if(this._activationButtonPressed||this._bOptionPressed){M.on(document,"mouseup",this._onDocumentMouseUp,null,this);}if(O==="split"&&(M.getPageX(N)>this._nOptionRegionX)){this.removeStateCSSClasses("hoveroption");}},_onDocumentMouseUp:function(P){this._activationButtonPressed=false;this._bOptionPressed=false;var Q=this.get("type"),N,O;if(Q=="menu"||Q=="split"){N=M.getTarget(P);O=this._menu.element;if(N!=O&&!G.isAncestor(O,N)){this.removeStateCSSClasses((Q=="menu"?"active":"activeoption"));this._hideMenu();}}M.removeListener(document,"mouseup",this._onDocumentMouseUp);},_onMouseDown:function(P){var Q,O=true;function N(){this._hideMenu();this.removeListener("mouseup",N);}if((P.which||P.button)==1){if(!this.hasFocus()){I.later(0,this,this.focus);}Q=this.get("type");if(Q=="split"){if(M.getPageX(P)>this._nOptionRegionX){this.fireEvent("option",P);O=false;}else{this.addStateCSSClasses("active");this._activationButtonPressed=true;}}else{if(Q=="menu"){if(this.isActive()){this._hideMenu();this._activationButtonPressed=false;}else{this._showMenu(P);this._activationButtonPressed=true;}}else{this.addStateCSSClasses("active");this._activationButtonPressed=true;}}if(Q=="split"||Q=="menu"){this._hideMenuTimer=I.later(250,this,this.on,["mouseup",N]);}}return O;},_onMouseUp:function(P){this.inMouseDown=false;var Q=this.get("type"),N=this._hideMenuTimer,O=true;if(N){N.cancel();}if(Q=="checkbox"||Q=="radio"){if((P.which||P.button)!=1){return;}this.set("checked",!(this.get("checked")));}this._activationButtonPressed=false;if(Q!="menu"){this.removeStateCSSClasses("active");}if(Q=="split"&&M.getPageX(P)>this._nOptionRegionX){O=false;}return O;},_onFocus:function(O){var N;this.addStateCSSClasses("focus");if(this._activationKeyPressed){this.addStateCSSClasses("active");}C=this;if(!this._hasKeyEventHandlers){N=this._button;M.on(N,"blur",this._onBlur,null,this);M.on(N,"keydown",this._onKeyDown,null,this);M.on(N,"keyup",this._onKeyUp,null,this);this._hasKeyEventHandlers=true;}this.fireEvent("focus",O);},_onBlur:function(N){this.removeStateCSSClasses("focus");if(this.get("type")!="menu"){this.removeStateCSSClasses("active");}if(this._activationKeyPressed){M.on(document,"keyup",this._onDocumentKeyUp,null,this);}C=null;this.fireEvent("blur",N);},_onDocumentKeyUp:function(N){if(this._isActivationKey(M.getCharCode(N))){this._activationKeyPressed=false;M.removeListener(document,"keyup",this._onDocumentKeyUp);}},_onKeyDown:function(O){var N=this._menu;if(this.get("type")=="split"&&this._isSplitButtonOptionKey(O)){this.fireEvent("option",O);}else{if(this._isActivationKey(M.getCharCode(O))){if(this.get("type")=="menu"){this._showMenu(O);}else{this._activationKeyPressed=true;this.addStateCSSClasses("active");}}}if(N&&N.cfg.getProperty("visible")&&M.getCharCode(O)==27){N.hide();this.focus();}},_onKeyUp:function(N){var O;
153   -if(this._isActivationKey(M.getCharCode(N))){O=this.get("type");if(O=="checkbox"||O=="radio"){this.set("checked",!(this.get("checked")));}this._activationKeyPressed=false;if(this.get("type")!="menu"){this.removeStateCSSClasses("active");}}},_onClick:function(P){var R=this.get("type"),Q,N,O;switch(R){case"submit":if(P.returnValue!==false){this.submitForm();}break;case"reset":Q=this.getForm();if(Q){Q.reset();}break;case"split":if(this._nOptionRegionX>0&&(M.getPageX(P)>this._nOptionRegionX)){O=false;}else{this._hideMenu();N=this.get("srcelement");if(N&&N.type=="submit"&&P.returnValue!==false){this.submitForm();}}break;}return O;},_onDblClick:function(O){var N=true;if(this.get("type")=="split"&&M.getPageX(O)>this._nOptionRegionX){N=false;}return N;},_onAppendTo:function(N){I.later(0,this,this._addListenersToForm);},_onFormReset:function(O){var P=this.get("type"),N=this._menu;if(P=="checkbox"||P=="radio"){this.resetValue("checked");}if(J&&N&&(N instanceof J)){this.resetValue("selectedMenuItem");}},_onFormSubmit:function(N){this.createHiddenFields();},_onDocumentMouseDown:function(R){var O=M.getTarget(R),Q=this.get("element"),P=this._menu.element;function N(T){var V,S,U;if(!T){return true;}for(V=0,S=T.length;V<S;V++){U=T[V].element;if(O==U||G.isAncestor(U,O)){return true;}if(T[V]&&T[V].getSubmenus){if(N(T[V].getSubmenus())){return true;}}}return false;}if(O!=Q&&!G.isAncestor(Q,O)&&O!=P&&!G.isAncestor(P,O)){if(this._menu&&this._menu.getSubmenus){if(!N(this._menu.getSubmenus())){return;}}this._hideMenu();if(L.ie&&(L.ie<9)&&O.focus){O.setActive();}M.removeListener(document,"mousedown",this._onDocumentMouseDown);}},_onOption:function(N){if(this.hasClass(this.CLASS_NAME_PREFIX+"split-button-activeoption")){this._hideMenu();this._bOptionPressed=false;}else{this._showMenu(N);this._bOptionPressed=true;}},_onMenuShow:function(N){M.on(document,"mousedown",this._onDocumentMouseDown,null,this);var O=(this.get("type")=="split")?"activeoption":"active";this.addStateCSSClasses(O);},_onMenuHide:function(N){var O=(this.get("type")=="split")?"activeoption":"active";this.removeStateCSSClasses(O);if(this.get("type")=="split"){this._bOptionPressed=false;}},_onMenuKeyDown:function(P,O){var N=O[0];if(M.getCharCode(N)==27){this.focus();if(this.get("type")=="split"){this._bOptionPressed=false;}}},_onMenuRender:function(P){var S=this.get("element"),O=S.parentNode,N=this._menu,R=N.element,Q=N.srcElement,T;if(O!=R.parentNode){O.appendChild(R);}this._renderedMenu=true;if(Q&&Q.nodeName.toLowerCase()==="select"&&Q.value){T=N.getItem(Q.selectedIndex);this.set("selectedMenuItem",T,true);this._onSelectedMenuItemChange({newValue:T});}},_onMenuClick:function(O,N){var Q=N[1],P;if(Q){this.set("selectedMenuItem",Q);P=this.get("srcelement");if(P&&P.type=="submit"){this.submitForm();}this._hideMenu();}},_onSelectedMenuItemChange:function(O){var P=O.prevValue,Q=O.newValue,N=this.CLASS_NAME_PREFIX;if(P){G.removeClass(P.element,(N+"button-selectedmenuitem"));}if(Q){G.addClass(Q.element,(N+"button-selectedmenuitem"));}},_onLabelClick:function(N){this.focus();var O=this.get("type");if(O=="radio"||O=="checkbox"){this.set("checked",(!this.get("checked")));}},createButtonElement:function(N){var P=this.NODE_NAME,O=document.createElement(P);O.innerHTML="<"+P+' class="first-child">'+(N=="link"?"<a></a>":'<button type="button"></button>')+"</"+P+">";return O;},addStateCSSClasses:function(O){var P=this.get("type"),N=this.CLASS_NAME_PREFIX;if(I.isString(O)){if(O!="activeoption"&&O!="hoveroption"){this.addClass(N+this.CSS_CLASS_NAME+("-"+O));}this.addClass(N+P+("-button-"+O));}},removeStateCSSClasses:function(O){var P=this.get("type"),N=this.CLASS_NAME_PREFIX;if(I.isString(O)){this.removeClass(N+this.CSS_CLASS_NAME+("-"+O));this.removeClass(N+P+("-button-"+O));}},createHiddenFields:function(){this.removeHiddenFields();var V=this.getForm(),Z,O,S,X,Y,T,U,N,R,W,P,Q=false;if(V&&!this.get("disabled")){O=this.get("type");S=(O=="checkbox"||O=="radio");if((S&&this.get("checked"))||(E==this)){Z=F((S?O:"hidden"),this.get("name"),this.get("value"),this.get("checked"));if(Z){if(S){Z.style.display="none";}V.appendChild(Z);}}X=this._menu;if(J&&X&&(X instanceof J)){Y=this.get("selectedMenuItem");P=X.srcElement;Q=(P&&P.nodeName.toUpperCase()=="SELECT");if(Y){U=(Y.value===null||Y.value==="")?Y.cfg.getProperty("text"):Y.value;T=this.get("name");if(Q){W=P.name;}else{if(T){W=(T+"_options");}}if(U&&W){N=F("hidden",W,U);V.appendChild(N);}}else{if(Q){N=V.appendChild(P);}}}if(Z&&N){this._hiddenFields=[Z,N];}else{if(!Z&&N){this._hiddenFields=N;}else{if(Z&&!N){this._hiddenFields=Z;}}}R=this._hiddenFields;}return R;},removeHiddenFields:function(){var Q=this._hiddenFields,O,P;function N(R){if(G.inDocument(R)){R.parentNode.removeChild(R);}}if(Q){if(I.isArray(Q)){O=Q.length;if(O>0){P=O-1;do{N(Q[P]);}while(P--);}}else{N(Q);}this._hiddenFields=null;}},submitForm:function(){var Q=this.getForm(),P=this.get("srcelement"),O=false,N;if(Q){if(this.get("type")=="submit"||(P&&P.type=="submit")){E=this;}if(L.ie&&(L.ie<9)){O=Q.fireEvent("onsubmit");}else{N=document.createEvent("HTMLEvents");N.initEvent("submit",true,true);O=Q.dispatchEvent(N);}if((L.ie||L.webkit)&&O){Q.submit();}}return O;},init:function(P,d){var V=d.type=="link"?"a":"button",a=d.srcelement,S=P.getElementsByTagName(V)[0],U;if(!S){U=P.getElementsByTagName("input")[0];if(U){S=document.createElement("button");S.setAttribute("type","button");U.parentNode.replaceChild(S,U);}}this._button=S;YAHOO.widget.Button.superclass.init.call(this,P,d);var T=this.get("id"),Z=T+"-button";S.id=Z;var X,Q;var e=function(f){return(f.htmlFor===T);};var c=function(){Q.setAttribute((L.ie?"htmlFor":"for"),Z);};if(a&&this.get("type")!="link"){X=G.getElementsBy(e,"label");if(I.isArray(X)&&X.length>0){Q=X[0];}}D[T]=this;var b=this.CLASS_NAME_PREFIX;this.addClass(b+this.CSS_CLASS_NAME);this.addClass(b+this.get("type")+"-button");M.on(this._button,"focus",this._onFocus,null,this);this.on("mouseover",this._onMouseOver);this.on("mousedown",this._onMouseDown);
154   -this.on("mouseup",this._onMouseUp);this.on("click",this._onClick);var R=this.get("onclick");this.set("onclick",null);this.set("onclick",R);this.on("dblclick",this._onDblClick);var O;if(Q){if(this.get("replaceLabel")){this.set("label",Q.innerHTML);O=Q.parentNode;O.removeChild(Q);}else{this.on("appendTo",c);M.on(Q,"click",this._onLabelClick,null,this);this._label=Q;}}this.on("appendTo",this._onAppendTo);var N=this.get("container"),Y=this.get("element"),W=G.inDocument(Y);if(N){if(a&&a!=Y){O=a.parentNode;if(O){O.removeChild(a);}}if(I.isString(N)){M.onContentReady(N,this.appendTo,N,this);}else{this.on("init",function(){I.later(0,this,this.appendTo,N);});}}else{if(!W&&a&&a!=Y){O=a.parentNode;if(O){this.fireEvent("beforeAppendTo",{type:"beforeAppendTo",target:O});O.replaceChild(Y,a);this.fireEvent("appendTo",{type:"appendTo",target:O});}}else{if(this.get("type")!="link"&&W&&a&&a==Y){this._addListenersToForm();}}}this.fireEvent("init",{type:"init",target:this});},initAttributes:function(O){var N=O||{};YAHOO.widget.Button.superclass.initAttributes.call(this,N);this.setAttributeConfig("type",{value:(N.type||"push"),validator:I.isString,writeOnce:true,method:this._setType});this.setAttributeConfig("label",{value:N.label,validator:I.isString,method:this._setLabel});this.setAttributeConfig("value",{value:N.value});this.setAttributeConfig("name",{value:N.name,validator:I.isString});this.setAttributeConfig("tabindex",{value:N.tabindex,validator:I.isNumber,method:this._setTabIndex});this.configureAttribute("title",{value:N.title,validator:I.isString,method:this._setTitle});this.setAttributeConfig("disabled",{value:(N.disabled||false),validator:I.isBoolean,method:this._setDisabled});this.setAttributeConfig("href",{value:N.href,validator:I.isString,method:this._setHref});this.setAttributeConfig("target",{value:N.target,validator:I.isString,method:this._setTarget});this.setAttributeConfig("checked",{value:(N.checked||false),validator:I.isBoolean,method:this._setChecked});this.setAttributeConfig("container",{value:N.container,writeOnce:true});this.setAttributeConfig("srcelement",{value:N.srcelement,writeOnce:true});this.setAttributeConfig("menu",{value:null,method:this._setMenu,writeOnce:true});this.setAttributeConfig("lazyloadmenu",{value:(N.lazyloadmenu===false?false:true),validator:I.isBoolean,writeOnce:true});this.setAttributeConfig("menuclassname",{value:(N.menuclassname||(this.CLASS_NAME_PREFIX+"button-menu")),validator:I.isString,method:this._setMenuClassName,writeOnce:true});this.setAttributeConfig("menuminscrollheight",{value:(N.menuminscrollheight||90),validator:I.isNumber});this.setAttributeConfig("menumaxheight",{value:(N.menumaxheight||0),validator:I.isNumber});this.setAttributeConfig("menualignment",{value:(N.menualignment||["tl","bl"]),validator:I.isArray});this.setAttributeConfig("selectedMenuItem",{value:null});this.setAttributeConfig("onclick",{value:N.onclick,method:this._setOnClick});this.setAttributeConfig("focusmenu",{value:(N.focusmenu===false?false:true),validator:I.isBoolean});this.setAttributeConfig("replaceLabel",{value:false,validator:I.isBoolean,writeOnce:true});},focus:function(){if(!this.get("disabled")){try{this._button.focus();}catch(N){}}},blur:function(){if(!this.get("disabled")){try{this._button.blur();}catch(N){}}},hasFocus:function(){return(C==this);},isActive:function(){return this.hasClass(this.CLASS_NAME_PREFIX+this.CSS_CLASS_NAME+"-active");},getMenu:function(){return this._menu;},getForm:function(){var N=this._button,O;if(N){O=N.form;}return O;},getHiddenFields:function(){return this._hiddenFields;},destroy:function(){var P=this.get("element"),N=this._menu,T=this._label,O,S;if(N){if(K&&K.find(N)){K.remove(N);}N.destroy();}M.purgeElement(P);M.purgeElement(this._button);M.removeListener(document,"mouseup",this._onDocumentMouseUp);M.removeListener(document,"keyup",this._onDocumentKeyUp);M.removeListener(document,"mousedown",this._onDocumentMouseDown);if(T){M.removeListener(T,"click",this._onLabelClick);O=T.parentNode;O.removeChild(T);}var Q=this.getForm();if(Q){M.removeListener(Q,"reset",this._onFormReset);M.removeListener(Q,"submit",this._onFormSubmit);}this.unsubscribeAll();O=P.parentNode;if(O){O.removeChild(P);}delete D[this.get("id")];var R=(this.CLASS_NAME_PREFIX+this.CSS_CLASS_NAME);S=G.getElementsByClassName(R,this.NODE_NAME,Q);if(I.isArray(S)&&S.length===0){M.removeListener(Q,"keypress",YAHOO.widget.Button.onFormKeyPress);}},fireEvent:function(O,N){var P=arguments[0];if(this.DOM_EVENTS[P]&&this.get("disabled")){return false;}return YAHOO.widget.Button.superclass.fireEvent.apply(this,arguments);},toString:function(){return("Button "+this.get("id"));}});YAHOO.widget.Button.onFormKeyPress=function(R){var P=M.getTarget(R),S=M.getCharCode(R),Q=P.nodeName&&P.nodeName.toUpperCase(),N=P.type,T=false,V,X,O,W;function U(a){var Z,Y;switch(a.nodeName.toUpperCase()){case"INPUT":case"BUTTON":if(a.type=="submit"&&!a.disabled){if(!T&&!O){O=a;}}break;default:Z=a.id;if(Z){V=D[Z];if(V){T=true;if(!V.get("disabled")){Y=V.get("srcelement");if(!X&&(V.get("type")=="submit"||(Y&&Y.type=="submit"))){X=V;}}}}break;}}if(S==13&&((Q=="INPUT"&&(N=="text"||N=="password"||N=="checkbox"||N=="radio"||N=="file"))||Q=="SELECT")){G.getElementsBy(U,"*",this);if(O){O.focus();}else{if(!O&&X){M.preventDefault(R);if(L.ie){X.get("element").fireEvent("onclick");}else{W=document.createEvent("HTMLEvents");W.initEvent("click",true,true);if(L.gecko<1.9){X.fireEvent("click",W);}else{X.get("element").dispatchEvent(W);}}}}}};YAHOO.widget.Button.addHiddenFieldsToForm=function(N){var R=YAHOO.widget.Button.prototype,T=G.getElementsByClassName((R.CLASS_NAME_PREFIX+R.CSS_CLASS_NAME),"*",N),Q=T.length,S,O,P;if(Q>0){for(P=0;P<Q;P++){O=T[P].id;if(O){S=D[O];if(S){S.createHiddenFields();}}}}};YAHOO.widget.Button.getButton=function(N){return D[N];};})();(function(){var C=YAHOO.util.Dom,B=YAHOO.util.Event,D=YAHOO.lang,A=YAHOO.widget.Button,E={};YAHOO.widget.ButtonGroup=function(J,H){var I=YAHOO.widget.ButtonGroup.superclass.constructor,K,G,F;
155   -if(arguments.length==1&&!D.isString(J)&&!J.nodeName){if(!J.id){F=C.generateId();J.id=F;}I.call(this,(this._createGroupElement()),J);}else{if(D.isString(J)){G=C.get(J);if(G){if(G.nodeName.toUpperCase()==this.NODE_NAME){I.call(this,G,H);}}}else{K=J.nodeName.toUpperCase();if(K&&K==this.NODE_NAME){if(!J.id){J.id=C.generateId();}I.call(this,J,H);}}}};YAHOO.extend(YAHOO.widget.ButtonGroup,YAHOO.util.Element,{_buttons:null,NODE_NAME:"DIV",CLASS_NAME_PREFIX:"yui-",CSS_CLASS_NAME:"buttongroup",_createGroupElement:function(){var F=document.createElement(this.NODE_NAME);return F;},_setDisabled:function(G){var H=this.getCount(),F;if(H>0){F=H-1;do{this._buttons[F].set("disabled",G);}while(F--);}},_onKeyDown:function(K){var G=B.getTarget(K),I=B.getCharCode(K),H=G.parentNode.parentNode.id,J=E[H],F=-1;if(I==37||I==38){F=(J.index===0)?(this._buttons.length-1):(J.index-1);}else{if(I==39||I==40){F=(J.index===(this._buttons.length-1))?0:(J.index+1);}}if(F>-1){this.check(F);this.getButton(F).focus();}},_onAppendTo:function(H){var I=this._buttons,G=I.length,F;for(F=0;F<G;F++){I[F].appendTo(this.get("element"));}},_onButtonCheckedChange:function(G,F){var I=G.newValue,H=this.get("checkedButton");if(I&&H!=F){if(H){H.set("checked",false,true);}this.set("checkedButton",F);this.set("value",F.get("value"));}else{if(H&&!H.set("checked")){H.set("checked",true,true);}}},init:function(I,H){this._buttons=[];YAHOO.widget.ButtonGroup.superclass.init.call(this,I,H);this.addClass(this.CLASS_NAME_PREFIX+this.CSS_CLASS_NAME);var K=(YAHOO.widget.Button.prototype.CLASS_NAME_PREFIX+"radio-button"),J=this.getElementsByClassName(K);if(J.length>0){this.addButtons(J);}function F(L){return(L.type=="radio");}J=C.getElementsBy(F,"input",this.get("element"));if(J.length>0){this.addButtons(J);}this.on("keydown",this._onKeyDown);this.on("appendTo",this._onAppendTo);var G=this.get("container");if(G){if(D.isString(G)){B.onContentReady(G,function(){this.appendTo(G);},null,this);}else{this.appendTo(G);}}},initAttributes:function(G){var F=G||{};YAHOO.widget.ButtonGroup.superclass.initAttributes.call(this,F);this.setAttributeConfig("name",{value:F.name,validator:D.isString});this.setAttributeConfig("disabled",{value:(F.disabled||false),validator:D.isBoolean,method:this._setDisabled});this.setAttributeConfig("value",{value:F.value});this.setAttributeConfig("container",{value:F.container,writeOnce:true});this.setAttributeConfig("checkedButton",{value:null});},addButton:function(J){var L,K,G,F,H,I;if(J instanceof A&&J.get("type")=="radio"){L=J;}else{if(!D.isString(J)&&!J.nodeName){J.type="radio";L=new A(J);}else{L=new A(J,{type:"radio"});}}if(L){F=this._buttons.length;H=L.get("name");I=this.get("name");L.index=F;this._buttons[F]=L;E[L.get("id")]=L;if(H!=I){L.set("name",I);}if(this.get("disabled")){L.set("disabled",true);}if(L.get("checked")){this.set("checkedButton",L);}K=L.get("element");G=this.get("element");if(K.parentNode!=G){G.appendChild(K);}L.on("checkedChange",this._onButtonCheckedChange,L,this);}return L;},addButtons:function(G){var H,I,J,F;if(D.isArray(G)){H=G.length;J=[];if(H>0){for(F=0;F<H;F++){I=this.addButton(G[F]);if(I){J[J.length]=I;}}}}return J;},removeButton:function(H){var I=this.getButton(H),G,F;if(I){this._buttons.splice(H,1);delete E[I.get("id")];I.removeListener("checkedChange",this._onButtonCheckedChange);I.destroy();G=this._buttons.length;if(G>0){F=this._buttons.length-1;do{this._buttons[F].index=F;}while(F--);}}},getButton:function(F){return this._buttons[F];},getButtons:function(){return this._buttons;},getCount:function(){return this._buttons.length;},focus:function(H){var I,G,F;if(D.isNumber(H)){I=this._buttons[H];if(I){I.focus();}}else{G=this.getCount();for(F=0;F<G;F++){I=this._buttons[F];if(!I.get("disabled")){I.focus();break;}}}},check:function(F){var G=this.getButton(F);if(G){G.set("checked",true);}},destroy:function(){var I=this._buttons.length,H=this.get("element"),F=H.parentNode,G;if(I>0){G=this._buttons.length-1;do{this._buttons[G].destroy();}while(G--);}B.purgeElement(H);F.removeChild(H);},toString:function(){return("ButtonGroup "+this.get("id"));}});})();YAHOO.register("button",YAHOO.widget.Button,{version:"2.9.0",build:"2800"});
156   -//
157 141 //../pacotes/yui290/build/json/json-min.js
158 142 /*
159 143 Copyright (c) 2011, Yahoo! Inc. All rights reserved.
... ...
js/i3geo_tudo_compacto7.js.php 100755 → 100644
... ... @@ -138,22 +138,6 @@ version: 2.9.0
138 138 (function(){var b=YAHOO.util,c=b.Dom,i=b.Event,g=window.document,k="active",d="activeIndex",f="activeTab",e="disabled",a="contentEl",h="element",j=function(m,l){l=l||{};if(arguments.length==1&&!YAHOO.lang.isString(m)&&!m.nodeName){l=m;m=l.element||null;}if(!m&&!l.element){m=this._createTabViewElement(l);}j.superclass.constructor.call(this,m,l);};YAHOO.extend(j,b.Element,{CLASSNAME:"yui-navset",TAB_PARENT_CLASSNAME:"yui-nav",CONTENT_PARENT_CLASSNAME:"yui-content",_tabParent:null,_contentParent:null,addTab:function(n,o){var p=this.get("tabs"),s=this._tabParent,q=this._contentParent,l=n.get(h),m=n.get(a),t=this.get(d),r;if(!p){this._queue[this._queue.length]=["addTab",arguments];return false;}r=this.getTab(o);o=(o===undefined)?p.length:o;p.splice(o,0,n);if(r){s.insertBefore(l,r.get(h));if(m){q.appendChild(m);}}else{s.appendChild(l);if(m){q.appendChild(m);}}if(!n.get(k)){n.set("contentVisible",false,true);if(o<=t){this.set(d,t+1,true);}}else{this.set(f,n,true);this.set("activeIndex",o,true);}this._initTabEvents(n);},_initTabEvents:function(l){l.addListener(l.get("activationEvent"),l._onActivate,this,l);l.addListener("activationEventChange",l._onActivationEventChange,this,l);},_removeTabEvents:function(l){l.removeListener(l.get("activationEvent"),l._onActivate,this,l);l.removeListener("activationEventChange",l._onActivationEventChange,this,l);},DOMEventHandler:function(q){var r=i.getTarget(q),t=this._tabParent,s=this.get("tabs"),n,m,l;if(c.isAncestor(t,r)){for(var o=0,p=s.length;o<p;o++){m=s[o].get(h);l=s[o].get(a);if(r==m||c.isAncestor(m,r)){n=s[o];break;}}if(n){n.fireEvent(q.type,q);}}},getTab:function(l){return this.get("tabs")[l];},getTabIndex:function(p){var m=null,o=this.get("tabs");for(var n=0,l=o.length;n<l;++n){if(p==o[n]){m=n;break;}}return m;},removeTab:function(o){var n=this.get("tabs").length,l=this.get(d),m=this.getTabIndex(o);if(o===this.get(f)){if(n>1){if(m+1===n){this.set(d,m-1);}else{this.set(d,m+1);}}else{this.set(f,null);}}else{if(m<l){this.set(d,l-1,true);}}this._removeTabEvents(o);this._tabParent.removeChild(o.get(h));this._contentParent.removeChild(o.get(a));this._configs.tabs.value.splice(m,1);o.fireEvent("remove",{type:"remove",tabview:this});},toString:function(){var l=this.get("id")||this.get("tagName");return"TabView "+l;},contentTransition:function(m,l){if(m){m.set("contentVisible",true);}if(l){l.set("contentVisible",false);}},initAttributes:function(l){j.superclass.initAttributes.call(this,l);if(!l.orientation){l.orientation="top";}var n=this.get(h);if(!this.hasClass(this.CLASSNAME)){this.addClass(this.CLASSNAME);}this.setAttributeConfig("tabs",{value:[],readOnly:true});this._tabParent=this.getElementsByClassName(this.TAB_PARENT_CLASSNAME,"ul")[0]||this._createTabParent();this._contentParent=this.getElementsByClassName(this.CONTENT_PARENT_CLASSNAME,"div")[0]||this._createContentParent();this.setAttributeConfig("orientation",{value:l.orientation,method:function(o){var p=this.get("orientation");this.addClass("yui-navset-"+o);if(p!=o){this.removeClass("yui-navset-"+p);}if(o==="bottom"){this.appendChild(this._tabParent);}}});this.setAttributeConfig(d,{value:l.activeIndex,validator:function(q){var o=true,p;if(q){p=this.getTab(q);if(p&&p.get(e)){o=false;}}return o;}});this.setAttributeConfig(f,{value:l[f],method:function(p){var o=this.get(f);if(p){p.set(k,true);}if(o&&o!==p){o.set(k,false);}if(o&&p!==o){this.contentTransition(p,o);}else{if(p){p.set("contentVisible",true);}}},validator:function(p){var o=true;if(p&&p.get(e)){o=false;}return o;}});this.on("activeTabChange",this._onActiveTabChange);this.on("activeIndexChange",this._onActiveIndexChange);if(this._tabParent){this._initTabs();}this.DOM_EVENTS.submit=false;this.DOM_EVENTS.focus=false;this.DOM_EVENTS.blur=false;this.DOM_EVENTS.change=false;for(var m in this.DOM_EVENTS){if(YAHOO.lang.hasOwnProperty(this.DOM_EVENTS,m)){this.addListener.call(this,m,this.DOMEventHandler);}}},deselectTab:function(l){if(this.getTab(l)===this.get(f)){this.set(f,null);}},selectTab:function(l){this.set(f,this.getTab(l));},_onActiveTabChange:function(n){var l=this.get(d),m=this.getTabIndex(n.newValue);if(l!==m){if(!(this.set(d,m))){this.set(f,n.prevValue);}}},_onActiveIndexChange:function(l){if(l.newValue!==this.getTabIndex(this.get(f))){if(!(this.set(f,this.getTab(l.newValue)))){this.set(d,l.prevValue);}}},_initTabs:function(){var q=c.getChildren(this._tabParent),o=c.getChildren(this._contentParent),n=this.get(d),r,m,s;for(var p=0,l=q.length;p<l;++p){m={};if(o[p]){m.contentEl=o[p];}r=new YAHOO.widget.Tab(q[p],m);this.addTab(r);if(r.hasClass(r.ACTIVE_CLASSNAME)){s=r;}}if(n!=undefined){this.set(f,this.getTab(n));}else{this._configs[f].value=s;this._configs[d].value=this.getTabIndex(s);}},_createTabViewElement:function(l){var m=g.createElement("div");if(this.CLASSNAME){m.className=this.CLASSNAME;}return m;},_createTabParent:function(l){var m=g.createElement("ul");if(this.TAB_PARENT_CLASSNAME){m.className=this.TAB_PARENT_CLASSNAME;}this.get(h).appendChild(m);return m;},_createContentParent:function(l){var m=g.createElement("div");if(this.CONTENT_PARENT_CLASSNAME){m.className=this.CONTENT_PARENT_CLASSNAME;}this.get(h).appendChild(m);return m;}});YAHOO.widget.TabView=j;})();(function(){var d=YAHOO.util,i=d.Dom,l=YAHOO.lang,m="activeTab",j="label",g="labelEl",q="content",c="contentEl",o="element",p="cacheData",b="dataSrc",h="dataLoaded",a="dataTimeout",n="loadMethod",f="postData",k="disabled",e=function(s,r){r=r||{};if(arguments.length==1&&!l.isString(s)&&!s.nodeName){r=s;s=r.element;}if(!s&&!r.element){s=this._createTabElement(r);}this.loadHandler={success:function(t){this.set(q,t.responseText);},failure:function(t){}};e.superclass.constructor.call(this,s,r);this.DOM_EVENTS={};};YAHOO.extend(e,YAHOO.util.Element,{LABEL_TAGNAME:"em",ACTIVE_CLASSNAME:"selected",HIDDEN_CLASSNAME:"yui-hidden",ACTIVE_TITLE:"active",DISABLED_CLASSNAME:k,LOADING_CLASSNAME:"loading",dataConnection:null,loadHandler:null,_loading:false,toString:function(){var r=this.get(o),s=r.id||r.tagName;
139 139 return"Tab "+s;},initAttributes:function(r){r=r||{};e.superclass.initAttributes.call(this,r);this.setAttributeConfig("activationEvent",{value:r.activationEvent||"click"});this.setAttributeConfig(g,{value:r[g]||this._getLabelEl(),method:function(s){s=i.get(s);var t=this.get(g);if(t){if(t==s){return false;}t.parentNode.replaceChild(s,t);this.set(j,s.innerHTML);}}});this.setAttributeConfig(j,{value:r.label||this._getLabel(),method:function(t){var s=this.get(g);if(!s){this.set(g,this._createLabelEl());}s.innerHTML=t;}});this.setAttributeConfig(c,{value:r[c]||document.createElement("div"),method:function(s){s=i.get(s);var t=this.get(c);if(t){if(t===s){return false;}if(!this.get("selected")){i.addClass(s,this.HIDDEN_CLASSNAME);}t.parentNode.replaceChild(s,t);this.set(q,s.innerHTML);}}});this.setAttributeConfig(q,{value:r[q]||this.get(c).innerHTML,method:function(s){this.get(c).innerHTML=s;}});this.setAttributeConfig(b,{value:r.dataSrc});this.setAttributeConfig(p,{value:r.cacheData||false,validator:l.isBoolean});this.setAttributeConfig(n,{value:r.loadMethod||"GET",validator:l.isString});this.setAttributeConfig(h,{value:false,validator:l.isBoolean,writeOnce:true});this.setAttributeConfig(a,{value:r.dataTimeout||null,validator:l.isNumber});this.setAttributeConfig(f,{value:r.postData||null});this.setAttributeConfig("active",{value:r.active||this.hasClass(this.ACTIVE_CLASSNAME),method:function(s){if(s===true){this.addClass(this.ACTIVE_CLASSNAME);this.set("title",this.ACTIVE_TITLE);}else{this.removeClass(this.ACTIVE_CLASSNAME);this.set("title","");}},validator:function(s){return l.isBoolean(s)&&!this.get(k);}});this.setAttributeConfig(k,{value:r.disabled||this.hasClass(this.DISABLED_CLASSNAME),method:function(s){if(s===true){this.addClass(this.DISABLED_CLASSNAME);}else{this.removeClass(this.DISABLED_CLASSNAME);}},validator:l.isBoolean});this.setAttributeConfig("href",{value:r.href||this.getElementsByTagName("a")[0].getAttribute("href",2)||"#",method:function(s){this.getElementsByTagName("a")[0].href=s;},validator:l.isString});this.setAttributeConfig("contentVisible",{value:r.contentVisible,method:function(s){if(s){i.removeClass(this.get(c),this.HIDDEN_CLASSNAME);if(this.get(b)){if(!this._loading&&!(this.get(h)&&this.get(p))){this._dataConnect();}}}else{i.addClass(this.get(c),this.HIDDEN_CLASSNAME);}},validator:l.isBoolean});},_dataConnect:function(){if(!d.Connect){return false;}i.addClass(this.get(c).parentNode,this.LOADING_CLASSNAME);this._loading=true;this.dataConnection=d.Connect.asyncRequest(this.get(n),this.get(b),{success:function(r){this.loadHandler.success.call(this,r);this.set(h,true);this.dataConnection=null;i.removeClass(this.get(c).parentNode,this.LOADING_CLASSNAME);this._loading=false;},failure:function(r){this.loadHandler.failure.call(this,r);this.dataConnection=null;i.removeClass(this.get(c).parentNode,this.LOADING_CLASSNAME);this._loading=false;},scope:this,timeout:this.get(a)},this.get(f));},_createTabElement:function(r){var v=document.createElement("li"),s=document.createElement("a"),u=r.label||null,t=r.labelEl||null;s.href=r.href||"#";v.appendChild(s);if(t){if(!u){u=this._getLabel();}}else{t=this._createLabelEl();}s.appendChild(t);return v;},_getLabelEl:function(){return this.getElementsByTagName(this.LABEL_TAGNAME)[0];},_createLabelEl:function(){var r=document.createElement(this.LABEL_TAGNAME);return r;},_getLabel:function(){var r=this.get(g);if(!r){return undefined;}return r.innerHTML;},_onActivate:function(u,t){var s=this,r=false;d.Event.preventDefault(u);if(s===t.get(m)){r=true;}t.set(m,s,r);},_onActivationEventChange:function(s){var r=this;if(s.prevValue!=s.newValue){r.removeListener(s.prevValue,r._onActivate);r.addListener(s.newValue,r._onActivate,this,r);}}});YAHOO.widget.Tab=e;})();YAHOO.register("tabview",YAHOO.widget.TabView,{version:"2.9.0",build:"2800"});
140 140 //
141   -//../pacotes/yui290/build/treeview/treeview_compacto.js
142   -(function(){var Dom=YAHOO.util.Dom,Event=YAHOO.util.Event,Lang=YAHOO.lang,Widget=YAHOO.widget;YAHOO.widget.TreeView=function(id,oConfig){if(id){this.init(id)}if(oConfig){this.buildTreeFromObject(oConfig)}else if(Lang.trim(this._el.innerHTML)){this.buildTreeFromMarkup(id)}};var TV=Widget.TreeView;TV.prototype={id:null,_el:null,_nodes:null,locked:false,_expandAnim:null,_collapseAnim:null,_animCount:0,maxAnim:2,_hasDblClickSubscriber:false,_dblClickTimer:null,currentFocus:null,singleNodeHighlight:false,_currentlyHighlighted:null,setExpandAnim:function(type){this._expandAnim=(Widget.TVAnim.isValid(type))?type:null},setCollapseAnim:function(type){this._collapseAnim=(Widget.TVAnim.isValid(type))?type:null},animateExpand:function(el,node){if(this._expandAnim&&this._animCount<this.maxAnim){var tree=this;var a=Widget.TVAnim.getAnim(this._expandAnim,el,function(){tree.expandComplete(node)});if(a){++this._animCount;this.fireEvent("animStart",{"node":node,"type":"expand"});a.animate()}return true}return false},animateCollapse:function(el,node){if(this._collapseAnim&&this._animCount<this.maxAnim){var tree=this;var a=Widget.TVAnim.getAnim(this._collapseAnim,el,function(){tree.collapseComplete(node)});if(a){++this._animCount;this.fireEvent("animStart",{"node":node,"type":"collapse"});a.animate()}return true}return false},expandComplete:function(node){--this._animCount;this.fireEvent("animComplete",{"node":node,"type":"expand"})},collapseComplete:function(node){--this._animCount;this.fireEvent("animComplete",{"node":node,"type":"collapse"})},init:function(id){this._el=Dom.get(id);this.id=Dom.generateId(this._el,"yui-tv-auto-id-");this.createEvent("animStart",this);this.createEvent("animComplete",this);this.createEvent("collapse",this);this.createEvent("collapseComplete",this);this.createEvent("expand",this);this.createEvent("expandComplete",this);this.createEvent("enterKeyPressed",this);this.createEvent("clickEvent",this);this.createEvent('focusChanged',this);var self=this;this.createEvent("dblClickEvent",{scope:this,onSubscribeCallback:function(){self._hasDblClickSubscriber=true}});this.createEvent("labelClick",this);this.createEvent("highlightEvent",this);this._nodes=[];TV.trees[this.id]=this;this.root=new Widget.RootNode(this);var LW=Widget.LogWriter;if(this._initEditor){this._initEditor()}},buildTreeFromObject:function(oConfig){var build=function(parent,oConfig){var i,item,node,children,type,NodeType,ThisType;for(i=0;i<oConfig.length;i++){item=oConfig[i];if(Lang.isString(item)){node=new Widget.TextNode(item,parent)}else if(Lang.isObject(item)){children=item.children;delete item.children;type=item.type||'text';delete item.type;switch(Lang.isString(type)&&type.toLowerCase()){case'text':node=new Widget.TextNode(item,parent);break;case'menu':node=new Widget.MenuNode(item,parent);break;case'html':node=new Widget.HTMLNode(item,parent);break;default:if(Lang.isString(type)){NodeType=Widget[type]}else{NodeType=type}if(Lang.isObject(NodeType)){for(ThisType=NodeType;ThisType&&ThisType!==Widget.Node;ThisType=ThisType.superclass.constructor){}if(ThisType){node=new NodeType(item,parent)}else{}}else{}}if(children){build(node,children)}}else{}}};if(!Lang.isArray(oConfig)){oConfig=[oConfig]}build(this.root,oConfig)},buildTreeFromMarkup:function(id){var build=function(markup){var el,child,branch=[],config={},label,yuiConfig;for(el=Dom.getFirstChild(markup);el;el=Dom.getNextSibling(el)){switch(el.tagName.toUpperCase()){case'LI':label='';config={expanded:Dom.hasClass(el,'expanded'),title:el.title||el.alt||null,className:Lang.trim(el.className.replace(/\bexpanded\b/,''))||null};child=el.firstChild;if(child.nodeType==3){label=Lang.trim(child.nodeValue.replace(/[\n\t\r]*/g,''));if(label){config.type='text';config.label=label}else{child=Dom.getNextSibling(child)}}if(!label){if(child.tagName.toUpperCase()=='A'){config.type='text';config.label=child.innerHTML;config.href=child.href;config.target=child.target;config.title=child.title||child.alt||config.title}else{config.type='html';var d=document.createElement('div');d.appendChild(child.cloneNode(true));config.html=d.innerHTML;config.hasIcon=true}}child=Dom.getNextSibling(child);switch(child&&child.tagName.toUpperCase()){case'UL':case'OL':config.children=build(child);break}if(YAHOO.lang.JSON){yuiConfig=el.getAttribute('yuiConfig');if(yuiConfig){yuiConfig=YAHOO.lang.JSON.parse(yuiConfig);config=YAHOO.lang.merge(config,yuiConfig)}}branch.push(config);break;case'UL':case'OL':config={type:'text',label:'',children:build(child)};branch.push(config);break}}return branch};var markup=Dom.getChildrenBy(Dom.get(id),function(el){var tag=el.tagName.toUpperCase();return tag=='UL'||tag=='OL'});if(markup.length){this.buildTreeFromObject(build(markup[0]))}else{}},_getEventTargetTdEl:function(ev){var target=Event.getTarget(ev);while(target&&!(target.tagName.toUpperCase()=='TD'&&Dom.hasClass(target.parentNode,'ygtvrow'))){target=Dom.getAncestorByTagName(target,'td')}if(Lang.isNull(target)){return null}if(/\bygtv(blank)?depthcell/.test(target.className)){return null}if(target.id){var m=target.id.match(/\bygtv([^\d]*)(.*)/);if(m&&m[2]&&this._nodes[m[2]]){return target}}return null},_onClickEvent:function(ev){var self=this,td=this._getEventTargetTdEl(ev),node,target,toggle=function(force){node.focus();if(force||!node.href){node.toggle();try{Event.preventDefault(ev)}catch(e){}}};if(!td){return}node=this.getNodeByElement(td);if(!node){return}target=Event.getTarget(ev);if(Dom.hasClass(target,node.labelStyle)||Dom.getAncestorByClassName(target,node.labelStyle)){this.fireEvent('labelClick',node)}if(this._closeEditor){this._closeEditor(false)}if(/\bygtv[tl][mp]h?h?/.test(td.className)){toggle(true)}else{if(this._dblClickTimer){window.clearTimeout(this._dblClickTimer);this._dblClickTimer=null}else{if(this._hasDblClickSubscriber){this._dblClickTimer=window.setTimeout(function(){self._dblClickTimer=null;if(self.fireEvent('clickEvent',{event:ev,node:node})!==false){toggle()}},200)}else{if(self.fireEvent('clickEvent',{event:ev,node:node})!==false){if(node.enableHighlight==true){toggle()}}}}}},_onDblClickEvent:function(ev){if(!this._hasDblClickSubscriber){return}var td=this._getEventTargetTdEl(ev);if(!td){return}if(!(/\bygtv[tl][mp]h?h?/.test(td.className))){this.fireEvent('dblClickEvent',{event:ev,node:this.getNodeByElement(td)});if(this._dblClickTimer){window.clearTimeout(this._dblClickTimer);this._dblClickTimer=null}}},_onMouseOverEvent:function(ev){var target;if((target=this._getEventTargetTdEl(ev))&&(target=this.getNodeByElement(target))&&(target=target.getToggleEl())){target.className=target.className.replace(/\bygtv([lt])([mp])\b/gi,'ygtv$1$2h')}},_onMouseOutEvent:function(ev){var target;if((target=this._getEventTargetTdEl(ev))&&(target=this.getNodeByElement(target))&&(target=target.getToggleEl())){target.className=target.className.replace(/\bygtv([lt])([mp])h\b/gi,'ygtv$1$2')}},_onKeyDownEvent:function(ev){var target=Event.getTarget(ev),node=this.getNodeByElement(target),newNode=node,KEY=YAHOO.util.KeyListener.KEY;switch(ev.keyCode){case KEY.UP:do{if(newNode.previousSibling){newNode=newNode.previousSibling}else{newNode=newNode.parent}}while(newNode&&!newNode._canHaveFocus());if(newNode){newNode.focus()}Event.preventDefault(ev);break;case KEY.DOWN:do{if(newNode.nextSibling){newNode=newNode.nextSibling}else{newNode.expand();newNode=(newNode.children.length||null)&&newNode.children[0]}}while(newNode&&!newNode._canHaveFocus);if(newNode){newNode.focus()}Event.preventDefault(ev);break;case KEY.LEFT:do{if(newNode.parent){newNode=newNode.parent}else{newNode=newNode.previousSibling}}while(newNode&&!newNode._canHaveFocus());if(newNode){newNode.focus()}Event.preventDefault(ev);break;case KEY.RIGHT:var self=this,moveFocusRight,focusOnExpand=function(newNode){self.unsubscribe('expandComplete',focusOnExpand);moveFocusRight(newNode)};moveFocusRight=function(newNode){do{if(newNode.isDynamic()&&!newNode.childrenRendered){self.subscribe('expandComplete',focusOnExpand);newNode.expand();newNode=null;break}else{newNode.expand();if(newNode.children.length){newNode=newNode.children[0]}else{newNode=newNode.nextSibling}}}while(newNode&&!newNode._canHaveFocus());if(newNode){newNode.focus()}};moveFocusRight(newNode);Event.preventDefault(ev);break;case KEY.ENTER:if(node.href){if(node.target){window.open(node.href,node.target)}else{window.location(node.href)}}else{node.toggle()}this.fireEvent('enterKeyPressed',node);Event.preventDefault(ev);break;case KEY.HOME:newNode=this.getRoot();if(newNode.children.length){newNode=newNode.children[0]}if(newNode._canHaveFocus()){newNode.focus()}Event.preventDefault(ev);break;case KEY.END:newNode=newNode.parent.children;newNode=newNode[newNode.length-1];if(newNode._canHaveFocus()){newNode.focus()}Event.preventDefault(ev);break;case 107:case 187:if(ev.shiftKey){node.parent.expandAll()}else{node.expand()}break;case 109:case 189:if(ev.shiftKey){node.parent.collapseAll()}else{node.collapse()}break;default:break}},render:function(){var html=this.root.getHtml(),el=this.getEl();el.innerHTML=html;if(!this._hasEvents){Event.on(el,'click',this._onClickEvent,this,true);Event.on(el,'dblclick',this._onDblClickEvent,this,true);Event.on(el,'mouseover',this._onMouseOverEvent,this,true);Event.on(el,'mouseout',this._onMouseOutEvent,this,true);Event.on(el,'keydown',this._onKeyDownEvent,this,true)}this._hasEvents=true},getEl:function(){if(!this._el){this._el=Dom.get(this.id)}return this._el},regNode:function(node){this._nodes[node.index]=node},getRoot:function(){return this.root},setDynamicLoad:function(fnDataLoader,iconMode){this.root.setDynamicLoad(fnDataLoader,iconMode)},expandAll:function(){if(!this.locked){this.root.expandAll()}},collapseAll:function(){if(!this.locked){this.root.collapseAll()}},getNodeByIndex:function(nodeIndex){var n=this._nodes[nodeIndex];return(n)?n:null},getNodeByProperty:function(property,value){for(var i in this._nodes){if(this._nodes.hasOwnProperty(i)){var n=this._nodes[i];if((property in n&&n[property]==value)||(n.data&&value==n.data[property])){return n}}}return null},getNodesByProperty:function(property,value){var values=[];for(var i in this._nodes){if(this._nodes.hasOwnProperty(i)){var n=this._nodes[i];if((property in n&&n[property]==value)||(n.data&&value==n.data[property])){values.push(n)}}}return(values.length)?values:null},getNodesBy:function(fn){var values=[];for(var i in this._nodes){if(this._nodes.hasOwnProperty(i)){var n=this._nodes[i];if(fn(n)){values.push(n)}}}return(values.length)?values:null},getNodeByElement:function(el){var p=el,m,re=/ygtv([^\d]*)(.*)/;do{if(p&&p.id){m=p.id.match(re);if(m&&m[2]){return this.getNodeByIndex(m[2])}}p=p.parentNode;if(!p||!p.tagName){break}}while(p.id!==this.id&&p.tagName.toLowerCase()!=="body");return null},getHighlightedNode:function(){return this._currentlyHighlighted},removeNode:function(node,autoRefresh){if(node.isRoot()){return false}var p=node.parent;if(p.parent){p=p.parent}this._deleteNode(node);if(autoRefresh&&p&&p.childrenRendered){p.refresh()}return true},_removeChildren_animComplete:function(o){this.unsubscribe(this._removeChildren_animComplete);this.removeChildren(o.node)},removeChildren:function(node){if(node.expanded){if(this._collapseAnim){this.subscribe("animComplete",this._removeChildren_animComplete,this,true);Widget.Node.prototype.collapse.call(node);return}node.collapse()}while(node.children.length){this._deleteNode(node.children[0])}if(node.isRoot()){Widget.Node.prototype.expand.call(node)}node.childrenRendered=false;node.dynamicLoadComplete=false;node.updateIcon()},_deleteNode:function(node){this.removeChildren(node);this.popNode(node)},popNode:function(node){var p=node.parent;var a=[];for(var i=0,len=p.children.length;i<len;++i){if(p.children[i]!=node){a[a.length]=p.children[i]}}p.children=a;p.childrenRendered=false;if(node.previousSibling){node.previousSibling.nextSibling=node.nextSibling}if(node.nextSibling){node.nextSibling.previousSibling=node.previousSibling}if(this.currentFocus==node){this.currentFocus=null}if(this._currentlyHighlighted==node){this._currentlyHighlighted=null}node.parent=null;node.previousSibling=null;node.nextSibling=null;node.tree=null;delete this._nodes[node.index]},destroy:function(){if(this._destroyEditor){this._destroyEditor()}var el=this.getEl();Event.removeListener(el,'click');Event.removeListener(el,'dblclick');Event.removeListener(el,'mouseover');Event.removeListener(el,'mouseout');Event.removeListener(el,'keydown');for(var i=0;i<this._nodes.length;i++){var node=this._nodes[i];if(node&&node.destroy){node.destroy()}}el.innerHTML='';this._hasEvents=false},toString:function(){return"TreeView "+this.id},getNodeCount:function(){return this.getRoot().getNodeCount()},getTreeDefinition:function(){return this.getRoot().getNodeDefinition()},onExpand:function(node){},onCollapse:function(node){},setNodesProperty:function(name,value,refresh){this.root.setNodesProperty(name,value);if(refresh){this.root.refresh()}},onEventToggleHighlight:function(oArgs){var node;if('node'in oArgs&&oArgs.node instanceof Widget.Node){node=oArgs.node}else if(oArgs instanceof Widget.Node){node=oArgs}else{return false}node.toggleHighlight();return false}};var PROT=TV.prototype;PROT.draw=PROT.render;YAHOO.augment(TV,YAHOO.util.EventProvider);TV.nodeCount=0;TV.trees=[];TV.getTree=function(treeId){var t=TV.trees[treeId];return(t)?t:null};TV.getNode=function(treeId,nodeIndex){var t=TV.getTree(treeId);return(t)?t.getNodeByIndex(nodeIndex):null};TV.FOCUS_CLASS_NAME='ygtvfocus'})();(function(){var Dom=YAHOO.util.Dom,Lang=YAHOO.lang,Event=YAHOO.util.Event;YAHOO.widget.Node=function(oData,oParent,expanded){if(oData){this.init(oData,oParent,expanded)}};YAHOO.widget.Node.prototype={index:0,children:null,tree:null,data:null,parent:null,depth:-1,expanded:false,multiExpand:true,renderHidden:false,childrenRendered:false,dynamicLoadComplete:false,previousSibling:null,nextSibling:null,_dynLoad:false,dataLoader:null,isLoading:false,hasIcon:true,iconMode:0,nowrap:false,isLeaf:false,contentStyle:"",contentElId:null,enableHighlight:true,highlightState:0,propagateHighlightUp:false,propagateHighlightDown:false,className:null,_type:"Node",init:function(oData,oParent,expanded){this.data={};this.children=[];this.index=YAHOO.widget.TreeView.nodeCount;++YAHOO.widget.TreeView.nodeCount;this.contentElId="ygtvcontentel"+this.index;if(Lang.isObject(oData)){for(var property in oData){if(oData.hasOwnProperty(property)){if(property.charAt(0)!='_'&&!Lang.isUndefined(this[property])&&!Lang.isFunction(this[property])){this[property]=oData[property]}else{this.data[property]=oData[property]}}}}if(!Lang.isUndefined(expanded)){this.expanded=expanded}this.createEvent("parentChange",this);if(oParent){oParent.appendChild(this)}},applyParent:function(parentNode){if(!parentNode){return false}this.tree=parentNode.tree;this.parent=parentNode;this.depth=parentNode.depth+1;this.tree.regNode(this);parentNode.childrenRendered=false;for(var i=0,len=this.children.length;i<len;++i){this.children[i].applyParent(this)}this.fireEvent("parentChange");return true},appendChild:function(childNode){if(this.hasChildren()){var sib=this.children[this.children.length-1];sib.nextSibling=childNode;childNode.previousSibling=sib}this.children[this.children.length]=childNode;childNode.applyParent(this);if(this.childrenRendered&&this.expanded){this.getChildrenEl().style.display=""}return childNode},appendTo:function(parentNode){return parentNode.appendChild(this)},insertBefore:function(node){var p=node.parent;if(p){if(this.tree){this.tree.popNode(this)}var refIndex=node.isChildOf(p);p.children.splice(refIndex,0,this);if(node.previousSibling){node.previousSibling.nextSibling=this}this.previousSibling=node.previousSibling;this.nextSibling=node;node.previousSibling=this;this.applyParent(p)}return this},insertAfter:function(node){var p=node.parent;if(p){if(this.tree){this.tree.popNode(this)}var refIndex=node.isChildOf(p);if(!node.nextSibling){this.nextSibling=null;return this.appendTo(p)}p.children.splice(refIndex+1,0,this);node.nextSibling.previousSibling=this;this.previousSibling=node;this.nextSibling=node.nextSibling;node.nextSibling=this;this.applyParent(p)}return this},isChildOf:function(parentNode){if(parentNode&&parentNode.children){for(var i=0,len=parentNode.children.length;i<len;++i){if(parentNode.children[i]===this){return i}}}return-1},getSiblings:function(){var sib=this.parent.children.slice(0);for(var i=0;i<sib.length&&sib[i]!=this;i++){}sib.splice(i,1);if(sib.length){return sib}return null},showChildren:function(){if(!this.tree.animateExpand(this.getChildrenEl(),this)){if(this.hasChildren()){this.getChildrenEl().style.display=""}}},hideChildren:function(){if(!this.tree.animateCollapse(this.getChildrenEl(),this)){this.getChildrenEl().style.display="none"}},getElId:function(){return"ygtv"+this.index},getChildrenElId:function(){return"ygtvc"+this.index},getToggleElId:function(){return"ygtvt"+this.index},getEl:function(){return Dom.get(this.getElId())},getChildrenEl:function(){return Dom.get(this.getChildrenElId())},getToggleEl:function(){return Dom.get(this.getToggleElId())},getContentEl:function(){return Dom.get(this.contentElId)},collapse:function(){if(!this.expanded){return}var ret=this.tree.onCollapse(this);if(false===ret){return}ret=this.tree.fireEvent("collapse",this);if(false===ret){return}if(!this.getEl()){this.expanded=false}else{this.hideChildren();this.expanded=false;this.updateIcon()}ret=this.tree.fireEvent("collapseComplete",this)},expand:function(lazySource){if(this.isLoading||(this.expanded&&!lazySource)){return}var ret=true;if(!lazySource){ret=this.tree.onExpand(this);if(false===ret){return}ret=this.tree.fireEvent("expand",this)}if(false===ret){return}if(!this.getEl()){this.expanded=true;return}if(!this.childrenRendered){this.getChildrenEl().innerHTML=this.renderChildren()}else{}this.expanded=true;this.updateIcon();if(this.isLoading){this.expanded=false;return}if(!this.multiExpand){var sibs=this.getSiblings();for(var i=0;sibs&&i<sibs.length;++i){if(sibs[i]!=this&&sibs[i].expanded){sibs[i].collapse()}}}this.showChildren();ret=this.tree.fireEvent("expandComplete",this)},updateIcon:function(){if(this.hasIcon){var el=this.getToggleEl();if(el){el.className=el.className.replace(/\bygtv(([tl][pmn]h?)|(loading))\b/gi,this.getStyle())}}el=Dom.get('ygtvtableel'+this.index);if(el){if(this.expanded){Dom.replaceClass(el,'ygtv-collapsed','ygtv-expanded')}else{Dom.replaceClass(el,'ygtv-expanded','ygtv-collapsed')}}},getStyle:function(){if(this.isLoading){return"ygtvloading"}else{var loc=(this.nextSibling)?"t":"l";var type="n";if(this.hasChildren(true)||(this.isDynamic()&&!this.getIconMode())){type=(this.expanded)?"m":"p"}return"ygtv"+loc+type}},getHoverStyle:function(){var s=this.getStyle();if(this.hasChildren(true)&&!this.isLoading){s+="h"}return s},expandAll:function(){var l=this.children.length;for(var i=0;i<l;++i){var c=this.children[i];if(c.isDynamic()){break}else if(!c.multiExpand){break}else{c.expand();c.expandAll()}}},collapseAll:function(){for(var i=0;i<this.children.length;++i){this.children[i].collapse();this.children[i].collapseAll()}},setDynamicLoad:function(fnDataLoader,iconMode){if(fnDataLoader){this.dataLoader=fnDataLoader;this._dynLoad=true}else{this.dataLoader=null;this._dynLoad=false}if(iconMode){this.iconMode=iconMode}},isRoot:function(){return(this==this.tree.root)},isDynamic:function(){if(this.isLeaf){return false}else{return(!this.isRoot()&&(this._dynLoad||this.tree.root._dynLoad))}},getIconMode:function(){return(this.iconMode||this.tree.root.iconMode)},hasChildren:function(checkForLazyLoad){if(this.isLeaf){return false}else{return(this.children.length>0||(checkForLazyLoad&&this.isDynamic()&&!this.dynamicLoadComplete))}},toggle:function(){if(!this.tree.locked&&(this.hasChildren(true)||this.isDynamic())){if(this.expanded){this.collapse()}else{this.expand()}}},getHtml:function(){this.childrenRendered=false;return['<div class="ygtvitem" id="',this.getElId(),'">',this.getNodeHtml(),this.getChildrenHtml(),'</div>'].join("")},getChildrenHtml:function(){var sb=[];sb[sb.length]='<div class="ygtvchildren" id="'+this.getChildrenElId()+'"';if(!this.expanded||!this.hasChildren()){sb[sb.length]=' style="display:none;"'}sb[sb.length]='>';if((this.hasChildren(true)&&this.expanded)||(this.renderHidden&&!this.isDynamic())){sb[sb.length]=this.renderChildren()}sb[sb.length]='</div>';return sb.join("")},renderChildren:function(){var node=this;if(this.isDynamic()&&!this.dynamicLoadComplete){this.isLoading=true;this.tree.locked=true;if(this.dataLoader){setTimeout(function(){node.dataLoader(node,function(){node.loadComplete()})},10)}else if(this.tree.root.dataLoader){setTimeout(function(){node.tree.root.dataLoader(node,function(){node.loadComplete()})},10)}else{return"Error: data loader not found or not specified."}return""}else{return this.completeRender()}},completeRender:function(){var sb=[];for(var i=0;i<this.children.length;++i){sb[sb.length]=this.children[i].getHtml()}this.childrenRendered=true;return sb.join("")},loadComplete:function(){this.getChildrenEl().innerHTML=this.completeRender();if(this.propagateHighlightDown){if(this.highlightState===1&&!this.tree.singleNodeHighlight){for(var i=0;i<this.children.length;i++){this.children[i].highlight(true)}}else if(this.highlightState===0||this.tree.singleNodeHighlight){for(i=0;i<this.children.length;i++){this.children[i].unhighlight(true)}}}this.dynamicLoadComplete=true;this.isLoading=false;this.expand(true);this.tree.locked=false},getAncestor:function(depth){if(depth>=this.depth||depth<0){return null}var p=this.parent;while(p.depth>depth){p=p.parent}return p},getDepthStyle:function(depth){return(this.getAncestor(depth).nextSibling)?"ygtvdepthcell":"ygtvblankdepthcell"},getNodeHtml:function(){var sb=[];sb[sb.length]='<table id="ygtvtableel'+this.index+'" border="0" cellpadding="0" cellspacing="0" class="ygtvtable ygtvdepth'+this.depth;sb[sb.length]=' ygtv-'+(this.expanded?'expanded':'collapsed');if(this.enableHighlight){sb[sb.length]=' ygtv-highlight'+this.highlightState}if(this.className){sb[sb.length]=' '+this.className}sb[sb.length]='"><tr class="ygtvrow">';for(var i=0;i<this.depth;++i){sb[sb.length]='<td class="ygtvcell '+this.getDepthStyle(i)+'"><div class="ygtvspacer"></div></td>'}if(this.hasIcon){sb[sb.length]='<td id="'+this.getToggleElId();sb[sb.length]='" class="ygtvcell ';sb[sb.length]=this.getStyle();sb[sb.length]='"><a href="#" class="ygtvspacer">&#160;</a></td>'}sb[sb.length]='<td id="'+this.contentElId;sb[sb.length]='" class="ygtvcell ';sb[sb.length]=this.contentStyle+' ygtvcontent" ';sb[sb.length]=(this.nowrap)?' nowrap="nowrap" ':'';sb[sb.length]=' >';sb[sb.length]=this.getContentHtml();sb[sb.length]='</td></tr></table>';return sb.join("")},getContentHtml:function(){return""},refresh:function(){this.getChildrenEl().innerHTML=this.completeRender();if(this.hasIcon){var el=this.getToggleEl();if(el){el.className=el.className.replace(/\bygtv[lt][nmp]h*\b/gi,this.getStyle())}}},toString:function(){return this._type+" ("+this.index+")"},_focusHighlightedItems:[],_focusedItem:null,_canHaveFocus:function(){return this.getEl().getElementsByTagName('a').length>0},_removeFocus:function(){if(this._focusedItem){Event.removeListener(this._focusedItem,'blur');this._focusedItem=null}var el;while((el=this._focusHighlightedItems.shift())){Dom.removeClass(el,YAHOO.widget.TreeView.FOCUS_CLASS_NAME)}},focus:function(){var focused=false,self=this;if(this.tree.currentFocus){this.tree.currentFocus._removeFocus()}var expandParent=function(node){if(node.parent){expandParent(node.parent);node.parent.expand()}};expandParent(this);Dom.getElementsBy(function(el){return(/ygtv(([tl][pmn]h?)|(content))/).test(el.className)},'td',self.getEl().firstChild,function(el){Dom.addClass(el,YAHOO.widget.TreeView.FOCUS_CLASS_NAME);if(!focused){var aEl=el.getElementsByTagName('a');if(aEl.length){aEl=aEl[0];aEl.focus();self._focusedItem=aEl;Event.on(aEl,'blur',function(){self.tree.fireEvent('focusChanged',{oldNode:self.tree.currentFocus,newNode:null});self.tree.currentFocus=null;self._removeFocus()});focused=true}}self._focusHighlightedItems.push(el)});if(focused){this.tree.fireEvent('focusChanged',{oldNode:this.tree.currentFocus,newNode:this});this.tree.currentFocus=this}else{this.tree.fireEvent('focusChanged',{oldNode:self.tree.currentFocus,newNode:null});this.tree.currentFocus=null;this._removeFocus()}return focused},getNodeCount:function(){for(var i=0,count=0;i<this.children.length;i++){count+=this.children[i].getNodeCount()}return count+1},getNodeDefinition:function(){if(this.isDynamic()){return false}var def,defs=Lang.merge(this.data),children=[];if(this.expanded){defs.expanded=this.expanded}if(!this.multiExpand){defs.multiExpand=this.multiExpand}if(this.renderHidden){defs.renderHidden=this.renderHidden}if(!this.hasIcon){defs.hasIcon=this.hasIcon}if(this.nowrap){defs.nowrap=this.nowrap}if(this.className){defs.className=this.className}if(this.editable){defs.editable=this.editable}if(!this.enableHighlight){defs.enableHighlight=this.enableHighlight}if(this.highlightState){defs.highlightState=this.highlightState}if(this.propagateHighlightUp){defs.propagateHighlightUp=this.propagateHighlightUp}if(this.propagateHighlightDown){defs.propagateHighlightDown=this.propagateHighlightDown}defs.type=this._type;for(var i=0;i<this.children.length;i++){def=this.children[i].getNodeDefinition();if(def===false){return false}children.push(def)}if(children.length){defs.children=children}return defs},getToggleLink:function(){return'return false;'},setNodesProperty:function(name,value,refresh){if(name.charAt(0)!='_'&&!Lang.isUndefined(this[name])&&!Lang.isFunction(this[name])){this[name]=value}else{this.data[name]=value}for(var i=0;i<this.children.length;i++){this.children[i].setNodesProperty(name,value)}if(refresh){this.refresh()}},toggleHighlight:function(){if(this.enableHighlight){if(this.highlightState==1){this.unhighlight()}else{this.highlight()}}},highlight:function(_silent){if(this.enableHighlight){if(this.tree.singleNodeHighlight){if(this.tree._currentlyHighlighted){this.tree._currentlyHighlighted.unhighlight(_silent)}this.tree._currentlyHighlighted=this}this.highlightState=1;this._setHighlightClassName();if(!this.tree.singleNodeHighlight){if(this.propagateHighlightDown){for(var i=0;i<this.children.length;i++){this.children[i].highlight(true)}}if(this.propagateHighlightUp){if(this.parent){this.parent._childrenHighlighted()}}}if(!_silent){this.tree.fireEvent('highlightEvent',this)}}},unhighlight:function(_silent){if(this.enableHighlight){this.tree._currentlyHighlighted=null;this.highlightState=0;this._setHighlightClassName();if(!this.tree.singleNodeHighlight){if(this.propagateHighlightDown){for(var i=0;i<this.children.length;i++){this.children[i].unhighlight(true)}}if(this.propagateHighlightUp){if(this.parent){this.parent._childrenHighlighted()}}}if(!_silent){this.tree.fireEvent('highlightEvent',this)}}},_childrenHighlighted:function(){var yes=false,no=false;if(this.enableHighlight){for(var i=0;i<this.children.length;i++){switch(this.children[i].highlightState){case 0:no=true;break;case 1:yes=true;break;case 2:yes=no=true;break}}if(yes&&no){this.highlightState=2}else if(yes){this.highlightState=1}else{this.highlightState=0}this._setHighlightClassName();if(this.propagateHighlightUp){if(this.parent){this.parent._childrenHighlighted()}}}},_setHighlightClassName:function(){var el=Dom.get('ygtvtableel'+this.index);if(el){el.className=el.className.replace(/\bygtv-highlight\d\b/gi,'ygtv-highlight'+this.highlightState)}}};YAHOO.augment(YAHOO.widget.Node,YAHOO.util.EventProvider)})();YAHOO.widget.RootNode=function(oTree){this.init(null,null,true);this.tree=oTree};YAHOO.extend(YAHOO.widget.RootNode,YAHOO.widget.Node,{_type:"RootNode",getNodeHtml:function(){return""},toString:function(){return this._type},loadComplete:function(){this.tree.draw()},getNodeCount:function(){for(var i=0,count=0;i<this.children.length;i++){count+=this.children[i].getNodeCount()}return count},getNodeDefinition:function(){for(var def,defs=[],i=0;i<this.children.length;i++){def=this.children[i].getNodeDefinition();if(def===false){return false}defs.push(def)}return defs},collapse:function(){},expand:function(){},getSiblings:function(){return null},focus:function(){}});(function(){var Dom=YAHOO.util.Dom,Lang=YAHOO.lang,Event=YAHOO.util.Event;YAHOO.widget.TextNode=function(oData,oParent,expanded){if(oData){if(Lang.isString(oData)){oData={label:oData}}this.init(oData,oParent,expanded);this.setUpLabel(oData)}};YAHOO.extend(YAHOO.widget.TextNode,YAHOO.widget.Node,{labelStyle:"ygtvlabel",labelElId:null,label:null,title:null,href:null,target:"_self",_type:"TextNode",setUpLabel:function(oData){if(Lang.isString(oData)){oData={label:oData}}else{if(oData.style){this.labelStyle=oData.style}}this.label=oData.label;this.labelElId="ygtvlabelel"+this.index},getLabelEl:function(){return Dom.get(this.labelElId)},getContentHtml:function(){var sb=[];sb[sb.length]=this.href?'<a':'<span';sb[sb.length]=' id="'+Lang.escapeHTML(this.labelElId)+'"';sb[sb.length]=' class="'+Lang.escapeHTML(this.labelStyle)+'"';if(this.href){sb[sb.length]=' href="'+Lang.escapeHTML(this.href)+'"';sb[sb.length]=' target="'+Lang.escapeHTML(this.target)+'"'}if(this.title){sb[sb.length]=' title="'+Lang.escapeHTML(this.title)+'"'}sb[sb.length]=' >';sb[sb.length]=Lang.escapeHTML(this.label);sb[sb.length]=this.href?'</a>':'</span>';return sb.join("")},getNodeDefinition:function(){var def=YAHOO.widget.TextNode.superclass.getNodeDefinition.call(this);if(def===false){return false}def.label=this.label;if(this.labelStyle!='ygtvlabel'){def.style=this.labelStyle}if(this.title){def.title=this.title}if(this.href){def.href=this.href}if(this.target!='_self'){def.target=this.target}return def},toString:function(){return YAHOO.widget.TextNode.superclass.toString.call(this)+": "+this.label},onLabelClick:function(){return false},refresh:function(){YAHOO.widget.TextNode.superclass.refresh.call(this);var label=this.getLabelEl();label.innerHTML=this.label;if(label.tagName.toUpperCase()=='A'){label.href=this.href;label.target=this.target}}})})();YAHOO.widget.MenuNode=function(oData,oParent,expanded){YAHOO.widget.MenuNode.superclass.constructor.call(this,oData,oParent,expanded);this.multiExpand=false};YAHOO.extend(YAHOO.widget.MenuNode,YAHOO.widget.TextNode,{_type:"MenuNode"});(function(){var Dom=YAHOO.util.Dom,Lang=YAHOO.lang,Event=YAHOO.util.Event;var HN=function(oData,oParent,expanded,hasIcon){if(oData){this.init(oData,oParent,expanded);this.initContent(oData,hasIcon)}};YAHOO.widget.HTMLNode=HN;YAHOO.extend(HN,YAHOO.widget.Node,{contentStyle:"ygtvhtml",html:null,_type:"HTMLNode",initContent:function(oData,hasIcon){this.setHtml(oData);this.contentElId="ygtvcontentel"+this.index;if(!Lang.isUndefined(hasIcon)){this.hasIcon=hasIcon}},setHtml:function(o){this.html=(Lang.isObject(o)&&'html'in o)?o.html:o;var el=this.getContentEl();if(el){if(o.nodeType&&o.nodeType==1&&o.tagName){el.innerHTML=""}else{el.innerHTML=this.html}}},getContentHtml:function(){if(typeof this.html==="string"){return this.html}else{HN._deferredNodes.push(this);if(!HN._timer){HN._timer=window.setTimeout(function(){var n;while((n=HN._deferredNodes.pop())){n.getContentEl().appendChild(n.html)}HN._timer=null},0)}return""}},getNodeDefinition:function(){var def=HN.superclass.getNodeDefinition.call(this);if(def===false){return false}def.html=this.html;return def}});HN._deferredNodes=[];HN._timer=null})();(function(){var Dom=YAHOO.util.Dom,Lang=YAHOO.lang,Event=YAHOO.util.Event,Calendar=YAHOO.widget.Calendar;YAHOO.widget.DateNode=function(oData,oParent,expanded){YAHOO.widget.DateNode.superclass.constructor.call(this,oData,oParent,expanded)};YAHOO.extend(YAHOO.widget.DateNode,YAHOO.widget.TextNode,{_type:"DateNode",calendarConfig:null,fillEditorContainer:function(editorData){var cal,container=editorData.inputContainer;if(Lang.isUndefined(Calendar)){Dom.replaceClass(editorData.editorPanel,'ygtv-edit-DateNode','ygtv-edit-TextNode');YAHOO.widget.DateNode.superclass.fillEditorContainer.call(this,editorData);return}if(editorData.nodeType!=this._type){editorData.nodeType=this._type;editorData.saveOnEnter=false;editorData.node.destroyEditorContents(editorData);editorData.inputObject=cal=new Calendar(container.appendChild(document.createElement('div')));if(this.calendarConfig){cal.cfg.applyConfig(this.calendarConfig,true);cal.cfg.fireQueue()}cal.selectEvent.subscribe(function(){this.tree._closeEditor(true)},this,true)}else{cal=editorData.inputObject}editorData.oldValue=this.label;cal.cfg.setProperty("selected",this.label,false);var delim=cal.cfg.getProperty('DATE_FIELD_DELIMITER');var pageDate=this.label.split(delim);cal.cfg.setProperty('pagedate',pageDate[cal.cfg.getProperty('MDY_MONTH_POSITION')-1]+delim+pageDate[cal.cfg.getProperty('MDY_YEAR_POSITION')-1]);cal.cfg.fireQueue();cal.render();cal.oDomContainer.focus()},getEditorValue:function(editorData){if(Lang.isUndefined(Calendar)){return editorData.inputElement.value}else{var cal=editorData.inputObject,date=cal.getSelectedDates()[0],dd=[];dd[cal.cfg.getProperty('MDY_DAY_POSITION')-1]=date.getDate();dd[cal.cfg.getProperty('MDY_MONTH_POSITION')-1]=date.getMonth()+1;dd[cal.cfg.getProperty('MDY_YEAR_POSITION')-1]=date.getFullYear();return dd.join(cal.cfg.getProperty('DATE_FIELD_DELIMITER'))}},displayEditedValue:function(value,editorData){var node=editorData.node;node.label=value;node.getLabelEl().innerHTML=value},getNodeDefinition:function(){var def=YAHOO.widget.DateNode.superclass.getNodeDefinition.call(this);if(def===false){return false}if(this.calendarConfig){def.calendarConfig=this.calendarConfig}return def}})})();(function(){var Dom=YAHOO.util.Dom,Lang=YAHOO.lang,Event=YAHOO.util.Event,TV=YAHOO.widget.TreeView,TVproto=TV.prototype;TV.editorData={active:false,whoHasIt:null,nodeType:null,editorPanel:null,inputContainer:null,buttonsContainer:null,node:null,saveOnEnter:true,oldValue:undefined};TVproto.validator=null;TVproto._initEditor=function(){this.createEvent("editorSaveEvent",this);this.createEvent("editorCancelEvent",this)};TVproto._nodeEditing=function(node){if(node.fillEditorContainer&&node.editable){var ed,topLeft,buttons,button,editorData=TV.editorData;editorData.active=true;editorData.whoHasIt=this;if(!editorData.nodeType){editorData.editorPanel=ed=this.getEl().appendChild(document.createElement('div'));Dom.addClass(ed,'ygtv-label-editor');ed.tabIndex=0;buttons=editorData.buttonsContainer=ed.appendChild(document.createElement('div'));Dom.addClass(buttons,'ygtv-button-container');button=buttons.appendChild(document.createElement('button'));Dom.addClass(button,'ygtvok');button.innerHTML=' ';button=buttons.appendChild(document.createElement('button'));Dom.addClass(button,'ygtvcancel');button.innerHTML=' ';Event.on(buttons,'click',function(ev){var target=Event.getTarget(ev),editorData=TV.editorData,node=editorData.node,self=editorData.whoHasIt;if(Dom.hasClass(target,'ygtvok')){Event.stopEvent(ev);self._closeEditor(true)}if(Dom.hasClass(target,'ygtvcancel')){Event.stopEvent(ev);self._closeEditor(false)}});editorData.inputContainer=ed.appendChild(document.createElement('div'));Dom.addClass(editorData.inputContainer,'ygtv-input');Event.on(ed,'keydown',function(ev){var editorData=TV.editorData,KEY=YAHOO.util.KeyListener.KEY,self=editorData.whoHasIt;switch(ev.keyCode){case KEY.ENTER:Event.stopEvent(ev);if(editorData.saveOnEnter){self._closeEditor(true)}break;case KEY.ESCAPE:Event.stopEvent(ev);self._closeEditor(false);break}})}else{ed=editorData.editorPanel}editorData.node=node;if(editorData.nodeType){Dom.removeClass(ed,'ygtv-edit-'+editorData.nodeType)}Dom.addClass(ed,' ygtv-edit-'+node._type);Dom.setStyle(ed,'display','block');Dom.setXY(ed,Dom.getXY(node.getContentEl()));ed.focus();node.fillEditorContainer(editorData);return true}};TVproto.onEventEditNode=function(oArgs){if(oArgs instanceof YAHOO.widget.Node){oArgs.editNode()}else if(oArgs.node instanceof YAHOO.widget.Node){oArgs.node.editNode()}return false};TVproto._closeEditor=function(save){var ed=TV.editorData,node=ed.node,close=true;if(!node||!ed.active){return}if(save){close=ed.node.saveEditorValue(ed)!==false}else{this.fireEvent('editorCancelEvent',node)}if(close){Dom.setStyle(ed.editorPanel,'display','none');ed.active=false;node.focus()}};TVproto._destroyEditor=function(){var ed=TV.editorData;if(ed&&ed.nodeType&&(!ed.active||ed.whoHasIt===this)){Event.removeListener(ed.editorPanel,'keydown');Event.removeListener(ed.buttonContainer,'click');ed.node.destroyEditorContents(ed);document.body.removeChild(ed.editorPanel);ed.nodeType=ed.editorPanel=ed.inputContainer=ed.buttonsContainer=ed.whoHasIt=ed.node=null;ed.active=false}};var Nproto=YAHOO.widget.Node.prototype;Nproto.editable=false;Nproto.editNode=function(){this.tree._nodeEditing(this)};Nproto.fillEditorContainer=null;Nproto.destroyEditorContents=function(editorData){Event.purgeElement(editorData.inputContainer,true);editorData.inputContainer.innerHTML=''};Nproto.saveEditorValue=function(editorData){var node=editorData.node,value,validator=node.tree.validator;value=this.getEditorValue(editorData);if(Lang.isFunction(validator)){value=validator(value,editorData.oldValue,node);if(Lang.isUndefined(value)){return false}}if(this.tree.fireEvent('editorSaveEvent',{newValue:value,oldValue:editorData.oldValue,node:node})!==false){this.displayEditedValue(value,editorData)}};Nproto.getEditorValue=function(editorData){};Nproto.displayEditedValue=function(value,editorData){};var TNproto=YAHOO.widget.TextNode.prototype;TNproto.fillEditorContainer=function(editorData){var input;if(editorData.nodeType!=this._type){editorData.nodeType=this._type;editorData.saveOnEnter=true;editorData.node.destroyEditorContents(editorData);editorData.inputElement=input=editorData.inputContainer.appendChild(document.createElement('input'))}else{input=editorData.inputElement}editorData.oldValue=this.label;input.value=this.label;input.focus();input.select()};TNproto.getEditorValue=function(editorData){return editorData.inputElement.value};TNproto.displayEditedValue=function(value,editorData){var node=editorData.node;node.label=value;node.getLabelEl().innerHTML=value};TNproto.destroyEditorContents=function(editorData){editorData.inputContainer.innerHTML=''}})();YAHOO.widget.TVAnim=function(){return{FADE_IN:"TVFadeIn",FADE_OUT:"TVFadeOut",getAnim:function(type,el,callback){if(YAHOO.widget[type]){return new YAHOO.widget[type](el,callback)}else{return null}},isValid:function(type){return(YAHOO.widget[type])}}}();YAHOO.widget.TVFadeIn=function(el,callback){this.el=el;this.callback=callback};YAHOO.widget.TVFadeIn.prototype={animate:function(){var tvanim=this;var s=this.el.style;s.opacity=0.1;s.filter="alpha(opacity=10)";s.display="";var dur=0.4;var a=new YAHOO.util.Anim(this.el,{opacity:{from:0.1,to:1,unit:""}},dur);a.onComplete.subscribe(function(){tvanim.onComplete()});a.animate()},onComplete:function(){this.callback()},toString:function(){return"TVFadeIn"}};YAHOO.widget.TVFadeOut=function(el,callback){this.el=el;this.callback=callback};YAHOO.widget.TVFadeOut.prototype={animate:function(){var tvanim=this;var dur=0.4;var a=new YAHOO.util.Anim(this.el,{opacity:{from:1,to:0.1,unit:""}},dur);a.onComplete.subscribe(function(){tvanim.onComplete()});a.animate()},onComplete:function(){var s=this.el.style;s.display="none";s.opacity=1;s.filter="alpha(opacity=100)";this.callback()},toString:function(){return"TVFadeOut"}};YAHOO.register("treeview",YAHOO.widget.TreeView,{version:"2.9.0",build:"2800"});
143   -//
144   -//../pacotes/yui290/build/button/button-min.js
145   -/*
146   -Copyright (c) 2011, Yahoo! Inc. All rights reserved.
147   -Code licensed under the BSD License:
148   -http://developer.yahoo.com/yui/license.html
149   -version: 2.9.0
150   -*/
151   -(function(){var G=YAHOO.util.Dom,M=YAHOO.util.Event,I=YAHOO.lang,L=YAHOO.env.ua,B=YAHOO.widget.Overlay,J=YAHOO.widget.Menu,D={},K=null,E=null,C=null;function F(O,N,R,P){var S,Q;if(I.isString(O)&&I.isString(N)){if(L.ie&&(L.ie<9)){Q='<input type="'+O+'" name="'+N+'"';if(P){Q+=" checked";}Q+=">";S=document.createElement(Q);S.value=R;}else{S=document.createElement("input");S.name=N;S.type=O;S.value=R;if(P){S.checked=true;}}}return S;}function H(O,V){var N=O.nodeName.toUpperCase(),S=(this.CLASS_NAME_PREFIX+this.CSS_CLASS_NAME),T=this,U,P,Q;function W(X){if(!(X in V)){U=O.getAttributeNode(X);if(U&&("value" in U)){V[X]=U.value;}}}function R(){W("type");if(V.type=="button"){V.type="push";}if(!("disabled" in V)){V.disabled=O.disabled;}W("name");W("value");W("title");}switch(N){case"A":V.type="link";W("href");W("target");break;case"INPUT":R();if(!("checked" in V)){V.checked=O.checked;}break;case"BUTTON":R();P=O.parentNode.parentNode;if(G.hasClass(P,S+"-checked")){V.checked=true;}if(G.hasClass(P,S+"-disabled")){V.disabled=true;}O.removeAttribute("value");O.setAttribute("type","button");break;}O.removeAttribute("id");O.removeAttribute("name");if(!("tabindex" in V)){V.tabindex=O.tabIndex;}if(!("label" in V)){Q=N=="INPUT"?O.value:O.innerHTML;if(Q&&Q.length>0){V.label=Q;}}}function A(P){var O=P.attributes,N=O.srcelement,R=N.nodeName.toUpperCase(),Q=this;if(R==this.NODE_NAME){P.element=N;P.id=N.id;G.getElementsBy(function(S){switch(S.nodeName.toUpperCase()){case"BUTTON":case"A":case"INPUT":H.call(Q,S,O);break;}},"*",N);}else{switch(R){case"BUTTON":case"A":case"INPUT":H.call(this,N,O);break;}}}YAHOO.widget.Button=function(R,O){if(!B&&YAHOO.widget.Overlay){B=YAHOO.widget.Overlay;}if(!J&&YAHOO.widget.Menu){J=YAHOO.widget.Menu;}var Q=YAHOO.widget.Button.superclass.constructor,P,N;if(arguments.length==1&&!I.isString(R)&&!R.nodeName){if(!R.id){R.id=G.generateId();}Q.call(this,(this.createButtonElement(R.type)),R);}else{P={element:null,attributes:(O||{})};if(I.isString(R)){N=G.get(R);if(N){if(!P.attributes.id){P.attributes.id=R;}P.attributes.srcelement=N;A.call(this,P);if(!P.element){P.element=this.createButtonElement(P.attributes.type);}Q.call(this,P.element,P.attributes);}}else{if(R.nodeName){if(!P.attributes.id){if(R.id){P.attributes.id=R.id;}else{P.attributes.id=G.generateId();}}P.attributes.srcelement=R;A.call(this,P);if(!P.element){P.element=this.createButtonElement(P.attributes.type);}Q.call(this,P.element,P.attributes);}}}};YAHOO.extend(YAHOO.widget.Button,YAHOO.util.Element,{_button:null,_menu:null,_hiddenFields:null,_onclickAttributeValue:null,_activationKeyPressed:false,_activationButtonPressed:false,_hasKeyEventHandlers:false,_hasMouseEventHandlers:false,_nOptionRegionX:0,CLASS_NAME_PREFIX:"yui-",NODE_NAME:"SPAN",CHECK_ACTIVATION_KEYS:[32],ACTIVATION_KEYS:[13,32],OPTION_AREA_WIDTH:20,CSS_CLASS_NAME:"button",_setType:function(N){if(N=="split"){this.on("option",this._onOption);}},_setLabel:function(O){this._button.innerHTML=O;var P,N=L.gecko;if(N&&N<1.9&&G.inDocument(this.get("element"))){P=(this.CLASS_NAME_PREFIX+this.CSS_CLASS_NAME);this.removeClass(P);I.later(0,this,this.addClass,P);}},_setTabIndex:function(N){this._button.tabIndex=N;},_setTitle:function(N){if(this.get("type")!="link"){this._button.title=N;}},_setDisabled:function(N){if(this.get("type")!="link"){if(N){if(this._menu){this._menu.hide();}if(this.hasFocus()){this.blur();}this._button.setAttribute("disabled","disabled");this.addStateCSSClasses("disabled");this.removeStateCSSClasses("hover");this.removeStateCSSClasses("active");this.removeStateCSSClasses("focus");}else{this._button.removeAttribute("disabled");this.removeStateCSSClasses("disabled");}}},_setHref:function(N){if(this.get("type")=="link"){this._button.href=N;}},_setTarget:function(N){if(this.get("type")=="link"){this._button.setAttribute("target",N);}},_setChecked:function(N){var O=this.get("type");if(O=="checkbox"||O=="radio"){if(N){this.addStateCSSClasses("checked");}else{this.removeStateCSSClasses("checked");}}},_setMenu:function(U){var P=this.get("lazyloadmenu"),R=this.get("element"),N,W=false,X,O,Q;function V(){X.render(R.parentNode);this.removeListener("appendTo",V);}function T(){X.cfg.queueProperty("container",R.parentNode);this.removeListener("appendTo",T);}function S(){var Y;if(X){G.addClass(X.element,this.get("menuclassname"));G.addClass(X.element,this.CLASS_NAME_PREFIX+this.get("type")+"-button-menu");X.showEvent.subscribe(this._onMenuShow,null,this);X.hideEvent.subscribe(this._onMenuHide,null,this);X.renderEvent.subscribe(this._onMenuRender,null,this);if(J&&X instanceof J){if(P){Y=this.get("container");if(Y){X.cfg.queueProperty("container",Y);}else{this.on("appendTo",T);}}X.cfg.queueProperty("clicktohide",false);X.keyDownEvent.subscribe(this._onMenuKeyDown,this,true);X.subscribe("click",this._onMenuClick,this,true);this.on("selectedMenuItemChange",this._onSelectedMenuItemChange);Q=X.srcElement;if(Q&&Q.nodeName.toUpperCase()=="SELECT"){Q.style.display="none";Q.parentNode.removeChild(Q);}}else{if(B&&X instanceof B){if(!K){K=new YAHOO.widget.OverlayManager();}K.register(X);}}this._menu=X;if(!W&&!P){if(G.inDocument(R)){X.render(R.parentNode);}else{this.on("appendTo",V);}}}}if(B){if(J){N=J.prototype.CSS_CLASS_NAME;}if(U&&J&&(U instanceof J)){X=U;W=true;S.call(this);}else{if(B&&U&&(U instanceof B)){X=U;W=true;X.cfg.queueProperty("visible",false);S.call(this);}else{if(J&&I.isArray(U)){X=new J(G.generateId(),{lazyload:P,itemdata:U});this._menu=X;this.on("appendTo",S);}else{if(I.isString(U)){O=G.get(U);if(O){if(J&&G.hasClass(O,N)||O.nodeName.toUpperCase()=="SELECT"){X=new J(U,{lazyload:P});S.call(this);}else{if(B){X=new B(U,{visible:false});S.call(this);}}}}else{if(U&&U.nodeName){if(J&&G.hasClass(U,N)||U.nodeName.toUpperCase()=="SELECT"){X=new J(U,{lazyload:P});S.call(this);}else{if(B){if(!U.id){G.generateId(U);}X=new B(U,{visible:false});S.call(this);}}}}}}}}},_setOnClick:function(N){if(this._onclickAttributeValue&&(this._onclickAttributeValue!=N)){this.removeListener("click",this._onclickAttributeValue.fn);
152   -this._onclickAttributeValue=null;}if(!this._onclickAttributeValue&&I.isObject(N)&&I.isFunction(N.fn)){this.on("click",N.fn,N.obj,N.scope);this._onclickAttributeValue=N;}},_isActivationKey:function(N){var S=this.get("type"),O=(S=="checkbox"||S=="radio")?this.CHECK_ACTIVATION_KEYS:this.ACTIVATION_KEYS,Q=O.length,R=false,P;if(Q>0){P=Q-1;do{if(N==O[P]){R=true;break;}}while(P--);}return R;},_isSplitButtonOptionKey:function(P){var O=(M.getCharCode(P)==40);var N=function(Q){M.preventDefault(Q);this.removeListener("keypress",N);};if(O){if(L.opera){this.on("keypress",N);}M.preventDefault(P);}return O;},_addListenersToForm:function(){var T=this.getForm(),S=YAHOO.widget.Button.onFormKeyPress,R,N,Q,P,O;if(T){M.on(T,"reset",this._onFormReset,null,this);M.on(T,"submit",this._onFormSubmit,null,this);N=this.get("srcelement");if(this.get("type")=="submit"||(N&&N.type=="submit")){Q=M.getListeners(T,"keypress");R=false;if(Q){P=Q.length;if(P>0){O=P-1;do{if(Q[O].fn==S){R=true;break;}}while(O--);}}if(!R){M.on(T,"keypress",S);}}}},_showMenu:function(R){if(YAHOO.widget.MenuManager){YAHOO.widget.MenuManager.hideVisible();}if(K){K.hideAll();}var N=this._menu,Q=this.get("menualignment"),P=this.get("focusmenu"),O;if(this._renderedMenu){N.cfg.setProperty("context",[this.get("element"),Q[0],Q[1]]);N.cfg.setProperty("preventcontextoverlap",true);N.cfg.setProperty("constraintoviewport",true);}else{N.cfg.queueProperty("context",[this.get("element"),Q[0],Q[1]]);N.cfg.queueProperty("preventcontextoverlap",true);N.cfg.queueProperty("constraintoviewport",true);}this.focus();if(J&&N&&(N instanceof J)){O=N.focus;N.focus=function(){};if(this._renderedMenu){N.cfg.setProperty("minscrollheight",this.get("menuminscrollheight"));N.cfg.setProperty("maxheight",this.get("menumaxheight"));}else{N.cfg.queueProperty("minscrollheight",this.get("menuminscrollheight"));N.cfg.queueProperty("maxheight",this.get("menumaxheight"));}N.show();N.focus=O;N.align();if(R.type=="mousedown"){M.stopPropagation(R);}if(P){N.focus();}}else{if(B&&N&&(N instanceof B)){if(!this._renderedMenu){N.render(this.get("element").parentNode);}N.show();N.align();}}},_hideMenu:function(){var N=this._menu;if(N){N.hide();}},_onMouseOver:function(O){var Q=this.get("type"),N,P;if(Q==="split"){N=this.get("element");P=(G.getX(N)+(N.offsetWidth-this.OPTION_AREA_WIDTH));this._nOptionRegionX=P;}if(!this._hasMouseEventHandlers){if(Q==="split"){this.on("mousemove",this._onMouseMove);}this.on("mouseout",this._onMouseOut);this._hasMouseEventHandlers=true;}this.addStateCSSClasses("hover");if(Q==="split"&&(M.getPageX(O)>P)){this.addStateCSSClasses("hoveroption");}if(this._activationButtonPressed){this.addStateCSSClasses("active");}if(this._bOptionPressed){this.addStateCSSClasses("activeoption");}if(this._activationButtonPressed||this._bOptionPressed){M.removeListener(document,"mouseup",this._onDocumentMouseUp);}},_onMouseMove:function(N){var O=this._nOptionRegionX;if(O){if(M.getPageX(N)>O){this.addStateCSSClasses("hoveroption");}else{this.removeStateCSSClasses("hoveroption");}}},_onMouseOut:function(N){var O=this.get("type");this.removeStateCSSClasses("hover");if(O!="menu"){this.removeStateCSSClasses("active");}if(this._activationButtonPressed||this._bOptionPressed){M.on(document,"mouseup",this._onDocumentMouseUp,null,this);}if(O==="split"&&(M.getPageX(N)>this._nOptionRegionX)){this.removeStateCSSClasses("hoveroption");}},_onDocumentMouseUp:function(P){this._activationButtonPressed=false;this._bOptionPressed=false;var Q=this.get("type"),N,O;if(Q=="menu"||Q=="split"){N=M.getTarget(P);O=this._menu.element;if(N!=O&&!G.isAncestor(O,N)){this.removeStateCSSClasses((Q=="menu"?"active":"activeoption"));this._hideMenu();}}M.removeListener(document,"mouseup",this._onDocumentMouseUp);},_onMouseDown:function(P){var Q,O=true;function N(){this._hideMenu();this.removeListener("mouseup",N);}if((P.which||P.button)==1){if(!this.hasFocus()){I.later(0,this,this.focus);}Q=this.get("type");if(Q=="split"){if(M.getPageX(P)>this._nOptionRegionX){this.fireEvent("option",P);O=false;}else{this.addStateCSSClasses("active");this._activationButtonPressed=true;}}else{if(Q=="menu"){if(this.isActive()){this._hideMenu();this._activationButtonPressed=false;}else{this._showMenu(P);this._activationButtonPressed=true;}}else{this.addStateCSSClasses("active");this._activationButtonPressed=true;}}if(Q=="split"||Q=="menu"){this._hideMenuTimer=I.later(250,this,this.on,["mouseup",N]);}}return O;},_onMouseUp:function(P){this.inMouseDown=false;var Q=this.get("type"),N=this._hideMenuTimer,O=true;if(N){N.cancel();}if(Q=="checkbox"||Q=="radio"){if((P.which||P.button)!=1){return;}this.set("checked",!(this.get("checked")));}this._activationButtonPressed=false;if(Q!="menu"){this.removeStateCSSClasses("active");}if(Q=="split"&&M.getPageX(P)>this._nOptionRegionX){O=false;}return O;},_onFocus:function(O){var N;this.addStateCSSClasses("focus");if(this._activationKeyPressed){this.addStateCSSClasses("active");}C=this;if(!this._hasKeyEventHandlers){N=this._button;M.on(N,"blur",this._onBlur,null,this);M.on(N,"keydown",this._onKeyDown,null,this);M.on(N,"keyup",this._onKeyUp,null,this);this._hasKeyEventHandlers=true;}this.fireEvent("focus",O);},_onBlur:function(N){this.removeStateCSSClasses("focus");if(this.get("type")!="menu"){this.removeStateCSSClasses("active");}if(this._activationKeyPressed){M.on(document,"keyup",this._onDocumentKeyUp,null,this);}C=null;this.fireEvent("blur",N);},_onDocumentKeyUp:function(N){if(this._isActivationKey(M.getCharCode(N))){this._activationKeyPressed=false;M.removeListener(document,"keyup",this._onDocumentKeyUp);}},_onKeyDown:function(O){var N=this._menu;if(this.get("type")=="split"&&this._isSplitButtonOptionKey(O)){this.fireEvent("option",O);}else{if(this._isActivationKey(M.getCharCode(O))){if(this.get("type")=="menu"){this._showMenu(O);}else{this._activationKeyPressed=true;this.addStateCSSClasses("active");}}}if(N&&N.cfg.getProperty("visible")&&M.getCharCode(O)==27){N.hide();this.focus();}},_onKeyUp:function(N){var O;
153   -if(this._isActivationKey(M.getCharCode(N))){O=this.get("type");if(O=="checkbox"||O=="radio"){this.set("checked",!(this.get("checked")));}this._activationKeyPressed=false;if(this.get("type")!="menu"){this.removeStateCSSClasses("active");}}},_onClick:function(P){var R=this.get("type"),Q,N,O;switch(R){case"submit":if(P.returnValue!==false){this.submitForm();}break;case"reset":Q=this.getForm();if(Q){Q.reset();}break;case"split":if(this._nOptionRegionX>0&&(M.getPageX(P)>this._nOptionRegionX)){O=false;}else{this._hideMenu();N=this.get("srcelement");if(N&&N.type=="submit"&&P.returnValue!==false){this.submitForm();}}break;}return O;},_onDblClick:function(O){var N=true;if(this.get("type")=="split"&&M.getPageX(O)>this._nOptionRegionX){N=false;}return N;},_onAppendTo:function(N){I.later(0,this,this._addListenersToForm);},_onFormReset:function(O){var P=this.get("type"),N=this._menu;if(P=="checkbox"||P=="radio"){this.resetValue("checked");}if(J&&N&&(N instanceof J)){this.resetValue("selectedMenuItem");}},_onFormSubmit:function(N){this.createHiddenFields();},_onDocumentMouseDown:function(R){var O=M.getTarget(R),Q=this.get("element"),P=this._menu.element;function N(T){var V,S,U;if(!T){return true;}for(V=0,S=T.length;V<S;V++){U=T[V].element;if(O==U||G.isAncestor(U,O)){return true;}if(T[V]&&T[V].getSubmenus){if(N(T[V].getSubmenus())){return true;}}}return false;}if(O!=Q&&!G.isAncestor(Q,O)&&O!=P&&!G.isAncestor(P,O)){if(this._menu&&this._menu.getSubmenus){if(!N(this._menu.getSubmenus())){return;}}this._hideMenu();if(L.ie&&(L.ie<9)&&O.focus){O.setActive();}M.removeListener(document,"mousedown",this._onDocumentMouseDown);}},_onOption:function(N){if(this.hasClass(this.CLASS_NAME_PREFIX+"split-button-activeoption")){this._hideMenu();this._bOptionPressed=false;}else{this._showMenu(N);this._bOptionPressed=true;}},_onMenuShow:function(N){M.on(document,"mousedown",this._onDocumentMouseDown,null,this);var O=(this.get("type")=="split")?"activeoption":"active";this.addStateCSSClasses(O);},_onMenuHide:function(N){var O=(this.get("type")=="split")?"activeoption":"active";this.removeStateCSSClasses(O);if(this.get("type")=="split"){this._bOptionPressed=false;}},_onMenuKeyDown:function(P,O){var N=O[0];if(M.getCharCode(N)==27){this.focus();if(this.get("type")=="split"){this._bOptionPressed=false;}}},_onMenuRender:function(P){var S=this.get("element"),O=S.parentNode,N=this._menu,R=N.element,Q=N.srcElement,T;if(O!=R.parentNode){O.appendChild(R);}this._renderedMenu=true;if(Q&&Q.nodeName.toLowerCase()==="select"&&Q.value){T=N.getItem(Q.selectedIndex);this.set("selectedMenuItem",T,true);this._onSelectedMenuItemChange({newValue:T});}},_onMenuClick:function(O,N){var Q=N[1],P;if(Q){this.set("selectedMenuItem",Q);P=this.get("srcelement");if(P&&P.type=="submit"){this.submitForm();}this._hideMenu();}},_onSelectedMenuItemChange:function(O){var P=O.prevValue,Q=O.newValue,N=this.CLASS_NAME_PREFIX;if(P){G.removeClass(P.element,(N+"button-selectedmenuitem"));}if(Q){G.addClass(Q.element,(N+"button-selectedmenuitem"));}},_onLabelClick:function(N){this.focus();var O=this.get("type");if(O=="radio"||O=="checkbox"){this.set("checked",(!this.get("checked")));}},createButtonElement:function(N){var P=this.NODE_NAME,O=document.createElement(P);O.innerHTML="<"+P+' class="first-child">'+(N=="link"?"<a></a>":'<button type="button"></button>')+"</"+P+">";return O;},addStateCSSClasses:function(O){var P=this.get("type"),N=this.CLASS_NAME_PREFIX;if(I.isString(O)){if(O!="activeoption"&&O!="hoveroption"){this.addClass(N+this.CSS_CLASS_NAME+("-"+O));}this.addClass(N+P+("-button-"+O));}},removeStateCSSClasses:function(O){var P=this.get("type"),N=this.CLASS_NAME_PREFIX;if(I.isString(O)){this.removeClass(N+this.CSS_CLASS_NAME+("-"+O));this.removeClass(N+P+("-button-"+O));}},createHiddenFields:function(){this.removeHiddenFields();var V=this.getForm(),Z,O,S,X,Y,T,U,N,R,W,P,Q=false;if(V&&!this.get("disabled")){O=this.get("type");S=(O=="checkbox"||O=="radio");if((S&&this.get("checked"))||(E==this)){Z=F((S?O:"hidden"),this.get("name"),this.get("value"),this.get("checked"));if(Z){if(S){Z.style.display="none";}V.appendChild(Z);}}X=this._menu;if(J&&X&&(X instanceof J)){Y=this.get("selectedMenuItem");P=X.srcElement;Q=(P&&P.nodeName.toUpperCase()=="SELECT");if(Y){U=(Y.value===null||Y.value==="")?Y.cfg.getProperty("text"):Y.value;T=this.get("name");if(Q){W=P.name;}else{if(T){W=(T+"_options");}}if(U&&W){N=F("hidden",W,U);V.appendChild(N);}}else{if(Q){N=V.appendChild(P);}}}if(Z&&N){this._hiddenFields=[Z,N];}else{if(!Z&&N){this._hiddenFields=N;}else{if(Z&&!N){this._hiddenFields=Z;}}}R=this._hiddenFields;}return R;},removeHiddenFields:function(){var Q=this._hiddenFields,O,P;function N(R){if(G.inDocument(R)){R.parentNode.removeChild(R);}}if(Q){if(I.isArray(Q)){O=Q.length;if(O>0){P=O-1;do{N(Q[P]);}while(P--);}}else{N(Q);}this._hiddenFields=null;}},submitForm:function(){var Q=this.getForm(),P=this.get("srcelement"),O=false,N;if(Q){if(this.get("type")=="submit"||(P&&P.type=="submit")){E=this;}if(L.ie&&(L.ie<9)){O=Q.fireEvent("onsubmit");}else{N=document.createEvent("HTMLEvents");N.initEvent("submit",true,true);O=Q.dispatchEvent(N);}if((L.ie||L.webkit)&&O){Q.submit();}}return O;},init:function(P,d){var V=d.type=="link"?"a":"button",a=d.srcelement,S=P.getElementsByTagName(V)[0],U;if(!S){U=P.getElementsByTagName("input")[0];if(U){S=document.createElement("button");S.setAttribute("type","button");U.parentNode.replaceChild(S,U);}}this._button=S;YAHOO.widget.Button.superclass.init.call(this,P,d);var T=this.get("id"),Z=T+"-button";S.id=Z;var X,Q;var e=function(f){return(f.htmlFor===T);};var c=function(){Q.setAttribute((L.ie?"htmlFor":"for"),Z);};if(a&&this.get("type")!="link"){X=G.getElementsBy(e,"label");if(I.isArray(X)&&X.length>0){Q=X[0];}}D[T]=this;var b=this.CLASS_NAME_PREFIX;this.addClass(b+this.CSS_CLASS_NAME);this.addClass(b+this.get("type")+"-button");M.on(this._button,"focus",this._onFocus,null,this);this.on("mouseover",this._onMouseOver);this.on("mousedown",this._onMouseDown);
154   -this.on("mouseup",this._onMouseUp);this.on("click",this._onClick);var R=this.get("onclick");this.set("onclick",null);this.set("onclick",R);this.on("dblclick",this._onDblClick);var O;if(Q){if(this.get("replaceLabel")){this.set("label",Q.innerHTML);O=Q.parentNode;O.removeChild(Q);}else{this.on("appendTo",c);M.on(Q,"click",this._onLabelClick,null,this);this._label=Q;}}this.on("appendTo",this._onAppendTo);var N=this.get("container"),Y=this.get("element"),W=G.inDocument(Y);if(N){if(a&&a!=Y){O=a.parentNode;if(O){O.removeChild(a);}}if(I.isString(N)){M.onContentReady(N,this.appendTo,N,this);}else{this.on("init",function(){I.later(0,this,this.appendTo,N);});}}else{if(!W&&a&&a!=Y){O=a.parentNode;if(O){this.fireEvent("beforeAppendTo",{type:"beforeAppendTo",target:O});O.replaceChild(Y,a);this.fireEvent("appendTo",{type:"appendTo",target:O});}}else{if(this.get("type")!="link"&&W&&a&&a==Y){this._addListenersToForm();}}}this.fireEvent("init",{type:"init",target:this});},initAttributes:function(O){var N=O||{};YAHOO.widget.Button.superclass.initAttributes.call(this,N);this.setAttributeConfig("type",{value:(N.type||"push"),validator:I.isString,writeOnce:true,method:this._setType});this.setAttributeConfig("label",{value:N.label,validator:I.isString,method:this._setLabel});this.setAttributeConfig("value",{value:N.value});this.setAttributeConfig("name",{value:N.name,validator:I.isString});this.setAttributeConfig("tabindex",{value:N.tabindex,validator:I.isNumber,method:this._setTabIndex});this.configureAttribute("title",{value:N.title,validator:I.isString,method:this._setTitle});this.setAttributeConfig("disabled",{value:(N.disabled||false),validator:I.isBoolean,method:this._setDisabled});this.setAttributeConfig("href",{value:N.href,validator:I.isString,method:this._setHref});this.setAttributeConfig("target",{value:N.target,validator:I.isString,method:this._setTarget});this.setAttributeConfig("checked",{value:(N.checked||false),validator:I.isBoolean,method:this._setChecked});this.setAttributeConfig("container",{value:N.container,writeOnce:true});this.setAttributeConfig("srcelement",{value:N.srcelement,writeOnce:true});this.setAttributeConfig("menu",{value:null,method:this._setMenu,writeOnce:true});this.setAttributeConfig("lazyloadmenu",{value:(N.lazyloadmenu===false?false:true),validator:I.isBoolean,writeOnce:true});this.setAttributeConfig("menuclassname",{value:(N.menuclassname||(this.CLASS_NAME_PREFIX+"button-menu")),validator:I.isString,method:this._setMenuClassName,writeOnce:true});this.setAttributeConfig("menuminscrollheight",{value:(N.menuminscrollheight||90),validator:I.isNumber});this.setAttributeConfig("menumaxheight",{value:(N.menumaxheight||0),validator:I.isNumber});this.setAttributeConfig("menualignment",{value:(N.menualignment||["tl","bl"]),validator:I.isArray});this.setAttributeConfig("selectedMenuItem",{value:null});this.setAttributeConfig("onclick",{value:N.onclick,method:this._setOnClick});this.setAttributeConfig("focusmenu",{value:(N.focusmenu===false?false:true),validator:I.isBoolean});this.setAttributeConfig("replaceLabel",{value:false,validator:I.isBoolean,writeOnce:true});},focus:function(){if(!this.get("disabled")){try{this._button.focus();}catch(N){}}},blur:function(){if(!this.get("disabled")){try{this._button.blur();}catch(N){}}},hasFocus:function(){return(C==this);},isActive:function(){return this.hasClass(this.CLASS_NAME_PREFIX+this.CSS_CLASS_NAME+"-active");},getMenu:function(){return this._menu;},getForm:function(){var N=this._button,O;if(N){O=N.form;}return O;},getHiddenFields:function(){return this._hiddenFields;},destroy:function(){var P=this.get("element"),N=this._menu,T=this._label,O,S;if(N){if(K&&K.find(N)){K.remove(N);}N.destroy();}M.purgeElement(P);M.purgeElement(this._button);M.removeListener(document,"mouseup",this._onDocumentMouseUp);M.removeListener(document,"keyup",this._onDocumentKeyUp);M.removeListener(document,"mousedown",this._onDocumentMouseDown);if(T){M.removeListener(T,"click",this._onLabelClick);O=T.parentNode;O.removeChild(T);}var Q=this.getForm();if(Q){M.removeListener(Q,"reset",this._onFormReset);M.removeListener(Q,"submit",this._onFormSubmit);}this.unsubscribeAll();O=P.parentNode;if(O){O.removeChild(P);}delete D[this.get("id")];var R=(this.CLASS_NAME_PREFIX+this.CSS_CLASS_NAME);S=G.getElementsByClassName(R,this.NODE_NAME,Q);if(I.isArray(S)&&S.length===0){M.removeListener(Q,"keypress",YAHOO.widget.Button.onFormKeyPress);}},fireEvent:function(O,N){var P=arguments[0];if(this.DOM_EVENTS[P]&&this.get("disabled")){return false;}return YAHOO.widget.Button.superclass.fireEvent.apply(this,arguments);},toString:function(){return("Button "+this.get("id"));}});YAHOO.widget.Button.onFormKeyPress=function(R){var P=M.getTarget(R),S=M.getCharCode(R),Q=P.nodeName&&P.nodeName.toUpperCase(),N=P.type,T=false,V,X,O,W;function U(a){var Z,Y;switch(a.nodeName.toUpperCase()){case"INPUT":case"BUTTON":if(a.type=="submit"&&!a.disabled){if(!T&&!O){O=a;}}break;default:Z=a.id;if(Z){V=D[Z];if(V){T=true;if(!V.get("disabled")){Y=V.get("srcelement");if(!X&&(V.get("type")=="submit"||(Y&&Y.type=="submit"))){X=V;}}}}break;}}if(S==13&&((Q=="INPUT"&&(N=="text"||N=="password"||N=="checkbox"||N=="radio"||N=="file"))||Q=="SELECT")){G.getElementsBy(U,"*",this);if(O){O.focus();}else{if(!O&&X){M.preventDefault(R);if(L.ie){X.get("element").fireEvent("onclick");}else{W=document.createEvent("HTMLEvents");W.initEvent("click",true,true);if(L.gecko<1.9){X.fireEvent("click",W);}else{X.get("element").dispatchEvent(W);}}}}}};YAHOO.widget.Button.addHiddenFieldsToForm=function(N){var R=YAHOO.widget.Button.prototype,T=G.getElementsByClassName((R.CLASS_NAME_PREFIX+R.CSS_CLASS_NAME),"*",N),Q=T.length,S,O,P;if(Q>0){for(P=0;P<Q;P++){O=T[P].id;if(O){S=D[O];if(S){S.createHiddenFields();}}}}};YAHOO.widget.Button.getButton=function(N){return D[N];};})();(function(){var C=YAHOO.util.Dom,B=YAHOO.util.Event,D=YAHOO.lang,A=YAHOO.widget.Button,E={};YAHOO.widget.ButtonGroup=function(J,H){var I=YAHOO.widget.ButtonGroup.superclass.constructor,K,G,F;
155   -if(arguments.length==1&&!D.isString(J)&&!J.nodeName){if(!J.id){F=C.generateId();J.id=F;}I.call(this,(this._createGroupElement()),J);}else{if(D.isString(J)){G=C.get(J);if(G){if(G.nodeName.toUpperCase()==this.NODE_NAME){I.call(this,G,H);}}}else{K=J.nodeName.toUpperCase();if(K&&K==this.NODE_NAME){if(!J.id){J.id=C.generateId();}I.call(this,J,H);}}}};YAHOO.extend(YAHOO.widget.ButtonGroup,YAHOO.util.Element,{_buttons:null,NODE_NAME:"DIV",CLASS_NAME_PREFIX:"yui-",CSS_CLASS_NAME:"buttongroup",_createGroupElement:function(){var F=document.createElement(this.NODE_NAME);return F;},_setDisabled:function(G){var H=this.getCount(),F;if(H>0){F=H-1;do{this._buttons[F].set("disabled",G);}while(F--);}},_onKeyDown:function(K){var G=B.getTarget(K),I=B.getCharCode(K),H=G.parentNode.parentNode.id,J=E[H],F=-1;if(I==37||I==38){F=(J.index===0)?(this._buttons.length-1):(J.index-1);}else{if(I==39||I==40){F=(J.index===(this._buttons.length-1))?0:(J.index+1);}}if(F>-1){this.check(F);this.getButton(F).focus();}},_onAppendTo:function(H){var I=this._buttons,G=I.length,F;for(F=0;F<G;F++){I[F].appendTo(this.get("element"));}},_onButtonCheckedChange:function(G,F){var I=G.newValue,H=this.get("checkedButton");if(I&&H!=F){if(H){H.set("checked",false,true);}this.set("checkedButton",F);this.set("value",F.get("value"));}else{if(H&&!H.set("checked")){H.set("checked",true,true);}}},init:function(I,H){this._buttons=[];YAHOO.widget.ButtonGroup.superclass.init.call(this,I,H);this.addClass(this.CLASS_NAME_PREFIX+this.CSS_CLASS_NAME);var K=(YAHOO.widget.Button.prototype.CLASS_NAME_PREFIX+"radio-button"),J=this.getElementsByClassName(K);if(J.length>0){this.addButtons(J);}function F(L){return(L.type=="radio");}J=C.getElementsBy(F,"input",this.get("element"));if(J.length>0){this.addButtons(J);}this.on("keydown",this._onKeyDown);this.on("appendTo",this._onAppendTo);var G=this.get("container");if(G){if(D.isString(G)){B.onContentReady(G,function(){this.appendTo(G);},null,this);}else{this.appendTo(G);}}},initAttributes:function(G){var F=G||{};YAHOO.widget.ButtonGroup.superclass.initAttributes.call(this,F);this.setAttributeConfig("name",{value:F.name,validator:D.isString});this.setAttributeConfig("disabled",{value:(F.disabled||false),validator:D.isBoolean,method:this._setDisabled});this.setAttributeConfig("value",{value:F.value});this.setAttributeConfig("container",{value:F.container,writeOnce:true});this.setAttributeConfig("checkedButton",{value:null});},addButton:function(J){var L,K,G,F,H,I;if(J instanceof A&&J.get("type")=="radio"){L=J;}else{if(!D.isString(J)&&!J.nodeName){J.type="radio";L=new A(J);}else{L=new A(J,{type:"radio"});}}if(L){F=this._buttons.length;H=L.get("name");I=this.get("name");L.index=F;this._buttons[F]=L;E[L.get("id")]=L;if(H!=I){L.set("name",I);}if(this.get("disabled")){L.set("disabled",true);}if(L.get("checked")){this.set("checkedButton",L);}K=L.get("element");G=this.get("element");if(K.parentNode!=G){G.appendChild(K);}L.on("checkedChange",this._onButtonCheckedChange,L,this);}return L;},addButtons:function(G){var H,I,J,F;if(D.isArray(G)){H=G.length;J=[];if(H>0){for(F=0;F<H;F++){I=this.addButton(G[F]);if(I){J[J.length]=I;}}}}return J;},removeButton:function(H){var I=this.getButton(H),G,F;if(I){this._buttons.splice(H,1);delete E[I.get("id")];I.removeListener("checkedChange",this._onButtonCheckedChange);I.destroy();G=this._buttons.length;if(G>0){F=this._buttons.length-1;do{this._buttons[F].index=F;}while(F--);}}},getButton:function(F){return this._buttons[F];},getButtons:function(){return this._buttons;},getCount:function(){return this._buttons.length;},focus:function(H){var I,G,F;if(D.isNumber(H)){I=this._buttons[H];if(I){I.focus();}}else{G=this.getCount();for(F=0;F<G;F++){I=this._buttons[F];if(!I.get("disabled")){I.focus();break;}}}},check:function(F){var G=this.getButton(F);if(G){G.set("checked",true);}},destroy:function(){var I=this._buttons.length,H=this.get("element"),F=H.parentNode,G;if(I>0){G=this._buttons.length-1;do{this._buttons[G].destroy();}while(G--);}B.purgeElement(H);F.removeChild(H);},toString:function(){return("ButtonGroup "+this.get("id"));}});})();YAHOO.register("button",YAHOO.widget.Button,{version:"2.9.0",build:"2800"});
156   -//
157 141 //../pacotes/yui290/build/json/json-min.js
158 142 /*
159 143 Copyright (c) 2011, Yahoo! Inc. All rights reserved.
... ...
js/i3geonaocompacto.js
... ... @@ -80,7 +80,7 @@ OpenLayers = {
80 80 "../pacotes/yui290/build/tabview/tabview-min.js",
81 81 "../pacotes/cpaint/cpaint2.inc.js",
82 82 //"../pacotes/yui290/build/treeview/treeview.js",
83   - "../pacotes/yui290/build/button/button-min.js",
  83 + //"../pacotes/yui290/build/button/button-min.js",
84 84 "../pacotes/yui290/build/json/json-min.js",
85 85 "../pacotes/yui290/build/resize/resize-min.js",
86 86 //"../pacotes/yui290/build/progressbar/progressbar-min.js",
... ...
js/janela.js
... ... @@ -302,12 +302,12 @@ i3GEO.janela =
302 302 janela.moveTo(nx, ny + 50);
303 303 }
304 304 YAHOO.i3GEO.janela.manager.register(janela);
305   - janela.cfg.setProperty("effect", [
306   - {
307   - effect : YAHOO.widget.ContainerEffect.FADE,
308   - duration : 0.5
309   - }
310   - ]);
  305 + janela.cfg.setProperty("effect", [
  306 + {
  307 + effect : YAHOO.widget.ContainerEffect.FADE,
  308 + duration : 0.5
  309 + }
  310 + ]);
311 311  
312 312 janela.cfg.setProperty("zIndex", [
313 313 4
... ...
pacotes/cpaint/cpaint2_compacto.inc.js 100755 → 100644
pacotes/mobileesp/mdetect_compacto.js 100755 → 100644
pacotes/yui290/build/carousel/carousel_compacto.js 100755 → 100644
pacotes/yui290/build/container/container_compacto.js 100755 → 100644
pacotes/yui290/build/container/container_core_compacto.js 100755 → 100644
pacotes/yui290/build/resize/resize_compacto.js 100755 → 100644
pacotes/yui290/build/treeview/treeview_compacto.js 100755 → 100644
pacotes/yui290/build/utilities/utilities_compacto.js 100755 → 100644