[GTK] accessibility/placeholder.html is failing
https://bugs.webkit.org/show_bug.cgi?id=98373
Patch by Joanmarie Diggs <jdiggs@igalia.com> on 2012-12-09
Reviewed by Martin Robinson.
The test was failing because the placeholder text was not supported and
AccessibilityUIElement::stringAttributeValue() was not implemented.
Source/WebCore:
No new tests; instead the failing test was unskipped.
* accessibility/atk/WebKitAccessibleWrapperAtk.cpp:
(webkitAccessibleGetAttributes): Add the placeholder text as an AtkAttribute
of the AtkObject, as is done in Gtk+ 3.
Tools:
* DumpRenderTree/gtk/AccessibilityUIElementGtk.cpp:
(coreAttributeToAtkAttribute): New convenience method to convert WebCore attribute
names into AtkObject attribute names
(AccessibilityUIElement::stringAttributeValue): implemented
LayoutTests:
* platform/gtk/TestExpectations: Unskip the failing test
git-svn-id: http://svn.webkit.org/repository/webkit/trunk@137099 268f45cc-cd09-0410-ab3c-d52691b4dbfc
diff --git a/Source/WebCore/ChangeLog b/Source/WebCore/ChangeLog
index b455272..ff2232c 100644
--- a/Source/WebCore/ChangeLog
+++ b/Source/WebCore/ChangeLog
@@ -1,3 +1,19 @@
+2012-12-09 Joanmarie Diggs <jdiggs@igalia.com>
+
+ [GTK] accessibility/placeholder.html is failing
+ https://bugs.webkit.org/show_bug.cgi?id=98373
+
+ Reviewed by Martin Robinson.
+
+ The test was failing because the placeholder text was not supported and
+ AccessibilityUIElement::stringAttributeValue() was not implemented.
+
+ No new tests; instead the failing test was unskipped.
+
+ * accessibility/atk/WebKitAccessibleWrapperAtk.cpp:
+ (webkitAccessibleGetAttributes): Add the placeholder text as an AtkAttribute
+ of the AtkObject, as is done in Gtk+ 3.
+
2012-12-09 Kondapally Kalyan <kalyan.kondapally@intel.com>
[EFL] [WebGL] Path is not resized correctly.
diff --git a/Source/WebCore/accessibility/atk/WebKitAccessibleWrapperAtk.cpp b/Source/WebCore/accessibility/atk/WebKitAccessibleWrapperAtk.cpp
index defd9c5..613a9a2 100644
--- a/Source/WebCore/accessibility/atk/WebKitAccessibleWrapperAtk.cpp
+++ b/Source/WebCore/accessibility/atk/WebKitAccessibleWrapperAtk.cpp
@@ -455,6 +455,10 @@
if (coreObject->isAccessibilityTable() && !coreObject->isDataTable())
attributeSet = addToAtkAttributeSet(attributeSet, "layout-guess", "true");
+ String placeholder = coreObject->placeholderValue();
+ if (!placeholder.isEmpty())
+ attributeSet = addToAtkAttributeSet(attributeSet, "placeholder-text", placeholder.utf8().data());
+
return attributeSet;
}