diff --git a/content/base/public/nsIContent.h b/content/base/public/nsIContent.h index 9618f1f6b5b3..cd76dcb909cf 100644 --- a/content/base/public/nsIContent.h +++ b/content/base/public/nsIContent.h @@ -170,7 +170,7 @@ public: bool IsRootOfNativeAnonymousSubtree() const { NS_ASSERTION(!HasFlag(NODE_IS_NATIVE_ANONYMOUS_ROOT) || - (HasFlag(NODE_IS_ANONYMOUS) && + (HasFlag(NODE_IS_ANONYMOUS_ROOT) && HasFlag(NODE_IS_IN_ANONYMOUS_SUBTREE)), "Some flags seem to be missing!"); return HasFlag(NODE_IS_NATIVE_ANONYMOUS_ROOT); @@ -188,7 +188,7 @@ public: */ void SetNativeAnonymous() { - SetFlags(NODE_IS_ANONYMOUS | NODE_IS_IN_ANONYMOUS_SUBTREE | + SetFlags(NODE_IS_ANONYMOUS_ROOT | NODE_IS_IN_ANONYMOUS_SUBTREE | NODE_IS_NATIVE_ANONYMOUS_ROOT); } @@ -210,7 +210,7 @@ public: "to binding parent"); NS_ASSERTION(!GetParent() || ((GetBindingParent() == GetParent()) == - HasFlag(NODE_IS_ANONYMOUS)) || + HasFlag(NODE_IS_ANONYMOUS_ROOT)) || // Unfortunately default content for XBL insertion points is // anonymous content that is bound with the parent of the // insertion point as the parent but the bound element for the @@ -218,10 +218,10 @@ public: // the assert a bit here. (GetBindingParent() && (GetBindingParent() == GetParent()->GetBindingParent()) == - HasFlag(NODE_IS_ANONYMOUS)), + HasFlag(NODE_IS_ANONYMOUS_ROOT)), "For nodes with parent, flag and GetBindingParent() check " "should match"); - return HasFlag(NODE_IS_ANONYMOUS); + return HasFlag(NODE_IS_ANONYMOUS_ROOT); } /** diff --git a/content/base/public/nsINode.h b/content/base/public/nsINode.h index 55489d6e7e3c..cd97babda3f2 100644 --- a/content/base/public/nsINode.h +++ b/content/base/public/nsINode.h @@ -83,7 +83,7 @@ enum { // XBL-generated ones, will do. This flag is set-once: once a node has it, // it must not be removed. // NOTE: Should only be used on nsIContent nodes - NODE_IS_ANONYMOUS = NODE_FLAG_BIT(2), + NODE_IS_ANONYMOUS_ROOT = NODE_FLAG_BIT(2), // Whether the node has some ancestor, possibly itself, that is native // anonymous. This includes ancestors crossing XBL scopes, in cases when an @@ -910,7 +910,7 @@ public: void SetFlags(uint32_t aFlagsToSet) { - NS_ASSERTION(!(aFlagsToSet & (NODE_IS_ANONYMOUS | + NS_ASSERTION(!(aFlagsToSet & (NODE_IS_ANONYMOUS_ROOT | NODE_IS_NATIVE_ANONYMOUS_ROOT | NODE_IS_IN_ANONYMOUS_SUBTREE | NODE_ATTACH_BINDING_ON_POSTCREATE | @@ -925,7 +925,7 @@ public: void UnsetFlags(uint32_t aFlagsToUnset) { NS_ASSERTION(!(aFlagsToUnset & - (NODE_IS_ANONYMOUS | + (NODE_IS_ANONYMOUS_ROOT | NODE_IS_IN_ANONYMOUS_SUBTREE | NODE_IS_NATIVE_ANONYMOUS_ROOT)), "Trying to unset write-only flags"); diff --git a/content/base/src/nsINode.cpp b/content/base/src/nsINode.cpp index a318f9002169..cf4a72fe5fc1 100644 --- a/content/base/src/nsINode.cpp +++ b/content/base/src/nsINode.cpp @@ -1180,7 +1180,7 @@ nsINode::GetOwnerGlobal() bool nsINode::UnoptimizableCCNode() const { - const uintptr_t problematicFlags = (NODE_IS_ANONYMOUS | + const uintptr_t problematicFlags = (NODE_IS_ANONYMOUS_ROOT | NODE_IS_IN_ANONYMOUS_SUBTREE | NODE_IS_NATIVE_ANONYMOUS_ROOT | NODE_MAY_BE_IN_BINDING_MNGR); diff --git a/content/xbl/src/nsXBLBinding.cpp b/content/xbl/src/nsXBLBinding.cpp index e36803ef0a6f..6904fd88e06c 100644 --- a/content/xbl/src/nsXBLBinding.cpp +++ b/content/xbl/src/nsXBLBinding.cpp @@ -256,7 +256,7 @@ nsXBLBinding::InstallAnonymousContent(nsIContent* aAnonParent, nsIContent* aElem return; } - child->SetFlags(NODE_IS_ANONYMOUS); + child->SetFlags(NODE_IS_ANONYMOUS_ROOT); #ifdef MOZ_XUL // To make XUL templates work (and other goodies that happen when diff --git a/layout/base/nsCSSFrameConstructor.cpp b/layout/base/nsCSSFrameConstructor.cpp index e8f538197b1e..4c59262d1dd7 100644 --- a/layout/base/nsCSSFrameConstructor.cpp +++ b/layout/base/nsCSSFrameConstructor.cpp @@ -3765,7 +3765,7 @@ nsCSSFrameConstructor::GetAnonymousContent(nsIContent* aParent, // least-surprise CSS binding until we do the SVG specified // cascading rules for - bug 265894 if (aParentFrame->GetType() == nsGkAtoms::svgUseFrame) { - content->SetFlags(NODE_IS_ANONYMOUS); + content->SetFlags(NODE_IS_ANONYMOUS_ROOT); } else { content->SetNativeAnonymous(); }