device_long_press
Long press at (x,y) on an Android device screen. Triggers context menus, drag handles, and other long-press actions. Coordinates are PHYSICAL pixels (from page_source bounds).Pass input="hid" to require the virtual touchscreen: the gesture then reaches the app as real kernel input and fails loudly instead of silently falling back to injected input. That strict path used to be device_uhid_long_press, which stays callable under its old name.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| x | Yes | X coordinate in physical pixels (from page_source bounds) | |
| y | Yes | Y coordinate in physical pixels (from page_source bounds) | |
| udid | Yes | Device serial number (UDID) | |
| input | No | Input path. 'auto' (default) prefers the virtual touchscreen and falls back to injected input. 'hid' requires the virtual touchscreen and fails if the device does not provide one — use it when the gesture must be real kernel input or must fail loudly. | |
| duration | No | Hold duration in ms (default: 800) |