Fixed Gamepad issue that incorrectly checked non-webkit prefix gamepads.

This commit is contained in:
photonstorm 2014-05-26 22:02:53 +01:00
parent cd963242cd
commit f007a77f3d
2 changed files with 2 additions and 1 deletions

View file

@ -69,6 +69,7 @@ Version 2.0.6 - "Jornhill" - -in development-
* Sprite.alive property now explicitly defined on the Sprite prototype (thanks @lewster32, #841)
* BitmapData.resize now properly updates the baseTexture and texture dimensions.
* Fixed Gamepad issue that incorrectly checked non-webkit prefix gamepads.
### Migration Guide

View file

@ -226,7 +226,7 @@ Phaser.Gamepad.prototype = {
*/
_pollGamepads: function () {
var rawGamepads = navigator.getGamepads || (navigator.webkitGetGamepads && navigator.webkitGetGamepads()) || navigator.webkitGamepads;
var rawGamepads = navigator.getGamepads() || (navigator.webkitGetGamepads && navigator.webkitGetGamepads()) || navigator.webkitGamepads;
if (rawGamepads)
{