bug 1209615 - use TabParent::GetTopLevelDocAccessible() in OuterDocAccessible::RemoteChildDoc() r=davidb

This commit is contained in:
Trevor Saunders 2015-10-06 13:14:00 -04:00
parent a12ee7e426
commit c3e44cb6c3

View File

@ -192,14 +192,8 @@ OuterDocAccessible::RemoteChildDoc() const
if (!tab) if (!tab)
return nullptr; return nullptr;
// XXX Consider managing non top level remote documents with there parent if (DocAccessibleParent* doc = tab->GetTopLevelDocAccessible()) {
// document. return doc;
const nsTArray<PDocAccessibleParent*>& docs = tab->ManagedPDocAccessibleParent();
size_t docCount = docs.Length();
for (size_t i = 0; i < docCount; i++) {
auto doc = static_cast<DocAccessibleParent*>(docs[i]);
if (!doc->ParentDoc())
return doc;
} }
MOZ_ASSERT(false, "no top level tab document?"); MOZ_ASSERT(false, "no top level tab document?");