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

Unified Diff: content/child/service_worker/web_service_worker_impl.h

Issue 249143002: ServiceWorker: Let the proxy drive state change (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 years, 8 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/child/service_worker/web_service_worker_impl.h
diff --git a/content/child/service_worker/web_service_worker_impl.h b/content/child/service_worker/web_service_worker_impl.h
index f6e00a1bcbc8685c093972fc43f2dc033ca69ee8..64a135ec60ba6cf8edc9a2924af65de720410ef8 100644
--- a/content/child/service_worker/web_service_worker_impl.h
+++ b/content/child/service_worker/web_service_worker_impl.h
@@ -28,15 +28,18 @@ class WebServiceWorkerImpl
ThreadSafeSender* thread_safe_sender);
virtual ~WebServiceWorkerImpl();
- void SetState(blink::WebServiceWorkerState new_state);
-
virtual void setProxy(blink::WebServiceWorkerProxy* proxy);
+ virtual void setState(blink::WebServiceWorkerState new_state);
virtual blink::WebURL scope() const;
virtual blink::WebURL url() const;
virtual blink::WebServiceWorkerState state() const;
virtual void postMessage(const blink::WebString& message,
blink::WebMessagePortChannelArray* channels);
+ // Informs the proxy that the state changed on the browser side. The proxy may
+ // queue the change and call setState() to commit it when ready.
+ void OnStateChanged(blink::WebServiceWorkerState new_state);
+
private:
const int handle_id_;
const GURL scope_;
« no previous file with comments | « content/child/service_worker/service_worker_dispatcher.cc ('k') | content/child/service_worker/web_service_worker_impl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698