/*  

	So here is the javascript file. Make sure that you add any of the images to the list down 

	below so they can preload and make sure that you have onload="preloadImages();" in the 

	<body> tag of each html page.

	

	So these are just the images to preload for the nav. If you want to change another image on 

	the site, add it to here and name it like this :

	blah_over = newImage("images/whatever.xxx");

	

	Then on the area coords in the image map it already has 

	onmouseover="changeImages('navmap', 'images/nav_news.jpg');" onmouseout="changeImages('navmap', 'images/nav_default.jpg');"

	

	All you need to do is change the first thing "navmap" to the id of the image, and then the second thing to

	the image you are loading...

	

	So add an id="whatever" to whatever image, and then add this function to the onmouseover or onmouseout of the area coords

	

	changeImages('imgname', 'path to image');

	

	you can do multiples,

	

	onmouseover="changeImages('imgname', 'path to image');changeImages('imgname', 'path to image');changeImages('imgname', 'path to image');"

	just separate them by ;

	

	That's all.

*/





function newImage(arg) {

if (document.images) {

	rslt = new Image();

	rslt.src = arg;

	return rslt;

}

}



function changeImages() {

if (document.images && (preloadFlag == true)) {

	for (var i=0; i<changeImages.arguments.length; i+=2) {

		document.images[changeImages.arguments[i]].src = changeImages.arguments[i+1];

	}

}

}



var preloadFlag = false;

function preloadImages() {

if (document.images) {

	foxg_over = newImage("images/foxglow.jpg");

	foxh_over = newImage("images/foxhead.jpg");

	cont_over = newImage("images/nav_contact.jpg");

	deal_over = newImage("images/nav_dealer.jpg");

	defa_over = newImage("images/nav_default.jpg");

	diff_over = newImage("images/nav_difference.jpg");

	live_over = newImage("images/nav_livehelp.jpg");

	news_over = newImage("images/nav_news.jpg");

	prod_over = newImage("images/nav_products.jpg");

	tour_over = newImage("images/nav_tour.jpg");

	dcon_over = newImage("images/drum_contact.jpg");

	ddea_over = newImage("images/drum_dealer.jpg");

	ddef_over = newImage("images/drum_default.jpg");

	ddif_over = newImage("images/drum_difference.jpg");

	dliv_over = newImage("images/drum_livehelp.jpg");

	dnew_over = newImage("images/drum_news.jpg");

	dpro_over = newImage("images/drum_products.jpg");

	dtou_over = newImage("images/drum_tour.jpg");

	preloadFlag = true;

}

}