movePointerBy

Function

Common

Deprecated Replaced by TouchInjectionScope. Use performTouchInput instead of performGesture

fun GestureScope.movePointerBy(pointerId: Int, delta: Offset) =
    delegateScope.touch { updatePointerBy(pointerId, delta) }

Moves the position of the pointer with the given pointerId by the given delta, but does not send a move event. The move event can be sent with move.

If the pointer is not yet down, an IllegalArgumentException will be thrown.

Parameters

pointerIdThe id of the pointer to move, as supplied in down
deltaThe position for this move event, relative to the last sent position of the pointer. For example, `delta = Offset(10.px, -10.px) will add 10.px to the pointer's last x-position, and subtract 10.px from the pointer's last y-position.