Branch: refs/heads/main
Home: https://github.com/WebKit/WebKit
Commit: be5630f6e9415e204e4e213c73d6706d4302070c
https://github.com/WebKit/WebKit/commit/be5630f6e9415e204e4e213c73d6706d4302070c
Author: Tyler Wilcock <[email protected]>
Date: 2026-09-05 (Sat, 05 Sep 2026)
Changed paths:
M LayoutTests/accessibility/base-select-option-press-closes-popover.html
A
LayoutTests/accessibility/isolated-tree/base-select-option-press-closes-popover.html
M LayoutTests/resources/accessibility-helper.js
M Source/WebCore/accessibility/AXObjectCache.cpp
Log Message:
-----------
AX: In isolated tree mode, a base-appearance select's value lags behind its
popover collapsing
https://bugs.webkit.org/show_bug.cgi?id=323332
rdar://186574679
Reviewed by Dominic Mazzoni.
Pressing an option in a base-appearance select through the accessibility API
publishes two facts about the same widget on two different channels.
AXProperty::IsExpanded is queued from the ExpandedChanged case of
updateIsolatedTree, which runs off the notification post timer, while
AXProperty::StringValue is only refreshed by handleMenuListValueChanged, which
deferMenuListValueChange defers to performDeferredCacheUpdate.
The result is that the isolated tree reports the popover as collapsed while its
value still
names the previously selected option, so a client that reads the value in
response to the collapse, which is what VoiceOver does, announces the wrong
option.
Fix this by queueing the value update in onSelectedOptionChanged, which runs
synchronously with
the selection change, so it lands in the same commit as IsExpanded rather than
two commits later.
318871@main landed
LayoutTests/accessibility/isolated-tree/base-select-option-press-closes-popover-expected.txt
without the corresponding .html, since the test did not pass with the isolated
tree enabled. Add the missing .html now that it does. The existing baseline is
already correct.
The same expanded-before-contents split affects the test's setup: the select
reports itself expanded before the popover's newly rendered options have been
committed to the isolated tree, so findBaseSelectMenu can hand back a menu with
no children and menu.childAtIndex(0) is null. Add waitForBaseSelectMenu, which
polls until the menu has its options, and use it in both copies of the test so
they stay in sync.
* LayoutTests/accessibility/base-select-option-press-closes-popover.html:
*
LayoutTests/accessibility/isolated-tree/base-select-option-press-closes-popover.html:
Added.
* LayoutTests/resources/accessibility-helper.js:
(waitForBaseSelectMenu):
* Source/WebCore/accessibility/AXObjectCache.cpp:
(WebCore::AXObjectCache::onSelectedOptionChanged):
Canonical link: https://commits.webkit.org/320563@main
To unsubscribe from these emails, change your notification settings at
https://github.com/WebKit/WebKit/settings/notifications