/*-----------------------------------------------------------------------------------------------*/
// common.js
//
// main ブロックの sidebox,mainbox のサイズをウィンドウサイズに合わせて変更する
//
/*-----------------------------------------------------------------------------------------------*/

function resizeScroll(){
	var myw=0.9*(getBrowserWidth());
	var myh=(getBrowserHeight() - 200);

    if (myh < 400) {
        myh = 430;
    }

    document.getElementById("sidebox").style.height = myh + "px";
    document.getElementById("mainbox").style.height = myh + "px";

}
function getBrowserWidth() {  
	if ( window.innerWidth ) {
		return window.innerWidth; 
	} 
	else if ( document.documentElement && document.documentElement.clientWidth != 0 ) {
		return document.documentElement.clientWidth; 
	}
	else if ( document.body ) {
		return document.body.clientWidth;
	}
	return 0;  
}  
function getBrowserHeight() {  
	if ( window.innerHeight ) {
		return window.innerHeight; 
	} 
	else if ( document.documentElement && document.documentElement.clientHeight != 0 ) {
		return document.documentElement.clientHeight; 
	}
	else if ( document.body ) {
		return document.body.clientHeight;
	}
	return 0;  
}  

