// SHOW / HIDE CONTENT FUNCTION



function HideContent(d) {document.getElementById(d).style.display = "none";}
function ShowContent(d) {document.getElementById(d).style.display = "";}
function ReverseContentDisplay(d)
{if(document.getElementById(d).style.display == "none") { document.getElementById(d).style.display = "";
}else { document.getElementById(d).style.display = "none"; }}

// ABRE DIV
function OpenDesc(text) {
	if (text != formulario)
    formulario.style.display = "none";

	if (text.style.display =="") {
    text.style.display = "none";
	}
	else {
	text.style.display="";
	}
}
// ABRE DIV 2
function OpenDescInterno(text) {
  if (text.style.display =="") {
    text.style.display = "none";
  }
  else {text.style.display="";
  }
}

// POPUP
function abre(url,janela,larg,alt,scroll_bar,pos1,pos2){  
	window.open(url,janela,'toolbar=no,location=no,directories=no,status=no,menubar=no,scrollbars='+scroll_bar+',resizable=no,copyhistory=no,top='+pos1+',left='+pos2+',screenY='+pos1+',screenX='+pos2+',width='+larg+',height='+alt);
}

function MM_openBrWindow(theURL,winName,features) { //v2.0
  window.open(theURL,winName,features);
}

// Impressão
	
var da = (document.all) ? 1 : 0;
var pr = (window.print) ? 1 : 0;
var mac = (navigator.userAgent.indexOf("Mac") != -1); 	

function printPage()
{
  if (pr) // NS4, IE5
    window.print()
  else if (da && !mac) // IE4 (Windows)
    vbPrintPage()
  else // other browsers
    alert("Seu navegador não suporta a função para impressão. Tecle CTRL + P para imprimir a página.");
  return false;
}


//SELECT
startList = function() {
	if (document.all&&document.getElementById) {
		navRoot = document.getElementById("nav");
		if(document.getElementById("nav")) {
			for (i=0; i<navRoot.childNodes.length; i++) {
				node = navRoot.childNodes[i];
				if (node.nodeName=="LI") {
					node.onmouseover=function() {
						this.className+=" over";
					}
					node.onmouseout=function() {
						this.className=this.className.replace(" over", "");
					}
				}
			}
		}
	}
}
window.onload=startList;
