sgraham/gamepad.js — pull request #7 by panzi (2012-08-09 00:46:10+00:00)
Title: added XBox controller mapping for Chrome under Linux

The XBox controller has the same layout under Linux as under Windows (in Chrome - couldn't get gamepads to work with Firefox), except it exposes one button more: the XBox button. I just mapped it like this: `into.xboxButton = raw.buttons[16];` I guess this button has a special function and cannot be used under Windows? Under Linux it's a button as any other.

Also I've fixed a typo (on one place `raw` was written as `Raw`), added missing semicolons (`;`) and limited the framerate of the example to 30fps in order to reduce CPU usage.