// JavaScript Document
function resize(id){ 
  var agt=navigator.userAgent.toLowerCase();
  myWidth = 0, myHeight = 0;
  if( typeof( window.innerWidth ) == 'number' ) {
	//Non-IE
	myWidth = window.innerWidth;
	myHeight = window.innerHeight;
  } else {
	if( document.documentElement &&
		( document.documentElement.clientWidth || document.documentElement.clientHeight ) ) {
	  //IE 6+ in 'standards compliant mode'
	  myWidth = document.documentElement.clientWidth;
	  myHeight = document.documentElement.clientHeight;
	} else {
	  if( document.body && ( document.body.clientWidth || document.body.clientHeight ) ) {
		//IE 4 compatible
		myWidth = document.body.clientWidth;
		myHeight = document.body.clientHeight;
	  }
	}
  }
  var frame = document.getElementById(id); 
  frame.style.height = (myHeight - 105) + "px";
  if (agt.indexOf("msie") != -1) {
	  frame.style.width = (myWidth - 320) + "px";
  }
}

function centerProgress(map, progress) {
	var mapDIV = document.getElementById(map);
	var progressDIV = document.getElementById(progress);
	if (mapDIV.clientHeight > 0) {
		var height = mapDIV.clientHeight;
		var width = mapDIV.clientWidth;
	} else {
		var height = mapDIV.offsetHeight;
		var width = mapDIV.offsetWidth;
	}
	x = 150 + (width / 2) - 100;
	y = 85 + (height / 2) - 25;
	progressDIV.style.left = x + "px";
	progressDIV.style.top = y + "px";
}

function resizeAll(id){ 
  var agt=navigator.userAgent.toLowerCase();
  myWidth = 0, myHeight = 0;
  if( typeof( window.innerWidth ) == 'number' ) {
	//Non-IE
	myWidth = window.innerWidth;
	myHeight = window.innerHeight;
  } else {
	if( document.documentElement &&
		( document.documentElement.clientWidth || document.documentElement.clientHeight ) ) {
	  //IE 6+ in 'standards compliant mode'
	  myWidth = document.documentElement.clientWidth;
	  myHeight = document.documentElement.clientHeight;
	} else {
	  if( document.body && ( document.body.clientWidth || document.body.clientHeight ) ) {
		//IE 4 compatible
		myWidth = document.body.clientWidth;
		myHeight = document.body.clientHeight;
	  }
	}
  }
  var frame = document.getElementById(id); 
  frame.style.height = (myHeight - 105) + "px";
  if (agt.indexOf("msie") != -1) {
	  frame.style.width = (myWidth - 320) + "px";
  }
}
