var Width = 0, Height = 0;

function Onload (Function) {
	if (typeof window.addEventListener != "undefined") {
		window.addEventListener("load", Function, false );
	}
	else if (typeof window.attachEvent != "undefined") {
		window.attachEvent("onload", Function);
	}
	else {
		if (window.onload != null) {
			var oldOnload = window.onload;
			window.onload = function (e) {
				oldOnload(e);
				window[Function]();
			};
		}
		else
			window.onload = Function;
	}
}

function getSize () {
	if( typeof( window.innerWidth ) == 'number' ) {
		Width = window.innerWidth;
		Height = window.innerHeight;
	}
	else if( document.documentElement && ( document.documentElement.clientWidth || document.documentElement.clientHeight ) ) {
		Width = document.documentElement.clientWidth;
		Height = document.documentElement.clientHeight;
	} 
	else if( document.body && ( document.body.clientWidth || document.body.clientHeight ) ) {
		Width = document.body.clientWidth;
		Height = document.body.clientHeight;
	}
}