MegaZine = {
	movieID:"wobookflash",
	movieObj:null,
	tmrStats:null,
	zoomOpen:false,
	recPageStats:function(page){
		if(page > 0) WB_FlashCall("Statistics", "page", page);
		if(page < WB.pages) WB_FlashCall("Statistics", "page", page + 1);
	},
	onStatusChange:function(state,prevstate){
		if(state == "status_ready"){
			WB_FlashCall("Statistics", "page", 1);
		}
	},
	onPageChange:function(page){
		if(!this.zoomOpen){
			if(this.tmrStats) clearTimeout(this.tmrStats);
			this.tmrStats = setTimeout("MegaZine.recPageStats("+page+")", 500);
		}
	},
	onZoomChanged:function(page){
		if(this.zoomOpen) {
			WB_FlashCall("Statistics", "zoom", page + 1)
		}
	},
	onZoomStatusChange:function(state,prevstate,page){
		this.zoomOpen = state == "zoom_status_open";
		this.onZoomChanged(page);
	},
	onMute:function(){},
	onUnmute:function(){},
	onSlideStop:function(){},
	onSlideStart:function(){},
	onFlipStatusChange:function(state,prevstate){},

	getMovie			:function(){if(this.movieObj==null)this.movieObj=document.getElementById(this.movieID);return this.movieObj},
	getCurrentAnchor	:function(){return this.getMovie().getCurrentAnchor();},
	getCurrentPage		:function(){return this.getMovie().getCurrentPage();},
	isDraggingEnabled	:function(){return this.getMovie().isDraggingEnabled();},
	setDraggingEnabled	:function(enable){this.getMovie().setDraggingEnabled(enable);},
	isMuted				:function(){return this.getMovie().isMuted();},
	setMuted			:function(mute){this.getMovie().setMuted(mute);},
	getPageAnchor		:function(page){return this.getMovie().getPageAnchor(page);},
	getPageCount		:function(){return this.getMovie().getPageCount();},
	getPageHeight		:function(){return this.getMovie().getPageHeight();},
	getPageWidth		:function(){return this.getMovie().getPageWidth();},
	getStatus			:function(){return this.getMovie().getStatus();},
	getFlipStatus		:function(){return this.getMovie().getFlipStatus();},
	getZoomStatus		:function(){return this.getMovie().getZoomStatus();},
	hasReflection		:function(){return this.getMovie().hasReflection();},
	setReflection		:function(enabled){this.getMovie().setReflection(enabled);},
	hasShadows			:function(){return this.getMovie().hasShadows();},
	setShadows			:function(enabled){this.getMovie().setShadows(enabled);},
	gotoAnchor			:function(id,instant){if(instant==null)instant=false;this.getMovie().gotoAnchor(id,instant);},
	gotoPage			:function(page,instant){if(instant==null)instant=false;this.getMovie().gotoPage(page,instant);},
	firstPage			:function(instant){if(instant==null)instant=false;this.getMovie().firstPage(instant);},
	lastPage			:function(instant){if(instant==null)instant=false;this.getMovie().lastPage(instant);},
	nextPage			:function(instant){if(instant==null)instant=false;this.getMovie().nextPage(instant);},
	prevPage			:function(instant){if(instant==null)instant=false;this.getMovie().prevPage(instant);},
	slideStart			:function(){this.getMovie().slideStart();},
	slideStop			:function(){this.getMovie().slideStop();},
	zoomIn				:function(){return this.getMovie().zoomIn();},
	zoomOut				:function(){return this.getMovie().zoomOut();},
	openZoom			:function(galleryOrPath,page,number){if(page==null)page=-1;if(number==null)number=0;this.getMovie().openZoom(galleryOrPath,page,number);}
};

