function onMouseOverColors() {
	if (this.className == "navButton") {
		this.style.backgroundColor = '#ffffff';
		this.firstChild.style.color = '#000000';
	} 
	else	{
		this.style.backgroundColor = '#000000';
		this.firstChild.style.color = '#ffffff';
	}
}
function onMouseOutColors() {
	if (this.className == "navButton") {
		this.style.backgroundColor = '#000000';
		this.firstChild.style.color = '#ffffff';
	} 
	else  {
		this.style.backgroundColor = '#ffffff';
		this.firstChild.style.color = '#000000';
	}
}
function followTheLink() {
	location.href = this.firstChild.href;
}
function displayPopUpworksMenu() {
	var element = document.getElementById('worksMenu');
	element.style.display = 'inline';
}
function onMouseOverWorksButton() {
	this.style.backgroundColor = '#ffffff';
	this.firstChild.style.color = '#000000';
	displayPopUpworksMenu();
}
function initializeEventHandlers() {
	var element;
	var tds = document.getElementsByTagName("TD");
	for (var i=0; i < tds.length; i++) {
		element = tds[i];
		if (element.className == "navButton" || element.className == "worksMenuChoiceWrapper") {
			element.onclick = followTheLink;
			element.onmouseout = onMouseOutColors;
			
			if (element.id == "WorksButton") {
				element.onmouseover = onMouseOverWorksButton;
			}
			else {
				element.onmouseover = onMouseOverColors;
			}
		}
	}
}
function hidePopUpworksMenu() {
	var element = document.getElementById('worksMenu');
	if (element) {
		element.style.display = 'none';
	}
}
document.onclick = hidePopUpworksMenu;