﻿// JScript File
parentItems = 1; // Set this variable to the number of parent items in the outline

	function toggleList(nodeNumber) {
		if (document.getElementById) {
			childNode = document.getElementById("child"+nodeNumber);
		} else if (document.all) {
			childNode = document.all["child"+nodeNumber];
		} else {
			// any other browsers - just do nothing
			// In these browsers the outline will be expanded by default
			return;
		}

		if (childNode.className == "collapsed") {
			childNode.className = "expanded";
		} else {
			childNode.className = "collapsed";
		}
	}
	
	function collapseList(nodeNumber) {
		if (document.getElementById) {
			childNode = document.getElementById("child"+nodeNumber);
		} else if (document.all) {
			childNode = document.all["child"+nodeNumber];
		} else {
			// any other browsers - just do nothing
			// In these browsers the outline will be expanded by default
			return;
		}

		if (childNode.className == "collapsed") {
			childNode.className = "collapsed";
		} else {
			childNode.className = "collapsed";
		}
	}

	function toggleAll() {
		for (i=1; i<=parentItems; i++) {
			toggleList(i);
		}
	}
