function WindowProperties() {
	
	this.getWindowWidth = function() {
		this.resetProperties();
		return this.frameWidth;
	}
	
	this.getWindowHeight = function() {
		this.resetProperties();
		return this.frameHeight;
	}
	
	this.getCenterPoint = function() {
		this.resetProperties();
		return [ parseInt(this.frameWidth / 2,10) + this.scrollX, (parseInt(this.frameHeight / 2,10)) + this.scrollY ]
	}
	
	this.resetProperties = function() {
		if (typeof( window.innerWidth ) == 'number') {
			this.frameWidth = window.innerWidth;
			this.frameHeight = window.innerHeight;
		} else if (document.documentElement && document.documentElement.clientWidth) {
			this.frameWidth = document.documentElement.clientWidth;
			this.frameHeight = document.documentElement.clientHeight;
		} else if (document.body) {
			this.frameWidth = document.body.clientWidth;
			this.frameHeight = document.body.clientHeight;
		}
		if( typeof( window.pageYOffset ) == 'number' ) {
			this.scrollY = window.pageYOffset;
		    this.scrollX = window.pageXOffset;
		} else if( document.body && ( document.body.scrollLeft || document.body.scrollTop ) ) {
		    this.scrollY = document.body.scrollTop;
		    this.scrollX = document.body.scrollLeft;
		} else if( document.documentElement && ( document.documentElement.scrollLeft || document.documentElement.scrollTop ) ) {
		    this.scrollY = document.documentElement.scrollTop;
		    this.scrollX = document.documentElement.scrollLeft;
		}
	}
	
	this.frameWidth = 0;
	this.frameHeight = 0;
	this.scrollY = 0;
	this.scrollX = 0;
	this.resetProperties();
}