init(s)


    private function init():void {
     stage.addEventListener(KeyboardEvent.KEY_DOWN, onKeyboardEvent);
     stage.addEventListener(KeyboardEvent.KEY_UP, onKeyboardEvent);
    }
  

keyboard(s)


    public function onKeyboardEvent(event:KeyboardEvent):void {
     trace(event.type);
    }
   }
  }