
var $=function(node){return document.getElementById(node);}
var $IMG=function(node){return document.images[node];}
var $DOM_T=function(node){return function(nameT){return node.getElementsByTagName(nameT);}}
var _A=function(){return document.URL;}();var _find=function(txtNode){return function(txt){if(txtNode.indexOf(txt)>-1){return true;}else{return false;}}}
var addEventSimple=function(_h,_e,_mF,_uC){try{_h.addEventListener(_e,_mF,_uC);}catch(e){try{_h.attachEvent('on'+_e,_mF);}catch(e2){}}}
var removeEventSimple=function(_h,_e,_mF,_uC){try{_h.removeEventListener(_e,_mF,_uC);}catch(e){try{_h.detachEvent('on'+_e,_mF);}catch(e2){}}}
navigatorCheck=function(){this.browser=navigator.userAgent.toUpperCase();this.browserList={'IE':'MSIE','FF':'FIREFOX','O':'OPERA','S':'SAFARI','GC':'CHROME'};this.engineList={'WK':'WEBKIT','KH':'KHTML','TI':'TRIDENT','PR':'PRESTO','GE':'GECKO'};this.checkName=function($name){switch($name){case'IE':return _find(this.browser)(this.browserList[$name]);break;case'FF':return _find(this.browser)(this.browserList[$name]);break;case'O':return _find(this.browser)(this.browserList[$name]);break;case'S':return _find(this.browser)(this.browserList[$name]);break;case'GC':return _find(this.browser)(this.browserList[$name]);break;default:return false;}}
this.checkVersion=function($name,$number){switch($name){case'IE':return _find(this.browser)(this.browserList[$name]+' '+new String($number));break;case'FF':if(_find(this.browser)(this.browserList[$name]+'/'+new String($number))){return true;}else{return _find(this.browser)(this.browserList[$name]+' '+new String($number));}
break;case'O':return _find(this.browser)(this.browserList[$name]+'/'+new String($number));break;case'S':return _find(this.browser)(this.browserList[$name]+'/'+new String($number));break;case'GC':return _find(this.browser)(this.browserList[$name]+'/'+new String($number));break;default:return false;}}
this.checkEngine=function($name){switch($name){case'WK':return _find(this.browser)(this.engineList[$name]);break;case'KH':return _find(this.browser)(this.engineList[$name]);break;case'TI':return _find(this.browser)(this.engineList[$name]);break;case'PR':return _find(this.browser)(this.engineList[$name]);break;case'GE':return _find(this.browser)(this.engineList[$name]);break;default:return false;}}}
var nC=new navigatorCheck();var stopEventPropagation=(!nC.checkName('IE'))?(function(e){e.preventDefault();}):(function(e){return false;});stopOnSelect=function(){if(!nC.checkName('IE')){addEventSimple(document.body,'dblclick',stopEventPropagation,false);addEventSimple(document.body,'click',stopEventPropagation,false);addEventSimple(document.body,'mousedown',stopEventPropagation,false);}else{addEventSimple(document.body,'selectstart',stopEventPropagation,false);}}
startOnSelect=function(){if(!nC.checkName('IE')){removeEventSimple(document.body,'dblclick',stopEventPropagation,false);removeEventSimple(document.body,'click',stopEventPropagation,false);removeEventSimple(document.body,'mousedown',stopEventPropagation,false);}else{removeEventSimple(document.body,'selectstart',stopEventPropagation,false);}}
stopOnSelectElement=function(el){if(!nC.checkName('IE')){addEventSimple(el,'dblclick',stopEventPropagation,false);addEventSimple(el,'click',stopEventPropagation,false);addEventSimple(el,'mousedown',stopEventPropagation,false);}else{addEventSimple(el,'selectstart',stopEventPropagation,false);addEventSimple(el,'copy',stopEventPropagation,false);addEventSimple(el,'select',stopEventPropagation,false);addEventSimple(el,'dragstart',stopEventPropagation,false);addEventSimple(el,'drag',stopEventPropagation,false);addEventSimple(el,'contextmenu',stopEventPropagation,false);}}
startOnSelectElement=function(el){if(!nC.checkName('IE')){removeEventSimple(el,'dblclick',stopEventPropagation,false);removeEventSimple(el,'click',stopEventPropagation,false);removeEventSimple(el,'mousedown',stopEventPropagation,false);}else{removeEventSimple(el,'selectstart',stopEventPropagation,false);removeEventSimple(el,'copy',stopEventPropagation,false);removeEventSimple(el,'select',stopEventPropagation,false);removeEventSimple(el,'dragstart',stopEventPropagation,false);removeEventSimple(el,'drag',stopEventPropagation,false);removeEventSimple(el,'contextmenu',stopEventPropagation,false);}}
stopOnSelectElement2=function(el){addEventSimple(el,'selectstart',stopEventPropagation,false);addEventSimple(el,'copy',stopEventPropagation,false);addEventSimple(el,'select',stopEventPropagation,false);addEventSimple(el,'contextmenu',stopEventPropagation,false);addEventSimple(el,'drop',stopEventPropagation,false);}
startOnSelectElement2=function(el){removeEventSimple(el,'selectstart',stopEventPropagation,false);removeEventSimple(el,'copy',stopEventPropagation,false);removeEventSimple(el,'select',stopEventPropagation,false);removeEventSimple(el,'contextmenu',stopEventPropagation,false);removeEventSimple(el,'drop',stopEventPropagation,false);}
var ucwordsProperty=function(type){var res=new String;var i=1;var sT=type.split('-');res+=sT[0];while(sT[i]){for(var k=0;k<sT[i].length;k++){if(k==0){var tmp=new String(sT[i].charAt(k));res+=tmp.toUpperCase();}else{res+=sT[i].charAt(k);}}
i++;}
return res;}
var getCssProperty=function(node,type){if(node.style[type]){return node.style[type];}else if(document.defaultView&&document.defaultView.getComputedStyle){return document.defaultView.getComputedStyle(node,null).getPropertyValue(type);}else if(node.currentStyle){type=ucwordsProperty(type);return node.currentStyle[type];}else{return null;}}
var setCssOpacity=function(node,value){var opacity=typeof(value)!="undefined"?value:0.5;try{node.style.filter='alpha(opacity='+(opacity*100)+')';}catch(err){}finally{node.style.opacity=opacity;}}
var filertRemover=function(node){try{node.style.filter=undefined;}catch(e){}}
var getObjFromString=function(val,sV,objVal){var ret={};var splitRes=val.split(sV);var i=0;for(var v in objVal){ret[objVal[v]]={value:splitRes[i]?splitRes[i]:null};i++;}
return ret;}
var setSpecCssProperty=function(node,type,valInc){var retVal=parseInt(getCssProperty(node,type))+valInc;return retVal+'px';}
var setSpecCssProperty2=function(node,valInc){var retVal=parseInt(node)+valInc;return retVal+'px';}
VisualPresentation=function(){this.closeV=function(){var vP=$("v");vP.style.visibility="hidden";vP.style.top='-100000px';vP.innerHTML='';}
this.cursor=function(_n,_t){if(_t==1){_n.style.cursor='url(/style/images/icon_lupa.png),url(/style/images/icon_lupa.cur),pointer';}else{_n.style.cursor='auto';}}
this.imageVis=function(imgSrc){var ScrollTop=document.body.scrollTop;if(ScrollTop==0){if(window.pageYOffset)
ScrollTop=window.pageYOffset;else
ScrollTop=(document.body.parentElement)?document.body.parentElement.scrollTop:0;}
imageTitle=(imgSrc.title==undefined)?'':imgSrc.title;imgSrc=imgSrc.src.replace(/size=[-0-9]{1,3}/gi,"size=-1");var vP=$("v");vP.innerHTML='<div id="visualPresentationImg" onclick="visual.closeV();"></div>'+'<div id="imgVP" class="imgVP">'+'<div style="background:#FFF; padding:3px; border:1px solid #AAA;"><table style="width:32px;"><tr><td  style="width:100%;" align="center">'+'<img src="/style/images/ajax-loader.gif" alt="" style="border:1px solid silver;" /></td></tr>'+'</table></div>'+'</div><div style="position:absolute;top:-2000px;z-index:1;">'+'<div style="background:#FFF; padding:3px; border:1px solid #AAA;"><table><tr><td>'+'<img src="'+imgSrc+'" alt="" name="visImgPres" style="border:1px solid silver;" /></td></tr><tr><td align="right"><div id="imageTit" style="position:relative;z-index:1; float:left; text-align:left;">'+imageTitle+'</div>'+'<a style="width:20px; display:block; color:black; float:right; margin-left:10px;" align="center" href="javascript:visual.closeV();"><span>&nbsp;</span></a></td></tr></table></div></div>';vP.style.visibility="visible";vP.style.width='100%';vP.style.top=(ScrollTop+100)+'px';vP.style.left='0px';vP.style.height='100%';var w=document.body.clientWidth;var h=window.screen.height;vP.childNodes[1].style.left=new String(w/2-8)+'px';vP.childNodes[1].style.top='0px';switch(nC.checkName('IE')){case true:{var sP='alpha(opacity=80)';vP.childNodes[0].style.filter=sP;if(nC.checkVersion('IE',6)){visualPresentationImg.style.height=document.body.scrollHeight+'px';}
break;}
default:{vP.childNodes[0].style.opacity='0.8';}}
var imgPre=new Image();imgPre.src=imgSrc;upVisualPresentation=function(){if(imgPre.complete){var imgWidth=document.images['visImgPres'].width;var imageTit=$('imageTit');imageTit.style.width=(parseInt(imgWidth)-80)+'px';var imgTop=(w/2-imgWidth/2)>0?(w/2-imgWidth/2):0;vP.childNodes[1].style.left=imgTop+'px';vP.childNodes[1].innerHTML='';vP.childNodes[1].appendChild(vP.childNodes[2].childNodes[0]);return;}else{window.setTimeout('upVisualPresentation()',500);}}
window.setTimeout('upVisualPresentation()',500);}}
var visual=new VisualPresentation();window.onload=function(){var _footer=$('menubottom');var x=document.createElement('div');x.style.height='100%';x.style.position='fixed';x.style.zIndex='-1';x.style.width='10px';x.style.top='0px';x.style.left='0px';x.style.backgroundColor="#FFF";x.style.visibility='hidden';x.setAttribute('id','innerHeight1');document.body.appendChild(x);var _x=$('innerHeight1');if((window.innerHeight?window.innerHeight:_x.clientHeight)-document.body.clientHeight>0){var _w=((document.body.clientWidth-980)/2);_footer.style.position='fixed';_footer.style.bottom='0px';_footer.style.left=_w+'px';var x2=document.createElement('div');x2.style.height='100%';x2.style.position='fixed';x2.style.zIndex='-1';x2.style.width='980px';x2.style.top='0px';x2.style.left=(_w)+'px';x2.style.backgroundColor="#FFF";document.body.appendChild(x2);}}
