NS_IMETHODIMP nsAccessible::GetFirstChild(nsIAccessible * *aFirstChild) { if (gIsCacheDisabled) { InvalidateChildren();
NS_IMETHODIMP nsAccessibleTreeWalker::GetFirstChild() { if (!mState.domNode) return NS_ERROR_FAILURE;  nsCOMPtr<nsIDOMNode> next, parent(mState.domNode);  PushState();  GetKids(parent);  if (mState.siblingIndex == eSiblingsWalkNormalDOM) parent->GetFirstChild(getter_AddRefs(next)); else mState.siblingList->Item(0, getter_AddRefs(next));   while (next) { mState.domNode = next; if (!IsHidden() && (GetAccessible() || NS_SUCCEEDED(GetFirstChild()))) return NS_OK; if (mState.siblingIndex == eSiblingsWalkNormalDOM) mState.domNode->GetNextSibling(getter_AddRefs(next)); else mState.siblingList->Item(++mState.siblingIndex, getter_AddRefs(next));
NS_IMETHODIMP nsAccessible::GetFirstChild(nsIAccessible * *aFirstChild) {    if (gIsCacheDisabled) {    InvalidateChildren();  }  PRInt32 numChildren;  GetChildCount(&numChildren);  // Make sure we cache all of the children  NS_IF_ADDREF(*aFirstChild = mFirstChild);  return NS_OK;  }