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

Unified Diff: content/renderer/service_worker/service_worker_script_context.cc

Issue 849163002: ServiceWorker: Expose registration within ServiceWorkerGlobalScope [2/3] (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: remove dcheck Created 5 years, 11 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 | « content/renderer/service_worker/service_worker_script_context.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/renderer/service_worker/service_worker_script_context.cc
diff --git a/content/renderer/service_worker/service_worker_script_context.cc b/content/renderer/service_worker/service_worker_script_context.cc
index dd0d523b83710e5580cdf55f0dd1a68480c26eac..73f411121423c36724ebfc991cba4709b0dced0b 100644
--- a/content/renderer/service_worker/service_worker_script_context.cc
+++ b/content/renderer/service_worker/service_worker_script_context.cc
@@ -8,6 +8,7 @@
#include "base/logging.h"
#include "base/metrics/histogram.h"
#include "content/child/notifications/notification_data_conversions.h"
+#include "content/child/service_worker/web_service_worker_registration_impl.h"
#include "content/child/thread_safe_sender.h"
#include "content/child/webmessageportchannel_impl.h"
#include "content/common/message_port_messages.h"
@@ -115,6 +116,11 @@ void ServiceWorkerScriptContext::OnMessageReceived(
DCHECK(handled);
}
+void ServiceWorkerScriptContext::SetRegistrationInServiceWorkerGlobalScope(
+ scoped_ptr<WebServiceWorkerRegistrationImpl> registration) {
+ proxy_->setRegistration(registration.release());
+}
+
void ServiceWorkerScriptContext::DidHandleActivateEvent(
int request_id,
blink::WebServiceWorkerEventResult result) {
« no previous file with comments | « content/renderer/service_worker/service_worker_script_context.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698