function navMO(e) {
	try {
		indent = e.indent;
		currentNavPath = '';
		if (e.indent > 0) {
			for (i=parseInt(e.navIndex); i >= 0; i--) {				
				if (document.all('nav' + i).indent < indent) {
					currentNavPath = ',' + i + currentNavPath;
					indent = document.all('nav' + i).indent;
				}
			}
			currentNavPath += ',' + e.navIndex + ',';
		} else {
			currentNavPath = ',' + e.navIndex + ',';
		}
		
		for (var i=0; i < totalNavItems; i++) {
			if (currentNavPath.indexOf(',' + i + ',') < 0) {
				if (document.all('navItem'+i)) {
					document.all('navItem'+i).style.display = 'none';
				}
			}
		}
	
		e.className = 'navDivOn';
		if (document.all('navItem' + e.navIndex)) {
			document.all('navItem' + e.navIndex).style.display = 'block';
		}

	} catch (e) {
		alert('Error: ' + e.description);
	}
}

function navMOut(e) {
	try {
		e.className = 'navDiv';		
		currentNavPath = '';
		clearInterval(hideNavInterval);
		hideNavInterval = setInterval('hideNav();', 100);
	} catch (e) {
		alert(e.description);
	}
}

function navMClick(e) {
	try {
		window.location = e.href;
	} catch (e) {
		alert(e.description);
	}
}

function hideNav() {
	clearInterval(hideNavInterval);
	
	for (var i=0; i < totalNavItems; i++) {
		if (currentNavPath.indexOf(',' + i + ',') < 0) {
			if (document.all('navItem'+i)) {
				document.all('navItem'+i).style.display = 'none';
				document.all('navItem'+i).innerHTML = document.all('navItem'+i).innerHTML;
			}
		}
	}
}

currentNavPath = '';
hideNavInterval = 0;

