Bug 630488 - ASSERTION: Document accessible isn't a child of outerdoc accessible in nsOuterDocAccessible::CacheChildren(), r=davidb, a=davidb

This commit is contained in:
Alexander Surkov 2011-02-02 00:08:43 +08:00
Родитель 36992dbd68
Коммит 2734c28268
1 изменённых файлов: 7 добавлений и 12 удалений

Просмотреть файл

@ -243,16 +243,11 @@ void
nsOuterDocAccessible::CacheChildren()
{
// Request document accessible for the content document to make sure it's
// created because once it's created it appends itself as a child.
nsIDocument *outerDoc = mContent->GetCurrentDoc();
if (!outerDoc)
return;
nsIDocument *innerDoc = outerDoc->GetSubDocumentFor(mContent);
if (!innerDoc)
return;
nsDocAccessible *docAcc = GetAccService()->GetDocAccessible(innerDoc);
NS_ASSERTION(docAcc && docAcc->GetParent() == this,
"Document accessible isn't a child of outerdoc accessible!");
// created. It will appended to outerdoc accessible children asynchronously.
nsIDocument* outerDoc = mContent->GetCurrentDoc();
if (outerDoc) {
nsIDocument* innerDoc = outerDoc->GetSubDocumentFor(mContent);
if (innerDoc)
GetAccService()->GetDocAccessible(innerDoc);
}
}