if ((top.TFCStateMapInit == "undefined") || (top.TFCStateMapInit != true))
{
	/**
	*
	* TFCStateMap CLASS definition.
	*
	*/
	
	function TFCStateMap (elementId, docObj){
		this.docObj = docObj;
		this.mapContent = null;
		this.elementId = elementId;
	}

	TFCStateMap.prototype.getMapContent = function(){
		return this.mapContent;
	}

	TFCStateMap.prototype.setMapContent = function(){
		var element = this.docObj.getElementById(this.elementId);
		if (element != null)
			this.mapContent = element.innerHTML;
	}

	/**
	*
	* TFCStateMap ACTION MANAGER definition.
	*
	* Handles user gestures
	*
	*/

	function TFCStateMapActionManager(){}

	TFCStateMapActionManager.handlerList = new Array();

	TFCStateMapActionManager.register = function (handler){
		TFCStateMapActionManager.handlerList[TFCStateMapActionManager.handlerList.length] = handler; 
	}

	TFCStateMapActionManager.doStateMapAction = function(stateCode){
		var len = TFCStateMapActionManager.handlerList.length;
		for(var i=0; i<len; i++){
			TFCStateMapActionManager.handlerList[i].doStateMapAction(stateCode);
		}
	}
	
	//////////////////////////////////////

	top.TFCStateMapInit = true;
}


