nsDocument::ContentStatesChanged(nsIContent* aContent1, nsIContent* aContent2) { PRInt32 i;   for (i = 0; i < mObservers.Count(); i++) { nsIDocumentObserver*  observer = (nsIDocumentObserver*)mObservers[i]; observer->ContentStatesChanged(this, aContent1, aContent2);   if (observer != (nsIDocumentObserver*)mObservers[i]) { i--; } } return NS_OK; }
NS_IMETHOD ContentStatesChanged(nsIDocument* aDocument, nsIContent* aContent1, nsIContent* aContent2, PRInt32 aStateMask) { return NS_OK; }
nsDocument::ContentStatesChanged(nsIContent* aContent1,                                 nsIContent* aContent2){  PRInt32 i;  // Get new value of count for every iteration in case  // observers remove themselves during the loop.  for (i = 0; i < mObservers.Count(); i++) {    nsIDocumentObserver*  observer = (nsIDocumentObserver*)mObservers[i];    observer->ContentStatesChanged(this, aContent1, aContent2);    // Make sure that the observer didn't remove itself during the    // notification. If it did, update our index and count.    if (observer != (nsIDocumentObserver*)mObservers[i]) {      i--;    }  }  return NS_OK;}