// JavaScript Document
var url = document.location.toString();

var showMenu = true;
try {
			
	showMenu = overrideShowMenu;
} catch (exception) {
	
}

if (showMenu) {
	if(top.document.location.toString().indexOf("ice/ide.html") >= 0){	
		document.write("<i>The menu below is automatically generated based on the menu to the left. Click the \"Link to Menu File\" link above the menu to edit it.</i>");
	}


	var thisPage = url.substr(url.lastIndexOf("/") + 1);
	var links = $("td[id='leftCol'] a[href='" + thisPage + "'] ~ ul");
	var categoryTitle = $("*[class='classTitle']");
	
	
	if (links.length > 0) {
		document.write ("<h5>All " + categoryTitle[0].innerText + "</h5>");
		document.write (links[0].innerHTML)	;
	} else {
		//find the ul that contains this a
		var thisLink = 	$("td[id='leftCol'] a[href='" + thisPage +"']")[0];
		if (thisLink) {
			var ulTag = $(thisLink).closest("ul")[0];
			var htmlContent = ulTag.innerHTML;
			var menuTitle = "Related Classes and Groups";
			try {
			
				menuTitle = relatedItemsMenuTitle;
			} catch (exception) {
				}
			document.write ("<h5>" + menuTitle + "</h5>");
			document.write(htmlContent);
		}
	}
}