// *** popup window scripts *** //

function openResizableWindow(page) {
	window.open(page, "featureWindowResizable", "width=616,innerwidth=616,height=450,innerheight=450,toolbar=no,titlebar=no,menubar=no,location=no,scrollbars=yes,resizable=yes");
}

function openNonResizableWindow(page) {
	window.open(page, "featureWindowNonResizable", "width=600,innerwidth=600,height=450,innerheight=450,toolbar=no,titlebar=no,menubar=no,location=no,scrollbars=no,resizable=no");
}

function openMidSizeWindow(page) {
	window.open(page, "featureWindowMidSize", "width=600,innerwidth=600,height=488,innerheight=488,toolbar=no,titlebar=no,menubar=no,location=no,scrollbars=yes,resizable=yes");
}

// *** image preload script *** //

function MM_preloadImages() { //v3.0
	var d = document;
	if(d.images) {
		if(!d.MM_p) {
			d.MM_p=new Array();
		}
	}

	var i, j = d.MM_p.length, a = MM_preloadImages.arguments;
	for (i = 0; i < a.length; i++) {
		if (a[i].indexOf("#") != 0) {
			d.MM_p[j] = new Image; d.MM_p[j++].src = a[i];
		}
	}
}

// *** mouseover scripts *** //

function photosOver(figure) {
	document.photos.src = ("images/" + figure + ".button.photos.on.jpg");
}

function photosOut(figure) {
	document.photos.src = ("images/" + figure + ".button.photos.off.jpg");
}

function qtvrOver(figure) {
	document.qtvr.src = ("images/" + figure + ".button.qtvr.on.jpg");
}

function qtvrOut(figure) {
	document.qtvr.src = ("images/" + figure + ".button.qtvr.off.jpg");
}

function packagingOver(figure) {
	document.packaging.src = ("images/" + figure + ".button.packaging.on.jpg");
}

function packagingOut(figure) {
	document.packaging.src = ("images/" + figure + ".button.packaging.off.jpg");
}

function specsOver(figure) {
	document.specs.src = ("images/" + figure + ".button.specs.on.jpg");
}

function specsOut(figure) {
	document.specs.src = ("images/" + figure + ".button.specs.off.jpg");
}

function referenceOver(figure) {
	document.reference.src = ("images/" + figure + ".button.reference.on.jpg");
}

function referenceOut(figure) {
	document.reference.src = ("images/" + figure + ".button.reference.off.jpg");
}

function wallpaperOver(figure) {
	document.wallpaper.src = ("images/" + figure + ".button.wallpaper.on.jpg");
}

function wallpaperOut(figure) {
	document.wallpaper.src = ("images/" + figure + ".button.wallpaper.off.jpg");
}

function hicksOver(figure) {
	document.hicks.src = ("images/" + figure + ".button.hicks.on.jpg");
}

function hicksOut(figure) {
	document.hicks.src = ("images/" + figure + ".button.hicks.off.jpg");
}

function robocopOver(figure) {
	document.robocop.src = ("images/" + figure + ".button.robocop.on.jpg");
}

function robocopOut(figure) {
	document.robocop.src = ("images/" + figure + ".button.robocop.off.jpg");
}

function leatherfaceOver(figure) {
	document.leatherface.src = ("images/" + figure + ".button.leatherface.on.jpg");
}

function leatherfaceOut(figure) {
	document.leatherface.src = ("images/" + figure + ".button.leatherface.off.jpg");
}

function erinOver(figure) {
	document.erin.src = ("images/" + figure + ".button.erin.on.jpg");
}

function erinOut(figure) {
	document.erin.src = ("images/" + figure + ".button.erin.off.jpg");
}

function hoytOver(figure) {
	document.hoyt.src = ("images/" + figure + ".button.hoyt.on.jpg");
}

function hoytOut(figure) {
	document.hoyt.src = ("images/" + figure + ".button.hoyt.off.jpg");
}

function montyOver(figure) {
	document.monty.src = ("images/" + figure + ".button.monty.on.jpg");
}

function montyOut(figure) {
	document.monty.src = ("images/" + figure + ".button.monty.off.jpg");
}

function twelveInchLeatherfaceOver(figure) {
	document.twelveinchleatherface.src = ("images/" + figure + ".button.12leatherface.on.jpg");
}

function twelveInchLeatherfaceOut(figure) {
	document.twelveinchleatherface.src = ("images/" + figure + ".button.12leatherface.off.jpg");
}

function storesOver(figure) {
	document.stores.src = ("images/" + figure + ".button.stores.on.jpg");
}

function storesOut(figure) {
	document.stores.src = ("images/" + figure + ".button.stores.off.jpg");
}

// *** window resize script *** //

var isNav, isIE;

if (parseInt(navigator.appVersion.charAt(0)) >= 4) {
	isNav = (navigator.appName == "Netscape") ? 1 : 0;
	isIE = (navigator.appName.indexOf("Microsoft") != -1) ? 1 : 0;
}

function fitWindowSize() {
if (isNav) {
	}

if (isIE) {
	var screen_width = screen.width;
	var screen_height = screen.height;

	width = 630;

	if (screen_height > 480) { height = 600; }
	if (screen_height > 600) { height = 768; }
	if (screen_height > 768) { height = 930; }

	window.resizeTo(width, height);
	}
}

function fitWindowSize2() {
if (isNav) {
	}

if (isIE) {
	var screen_width = screen.width;
	var screen_height = screen.height;

	width = 630;

	if (screen_height > 480) { height = 600; }
	if (screen_height > 600) { height = 768; }
	if (screen_height > 768) { height = 770; }

	window.resizeTo(width, height);
	}
}

