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

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: rebase, rename 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
« no previous file with comments | « content/browser/service_worker/service_worker_version.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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 fdf35e9398dd7940023e04de3540746fbf3a8c8f..7c33cb28ec28fcfccecd046ac9ef7e7f0550c425 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_, OnDevToolsRoutingIdChanged(this));
+}
+
void ServiceWorkerVersion::OnReportException(
const base::string16& error_message,
int line_number,
« no previous file with comments | « content/browser/service_worker/service_worker_version.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698