// JavaScript Document
function fnEmbedMainFlash(strParam,width,height){
	var strObject;
	strObject = "<object classid='clsid:d27cdb6e-ae6d-11cf-96b8-444553540000' codebase='http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,0,0' width='" + width + "' height='" + height + "' id='menu'> " + "<param name=movie value='" + strParam + "'>" + "<param name=menu value=false>" + "<param name=quality value=high>" + "<param name=wmode value='transparent'>" + "<param name=bgcolor value=#011d28>" + "<embed src='" + strParam + "' menu=false quality=High wmode=transparent bgcolor=#011d28 width='" + width + "' height='" + height + "' name='menu' type='application/x-shockwave-flash' pluginspage='http://www.macromedia.com/go/getflashplayer'></embed>" +	"</object>";
	document.write(strObject);
} 
function ckNav(pid){
	switch (pid) {
		case 10 : 
			location.href = "brief.asp";
			break;
		case 11:
			location.href = "brief.asp";
			break;
		case 12:
			location.href = "honor.asp";
			break;
		case 13:
			location.href = "culture.asp";
			break;
		case 20:
			location.href = "tech.asp";
			break;
		case 21:
			location.href = "tech.asp";
			break;
		case 22:
			location.href = "QS.asp";
			break;
		case 23:
			location.href = "QC.asp";
			break;
		case 30:
			location.href = "news.asp?classid=1";
			break;
		case 31:
			location.href = "news.asp?classid=1";
			break;
		case 32:
			location.href = "news.asp?classid=2";
			break;
		case 40:
			location.href = "product.asp";
			break;
		case 41:
			location.href = "product.asp?classid=1";
			break;
		case 42:
			location.href = "product.asp?classid=2";
			break;
		case 43:
			location.href = "product.asp?classid=4";
			break;
		case 44:
			location.href = "product.asp?classid=6";
			break;
		case 45:
			location.href = "product.asp?classid=5";
			break;
		case 50:
			location.href = "job.asp";
			break;
		case 51:
			location.href = "job.asp";
			break;
		case 52:
			location.href = "recruit.asp";
			break;
		case 60:
			location.href = "contact.asp";
			break;
		case 901:
			location.href = "product.asp";
			break;
		case 902:
			location.href = "ask.asp";
			break;
		case 903:
			location.href = "QNA.asp";
			break;
		case 904:
			location.href = "contact.asp";
			break;
		default :
	} 
}
function FixImage(image,imageWidthFix,imageHeightFix,autoFix){
	if(image.width/image.height>imageWidthFix/imageHeightFix){
		if(image.width>imageWidthFix){
			image.width=imageWidthFix;
		}		
	}else{
		if(image.height>imageHeightFix){
			image.height=imageHeightFix;
		}
	}
	if(autoFix!=undefined&&autoFix!=-1){
		var marginTop=Math.floor((image.height)/2+autoFix);
		var marginLeft=Math.floor((image.width)/2+autoFix);
		image.style.margin="-"+marginTop+"px auto auto -"+marginLeft+"px";
	}else{
		var marginTop=Math.floor((imageHeightFix-image.height)/2)
		var marginLeft=Math.floor((imageWidthFix-image.width)/2)
		image.style.marginTop=marginTop+"px";
	}	
}

function openVR(url,wWidth,wHeight){window.open (url, 'newwindow', 'height=' + wHeight + ', width=' + wWidth + ', top=0, left=0, toolbar=no, menubar=no, scrollbars=no, resizable=no,location=no, status=no')}