//取り急ぎのライブでのサウンド再生用(20070220)
function tmpDocwrite() {
	//0か1をランダムにゲットする
	var tRandom	=	Math.floor(Math.random() * 7) + 1;
	var tSound	=	"";
	 	tSound	= "sounds/live_in_kobe_s_0" + tRandom + ".mp3";
	
	document.writeln("<embed src=\"" + tSound + "\"width=\"1\" height=\"1\" autostart=\"true\" hidden=\"true\"></embed>");	
	
	//Windows Media Player 6.3
	/*var tText	= "<object classid=\"CLSID\:22D6F312-B0F6-11D0-94AB-0080C74C7E95\" height=0 width=0><param name=\"data\" value=tSound><param name=\"type\" value=\"audio/mpeg3\"><param name=\"AutoStart\" value=\"true\"><param name=\"ShowControls\" value=\"false\"><param name=\"Volume\" value=\"0\"></object>";
	document.writeln(tText);*/
}


//変数を初期化するためのクラスとして計画中(20061212)
//ただ、JavaScriptのクラスが自体が・・・・・・。
function clsInit(aArray) {
    this.os;
	this.brw;
	this.na=navigator.userAgent;
	if(this.na.indexOf("Mac")>=0){this.os="mac";}
	if(this.na.indexOf("MSIE")>=0){this.brw="ie";}
	//this.toString = function () {
	//	return (this.name + " / " + this.age);
	//}
}

function checkUserAgent(aArray){
	var tClsInit = new clsInit();
	if(tClsInit.os=="mac"){
		location.replace("index_mac.html");
	} else {
		location.replace("index_win.html");
	}
	//else if(brw!="ie"){
	//  location.replace("bbtop_noie.html");
	//}
	//window.moveTo(0,0);
	//w=screen.availWidth;
	//h=screen.availHeight;
	//window.resizeTo(w,h);
}




function xxxx() {
	if (checkUserAgent()) {}
}



function xOpenWindow(tURL,tWindowName,tFeatures) { //v2.0
		window.open(tURL,tWindowName,tFeatures);
}

//プロモーション動画用
//20070621
//485 * 332
function xOpenWindow_02(tURL,tWindowName,tFeatures,tNum) {
	var tMovieWindowWidth	= 485;	//ムービーの幅
	var tMovieWindowHeight	= 332;	//ムービーの高さ
	var tMargin				= 50;
	var tScreenWidth	= screen.availWidth;	//デスクトップの幅
	var tScreenHeight	= screen.availHeight;	//デスクトップの高さ
//	新規ウィンドウの左端位置
	var tLeft	= tScreenWidth - tMovieWindowWidth - tMargin;
//	新規ウィンドウの上端位置
	var tTop	= tMargin * tNum;
	//var tTop	= tMargin + tMovieWindowHeight/3 * (tNum - 1);
//	tFeaturesにleftとtopを加える//left=485,top=300
	tFeatures	= tFeatures + ', left=' + tLeft + ', top=' + tTop;
	window.open(tURL,tWindowName,tFeatures);
//城尾さんに、次の処理を「acqulia.inc.php」に埋め込んでもらう予定。またゆっくり相談することに(20070621)。
//	<body oncontextmenu="return false" onLoad="javascript:window.focus();">
}

function MM_findObj(n, d) { //v4.01
  var p,i,x;  if(!d) d=document; if((p=n.indexOf("?"))>0&&parent.frames.length) {
    d=parent.frames[n.substring(p+1)].document; n=n.substring(0,p);}
  if(!(x=d[n])&&d.all) x=d.all[n]; for (i=0;!x&&i<d.forms.length;i++) x=d.forms[i][n];
  for(i=0;!x&&d.layers&&i<d.layers.length;i++) x=MM_findObj(n,d.layers[i].document);
  if(!x && d.getElementById) x=d.getElementById(n); return x;
}
function MM_swapImage() { //v3.0
  var i,j=0,x,a=MM_swapImage.arguments; document.MM_sr=new Array; for(i=0;i<(a.length-2);i+=3)
   if ((x=MM_findObj(a[i]))!=null){document.MM_sr[j++]=x; if(!x.oSrc) x.oSrc=x.src; x.src=a[i+2];}
}
function MM_swapImgRestore() { //v3.0
  var i,x,a=document.MM_sr; for(i=0;a&&i<a.length&&(x=a[i])&&x.oSrc;i++) x.src=x.oSrc;
}
function MM_preloadImages() { //v3.0
  var d=document; if(d.images){ if(!d.MM_p) d.MM_p=new Array();
    var i,j=d.MM_p.length,a=MM_preloadImages.arguments; for(i=0; i<a.length; i++)
    if (a[i].indexOf("#")!=0){ d.MM_p[j]=new Image; d.MM_p[j++].src=a[i];}}
}
