mirror of
https://github.com/servo/servo.git
synced 2025-08-05 05:30:08 +01:00
Gamepad: Align closer to spec and implement missing slots (#31385)
* Implement missing gamepad slots, align to spec more - Fixes TODO's from initial gamepad implementation - Adds some missing spec steps * Only handle gamepad events when pref is enabled * Return empty list in getGamepads if document not active * ./mach fmt * Update getGamepads to return an array instead of GamepadList * Add spec link for [[exposed]] slot * Remove failing test expectations for not-fully-active * A few fixes - Change should_notify to has_gesture - Add spec links and TODO to navigator - Remove unneeded clone from GamepadList::list - Move gamepadconnected event firing into has_gesture block * Use queue_with_canceller for tasks and add expects * Explicitly check for gamepad user gesture * Move user gesture check into separate function * Change contains_user_gesture to be a gamepad function * mach fmt * Change axis/button threshold constants to be private to module
This commit is contained in:
parent
31a50feb4a
commit
48fa77df67
8 changed files with 124 additions and 45 deletions
|
@ -1,3 +0,0 @@
|
|||
[not-fully-active.html]
|
||||
[calling getGamepads() in a non-fully-active document]
|
||||
expected: FAIL
|
|
@ -1,3 +0,0 @@
|
|||
[not-fully-active.html]
|
||||
[calling getGamepads() in a non-fully-active document]
|
||||
expected: FAIL
|
Loading…
Add table
Add a link
Reference in a new issue