[Reland] Synthetic gestures wait on renderer ACK.

Currently, synthetic gestures invoke the "completed callback" as soon as
the final gesture has been dispatched. This causes issues in client
code, typically tests, that want to wait until the effects of a gesture
are complete before sending further input or checking page state.

This CL is the first step in a series of CLs to make this completion
callback reliable. We add a new API in the renderer that resolves the
completion callback once the input has been fully processed by the
renderer. For now, this method just ACKs immediately but its
implementation will be further fleshed out in a followup CL.

Reland Node:
This was reverted in
https://crrev.com/d3d4d7c7480b4424a8d009194dd14405654843a4 due to
causing failures on the LeakDetector bot. The leaks were a result of
tests finishing before the synthetic gesture had completed. I've
modified these tests (in wpt/pointerevents) to wait until the guesture
is completed before finishing the test.

TBR=dtapuska@chromium.org,rsesek@chromium.org,avi@chromium.org

Bug: 902446
Change-Id: I6a6a517a719616b2536538686fa4d7b980f0b485
Reviewed-on: https://chromium-review.googlesource.com/c/1424219
Reviewed-by: David Bokan <bokan@chromium.org>
Commit-Queue: David Bokan <bokan@chromium.org>
Cr-Commit-Position: refs/heads/master@{#624496}
40 files changed