virtual nsresult OpenContext(nsCParserNode *aNode,eHTMLTags aTag,nsDTDContext *aContext,nsIHTMLContentSink *aSink) { CElement::OpenContext(aNode,aTag,aContext,aSink);  nsresult result=NS_OK; PRInt32   theCount=aContext->GetCount();  nsCParserNode *theNode = (nsCParserNode*)aNode;  #ifdef DEBUG eHTMLTags theGrandParentTag=aContext->TagAt(theCount-2); nsAutoString  theNumber; aContext->IncrementCounter(theGrandParentTag,*theNode,theNumber);  CTextToken theToken(theNumber); nsCParserNode theNewNode(&theToken, 0 ); *theNode = theNewNode; #endif result=aSink->AddLeaf(*theNode); return result;
virtual nsresult  OpenContext(nsCParserNode *aNode,eHTMLTags aTag,nsDTDContext *aContext,nsIHTMLContentSink *aSink) { aContext->Push(aNode, 0, PR_FALSE); CElement *theElement = (aTag == mTag) ? this : GetElement(aTag); theElement->NotifyOpen(aNode, aTag, aContext,aSink); return NS_OK;
  virtual nsresult OpenContext(nsCParserNode *aNode,eHTMLTags aTag,nsDTDContext *aContext,nsIHTMLContentSink *aSink) {        CElement::OpenContext(aNode,aTag,aContext,aSink);        nsresult result=NS_OK;    PRInt32   theCount=aContext->GetCount();    nsCParserNode *theNode = (nsCParserNode*)aNode;#ifdef DEBUG    eHTMLTags theGrandParentTag=aContext->TagAt(theCount-2);    nsAutoString  theNumber;    aContext->IncrementCounter(theGrandParentTag,*theNode,theNumber);    CTextToken theToken(theNumber);    nsCParserNode theNewNode(&theToken, 0 /*stack token*/);    *theNode = theNewNode;#endif    result=aSink->AddLeaf(*theNode);    return result;  }