// *** popup window scripts *** //

function openAutoResizingWindow(page) {
	window.open(page, "featureAutoResizingWindow", "width=620,innerwidth=620,height=450,innerheight=450,toolbar=no,titlebar=no,menubar=no,location=no,scrollbars=yes,resizable=yes");
}

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 = 823; }

	window.resizeTo(width, height);
	}
}

// *** 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];
		}
	}
}

function cindyOver() { document.cindy.src = ("images/button.cindy.on.jpg"); }
function cindyOut() { document.cindy.src = ("images/button.cindy.off.jpg"); }

function reindeerOver() { document.reindeer.src = ("images/button.reindeer.on.jpg"); }
function reindeerOut() { document.reindeer.src = ("images/button.reindeer.off.jpg"); }

function meanoneOver() { document.meanone.src = ("images/button.meanone.on.jpg"); }
function meanoneOut() { document.meanone.src = ("images/button.meanone.off.jpg"); }

function crumpitOver() { document.crumpit.src = ("images/button.crumpit.on.jpg"); }
function crumpitOut() { document.crumpit.src = ("images/button.crumpit.off.jpg"); }

function twosizesOver() { document.twosizes.src = ("images/button.twosizes.on.jpg"); }
function twosizesOut() { document.twosizes.src = ("images/button.twosizes.off.jpg"); }
