/*==========left manu function-------------------*/
	var nn4 = (document.layers) ? true : false
	var ie = (document.all) ? true : false
	var TotComps,tmp_d;
	
	function getAbsoluteTopMenu(vobjectId) {
		// Get an object top position from the upper left viewport corner
		// Tested with relative and nested objects 
		//alert(document.getElementById(objectId))
		o = document.getElementById(vobjectId)
		oTop = o.offsetTop            // Get top position from the parent object
		while(o.offsetParent!=null) { // Parse the parent hierarchy up to the document element
			oParent = o.offsetParent  // Get parent object reference
			oTop += oParent.offsetTop // Add parent top position
			o = oParent
		}
		// Return top position
		return oTop
	}
	
	function getAbsoluteLeftMenu(objectId) {
		// Get an object left position from the upper left viewport corner
		// Tested with relative and nested objects
		var oLeft
		o = document.getElementById(objectId)
		if((document.all) ? true : false) {
			oLeft = o.offsetLeft            // Get left position from the parent object
			while(o.offsetParent!=null) {   // Parse the parent hierarchy up to the document element
				oParent = o.offsetParent    // Get parent object reference
				oLeft += oParent.offsetLeft // Add parent left position
				o = oParent
			}
		}
		else
		{
		var FireFoxCoordsSplit=o.coords.split(',');
		oLeft = parseInt(FireFoxCoordsSplit[FireFoxCoordsSplit.length-2]);
		oLeft=parseInt(oLeft-110);
		if(oLeft<0) oLeft=3; 
		o = o.offsetParent
		}
		
		// Return left postion
		return oLeft
	}
	
	var In="",tmp_d="";
	function ShowMenu(d,usage) {
		//alert(d);
		//usage=1 means Catmenu
		//usage=2 means Thememenu
		if(TotComps!=undefined)
		{
			HideMenu(TotComps,usage);
			if(usage==1)
			{
				TotComps=document.getElementById("DivCat" + d)
				TotComps=d
				//alert("DivCat" + d);
			}
			else
			{
				TotComps=document.getElementById("DivTheme" + d)
				TotComps=d
			}
		}
		else
		{
			if(usage==1)
			{
				TotComps=document.getElementById("DivCat" + d)
				TotComps=d
			}
			else
			{
				TotComps=document.getElementById("DivTheme" + d)
				TotComps=d
			}
			HideMenu(d,usage)
		}
		var type_str="Cat";
		if(usage==2) {type_str="Theme";}
		var s, DivComp, DivCompImg;
		s = d * 100;
		try {
			DivComp = document.getElementById("Div" + type_str + s);
			if(DivComp) { 
			
				if((document.all) ? true : false) {
					DivComp.style.left = getAbsoluteLeftMenu("Div" +type_str+ d)+10
					getAbsoluteTopMenu("Div" +type_str+ d);
					DivComp.style.top =(getAbsoluteTopMenu("Div" +type_str+ d)+165)+ 'px';
				} else {
					DivComp.style.left = getAbsoluteLeftMenu("Div" +type_str+ d) + 'px';
					DivComp.style.top =(getAbsoluteTopMenu("Div" +type_str+ d)+35) + 'px';
				}
				DivComp.style.visibility = 'visible';
				DivComp.style.display= 'inline';
				
			}
			i=1;
			/*
			tmp_d = d;
			tmp_cat_theme = usage;
			if(In != "") {
				window.clearInterval(In);
			}
			In = window.setInterval("javascript:StayVisible()","3000");
			*/
		} catch(e) {
			//alert("Error : " & DivComp);
		}
	}
	
	function StayVisible() {
		window.clearInterval(In);
		HideMenu(tmp_d,tmp_cat_theme);
		//HideMenu(tmp_d,2);
	}
	function HideMenu(d,usage){
		//usage=1 means Catmenu
		//usage=2 means Thememenu
		var type_str="Cat";
		if(usage==2) {type_str="Theme";}
		
		var s, DivComp, DivCompImg;
		s = d * 100;
		//alert(s)
		DivComp = document.getElementById("Div"+type_str + s);
		if(DivComp) {
			DivComp.style.visibility = 'hidden';
			DivComp.style.display= 'none';
		}
	}
	function HideMenu1(d,usage){
		tmp_d = d;
		tmp_cat_theme = usage;
		if(In != "") {
			window.clearInterval(In);
		}
		In = window.setInterval("javascript:StayVisible()","800");
	}
	function ClearInt(){
		if(In != "") {
			window.clearInterval(In);
		}
	}
	/*=========right menu javascript===========*/