//MENU POZADI
function chbg(id,cl) {
	document.getElementById(id).className = cl;
}

//MENU 
if (navigator.appName == "Netscape") {
	layerRef="document.layers";
  	styleSwitch="";
    } else {
    	layerRef="document.all";
    	styleSwitch=".style";
    }

function hiL(layerName) {
	eval(layerRef+'["'+layerName+'"]'+styleSwitch+'.visibility="hidden"');
}

function hL(layerName) {
     document.getElementById(layerName).style.visibility = 'hidden';
}

function shL(layerName) {
     eval(layerRef+'["'+layerName+'"]'+styleSwitch+'.visibility="visible"');
}																		   		

function sL(layerName) {
     document.getElementById(layerName).style.visibility = 'visible';
}		

function ssL(layerName) {
	 if (flag) {
	 hideActiveMenus();
     document.getElementById(layerName).style.visibility = 'visible';
	 }
}		

flag = false;
fwHideMenuTimer = null;

function FW_clearTimeout()
{
	if (fwHideMenuTimer) clearTimeout(fwHideMenuTimer);
	fwHideMenuTimer = null;
	fwDHFlag = false;
}

function FW_startTimeout()
{
	fwStart = new Date();
	fwDHFlag = true;
	fwHideMenuTimer = setTimeout("fwDoHide()", 1000);
}

function fwDoHide()
{
	if (!fwDHFlag) return;
	var elapsed = new Date() - fwStart;
	if (elapsed < 1000) {
		fwHideMenuTimer = setTimeout("fwDoHide()", 1100-elapsed);
		return;
	}
	fwDHFlag = false;
	flag = false;
	hideActiveMenus();
}



//OKNO
function okno(zdroj) {
   aPopUp = window.open(zdroj,'popup','menubar=yes,toolbar=no,location=no,directories=no,status=no,scrollbars=yes,resizable=yes,copyhistory=no,top=10,left=10,width=780,height=450');
}

//OKNO2
function okinko(zdroj) {
   bpopup = window.open(zdroj,'main','');
}

//OKNO POZOR
function pozor(zdroj) {
   aPopUp = window.open(zdroj,'popup','menubar=no,toolbar=no,location=no,directories=no,status=no,scrollbars=no,resizable=no,copyhistory=no,top=10,left=10,width=200,height=200');
}

//javascript:window.opener.location.reload();self.close()
