var vastusFrame=null;function mapClick(D,A,F,B,E,C){if(isMap||C!="Info"){return }if(!vastusFrame){vastusFrame=document.getElementById("vastus")}if(D=="EPSG:3301"){vastusFrame.src="vorm?xBTN.txtXY="+F+":"+A}else{vastusFrame.src="vorm?xBTN.txtXY="+A+":"+F}}var isMap=-1;var appRedy=0;var tryCnt=0;var timeBo=0;var mcmmnd;function setPos(tn,box){if(timeBo){clearTimeout(timeBo)}if(!appRedy){tryCnt++;if(tryCnt<10){timeBo=setTimeout("setPos('"+tn+"','"+box+"')",300)}return }timeBo=tryCnt=0;if(!mcmmnd){mcmmnd=document.getElementById("cmmnd").value}dogis_setFlashParams(eval(mcmmnd+tn+"'},{'bbox':'"+box+"'}]"))}function appReady(A){appRedy=A;if(A){mapHolder2.style.border="0"}}var mHeight=0;var mapStep=1600;var mapHeight=mapStep;var mapHolder=null;var mapHolder2=null;var lasttn,lastn,lastbox;function openMap(A,C,B){if(!mapHolder){mapHolder=document.getElementById("kaart");mapHolder2=document.getElementById("kaart2")}lasttn=A;lastn=C;lastbox=B;if(isMap==-1){isMap=1;setTimeout("showMap()",10)}if(isMap){mapHolder.src="map?n="+C+"&ky="+A}else{setPos(A,B)}}var xgisurl;var xgiscmm;function openXgis(tn){if(!xgisurl){xgisurl=document.getElementById("xgis").value}if(!xgiscmm){xgiscmm=document.getElementById("cmmnd2").value}var sObj=eval(xgiscmm+tn+"'}]");var arg=new Array();for(var i=0;i<sObj.length;i++){for(var par in sObj[i]){arg.push(new Array(par,sObj[i][par]))}}parent.HooK_Sender(xgisurl+tn,"dogisgis","toolbar=no,menubar=no,location=yes,scrollbars=no,resizable=yes",null,arg)}function showMap(){if(!mHeight){mHeight=parseInt(document.getElementById("mheight").value)}if(mapHolder.style.display){mapHolder.style.display=""}mapHeight+=mapStep;if(mapHeight>mHeight){mapHeight=mHeight}mapHolder.style.height=mapHeight+"px";if(mapHeight==mHeight){setTimeout("doResize();",10)}else{setTimeout("showMap()",1)}}function hideMap(){lasttn="";if(isMap!=1){return }mapHeight-=mapStep;if(mapHeight<=mapStep){isMap=-1;mapHolder.style.display="none";mapHeight=mapStep;setTimeout("doResize();",10)}else{mapHolder.style.height=mapHeight+"px";setTimeout("hideMap()",1)}}var xhttp=null;function setApp(A,B){mapHolder.style.display="none";isMap=0;if(!document.dogis){try{xhttp=new XMLHttpRequest()}catch(C){try{xhttp=new ActiveXObject("Msxml2.XMLHTTP")}catch(C){return }}xhttp.open("GET",A+"&onlyMap=ajax&bbox="+B,true);xhttp.onreadystatechange=drawFlash;xhttp.send(null);mapHolder2.style.display=""}else{standBy(1);setPos(A.substr(A.lastIndexOf("=")+1),B)}setTimeout("doResize();",10)}function drawFlash(){if(xhttp.readyState!=4){return }if(xhttp.status==200){try{mapHolder2.innerHTML=eval(xhttp.responseText)}catch(e){alert(getXMLText(xhttp.responseXML.documentElement))}}else{alert(xhttp.statusText)}}function getXMLText(A){if(typeof XMLSerializer!="undefined"){return(new XMLSerializer()).serializeToString(A)}return A.text}function custombuttonClick(A){if(A=="customTagasiBtn"){isMap=-1;standBy(0);if(lasttn){openMap(lasttn,lastn,lastbox)}}}var scr_form=null;var scr_pos=0;var scr_mode;function scForm(){if(!scr_form){scr_form=document.getElementById("xforms");if(typeof (window.pageYOffset)=="number"){scr_mode=1}else{if(typeof (document.documentElement.scrollTop)=="number"){scr_mode=2}else{if(typeof (document.body.scrollTop)=="number"){scr_mode=3}}}}var A=0;if(scr_mode==1){A=top.pageYOffset}else{if(scr_mode==2){A=top.document.documentElement.scrollTop}else{if(scr_mode==3){A=top.document.body.scrollTop}}}A=(A<=100)?0:A-100;if(A!=scr_pos){scr_pos=A;scr_form.style.top=A+50+"px"}}setInterval("scForm()",200);function toggleWidth(){}var xSet=null;function setHeight(A){if(!xSet){xSet=document.getElementById("vastus")}if(A>30){xSet.style.height=A+"px"}else{xSet.style.height="30px"}doResize()};
