Add keyboardManaged#createCursorKeys typedefs

This commit is contained in:
Christian Panadero 2018-04-06 18:17:58 +01:00
parent e0dc28e4ba
commit c08f769351

View file

@ -190,13 +190,24 @@ var KeyboardManager = new Class({
this.target.removeEventListener('keyup', this.handler); this.target.removeEventListener('keyup', this.handler);
}, },
/**
* @typedef {object} CursorKeys
*
* @property {Phaser.Input.Keyboard.Key} [up] - [description]
* @property {Phaser.Input.Keyboard.Key} [down] - [description]
* @property {Phaser.Input.Keyboard.Key} [left] - [description]
* @property {Phaser.Input.Keyboard.Key} [right] - [description]
* @property {Phaser.Input.Keyboard.Key} [space] - [description]
* @property {Phaser.Input.Keyboard.Key} [shift] - [description]
*/
/** /**
* Creates and returns an object containing 4 hotkeys for Up, Down, Left and Right, and also space and shift. * Creates and returns an object containing 4 hotkeys for Up, Down, Left and Right, and also space and shift.
* *
* @method Phaser.Input.Keyboard.KeyboardManager#createCursorKeys * @method Phaser.Input.Keyboard.KeyboardManager#createCursorKeys
* @since 3.0.0 * @since 3.0.0
* *
* @return {object} [description] * @return {CursorKeys} [description]
*/ */
createCursorKeys: function () createCursorKeys: function ()
{ {