function $(id){return document.getElementById(id);}function getElement(idOrElem){return(typeof idOrElem=="object"?idOrElem:$(idOrElem));}wcl={};wcl.idFactory=new function(){var lastId=0;this.get=function(){return"genericID_"+(++lastId);};this.ensure=function(elem){if(elem!=null&&(elem.id==null||elem.id==UNDEFINED||""==elem.id)){elem.id=this.get();}};};wcl.html={$elem:function(idOrElem){return(typeof idOrElem=="object"?idOrElem:$(idOrElem));},addLoadEvent:function(funct){var oldOnLoad=window.onload;if(typeof window.onload!="function"){window.onload=funct;}else{window.onload=function(){oldOnLoad();funct();};}},cloneNode:function(source,cloneChildren){if(source.cloneNode!=null&&source.cloneNode!=UNDEFINED){return source.cloneNode(cloneChildren);}else{var clone=document.createElement(source.nodeName);for(var i=0;i<source.attributes.length;i++){var attrib=source.attributes[i];if(attrib.specified==true){clone.setAttribute(attrib.name,attrib.value);}}if(cloneChildren){for(childNode in source){clone.appendChild(wcl.html.cloneNode(childNode,cloneChildren));}}return clone;}},create:function(tagName,id,className){var tag=document.createElement(tagName);tag.id=((id==UNDEFINED||id==null)?wcl.idFactory.get():id);if(className){wcl.css.set(tag,className);}return tag;},clearChildren:function(container){container=wcl.html.$elem(container);while(container.firstChild){container.removeChild(container.firstChild);}},img:function(id,src,alt,title,description,className){var img=wcl.html.create("img",id,className);if(src!=UNDEFINED&&src!=null){img.setAttribute("src",src);}img.setAttribute("alt",(alt==UNDEFINED||alt==null)?src:alt);img.setAttribute("title",(title==UNDEFINED||title==null)?src:title);img.setAttribute("description",(description==UNDEFINED||description==null)?src:description);return img;},a:function(id,href,title,className){var a=wcl.html.create("a",id,className);a.setAttribute("href",href);a.setAttribute("title",title||href);return a;},addANewWindow:function(elem){elem=wcl.html.$elem(elem);elem.onclick=function(){var fWin=window.open(this.href);return(fWin==null);};},div:function(id,className){return wcl.html.create("div",id,className);},p:function(id,className){return wcl.html.create("p",id,className);},cselect:function(id,name,className){var ctrl=wcl.html.create("select",id,className);if(ctrl.name){ctrl.name=name;}else{ctrl.setAttribute("name",name);}return ctrl;},coption:function(value,selected,text){var opt=wcl.html.create("option");if(opt.value){opt.value=value;}else{opt.setAttribute("value",value);}if(selected&&(selected=="selected"||selected==true)){if(opt.selected){opt.selected=selected;}else{opt.setAttribute("selected",selected);}}opt.appendChild(document.createTextNode(text));return opt;},text:function(text){return document.createTextNode(text);},h:function(type,text,id,className){var h=wcl.html.create("h"+type,id,className);h.appendChild(wcl.html.text(text));return h;},show:function(elem){elem.style.visibility="visible";elem.style.display="block";},hide:function(elem){elem.style.visibility="hidden";elem.style.display="none";},opacity:function(elem,value){elem.style.opacity=value/100;elem.style.filter="alpha(opacity="+value+")";},getOpacity:function(elem){elem=this.$elem(elem);return elem.style.opacity?elem.style.opacity*100:100;},calcToParent:function(elem,parent,delegate){elem=wcl.html.$elem(elem);parent=wcl.html.$elem(parent);if(!elem||!parent){return null;}var result=0;while(elem&&elem.parentNode&&elem.parentNode!=parent){result=delegate(elem,result);elem=elem.parentNode;}return result;},getEventSrc:function(elem,event){if(event.srcElement){return event.srcElement;}else{return elem;}}};String.prototype.leftTrim=function(){return(this.replace(/^\s+/,""));};wcl.css={get:function(elem){if(elem==null||elem==UNDEFINED){return null;}if((elem.getAttribute==null||elem.getAttribute==UNDEFINED)){return elem.className;}else{return elem.getAttribute("class")||elem.getAttribute("className");}},set:function(elem,value){if(elem==null||elem==UNDEFINED){return null;}if(elem.setAttribute==null||elem.setAttribute==UNDEFINED){elem.className=value;}else{elem.setAttribute("class",value);elem.setAttribute("className",value);}},is:function(elem,value){return wcl.css.get(elem)==value;},has:function(elem,value){var cssnames=wcl.css.get(elem);return(cssnames!=null&&cssnames!=UNDEFINED&&cssnames.indexOf(value)>=0);},append:function(elem,value){wcl.css.set(elem,wcl.css.get(elem)+" "+value);},prepend:function(elem,value){wcl.css.set(elem,value+" "+wcl.css.get(elem));},remove:function(elem,value){var cssnames=wcl.css.get(elem);if(cssnames==null||cssnames==UNDEFINED||cssnames.indexOf(value)<0){return true;}wcl.css.set(elem,cssnames.replace(cssnames.indexOf(value)==0?value:" "+value,"").leftTrim());return true;},getStyle:function(element){if(window.getComputedStyle){return window.getComputedStyle(element,null);}else{if(element.currentStyle){return element.currentStyle;}}}};wcl.StopWatch=function(){this.started=0;this.stoped=0;this.running=false;this.start=function(){this.started=new Date().getTime();this.stoped=0;this.running=true;};this.stop=function(){this.stoped=new Date().getTime();this.running=false;return this.stoped-this.started;};this.reset=function(){this.stop();this.started=0;this.stoped=0;};this.elapsed=function(){if(!this.running){return 0;}var now=new Date().getTime();return now-this.started;};};function MM_swapImgRestore(){var i,x,a=document.MM_sr;for(i=0;a&&i<a.length&&(x=a[i])&&x.oSrc;i++){x.src=x.oSrc;}}function MM_preloadImages(){var d=document;if(d.images){if(!d.MM_p){d.MM_p=new Array();}var i,j=d.MM_p.length,a=MM_preloadImages.arguments;for(i=0;i<a.length;i++){if(a[i].indexOf("#")!=0){d.MM_p[j]=new Image;d.MM_p[j++].src=a[i];}}}}function MM_findObj(n,d){var p,i,x;if(!d){d=document;}if((p=n.indexOf("?"))>0&&parent.frames.length){d=parent.frames[n.substring(p+1)].document;n=n.substring(0,p);}if(!(x=d[n])&&d.all){x=d.all[n];}for(i=0;!x&&i<d.forms.length;i++){x=d.forms[i][n];}for(i=0;!x&&d.layers&&i<d.layers.length;i++){x=MM_findObj(n,d.layers[i].document);}if(!x&&d.getElementById){x=d.getElementById(n);}return x;}function MM_swapImage(){var i,j=0,x,a=MM_swapImage.arguments;document.MM_sr=new Array;for(i=0;i<(a.length-2);i+=3){if((x=MM_findObj(a[i]))!=null){document.MM_sr[j++]=x;if(!x.oSrc){x.oSrc=x.src;}x.src=a[i+2];}}}function MM_openBrWindow(theURL,winName,features){window.open(theURL,winName,features);}function setCssClass(element,cssclass){if(element.className){element.className=cssclass;}else{element.setAttribute("class",cssclass);}}function getCssClass(element){if(element.className){return element.className;}return element.getAttribute("class");}function strEqualsIgnoreCase(str1,str2){if(str1==UNDEFINED&&str2==UNDEFINED){return true;}if((str1==UNDEFINED&&str2!=UNDEFINED)||(str1!=UNDEFINED&&str2==UNDEFINED)){return false;}return str1.toLowerCase()==str2.toLowerCase();}function getChildElementsByTagName(rootElement,tagName){if(rootElement.getElementsByTagName!=null&&typeof rootElement.getElementsByTagName=="function"){return rootElement.getElementsByTagName(tagName);}var result=new Array();for(var i=0;i<rootElement.childNodes.length;i++){if(strEqualsIgnoreCase(rootElement.childNodes[i].tagName,tagName)){result.push(rootElement.childNodes[i]);}var childResult=getChildElementsByTagName(rootElement.childNodes[i],tagName);for(var ic=0;ic<childResult.length;ic++){result.push(childResult[ic]);}}return result;}function forAllObjects(objArray,funct){for(var i=0;i<objArray.length;i++){funct(objArray[i]);}}function getFirstParentTag(childElement,tagName,className){if(childElement==null||childElement==UNDEFINED||childElement.parentNode==null||childElement.parentNode==UNDEFINED){return null;}var parent=childElement.parentNode;if(strEqualsIgnoreCase(parent.tagName,tagName)&&getCssClass(parent).indexOf(className)>=0){return parent;}return getFirstParentTag(parent,tagName,className);}function getFormByName(formName){for(var i=0;i<document.forms.length;++i){var iFormName="";if(document.forms[i].name){iFormName=document.forms[i].name;}else{iFormName=document.forms[i].getAttribute("name");}if(iFormName==formName){return document.forms[i];}}return null;}function checkAllFormname(checked,formName){checkAllForm(checked,getFormByName(formName));}function checkAllForm(checked,form){for(var i=0;i<form.elements.length;++i){if(form.elements[i].type=="checkbox"&&form.elements[i].id=="remote"){form.elements[i].checked=checked;}}}function checkAll(checked){for(var i=0;i<document.forms[0].elements.length;++i){if(document.forms[0].elements[i].type=="checkbox"&&document.forms[0].elements[i].id=="remote"){document.forms[0].elements[i].checked=checked;}}}function setCheckedByIdRegexFormname(checked,regex,formName){setCheckedByIdRegexForm(checked,regex,getFormByName(formName));}function setCheckedByIdRegexForm(checked,regex,form){for(var i=0;i<form.elements.length;++i){if(form.elements[i].type=="checkbox"){var elem=form.elements[i];if(elem.id.match(regex)){form.elements[i].checked=checked;}}}}function setCheckedByIdRegex(checked,regex){for(var i=0;i<document.forms[0].elements.length;++i){if(document.forms[0].elements[i].type=="checkbox"){var elem=document.forms[0].elements[i];if(elem.id.match(regex)){document.forms[0].elements[i].checked=checked;}}}}var genericId=1;var genericIdPrefix="#genericID";function getNewGenericId(){return genericIdPrefix+(++genericId);}Array.prototype.remove=function(from,to){var rest=this.slice((to||from)+1||this.length);this.length=from<0?this.length+from:from;return this.push.apply(this,rest);};eventobj=new Array();function addEventHandler(sourceObject,eventName,eventHandler){var isNewHandler=false;if(sourceObject==null||eventName==null||typeof eventHandler!="function"){return false;}if(eventobj[sourceObject.id]==null){eventobj[sourceObject.id]=new Array();}if(eventobj[sourceObject.id][eventName]==null){eventobj[sourceObject.id][eventName]=new Array();isNewHandler=true;}var registered=eval("sourceObject."+eventName);if(isNewHandler&&typeof registered=="function"){eventobj[sourceObject.id][eventName][eventobj[sourceObject.id][eventName].length]=registered;}eventobj[sourceObject.id][eventName][eventobj[sourceObject.id][eventName].length]=eventHandler;if(isNewHandler){var gEvent=function(event){var toReturn=true;if(this.id!=null&&eventobj[this.id]!=null&&eventName!=null){for(var i=0;i<eventobj[this.id][eventName].length;i++){try{toReturn=eventobj[this.id][eventName][i](this,event)&&toReturn;}catch(e){toReturn=false;}}return(toReturn==true);}else{return false;}};eval("sourceObject."+eventName+"=gEvent");}return true;}function addLoadEvent(funct){var oldOnLoad=window.onload;if(typeof window.onload!="function"){window.onload=funct;}else{window.onload=function(){oldOnLoad();funct();};}}function addOnClick(element,funct){if(element==null||funct==null){return false;}return addEventHandler(element,"onclick",funct);}function onButtonClickAvoidMultiSubmit(button){var disabled=isDisabledButton(button);if(button.disableTimeout==null&&!disabled){disableButton(button,3000);}else{if(!disabled){disableButton(button,button.disableTimeout);}}button.style.cursor="wait";return !disabled;}function isDisabledButton(button){return(button.style.cursor=="wait");}var disabledButtons=new Array();function disableButton(button,milliseconds){if(button.onmouseout!=null){var oldMouseOut=button.onmouseout;button.onmouseout=function(){if(!isDisabledButton(button)){oldMouseOut();}};}button.style.cursor="wait";disabledButtons[button.id]=button;if(milliseconds>0){setTimeout("enableButton(disabledButtons['"+button.id+"'])",milliseconds);}}function enableButton(button){if(button!=null&&button.style!=null){button.style.cursor="";}if(button.onmouseout!=null){button.onmouseout();}}function registerImageButtonMultiClickHandlers(){if(!document.getElementsByTagName||!document.getElementById){return false;}inputElements=document.getElementsByTagName("input");for(var i=0;i<inputElements.length;i++){if(inputElements[i].getAttribute("type")=="image"){addOnClick(inputElements[i],onButtonClickAvoidMultiSubmit);}}return true;}function registerHrefMultiClickHandlers(){if(document.getElementsByTagName!=null||document.getElementById!=null){inputElements=document.getElementsByTagName("a");for(var i=0;i<inputElements.length;i++){if(inputElements[i].getAttribute("href").indexOf(".do")>0){if(inputElements[i].id==null||inputElements[i].id==""){inputElements[i].id=getNewGenericId();}addOnClick(inputElements[i],onButtonClickAvoidMultiSubmit);}}}return true;}function addEvent(elem,eventType,method){if(elem.addEventListener){elem.addEventListener(eventType,method,false);}else{if(elem.attachEvent){elem.attachEvent("on"+eventType,method);}else{elem["on"+eventType]=method;}}}function returnFalse(event){if(event.preventDefault){event.preventDefault();}else{event.returnValue=false;}}wcl.FilteredDropDown=function(dropDownId,dropDownPfeilImgSrc,activeDropDownPfeilImgSrc,maxElemCount,optionValueForDelete){var actualPosition=null;var timeoutId=null;var _this=this;var skipBlur=false;var filterListVisible=false;this.maxElemCount=maxElemCount||20;this.filteredElemCount=0;this.show=function(){var originalDropDown=getElement(dropDownId);if(originalDropDown!=null){var filterListId="filterListFor"+originalDropDown.id;var filterFieldId="filterFieldFor"+originalDropDown.id;var filterSelectImgId="filterSelectImg"+originalDropDown.id;var filterField=wcl.html.create("input",filterFieldId);addEvent(filterField,"keyup",function(event){doFiltering(event,getElement(filterListId),wcl.html.getEventSrc(this,event),originalDropDown);});addEvent(filterField,"keypress",function(event){event=!event?window.event:event;var keyCode=event.which?event.which:event.keyCode;if(keyCode==13){returnFalse(event);if(_this.actualPosition==-1&&filterField.value!=""){var newPosition=0;while(newPosition<getElement(filterListId).childNodes.length&&getElement(filterListId).childNodes[newPosition].style.visibility=="hidden"){newPosition++;}if(newPosition<getElement(filterListId).childNodes.length){selectFilteredValue(getElement(getElement(filterListId).childNodes[newPosition].id),filterField,filterListId,originalDropDown);}}else{if(_this.actualPosition!=null&&_this.actualPosition!=-1){selectFilteredValue(getElement(getElement(filterListId).childNodes[_this.actualPosition].id),filterField,filterListId,originalDropDown);}}}else{if(keyCode==27){var filterList=getElement(filterListId);var parentNode=filterList.parentNode;parentNode.removeChild(filterList);for(var i=0;i<filterList.childNodes.length;i++){show(filterList.childNodes[i]);}hide(filterList);parentNode.appendChild(filterList);_this.filteredElemCount=_this.maxElemCount;setHeightOfFilterList(filterList);for(var i=0;i<originalDropDown.childNodes.length;i++){if(originalDropDown.childNodes[i].selected==true){filterField.value=originalDropDown.childNodes[i].text;}}if(_this.actualPosition!=null&&_this.actualPosition!=-1){wcl.css.remove(getElement(filterListId).childNodes[_this.actualPosition],"selectedFilterValueHoverJS");wcl.css.remove(getElement(filterListId).childNodes[_this.actualPosition].childNodes[0],"selectedFilterValueHoverJS");}_this.actualPosition=null;}}});addEvent(filterField,"click",function(){toggleDropDown(filterListId,filterField);});addEvent(filterField,"focus",function(){getElement(filterSelectImgId).src=activeDropDownPfeilImgSrc;});addEvent(filterField,"blur",function(){getElement(filterSelectImgId).src=dropDownPfeilImgSrc;if(!_this.skipBlur){var filterList=getElement(filterListId);var parentNode=filterList.parentNode;parentNode.removeChild(filterList);for(var i=0;i<filterList.childNodes.length;i++){show(filterList.childNodes[i]);}hide(filterList);parentNode.appendChild(filterList);if(_this.maxElemCount<filterList.childNodes.length){_this.filteredElemCount=_this.maxElemCount;}else{_this.filteredElemCount=filterList.childNodes.length;}setHeightOfFilterList(filterList);filterListVisible=false;for(var i=0;i<originalDropDown.childNodes.length;i++){if(originalDropDown.childNodes[i].selected==true){filterField.value=originalDropDown.childNodes[i].text;
}}if(_this.actualPosition!=null&&_this.actualPosition!=-1){wcl.css.remove(getElement(filterListId).childNodes[_this.actualPosition],"selectedFilterValueHoverJS");wcl.css.remove(getElement(filterListId).childNodes[_this.actualPosition].childNodes[0],"selectedFilterValueHoverJS");}_this.actualPosition=null;}});filterField.setAttribute("autocomplete","off");var filterSelectImg=wcl.html.create("img",filterSelectImgId,"filterFieldSelectImgJS");filterSelectImg.setAttribute("src",dropDownPfeilImgSrc);addEvent(filterSelectImg,"mousedown",function(){_this.skipBlur=true;});addEvent(filterSelectImg,"click",function(){_this.skipBlur=false;filterField.click();});var filterList=wcl.html.create("div",filterListId,"filterListJS");var filteredValue=null;for(var i=0;i<originalDropDown.childNodes.length;i++){if(originalDropDown.childNodes[i].nodeType==1&&originalDropDown.childNodes[i].value!=optionValueForDelete){this.filteredElemCount++;var filteredValueId=originalDropDown.id+"$"+originalDropDown.childNodes[i].value+"$";filteredValue=wcl.html.create("div",filteredValueId);var filteredValueLink=wcl.html.a("a"+filteredValueId,null,"");filteredValueLink.appendChild(wcl.html.text(originalDropDown.childNodes[i].text));addEvent(filteredValueLink,"mouseover",function(event){event=!event?window.event:event;wcl.css.append(wcl.html.getEventSrc(this,event).parentNode,"selectedFilterValueHoverJS");});addEvent(filteredValueLink,"mouseout",function(event){event=!event?window.event:event;wcl.css.remove(wcl.html.getEventSrc(this,event).parentNode,"selectedFilterValueHoverJS");});addEvent(filteredValueLink,"click",function(event){event=!event?window.event:event;returnFalse(event);});filteredValue.appendChild(filteredValueLink);addEvent(filteredValue,"mousedown",function(){_this.skipBlur=true;});addEvent(filteredValue,"click",function(event){event=!event?window.event:event;_this.skipBlur=true;selectFilteredValue(wcl.html.getEventSrc(this,event),filterFieldId,filterListId,originalDropDown);});addEvent(filteredValue,"mouseover",function(event){event=!event?window.event:event;wcl.css.append(wcl.html.getEventSrc(this,event),"selectedFilterValueHoverJS");});addEvent(filteredValue,"mouseout",function(event){event=!event?window.event:event;wcl.css.remove(wcl.html.getEventSrc(this,event),"selectedFilterValueHoverJS");});if(originalDropDown.childNodes[i].selected==true){wcl.css.set(filteredValue,"selectedFilterValueJS");filterField.value=originalDropDown.childNodes[i].text;}filterList.appendChild(filteredValue);}}addEvent(filterList,"mousedown",function(){_this.skipBlur=true;});addEvent(filterList,"mouseup",function(){filterField.select();_this.skipBlur=false;});var filteredDropDown=wcl.html.create("div",null,"filteredDropDownJS");filteredDropDown.appendChild(filterField);filteredDropDown.appendChild(filterSelectImg);setHeightAndWidthOfFilteredDropDown(filteredDropDown,originalDropDown);originalDropDown.parentNode.insertBefore(filterList,originalDropDown);filterList.parentNode.insertBefore(filteredDropDown,filterList);filterList.style.minWidth=filterField.offsetWidth+"px";hide(filterList);hide(originalDropDown);}};var setHeightAndWidthOfFilteredDropDown=function(filteredDropDown,originalDropDown){filteredDropDown.style.width=originalDropDown.offsetWidth;filteredDropDown.style.marginLeft=parseInt(wcl.css.getStyle(originalDropDown).marginLeft);filteredDropDown.style.marginRight=parseInt(wcl.css.getStyle(originalDropDown).marginRight);filteredDropDown.style.height=originalDropDown.offsetHeight;filteredDropDown.style.marginTop=parseInt(wcl.css.getStyle(originalDropDown).marginTop);filteredDropDown.style.marginBottom=parseInt(wcl.css.getStyle(originalDropDown).marginBottom);};var setHeightOfFilterList=function(filterList){var filteredValues=filterList.getElementsByTagName("div");var filteredValue=filteredValues[0];if(filteredValue){var elemHeight=(filteredValue.offsetHeight==0?15:filteredValue.offsetHeight)+parseInt(wcl.css.getStyle(filteredValue).marginTop)+parseInt(wcl.css.getStyle(filteredValue).marginBottom);if(_this.filteredElemCount>_this.maxElemCount){filterList.style.height=_this.maxElemCount*elemHeight;}else{filterList.style.height=_this.filteredElemCount*elemHeight;}}};var toggleDropDown=function(filterListId,filterField){if(filterListVisible){hide(getElement(filterListId));filterListVisible=false;if(_this.actualPosition!=null&&_this.actualPosition!=-1&&getElement(filterListId).childNodes[_this.actualPosition].getAttribute){wcl.css.remove(getElement(filterListId).childNodes[_this.actualPosition],"selectedFilterValueHoverJS");}}else{filterListVisible=true;filterField.select();var filterList=getElement(filterListId);filterList.style.top=parseInt(filterField.parentNode.offsetTop)+parseInt(filterField.parentNode.offsetHeight);filterList.style.left=parseInt(filterField.parentNode.offsetLeft);show(filterList);setHeightOfFilterList(filterList);}};var doFiltering=function(event,filterList,filterField,originalDropDown){event=!event?window.event:event;var keyCode=event.which?event.which:event.keyCode;if(keyCode==40||keyCode==39){if(_this.actualPosition==-1){_this.actualPosition=null;}if(_this.actualPosition==null){var firstPos=0;while(firstPos<filterList.childNodes.length&&filterList.childNodes[firstPos].style.visibility=="hidden"){firstPos++;}if(filterList.childNodes[firstPos]){wcl.css.append(filterList.childNodes[firstPos],"selectedFilterValueHoverJS");filterField.value=filterList.childNodes[firstPos].childNodes[0].childNodes[0].data;}_this.actualPosition=firstPos;return;}else{var firstPos=_this.actualPosition+1;while(firstPos<filterList.childNodes.length&&filterList.childNodes[firstPos].style.visibility=="hidden"){firstPos++;}if(firstPos<filterList.childNodes.length){if(filterList.childNodes[firstPos].offsetTop>filterList.offsetHeight+filterList.scrollTop-filterList.childNodes[firstPos].offsetHeight){filterList.scrollTop=filterList.childNodes[firstPos].offsetHeight+filterList.scrollTop+1;}wcl.css.remove(filterList.childNodes[_this.actualPosition],"selectedFilterValueHoverJS");wcl.css.append(filterList.childNodes[firstPos],"selectedFilterValueHoverJS");filterField.value=filterList.childNodes[firstPos].childNodes[0].childNodes[0].data;_this.actualPosition=firstPos;}return;}}else{if(keyCode==38||keyCode==37){if(_this.actualPosition==-1){_this.actualPosition=null;}if(_this.actualPosition!=null){var lastPos=_this.actualPosition-1;while(lastPos>=0&&filterList.childNodes[lastPos].style.visibility=="hidden"){lastPos--;}if(lastPos>=0){if(filterList.childNodes[lastPos].offsetTop<filterList.scrollTop){filterList.scrollTop=filterList.childNodes[lastPos].offsetTop;}wcl.css.remove(filterList.childNodes[_this.actualPosition],"selectedFilterValueHoverJS");wcl.css.append(filterList.childNodes[lastPos],"selectedFilterValueHoverJS");filterField.value=filterList.childNodes[lastPos].childNodes[0].childNodes[0].data;_this.actualPosition=lastPos;}return;}}else{if(keyCode==9){}else{if(keyCode==27){hide(filterList);filterListVisible=false;for(var i=0;i<originalDropDown.childNodes.length;i++){if(originalDropDown.childNodes[i].selected==true){filterField.value=originalDropDown.childNodes[i].text;}}if(_this.actualPosition!=null&&_this.actualPosition!=-1){wcl.css.remove(filterList.childNodes[_this.actualPosition],"selectedFilterValueHoverJS");wcl.css.remove(filterList.childNodes[_this.actualPosition].childNodes[0],"selectedFilterValueHoverJS");_this.actualPosition=null;}}else{_this.actualPosition=-1;show(filterList);setHeightOfFilterList(filterList);filterListVisible=true;clearTimeout(_this.timeoutId);_this.timeoutId=window.setTimeout(function(){var parentNode=filterList.parentNode;parentNode.removeChild(filterList);var filterItems=filterList.getElementsByTagName("div");var visibleElemCnt=0;for(var i=0;i<filterItems.length;i++){var hrefs=filterItems[i].getElementsByTagName("a");var toCompare=""+hrefs[0].childNodes[0].data.replace(String.fromCharCode(160)," ");toCompare=toCompare.toLowerCase();var compareResult=(toCompare.indexOf(filterField.value.toLowerCase())==-1);if(compareResult){hide(filterItems[i]);wcl.css.remove(filterItems[i],"selectedFilterValueHoverJS");wcl.css.remove(hrefs[0],"selectedFilterValueHoverJS");}else{show(filterItems[i]);visibleElemCnt++;wcl.css.remove(filterItems[i],"selectedFilterValueHoverJS");wcl.css.remove(hrefs[0],"selectedFilterValueHoverJS");}}parentNode.appendChild(filterList);_this.filteredElemCount=visibleElemCnt;setHeightOfFilterList(filterList);},300);}}}}};var selectFilteredValue=function(selected,filterFieldId,filterListId,originalDropDown){var taga=selected.tagName.toLowerCase()=="a"?selected:selected.getElementsByTagName("a")[0];if(taga!=null&&taga!=UNDEFINED&&taga.childNodes[0]!=null&&taga.childNodes[0]!=UNDEFINED){getElement(filterFieldId).value=taga.childNodes[0].data;}hide(getElement(filterListId));wcl.css.set(taga,"selectedFilterValueJS");var extractedId=selected.id.substring(selected.id.indexOf("$")+1,selected.id.length);extractedId=extractedId.substring(0,extractedId.indexOf("$"));for(var i=0;i<originalDropDown.options.length;i++){if(originalDropDown.options[i].value==extractedId){originalDropDown.options[i].selected=true;originalDropDown.selectedIndex=i;if(originalDropDown.onchange){originalDropDown.onchange();}return;}}};};function show(elem,display){if(display==null){display="block";}getElement(elem).style.visibility="visible";getElement(elem).style.display=display;}function hide(elem){getElement(elem).style.visibility="hidden";getElement(elem).style.display="none";}function showHide(elem){if(getElement(elem).style.visibility=="visible"||getElement(elem).style.visibility=="block"){getElement(elem).style.visibility="hidden";getElement(elem).style.display="none";}else{getElement(elem).style.visibility="visible";getElement(elem).style.display="block";}}addLoadEvent(registerImageButtonMultiClickHandlers);addLoadEvent(registerHrefMultiClickHandlers);
