
var isMacIE = document.all && !window.print;
var isIE = document.all;
LCB_version = 2.8;
// _mac : true = macintosh, false = other os
_mac=navigator.userAgent.indexOf('Mac')!=-1;
// _ie512 : true = MSIE 5.12(mac), false = others
_ie512=navigator.userAgent.indexOf('MSIE 5.12')!=-1;
// _dom : kind of DOM.
//        IE4 = 1, IE5+ = 2, NN4 = 3, NN6+ = 4, others = 0
_dom = document.all?(document.getElementById?2:1)
                   :(document.getElementById?4:(document.layers?3:0));
_createLayerNo = 0;                    // layer no.
/* ======================================================================
 *このスクリプトを外部ソースとして使用する場合は以下の関数を有効にして
 * 使用する最初に onLoad イベントでこの関数を呼び出して初期化して下さい */
function initCrossBrowserLib(){
  _mac=navigator.userAgent.indexOf('Mac')!=-1;
  _ie512=navigator.userAgent.indexOf('MSIE 5.12')!=-1;
  _dom=document.all?(document.getElementById?2:1)
                     :(document.getElementById?4:(document.layers?3:0));
  _createLayerNo=0;
}

function GetWinSize(arg){
	if(isMacIE){
		if(arg=='w'){return parseInt(document.body.clientWidth-15,10)}
		else{
			return parseInt(document.body.clientHeight,10)+parseInt(document.body.scrollTop,10)
		}
	}
	else if(isIE){
		if(arg=='w'){return parseInt(document.body.clientWidth,10)}
		else{
			if(parseInt(document.body.scrollHeight,10) > parseInt(document.body.clientHeight,10)){
				return parseInt(document.body.scrollHeight,10)
			}
			else{
				return parseInt(document.body.clientHeight,10)
			}
		}
	}
	else{
		if(arg=='w'){return parseInt(window.innerWidth,10)-18;}
		else{return parseInt(window.innerHeight+window.pageYOffset,10)}
	}
}
