Title: [155041] trunk
Revision
155041
Author
[email protected]
Date
2013-09-04 07:19:02 -0700 (Wed, 04 Sep 2013)

Log Message

[ATK] Adds an accessibility support to access a value of the color control element
https://bugs.webkit.org/show_bug.cgi?id=114354

Patch by Krzysztof Czech <[email protected]> on 2013-09-04
Reviewed by Mario Sanchez Prada.

Source/WebCore:

Implements a possibility of retrieving a value of the color control element.

* accessibility/atk/WebKitAccessibleInterfaceText.cpp:
(webkitAccessibleTextGetText):
* accessibility/atk/WebKitAccessibleWrapperAtk.cpp:
(getInterfaceMaskFromObject):

Tools:

Added accessibility role of the color control element.

* DumpRenderTree/atk/AccessibilityUIElementAtk.cpp:
(roleToString):
* WebKitTestRunner/InjectedBundle/atk/AccessibilityUIElementAtk.cpp:
(WTR::roleToString):

LayoutTests:

Moving mac's color-well-expected.txt result to base accessibility folder.
Unskipping accessibility/color-well.html for EFL port.

* accessibility/color-well-expected.txt: Renamed from LayoutTests/platform/mac/accessibility/color-well-expected.txt.
* platform/efl-wk1/TestExpectations:
* platform/efl-wk2/TestExpectations:

Modified Paths

Added Paths

Removed Paths

Diff

Modified: trunk/LayoutTests/ChangeLog (155040 => 155041)


--- trunk/LayoutTests/ChangeLog	2013-09-04 13:59:19 UTC (rev 155040)
+++ trunk/LayoutTests/ChangeLog	2013-09-04 14:19:02 UTC (rev 155041)
@@ -1,3 +1,17 @@
+2013-09-04  Krzysztof Czech  <[email protected]>
+
+        [ATK] Adds an accessibility support to access a value of the color control element
+        https://bugs.webkit.org/show_bug.cgi?id=114354
+
+        Reviewed by Mario Sanchez Prada.
+
+        Moving mac's color-well-expected.txt result to base accessibility folder.
+        Unskipping accessibility/color-well.html for EFL port.
+
+        * accessibility/color-well-expected.txt: Renamed from LayoutTests/platform/mac/accessibility/color-well-expected.txt.
+        * platform/efl-wk1/TestExpectations:
+        * platform/efl-wk2/TestExpectations:
+
 2013-09-04  Zan Dobersek  <[email protected]>
 
         Unreviewed GTK gardening.

Copied: trunk/LayoutTests/accessibility/color-well-expected.txt (from rev 155040, trunk/LayoutTests/platform/mac/accessibility/color-well-expected.txt) (0 => 155041)


--- trunk/LayoutTests/accessibility/color-well-expected.txt	                        (rev 0)
+++ trunk/LayoutTests/accessibility/color-well-expected.txt	2013-09-04 14:19:02 UTC (rev 155041)
@@ -0,0 +1,14 @@
+    
+This test checks the role of ColorWellRolean input with type=color
+
+On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
+
+
+Role of input type=color is: AXRole: AXColorWell
+Value of empty color well: AXValue: rgb 0.00000 0.00000 0.00000 1
+Value of good color well: AXValue: rgb 1.00000 0.00000 0.00000 1
+Value of bad color well: AXValue: rgb 0.00000 0.00000 0.00000 1
+PASS successfullyParsed is true
+
+TEST COMPLETE
+

Modified: trunk/LayoutTests/platform/efl-wk1/TestExpectations (155040 => 155041)


--- trunk/LayoutTests/platform/efl-wk1/TestExpectations	2013-09-04 13:59:19 UTC (rev 155040)
+++ trunk/LayoutTests/platform/efl-wk1/TestExpectations	2013-09-04 14:19:02 UTC (rev 155041)
@@ -175,7 +175,6 @@
 webkit.org/b/112021 accessibility/visible-elements.html [ Failure Crash ]
 
 accessibility/aria-checkbox-sends-notification.html [ Skip ]
