﻿function NetReader(Code){

	var value = NetReader.arguments;	

	if (window.ActiveXObject) {
	}
	else{

		if ( Otder_browser == "F" ){	//!IE일경우 비활성화이면 리턴
			if (Code =="FontUp" || Code == "FontDown"){//폰트 확대는 진행시킨다.
			}
			else if(Code == "ZoomUp" || Code =="ZoomDown"){  //화면 확대축소는 FF에서 지운하지 않는다.
				alert("It is not support to zoom in or out on FireFox.");
				if (!window.ActiveXObject) return;
			}else{  //이외의 키는 모두 막는다.
				alert("NetLignt is only compatible with Internet Explorer.");
				if (!window.ActiveXObject) return;
			}
			
		}
	}
	

			if(KeyEvent_F == 1){ //사이트 폭주 등 임시로 이벤트를 막고 싶을때 사용
					// 2009.05.25 OK 음성서비스 중지
					//음성시작
//					if( Code == "VoiceStart" ){
//						
//						/*버튼 오류로 인한 소스 수정*/	
//						if (typeof (DynamicNetLightCOM)=="undefined"){
//							if (readCookie("VoiceStart")=="stop"){
//								space_setCookie("VoiceStart","start",1);	
//							}
//						}
//						/*버튼 오류로 인한 소스 수정*/	
//
//						if( FrameLength == 2 )eval(FrameMainName +"f_VoiceStart('start')");
//						else f_VoiceStart('start');								
//					}
			
					//음성중지
					if( Code == "VoiceStop" ){
						if( FrameLength == 2 )
							eval(FrameMainName +"f_VoiceStart('stop')");						
						else
							f_VoiceStart('stop');
				
				
					}

					//네비게이션 시작
					if( Code == "NaviStart")
					{
						if ( FrameLength == 2)
							eval(FrameMainName + "f_NaviStart('start')");
						else
							f_NaviStart('start');
					}

					//네비게이션 중지
					if ( Code == "NaviStop")
					{
						if ( FrameLength == 2)
							eval(FrameMainName + "f_NaviStart('stop')");
						else
							f_NaviStart('stop');	
					}
			
					//음성볼륨 업
					if( Code == "VolumUp" ){
						if(DynamicNetLightCOM.VoiceActive  == true || DynamicNetLightCOM.NavigationActive  == true){
							if( FrameLength == 2 )
								eval(FrameMainName +"f_VoiceVolume('up');");
							else
								f_VoiceVolume('up');
						}else{
							alert("It would only work with Voice Service working.");
						}
					}
				
					//음성볼륨 다운
					if( Code == "VolumDown" ){
						if(DynamicNetLightCOM.VoiceActive  == true || DynamicNetLightCOM.NavigationActive  == true){
							if( FrameLength == 2 )
								eval(FrameMainName +"f_VoiceVolume('down');");
							else
								f_VoiceVolume('down');
						}else{
							alert("It would only work with Voice Service working.");
						}
					}
			
					//음성속도 업
					if( Code == "SpeedUp" ){
						if(DynamicNetLightCOM.VoiceActive  == true || DynamicNetLightCOM.NavigationActive  == true){
							if( FrameLength == 2 )
								eval(FrameMainName +"f_VoiceSpeed('up');");
							else
								f_VoiceSpeed('up');
						}else{
							alert("It would only work with Voice Service working.");
						}
					}
				
					//음성속도 다운
					if( Code == "SpeedDown" ){
						if(DynamicNetLightCOM.VoiceActive  == true || DynamicNetLightCOM.NavigationActive  == true){
							if( FrameLength == 2 )
								eval(FrameMainName +"f_VoiceSpeed('down');");
							else
								f_VoiceSpeed('down');
						}else{
							alert("It would only work with Voice Service working.");
						}
					}
				
					//글자크기 크게
					if( Code == "FontUp" ){
						if( FrameLength == 2 )
							eval(FrameMainName +"f_fontPlus();");
						else
							f_fontPlus();
					}
			
					//글자크기 작게
					if( Code == "FontDown" ){
						if( FrameLength == 2 )
							eval(FrameMainName +"f_fontMinus();");
						else
							f_fontMinus();
					}
				
					//화면크기 크게
					if( Code == "ZoomUp" ){
						if( FrameLength == 2 )
							eval(FrameMainName +"zoomInOut('in');");			
						else
							zoomInOut('in');
					}
				
					//화면크기 작게
					if( Code == "ZoomDown" ){
						if( FrameLength == 2 )
							eval(FrameMainName +"zoomInOut('out');");
						else
							zoomInOut('out');
					}
				
					//글자색 변경
					if( Code == "FontColor" ){
						if( FrameLength == 2 )
							eval(FrameMainName +"f_setFontColor("+ value[1] +");");
						else
							f_setFontColor();
					}
				
					//바탕색 변경
					if( Code == "BgColor" ){
						if( FrameLength == 2 )
							eval(FrameMainName +"f_setBgColor("+ value[1] +");");
						else
							f_setBgColor();
					}
			
			}else{
				if(KeyEvent_F_F == 1){
				alert(KeyEvent_F_M);
				}
			}	
	
}