diff --git a/mozilla/content/base/public/nsIDocument.h b/mozilla/content/base/public/nsIDocument.h index abb77b0d651..fdb774dc7cc 100644 --- a/mozilla/content/base/public/nsIDocument.h +++ b/mozilla/content/base/public/nsIDocument.h @@ -41,6 +41,7 @@ #include "nsStringGlue.h" #include "nsIDocumentObserver.h" // for nsUpdateType #include "nsCOMPtr.h" +#include "nsCOMArray.h" #include "nsIURI.h" #include "nsWeakPtr.h" #include "nsIWeakReferenceUtils.h" @@ -95,8 +96,8 @@ class mozAutoSubtreeModified; // IID for the nsIDocument interface #define NS_IDOCUMENT_IID \ -{ 0x6700e22b, 0x95b8, 0x44cf, \ - { 0x8f, 0x5a, 0x57, 0x2c, 0x14, 0x5b, 0xd1, 0xa1 } } +{ 0x9a26d0aa, 0x37d2, 0x4313, \ + { 0x9e, 0x53, 0x16, 0xd1, 0xa4, 0x67, 0xb3, 0x5b } } // Flag for AddStyleSheet(). @@ -853,7 +854,12 @@ public: * * @param aTarget is the target for the mutation event. */ - virtual void MayDispatchMutationEvent(nsINode* aTarget) = 0; + void MayDispatchMutationEvent(nsINode* aTarget) + { + if (mSubtreeModifiedDepth > 0) { + mSubtreeModifiedTargets.AppendObject(aTarget); + } + } /** * Marks as not-going-to-be-collected for the given generation of @@ -962,6 +968,9 @@ protected: PRUint32 mMarkedCCGeneration; nsTObserverArray mPresShells; + + nsCOMArray mSubtreeModifiedTargets; + PRUint32 mSubtreeModifiedDepth; }; NS_DEFINE_STATIC_IID_ACCESSOR(nsIDocument, NS_IDOCUMENT_IID) diff --git a/mozilla/content/base/src/nsDocument.cpp b/mozilla/content/base/src/nsDocument.cpp index 8d2fdd09fe9..92b5d716dc9 100644 --- a/mozilla/content/base/src/nsDocument.cpp +++ b/mozilla/content/base/src/nsDocument.cpp @@ -5756,14 +5756,6 @@ nsDocument::OnPageHide(PRBool aPersisted) mVisible = PR_FALSE; } -void -nsDocument::MayDispatchMutationEvent(nsINode* aTarget) -{ - if (mSubtreeModifiedDepth > 0) { - mSubtreeModifiedTargets.AppendObject(aTarget); - } -} - void nsDocument::WillDispatchMutationEvent(nsINode* aTarget) { diff --git a/mozilla/content/base/src/nsDocument.h b/mozilla/content/base/src/nsDocument.h index fc7c35c5e4b..482458da657 100644 --- a/mozilla/content/base/src/nsDocument.h +++ b/mozilla/content/base/src/nsDocument.h @@ -73,7 +73,6 @@ #include "nsINodeInfo.h" #include "nsIDOMDocumentEvent.h" #include "nsIDOM3DocumentEvent.h" -#include "nsCOMArray.h" #include "nsHashtable.h" #include "nsInterfaceHashtable.h" #include "nsIBoxObject.h" @@ -507,7 +506,6 @@ public: virtual void OnPageShow(PRBool aPersisted); virtual void OnPageHide(PRBool aPersisted); - virtual void MayDispatchMutationEvent(nsINode* aTarget); virtual void WillDispatchMutationEvent(nsINode* aTarget); virtual void MutationEventDispatched(nsINode* aTarget); @@ -819,9 +817,6 @@ private: // Member to store out last-selected stylesheet set. nsString mLastStyleSheetSet; - nsCOMArray mSubtreeModifiedTargets; - PRUint32 mSubtreeModifiedDepth; - // Our update nesting level PRUint32 mUpdateNestLevel; };