void *value = UnsetProperty(contentParentAtom, &rv);
void *value = aPresContext->FrameManager()->GetFrameProperty(this, contentParentAtom, NS_IFRAME_MGR_REMOVE_PROP, &rv);
nsSubDocumentFrame::Init(nsPresContext* aPresContext,                         nsIContent*     aContent,                         nsIFrame*       aParent,                         nsStyleContext* aContext,                         nsIFrame*       aPrevInFlow){  // determine if we are a <frame> or <iframe>  if (aContent) {    nsCOMPtr<nsIDOMHTMLFrameElement> frameElem = do_QueryInterface(aContent);    mIsInline = frameElem ? PR_FALSE : PR_TRUE;  }  nsresult rv =  nsLeafFrame::Init(aPresContext, aContent, aParent,                                   aContext, aPrevInFlow);  if (NS_FAILED(rv))    return rv;  // We are going to create an inner view.  If we need a view for the  // OuterFrame but we wait for the normal view creation path in  // nsCSSFrameConstructor, then we will lose because the inner view's  // parent will already have been set to some outer view (e.g., the  // canvas) when it really needs to have this frame's view as its  // parent. So, create this frame's view right away, whether we  // really need it or not, and the inner view will get it as the  // parent.  if (!HasView()) {    // To properly initialize the view we need to know the frame for the content    // that is the parent of content for this frame. This might not be our actual    // frame parent if we are out of flow (e.g., positioned) so our parent frame    // may have been set to some other ancestor.    // We look for a content parent frame in the frame property list, where it    // will have been set by nsCSSFrameConstructor if necessary.    nsCOMPtr<nsIAtom> contentParentAtom = do_GetAtom("contentParent");    nsIFrame* contentParent = nsnull;    void *value = UnsetProperty(contentParentAtom, &rv);    if (NS_SUCCEEDED(rv)) {          contentParent = (nsIFrame*)value;    }    nsHTMLContainerFrame::CreateViewForFrame(this, contentParent, PR_TRUE);  }  nsIView* view = GetView();  NS_ASSERTION(view, "We should always have a view now");  if (aParent->GetStyleDisplay()->mDisplay == NS_STYLE_DISPLAY_DECK      && !view->HasWidget()) {    view->CreateWidget(kCChildCID);  }  // determine if we are a printcontext  PRBool shouldCreateDoc;  if (aPresContext->Medium() == nsLayoutAtoms::print) {    if (aPresContext->Type() == nsPresContext::eContext_PrintPreview) {      // for print preview we want to create the view and widget but      // we do not want to load the document, it is already loaded.      rv = CreateViewAndWidget(eContentTypeContent);      NS_ENSURE_SUCCESS(rv,rv);    }    shouldCreateDoc = PR_FALSE;  } else {    shouldCreateDoc = PR_TRUE;  }  if (shouldCreateDoc) {    rv = ShowDocShell();    NS_ENSURE_SUCCESS(rv,rv);  }  return NS_OK;}