function gebi(id){return document.getElementById(id)}
function popup(l,w){if(!window.focus)return true;var h=typeof(l)=='string'?l:l.href;window.open(h,w,'width=400,height=230,left=50,top=50,resizable=no,scrollbars=no,toolbar=no,menubar=no,location=no,directories=no,status=no');return false}
function BgMove(e,c){e.style.backgroundPosition=c;}function BgMoveByX(e){BgMove(e,-e.offsetWidth+'px 0px');}
function srAddEvent(obj, type, fn){if (obj.addEventListener)obj.addEventListener(type, fn, false);else if(obj.attachEvent)obj.attachEvent(("on"+type),fn);}
function SwapImage(){if(document.images)gebi(SwapImage.arguments[0]).src="/img/tanat/"+SwapImage.arguments[1];}
function ProcessMenu(id,ignore){
	if(ignore)return;
	var div='mBut'+id+'_content';
	var subBlock=gebi(div).style.display;
	if(subBlock!='none'){
		gebi('mPM00'+id).style.display='none';
		gebi('mPM01'+id).style.display='block';
		gebi(div).style.display='none';
	}else{
		gebi('mPM00'+id).style.display='block';
		gebi('mPM01'+id).style.display='none';
		gebi(div).style.display='block';
	}
}
function StopAllAudio(id){
	var NodeList=document.getElementsByTagName('OBJECT');
	for(var i=0; i<NodeList.length; i++)
		if(NodeList[i].id!=null && NodeList[i].id!='' && NodeList[i].id!=id){
			var movie=(navigator.appName.indexOf("Microsoft")!=-1?window:document)[NodeList[i].id];
			movie.SetVariable('message','data');
		}
}
