Add touch-down event to simulated and watch inputs

This commit is contained in:
James Babcock committed 2026-09-28 02:34:08 -07:00
1 parent 45d2ece0d2
commit 2052e268b0
19 files changed
+191 -35

No files matched your search

+12
View File
@@ -1838,6 +1838,8 @@ class DashboardController {
* test buttons, the watch). "long-press" is a complete short hold;
* "long-press-start" / "long-press-release" let a source with a real
* finger-down/finger-up (the watch) hold for as long as the user does.
* Such a source also sends "ring-press" at each finger-down, as the ring
* does before it knows which gesture the touch will become.
*/
async injectSyntheticRingInput(kind: WearRemoteInputKind, origin: SyntheticInputOrigin = "ring"): Promise<void> {
// Match the ring while the display is dark: a double-click wakes it
@@ -2831,6 +2833,7 @@ class DashboardController {
private buildSyntheticRingInput(
kind:
| "ring-press"
| "click"
| "double-click"
| "scroll-up"
@@ -2879,6 +2882,15 @@ class DashboardController {
systemExitReasonCode: 0,
frameId,
};
case "ring-press":
return {
kind: "sys-event",
containerName: "",
eventType: OsEventTypeList.RING_PRESS_EVENT,
eventSource,
systemExitReasonCode: 0,
frameId,
};
case "long-press":
return {
kind: "sys-event",