mContext = aPresContext; mOwner = aFrame; return NS_OK;
nsresult rv = nsObjectFrameSuper::Init(aPresContext, aContent, aParent, aContext, aPrevInFlow);  if(rv != NS_OK) return rv;  PRBool bImage = PR_FALSE;    IsSupportedImage(aContent, &bImage);  if(bImage) { nsCOMPtr<nsIPresShell> shell; aPresContext->GetShell(getter_AddRefs(shell)); nsIFrame * aNewFrame = nsnull; rv = NS_NewImageFrame(shell, &aNewFrame); if(rv != NS_OK) return rv;  rv = aNewFrame->Init(aPresContext, aContent, this, aContext, aPrevInFlow); if(rv == NS_OK) { nsHTMLContainerFrame::CreateViewForFrame(aPresContext, aNewFrame, aContext, PR_FALSE); mFrames.AppendFrame(this, aNewFrame); } else aNewFrame->Destroy(aPresContext); }  return rv;
NS_IMETHODIMP nsPluginInstanceOwner::Init(nsIPresContext* aPresContext, nsObjectFrame *aFrame){  //do not addref to avoid circular refs. MMP  mContext = aPresContext;  mOwner = aFrame;  return NS_OK;}