我如何在ios的应用程序中添加as3中的文本? 为什么代码不起作用:
import flash.display.Sprite;
import flash.text.TextField;
public class book extends Sprite
{
public function book()
{
var greetingText:TextField = new TextField();
greetingText.text = "Hello World!";
var textContainer:Sprite = new Sprite();
textContainer.scaleX = 10;
textContainer.scaleY = 10;
textContainer.addChild(greetingText);
addChild(textContainer);
}
}
谢谢!