зеркало из https://github.com/mozilla/pjs.git
Bug 421366, [@ nsContentUtils::IsEventAttributeName] r+sr=peterv
This commit is contained in:
Родитель
e0f84d5154
Коммит
a5600aeaf2
|
@ -2224,7 +2224,10 @@ nsHTMLDocument::OpenCommon(const nsACString& aContentType, PRBool aReplace)
|
|||
// Remove all attributes from the root element
|
||||
while (count-- > 0) {
|
||||
const nsAttrName* name = root->GetAttrNameAt(count);
|
||||
root->UnsetAttr(name->NamespaceID(), name->LocalName(), PR_FALSE);
|
||||
// Hold a strong reference here so that the atom doesn't go away during
|
||||
// UnsetAttr.
|
||||
nsCOMPtr<nsIAtom> localName = name->LocalName();
|
||||
root->UnsetAttr(name->NamespaceID(), localName, PR_FALSE);
|
||||
}
|
||||
|
||||
// Remove the root from the childlist
|
||||
|
|
|
@ -770,7 +770,9 @@ nsXBLBinding::GenerateAnonymousContent()
|
|||
const nsAttrName* attrName;
|
||||
for (PRUint32 i = 0; (attrName = content->GetAttrNameAt(i)); ++i) {
|
||||
PRInt32 namespaceID = attrName->NamespaceID();
|
||||
nsIAtom* name = attrName->LocalName();
|
||||
// Hold a strong reference here so that the atom doesn't go away during
|
||||
// UnsetAttr.
|
||||
nsCOMPtr<nsIAtom> name = attrName->LocalName();
|
||||
|
||||
if (name != nsGkAtoms::includes) {
|
||||
if (!nsContentUtils::HasNonEmptyAttr(mBoundElement, namespaceID, name)) {
|
||||
|
|
|
@ -570,7 +570,9 @@ nsXBLPrototypeBinding::AttributeChanged(nsIAtom* aAttribute,
|
|||
element);
|
||||
|
||||
if (realElement) {
|
||||
nsIAtom* dstAttr = xblAttr->GetDstAttribute();
|
||||
// Hold a strong reference here so that the atom doesn't go away during
|
||||
// UnsetAttr.
|
||||
nsCOMPtr<nsIAtom> dstAttr = xblAttr->GetDstAttribute();
|
||||
PRInt32 dstNs = xblAttr->GetDstNameSpace();
|
||||
|
||||
if (aRemoveFlag)
|
||||
|
|
|
@ -898,7 +898,9 @@ nsXULContentBuilder::CopyAttributesToElement(nsIContent* aTemplateNode,
|
|||
for (PRUint32 attr = 0; attr < numAttribs; attr++) {
|
||||
const nsAttrName* name = aTemplateNode->GetAttrNameAt(attr);
|
||||
PRInt32 attribNameSpaceID = name->NamespaceID();
|
||||
nsIAtom* attribName = name->LocalName();
|
||||
// Hold a strong reference here so that the atom doesn't go away
|
||||
// during UnsetAttr.
|
||||
nsCOMPtr<nsIAtom> attribName = name->LocalName();
|
||||
|
||||
// XXXndeakin ignore namespaces until bug 321182 is fixed
|
||||
if (attribName != nsGkAtoms::id && attribName != nsGkAtoms::uri) {
|
||||
|
|
Загрузка…
Ссылка в новой задаче