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

Side by Side Diff: content/renderer/service_worker/embedded_worker_context_client.h

Issue 717353004: ServiceWorker: Add support for .skipWaiting and controllerchange event(2/3) (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: do not replace other registerations Created 6 years, 1 month 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 unified diff | Download patch
OLDNEW
1 // Copyright 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef CONTENT_RENDERER_SERVICE_WORKER_EMBEDDED_WORKER_CONTEXT_CLIENT_H_ 5 #ifndef CONTENT_RENDERER_SERVICE_WORKER_EMBEDDED_WORKER_CONTEXT_CLIENT_H_
6 #define CONTENT_RENDERER_SERVICE_WORKER_EMBEDDED_WORKER_CONTEXT_CLIENT_H_ 6 #define CONTENT_RENDERER_SERVICE_WORKER_EMBEDDED_WORKER_CONTEXT_CLIENT_H_
7 7
8 #include "base/memory/ref_counted.h" 8 #include "base/memory/ref_counted.h"
9 #include "base/memory/weak_ptr.h" 9 #include "base/memory/weak_ptr.h"
10 #include "base/strings/string16.h" 10 #include "base/strings/string16.h"
(...skipping 82 matching lines...) Expand 10 before | Expand all | Expand 10 after
93 const blink::WebServiceWorkerResponse& response); 93 const blink::WebServiceWorkerResponse& response);
94 virtual void didHandlePushEvent(int request_id, 94 virtual void didHandlePushEvent(int request_id,
95 blink::WebServiceWorkerEventResult result); 95 blink::WebServiceWorkerEventResult result);
96 virtual void didHandleSyncEvent(int request_id); 96 virtual void didHandleSyncEvent(int request_id);
97 virtual blink::WebServiceWorkerNetworkProvider* 97 virtual blink::WebServiceWorkerNetworkProvider*
98 createServiceWorkerNetworkProvider(blink::WebDataSource* data_source); 98 createServiceWorkerNetworkProvider(blink::WebDataSource* data_source);
99 virtual void postMessageToClient( 99 virtual void postMessageToClient(
100 int client_id, 100 int client_id,
101 const blink::WebString& message, 101 const blink::WebString& message,
102 blink::WebMessagePortChannelArray* channels); 102 blink::WebMessagePortChannelArray* channels);
103 virtual void skipWaiting(blink::WebCallback* callback);
103 104
104 // TODO: Implement DevTools related method overrides. 105 // TODO: Implement DevTools related method overrides.
105 106
106 int embedded_worker_id() const { return embedded_worker_id_; } 107 int embedded_worker_id() const { return embedded_worker_id_; }
107 base::MessageLoopProxy* main_thread_proxy() const { 108 base::MessageLoopProxy* main_thread_proxy() const {
108 return main_thread_proxy_.get(); 109 return main_thread_proxy_.get();
109 } 110 }
110 ThreadSafeSender* thread_safe_sender() { return sender_.get(); } 111 ThreadSafeSender* thread_safe_sender() { return sender_.get(); }
111 112
112 private: 113 private:
(...skipping 14 matching lines...) Expand all
127 scoped_ptr<ServiceWorkerScriptContext> script_context_; 128 scoped_ptr<ServiceWorkerScriptContext> script_context_;
128 129
129 base::WeakPtrFactory<EmbeddedWorkerContextClient> weak_factory_; 130 base::WeakPtrFactory<EmbeddedWorkerContextClient> weak_factory_;
130 131
131 DISALLOW_COPY_AND_ASSIGN(EmbeddedWorkerContextClient); 132 DISALLOW_COPY_AND_ASSIGN(EmbeddedWorkerContextClient);
132 }; 133 };
133 134
134 } // namespace content 135 } // namespace content
135 136
136 #endif // CONTENT_RENDERER_SERVICE_WORKER_EMBEDDED_WORKER_CONTEXT_CLIENT_H_ 137 #endif // CONTENT_RENDERER_SERVICE_WORKER_EMBEDDED_WORKER_CONTEXT_CLIENT_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698