Back to index

lightning-sunbird  0.9+nobinonly
Public Member Functions | Public Attributes
nsContentOrDocument Struct Reference
Collaboration diagram for nsContentOrDocument:
Collaboration graph
[legend]

List of all members.

Public Member Functions

 nsContentOrDocument (nsIContent *aContent, nsIDocument *aDocument)
PRInt32 IndexOf (nsIContent *aPossibleChild)
PRUint32 GetChildCount ()
nsIContentGetChildAt (PRUint32 aIndex)
nsIDocumentGetOwnerDoc ()
nsresult InsertChildAt (nsIContent *aKid, PRUint32 aIndex, PRBool aNotify, nsAttrAndChildArray &aChildArray)
nsresult RemoveChildAt (PRUint32 aIndex, PRBool aNotify)
PRBool Equals (nsContentOrDocument &aOther)

Public Attributes

nsIContentmContent
nsIDocumentmDocument

Detailed Description

Definition at line 2924 of file nsGenericElement.cpp.


Constructor & Destructor Documentation

nsContentOrDocument::nsContentOrDocument ( nsIContent aContent,
nsIDocument aDocument 
) [inline]

Definition at line 2925 of file nsGenericElement.cpp.

                                                                    :
    mContent(aContent), mDocument(aDocument)
  {}

Member Function Documentation

Definition at line 2977 of file nsGenericElement.cpp.

  {
    return mContent ? mContent == aOther.mContent :
                      mDocument == aOther.mDocument;
  }

Here is the caller graph for this function:

Definition at line 2941 of file nsGenericElement.cpp.

  {
    return mContent ? mContent->GetChildAt(aIndex) :
      mDocument->GetChildAt(aIndex);
  }

Here is the call graph for this function:

Here is the caller graph for this function:

Definition at line 2935 of file nsGenericElement.cpp.

Here is the call graph for this function:

Here is the caller graph for this function:

Definition at line 2947 of file nsGenericElement.cpp.

  {
    return mContent ? mContent->GetOwnerDoc() : mDocument;
  }

Here is the call graph for this function:

Here is the caller graph for this function:

PRInt32 nsContentOrDocument::IndexOf ( nsIContent aPossibleChild) [inline]

Definition at line 2929 of file nsGenericElement.cpp.

  {
    return mContent ? mContent->IndexOf(aPossibleChild) :
      mDocument->IndexOf(aPossibleChild);
  }

Here is the call graph for this function:

Here is the caller graph for this function:

nsresult nsContentOrDocument::InsertChildAt ( nsIContent aKid,
PRUint32  aIndex,
PRBool  aNotify,
nsAttrAndChildArray aChildArray 
) [inline]

Definition at line 2952 of file nsGenericElement.cpp.

  {
    // XXXbz can't quite use doInsertChildAt because InsertChildAt has this
    // random subclass notification it now does... and because subclasses
    // might be intercepting InsertChildAt and doing stuff.
    return mContent ? mContent->InsertChildAt(aKid, aIndex, aNotify) :
      doInsertChildAt(aKid, aIndex, aNotify, mContent, mDocument, aChildArray);
  }

Here is the call graph for this function:

Here is the caller graph for this function:

nsresult nsContentOrDocument::RemoveChildAt ( PRUint32  aIndex,
PRBool  aNotify 
) [inline]

Definition at line 2962 of file nsGenericElement.cpp.

  {
    // XXXbz can't quite use doRemoveChildAt because RemoveChildAt has this
    // random subclass notification it now does... and because subclasses
    // might be intercepting RemoveChildAt and doing stuff.
    if (mContent) {
      return mContent->RemoveChildAt(aIndex, aNotify);
    }

    nsCOMPtr<nsIDocument_MOZILLA_1_8_0_BRANCH> doc =
      do_QueryInterface(mDocument);

    return doc->RemoveChildAt(aIndex, aNotify);
  }

Here is the call graph for this function:

Here is the caller graph for this function:


Member Data Documentation

Definition at line 2983 of file nsGenericElement.cpp.

Definition at line 2984 of file nsGenericElement.cpp.


The documentation for this struct was generated from the following file: