I'm developing an ActionScript mobile project for Android.
When I add the following import, compiler says that is not found.
import fl.transitions.Tween;
How can I use Tween with mobile projects?
package{
import开发者_开发百科 flash.display.Sprite;
import flash.text.TextField;
import flash.events.MouseEvent;
import fl.transitions.Tween;
import fl.transitions.easing.Strong;
public class spriteButton extends Sprite
{
private var alphaOver:Tween;
private var alphaLabelOver:Tween;
private var alphaLabel:Tween;
public function spriteButton(newLabel:String)
{
myLabel.text = newLabel;
myLabelOver.text = newLabel;
myLabelOver.alpha = 0;
buttonMode = true;
mouseChildren = false;
addEventListener(MouseEvent.MOUSE_OVER, handleMouseOver);
addEventListener(MouseEvent.MOUSE_OUT, handleMouseOut);
addEventListener(MouseEvent.MOUSE_UP, handleMouseUp);
}
By the way, I'm very new on ActionScript 3.0 development.
I get this errors:
The import fl could not be found.
The import Tween could not be found.
Description Resource Path Location Type
1172: Definition fl.transitions:Tween could not be found. spriteButton.as /Test01/src line 4 Flex Problem
if you are new to AS3, then use this library: http://www.greensock.com/tweenmax/ for tweenning objects.
精彩评论