[webkit-changes] [WebKit/WebKit] 27a08b: AX: VoiceOver is reading standard time instead of ...

AndresGonzalezApple noreply at github.com
Mon Mar 18 13:35:52 PDT 2024


  Branch: refs/heads/main
  Home:   https://github.com/WebKit/WebKit
  Commit: 27a08be942a4d169a735ff4b7136cfed2eed80d5
      https://github.com/WebKit/WebKit/commit/27a08be942a4d169a735ff4b7136cfed2eed80d5
  Author: Andres Gonzalez <andresg_22 at apple.com>
  Date:   2024-03-18 (Mon, 18 Mar 2024)

  Changed paths:
    M LayoutTests/accessibility/datetime/input-time-label-value-expected.txt
    M LayoutTests/accessibility/datetime/input-time-label-value.html
    A LayoutTests/platform/ios/accessibility/datetime/input-time-label-value-expected.txt
    M LayoutTests/platform/mac-ventura/accessibility/datetime/input-time-label-value-expected.txt
    M Source/WebCore/accessibility/AXCoreObject.h
    M Source/WebCore/accessibility/AccessibilityNodeObject.cpp
    M Source/WebCore/accessibility/AccessibilityObject.h
    M Source/WebCore/accessibility/isolatedtree/AXIsolatedObject.cpp
    M Source/WebCore/accessibility/isolatedtree/AXIsolatedObject.h
    M Source/WebCore/accessibility/isolatedtree/AXIsolatedTree.h
    M Source/WebCore/accessibility/mac/AccessibilityObjectMac.mm
    M Source/WebCore/accessibility/mac/WebAccessibilityObjectWrapperMac.mm
    M Tools/WebKitTestRunner/InjectedBundle/mac/AccessibilityUIElementMac.mm

  Log Message:
  -----------
  AX: VoiceOver is reading standard time instead of daylight savings time in <input type="time"> elements.
https://bugs.webkit.org/show_bug.cgi?id=270988
<rdar://problem/124627373>

Reviewed by Tyler Wilcock.

Corrects the NSDate returned to AX client taking into account the daylight savings status. The correction does not apply to datetime-local fields. This involves the following changes:
- AXIsolatedObjects now cache the DateComponentsType instead of the AXF value requred by VoiceOver.
- The AXFDateTimeComponent value is computed on demand from the DateComponentsType.
- AccessibilityUIElement::dateValue also accounts for daylight savings adjustment.
- The test input-time-label-value.html was expanded to also check not just the UI string representing the time, but the NSDate being sent to VoiceOver.

* LayoutTests/accessibility/datetime/input-time-label-value-expected.txt:
* LayoutTests/accessibility/datetime/input-time-label-value.html:
* LayoutTests/platform/ios/accessibility/datetime/input-time-label-value-expected.txt: Added.
* Source/WebCore/accessibility/AXCoreObject.h:
* Source/WebCore/accessibility/AccessibilityNodeObject.cpp:
(WebCore::AccessibilityObject::dateTimeComponentsType const):
* Source/WebCore/accessibility/AccessibilityObject.h:
* Source/WebCore/accessibility/isolatedtree/AXIsolatedObject.cpp:
(WebCore::AXIsolatedObject::initializeProperties):
(WebCore::AXIsolatedObject::setProperty):
* Source/WebCore/accessibility/isolatedtree/AXIsolatedObject.h:
* Source/WebCore/accessibility/isolatedtree/AXIsolatedTree.h:
* Source/WebCore/accessibility/mac/AccessibilityObjectMac.mm:
(): Deleted.
(WebCore::AccessibilityObject::dateTimeComponents const): Deleted.
* Source/WebCore/accessibility/mac/WebAccessibilityObjectWrapperMac.mm:
(convertToAXFDateTimeComponents):
(gmtToLocalTimeOffset):
(-[WebAccessibilityObjectWrapper accessibilityAttributeValue:]):
* Tools/WebKitTestRunner/InjectedBundle/mac/AccessibilityUIElementMac.mm:
(WTR::AccessibilityUIElement::dateValue):

Canonical link: https://commits.webkit.org/276291@main



To unsubscribe from these emails, change your notification settings at https://github.com/WebKit/WebKit/settings/notifications


More information about the webkit-changes mailing list