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

Unified Diff: Source/modules/serviceworkers/FetchEvent.cpp

Issue 1102363002: Add Client Attribute to FetchEvent- Blink Side. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Created 5 years, 7 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: Source/modules/serviceworkers/FetchEvent.cpp
diff --git a/Source/modules/serviceworkers/FetchEvent.cpp b/Source/modules/serviceworkers/FetchEvent.cpp
index 81a52fbeb9f5426d73d729afa772aba4394fb085..551c3ffe2f01090d5c6121ccd31aaee2fde73e11 100644
--- a/Source/modules/serviceworkers/FetchEvent.cpp
+++ b/Source/modules/serviceworkers/FetchEvent.cpp
@@ -38,6 +38,11 @@ bool FetchEvent::isReload() const
return m_isReload;
}
+ServiceWorkerClient* FetchEvent::client() const
+{
+ return m_client;
+}
+
void FetchEvent::respondWith(ScriptState* scriptState, const ScriptValue& value, ExceptionState& exceptionState)
{
stopImmediatePropagation();
@@ -60,6 +65,8 @@ FetchEvent::FetchEvent(const AtomicString& type, const FetchEventInit& initializ
{
if (initializer.hasRequest())
m_request = initializer.request();
+ if (initializer.hasClient())
+ m_client = initializer.client();
m_isReload = initializer.isReload();
}

Powered by Google App Engine
This is Rietveld 408576698