Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(233)

Unified Diff: third_party/WebKit/Source/core/frame/LocalDOMWindow.cpp

Issue 1810973004: Add the CustomElementsRegistry interface behind the flag (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebase (merge conflict) Created 4 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
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 f178a4be125a963cdf7ec107985b8652be38d5e2..ff6ada9618cc8b25febee8d7d9f5feebceb3d3d0 100644
--- a/third_party/WebKit/Source/core/frame/LocalDOMWindow.cpp
+++ b/third_party/WebKit/Source/core/frame/LocalDOMWindow.cpp
@@ -39,6 +39,7 @@
#include "core/dom/ExecutionContextTask.h"
#include "core/dom/FrameRequestCallback.h"
#include "core/dom/SandboxFlags.h"
+#include "core/dom/custom/CustomElementsRegistry.h"
#include "core/editing/Editor.h"
#include "core/events/DOMWindowEventQueue.h"
#include "core/events/HashChangeEvent.h"
@@ -552,6 +553,7 @@ void LocalDOMWindow::reset()
m_console = nullptr;
m_navigator = nullptr;
m_media = nullptr;
+ m_customElements = nullptr;
m_applicationCache = nullptr;
#if ENABLE(ASSERT)
m_hasBeenReset = true;
@@ -1308,6 +1310,13 @@ void LocalDOMWindow::cancelIdleCallback(int id)
document->cancelIdleCallback(id);
}
+CustomElementsRegistry* LocalDOMWindow::customElements() const
+{
+ if (!m_customElements)
+ m_customElements = CustomElementsRegistry::create();
+ return m_customElements.get();
+}
+
bool LocalDOMWindow::addEventListenerInternal(const AtomicString& eventType, EventListener* listener, const EventListenerOptions& options)
{
if (!EventTarget::addEventListenerInternal(eventType, listener, options))
@@ -1504,6 +1513,7 @@ DEFINE_TRACE(LocalDOMWindow)
visitor->trace(m_console);
visitor->trace(m_navigator);
visitor->trace(m_media);
+ visitor->trace(m_customElements);
visitor->trace(m_applicationCache);
visitor->trace(m_eventQueue);
visitor->trace(m_postMessageTimers);
« no previous file with comments | « third_party/WebKit/Source/core/frame/LocalDOMWindow.h ('k') | third_party/WebKit/Source/core/frame/RemoteDOMWindow.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698