53 lines
2.8 KiB
Markdown
53 lines
2.8 KiB
Markdown
# Browser Find
|
|
|
|
Ctrl+F opens the browser's native Find interface. Cthulhu must announce its
|
|
entry and release browse-mode keys so typing and navigation reach Find.
|
|
|
|
Chromium/Brave exposes Find as an AT-SPI frame nested beneath its main frame.
|
|
The inner frame has no independent X11 window or ACTIVE state. Taking that
|
|
inner frame as the window owner caused foreground filtering to discard Find's
|
|
focus and typing events, leaving browse-mode grabs active. Window ancestry now
|
|
resolves the enclosing frame, including nested frames in the same provider.
|
|
Separate application windows still undergo the existing foreground checks.
|
|
|
|
## Automated checks
|
|
|
|
```sh
|
|
CTHULHU_NATIVE_BROWSER_TESTS=find,keys,modes,menu,tabs,flat-chrome,document python3 tests/native_browser.py
|
|
CTHULHU_FIREFOX_FIND=1 python3 tests/native_firefox.py
|
|
go test ./internal/atspi ./internal/input ./internal/app -count=1
|
|
go vet ./internal/atspi ./internal/app
|
|
python3 tests/native_test_session.py env GOCACHE=/tmp/cthulhu-cache CTHULHU_NATIVE_PANEL_APPLET=1 CTHULHU_NATIVE_PANEL_MENU=1 CTHULHU_NATIVE_BACKGROUND_EVENTS=1 go test ./internal/atspi ./internal/app -run '^TestNative(EmbeddedPanelApplet|MatePanelMenu|BackgroundEventFiltering)' -count=1 -p=1 -timeout=90s -v
|
|
```
|
|
|
|
The Find proof uses private Xvfb, D-Bus and browser profiles. It checks Find
|
|
entry speech, browse-key release, typing a structural-navigation letter,
|
|
Tab/Shift+Tab, Escape, restored caret/heading commands and reopening Find.
|
|
It records requests without producing audible speech.
|
|
|
|
## Live acceptance
|
|
|
|
With a rebuilt reader, check Brave and Firefox separately:
|
|
|
|
1. Open a normal webpage, navigate by heading and arrow, and press Ctrl+F.
|
|
Confirm that Find is announced.
|
|
2. Type a phrase containing browse keys such as H, F or L. Confirm the phrase
|
|
reaches Find. Try Enter/Shift+Enter, Tab and Shift+Tab through its controls.
|
|
3. Press Escape. Confirm reading and heading navigation work, then reopen Find.
|
|
4. Check address-bar typing, browser menus and switching tabs/windows. Keep a
|
|
second browser window in the background and confirm its updates stay quiet.
|
|
5. With Braille, check Find's label, entered text and return to document content.
|
|
|
|
Installed-reader, physical-keyboard, audible-speech and physical-Braille
|
|
acceptance remain separate from these automated checks.
|
|
|
|
## Separate Firefox follow-up
|
|
|
|
The expanded proof also reproduced a heading-label problem after typing in
|
|
Find, closing it, pressing Ctrl+Home, then H: Firefox can announce only
|
|
"heading level 2" for the fixture's "Searchable destination" heading.
|
|
The same failure was reproduced using the original `adapter_events.c` from
|
|
commit `1074904` through a Go build overlay. It predates this ancestry fix.
|
|
The Find proof checks the heading level to verify restored command ownership;
|
|
it does not establish correct heading text or full Find-result presentation.
|