Skip to content

macOS engine: a click on the app's own window over the observed one is refused, not landed under it (#452, #337) - #455

Merged
SSFSKIM merged 12 commits into
mainfrom
fix/452-same-app-overlay
Nov 21, 2026
Merged

SSFSKIM merged 12 commits into
mainfrom
fix/452-same-app-overlay

Conversation

@SSFSKIM

@SSFSKIM SSFSKIM commented Nov 21, 2026

Copy link
Copy Markdown
Owner

Closes #452. Closes #337. Version 0.28.23. Design rulings 928 and 940.

The bug

Chrome's omnibox suggestion list is a separate Chrome window, layered over the browser window. The engine stamps every pointer post with the observed window's id (stampWindow), so a click on a suggestion row went to the browser window beneath:

The fix

Before anything is posted, in every mode, the stale-point guard refuses appWindowOverPoint in two cases:

  • (a) by: "axHit": the app's AX hit at the point is in another window of the same app, at any layer, and the on-screen list confirms that window covers the point. It must be listed, have alpha above 0, have bounds that hold the point, and sit in front of the observed window.
  • (b) by: "popover": the hit is under an AXPopover in the observed window, and a same-app, same-layer window is over the point.

In all other cases, main's verdict stands. That includes:

  • click-through bubbles and cards, whose hit is an ordinary element of the observed window;
  • a hit that fails, can't be read, or runs past the signal's 500 ms deadline;
  • a hit under an observed sheet;
  • a hit whose window is transparent, unlisted, or no longer over the point.

#288's re-hit carries its own outcome. The refusal sentence names the app's own window and the way through: keys, or a fresh screenshot and a target from the tree. Meta: stalePoint.reason, by, overWindow, and hitMs on every coordinate click. The model-facing docs and the Decision Log are updated.

Evidence

docs/evidence/2026-11-20-same-app-overlay/README.md. Kit probe/337-measure, README 50e267c5. Main is 0469183; the fix is bbe42e2 (the head adds only the evidence commit). Run 44837693749 for the fix, and 44822312301, 44805302760 and 44816112944 for main.

Refused where main misdelivered or blamed the page:

  • omnibox popup, all modes;
  • <datalist> popup at layer 999;
  • permission bubble;
  • TextEdit's colour-well popover. Main landed that click in the text beneath, 15/15.

At parity with main:

  • Chrome's status bubble and tab hover card (click-through): land 5/5 each. The first head refused these, which is why the rule was rebuilt on the hit-test signal.
  • layer-101 menus;
  • the save panel;
  • the permission bubble when it is itself the observed window;
  • the two-window cells;
  • every outside click.

Cost: Chrome stalePoint.ms p50/p95 is 1.72/5.22 against main's 1.67/7.91. hitMs is 2.53/4.93; it times main's own hit-test and isn't counted in stalePoint.ms.

Review: reviewer-high on 023a3be found 2 P1s and 4 P2s. Five were fixed in e98276d. The sixth, the overlay guard on the element route's post-wait recheck, is main-existing and is recorded in tech-debt-tracker.md. The re-review found 1 P1 and 1 P2, fixed in bbe42e2, and the review was stopped there. swift test: 1512 run, 0 failures, 1 skipped.

Limits

Sminos-Session: cursor235#b93055dd (cua on macbook)

…ed one, is refused before anything is posted (refs #452)

Design ruling 928. The pointer's events are posted to the process stamped with the observed window, so Chrome
delivered a click on its omnibox popup to the page under it. The stale-point guard now refuses, after #316's rule W
and before the tree, when the app's topmost window at the point (its own windows at the observed window's layer,
alpha above 0, front to back down to the observed one) is not the observed window, with `appWindowOverPoint` and
the window's number in `stalePoint.overWindow`. The window list is read whenever the click's window has a number.

Sminos-Session: cursor235#b93055dd (cua on macbook)
…'s names that window, not the page (refs #337)

`windowHit` answers a hit in another of the app's windows as its own outcome with that window's number
(`stalePoint.hitWindow`); the action still takes it as no hit, and #282's shared-mode refusal then answers with
#452's sentence instead of blaming the page, for a case the window list missed.

Sminos-Session: cursor235#b93055dd (cua on macbook)
…Log, and the meta's new fields (refs #452)

Sminos-Session: cursor235#b93055dd (cua on macbook)
… is refused, not landed under it (refs #452)

Sminos-Session: cursor235#b93055dd (cua on macbook)
…screenshot's is refused, and the way through (refs #452)

One sentence after the stale-point paragraph's "also refuses" sentence, in agent-cursor.md, the test's expected text
and the parity docs oracle; the surface inventory's Table 3 amendment and PROVENANCE.md record it.

Sminos-Session: cursor235#b93055dd (cua on macbook)
…lick-through bubbles keep and Chrome's datalist popup refuses (refs #452)

The qualification of 5f85ffc (kit probe/337-measure README ac80594) found the window-list rule refusing clicks main
lands on Chrome's status bubble and tab hover card, and missing the <datalist> popup at layer 999. Design rulings 928
and 940: refuse when the app's hit-test answers in another of its windows, at any layer (`by: axHit`), or in an
AXPopover of the observed window with a window of the app's over the point in the list (`by: popover`); keep main's
verdict otherwise, a failed hit and one past 500 ms included. The hit-test's time rides as `stalePoint.hitMs`; the
window list is read only for rule W or a popover; `hitWindow` and #282's overlay branch are gone, (a) refusing first.

Sminos-Session: cursor235#b93055dd (cua on macbook)
…nd the meta's `by` and `hitMs` (refs #452)

Sminos-Session: cursor235#b93055dd (cua on macbook)
…se a click, and #330's pass-through sentence goes (refs #452)

Sminos-Session: cursor235#b93055dd (cua on macbook)
…ow keeps, the signal is the last hit-test's, an observed sheet is recognised (refs #452)

The review of 0469183..023a3be: (1) the axHit refusal needs the hit's window on screen in the window list with alpha
above 0 (run 44822312301's window 44, alpha 0), any layer; unlisted or unnumbered keeps main's verdict. (2) The guard
reads the outcome of the hit-test whose hit it judges (`LatestHit`, #288's last re-hit), not element equality. (3)
`windowHit` meets the observed target whatever its role (an AXSheet, run 44816112944). (4) The element-only hit-test
numbers no window; the timed one reads the frame only where the SPI gives no number, bounded by the deadline left.
(5) An element route's record carries `hitMs`.

Sminos-Session: cursor235#b93055dd (cua on macbook)
…nt route's recheck without the overlay guard logged (refs #452)

Sminos-Session: cursor235#b93055dd (cua on macbook)
…rame is read against an absolute cutoff (refs #452)

The re-review of 023a3be..e98276d: (1) the axHit refusal needs the hit's window, in the list already read, to hold
the point and, the observed window listed, to lie in front of it at any layer (`hitWindowCovers`); otherwise main's
verdict. (2) Another window's frame is read before an absolute cutoff, checked after the SPI's attempt and before
each of the position and size reads, each asked with what is left (`boundedFrame`); none once it has passed.

Sminos-Session: cursor235#b93055dd (cua on macbook)
…against the final head (refs #452)

Sminos-Session: cursor235#b93055dd (cua on macbook)
@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Nov 21, 2026 •

Copy link
Copy Markdown
Codex Review Summary: ✅ Completed

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-11-21T00:27:16.603009Z ffa6bcc PR opened
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

1 participant