fix_e=function(e){if(!e&&window.event){e=window.event;e.preventDefault=fix_e_preventDefault;e.stopPropagation=fix_e_stopPropagation;}
if(!e.target)e.target=e.srcElement;if(undefined(e.pageX))e.pageX=e.clientX+document.documentElement.scrollLeft+document.body.scrollLeft;if(undefined(e.pageY))e.pageY=e.clientY+document.documentElement.scrollTop+document.body.scrollTop;return e;}
fix_e_preventDefault=function(){this.returnValue=false;};fix_e_stopPropagation=function(){this.cancelBubble=true;};delayed_events_onload=[];addEventOnLoad=function(e,t,h){delayed_events_onload[delayed_events_onload.length]=[e,t,h];}
triggerAddEventsOnLoad=function(){for(var i=0;i<delayed_events_onload.length;i++){var e=delayed_events_onload[i];addEvent(e[0],e[1],e[2]);}}
addEvent=function(jb,kb,lb){if(typeof jb=="undefined")return;if(!lb.$$guid)lb.$$guid=addEvent.guid++;if(!jb.events)jb.events={};var mb=jb.events[kb];if(!mb){mb=jb.events[kb]={};if(jb["on"+kb]){mb[0]=jb["on"+kb];}}
mb[lb.$$guid]=lb;jb["on"+kb]=handleEvent;};addEvent.guid=1;removeEvent=function(nb,ob,pb){if(nb.events&&nb.events[ob]){delete nb.events[ob][pb.$$guid];}};handleEvent=function(qb){var rb=null;if(typeof fix_e=="undefined")return;qb=fix_e(qb);var sb=this.events[qb.type];for(var i in sb){if(sb[i]!=Object.prototype[i]){this.$$handleEvent=sb[i];var tb=this.$$handleEvent(qb);if(tb===false){rb=false;}else if(tb===true){rb=true;}}}
if(rb!=null)return rb;};elem=function(id){var ub;if(document.getElementById){ub=document.getElementById(id);}else if(document.all){ub=document.all[id];}
return ub;}
getObject=elem;isDefined=function(vb){return(typeof vb!="undefined");}
undefined=function(wb){return typeof wb=="undefined";}
function Base(){}
Base.prototype={extend:function(xb,c){if(undefined(c)){c=function(){}}
c.prototype=this;for(var yb in xb){if(yb!="extend"){c.prototype[yb]=xb[yb];}}
return c;}}
objinspect=function(zb){var Ab="===================\n";for(var i in zb){if(zb[i]){Ab+=i+" "+zb[i]+"\n";}}
Ab+="====================\n";debug(Ab);}
debug=function(Bb){Log.debug(Bb);}
assert=function(Cb,Db){if(!Cb){Log.error("Assertion error: "+Db);}}
firstLogTime=(new Date()).getTime();function LogMessage(Eb,Fb){this.message=Eb;this.code=Fb;this.time=(new Date()).getTime();}
LogMessage.prototype.toString=function(){return(this.time-firstLogTime)+" "+this.code+" "+this.message;}
Log={ERROR:"ERROR",INTERNAL_ERROR:"ERROR",CONSYN_ERROR:"CONSYN_ERROR",DEBUG:"DEBUG",_aa:[],debug:function(Gb){this._ba(Gb,this.DEBUG);},error:function(Hb){this._ba(Hb,this.ERROR);},consyn_error:function(Ib){this._ba(Ib,this.CONSYN_ERROR);},_ba:function(Jb,Kb){this._aa[this._aa.length]=new LogMessage(Jb,Kb);if(typeof getObject!="undefined"&&elem("debugBox")){elem("debugBox").value=this._aa.join("\n");}},getFullLog:function(){return this._aa.join("\n");}}
window.onerror=function(p1,p2,p3){Log.error(p1+"\n"+p2+"\n"+p3);};getIframe=function(Lb){if(Lb.contentWindow){return Lb.contentWindow;}else{return Lb;}}
getRealOffsetTop=function(Mb,Nb){if(undefined(Nb))Nb=document.body;var Ob=0;var Pb=Mb;while(Pb!=null&&Pb!=Nb){Ob+=Pb.offsetTop;Pb=Pb.offsetParent;}
return Ob;}
getRealOffsetLeft=function(Qb,Rb){if(undefined(Rb))Rb=document.body;var Sb=0;var Tb=Qb;while(Tb!=null&&Tb!=Rb){Sb+=Tb.offsetLeft;Tb=Tb.offsetParent;}
return Sb;}
addClassFront=function(Ub,Vb){Ub.className=Vb+" "+Ub.className;}
addClassBack=function(Wb,Xb){Wb.className=Wb.className+" "+Xb;}
removeClass=function(Yb,Zb){var $b=Yb.className.split(" ");var i=-1;while((i=$b.indexOf(Zb))>=0){$b.splice(i,1);}
Yb.className=$b.join(" ");}
hide=function(ac){ac.style.display='none';}
show=function(bc){bc.style.display='';}
function toggleDisplay(cc){if(cc.style.display=='none'){show(cc);}else{hide(cc);}}
setOffsetLeft=function(dc,ec){dc.style.left=ec+'px';}
setOffsetTop=function(fc,gc){fc.style.top=gc+'px';}
setOffset=function(hc,x,y){hc.style.left=x+'px';hc.style.top=y+'px';}
setSize=function(ic,h,w){ic.style.height=h+'px';ic.style.width=w+'px';}
DOM={ce:function(jc,kc,lc,mc){var n=document.createElement(jc);if(isDefined(kc)){for(var k in kc){n[k]=kc[k];}}
if(isDefined(lc)){for(var i=0;i<lc.length;i++){n.appendChild(lc[i]);}}
if(isDefined(mc)){for(var k in mc){addEvent(n,k,mc[k]);}}
return n;},text:function(nc){return document.createTextNode(nc);},appendNew:function(oc,pc){var n=document.createElement(oc);pc.appendChild(n);return n;},insertNewBefore:function(qc,rc){var n=document.createElement(qc);rc.parentNode.insertBefore(n,rc);return n;}};String.prototype.trim=function(){return this.replace(/^\s+|\s+$/g,"");};Array.prototype.indexOf=function(sc){var i=this.length-1;while(i>=0&&this[i]!=sc){i--;}
return i;}
Array.prototype.contains=function(tc){return(this.indexOf(tc)>=0);}
Array.prototype.each=function(uc){var vc=[];for(var i=0;i<this.length;i++){vc[i]=uc(this[i]);}
return vc;}
if(typeof Array.prototype.remove=="undefined"){Array.prototype.remove=function(el){var i=this.indexOf(el);if(i>=0){var wc=this.splice(i,1);return wc[0];}}}
if(typeof Array.prototype.push=="undefined"){Array.prototype.push=function(el){this[this.length]=el;return this.length;}}
if(typeof Array.prototype.pop=="undefined"){Array.prototype.pop=function(el){var xc=this[this.length-1];this.length--;return xc;}}
if(typeof Array.prototype.splice=="undefined"){Array.prototype.splice=function(yc,zc){var Ac=(arguments.length-2);var Bc=[];var ci=yc;var c=0;while(c<zc){Bc[c]=this[ci];ci++;c++;}
var Cc=Ac-zc;if(Cc>0){ci=this.length;while(ci>yc+zc){this[ci]=this[ci-Cc];ci--;}}else{c=(this.length-(yc+zc));ci=yc+Ac;while(c>0){this[ci]=this[ci-Cc];ci++;c--;}
this.length+=Cc;}
for(c=0;c<Ac;c++){this[yc+c]=arguments[c+2];}
return Bc;}}
StringBuffer=function(){this.data=new Array();}
StringBuffer.prototype.append=function(Dc){this.data[this.data.length]=Dc;}
StringBuffer.prototype.toString=function(){return this.data.join("");}
removeChildNodes=function(Ec){if(Ec.hasChildNodes()){var Fc=Ec.childNodes;for(var i=Fc.length-1;i>=0;i--){Ec.removeChild(Fc[i]);}}}
deleteNode=function(Gc){if(Gc.parentNode)Gc.parentNode.removeChild(Gc);return Gc;}
findFirstElement=function(Hc){while(Hc&&Hc.nodeType!=1){Hc=Hc.nextSibling;}
if(!isDefined(Hc))return null;return Hc;}
DomIterator=function(Ic){this._ca=Ic;this._da=findFirstElement(Ic.firstChild);this._ea=null;}
DomIterator.prototype={hasNext:function(){return this._da!=null;},skipChildren:function(){this._da=null;if(this._ea.nextSibling){this._da=findFirstElement(this._ea.nextSibling);}
var Jc=this._ea;while(this._da==null&&Jc.parentNode!=null&&Jc.parentNode!=this._ca){Jc=Jc.parentNode;this._da=findFirstElement(Jc.nextSibling);}},next:function(){this._ea=this._da;this._da=findFirstElement(this._ea.firstChild);if(this._da==null&&this._ea.nextSibling){this._da=findFirstElement(this._ea.nextSibling);}
var Kc=this._ea;while(this._da==null&&Kc.parentNode!=null&&Kc.parentNode!=this._ca){Kc=Kc.parentNode;this._da=findFirstElement(Kc.nextSibling);}
return this._ea;}}
selectElementsByAttribute=function(Lc,Mc,Nc,Oc){var Pc=Lc.getElementsByTagName(Mc);var Qc=[];for(var i=0;i<Pc.length;i++){if(Pc[i].getAttribute(Nc)==Oc){Qc[Qc.length]=Pc[i];}}
return Qc;}
selectSingleElementByAttribute=function(Rc,Sc,Tc,Uc){var Vc=selectElementsByAttribute(Rc,Sc,Tc,Uc);return Vc[0];}
selectSingleElementByTagName=function(Wc,Xc){var Yc=Wc.getElementsByTagName(Xc);return(Yc.length>0)?Yc[0]:null;}
selectAttributes=function(Zc,$c){var ad=[];if(Zc!=null){for(var i=0;i<Zc.length;i++){ad[ad.length]=Zc[i].getAttribute($c);}}
return ad;}
getFirstTagParent=function(bd,cd){var dd=cd.toUpperCase();var ed=cd.toLowerCase();return getFirstParent(bd,function(el){return(el.nodeName==dd||el.nodeName==ed);});}
getFirstSupportingParent=function(fd,gd){return getFirstParent(fd,function(el){for(var i=0;i<gd.length;i++){if(el[gd[i]]){return true;}}
return false;});}
getFirstParent=function(hd,jd){var el=hd;while(el&&el!=document){if(jd(el))return el;el=el.parentNode;}
return null;}
getFirstUlChild=function(kd){var ld=kd.childNodes;for(var i=0;i<ld.length;i++){if(ld[i].nodeName=="ul"||ld[i].nodeName=="UL"){return ld[i];}}
return null;}
Assert={isTrue:function(md,nd){if(!md){Log.error("Assertion failure: "+nd);}},isFalse:function(od,pd){this.isTrue(!od,pd);},isNull:function(qd,rd){this.isTrue(qd==null,rd);},isNotNull:function(sd,td){this.isTrue(sd!=null,td);},isDefined:function(ud,vd){this.isTrue(typeof ud!="undefined",vd);}};function Sarissa(){};Sarissa.PARSED_OK="Document contains no parsing errors";Sarissa.IS_ENABLED_TRANSFORM_NODE=false;Sarissa.IS_ENABLED_XMLHTTP=false;Sarissa.IS_ENABLED_SELECT_NODES=false;var _fa=0;var _ga="";var _ha=document.implementation&&true;var _ia=_ha&&document.implementation.createDocument;var _ja=_ha&&document.implementation.hasFeature;var _ka=_ia&&_ja;var _la=(navigator.userAgent&&navigator.vendor&&(navigator.userAgent.toLowerCase().indexOf("applewebkit")!=-1||navigator.vendor.indexOf("Apple")!=-1));var _ma=document.all&&window.ActiveXObject&&navigator.userAgent.toLowerCase().indexOf("msie")>-1&&navigator.userAgent.toLowerCase().indexOf("opera")==-1;if(!window.Node||!window.Node.ELEMENT_NODE){window.Node={ELEMENT_NODE:1,ATTRIBUTE_NODE:2,TEXT_NODE:3,CDATA_SECTION_NODE:4,ENTITY_REFERENCE_NODE:5,ENTITY_NODE:6,PROCESSING_INSTRUCTION_NODE:7,COMMENT_NODE:8,DOCUMENT_NODE:9,DOCUMENT_TYPE_NODE:10,DOCUMENT_FRAGMENT_NODE:11,NOTATION_NODE:12};};if(_ma){_ga="xsl:";var _na="";var _oa="";pickRecentProgID=function(wd,xd){var yd=false;for(var i=0;i<wd.length&&!yd;i++){try{var zd=new ActiveXObject(wd[i]);o2Store=wd[i];yd=true;for(var j=0;j<xd.length;j++)if(i<=xd[j][1])Sarissa["IS_ENABLED_"+xd[j][0]]=true;}catch(objException){};};if(!yd)throw "Could not retreive a valid progID of Class: "+wd[wd.length-1]+". (original exception: "+e+")";wd=null;return o2Store;};_na=pickRecentProgID(["Msxml2.DOMDocument.5.0","Msxml2.DOMDocument.4.0","Msxml2.DOMDocument.3.0","MSXML2.DOMDocument","MSXML.DOMDocument","Microsoft.XMLDOM"],[["SELECT_NODES",2],["TRANSFORM_NODE",2]]);_oa=pickRecentProgID(["Msxml2.XMLHTTP.5.0","Msxml2.XMLHTTP.4.0","MSXML2.XMLHTTP.3.0","MSXML2.XMLHTTP","Microsoft.XMLHTTP"],[["XMLHTTP",4]]);_pa=pickRecentProgID(["Msxml2.FreeThreadedDOMDocument.5.0","MSXML2.FreeThreadedDOMDocument.4.0","MSXML2.FreeThreadedDOMDocument.3.0"]);_qa=pickRecentProgID(["Msxml2.XSLTemplate.5.0","Msxml2.XSLTemplate.4.0","MSXML2.XSLTemplate.3.0"],[["XSLTPROC",2]]);pickRecentProgID=null;Sarissa.getDomDocument=function(Ad,Bd){var Cd=new ActiveXObject(_na);if(Bd){if(Ad){Cd.loadXML("<a"+_fa+":"+Bd+" xmlns:a"+_fa+"=\""+Ad+"\" />");++_fa;}
else Cd.loadXML("<"+Bd+"/>");};return Cd;};Sarissa.getParseErrorText=function(Dd){var Ed=Sarissa.PARSED_OK;if(Dd.parseError!=0){Ed="XML Parsing Error: "+Dd.parseError.reason+"\nLocation: "+Dd.parseError.url+"\nLine Number "+Dd.parseError.line+", Column "+Dd.parseError.linepos+":\n"+Dd.parseError.srcText+"\n";for(var i=0;i<Dd.parseError.linepos;i++){Ed+="-";};Ed+="^\n";};return Ed;};}else{if(_ia){Sarissa._ra=function(Fd){if(!Fd.documentElement||Fd.documentElement.tagName=="parsererror")Fd.parseError=-1;Sarissa._sa(Fd,4);};_ta=function(){Sarissa._ra(this);};Sarissa._sa=function(Gd,Hd){Gd.readyState=Hd;if(Gd.onreadystatechange!=null&&typeof Gd.onreadystatechange=="function")Gd.onreadystatechange();};Sarissa.getDomDocument=function(Id,Jd){var Kd=document.implementation.createDocument(Id?Id:"",Jd?Jd:"",null);Kd.addEventListener("load",_ta,false);return Kd;};if(window.XMLDocument){XMLDocument.prototype.onreadystatechange=null;XMLDocument.prototype.readyState=0;XMLDocument.prototype.parseError=0;var _ua=false;XMLDocument.prototype._va=XMLDocument.prototype.load;XMLDocument.prototype.load=function(Ld){var Md=document.implementation.createDocument("","",null);Sarissa.copyChildNodes(this,Md);this.parseError=0;Sarissa._sa(this,1);try{if(this.async==false&&_ua){var Nd=new XMLHttpRequest();Nd.open("GET",Ld,false);Nd.send(null);Sarissa._sa(this,2);Sarissa.copyChildNodes(Nd.responseXML,this);Sarissa._sa(this,3);}
else{this._va(Ld);};}
catch(objException){this.parseError=-1;}
finally{if(this.async==false){Sarissa._ra(this);};};return Md;};}
else if(document.implementation&&document.implementation.hasFeature&&document.implementation.hasFeature('LS','3.0')){Document.prototype.async=true;Document.prototype.onreadystatechange=null;Document.prototype.parseError=0;Document.prototype.load=function(Od){var Pd=document.implementation.createLSParser(this.async?document.implementation.MODE_ASYNCHRONOUS:document.implementation.MODE_SYNCHRONOUS,null);if(this.async){var Qd=this;Pd.addEventListener("load",function(e){Qd.readyState=4;Sarissa.copyChildNodes(e.newDocument,Qd.documentElement,false);Qd.onreadystatechange.call();},false);};try{var Rd=Pd.parseURI(Od);}
catch(e){this.parseError=-1;};if(!this.async)Sarissa.copyChildNodes(Rd,this.documentElement,false);return Rd;};Sarissa.getDomDocument=function(Sd,Td){return document.implementation.createDocument(Sd?Sd:"",Td?Td:"",null);};};};};if(window.XMLHttpRequest){Sarissa.IS_ENABLED_XMLHTTP=true;}else if(_ma){XMLHttpRequest=function(){return new ActiveXObject(_oa);};Sarissa.IS_ENABLED_XMLHTTP=true;};if(!window.document.importNode&&_ma){try{window.document.importNode=function(Ud,Vd){var Wd=document.createElement("div");if(Vd)Wd.innerHTML=Sarissa.serialize(Ud);else Wd.innerHTML=Sarissa.serialize(Ud.cloneNode(false));return Wd.firstChild;};}catch(e){};};if(!Sarissa.getParseErrorText){Sarissa.getParseErrorText=function(Xd){var Yd=Sarissa.PARSED_OK;if(Xd&&Xd.parseError&&Xd.parseError!=0){if(Xd.documentElement.tagName=="parsererror"){Yd=Xd.documentElement.firstChild.data;Yd+="\n"+Xd.documentElement.firstChild.nextSibling.firstChild.data;}
else{Yd=Sarissa.getText(Xd.documentElement);};};return Yd;};};Sarissa.getText=function(Zd,$d){var s="";var ae=Zd.childNodes;for(var i=0;i<ae.length;i++){var be=ae[i];var de=be.nodeType;if(de==Node.TEXT_NODE||de==Node.CDATA_SECTION_NODE){s+=be.data;}else if($d==true&&(de==Node.ELEMENT_NODE||de==Node.DOCUMENT_NODE||de==Node.DOCUMENT_FRAGMENT_NODE)){s+=Sarissa.getText(be,true);};};return s;};if(window.XMLSerializer){Sarissa.serialize=function(ee){var s=null;if(ee){s=ee.innerHTML?ee.innerHTML:(new XMLSerializer()).serializeToString(ee);};return s;};}else{if(Sarissa.getDomDocument&&(Sarissa.getDomDocument("","foo",null)).xml){Sarissa.serialize=function(fe){var s=null;if(fe){s=fe.innerHTML?fe.innerHTML:fe.xml;};return s;};XMLSerializer=function(){};XMLSerializer.prototype.serializeToString=function(ge){return ge.xml;};};};Sarissa.stripTags=function(s){return s.replace(/<[^>]+>/g,"");};Sarissa.clearChildNodes=function(he){while(he.firstChild){he.removeChild(he.firstChild);};};Sarissa.copyChildNodes=function(ie,je,ke){if((!ie)||(!je)){throw "Both source and destination nodes must be provided";};if(!ke){Sarissa.clearChildNodes(je);};var le=je.nodeType==Node.DOCUMENT_NODE?je:je.ownerDocument;var me=ie.childNodes;if(le.importNode&&(!_ma)){for(var i=0;i<me.length;i++){je.appendChild(le.importNode(me[i],true));};}
else{for(var i=0;i<me.length;i++){je.appendChild(me[i].cloneNode(true));};};};Sarissa.moveChildNodes=function(ne,oe,pe){alert("Undesired method Sarissa.moveChildNodes");};Sarissa.xmlize=function(qe,re,se){alert("Undesired function Sarissa.xmlize");};Sarissa.escape=function(te){return te.replace(/&/g,"&amp;").replace(/</g,"&lt;").replace(/>/g,"&gt;").replace(/"/g,"&quot;").replace(/'/g,"&apos;");};Sarissa.unescape=function(ue){return ue.replace(/&apos;/g,"'").replace(/&quot;/g,"\"").replace(/&gt;/g,">").replace(/&lt;/g,"<").replace(/&amp;/g,"&");};XML={getText:function(n){return Sarissa.getText(n);}};NAMESPACE_PREFIX="e";NAMESPACE_URI="http://www.2vi.nl/e";eAttr=function(ve,we){var pf=NAMESPACE_PREFIX+':'+we;var xe=ve[NAMESPACE_PREFIX+'_'+we];if(typeof xe!="undefined"){return xe;}else{xe=null;var a=null;try{a=ve.getAttributeNode(pf);}catch(e){};try{if(a){xe=a.value;}else if(ve.getAttributeNS){xe=ve.getAttributeNS(NAMESPACE_URI,we);}else if(ve.getAttribute){xe=ve.getAttribute(pf);}}catch(e){};return xe?xe:null;}}
getEAttribute=eAttr;getAttribute=eAttr;setEAttribute=function(ye,ze,Ae){ye[NAMESPACE_PREFIX+'_'+ze]=Ae;ye.setAttribute(NAMESPACE_PREFIX+':'+ze,Ae);}
setAttribute=setEAttribute;removeAttribute=function(Be,Ce){setAttribute(Be,Ce,null);}
getFirstEAttributeParent=function(De,Ee,Fe){return getFirstParent(De,function(el){var Ge=eAttr(el,Ee);return(Ge&&Ge==Fe);});}
Consyn={_wa:".",_xa:"en",_ya:["en"],_za:[],_Aa:{},_Ba:false,includeLoadAllowed:true,getScriptPath:function(){return this._wa;},getStylePath:function(He){return this._wa+'/'+this._Aa.stylePath+'/'+He},getImagePath:function(Ie){return this._wa+'/'+this._Aa.imgPath+'/'+Ie},getHtmlPath:function(Je){return this._wa+'/'+this._Aa.htmlPath+'/'+Je},start:function(Ke,Le){DomLoaded.load(function(){Consyn.init(Ke,Le);});},stop:function(){clearInterval(this._Ca);},init:function(Me,Ne){if(this._Ba){return;}
this._Ba=true;try{this.includeLoadAllowed=false;Log.debug("Initialize framework");this._wa=Me;this._ya=Ne;var Oe=this.loadConfigFile("config.js");this.loadConfig(Oe);this.loadStylesheet("base.css");this.loadAllLocale("locale");this.recoverState();this.processPage();this._Da();triggerAddEventsOnLoad();Log.debug("Consyn Framework initialized");}catch(e){Log.error("Error initializing: "+e);}},require:function(){for(var i=0;i<arguments.length;i++){var Pe=arguments[i];this.importLibrary(Pe);}},importLibrary:function(Qe){if(!this._za[Qe]){var Re=this._wa+'/'+Qe+'.js?id'+Math.random();if(this.includeLoadAllowed){document.write("<script type='text/javascript' src='"+Re+"'></script>");}else{this._Ea(Re);}
this._za[Qe]=true;}},_Ea:function(Se){try{var Te=this.getFileContent(Se);return eval(Te);}catch(e){Log.error("Error in "+Se+": \n"+e);return null;}},loadConfigFile:function(Ue){return this._Ea(this._wa+"/"+Ue);},loadStylesheet:function(Ve){var We=selectSingleElementByTagName(document,"head");var Xe=this.getStylePath(Ve);var Ye=document.createElement("link");Ye.setAttribute("rel","stylesheet");Ye.setAttribute("type","text/css");if(Ve!=null&&Ve.length>0){Ye.setAttribute("href",Xe);}
We.appendChild(Ye);Ye.disabled=false;return Ye;},_Fa:"",_Ca:null,_Ga:[],_Ha:function(){var u=document.location.href;var j=u.indexOf('#');if(j>=0){var Ze=u.substring(j+1);if(!Consyn._Ia(Ze)){Consyn.recoverState(true);}}},_Da:function(){if(this._Ca==null){this._Ca=setInterval(this._Ha,100);}},_Ia:function($e){var af=this._Ja($e);for(var bf in af){if(this._Ga[bf]!=af[bf])return false;}
return true;},_Ja:function(cf){var df={};var ef=cf.split(';;');for(var i=0;i<ef.length;i++){if(ef[i].length>0){var ff=ef[i].split('::');df[ff[0]]=ff[1];}}
return df;},recoverState:function(gf){var hf=[];var u=document.location.href;var j=u.indexOf('#');if(j>=0){var jf=u.substring(j+1);this._Ga=this._Ja(jf);if(gf){for(var kf in this._Ga){var lf=this._Ga[kf];var mf=elem(kf);hf.push({obj:mf,src:lf,applied:0});}}}
var i=0;var nf=hf.length;var of=false;while(hf.length>0&&nf>0){if(i==hf.length){if(of=false){nf=0;}
else{i=0;nf--;of=false;}}
var o=hf[i].obj;var s=hf[i].src;if(o&&o.setEsrc){o.setEsrc(s);hf.splice(i,1);of=true;}else{i++;}}},storeState:function(qf,rf){var sf=eAttr(qf,"storestate");if(qf.id&&sf&&sf.indexOf("anchor")>=0){var tf=this.getStateString(qf.id,rf);this._Ga[qf.id]=rf;if(this._Fa!=tf){document.location="#"+tf;this._Fa=tf;}}
activateLinks(qf,rf);},getStateString:function(uf,vf){var wf="";var xf=false;var yf=this._Ga;for(var zf in yf){if(typeof yf[zf]!="function"&&elem(zf)&&zf!=uf&&elem(zf).defaultState!=yf[zf]){if(xf)wf+=";;";xf=true;wf+=zf+"::"+yf[zf];}}
if(uf&&(!elem(uf)||elem(uf).defaultState!=vf)){if(xf)wf+=";;";wf+=uf+"::"+vf;}
return wf;},getState:function(Af){if(this._Ga[Af.id]){return this._Ga[Af.id];}
return null;},_Ka:[],loadAllLocale:function(Bf){for(var i=0;i<this._ya.length;i++){this.loadLocale(Bf,this._ya[i]);}},loadLocale:function(Cf,Df){var f=this._wa+'/'+Cf+'.'+Df+'.js';var Ef=this._Ea(f);if(!isDefined(this._Ka[Df])){this._Ka[Df]=[];}
for(var k in Ef){this._Ka[Df][k]=Ef[k];}},getLocalized:function(Ff){var Gf=this._Ka[this._xa][Ff];return Gf?Gf:Ff;},setLanguage:function(Hf){this._xa=Hf;this.updateLabels();},updateLabels:function(){this.processNodes(document,{"label":true});},loadConfig:function(If){this._Aa=If;},tryLoadTransform:function(Jf){var Kf=null;for(var Lf in this._Aa.modules){Kf=this._Aa.modules[Lf];if(typeof Kf!="function"){for(var i=0;i<Kf.transforms.length;i++){if(Kf.transforms[i]==Jf){this.require(Lf);return true;}}}}
var i=Jf.indexOf('.');if(i>=0){var Lf=Jf.substring(0,i);this.require(Lf);}
return false;},tryLoadBehavior:function(Mf){var Nf=null;for(var Of in this._Aa.modules){Nf=this._Aa.modules[Of];for(var i=0;i<Nf.behaviors.length;i++){if(Nf.behaviors[i]==Mf){this.require(Of);return true;}}}
var i=Mf.indexOf('.');if(i>=0){var Of=Mf.substring(0,i);this.require(Of);}
return false;},addPrefixedClassFront:function(Pf,Qf){Pf.className=this.getPrefixedClassName(Qf)+" "+Pf.className;},removePrefixedClass:function(Rf,Sf){removeClass(Rf,this.getPrefixedClassName(Sf));},getPrefixedClassName:function(Tf){return this._Aa.stylePrefix+Tf;},getFileContent:function(Uf){return this.doRequest({uri:Uf,method:"GET",sync:true,type:"text"});},getFileContentAsync:function(Vf,Wf){return this.doRequest({uri:Vf,method:"GET",callback:Wf,type:"text"});},postRequest:function(Xf,Yf){return this.doRequest({uri:Xf,method:"POST",data:Yf,sync:true,type:"text"});},postRequestAsync:function(Zf,$f,ag){return this.doRequest({uri:Zf,method:"POST",data:$f,callback:ag,type:"text"});},_La:function(bg){var cg=[];var dg=true;var eg=(bg.length)?true:false;if(eg){for(var i=0;i<bg.length;i++){var fg=bg[i];var gg=fg.key;var hg=fg.value;cg=this._Ma(cg,gg,hg,dg);dg=false;}}else{for(var gg in bg){var hg=bg[gg];cg=this._Ma(cg,gg,hg,dg);dg=false;}}
return cg.join("");},_Ma:function(ig,jg,kg,lg){if(typeof kg!="function"&&kg!=null&&jg.length>0){if(!lg){ig.push("&");}
ig.push(jg);ig.push("=");ig.push(encodeURIComponent(kg));}
return ig;},getDomDocumentAsync:function(mg,ng){return this.doRequest({uri:mg,method:"GET",callback:ng,type:"XML"});},getDomDocument:function(og){if(undefined(og)){return Sarissa.getDomDocument();}
return this.doRequest({uri:og,method:"GET",sync:true,type:"XML"});},doRequest:function(pg){var qg=this.getRequest();qg.open(pg.method,pg.uri,!pg.sync);try{if(!pg.sync){qg.onreadystatechange=function(){if(qg.readyState==4){if(qg.status==200||qg.status==0){pg.callback(pg.type=="text"?qg.responseText:qg.responseXML);}else{pg.callback(null);Log.error("Error retrieving content from: "+sUri);}}}}
if(pg.method=="POST"){var rg=this._La(pg.data);qg.setRequestHeader("Content-type","application/x-www-form-urlencoded");qg.setRequestHeader("Content-length",rg.length);qg.setRequestHeader("Connection","close");qg.send(rg);}else{qg.send(null);}
if(pg.sync){return pg.type=="text"?qg.responseText:qg.responseXML;}}catch(e){Log.error("doRequest: Error retrieving content from: "+sUri);}},getRequest:function(){return new XMLHttpRequest();},setLoading:function(sg){if(undefined(sg.eLoadingIndicator)||sg.eLoadingIndicator==null){var x=getRealOffsetLeft(sg)+5+"px";var y=getRealOffsetTop(sg)+5+"px";sg.eLoadingIndicator=DOM.ce("div",{},[DOM.text("Loading...")]);this.addPrefixedClassFront(sg.eLoadingIndicator,"loading_indicator");sg.eLoadingIndicator.style.position="absolute";sg.eLoadingIndicator.style.left=x;sg.eLoadingIndicator.style.top=y;sg.eLoadingIndicator.style.zIndex=99;this.addPrefixedClassFront(sg,"loading");document.body.appendChild(sg.eLoadingIndicator);}},removeLoading:function(tg){if(isDefined(tg.eLoadingIndicator)&&tg.eLoadingIndicator){document.body.removeChild(tg.eLoadingIndicator);this.removePrefixedClass(tg,"loading");tg.eLoadingIndicator=null;}},processPage:function(){this.processNodes(document.documentElement);},processNodes:function(ug,vg){var wg=new DomIterator(ug);var xg=true;while(wg.hasNext()){var el=wg.next();xg=this.processNode(el,vg);if(xg==false){wg.skipChildren();}}},processNode:function(el,yg){var zg=undefined(yg);if(el.nodeName.toLowerCase()=='applet')return false;if(zg&&(el.nodeName.toLowerCase()==NAMESPACE_PREFIX+":action"||el.nodeName.toLowerCase()=="action"&&el.scopeName==NAMESPACE_PREFIX)){this.action(el);}
var Ag=eAttr(el,"iterate");if((zg||yg['iterate'])&&Ag&&Ag!=""&&!el.iterateInstance){return false;}
var Bg=eAttr(el,"template");if((zg||yg['template'])&&Bg&&Bg!=""&&!el.iterateInstance){return false;}
if(zg||yg['transform']){var Cg=eAttr(el,"transform");if(Cg){this.transform(Cg.split(" "),el);}}
if(zg||yg['label']){var Dg=eAttr(el,"label");if(Dg){this.label(Dg,el);}}
if(zg||yg['lib']){var Eg=eAttr(el,"lib");if(Eg){Consyn.require(Eg);}}
if(zg||yg['locale']){var Fg=eAttr(el,"locale");if(Fg){Consyn.loadAllLocale(Fg);}}
if(zg||yg['behave']){var Gg=eAttr(el,"behave");if(Gg){this.behave(Gg.split(" "),el);}}
if(zg||yg['drag']){var Hg=eAttr(el,"drag");if(Hg){this.drag(Hg,el);}}
if(zg||yg['dragcontainer']){var Hg=eAttr(el,"dragcontainer");if(Hg){this.dragcontainer(Hg,el);}}
if(zg||yg['tag']){var Ig=eAttr(el,"tag");if(Ig){this.tag(Ig,el);}}},registerTransform:function(Jg,Kg){if(typeof Kg=="function"){Kg=Transform.extend({apply:Kg});}
Transforms[Jg]=Kg;},transform:function(Lg,Mg){for(var i=0;i<Lg.length;i++){var Ng=Lg[i];if(undefined(Transforms[Ng])){this.tryLoadTransform(Ng);if(undefined(Transforms[Ng])){return;}}
if(undefined(Mg.appliedTransforms)){Mg.appliedTransforms={};}
if(Mg.appliedTransforms[Ng]){return;}else{Transforms[Ng].apply(Mg);Mg.appliedTransforms[Ng]=true;}}},label:function(Og,Pg){var Qg=this.getLocalized(Og);if(Qg){removeChildNodes(Pg);Pg.appendChild(DOM.text(Qg));}},behave:function(Rg,Sg){for(var i=0;i<Rg.length;i++){var b=Behaviors.get(Rg[i]);b.attach(Sg);}},dragcontainer:function(Tg,Ug){var Vg=Tg.split(' ');Drag.addTarget(Ug);},drag:function(Wg,Xg){var Yg=Wg.split(' ');if(Yg.contains("position")){addEvent(Xg,'mousedown',function(e){Drag.start(e,'ConsynBase_ElementDrag',{element:this,bounded:Yg.contains("local")});});this.addPrefixedClassFront(Xg,"moveable");}else if(Yg.contains("structure")){var Zg=Yg.contains("datamanipulation");if(Zg){Zg=Xg.getEdata();}
addEvent(Xg,'mousedown',function(e){Drag.start(e,'ConsynBase_StructureDrag',{element:this,datamanipulation:Zg});});this.addPrefixedClassFront(Xg,"dragable");}},tag:function($g,ah){var bh=$g.split('.');if(bh.length>1){var dh=findContext(bh[0],ah);if(undefined(dh.context)||dh.context==null){dh.context={};}
ah._Na=dh;dh.context[bh[1]]=ah;}else{}},elem:function(eh,fh){var gh=fh.charAt(0);if(gh=='#'){return elem(fh.substring(1));}else if(gh=='.'){var hh=" "+fh.substring(1)+" ";return getFirstParent(eh,function(el){return(" "+el.className+" ").indexOf(hh)>=0;});}else if(fh.indexOf('.')>0){var ih=fh.split('.');return this.getFromContext(eh,ih[0],ih[1]);}else if(fh=="this"){return eh;}else{var e=getFirstEAttributeParent(eh,"tag",fh);if(e)return e;else return elem(fh);}},getFromContext:function(jh,kh,lh){var c=findContext(kh,jh);if(c&&c.context){return c.context[lh];}else{return null;}},setInContext:function(mh,nh,oh,ph){var c=findContext(nh,mh);if(c){if(undefined(c.context))c.context=[];c.context[oh]=ph;}else{Log.error("Invalid context: "+nh);}},action:function(qh){var rh="";var sh="";var th=eAttr(qh,"go");var uh=eAttr(qh,"refresh");if(th){rh="go";sh=th;}else if(uh){rh="refresh";sh=uh;}else{rh=eAttr(qh,"name");sh=eAttr(qh,"params");sh=sh?sh:"";}
Actions.exec(rh,sh.split(" "));},handleKey:function(e){var ch=String.fromCharCode(e.keyCode).toLowerCase();if(ch=='d'&&e.altKey&&e.ctrlKey){this.toggleDebugWindow();}},toggleDebugWindow:function(){var vh=elem("consyn_debug_console");if(vh){deleteNode(vh);this.removePrefixedClass(document.body,"debug_body");}else{this.addPrefixedClassFront(document.body,"debug_body");var wh=DOM.ce("textarea",{id:"debugBox"});vh=DOM.ce("div",{id:"consyn_debug_console"},[DOM.ce("h1",{},[DOM.text("Debug console:")]),wh]);document.body.appendChild(vh);wh.value=Log.getFullLog();}}};addEventOnLoad(document,'keydown',function(e){Consyn.handleKey(e);});addEventOnLoad(window,'pageshow',function(e){Consyn.recoverState();});Framework=Consyn;DomLoaded={onload:[],loaded:function(){if(arguments.callee.done)return;arguments.callee.done=true;for(i=0;i<DomLoaded.onload.length;i++)DomLoaded.onload[i]();},load:function(xh){this.onload.push(xh);if(document.addEventListener)document.addEventListener("DOMContentLoaded",DomLoaded.loaded,null);if(/KHTML|WebKit/i.test(navigator.userAgent)){var yh=setInterval(function(){if(/loaded|complete/.test(document.readyState)){clearInterval(yh);delete yh;DomLoaded.loaded();}},10);}/*@cc_on @*//*@if (@_win32)
		var proto = "src='javascript:void(0)'";
		if (location.protocol == "https:") proto = "src=//0";
		document.write("<scr"+"ipt id=__ie_onload defer " + proto + "><\/scr"+"ipt>");
		var script = document.getElementById("__ie_onload");
		script.onreadystatechange = function() {
		    if (this.readyState == "complete") {
		        DomLoaded.loaded();
		    }
		};
		/*@end @*/window.onload=DomLoaded.loaded;}};registerAction=function(zh,Ah){alert("Deprecated method: registerAction, please replease");actions[zh].push(Ah);}
findContext=function(Bh,Ch){while(Ch!=null&&Ch!=document.documentElement){var Dh=eAttr(Ch,'context');var Eh=eAttr(Ch,'tag');if(Dh==Bh||Eh==Bh)return Ch;Ch=Ch.parentNode;}
return null;}
findTarget=function(Fh,Gh){if(isDefined(Fh)&&Fh){return Consyn.elem(Gh,Fh);}else{return getFirstSupportingParent(Gh,["setTextData","setEsrc"]);}}
DROP_ON_TARGET=1;DROP_ON_POSITION=2;DragService=function(){this.type=DROP_ON_POSITION;this.startDrag=null;this.reset=null;this.doStep=null;this.dropOnTarget=null;this.dropOnPosition=null;this.key=null;}
DROP_MARGIN=5;Drag={x:0,y:0,busy:false,startData:{},endData:{},possible:false,smoother:null,interval:null,services:[],targets:[],current:null,register:function(Hh){Drag.services[Hh.key]=Hh;},addTarget:function(Ih){Drag.targets.push(Ih);},getData:function(e){e=fix_e(e);Drag.x=e.pageX;Drag.y=e.pageY;},start:function(e,Jh,Kh){if(!Drag.busy){Drag.getData(e);Drag.current=Drag.services[Jh];Drag.startData=Kh;Drag.possible=true;if(Drag.current.type==DROP_ON_POSITION){}
Drag.current.startDrag(Drag);}
e.cancelBubble=true;if(isDefined(e.preventDefault))e.preventDefault();return false;},drag:function(e){if(Drag.possible){Drag.busy=true;Drag.getData(e);Drag.doStep();}
if(isDefined(e.preventDefault))e.preventDefault();return false;},dragInFrame:function(e,Lh){Drag.x=e.pageX+getRealOffsetLeft(Lh);Drag.y=e.pageY+getRealOffsetTop(Lh);return false;},doStep:function(){if(Drag.busy&&Drag.current!=null){Drag.current.doStep(Drag);}},dropOnTarget:function(e,Mh,Nh,Oh){if(Drag.busy&&Drag.current!=null&&Mh==Drag.current.key){Drag.getData(e);Drag.endData=Nh;Drag.current.dropOnTarget(Drag,e.target);}
Drag.reset();},dropOnPosition:function(e){if(Drag.busy&&Drag.current!=null){Drag.getData(e);if(Drag.current.type==DROP_ON_POSITION){Drag.current.dropOnPosition(Drag);}else{for(var i=0;i<Drag.targets.length;i++){var Ph=Drag.targets[i];var x=getRealOffsetLeft(Ph);var y=getRealOffsetTop(Ph);if(Drag.y>=y-DROP_MARGIN&&Drag.y<=y+Ph.offsetHeight+DROP_MARGIN&&Drag.x>=x-DROP_MARGIN&&Drag.x<=x+Ph.offsetWidth+DROP_MARGIN){Drag.current.dropOnTarget(Drag,Ph);}}}}
Drag.reset();},reset:function(){Drag.interval=null;Drag.busy=false;Drag.possible=false;if(Drag.smoother!=null){Drag.smoother.style.display="none";}
if(Drag.current!=null){Drag.current.reset();}
Drag.current=null;}}
addEventOnLoad(document,'mousemove',Drag.drag);addEventOnLoad(document,'mouseup',Drag.dropOnPosition);addEventOnLoad(document,'selectstart',function(e){debug("selectStart");e.cancelBubble=Drag.busy;return!Drag.busy;});Drag.register({type:DROP_ON_POSITION,key:"ConsynBase_ElementDrag",dragable:null,bounded:true,realOffsetTop:0,realOffsetLeft:0,startDragX:0,startDragY:0,elLeft:0,elTop:0,startDrag:function(d){this.dragable=d.startData.element;this.startDragX=d.x;this.startDragY=d.y;this.bounded=isDefined(d.startData.bounded)?d.startData.bounded:true;this.elLeft=this.dragable.offsetLeft;this.elTop=this.dragable.offsetTop;},doStep:function(d){var Qh=d.x-this.startDragX;var Rh=d.y-this.startDragY;var Sh=this.elLeft+Qh;var Th=this.elTop+Rh;if(Sh<0&&this.bounded)Sh=0;if(Th<0&&this.bounded)Th=0;var oP=this.dragable.offsetParent;var Uh=oP.offsetWidth-this.dragable.offsetWidth;if(Sh>Uh&&this.bounded)Sh=Uh;var Vh=oP.offsetHeight-this.dragable.offsetHeight;if(Th>Vh&&this.bounded)Th=Vh;this.dragable.style.left=Sh+"px";this.dragable.style.top=Th+"px";},dropOnPosition:function(d){},reset:function(){}});Drag.register({type:DROP_ON_TARGET,key:"ConsynBase_StructureDrag",dragable:null,startElem:null,dragOffsetTop:0,dragOffsetLeft:0,dragStartX:0,dragStartY:0,startDrag:function(d){this.startElem=d.startData.element;if(this.dragable==null){this.dragable=DOM.ce("div");Consyn.addPrefixedClassFront(this.dragable,"dragableOnCursor");document.body.appendChild(this.dragable);this.dragable.style.display='none';for(var i=0;i<4;i++){var t=DOM.ce("div",{className:"outline"});this.dragable.appendChild(t);}}
var w=this.startElem.offsetWidth;var h=this.startElem.offsetHeight;var Wh=this.dragable.getElementsByTagName("div");Wh[0].style.width=w+"px";Wh[0].style.height="2px";Wh[1].style.width=w+"px";Wh[1].style.height="2px";Wh[1].style.top=h+"px";Wh[2].style.width="2px";Wh[2].style.height=h+"px";Wh[3].style.width="2px";Wh[3].style.height=h+"px";Wh[3].style.left=w+"px";this.dragOffsetLeft=getRealOffsetLeft(this.startElem)-d.x-1;this.dragOffsetTop=getRealOffsetTop(this.startElem)-d.y-1;this.dragStartX=d.x;this.dragStartY=d.y;},doStep:function(d){if(Math.abs(d.x-this.dragStartX)>2||Math.abs(d.y-this.dragStartY)>2){this.dragable.style.display='block';}
this.dragable.style.left=(d.x+this.dragOffsetLeft)+"px";this.dragable.style.top=(d.y+this.dragOffsetTop)+"px";},dropOnTarget:function(d,Xh){var Yh=Xh;var Zh=eAttr(this.startElem,"dragtype");var $h=eAttr(Yh,"dragtype");if($h){var ai=$h.split(' ');debug("rec type: "+$h);if(!ai.contains(Zh)){return;}}
var bi=Yh.childNodes;var di=null;var ei=d.x;var fi=d.y;for(var i=0;i<bi.length;i++){di=bi[i];var x=getRealOffsetLeft(di);var y=getRealOffsetTop(di);if(di!=this.startElem&&fi>=y&&fi<=y+di.offsetHeight&&ei>=x&&ei<=x+di.offsetWidth){var gi=null;if(d.y<y+(di.offsetHeight/2)){gi=di;}else if(di.nextSibling){gi=di.nextSibling;}
if(d.startData.datamanipulation){var hi=d.startData.datamanipulation.getManipulator();hi.moveItem(d.startElem.getEItemKey(),gi?gi.getEItemKey():null);}else{deleteNode(this.startElem);if(gi==null){di.parentNode.appendChild(this.startElem);}else{di.parentNode.insertBefore(this.startElem,gi);}}
return;}}
deleteNode(this.startElem);Yh.appendChild(this.startElem);},reset:function(){this.dragable.style.display='none';}});contextmenu={x:0,y:0,object:null,contextmenu:null,init:function(){},show:function(e,ii,ji,ki){e=fix_e(e);this.x=e.pageX;this.y=e.pageY;this.object=ji;this.component=ki;this.contextmenu=getObject("cm"+ii);this.contextmenu.style.left=this.x+"px";this.contextmenu.style.top=this.y+"px";this.contextmenu.style.display="block";if(e.stopPropagation){e.stopPropagation();}else{e.cancelBubble=true;}
return false;},hide:function(){if(this.contextmenu){this.contextmenu.style.display="none";}}}
hideContextMenu=function(e){contextmenu.hide();}
addEventOnLoad(window,'load',function(){contextmenu.init();});addEventOnLoad(document,'click',hideContextMenu);Actions={_Pa:{go:function(li){if(li.length==1){var mi=li[0];window.location.href=mi;}else if(li.length==2){var ni=li[0];var mi=li[1];var oi;if(ni=="lightbox"){oi=showLightbox("");}else{oi=elem(ni);}
oi.setEsrc(mi);}},refresh:function(pi){var qi=pi[0];var ri=elem(qi);ri.setEsrc(getEAttribute(ri,"src"));},close:function(si){var ti=si[0];var ui=elem(ti);ui.close();},scrollTo:function(vi){window.scrollTo(parseInt(vi[0]),parseInt(vi[1]));}},exec:function(wi,xi){var yi=this._Pa[wi];if(yi)yi(xi);},get:function(zi){return this._Pa[zi];},register:function(Ai,Bi){this._Pa[Ai]=Bi;}};Behavior=function(Ci,Di){if(Di)this.className=Di;this.funcs=Ci;};Behavior.prototype={attach:function(Ei,Fi){if(this.className)Consyn.addPrefixedClassFront(Ei,this.className);for(var Gi in this.funcs){addEvent(Ei,Gi,this.funcs[Gi]);}}};Behaviors={_Qa:[],add:function(Hi,Ii){this._Qa[Hi]=Ii;},get:function(Ji){if(undefined(this._Qa[Ji])){Consyn.tryLoadBehavior(Ji);}
return this._Qa[Ji];}};Behaviors.add("setLanguage",new Behavior({click:function(){Consyn.setLanguage(getAttribute(this,"language"));return false;}}));Behaviors.add("tabbutton",new Behavior({click:function(){var el=this;while(el!=null&&el!=document){if(el._Ra||el.setFocus){if(el._Ra)el._Ra(getAttribute(this,"key"),this);else if(el.setFocus)el.setFocus(getAttribute(this,"key"),this);return true;}
el=el.parentNode;}
return false;}},"tabbutton"));Behaviors.add("tooltip",new Behavior({mouseover:function(e){var Ki=getEAttribute(this,"tooltip");var Li=null;if(Ki){Li=Consyn.elem(this,Ki);var d=eval('['+getEAttribute(this,'tipdata')+']');var Mi=new ObjectDataCollection(d);if(Mi.hasNext()){Mi.next();fillTemplate(Mi,Li,getEAttribute(Li,"tiptemplate"));}}else{Li=elem("consyn_default_tooltip");if(!Li){Li=DOM.ce("div",{id:"consyn_default_tooltip"});document.body.appendChild(Li);Consyn.addPrefixedClassFront(Li,"tooltip");}
Li.innerHTML=getEAttribute(this,"tiptext");}
this.$tooltipOffsetLeft=14-getRealOffsetLeft(Li.parentNode);this.$tooltipOffsetTop=4-getRealOffsetTop(Li.parentNode);this.$tooltip=Li;setOffset(this.$tooltip,e.pageX+this.$tooltipOffsetLeft,e.pageY+this.$tooltipOffsetTop);show(Li);},mousemove:function(e){if(this.$tooltip){var x=e.pageX;var y=e.pageY;var ox=this.$tooltip.offsetWidth;var oy=this.$tooltip.offsetHeight;var Ni=(x+ox)-((window.innerWidth?window.innerWidth:document.documentElement.clientWidth?document.documentElement.clientWidth:document.body.clientWidth)+(window.scrollX?window.scrollX:document.documentElement.scrollLeft?document.documentElement.scrollLeft:document.body.scrollLeft));var Oi=(y+oy)-((window.innerHeight?window.innerHeight:document.documentElement.clientHeight?document.documentElement.clientHeight:document.body.clientHeight)+(window.scrollY?window.scrollY:document.documentElement.scrollTop?document.documentElement.scrollTop:document.body.scrollTop));if(Ni>=-22){x-=ox+2*14;}
if(Oi>=-22){y-=oy+2*4;}
setOffset(this.$tooltip,x+this.$tooltipOffsetLeft,y+this.$tooltipOffsetTop);}},mouseout:function(e){if(this.$tooltip){hide(this.$tooltip);this.$tooltip=null;}}}));_Sa=new Array();expandMenu=function(Pi,Qi){collapseCurrentMenu();_Sa=new Array();Pi=getFirstTagParent(Pi,"li");while(Pi&&Pi!=Qi){if(Pi.nodeName=="li"||Pi.nodeName=="LI"){_Sa.push(Pi);Pi.className="active";}
Pi=Pi.parentNode;}}
collapseMenu=function(Ri){Ri.className="";}
collapseCurrentMenu=function(){for(var i=0;i<_Sa.length;i++){collapseMenu(_Sa[i]);}
_Sa=new Array();}
Behaviors.add("dropdown",new Behavior({click:function(e){if(this.open){collapseCurrentMenu();this.open=false;}else{expandMenu(e.target,this);e.cancelBubble=true;this.open=true;return false;}},mouseover:function(e){if(_Sa.length>0){expandMenu(e.target,this);}}},"dropdown"));addEventOnLoad(document,'click',collapseCurrentMenu);Behaviors.add("rollover",new Behavior({mouseover:function(e){var Si=eAttr(this,"overclass");if(Si==null){Si="over";}
addClassFront(this,Si);},mouseout:function(e){var Ti=eAttr(this,"overclass");if(Ti==null){Ti="over";}
removeClass(this,Ti);}}));Behaviors.add("togglePane",new Behavior({click:function(e){var Ui=eAttr(this,"toggle_target");var Vi=Consyn.elem(this,Ui);toggleDisplay(Vi);}}));Behaviors.add("applyTransform",new Behavior({click:function(e){var Wi=eAttr(this,"apply_transform");var Xi=eAttr(this,"apply_target");var Yi=Consyn.elem(this,Xi);Consyn.transform(transform.split(' '),Xi);}}));Behaviors.add("do",new Behavior({click:function(e){var Zi=eAttr(this,"action");var $i=eAttr("params");Consyn.transform(Zi,$i.split(' '));}}));$$GUID=0;DataCollection=(new Base()).extend({getKey:function(){return -1;},hasNext:function(){return false;},next:function(){},get:function(aj){return null;},registerObserverCallback:function(bj,cj){this._Ta.push({observer:bj,method:cj});},notify:function(){for(var i=0;i<this._Ta.length;i++){var d=this._Ta[i];d.observer[d.method](this);}},getManipulator:function(){alert("This is an abstract method, please override.");},takeOver:function(dj){if(isDefined(dj)&&dj!=null){this._Ta=dj._Ta;}
this.notify();},reset:function(){}},function(){this._Ta=[];this.$GUID=$$GUID++;});EmptyDataCollection=(new DataCollection()).extend({},function(){this._Ta=[];this.$GUID=$$GUID++;});DataManipulator=(new Base()).extend({removeItem:function(ej){alert("This is an abstract method, please override.");},insertItem:function(fj,gj){alert("This is an abstract method, please override.");},moveItem:function(hj,ij){alert("This is an abstract method, please override.");}},function(jj){this.data=jj;});ObjectDataCollection=(new DataCollection()).extend({hasNext:function(){return this._Ua<this.array.length;},getKey:function(){return this._Ua-1;},next:function(){this._ea=this.array[this._Ua];this._Ua++;},get:function(kj){return this._ea[kj];},setData:function(lj){this.array=lj;this.reset();this.notify();},reset:function(){this._ea=null;this._Ua=0;},getManipulator:function(){return new ObjectDataManipulator(this);}},function(mj){this._Ta=[];this.setData(mj);this.$GUID=$$GUID++;});ObjectDataManipulator=(new DataManipulator()).extend({removeItem:function(nj){var oj=this.data.array.splice(nj,1);this.data.notify();return oj;},insertItem:function(pj,qj){if(qj==null){this.data.array.push(pj);}else{this.data.array.splice(qj,0,pj);}
this.data.notify();},moveItem:function(rj,sj){var tj=this.data.array.remove(rj);this.data.array.splice(sj,0,tj);this.data.notify();}},function(uj){this.data=uj;});XmlDataCollection=(new DataCollection()).extend({hasNext:function(){return this._da!=null;},getKey:function(){return this._Va;},next:function(){this._Va++;this._ea=this._da;if(this._ea!=null){this._da=findFirstElement(this._ea.nextSibling);}},get:function(vj){if(vj=="DATAITEM_KEY"){return this.getKey();}
var wj=null;try{wj=this._ea.getAttribute(vj);}catch(e){};if(wj){return wj;}else{if(this._ea&&this._ea.nodeName==vj){return new XmlDataCollection(this._ea);}
return null;}},setData:function(xj){this.root=xj;this.reset();this.notify();},reset:function(){this._ea=null;this._da=findFirstElement(this.root.firstChild);this._Va=-1;}},function(yj){this._Ta=[];this.setData(yj);this.$GUID=$$GUID++;});Transforms={};Transform={apply:function(zj){Log.consyn_error("Transform.apply should be overridden");},extend:function(Aj){for(var Bj in this){if(undefined(Aj[Bj])||Bj=="extend"){Aj[Bj]=this[Bj];}}
Aj.$super=this;return Aj;}};Component=Transform.extend({apply:function(Cj){for(var Dj in this){if(Dj!="apply"){Cj[Dj]=this[Dj];}}
Cj.init();},getState:function(){return "";},setState:function(Ej){},init:function(){}});nav_links_for={};Transforms.nav=Transform.extend({_Wa:function(e){var Fj=eAttr(this,"target");var Gj=eAttr(this,"href");var Hj=eAttr(this,"preventbubble");var Ij=eAttr(this,"confirm");var Jj=eAttr(this,"insert");if(Ij){var r=window.confirm(Ij);if(!r){return false;}}
var Kj;if(Fj=="lightbox"){Kj=showLightbox(this.title||"");}
if(Fj!="_top"){Kj=findTarget(Fj,this);}
if(!Kj){window.location.href=Gj;}else{Kj.setEsrc(Gj,Jj);}
if(Hj&&Hj.toLowerCase()=="true"){e.stopPropagation();}
return false;},apply:function(Lj){Consyn.addPrefixedClassFront(Lj,"nav");var Mj=eAttr(Lj,"target");var Nj=eAttr(Lj,"href");var Oj=findTarget(Mj,this);if(!Mj&&Oj){Mj=Oj.id;}
if(Lj.nodeName.toLowerCase()=="a"){var Nj=Lj.getAttribute("href");setAttribute(Lj,"href",Nj);Nj='#'+Consyn.getStateString(Mj,Nj);Lj.href=Nj;}
if(Oj){if(Mj){if(undefined(nav_links_for[Mj])){nav_links_for[Mj]=[];}
nav_links_for[Mj].push(Lj);}
if(Consyn.getState(Oj)==Nj){activateLink(Lj,Oj,Nj);}}
addEvent(Lj,'click',this._Wa);}});Transforms.content=Component.extend({defaultState:null,setTextData:function(Pj,Qj){if(isDefined(Qj)&&Qj!=null){if(Qj=="after"){var n=DOM.appendNew("div",this);n.innerHTML=Pj;}else if(Qj=="before"){var n=DOM.insertNewBefore("div",this.firstChild);n.innerHTML=Pj;}}else{removeChildNodes(this);this.innerHTML=Pj;}
Consyn.processNodes(this);Consyn.removeLoading(this);},setEsrc:function(Rj,Sj){this.e_src=Rj;setEAttribute(this,"src",Rj);if(Rj!=null){Consyn.storeState(this,Rj);Consyn.setLoading(this);var Tj=this;Consyn.getFileContentAsync(Rj,function(Uj){if(Uj!=null){Tj.setTextData(Uj,Sj);}else{Tj.setTextData("",Sj);}});}},show:function(){show(this);},hide:function(){hide(this);},init:function(){var Vj=getAttribute(this,"src");this.defaultState=Vj;var Wj=Consyn.getState(this);if(Wj)Vj=Wj;this.setEsrc(Vj);var s=eAttr(this,"state");if(s&&s.indexOf("hide")>=0){hide(this);}}});findIterate=function(Xj,Yj){if(undefined(Yj)){Yj=eAttr(Xj,'as');}
var Zj=new DomIterator(Xj);while(Zj.hasNext()){var el=Zj.next();var $j=eAttr(el,"template");if($j==Yj){return el;}
$j=eAttr(el,"iterate");if($j==Yj){return el;}}
return null;}
getDataByVarName=function(ak,bk,ck,el){var dk=ak.split('.');if(dk.length>1){if(dk[dk.length-2]==ck){ak=dk[dk.length-1];}else if(isDefined(el)){var n=getFirstEAttributeParent(el,'as',dk[0]);if(n){bk=n.getEdata();ak=dk[1];}else return null;}else return null;}
return isDefined(bk)?bk.get(ak):null;}
_Xa=["href","src","label","key","var","tipdata","tiptext"];_Ya=["href","src","id","name","value"];applyTemplateToElement=function(ek,fk,el){for(var i=0;i<_Ya.length;i++){var gk=_Ya[i];var hk=el.getAttribute('consynov'+gk);if(hk==null){hk=el.getAttribute(gk);el.setAttribute('consynov'+gk,hk);}
if(hk!=null&&typeof hk=="string"){if(gk=="href"&&hk.substring(0,11)=="about:blank"){hk=hk.substring(11);}
hk=processAttributeValue(hk,ek,fk);el.setAttribute(gk,hk);}}
for(var i=0;i<_Xa.length;i++){var gk=_Xa[i];var hk=eAttr(el,'consynov'+gk);if(hk==null){hk=eAttr(el,gk);setEAttribute(el,'consynov'+gk,hk);}
if(hk!=null&&typeof hk=="string"){hk=processAttributeValue(hk,ek,fk);setEAttribute(el,gk,hk);}}
var ik=getAttribute(el,"var");if(ik){var jk=ik.split('.');var d=getDataByVarName(ik,ek,fk,el);if(d!=null){removeChildNodes(el);el.appendChild(DOM.text(d));}}
var kk=eAttr(el,"template");if(undefined(kk)||kk==null){kk=eAttr(el,"iterate");}
if(kk&&kk!=""){var jk=kk.split('.');if(jk.length>1){if(jk[0]==fk){ek=ek.get(jk[1]);if(ek){dataToTemplate(ek,el);}}}}}
processAttributeValue=function(lk,mk,nk){var ok=lk.indexOf('${');while(ok>=0){j=lk.indexOf('}',ok);var pk=lk.substring(ok+2,j);var d=getDataByVarName(pk,mk,nk);if(d!=null){lk=lk.replace('${'+pk+'}',d);ok=j+1+d.length;}else{ok=j+1;}
ok=lk.indexOf('${',ok);}
return lk;}
fillTemplate=function(qk,rk,sk){if(undefined(sk)||sk==null){sk=eAttr(rk,'template');}
if(undefined(sk)||sk==null){sk=eAttr(rk,'iterate');}
var tk=new DomIterator(rk);var uk=false;while(tk.hasNext()){var el=tk.next();applyTemplateToElement(qk,sk,el);if(el==rk)uk=true;}
if(!uk)applyTemplateToElement(qk,sk,rk);Consyn.processNodes(rk);Consyn.processNode(rk);return rk;}
initDataTableIterator=function(vk,wk){if(!isDefined(vk.items)||vk.items.length==0){vk.iterate=findIterate(vk,wk);vk.iterate.style.display="none";vk.items=[];}}
dataToTemplate=function(xk,yk){yk.style.display="none";var zk=[];while(xk.hasNext()){xk.next();var c=yk.cloneNode(true);yk.parentNode.insertBefore(c,yk);c.iterateInstance=true;c=fillTemplate(xk,c);setAttribute(c,"template","");setAttribute(c,"iterate","");c.eItemKey=xk.getKey();c.getEItemKey=function(){return this.eItemKey;}
c.style.display="";zk[zk.length]=c;}
return zk;}
Transforms.datatable=Component.extend({setEsrc:function(Ak,Bk){setAttribute(this,'src',Ak);Consyn.storeState(this,Ak);var Ck=this;if(Bk){var Dk=Consyn.getDomDocument(Ak);var Ek=new XmlDataCollection(Dk.documentElement);this.setEdata(Ek);}else{Consyn.getDomDocumentAsync(Ak,function(Dk){var Ek=new XmlDataCollection(Dk.documentElement);Ck.setEdata(Ek);});}},setEdata:function(Fk){initDataTableIterator(this);for(var i=0;i<this.items.length;i++){deleteNode(this.items[i]);}
Fk.reset();if(this.eData==null||undefined(this.eData)){Fk.registerObserverCallback(this,"setEdata");}
this.eData=Fk;this.items=dataToTemplate(Fk,this.iterate);},getEdata:function(){return this.eData;},init:function(){var Gk=eAttr(this,"src");var Hk=eAttr(this,"data");var Ik=eAttr(this,"synchronized");var Jk=Ik&&Ik=="true";initDataTableIterator(this);var Kk=Consyn.getState(this);if(Kk)Gk=Kk;if(Gk){this.setEsrc(Gk,Jk);}else if(Hk){var Lk=Hk.split('.');var Mk=Consyn.getFromContext(this,Lk[0],Lk[1]);if(Mk==null||undefined(Mk)){Mk=new EmptyDataCollection();Consyn.setInContext(this,Lk[0],Lk[1],Mk);}
this.setEdata(Mk);}}});activateLinks=function(Nk,Ok){if(nav_links_for[Nk.id]){for(var i=nav_links_for[Nk.id].length-1;i>=0;i--){var Pk=nav_links_for[Nk.id][i];activateLink(Pk,Nk,Ok);}}}
activateLink=function(Qk,Rk,Sk){var Tk=eAttr(Qk,"highlight");if(Tk&&Tk.toLowerCase()=="true"){var h=eAttr(Qk,"href");removeClass(Qk,"active");if(Sk==h){addClassBack(Qk,"active");}}}
Transforms.tooltip=Transform.extend({apply:function(Uk){Consyn.addPrefixedClassFront(Uk,"tooltip");hide(Uk);}});Transforms.editable=Component.extend({init:function(){addEvent(this,'click',function(){this.makeEditable();});},makeEditable:function(){if(this.$editMode){return;}
this.$editMode=true;var Vk=XML.getText(this);removeChildNodes(this);var Wk=DOM.ce('input',{type:'text',value:Vk,$controller:this},[],{keyup:function(e){if(e.keyCode==13){var Xk=this.value;var Yk=this.$controller;var Zk=eAttr(Yk,"action");var $k=eval("x="+eAttr(Yk,"requestvars"));$k[eAttr(Yk,"var")]=Xk;Consyn.postRequestAsync(Zk,$k,function(al){if(al!=null){removeChildNodes(Yk);Yk.innerHTML=al;}else{alert("Could not save data!");}
Yk.$editMode=false;});}}});this.appendChild(Wk);Wk.focus();}});Transforms.pane=Transforms.content.extend({});Pane=(new Base()).extend({show:function(){this.active=true;this.div.style.display="block";if(this.labelNode){addClassBack(this.labelNode,"active");}},hide:function(){this.active=false;this.div.style.display="none";if(this.labelNode){removeClass(this.labelNode,"active");}}},function(bl,cl){this.name=bl;this.div=cl;this.active=false;this.labelNode=null;});Transforms.tabbed=Component.extend({init:function(){debug("Deprecated transform: 'tabbed'");var dl=new Array();var fl=new DomIterator(this);while(fl.hasNext()){var el=fl.next();var gl=getAttribute(el,"tab");if(gl){var t=new Pane(gl,el);t.hide();dl.push(t);}}
this.tabs=dl;setEAttribute(this,"as","tabs");this.setTabNamesData=Transforms.datatable.setEdata;this._Ra=function(hl,il){if(this._Za){this._Za.hide();}
for(var i=0;i<this.tabs.length;i++){if(this.tabs[i].name==hl){this._Za=this.tabs[i];break;}}
this._Za.labelNode=il;this._Za.show();}
this.setTabNamesData(new ObjectDataCollection(this.tabs));this._Ra(dl[0].name,this.items[0]);}});PaneGroupBehaviors={tabs:{after_init:function(){setEAttribute(this,"as","panes");this.setPaneNamesData(new ObjectDataCollection(this.panes));this.setFocus(this.panes[0].name,this.items[0]);},before_focus:function(){if(this.$activePane){this.$activePane.hide();}},after_focus:function(jl,kl){this.$activePane.labelNode=kl;this.$activePane.show();}},harmonics:{after_init:function(){for(var i=0;i<this.panes.length;i++){var t=DOM.ce("div");t.$paneGroup=this;t.$pane=this.panes[i];t.$pane.labelNode=t;addEvent(t,'click',function(){this.$paneGroup.setFocus(this.$pane.name,this);});t.appendChild(DOM.text(t.$pane.name));t.$pane.div.parentNode.insertBefore(t,t.$pane.div);Consyn.addPrefixedClassFront(t,"harmonics_title");if(i==0){this.setFocus(t.$pane.name);}}},before_focus:function(){if(this.$activePane){this.$activePane.hide();}},after_focus:function(ll){this.$activePane.show();}},frameset:{after_init:function(){},before_focus:function(){},after_focus:function(ml){}}};Transforms.panegroup=Component.extend({behavior:PaneGroupBehaviors.tabs,$activePane:null,$behavior:null,setFocus:function(nl,ol){this.$behavior.before_focus.call(this);for(var i=0;i<this.panes.length;i++){if(this.panes[i].name==nl){this.$activePane=this.panes[i];break;}}
this.$behavior.after_focus.call(this,nl,ol);},setPaneNamesData:Transforms.datatable.setEdata,init:function(){this.panes=[];var pl=new DomIterator(this);while(pl.hasNext()){var el=pl.next();var ql=getAttribute(el,"pane");if(ql){var t=new Pane(ql,el);Consyn.addPrefixedClassFront(el,"pane");t.hide();this.panes.push(t);}}
var rl=eAttr(this,"panebehavior");if(rl){this.$behavior=PaneGroupBehaviors[rl];this.$behavior.after_init.call(this);}else{Log.consyn_error("Missing e:panebehavior attribute for panegroup transform");}}});Transforms.window=Transforms.pane.extend({init:function(){this.$super.init.call(this);var h=this.offsetHeight;var w=this.offsetWidth;var sl=DOM.ce("div");Consyn.addPrefixedClassFront(sl,"window");var tl=eAttr(this,"title");var ul=DOM.ce("div",{},[DOM.text(tl)]);Consyn.addPrefixedClassFront(ul,"titlebar");addEvent(ul,'mousedown',function(e){Drag.start(e,'ConsynBase_ElementDrag',{element:sl,bounded:false});});sl.appendChild(ul);setSize(sl,h,w);this.parentNode.insertBefore(sl,this);var vl=deleteNode(this);sl.appendChild(vl);}});Transforms.lightbox=Transforms.pane.extend({init:function(){this.$super.init.call(this);var wl=this;this.$bgNode=DOM.ce("div");var xl=eAttr(this,"title")||"";var yl=DOM.ce("span",{},[DOM.text("x")],{click:function(e){wl.close();}});var zl=DOM.ce("div",{},[DOM.text(xl),DOM.ce("div",{className:Consyn.getPrefixedClassName("controls")},[yl])]);Consyn.addPrefixedClassFront(zl,"titlebar");this.$bgNode.appendChild(zl);this.parentNode.insertBefore(this.$bgNode,this);var el=deleteNode(this);var Al=DOM.ce('div',{},[zl,el]);this.$bgNode.appendChild(Al);Consyn.addPrefixedClassFront(this.$bgNode,"lightbox_bg");Consyn.addPrefixedClassFront(Al,"lightbox_box");Consyn.addPrefixedClassFront(el,"pane");this.update();addEvent(document,'scroll',function(e){wl.update();});addEvent(document.body,'scroll',function(e){wl.update();});},close:function(){deleteNode(this.$bgNode);},update:function(){var t=document.body.scrollTop;if(document.documentElement)t+=document.documentElement.scrollTop;this.$bgNode.style.top=t+"px";}});showLightbox=function(Bl){var n=elem("lightbox");if(n==null){n=DOM.ce("div",{id:"lightbox"});document.body.appendChild(n);setEAttribute(n,"title",Bl||"");Framework.transform(["lightbox"],n);}
return n;}
Animation=(new Base()).extend({step:function(dt){return false;},start:function(){Animations.start(this);}});Animations={all:{move:(new Animation()).extend({step:function(dt){this.time-=dt;var Cl=(this.totalTime-this.time)/this.totalTime;if(this.time<=0){Cl=1;}
setOffset(this.obj,this.fromX+(Cl*this.deltaX),this.fromY+(Cl*this.deltaY));return this.time>0;}},function(Dl,El,Fl,Gl){this.obj=Dl;this.fromX=Dl.offsetLeft;this.fromY=Dl.offsetTop;this.deltaX=El-this.fromX;this.deltaY=Fl-this.fromY;this.toX=El;this.toY=Fl;this.time=Gl;this.totalTime=Gl;}),resize:(new Animation()).extend({step:function(dt){}})},_$a:null,_ab:[],_bb:0,start:function(Hl){this._ab.push(Hl);if(this._$a==null){this._bb=(new Date()).getTime();this._$a=setInterval(this._cb,40);}},_db:function(){var t=(new Date()).getTime();var dt=t-this._bb;this._bb=t;for(var i=this._ab.length-1;i>=0;i--){var Il=this._ab[i].step(dt);if(Il==false){this._ab.splice(i,1);}}},_cb:function(){Animations._db();}};Push={request:null,lastLength:0,newContent:"",_eb:"",_fb:false,_gb:null,restart:function(){this.reset();if(!this._fb){this.open(this._eb,this._hb,this._ib);this._fb=false;}},reset:function(){this.check();clearInterval(this._gb);this.request=null;this.lastLength=0;this.newContent="";},stop:function(){if(this.request){this.request.abort();this.request=null;}
this.reset();this._fb=true;},open:function(Jl,Kl,Ll){if(this.request!=null)this.stop();this._eb=Jl;this._hb=Kl;this._ib=Ll;this._fb=false;if(_ma){var Ml=document.createElement("iframe");Ml.style.display="none";Ml.setAttribute("src",Jl);document.body.appendChild(Ml);}else{Push.request=Consyn.getRequest();Push.request.open("GET",Jl+"?channel="+Kl+"&startFrom="+Ll,true);Push.request.onreadystatechange=function(){if(Push.request.readyState==4){Push.restart();}};Push.request.send(null);Push._gb=setInterval(Push.check,100);}},check:function(){if(Push.request!=null){var Nl=Push.request.responseText.length;if(Nl>Push.lastLength){Push.newContent+=Push.request.responseText.substring(Push.lastLength,Nl);var Ol="";var i=Push.newContent.indexOf("<script>");var j=(i>=0)?Push.newContent.indexOf("</script>",i):-1;while(i>=0&&j>i){var Ol=Push.newContent.substring(i+8,j);Push.newContent=Push.newContent.substring(j+9);i=Push.newContent.indexOf("<script>");j=Push.newContent.indexOf("</script>",i);eval(Ol);}
Push.lastLength=Nl;}}},receive:function(Pl,Ql,Rl){var Sl=document.createElement("div");Sl.appendChild(document.createTextNode(Rl));var Tl=elem('pushReceiver');Tl.appendChild(Sl);Tl.scrollTop=Sl.offsetTop;if(Ql>this._ib)this._ib=Ql;},send:function(Ul){}};P_receive=function(c,s,m){Push.receive(c,s,m);};