Title: [139077] trunk
Revision
139077
Author
[email protected]
Date
2013-01-08 10:40:12 -0800 (Tue, 08 Jan 2013)

Log Message

AX: PopUpButtons do not report that AXValueAttribute is supported
https://bugs.webkit.org/show_bug.cgi?id=106333

Reviewed by Ryosuke Niwa.

Source/WebCore: 

The Mac platform expects that AXPopUpButton's expose the AXValue attribute.

Test: platform/mac/accessibility/popup-button-exposes-axvalue.html

* accessibility/AccessibilityObject.h:
(WebCore::AccessibilityObject::isPopUpButton):
* accessibility/mac/WebAccessibilityObjectWrapper.mm:
(-[WebAccessibilityObjectWrapper additionalAccessibilityAttributeNames]):

LayoutTests: 

* platform/mac/accessibility/popup-button-exposes-axvalue-expected.txt: Added.
* platform/mac/accessibility/popup-button-exposes-axvalue.html: Added.

Modified Paths

Added Paths

Diff

Modified: trunk/LayoutTests/ChangeLog (139076 => 139077)


--- trunk/LayoutTests/ChangeLog	2013-01-08 18:34:38 UTC (rev 139076)
+++ trunk/LayoutTests/ChangeLog	2013-01-08 18:40:12 UTC (rev 139077)
@@ -1,3 +1,13 @@
+2013-01-08  Chris Fleizach  <[email protected]>
+
+        AX: PopUpButtons do not report that AXValueAttribute is supported
+        https://bugs.webkit.org/show_bug.cgi?id=106333
+
+        Reviewed by Ryosuke Niwa.
+
+        * platform/mac/accessibility/popup-button-exposes-axvalue-expected.txt: Added.
+        * platform/mac/accessibility/popup-button-exposes-axvalue.html: Added.
+
 2013-01-08  Dimitri Glazkov  <[email protected]>
 
         Update expectations for fast/text/justify-ideograph*.

Added: trunk/LayoutTests/platform/mac/accessibility/popup-button-exposes-axvalue-expected.txt (0 => 139077)


--- trunk/LayoutTests/platform/mac/accessibility/popup-button-exposes-axvalue-expected.txt	                        (rev 0)
+++ trunk/LayoutTests/platform/mac/accessibility/popup-button-exposes-axvalue-expected.txt	2013-01-08 18:40:12 UTC (rev 139077)
@@ -0,0 +1,11 @@
+This tests that pop up buttons expose the AXValue attribute.
+
+On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
+
+
+PASS popup.isAttributeSupported('AXValue') is true
+PASS ariaPopup.isAttributeSupported('AXValue') is true
+PASS successfullyParsed is true
+
+TEST COMPLETE
+

Added: trunk/LayoutTests/platform/mac/accessibility/popup-button-exposes-axvalue.html (0 => 139077)


--- trunk/LayoutTests/platform/mac/accessibility/popup-button-exposes-axvalue.html	                        (rev 0)
+++ trunk/LayoutTests/platform/mac/accessibility/popup-button-exposes-axvalue.html	2013-01-08 18:40:12 UTC (rev 139077)
@@ -0,0 +1,34 @@
+<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML//EN">
+<html>
+<head>
+<script src=""
+</head>
+<body id="body">
+
+<select id="popup"><option>1</option><option>2</option></select>
+<div id="aria-popup" role="button" aria-haspopup="true">popup</div>
+
+<p id="description"></p>
+<div id="console"></div>
+
+<script>
+
+    description("This tests that pop up buttons expose the AXValue attribute.");
+
+    if (window.accessibilityController) {
+
+          var popup = accessibilityController.accessibleElementById("popup");
+          shouldBeTrue("popup.isAttributeSupported('AXValue')");
+
+          var ariaPopup = accessibilityController.accessibleElementById("aria-popup");
+          shouldBeTrue("ariaPopup.isAttributeSupported('AXValue')");
+
+          document.getElementById("aria-popup").style.display = "none";
+          document.getElementById("popup").style.display = "none";
+    }
+
+</script>
+
+<script src=""
+</body>
+</html>

Modified: trunk/Source/WebCore/ChangeLog (139076 => 139077)


--- trunk/Source/WebCore/ChangeLog	2013-01-08 18:34:38 UTC (rev 139076)
+++ trunk/Source/WebCore/ChangeLog	2013-01-08 18:40:12 UTC (rev 139077)
@@ -1,3 +1,19 @@
+2013-01-08  Chris Fleizach  <[email protected]>
+
+        AX: PopUpButtons do not report that AXValueAttribute is supported
+        https://bugs.webkit.org/show_bug.cgi?id=106333
+
+        Reviewed by Ryosuke Niwa.
+
+        The Mac platform expects that AXPopUpButton's expose the AXValue attribute.
+
+        Test: platform/mac/accessibility/popup-button-exposes-axvalue.html
+
+        * accessibility/AccessibilityObject.h:
+        (WebCore::AccessibilityObject::isPopUpButton):
+        * accessibility/mac/WebAccessibilityObjectWrapper.mm:
+        (-[WebAccessibilityObjectWrapper additionalAccessibilityAttributeNames]):
+
 2013-01-08  Alexis Menard  <[email protected]>
 
         transition-delay and transition-duration return incorrect values when querying using the computed style.

Modified: trunk/Source/WebCore/accessibility/AccessibilityObject.h (139076 => 139077)


--- trunk/Source/WebCore/accessibility/AccessibilityObject.h	2013-01-08 18:34:38 UTC (rev 139076)
+++ trunk/Source/WebCore/accessibility/AccessibilityObject.h	2013-01-08 18:40:12 UTC (rev 139077)
@@ -426,6 +426,7 @@
     bool isCheckboxOrRadio() const { return isCheckbox() || isRadioButton(); }
     bool isScrollView() const { return roleValue() == ScrollAreaRole; }
     bool isCanvas() const { return roleValue() == CanvasRole; }
+    bool isPopUpButton() const { return roleValue() == PopUpButtonRole; }
     bool isBlockquote() const;
     bool isLandmark() const;
     

Modified: trunk/Source/WebCore/accessibility/mac/WebAccessibilityObjectWrapper.mm (139076 => 139077)


--- trunk/Source/WebCore/accessibility/mac/WebAccessibilityObjectWrapper.mm	2013-01-08 18:34:38 UTC (rev 139076)
+++ trunk/Source/WebCore/accessibility/mac/WebAccessibilityObjectWrapper.mm	2013-01-08 18:40:12 UTC (rev 139077)
@@ -1007,6 +1007,10 @@
     // All objects should expose the ARIA busy attribute (ARIA 1.1 with ISSUE-538).
     [additional addObject:NSAccessibilityARIABusyAttribute];
     
+    // Popup buttons on the Mac expose the value attribute.
+    if (m_object->isPopUpButton())
+        [additional addObject:NSAccessibilityValueAttribute];
+
     if (m_object->ariaHasPopup())
         [additional addObject:NSAccessibilityHasPopupAttribute];
     
_______________________________________________
webkit-changes mailing list
[email protected]
http://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to