-accessibility/color-well.html [ Skip ]
 accessibility/deleting-iframe-destroys-axcache.html [ Skip ]
 accessibility/img-fallsback-to-title.html [ Skip ]
 accessibility/internal-link-anchors2.html [ Skip ]

Modified: trunk/LayoutTests/platform/efl-wk2/TestExpectations (155040 => 155041)


--- trunk/LayoutTests/platform/efl-wk2/TestExpectations	2013-09-04 13:59:19 UTC (rev 155040)
+++ trunk/LayoutTests/platform/efl-wk2/TestExpectations	2013-09-04 14:19:02 UTC (rev 155041)
@@ -252,7 +252,6 @@
 webkit.org/b/112019 accessibility/title-ui-element-correctness.html [ Crash ]
 
 accessibility/aria-checkbox-sends-notification.html [ Skip ]
-accessibility/color-well.html [ Skip ]
 accessibility/deleting-iframe-destroys-axcache.html [ Skip ]
 accessibility/img-fallsback-to-title.html [ Skip ]
 accessibility/internal-link-anchors2.html [ Skip ]

Deleted: trunk/LayoutTests/platform/mac/accessibility/color-well-expected.txt (155040 => 155041)


--- trunk/LayoutTests/platform/mac/accessibility/color-well-expected.txt	2013-09-04 13:59:19 UTC (rev 155040)
+++ trunk/LayoutTests/platform/mac/accessibility/color-well-expected.txt	2013-09-04 14:19:02 UTC (rev 155041)
@@ -1,14 +0,0 @@
-    
-This test checks the role of ColorWellRolean input with type=color
-
-On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
-
-
-Role of input type=color is: AXRole: AXColorWell
-Value of empty color well: AXValue: rgb 0.00000 0.00000 0.00000 1
-Value of good color well: AXValue: rgb 1.00000 0.00000 0.00000 1
-Value of bad color well: AXValue: rgb 0.00000 0.00000 0.00000 1
-PASS successfullyParsed is true
-
-TEST COMPLETE
-

Modified: trunk/Source/WebCore/ChangeLog (155040 => 155041)


--- trunk/Source/WebCore/ChangeLog	2013-09-04 13:59:19 UTC (rev 155040)
+++ trunk/Source/WebCore/ChangeLog	2013-09-04 14:19:02 UTC (rev 155041)
@@ -1,3 +1,17 @@
+2013-09-04  Krzysztof Czech  <[email protected]>
+
+        [ATK] Adds an accessibility support to access a value of the color control element
+        https://bugs.webkit.org/show_bug.cgi?id=114354
+
+        Reviewed by Mario Sanchez Prada.
+
+        Implements a possibility of retrieving a value of the color control element.
+
+        * accessibility/atk/WebKitAccessibleInterfaceText.cpp:
+        (webkitAccessibleTextGetText):
+        * accessibility/atk/WebKitAccessibleWrapperAtk.cpp:
+        (getInterfaceMaskFromObject):
+
 2013-09-04  Andreas Kling  <[email protected]>
 
         Use Vector<Ref<T>> in three random WebCore loops.

Modified: trunk/Source/WebCore/accessibility/atk/WebKitAccessibleInterfaceText.cpp (155040 => 155041)


--- trunk/Source/WebCore/accessibility/atk/WebKitAccessibleInterfaceText.cpp	2013-09-04 13:59:19 UTC (rev 155040)
+++ trunk/Source/WebCore/accessibility/atk/WebKitAccessibleInterfaceText.cpp	2013-09-04 14:19:02 UTC (rev 155041)
@@ -626,6 +626,14 @@
         }
     }
 
+#if ENABLE(INPUT_TYPE_COLOR)
+    if (coreObject->roleValue() == ColorWellRole) {
+        int r, g, b;
+        coreObject->colorValue(r, g, b);
+        return g_strdup_printf("rgb %7.5f %7.5f %7.5f 1", r / 255., g / 255., b / 255.);
+    }
+#endif
+
     ret = ret.substring(startOffset, end - startOffset);
     return g_strdup(ret.utf8().data());
 }

