moveTo

Function

Common

Deprecated Replaced by TouchInjectionScope. Use performTouchInput instead of performGesture

fun GestureScope.moveTo(pointerId: Int, position: Offset) =
    delegateScope.touch { moveTo(pointerId, position) }

Sends a move event on the associated node, with the position of the pointer with the given pointerId updated to position. The position is in the node's local coordinate system, where (0, 0) is the top left corner of the node.

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

Parameters

pointerIdThe id of the pointer to move, as supplied in down
positionThe new position of the pointer, in the node's local coordinate system
Common

Deprecated Replaced by TouchInjectionScope. Use performTouchInput instead of performGesture

fun GestureScope.moveTo(position: Offset) = delegateScope.touch { moveTo(position) }

Sends a move event on the associated node, with the position of the default pointer updated to position. The position is in the node's local coordinate system, where (0, 0) is the top left corner of the node. The default pointer has pointerId = 0.

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

Parameters

positionThe new position of the pointer, in the node's local coordinate system