Branch: refs/heads/main
Home: https://github.com/WebKit/WebKit
Commit: 63168d28d1bc309c8b3608db2d485bcd7cacf9c3
https://github.com/WebKit/WebKit/commit/63168d28d1bc309c8b3608db2d485bcd7cacf9c3
Author: Tyler Wilcock <[email protected]>
Date: 2026-05-21 (Thu, 21 May 2026)
Changed paths:
A
LayoutTests/accessibility/mac/bounds-for-range-on-empty-text-control-expected.txt
A LayoutTests/accessibility/mac/bounds-for-range-on-empty-text-control.html
M Source/WebCore/accessibility/AccessibilityRenderObject.cpp
Log Message:
-----------
AX: When focused on an empty password input, context menu from VO-Shift-M is
opened in the middle of the page rather than next to the input
https://bugs.webkit.org/show_bug.cgi?id=315202
rdar://177531795
Reviewed by Dominic Mazzoni.
NSAccessibilityBoundsForRangeParameterizedAttribute returned a zero-size rect
for the (0, 0) range on empty native text controls, so VoiceOver had no caret
location to anchor the VO-Shift-M context menu and fell back to the middle of
the page.
doAXBoundsForRangeUsingCharacterOffset routed through rangeForCharacterRange,
which has an early return for empty text controls. In this case, fall back to
a visiblePositionForIndex(0)-based rect, rooting the context menu at the
origin of the text control as is expected.
*
LayoutTests/accessibility/mac/bounds-for-range-on-empty-text-control-expected.txt:
Added.
* LayoutTests/accessibility/mac/bounds-for-range-on-empty-text-control.html:
Added.
* Source/WebCore/accessibility/AccessibilityRenderObject.cpp:
(WebCore::AccessibilityRenderObject::doAXBoundsForRangeUsingCharacterOffset
const):
Canonical link: https://commits.webkit.org/313691@main
To unsubscribe from these emails, change your notification settings at
https://github.com/WebKit/WebKit/settings/notifications