var iO = null;

function InitOnloadHandler()
{
	this.exeColl = new Array();
	
	this.appendFunction = function(fO)
	{
		if((typeof fO).toLowerCase() == 'function')
		{
			this.exeColl[this.exeColl.length] = fO;
		}
	}
	
	this.execute = function()
	{
		for(var i=0; i<this.exeColl.length; i++)
		{
			this.exeColl[i].apply(this);
		}
	}
}

function addOnloadFunction(fO)
{
	if(iO == null)
	{
		iO = new InitOnloadHandler();
	}
	
	iO.appendFunction(fO);
}

window.onload = function()
{
	if(iO != null)
	{
		iO.execute();
	}
}
