New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Updating gamepads test to match new spec #646
Conversation
@@ -2,4 +2,5 @@ | |||
// https://dvcs.w3.org/hg/gamepad/raw-file/default/gamepad.html | |||
// By Eric Bidelman | |||
|
|||
Modernizr.addTest('gamepads', !!Modernizr.prefixed('gamepads', navigator)); | |||
Modernizr.addTest('gamepads', !!Modernizr.prefixed('Gamepads', navigator) || | |||
!!Modernizr.prefixed('GetGamepads', navigator)); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
lowercase for both, actually. getGamepads
. prefixed() will uppercase both while it checks for prefixes versions. but the standard unprefixed is targetting lower.
Updating gamepads test to match new spec
pulled. thx. i'm gonna make a note about FF's inability to feature detect. |
Hey Paul, what do you mean by "FF's inability to feature detect"? |
@Ms2ger I mean there is no way to feature detect support for the gamepad API in Firefox. You can only see that gamepad events are firing, but cannot see that the API is available A day after posting the above, I realized that gamepad support is only available in special builds and not even behind a flag in nightly firefox. So it's not a huge deal. Sounds like updating the impl to the newest spec rev will happen soon. |
Oh, because we don't support the navigator property in the initial patch, right. |"GamePad" in window| should work, though. |
IMO we should probably stay way from returning a false positive for FF's implementation. |
Updating gamepads test to match new spec
No description provided.