root stage this之间的区别_thisthat区别

2020-02-28 其他范文 下载本文

root stage this之间的区别由刀豆文库小编整理,希望给你工作、学习、生活带来方便,猜你可能喜欢“thisthat区别”。

root stage this之间的区别

var a:Sprite =new Sprite();

a.name=“box”;

addChild(a);

trace(stage.getChildByName(“box”));

输出:null

var a:Sprite =new Sprite();

a.name=“box”;

addChild(a);

trace(root.getChildByName(“box”));

输出:1061: 调用可能未定义的方法 getChildByName(通过 static 类型 flash.display

isplayObject 引用)。

var a:Sprite =new Sprite();

a.name=“box”;

addChild(a);

trace(this.getChildByName(“box”));

输出:[object Sprite]

到底这三者之间有什么区别啊?请教

《root stage this之间的区别.docx》
将本文的Word文档下载,方便收藏和打印
推荐度:
root stage this之间的区别
点击下载文档
相关专题 thisthat区别 区别 root stage thisthat区别 区别 root stage
[其他范文]相关推荐
    [其他范文]热门文章
      下载全文