/* CLASS LayoutManager0 */
function LayoutManager1(id) {
	
	this.id=id;
	this.config = {
		MARGIN_TOP:27,
		MARGIN_BOTTOM:42
	};
	
	this.bClientCompliant=true;


	this.oDiv=new Array();
	this.oDiv['page']=getObj('page');
	
};

LayoutManager1.prototype.getInnerHeight= function(){
	
	var cHeight=null;
	
	if (!!window.innerHeight){
		cHeight = window.innerHeight;
	} else 	if (window.document.documentElement && window.document.documentElement.clientHeight){
		cHeight = window.document.documentElement.clientHeight;
	} else if (window.document.body){
		cHeight = window.document.body.clientHeight;
	}
	
	return cHeight;
};

LayoutManager1.prototype.getInnerWidth= function(){
	
	var cWidth=null;
	
	if (!!window.innerWidth){
		cWidth = window.innerWidth;
	} else 	if (window.document.documentElement && window.document.documentElement.clientWidth){
		cWidth = window.document.documentElement.clientWidth;
	} else if (window.document.body){
		cWidth = window.document.body.clientWidth;
	}
	
	return cWidth;
};

LayoutManager1.prototype.layout = function() {
	if (!this.bClientCompliant) return;

	if ((this.getInnerHeight()-(this.config.MARGIN_TOP+this.config.MARGIN_BOTTOM))>0){
		this.oDiv['page'].style.height=(this.getInnerHeight()-(this.config.MARGIN_TOP+this.config.MARGIN_BOTTOM))+'px';
	}
		
};

LayoutManager1.prototype.print=function(objname){

	if (!this.bClientCompliant) {
		window.print();
		return;
	}

	var i,j;
	var content=getObj((objname?objname:'middlecol')).innerHTML;
	var stylesheetimports=getObj('stylesheetimports').innerHTML;
	var title=document.title;
	var xhtml='<html><head><title>'+title+'</title><style type="text/css" media="all">'+stylesheetimports+'</style></head><body style="margin: 10px;" onload="window.print();window.setTimeout(\'history.go(-1)\',100);">'+content+'</body></html>';
	document.open("text/html");
	document.write(xhtml);
	document.close();
};
