var main = {
	prepare : function () {
		initLightbox();
		theme.prepare();
		window.onresize = theme.orientFooter.bindAsEventListener(theme);
	}
};


/*
 * Position extensions
 *================================================================================================*/
Object.extend(Position, {
  pageScrollTop : function(){
  	var yScrolltop;
  	if (self.pageYOffset) {
  		yScrolltop = self.pageYOffset;
  	} else if (document.documentElement && document.documentElement.scrollTop){	 // Explorer 6 Strict
  		yScrolltop = document.documentElement.scrollTop;
  	} else if (document.body) {// all other Explorers
  		yScrolltop = document.body.scrollTop;
  	}
  	return yScrolltop;
  },
  viewportSize : function(){
  	var de = document.documentElement;
  	var w = window.innerWidth || self.innerWidth || (de&&de.clientWidth) || document.body.clientWidth;
  	var h = window.innerHeight || self.innerHeight || (de&&de.clientHeight) || document.body.clientHeight;
  	return {width:w, height:h};
  },
	pageDimensions : function () {
		var de = document.documentElement;
		return {width:(de.scrollWidth > de.clientWidth) ? de.scrollWidth : de.clientWidth,
						height:(de.scrollHeight > de.clientHeight) ? de.scrollHeight : de.clientHeight}
  }
});

