perf(ios): reuse the resolved window for a fill's content translation

Merged
TH
9d ago
+14-2

Summary

A coordinate fill replacement resolves the app's window for its tap context, then liveContentTranslation queried the windows again in the same command. The content translation now comes from the context's own resolved window, which removes one XCTest windows round (about 3 queries) from every ref/point fill.

The fresh read stays wherever the context does not prove a window origin: no resolved window (sole-screen frame), an unreadable tree, or a lit-panel booking. The off-origin window case from #3899 keeps its proof.

3 runner files, +14/−2.

Validation

  • iOS 27.0 simulator, Bluesky prod app, 3 rounds of search-tab → fill → keyboard enter: the focus phase went from 2 windows rounds / 18 XCTest steps to 1 round / 15 steps; every fill succeeded and verified. Focus took 2.4–2.7 s vs 2.8–2.9 s on base, but the host load average was 300–1000, so wall times are not a clean A/B.
  • Design reviewed read-only by a second model against #3899, #4616 and the text-entry evidence doc; it ranked this the safest fill cut.
  • Local check:affected not run (host load); CI owns the Swift unit and iOS device lanes on the pushed head.

🤖 Generated with Claude Code


Autofix with [code]smith
Open in [code]smith · Need help on this PR? Tag @codesmith-bot with what you need.