我必须在舞台上连续地来回摆动一个形状而不更新它。实际上我正在使用adobe flash pro cs6将flash转换为html,并且createjs和flash包含一个箭头,下一个按钮中的箭头不断来回移动 这里是我正在转换的flash的链接。 https://dl.dropboxusercontent.com/u/79167545/sp_dla_dominican_photo_album_p2.swf
答案 0 :(得分:2)
简短的回答:你没有。
您可以在不更新舞台的情况下勾选动画,但之后您将无法看到它。
如果你想将它绘制到屏幕上,你将不得不使用stage.update()
- 这就是调用所有绘图/渲染更新的内容。
FlashJ中的框架概念在CreateJS中不存在于该形式中。我的猜测是你在.swf文件中使用gotoAndStop(...)
按钮,这是正确的吗? - 如果是这样,则无法使用CreateJS阶段完成此操作。如果你想用CreateJS做到这一点你必须使用MovieClip(但是,这不是那么优雅) - 但我的建议是让对象像这样:
Stage
├─ Page1 (createjs.Container)
│ ├─ Contents [Bitmap, MovieClip, Shape, whatever...]
│ └─ Button (animated, with eventListener:click -> Page1.visible = false; Page2.visible = true;
└─ Page2 (createjs.Container)
├─ Contents [Bitmap, MovieClip, Shape, whatever...]
└─ Button (animated, with eventListener:click -> Page2.visible = false; Page1.visible = true;