// JavaScript Document

function changeTop (value) {
	nav.setTop(value);
	nav.updateTopNav();
}

function navSelection () {
	this.top=0;
	this.left=0;
	this.leftSub=0;
}

navSelection.prototype.getTop = function () {
	return this.top;
}

navSelection.prototype.setTop = function (setTopTo) {
	this.top = setTopTo;
}

navSelection.prototype.getLeft = function () {
	return this.left;
}

navSelection.prototype.setLeft = function (setLeftTo) {
	this.left = setLeftTo;
}

navSelection.prototype.getLeftSub = function () {
	return this.leftSub;
}

navSelection.prototype.setLeftSub = function (setLeftSubTo) {
	this.leftSub = setLeftSubTo;
}

navSelection.prototype.updateTopNav = function () {
	if(window.top_nav) window.document["top_nav"].SetVariable("changeFlag", 1);
	if(document.top_nav) document.top_nav.SetVariable("changeFlag", 1);
	
	if(window.top_nav) window.document["top_nav"].SetVariable("changedSelection", this.top);
	if(document.top_nav) document.top_nav.SetVariable("changedSelection", this.top);
}

navSelection.prototype.updateLeftNav = function () {
	if(window.maincontent) window.maincontent.document["leftnav"].SetVariable("changedSelection", this.top);
	if(document.maincontent) document.maincontent.leftnav.SetVariable("changedSelection", this.top);
}


var nav = new navSelection();