try{
	document.execCommand("BackgroundImageCache",false,true);
}
catch(e){};


function ge(n){
	return document.getElementById(n);
}
var getOffset = function(o){
	for(var r = {x: o.offsetLeft, y: o.offsetTop, h: o.offsetHeight, w: o.offsetWidth}; o = o.offsetParent; r.x += o.offsetLeft, r.y += o.offsetTop);
	return r;
}
function getElementsByClassName(name, parent){
	for(var o = [], n = new RegExp("\\b" + name.replace(/([(){}|*+?.,^$\[\]\\])/g, "\\\$1") + "\\b"), l = (parent || document).getElementsByTagName("*"), i = l.length; i--;)
		n.test(l[i].className) && (o[o.length] = l[i]);
	return o;
}
function getElementsInClassName(name, elements){
	for(var o = [], n = new RegExp("\\b" + name.replace(/([(){}|*+?.,^$\[\]\\])/g, "\\\$1") + "\\b"), l = elements, i = l.length; i--;)
		n.test(l[i].className) && (o[o.length] = l[i]);
	return o;
}
function findAncestor(o, tag, limit){
	for(tag = tag.toLowerCase(); o = o.parentNode;)
		if(o.tagName && o.tagName.toLowerCase() == tag)
			return o;
		else if(limit && o == limit)
			return null;
	return null;
}
function findNext(o, tag, limit){
	for(tag = tag.toLowerCase(); o = o.nextSibling;)
		if(o.tagName && o.tagName.toLowerCase() == tag)
			return o;
		else if(limit && o == limit)
			return null;
	return null;
}
function findPrevious(o, tag, limit){
	for(tag = tag.toLowerCase(); o = o.previousSibling;)
		if(o.tagName && o.tagName.toLowerCase() == tag)
			return o;
		else if(limit && o == limit)
			return null;
	return null;
}


function showHide(o) {
	var obj = document.getElementById(o), d = obj.style.display;
	obj.style.display = d == "none" || !d ? "block" : "none";
}
function showLightBox(id, className){
	var o = ge(id);
	if(!window.BOX){
		BOX = new LightBox();
		addEvent(document, "keydown", function(e){
			if(BOX.locked && e.key == 27)
				hideLightBox();
		});
	}
	if(BOX.locked)
		return;
	
	BOX.setClassName(className ? className : "LightBox");
	BOX.setTopMost();
	var original = o.parentNode, node;
	original.style.display = "block";
	BOX.box.innerHTML = "";
	node = BOX.box.appendChild(o);
	hideLightBox = function(){
		original.appendChild(node);
		BOX.hide();
	}
	BOX.show();
}
function hideLightBox(){
	if(window.BOX){
		BOX.hide();
	}
}

function fontRezise(a, padrao, min, max) {
	var min = min || 8, max = max || 17, d = padrao || 14;
	var o = getElementsByClassName('fontSize');
	for(i = o.length; i--;) {
		for(var j = o[i].getElementsByTagName("p"), c = j.length; c--;) {
			var e = j[c], s = e.style.fontSize ? +e.style.fontSize.replace("px","") : d;
			a && (s < max) ? s++ : !a && (s > min && s--);
			e.style.fontSize = s + "px";
		}
	}
	window.SimpleScroll && window.SimpleScroll.refresh();
}


function openFlash (srcFlash, widthFlash, heightFlash) {
	var strSwf;
	var final;
	final = srcFlash;
	
	strSwf = "<object align=\"middle\" classid=\"clsid:d27cdb6e-ae6d-11cf-96b8-444553540000\" codebase=\"http://download.macromedia.com/pub/shockwave/cabs/flash/s.cab#version=10,0,0,0\" width="+widthFlash+" height="+heightFlash+">";
	strSwf += "<param name=\"movie\" value=\""+final+"\">";
	strSwf += "<param name=\"allowScriptAccess\" value=\"sameDomain\">";
	strSwf += "<param name=\"allowFullScreen\" value=\"false\">";
	strSwf += "<param name=\"scale\" value=\"noscale\">";
	strSwf += "<param name=\"quality\" value=\"high\">";
	strSwf += "<param name=\"WMode\" value=\"Transparent\">";
	strSwf += "<embed align=\"middle\" src=\""+final+"\" width="+widthFlash+" height="+heightFlash+" scale=\"noscale\" wmode=\"transparent\" pluginspage=\"http://www.adobe.com/go/getflashplayer\"></embed>";
	strSwf += "</object>";
	
	this.document.write(strSwf);
}