Index: third_party/WebKit/Source/core/frame/LocalDOMWindow.cpp |
diff --git a/third_party/WebKit/Source/core/frame/LocalDOMWindow.cpp b/third_party/WebKit/Source/core/frame/LocalDOMWindow.cpp |
index 8899ff7d3c8558d44d2e4ced8b5ed284d48654b6..5ddce83187c7f4ec075b2e1ddeb605d9c8829707 100644 |
--- a/third_party/WebKit/Source/core/frame/LocalDOMWindow.cpp |
+++ b/third_party/WebKit/Source/core/frame/LocalDOMWindow.cpp |
@@ -1327,13 +1327,18 @@ void LocalDOMWindow::cancelIdleCallback(int id) |
document->cancelIdleCallback(id); |
} |
-CustomElementsRegistry* LocalDOMWindow::customElements(ScriptState* scriptState) const |
+CustomElementsRegistry* LocalDOMWindow::customElementsForBindings(ScriptState* scriptState) const |
{ |
if (!scriptState->world().isMainWorld()) |
return nullptr; |
+ return &customElements(); |
+} |
+ |
+CustomElementsRegistry& LocalDOMWindow::customElements() const |
+{ |
if (!m_customElements) |
- m_customElements = CustomElementsRegistry::create(scriptState, document()->registrationContext()); |
- return m_customElements.get(); |
+ m_customElements = CustomElementsRegistry::create(document()->registrationContext()); |
+ return *m_customElements.get(); |
} |
void LocalDOMWindow::addedEventListener(const AtomicString& eventType, RegisteredEventListener& registeredListener) |