Input.synthesizePinchGestureSynthesizes a pinch gesture over a time period by issuing appropriate touch events.
| Name | Type | Description |
|---|---|---|
x | number | X coordinate of the start of the gesture in CSS pixels. |
y | number | Y coordinate of the start of the gesture in CSS pixels. |
scaleFactor | number | Relative scale factor after zooming (>1.0 zooms in, <1.0 zooms out). |
relativeSpeed (optional) | integer | Relative pointer speed in pixels per second (default: 800). |
gestureSourceType (optional) | GestureSourceType | Which type of input events to be generated (default: 'default', which queries the platform for the preferred input type). |
{
"id": 1,
"method": "Input.synthesizePinchGesture",
"params": {
"x": 100,
"y": 100,
"scaleFactor": 1.0
}
}
{
"id": 1,
"result": {}
}
const result = await send('Input.synthesizePinchGesture', {"x": 100, "y": 100, "scaleFactor": 1.0});
console.log(result);