/* ----------Nbox start ------------------- */
/* Nbox functions*/

var nbox_current;
var nbox_current_timeout;
// Record scripts
function nbox_over(self) {
	
	if ((nbox_current) && (nbox_current != self)) nbox_out(nbox_current);
	if (nbox_current == self) return;
	

//	if (self.filters.item(0)) { 
		// INFU ADD
//		self.filters.item(1).orientation='horizontal';
//		self.filters.item(0).apply();          //-- TRANSITION :: start point
//		}
	
	

	//self.style.backgroundImage = "url('images/nbox_recbg_over.jpg')";
	//self.style.borderRight = "6px solid";
	//self.style.padding = "5 1 5 10";

	self.style.backgroundColor = self.overcolor;

	
        //if (self.filters) self.filters.item(0).play();           //-- TRANSITION :: end point
        nbox_current = self;
        
        clearTimeout(nbox_current_timeout);
}
function nbox_mouseOut() {
	clearTimeout(nbox_current_timeout);
	nbox_current_timeout = setTimeout('nbox_out()', 2000);
}

function nbox_out(self) {
	if (!self) self = nbox_current;
	self.style.backgroundColor = self.normalcolor;

	//self.style.backgroundImage = "url('images/nbox_recbg.jpg')";
	//self.style.borderRight = "2px solid";
	//self.style.padding = "5 5 5 10";
	nbox_current = false;
}


/* -----------Nbox end------------------ */








/* ----------Nbox 22222222222 start ------------------- */
/* Nbox functions*/

var nbox_current2;
var nbox_current_timeout2;
// Record scripts
function nbox_over2(self) {
	
	if ((nbox_current2) && (nbox_current2 != self)) nbox_out2(nbox_current2);
	if (nbox_current2 == self) return;
	

//	if (self.filters.item(0)) { 
		// INFU ADD
//		self.filters.item(1).orientation='horizontal';
//		self.filters.item(0).apply();          //-- TRANSITION :: start point
//		}
	
	

	//self.style.backgroundImage = "url('images/nbox_recbg_over.jpg')";
	//self.style.borderRight = "6px solid";
	//self.style.padding = "5 1 5 10";

	self.style.backgroundColor = self.overcolor;

	
        //if (self.filters) self.filters.item(0).play();           //-- TRANSITION :: end point
        nbox_current2 = self;
        
        clearTimeout(nbox_current_timeout2);
}
function nbox_mouseOut2() {
	clearTimeout(nbox_current_timeout2);
	nbox_current_timeout2 = setTimeout('nbox_out2()', 2000);
}

function nbox_out2(self) {
	if (!self) self = nbox_current2;
	self.style.backgroundColor = self.normalcolor;

	//self.style.backgroundImage = "url('images/nbox_recbg.jpg')";
	//self.style.borderRight = "2px solid";
	//self.style.padding = "5 5 5 10";
	nbox_current2 = false;
}




/* -----------Nbox end------------------ */




function getContData(control){
	key = control+'_cont';
	var cont = document.getElementById(key).value;
	return cont;
}

function setContData(control,cont){
	key = control+'_cont';
	document.getElementById(key).value = cont;
}



function setIsChanged(block_name){
	document.getElementById(block_name+'_isChanged').value = '*';		
	len = document.getElementById(block_name+'_cont').value.length;
	document.getElementById(block_name+'_size').value = len;		
}

function show_hide(block_name,def_str){
	myobj = document.getElementById(block_name);
	switch(myobj.style.display){
		case 'none':
			myobj.style.display = 'inline';
			document.getElementById(block_name+'_header').className = 'show_hide_div_full';
		break;
		case 'inline':
			myobj.style.display = 'none';
			document.getElementById(block_name+'_header').className = 'show_hide_div_empty';
		break;
		default:
			myobj.style.display = def_str;
		break;
	}
}
	
function showCSSW(key){
	CalWidth = screen.width - 200;
	CalHeight = screen.Height - 160;
	LEFT =screen.width/2-CalWidth/2;
	TOP =screen.Height/2-CalHeight/2;
	var strFeatures = "width=" + CalWidth + ",height="+ CalHeight + ",left=" + LEFT + ",top=" + TOP;
	path = "js/CSSEditor.php?key="+key;
	var CalWindow = window.open(path,"Calendar", strFeatures)
	CalWindow.focus();
} //End Function
