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

Unified Diff: Source/web/ServiceWorkerGlobalScopeProxy.cpp

Issue 1099073002: Introducing FetchEventInit Dictionary. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Created 5 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
« no previous file with comments | « Source/modules/serviceworkers/FetchEventInit.idl ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/web/ServiceWorkerGlobalScopeProxy.cpp
diff --git a/Source/web/ServiceWorkerGlobalScopeProxy.cpp b/Source/web/ServiceWorkerGlobalScopeProxy.cpp
index fb6044a0ddf2b5a8f8fd18548974489f6ab04c8a..233c8a81c0d7d93578524b0f68163489b2308db1 100644
--- a/Source/web/ServiceWorkerGlobalScopeProxy.cpp
+++ b/Source/web/ServiceWorkerGlobalScopeProxy.cpp
@@ -101,8 +101,10 @@ void ServiceWorkerGlobalScopeProxy::dispatchFetchEvent(int eventID, const WebSer
Request* request = Request::create(m_workerGlobalScope, webRequest);
request->headers()->setGuard(Headers::ImmutableGuard);
- RefPtrWillBeRawPtr<FetchEvent> fetchEvent(FetchEvent::create(observer, request));
- fetchEvent->setIsReload(webRequest.isReload());
+ FetchEventInit eventInit;
+ eventInit.setRequest(request);
+ eventInit.setIsReload(webRequest.isReload());
+ RefPtrWillBeRawPtr<FetchEvent> fetchEvent(FetchEvent::create(EventTypeNames::fetch, eventInit, observer));
defaultPrevented = !m_workerGlobalScope->dispatchEvent(fetchEvent.release());
observer->didDispatchEvent(defaultPrevented);
}
« no previous file with comments | « Source/modules/serviceworkers/FetchEventInit.idl ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698