// ***** Copyright Pacific Fox 2006 (info@pacificfox.com.au)
Window = function () // Constructor
{
	this.onloadListenerCollection = new Array();
	return this;
}
Window.prototype = 
{
	getOnloadListenerCollection:function() 
	{
		return this.onloadListenerCollection;
	},
	doAddOnloadListener:function( listener ) 
	{
		this.getOnloadListenerCollection().push( listener );
		return this;
	},
	doCallOnloadEventCollection:function() 
	{
		var myListenerCollection = this.getOnloadListenerCollection();
		for ( var i = 0; i < myListenerCollection.length; i++ )
		{
			var myFunction = myListenerCollection[ i ];
			myFunction.call();
		}
		return this;
	}
}

// Lousy way to keep this a singleton
if ( typeof( myWindow ) == "undefined" )
{
	var myWindow = new Window();
}