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

Unified Diff: content/browser/accessibility/browser_accessibility_android.cc

Issue 1046883002: Use multiline attribute to check for IA2_STATE_MULTILINE. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Removing textarea Created 5 years, 8 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/browser/accessibility/browser_accessibility_android.cc
diff --git a/content/browser/accessibility/browser_accessibility_android.cc b/content/browser/accessibility/browser_accessibility_android.cc
index 3cd374e7ea1f4626a310a9afd9122291c9e558d4..9bfd68a343175d8505db9081a250d982a5d68013 100644
--- a/content/browser/accessibility/browser_accessibility_android.cc
+++ b/content/browser/accessibility/browser_accessibility_android.cc
@@ -172,8 +172,7 @@ bool BrowserAccessibilityAndroid::IsDismissable() const {
}
bool BrowserAccessibilityAndroid::IsEditableText() const {
- return (GetRole() == ui::AX_ROLE_TEXT_AREA ||
- GetRole() == ui::AX_ROLE_TEXT_FIELD);
+ return GetRole() == ui::AX_ROLE_TEXT_FIELD;
}
bool BrowserAccessibilityAndroid::IsEnabled() const {
@@ -216,7 +215,7 @@ bool BrowserAccessibilityAndroid::IsLink() const {
}
bool BrowserAccessibilityAndroid::IsMultiLine() const {
- return GetRole() == ui::AX_ROLE_TEXT_AREA;
+ return HasState(ui::AX_STATE_MULTILINE);
}
bool BrowserAccessibilityAndroid::IsPassword() const {
@@ -257,7 +256,6 @@ const char* BrowserAccessibilityAndroid::GetClassName() const {
switch (GetRole()) {
case ui::AX_ROLE_SEARCH_BOX:
case ui::AX_ROLE_SPIN_BUTTON:
- case ui::AX_ROLE_TEXT_AREA:
case ui::AX_ROLE_TEXT_FIELD:
class_name = "android.widget.EditText";
break;
@@ -345,7 +343,6 @@ base::string16 BrowserAccessibilityAndroid::GetText() const {
switch (GetRole()) {
case ui::AX_ROLE_COMBO_BOX:
case ui::AX_ROLE_POP_UP_BUTTON:
- case ui::AX_ROLE_TEXT_AREA:
case ui::AX_ROLE_TEXT_FIELD:
return value;
}
@@ -381,7 +378,6 @@ base::string16 BrowserAccessibilityAndroid::GetText() const {
base::string16 placeholder;
switch (GetRole()) {
case ui::AX_ROLE_DATE:
- case ui::AX_ROLE_TEXT_AREA:
case ui::AX_ROLE_TEXT_FIELD:
case ui::AX_ROLE_TIME:
GetHtmlAttribute("placeholder", &placeholder);
« no previous file with comments | « content/browser/accessibility/browser_accessibility.cc ('k') | content/browser/accessibility/browser_accessibility_cocoa.mm » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698