Refactor gamepad code
This is !1695 (closed) without the Lua changes. It implements the SDL Game Controller API, haptics, and axis bindings.
This is !1695 (closed) without the Lua changes. It implements the SDL Game Controller API, haptics, and axis bindings.