// JavaScript Document
function __fontsize() {
	__tamanhofonte=__tamanhofonte-1;
	if (__tamanhofonte<1) { __tamanhofonte=1; }
	fontresize();
}
function fontsize__() {
	__tamanhofonte=__tamanhofonte+1;
	if (__tamanhofonte>5) { __tamanhofonte=5; }
	fontresize();
}
function fontresize() {
	var __conteudo = document.getElementById("__conteudo");
	__conteudo.setAttribute("className","tamanho-fonte"+__tamanhofonte);
	__conteudo.setAttribute("class","tamanho-fonte"+__tamanhofonte);
	try
	{
		__conteudo = document.getElementById("__pp");
		__conteudo.setAttribute("className","tamanho-fonte"+__tamanhofonte);
		__conteudo.setAttribute("class","tamanho-fonte"+__tamanhofonte);
	} catch(e) {
	}
}

function getPageSize() {
	var windowWidth, windowHeight;
	if (self.innerHeight) {
		windowWidth = self.innerWidth;
		windowHeight = self.innerHeight;
	} else if (document.documentElement && document.documentElement.clientHeight) {
		windowWidth = document.documentElement.clientWidth;
		windowHeight = document.documentElement.clientHeight;
	} else if (document.body) {
		windowWidth = document.body.clientWidth;
		windowHeight = document.body.clientHeight;
	}	
	arrayPageSize = {windowWidth:windowWidth,windowHeight:windowHeight}
	return arrayPageSize;
}
function getPageScroll(){
	var yScroll;
	if (self.pageYOffset) yScroll = self.pageYOffset;
	else if (document.documentElement && document.documentElement.scrollTop) yScroll = document.documentElement.scrollTop;
	else if (document.body) yScroll = document.body.scrollTop;
	arrayPageScroll = {yScroll:yScroll};
	return arrayPageScroll;
}
function __zoom() {
	var e = document.getElementById("image__");
	var __w = document.getElementById("__imagem_noticia");
	var pageSize = getPageSize();
	var __document_body = document.getElementsByTagName('body')[0];
	if (__zoom_open==false) {
		__zoom_open=true;
		var __box__maskdark=document.createElement("div");
		__box__maskdark.setAttribute("id","__imagem_maskdark");
		__box__maskdark.setAttribute("className","zoom_maskdark__");
		__box__maskdark.setAttribute("class","zoom_maskdark__");
		//__box__maskdark.style.width=pageSize.windowWidth+"px";
		//__box__maskdark.style.height=pageSize.windowHeight+"px";
		__box__maskdark.style.width="100%";
		__box__maskdark.style.height=pageSize.windowHeight+"px";
		__document_body.appendChild(__box__maskdark);

		var __ct__imagem=document.getElementById("__imagem_container");
		__ct__imagem.setAttribute("className","imagem__zoom");
		__ct__imagem.setAttribute("class","imagem__zoom");
		//__ct__imagem.style.width=pageSize.windowWidth+"px";
		//__ct__imagem.style.height=pageSize.windowHeight+"px";
		__ct__imagem.style.width="100%";
		__ct__imagem.style.height=pageSize.windowHeight+"px";
		__document_body.appendChild(__ct__imagem);
		e.src=e.getAttribute("longdesc");

		var __bt__imagem=document.getElementById("bnt__openclose__");
		__bt__imagem.src="/_estrutura/img/btn/fechar.gif";

		__moveWindow();


		var __publ__bann=document.getElementsByTagName("div");
		for(var i=0;i<__publ__bann.length;i++) {
			if (__publ__bann[i].className == 'banner') {
				__publ__bann[i].style.display="none";
			}
		}

	} else {
		__zoom_open=false;
		var __box__maskdark=document.getElementById("__imagem_maskdark");
		__document_body.removeChild(__box__maskdark);
		var __bt__imagem=document.getElementById("bnt__openclose__");
		__bt__imagem.src="/_estrutura/img/btn/ampliar.gif";
		var __ct__imagem=document.getElementById("__imagem_container");
		__ct__imagem.setAttribute("className","imagem_container__");
		__ct__imagem.setAttribute("class","imagem_container__");
		__ct__imagem.removeAttribute("style");
		__w.appendChild(__ct__imagem);
		e.src=e.getAttribute("lowsrc");

		var __publ__bann=document.getElementsByTagName("div");
		for(var i=0;i<__publ__bann.length;i++) {
			if (__publ__bann[i].className == 'banner') {
				__publ__bann[i].style.display="block";
			}
		}

	}
}
window.onscroll = function (e) {
	if (__zoom_open==true) {
		__moveWindow();
	}
}
function __moveWindow() {
	var pageScroll = getPageScroll();
	var __ct__imagem=document.getElementById("__imagem_container");
	var __bk__imagem=document.getElementById("__imagem_maskdark");
	__ct__imagem.style.top=pageScroll.yScroll+"px";
	__bk__imagem.style.top=pageScroll.yScroll+"px";
}

function EnviarBot(form) {
	if (form.nomeApelido.value=="") {
		alert( "Campo NOME est&aacute; vazio." );
		form.nomeApelido.focus();
		return false;
	} else if (form.emailPessoa.value=="") {
		alert( "Campo E-MAIL est&aacute; vazio." );
		form.emailPessoa.focus();
		return false;
	} else if(form.emailPessoa.value.search("@")== -1){
		alert("Insira um E-MAIL v&aacute;lido.");
		form.emailPessoa.focus();
		return false;
	} else if(form.assunto.value=="") {
		alert("Campo ASSUNTO est&aacute; vazio.");
		form.assunto.focus();
		return false;
	} else if (form.coment.value=="") {
		alert("Seu COMENT&Aacute;RIO est&aacute; vazio.");
		form.coment.focus();
		return false;
	} else if (form.coment.value.length > 2000) {
		alert("Voc&ecirc; excedeu o limite de caracteres.");
		form.coment.focus();
		return false;
	} else {
		form.texto.value = form.nomeApelido.value + "|" + form.emailPessoa.value + "|" + form.assunto.value + "|" + form.coment.value;
		form.submit();
 	}
}
function Contar(Campo,Qtdname){
document.getElementById(Qtdname).innerText = 1800-Campo.value.length
if((1800-Campo.value.length)==0)
alert('Atencao, voc atingiu o limite mximo de caracteres!');
}