onPointerEvent
fun Modifier.onPointerEvent(propagation: InputResult, action: UiSession.(PointerEvent, IntOffset) -> Unit): Modifier(source)
Subscribes to typed pointer notifications within the modifier's hit region, including local coordinates. propagation is applied immediately; action runs on the screen owner thread, on the hosting server or proxy for remote screens. Only the subscribed event variant and optional button are delivered or transmitted.
fun Modifier.onPointerEvent(callback: UiSession.(PointerEvent, IntOffset) -> InputResult): Modifier(source)
Handles every typed pointer event that hits this modifier's laid-out bounds.
The callback runs on the owning tree thread in deepest/latest-painted-first dispatch order. Returning InputResult.Consumed stops ordinary event propagation; returning InputResult.Ignored allows earlier candidates to run.
Return
this chain with one appended active pointer-input node.
Parameters
callback
callback receiving the tree event and modifier-local position.