diff options
Diffstat (limited to 'dom/base/CustomElementRegistry.cpp')
-rw-r--r-- | dom/base/CustomElementRegistry.cpp | 12 |
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); } //----------------------------------------------------- |