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

Unified Diff: content/browser/service_worker/service_worker_version.cc

Issue 2365053002: Notify ServiceWorkerContextWatcher about routing ids of ServiceWorkerVersion and their updates. (Closed)
Patch Set: live updates Created 4 years, 3 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: content/browser/service_worker/service_worker_version.cc
diff --git a/content/browser/service_worker/service_worker_version.cc b/content/browser/service_worker/service_worker_version.cc
index 7fe73cbae3b183810dffdbe002d05cb3f0129fb9..a1fbee8aa720a799f3dd67bbbb561dcd587697c1 100644
--- a/content/browser/service_worker/service_worker_version.cc
+++ b/content/browser/service_worker/service_worker_version.cc
@@ -317,9 +317,9 @@ ServiceWorkerVersion::ServiceWorkerVersion(
DCHECK(context_);
DCHECK(registration);
DCHECK(script_url_.is_valid());
- context_->AddLiveVersion(this);
embedded_worker_ = context_->embedded_worker_registry()->CreateWorker();
embedded_worker_->AddListener(this);
+ context_->AddLiveVersion(this);
}
ServiceWorkerVersion::~ServiceWorkerVersion() {
@@ -868,6 +868,10 @@ void ServiceWorkerVersion::OnScriptLoadFailed() {
UMA_HISTOGRAM_BOOLEAN("ServiceWorker.ScriptLoadSuccess", false);
}
+void ServiceWorkerVersion::OnRegisteredToDevToolsManager() {
+ FOR_EACH_OBSERVER(Listener, listeners_, OnRoutingIdsChanged(this));
horo 2016/09/26 01:30:05 OnDevToolsRoutingIdChanged
dgozman 2016/09/26 15:49:12 Done.
+}
+
void ServiceWorkerVersion::OnReportException(
const base::string16& error_message,
int line_number,

Powered by Google App Engine
This is Rietveld 408576698