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

Unified Diff: third_party/WebKit/Source/modules/serviceworkers/ServiceWorkerContainer.cpp

Issue 2466513002: Deprecate ServiceWorkerMessageEvent in favor of MessageEvent (Closed)
Patch Set: Remove ServiceWorkerMessageEvent codes; update layout tests Created 4 years, 1 month 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/modules/serviceworkers/ServiceWorkerContainer.cpp
diff --git a/third_party/WebKit/Source/modules/serviceworkers/ServiceWorkerContainer.cpp b/third_party/WebKit/Source/modules/serviceworkers/ServiceWorkerContainer.cpp
index 5bfdcc44afc45394e4ebcb605818d1d6e96b3d02..cb4eacdd35937d817dcac8c499e98eff9bfedbcc 100644
--- a/third_party/WebKit/Source/modules/serviceworkers/ServiceWorkerContainer.cpp
+++ b/third_party/WebKit/Source/modules/serviceworkers/ServiceWorkerContainer.cpp
@@ -40,6 +40,7 @@
#include "core/dom/ExceptionCode.h"
#include "core/dom/ExecutionContext.h"
#include "core/dom/MessagePort.h"
+#include "core/events/MessageEvent.h"
#include "core/frame/LocalDOMWindow.h"
#include "core/frame/UseCounter.h"
#include "core/frame/csp/ContentSecurityPolicy.h"
@@ -47,7 +48,6 @@
#include "modules/serviceworkers/ServiceWorker.h"
#include "modules/serviceworkers/ServiceWorkerContainerClient.h"
#include "modules/serviceworkers/ServiceWorkerError.h"
-#include "modules/serviceworkers/ServiceWorkerMessageEvent.h"
#include "modules/serviceworkers/ServiceWorkerRegistration.h"
#include "platform/RuntimeEnabledFeatures.h"
#include "platform/weborigin/SchemeRegistry.h"
@@ -510,9 +510,9 @@ void ServiceWorkerContainer::dispatchMessageEvent(
RefPtr<SerializedScriptValue> value = SerializedScriptValue::create(message);
ServiceWorker* source =
ServiceWorker::from(getExecutionContext(), wrapUnique(handle.release()));
- dispatchEvent(ServiceWorkerMessageEvent::create(
- ports, value, source,
- getExecutionContext()->getSecurityOrigin()->toString()));
+ dispatchEvent(MessageEvent::create(
+ ports, value, getExecutionContext()->getSecurityOrigin()->toString(),
+ String(), source, String()));
nhiroki 2016/11/14 05:48:55 nit: Adding arg names would be a bit more readabl
jungkees 2016/11/14 14:17:11 Yes. Addressed.
}
const AtomicString& ServiceWorkerContainer::interfaceName() const {

Powered by Google App Engine
This is Rietveld 408576698