Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(122)

Unified Diff: content/renderer/accessibility/blink_ax_tree_source.cc

Issue 559343002: Add AX attribute conversion for input type (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Re-generated test results Created 6 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: content/renderer/accessibility/blink_ax_tree_source.cc
diff --git a/content/renderer/accessibility/blink_ax_tree_source.cc b/content/renderer/accessibility/blink_ax_tree_source.cc
index 994550f32e8ef5396e158b04638d1fb2bfc3cfd4..e382963f5f07ed3818f0ad328c2e429d395184f5 100644
--- a/content/renderer/accessibility/blink_ax_tree_source.cc
+++ b/content/renderer/accessibility/blink_ax_tree_source.cc
@@ -346,6 +346,12 @@ void BlinkAXTreeSource::SerializeNode(blink::WebAXObject src,
line_breaks.push_back(src_line_breaks[i]);
dst->AddIntListAttribute(ui::AX_ATTR_LINE_BREAKS, line_breaks);
}
+
+ if (dst->role == ui::AX_ROLE_TEXT_FIELD &&
+ src.textInputType().length()) {
+ dst->AddStringAttribute(ui::AX_ATTR_TEXT_INPUT_TYPE,
+ UTF16ToUTF8(src.textInputType()));
+ }
}
// ARIA role.
« no previous file with comments | « content/browser/accessibility/dump_accessibility_tree_browsertest.cc ('k') | content/test/data/accessibility/input-types.html » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698