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

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

Issue 380093002: Update installed ServiceWorkers. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 years, 5 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.h
diff --git a/content/browser/service_worker/service_worker_version.h b/content/browser/service_worker/service_worker_version.h
index 5c24b2af1db97bf899cde8e20a95a66f340ab168..113bdb0022095b6414a14d9626523f2eb23deee0 100644
--- a/content/browser/service_worker/service_worker_version.h
+++ b/content/browser/service_worker/service_worker_version.h
@@ -63,27 +63,33 @@ class CONTENT_EXPORT ServiceWorkerVersion
INSTALLING, // Install event is dispatched and being handled.
INSTALLED, // Install event is finished and is ready to be activated.
ACTIVATING, // Activate event is dispatched and being handled.
- ACTIVATED, // Activation is finished and can run as activated.
+ ACTIVATED, // Activation is finished and can run as activated.
REDUNDANT, // The version is no longer running as activated, due to
// unregistration or replace.
};
class Listener {
public:
- virtual void OnWorkerStarted(ServiceWorkerVersion* version) {};
- virtual void OnWorkerStopped(ServiceWorkerVersion* version) {};
- virtual void OnVersionStateChanged(ServiceWorkerVersion* version) {};
+ virtual void OnWorkerStarted(ServiceWorkerVersion* version) {}
+ virtual void OnWorkerStopped(ServiceWorkerVersion* version) {}
+ virtual void OnVersionStateChanged(ServiceWorkerVersion* version) {}
virtual void OnErrorReported(ServiceWorkerVersion* version,
const base::string16& error_message,
int line_number,
int column_number,
- const GURL& source_url) {};
+ const GURL& source_url) {}
virtual void OnReportConsoleMessage(ServiceWorkerVersion* version,
int source_identifier,
int message_level,
const base::string16& message,
int line_number,
- const GURL& source_url) {};
+ const GURL& source_url) {}
+
+ // Fires when a version transitions from having a controllee to not.
+ virtual void OnNoControllees(ServiceWorkerVersion* version) {}
+
+ protected:
+ virtual ~Listener() {}
};
ServiceWorkerVersion(

Powered by Google App Engine
This is Rietveld 408576698