Bug 1285272 - Replace direct use of mRoleMapEntry with calls to ARIARoleMap(). r=yzen

MozReview-Commit-ID: JEuMlNLxD8R
This commit is contained in:
Michael Li
2016-07-12 15:34:13 -04:00
parent 7fbea07526
commit 7af2c4c079
5 changed files with 78 additions and 58 deletions

View File

@@ -308,7 +308,7 @@ HTMLTextFieldAccessible::NativeAttributes()
nsAutoString type;
if (mContent->GetAttr(kNameSpaceID_None, nsGkAtoms::type, type)) {
nsAccUtils::SetAccAttr(attributes, nsGkAtoms::textInputType, type);
if (!mRoleMapEntry && type.EqualsLiteral("search")) {
if (!ARIARoleMap() && type.EqualsLiteral("search")) {
nsAccUtils::SetAccAttr(attributes, nsGkAtoms::xmlroles,
NS_LITERAL_STRING("searchbox"));
}