Bug 1187611 - (part 3) Handle ProxyAccessibles in mozAccessible canBeFocused r=tbsaunde

This commit is contained in:
Lorien Hu 2015-08-04 14:56:13 -04:00
parent 9e44300d4f
commit fb72a45a11

View File

@ -1236,8 +1236,13 @@ struct RoleDescrComparator
- (BOOL)canBeFocused
{
AccessibleWrap* accWrap = [self getGeckoAccessible];
return accWrap && (accWrap->InteractiveState() & states::FOCUSABLE);
if (AccessibleWrap* accWrap = [self getGeckoAccessible])
return accWrap->InteractiveState() & states::FOCUSABLE;
if (ProxyAccessible* proxy = [self getProxyAccessible])
return proxy->State() & states::FOCUSABLE;
return false;
}
- (BOOL)focus