//_______________________________________________________________■　Bridal Fair 専用

//_短いとき(スクロールなし)
var wObj;
function openWin(wUrl,wName,wWidth,wHeight){
	scWidthCenter = screen.availWidth / 2;
	scHeightCenter = screen.availHeight / 2;
	if(OSFlag == "MacIE"){
		wWidth=wWidth+0
		wHeight=wHeight+0
	}else if(OSFlag == "MacNN4"){
		wWidth=wWidth+0
		wHeight=wHeight-10
	}else if(OSFlag == "MacNN7"){
		wWidth=wWidth+0
		wHeight=wHeight+35
	}else if(OSFlag == "WinIE"){
		wWidth=wWidth+0
		wHeight=wHeight+0
	}else if(OSFlag == "WinNN4"){
		wWidth=wWidth+0
		wHeight=wHeight-25
	}else{
		wWidth=wWidth+0
		wHeight=wHeight+0
	}
	wOption = "toolbar=no,location=no,directories=no,status=no,menubar=no,scrollbars=no,resizable=yes,width=" + wWidth + ",height=" + wHeight + ",left=" + (scWidthCenter - (wWidth / 2)) + ",top=" + (scHeightCenter - (wHeight / 2));
	wObj = window.open(wUrl,wName,wOption);

	wObj.focus();
}

//_長いとき(スクロールあり)
var wObj2;
function openWin2(wUrl,wName,wWidth,wHeight){
	scWidthCenter = screen.availWidth / 2;
	scHeightCenter = screen.availHeight / 2;
	if(OSFlag == "MacIE"){
		wWidth=wWidth+0
		wHeight=wHeight+0
	}else if(OSFlag == "MacNN4"){
		wWidth=wWidth+0
		wHeight=wHeight+0
	}else if(OSFlag == "MacNN7"){
		wWidth=wWidth+15
		wHeight=wHeight+20
	}else if(OSFlag == "WinIE"){
		wWidth=wWidth+16
		wHeight=wHeight+12
	}else if(OSFlag == "WinNN4"){
		wWidth=wWidth+15
		wHeight=wHeight-10
	}else{
		wWidth=wWidth+15
		wHeight=wHeight+15
	}
	wOption = "toolbar=no,location=no,directories=no,status=yes,menubar=no,scrollbars=yes,resizable=yes,width=" + wWidth + ",height=" + wHeight + ",left=" + (scWidthCenter - (wWidth / 2)) + ",top=" + (scHeightCenter - (wHeight / 2));
	wObj2 = window.open(wUrl,wName,wOption);

	wObj2.focus();
}


//_______________________________________________________________■　Nomal

var wObj3;
function openWin3(wUrl,wName,wWidth,wHeight){
	scWidthCenter = screen.availWidth / 2;
	scHeightCenter = screen.availHeight / 2;
	wOption = "toolbar=no,location=no,directories=no,status=yes,menubar=no,scrollbars=no,resizable=no,width=" + wWidth + ",height=" + wHeight + ",left=" + (scWidthCenter - (wWidth / 2)) + ",top=" + (scHeightCenter - (wHeight / 2));
	wObj3 = window.open(wUrl,wName,wOption);

	wObj3.focus();
}


//_______________________________________________________________■　Opener Change
function OpenerChange(TargetPage){
	if( OSFlag == "MacIE"){
		if (window.opener){
			window.opener.location.href=TargetPage;
		}else{
			NewWin = window.open('','Main','toolbar=yes,location=yes,directories=yes,status=yes,menubar=yes,scrollbars=yes,resizable=yes,width=800,height=680');
			NewWin.location.href=TargetPage;
		}
	}else if(OSFlag == "MacNN7" || OSFlag == "WinNN7"){
		NewWin = window.open('','Main','toolbar=yes,location=yes,directories=yes,status=yes,menubar=yes,scrollbars=yes,resizable=yes,width=800,height=680');
		NewWin.location.href=TargetPage;
	}else {
		if(opener.closed == true ){
			NewWin = window.open('','Main','toolbar=yes,location=yes,directories=yes,status=yes,menubar=yes,scrollbars=yes,resizable=yes,width=800,height=680');
		NewWin.location.href=TargetPage;
		}else{
			window.opener.location.href=TargetPage;
		}
	}
}