Bug 1187611 - (part 1) Handle ProxyAccessibles in mozAccessible focus r=tbsaunde

This commit is contained in:
Lorien Hu 2015-08-04 14:56:09 -04:00
parent e43e59977d
commit adcddd62d0

View File

@ -1242,11 +1242,13 @@ struct RoleDescrComparator
- (BOOL)focus
{
AccessibleWrap* accWrap = [self getGeckoAccessible];
if (!accWrap)
if (AccessibleWrap* accWrap = [self getGeckoAccessible])
accWrap->TakeFocus();
else if (ProxyAccessible* proxy = [self getProxyAccessible])
proxy->TakeFocus();
else
return NO;
accWrap->TakeFocus();
return YES;
}