dot_on = new Image (11,19);
dot_on.src = "/img/marker_up.gif";
dot_off = new Image (11,19);
dot_off.src = "/img/marker.gif";

sherdart_on = new Image (88,31);
sherdart_on.src = "/img/sherdart_up.gif";
sherdart_off = new Image (88,31);
sherdart_off.src = "/img/sherdart.gif";

function dotOn(dotName) {
	document.images["dot_" + dotName].src = dot_on.src;
}

function dotOff(dotName) {
	document.images["dot_" + dotName].src = dot_off.src;
}

function picOn(graphName) {
	graph = eval(graphName + "_on.src");
	document.images[graphName].src = graph;
}
function picOff(graphName) {
	graph = eval(graphName + "_off.src");
	document.images[graphName].src = graph;
}

function getNav() {
	N = window.navigator.appName.substring(0,8);
	if(N == "Microsof") {
		return 'I';
	} else {
		return 'N';
	}
}

function getPageHeight() {
	if(getNav() == 'I') {
		h = document.body.clientHeight -3;
	}
	if(getNav() == 'N') {
		h = document.body.scrollHeight;
	}
	return(h);
}

function glueBottom() {
	contentHeightL = 581;
//	contentHeightL = 441;
	contentHeightR = 70;
	
	pHeight = getPageHeight();
	offL = document.vMarkerLeft.offsetTop;
	offR = document.vMarkerRight.offsetTop;
	if ((offL+contentHeightL) > (offR+contentHeightR)) {
		max = offL+contentHeightL;
		type = 1;
	} else {
		max = offR+contentHeightR;
		type = 2;
	}
	if (max < pHeight) {
		offsetL = pHeight-offL-contentHeightL;
		offsetR = pHeight-offR-contentHeightR;
	} else {
		if (type == 1) {
			offsetL = 1;
			offsetR = max-offR-contentHeightR;
		}
		if (type == 2) {
			offsetL = max-offL-contentHeightR;
			offsetR = 1;
		}
	}
	document.vSpacer.height = offsetL;
	document.vMarkerRight.height = offsetR;
}

function glueBottomInt() {
	pHeight = getPageHeight();
	offL = document.vMarker.offsetTop;
	offR = document.vMarkerRight.offsetTop;
	if ((offL+208) > (offR+45)) {
		max = offL+208;
		type = 1;
	} else {
		max = offR+45;
		type = 2;
	}
	offset = 1;
	if (max < pHeight) {
		offset = pHeight - 400;
	} else {
		if (type == 2) {
			offset = max - 400;
			if (getNav() == 'I') offset += 2;
		}
	}
	document.vSpacer.height = offset;
}
