haikuwebkit/Source/WebCore/platform/gamepad/cocoa
Brady Eidson c6acfc899e HIDGamepadProvider adds an extra 50ms to all inputs
<rdar://70315838> and https://bugs.webkit.org/show_bug.cgi?id=217742

Reviewed by Alex Christensen.

No new tests.
Tried to write an API test to drive inputs in the delay range, but that was way too fragile
on a local developer machine, much less a bot that's under load.

These input delays were an early best-effort to get input to line up with RaF, which the spec
mentions as a goal.

Not sure how 50 slipped in for HID, vs the 16 on GCF.

Whether or not lining up perfectly with RaF is actually a useful goal, in the meantime driving
input as quickly as possible seems much more desirable.

We still want to coalesce multiple close together inputs into 1 logical event to smooth out jitter
with certain devices, and reduce IPC and DOM object churn during rapid input (or with buggy devices).

In testing with what I have on my desk, using a true 0-delay timer for that was not desirable.

But 1ms seems peachy keen.

* platform/gamepad/cocoa/GameControllerGamepadProvider.mm:
* platform/gamepad/mac/HIDGamepadProvider.mm:


Canonical link: https://commits.webkit.org/239333@main
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@279480 268f45cc-cd09-0410-ab3c-d52691b4dbfc
2021-07-01 20:22:16 +00:00
..
GameControllerGamepad.h
GameControllerGamepad.mm
GameControllerGamepadProvider.h
GameControllerGamepadProvider.mm
GameControllerSPI.h
GameControllerSoftLink.h
GameControllerSoftLink.mm