// JavaScript Document

IMG_ROOT = "/images/";

function currentPage(menuObj)
{
	btnImage = new Image();
	var imageObj = new Image();
	 
	
	btnImage = document.getElementById(menuObj);		
	btnImage.src = IMG_ROOT+"/btn_"+menuObj+"_on.gif";
	
	
}

function btnMagic(obj)
{
	var imgObj = new Image();
	var isCurrentPage = skipMagic(obj);
	
	function btnMagicBack()
	{
		obj.src = IMG_ROOT+"/btn_"+obj.id+".gif";
	}

	if(isCurrentPage == false)
	{
		obj.src = IMG_ROOT+"/btn_"+obj.id+"_on.gif";		
		obj.onmouseout = btnMagicBack;		
	}
	
}

function skipMagic(obj)
{
	var img = new Image();
	var img_root = new Array();
	img_root = obj.src.split("_");
	var underscoreAmount = img_root.length-1;

	if (img_root[underscoreAmount] == "on.gif")
		return true;
	else
		return false;	
}


function currentInnerPage(innerPage)
{
	page = document.getElementById(innerPage);
	page.className = "rhsLink_on";
}


function downloadPPT(obj)
{
	fullSizeImage = "pptSlides/"+obj+".ppt";
	window.location = fullSizeImage;
}

function highlightThumb(obj)
{
	obj.style.border="2px solid #b9b6b6";
	obj.onmouseout = unHighLight;
	
	function unHighLight()
	{
		obj.style.border="2px solid #DEDEDE";
	}
}
