Bug 1375460 - "haspopup" AtkObject attribute missing if multiprocess enabled. r=surkov

Move the object attribute exposure of states::HASPOPUP from the ATK wrapper
code to the shared accessibility code. Call UniversalStatesFor() rather than
State() for performance.
This commit is contained in:
Joanmarie Diggs
2017-06-22 07:25:00 -04:00
parent f3699015b4
commit a31096518e
4 changed files with 12 additions and 12 deletions

View File

@@ -754,17 +754,8 @@ AtkAttributeSet*
GetAttributeSet(Accessible* aAccessible)
{
nsCOMPtr<nsIPersistentProperties> attributes = aAccessible->Attributes();
if (attributes) {
// There is no ATK state for haspopup, must use object attribute to expose
// the same info.
if (aAccessible->State() & states::HASPOPUP) {
nsAutoString unused;
attributes->SetStringProperty(NS_LITERAL_CSTRING("haspopup"),
NS_LITERAL_STRING("true"), unused);
}
if (attributes)
return ConvertToAtkAttributeSet(attributes);
}
return nullptr;
}