summaryrefslogtreecommitdiffstats
path: root/dom/base/CustomElementRegistry.cpp
diff options
context:
space:
mode:
authorGaming4JC <g4jc@hyperbola.info>2020-01-05 12:51:10 -0500
committerGaming4JC <g4jc@hyperbola.info>2020-01-26 15:50:27 -0500
commitf50503df9c2eced785957626273ee07e5312d546 (patch)
tree3bc2c0f85b649507cc0c56700fa39f943180847e /dom/base/CustomElementRegistry.cpp
parent5840b63cca00a45c8c40bf5e04195aabd4dabb73 (diff)
downloadUXP-f50503df9c2eced785957626273ee07e5312d546.tar
UXP-f50503df9c2eced785957626273ee07e5312d546.tar.gz
UXP-f50503df9c2eced785957626273ee07e5312d546.tar.lz
UXP-f50503df9c2eced785957626273ee07e5312d546.tar.xz
UXP-f50503df9c2eced785957626273ee07e5312d546.zip
Bug 1301024 - Part 2: Implement create an element steps.
Tag UXP Issue #1344
Diffstat (limited to 'dom/base/CustomElementRegistry.cpp')
-rw-r--r--dom/base/CustomElementRegistry.cpp12
1 files changed, 8 insertions, 4 deletions
diff --git a/dom/base/CustomElementRegistry.cpp b/dom/base/CustomElementRegistry.cpp
index 897f7df12..27e92a56a 100644
--- a/dom/base/CustomElementRegistry.cpp
+++ b/dom/base/CustomElementRegistry.cpp
@@ -931,7 +931,7 @@ DoUpgrade(Element* aElement,
} // anonymous namespace
// https://html.spec.whatwg.org/multipage/scripting.html#upgrades
-void
+/* static */ void
CustomElementRegistry::Upgrade(Element* aElement,
CustomElementDefinition* aDefinition,
ErrorResult& aRv)
@@ -969,8 +969,10 @@ CustomElementRegistry::Upgrade(Element* aElement,
(attrValue.IsEmpty() ? NullString() : attrValue),
(namespaceURI.IsEmpty() ? NullString() : namespaceURI)
};
- EnqueueLifecycleCallback(nsIDocument::eAttributeChanged, aElement,
- &args, aDefinition);
+ nsContentUtils::EnqueueLifecycleCallback(aElement->OwnerDoc(),
+ nsIDocument::eAttributeChanged,
+ aElement,
+ &args, aDefinition);
}
}
}
@@ -995,7 +997,9 @@ CustomElementRegistry::Upgrade(Element* aElement,
data->mState = CustomElementData::State::eCustom;
// This is for old spec.
- EnqueueLifecycleCallback(nsIDocument::eCreated, aElement, nullptr, aDefinition);
+ nsContentUtils::EnqueueLifecycleCallback(aElement->OwnerDoc(),
+ nsIDocument::eCreated,
+ aElement, nullptr, aDefinition);
}
//-----------------------------------------------------