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

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

Issue 985663002: Implement ServiceWorkerRegistration related DevTools events [2/2 chromium] (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: override Created 5 years, 9 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_internals_ui.cc
diff --git a/content/browser/service_worker/service_worker_internals_ui.cc b/content/browser/service_worker/service_worker_internals_ui.cc
index 4e3506b6fec13c74863e0686192f9b4ac2b8b40d..4a3d0fe0b225b611e6a2a958f83d0652e523a721 100644
--- a/content/browser/service_worker/service_worker_internals_ui.cc
+++ b/content/browser/service_worker/service_worker_internals_ui.cc
@@ -304,27 +304,11 @@ class ServiceWorkerInternalsUI::PartitionObserver
: partition_id_(partition_id), web_ui_(web_ui) {}
~PartitionObserver() override {}
// ServiceWorkerContextObserver overrides:
- void OnWorkerStarted(int64 version_id,
- int process_id,
- int thread_id) override {
- DCHECK(BrowserThread::CurrentlyOn(BrowserThread::UI));
- web_ui_->CallJavascriptFunction(
- "serviceworker.onWorkerStarted",
- FundamentalValue(partition_id_),
- StringValue(base::Int64ToString(version_id)),
- FundamentalValue(process_id),
- FundamentalValue(thread_id));
- }
- void OnWorkerStopped(int64 version_id,
- int process_id,
- int thread_id) override {
+ void OnRunningStateChanged(int64 version_id) override {
DCHECK(BrowserThread::CurrentlyOn(BrowserThread::UI));
web_ui_->CallJavascriptFunction(
- "serviceworker.onWorkerStopped",
- FundamentalValue(partition_id_),
- StringValue(base::Int64ToString(version_id)),
- FundamentalValue(process_id),
- FundamentalValue(thread_id));
+ "serviceworker.onRunningStateChanged", FundamentalValue(partition_id_),
+ StringValue(base::Int64ToString(version_id)));
}
void OnVersionStateChanged(int64 version_id) override {
DCHECK(BrowserThread::CurrentlyOn(BrowserThread::UI));
@@ -372,7 +356,8 @@ class ServiceWorkerInternalsUI::PartitionObserver
web_ui_->CallJavascriptFunction("serviceworker.onConsoleMessageReported",
args.get());
}
- void OnRegistrationStored(const GURL& pattern) override {
+ void OnRegistrationStored(int64 registration_id,
+ const GURL& pattern) override {
DCHECK(BrowserThread::CurrentlyOn(BrowserThread::UI));
web_ui_->CallJavascriptFunction("serviceworker.onRegistrationStored",
StringValue(pattern.spec()));
« no previous file with comments | « content/browser/service_worker/service_worker_info.cc ('k') | content/browser/service_worker/service_worker_version.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698