Expand description
Core pointer resolution: one host-agnostic stage that turns untargeted raw pointer samples
(EventFlags::RAW_POINTER, see nativeview_abi::EventBatchBuf::push_pointer_raw) into the
targeted W3C Pointer Events stream every app sees, on every host.
Per sample the stage runs, in order:
- Top-layer press (primary
PointerDown): the HTML “hide popovers until” walk (super::top_layer_press) emits the light-dismisscloseevents; a press outside the topmost modal is swallowed (PointerOutcomeFlags::MODAL_BARRIER) until it ends. - Hit-test / capture: a captured pointer targets its capture node; otherwise the deepest
interaction target (
PointerHitTest). Captures are W3C: pending targets ([InteractionTracker::pointers_mut]) switch before the pointer’s next sample, emittingLostPointerCapture/GotPointerCapture; touch and pen capture their down target implicitly; acapture_on_primary_downowner (nativeview_engine::ext::input::capture_owner) claims the pointer (PointerOutcomeFlags::CLAIMED). PointerTable+ tracker::hoverfollows the primary hover-capable pointer,:activeandPressthe primary pointer only; a contact beyond the table’s capacity is refused (PointerOutcomeFlags::REFUSED) with aPointerCancel.- Synthesis: non-bubbling
PointerLeave/PointerEntertransitions, the targeted pointer event, capture changes, andPresson a primary release over the press chain.
Resolution is split in two so a hit tester may borrow the scene (or the backend owning it):
PointerProbe::new reads (hits, top-layer decision, capture owner) and
LaidOutScene::apply_pointer mutates the tracker. LaidOutScene::resolve_pointer runs
both against the scene’s own hit test (SurfaceRuntime); the Skia backend probes with its
paint-accurate hit test. Zero heap allocations in steady state.
Structs§
- Pointer
Outcome Flags - What the core pointer-resolution stage did with a batch’s raw samples
(
NV_POINTER_OUTCOME_*, bits 8.. of thedispatch_events_exdisposition word). - Pointer
Probe - The read-only half of resolution (see the module docs).
- Pointer
Resolution - What one raw sample resolved to.
- Scene
Geometry PointerGeometryoverLaidOutScene::visual_rect_of.
Traits§
- Pointer
HitTest - The geometry queries the stage needs. Backends with paint-accurate state (live animated transforms, the painted stacking plan) implement it over their own hit test.