
void function menu_focus(menuA, classNameA) {

	if (menuA == null)
		return;

	menuA.className = classNameA;

	return;
}

void function menu_blur(menuA, classNameA) {

	if (menuA == null)
		return;

	menuA.className = classNameA;

	return;
}

void function menu_select(cellIDA, classNameA) {

var cellP = null;

	cellP = getElementByID(cellIDA);
	if (cellP == null)
		return;

	cellP.className = classNameA;
	return;
}

function menu_deselectAll(classNameA) {

var cellP = null;
var i = 1;

	cellP = getElementByID('menu' + i);
	while (cellP != null) {
		cellP.className = classNameA;
		i++;
		cellP = getElementByID('menu' + i);
	}

	return;
}

// returns the document element with the given ID
function getElementByID(id) {

var i = 0;

	for (i=0; i<document.all.length; i++) {
		if (document.all[i].id == id)
			return document.all[i];
	}

	return null;
}

