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

Unified Diff: third_party/WebKit/Source/core/dom/MessagePort.cpp

Issue 1808533003: Revert of Reduce ActiveDOMObjects from core/ (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 9 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/dom/MessagePort.cpp
diff --git a/third_party/WebKit/Source/core/dom/MessagePort.cpp b/third_party/WebKit/Source/core/dom/MessagePort.cpp
index 4c57d77312993f2a3d103b8fd08eae3ce3d89b26..82fceb6323bcb4e60f579de0bd8237c96e17745e 100644
--- a/third_party/WebKit/Source/core/dom/MessagePort.cpp
+++ b/third_party/WebKit/Source/core/dom/MessagePort.cpp
@@ -45,11 +45,13 @@
MessagePort* MessagePort::create(ExecutionContext& executionContext)
{
- return new MessagePort(executionContext);
+ MessagePort* port = new MessagePort(executionContext);
+ port->suspendIfNeeded();
+ return port;
}
MessagePort::MessagePort(ExecutionContext& executionContext)
- : ContextLifecycleObserver(&executionContext)
+ : ActiveDOMObject(&executionContext)
, m_started(false)
, m_closed(false)
, m_weakFactory(this)
@@ -276,7 +278,7 @@
DEFINE_TRACE(MessagePort)
{
- ContextLifecycleObserver::trace(visitor);
+ ActiveDOMObject::trace(visitor);
RefCountedGarbageCollectedEventTargetWithInlineData<MessagePort>::trace(visitor);
}
« no previous file with comments | « third_party/WebKit/Source/core/dom/MessagePort.h ('k') | third_party/WebKit/Source/core/fileapi/FileReader.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698