// JavaScript Document

function PanelManager(divPrefix, tabPrefix, active, inactive) {
	this.prefix = divPrefix;
	this.tPrefix = tabPrefix;
	this.active = active;
	this.inactive = inactive;
	this.open = null;
	this.showPanel(1);
}
function showPanel(panel) {
	if ( this.open != null ) {
		var c = document.getElementById(this.prefix + this.open);
		

		if ( !c ) {
		}else{
			c.style.display = "none";
//			c.style.visibility = 'hidden';
		}
		
		var e = document.getElementById(this.tPrefix + this.open);
	
		if ( !e ) {
			
		} else {
			e.className =this.inactive;
		}

		
	}
	
	var b = document.getElementById(this.prefix + panel);
	if ( !b ) {
	} else {
		b.style.display = "block";
//		b.style.visibility = 'visible';
	}
	
	this.open = panel;
	
	var d = document.getElementById(this.tPrefix + panel);
	
	if ( !d ) {
		
	} else {
//		d.style.backgroundColor = "#94a5b5";	
		d.className= this.active;
	}

	
}

PanelManager.prototype.showPanel = showPanel;