package modules.menu
{
	import classes.fl.motion.easing.Exponential;
	import classes.fl.transitions.easing.Strong;
	import classes.greensock.TweenLite;
	import classes.greensock.TweenMax;
	import classes.greensock.easing.Circ;
	import classes.greensock.easing.Quint;
	import classes.matuto.core.Button;
	import classes.matuto.core.Matuto;
	import classes.matuto.core.module.Module;
	import classes.matuto.model.Model;
	
	import fl.motion.easing.Exponential;
	import fl.motion.easing.Quintic;
	
	import flash.display.MovieClip;
	import flash.display.Sprite;
	import flash.events.Event;
	import flash.geom.Rectangle;
	import flash.utils.setTimeout;

	
	
	public class MenuBotao extends Button 
	{
		
		
		
		public var bgColor:uint;	
		public var textoColor:uint;
		public var iconColor:uint;	
		public var fragment:Class;

		
		
		public function MenuBotao() 
		{
						
		}
		
		
		
		
		public override function over() :void
		{
			
			TweenMax.to(_bg,.3,{tint:bgColor,ease:Exponential.easeInOut});
			TweenMax.to(_texto,.3,{tint:textoColor,ease:Exponential.easeInOut});
			TweenMax.to(_icone,.3,{tint:iconColor,ease:Exponential.easeInOut});
		}
		
		public override function out() :void
		{
			if (enabled) 
			{	
				TweenMax.to(_bg,.3,{tint:null,ease:Exponential.easeInOut});
				TweenMax.to(_texto,.3,{tint:null,ease:Exponential.easeInOut});
				TweenMax.to(_icone,.3,{tint:null,ease:Exponential.easeInOut});
			}
		}
		
		override public function set enabled(value:Boolean):void 
		{			
			super.enabled = value;
			
			if (value)out();
			else over();
		}
		
		
		
		
	}//end class

}