// Copyright Acro Media Inc. 1998-2003, www.acromediainc.com

window.onerror = null;
NS4 = (document.layers) ? true : false;
IE4 = (document.all) ? true : false;
NS3 = (!NS4 && !IE4 && document.images) ? true : false;
NS2 = (!NS4 && !IE4 && !NS3 && !document.images) ? true : false;
ver4 = (NS4 || IE4) ? 1 : 0;
IE5 = (document.all && document.getElementById) ? true : false;
NS6 = (!document.all && document.getElementById) ? true : false;
isMac = (navigator.appVersion.indexOf("Mac") != -1) ? true : false;
isGo = (NS4 || (IE4 && !isMac)) ? true : false;
isDom = (NS6 || IE5) ? true : false;

preloaded = 0;
var imageNames;
var imageOver;

doc = (NS4) ? "document[\"" : (isDom) ? "document.getElementById(\"" : "document.all[\"";
sty = (NS4) ? "\"]" : (isDom) ? "\").style" : "\"].style";

initialized = 0;
currentLay = "release";
	
if(NS4 || isDom || (IE4 && !isMac)){
	defaultStyle = "<STYLE TYPE='text/css'>"
	+ ".obj {"
	+ "position:absolute;"
	+ "visibility:hidden;"
	+ "width:10;"
	+ "height:10;"
	+ "}"
	+ "</STYLE>";

	document.write(defaultStyle);
}

function setupLayer(layName,layTop,layLeft,layWidth, layHeight,layIndex, invisible){
	if(initialized){
		layerObj = eval(doc + layName + sty);

		if (NS4) {
			layerObj.document.width = layWidth;
			layerObj.document.height = layHeight;
			layerObj.clip.right = layWidth;
			layerObj.clip.bottom = layHeight;
		}
		else{
			layerObj.width = layWidth;
			layerObj.height = layHeight;
			layerObj.clip = "rect(0 "+layWidth+" "+layHeight+" 0)";
		}
		layerObj.top = layTop;
		layerObj.left = layLeft;
		layerObj.zIndex = layIndex;
		if(!invisible){
			layerObj.visibility = "visible";
		}
	}
}

function showLayer(layName){
	hideLayer(currentLay);
	if(initialized){
		layerObj = eval(doc + layName + sty);
		layerObj.visibility = "visible";
		currentLay = layName;
	}
}

function hideLayer(layName){
	if(initialized){
		layerObj = eval(doc + layName + sty);
		layerObj.visibility = "hidden";
	}
}

