//按键盘返回键控代码
package
{
import flash.display.Sprite;
import flash.events.KeyboardEvent;
public class Main extends Sprite
{
public function Main()
{
stage.focus = this;
addEventListener(KeyboardEvent.KEY_DOWN, onKeyDown);
}
private function onKeyDown(event:KeyboardEvent):void
{
trace("key down: " + event.charCode);
}
}
}
page 13 KeyBoardEvent
最新推荐文章于 2020-11-25 17:10:29 发布