Modified: trunk/Source/WebCore/accessibility/atk/WebKitAccessibleWrapperAtk.cpp (155040 => 155041)


--- trunk/Source/WebCore/accessibility/atk/WebKitAccessibleWrapperAtk.cpp	2013-09-04 13:59:19 UTC (rev 155040)
+++ trunk/Source/WebCore/accessibility/atk/WebKitAccessibleWrapperAtk.cpp	2013-09-04 14:19:02 UTC (rev 155041)
@@ -1036,6 +1036,12 @@
     if (role == SliderRole || role == SpinButtonRole || role == ScrollBarRole)
         interfaceMask |= 1 << WAI_VALUE;
 
+#if ENABLE(INPUT_TYPE_COLOR)
+    // Color type.
+    if (role == ColorWellRole)
+        interfaceMask |= 1 << WAI_TEXT;
+#endif
+
     return interfaceMask;
 }
 

Modified: trunk/Tools/ChangeLog (155040 => 155041)


--- trunk/Tools/ChangeLog	2013-09-04 13:59:19 UTC (rev 155040)
+++ trunk/Tools/ChangeLog	2013-09-04 14:19:02 UTC (rev 155041)
@@ -1,3 +1,17 @@
+2013-09-04  Krzysztof Czech  <[email protected]>
+
+        [ATK] Adds an accessibility support to access a value of the color control element
+        https://bugs.webkit.org/show_bug.cgi?id=114354
+
+        Reviewed by Mario Sanchez Prada.
+
+        Added accessibility role of the color control element.
+
+        * DumpRenderTree/atk/AccessibilityUIElementAtk.cpp:
+        (roleToString):
+        * WebKitTestRunner/InjectedBundle/atk/AccessibilityUIElementAtk.cpp:
+        (WTR::roleToString):
+
 2013-09-04  Mario Sanchez Prada  <[email protected]>
 
         REGRESSION (r132328): /WebKit2APITests/TestWebKitAccessibility unit test is failing

Modified: trunk/Tools/DumpRenderTree/atk/AccessibilityUIElementAtk.cpp (155040 => 155041)


--- trunk/Tools/DumpRenderTree/atk/AccessibilityUIElementAtk.cpp	2013-09-04 13:59:19 UTC (rev 155040)
+++ trunk/Tools/DumpRenderTree/atk/AccessibilityUIElementAtk.cpp	2013-09-04 14:19:02 UTC (rev 155041)
@@ -104,6 +104,8 @@
         return "AXCanvas";
     case ATK_ROLE_CHECK_BOX:
         return "AXCheckBox";
+    case ATK_ROLE_COLOR_CHOOSER:
+        return "AXColorWell";
     case ATK_ROLE_COLUMN_HEADER:
         return "AXColumnHeader";
     case ATK_ROLE_COMBO_BOX:

Modified: trunk/Tools/WebKitTestRunner/InjectedBundle/atk/AccessibilityUIElementAtk.cpp (155040 => 155041)


--- trunk/Tools/WebKitTestRunner/InjectedBundle/atk/AccessibilityUIElementAtk.cpp	2013-09-04 13:59:19 UTC (rev 155040)
+++ trunk/Tools/WebKitTestRunner/InjectedBundle/atk/AccessibilityUIElementAtk.cpp	2013-09-04 14:19:02 UTC (rev 155041)
@@ -193,6 +193,8 @@
         return "AXCanvas";
     case ATK_ROLE_CHECK_BOX:
         return "AXCheckBox";
+    case ATK_ROLE_COLOR_CHOOSER:
+        return "AXColorWell";
     case ATK_ROLE_COLUMN_HEADER:
         return "AXColumnHeader";
     case ATK_ROLE_COMBO_BOX:
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to