<!--
main_addEvent(window, "load", main_init, true);

function main_addEvent(obj, evType, fn, useCapture){
	if (obj.addEventListener){
		obj.addEventListener(evType, fn, useCapture);
		return true;
	} else if (obj.attachEvent){
		var r = obj.attachEvent("on"+evType, fn);
		return r;
	} else {
	}
}

function main_init() {
	var currPage = location.href;
	if (currPage.indexOf("toc.html") == -1) {
		var currPageName = main_currPageName(currPage);
		main_highlightSection('header', currPageName, 'currentPage');
		main_highlightSection('footer', currPageName, 'currentPage');
		main_highlightSection('toc-short', currPageName, 'currentPage');
	}
}

function main_currPageName(currPage) {
	return currPage.substring(currPage.lastIndexOf("/") + 1);
}

function main_highlightSection(section, pageName, className) {
	if (document.getElementById) {
		var section = document.getElementById(section);
		if (section) {
			var anchors = section.getElementsByTagName("a");
			if (anchors.length > 0) {
				for (var i = 0; i < anchors.length; i++) {
					if (main_currPageName(anchors[i].href) == pageName) {
						anchors[i].className = className;
					}
				}
			}
		}
	}
}
//-->