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

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

Issue 2748213003: Service Worker event dispatcher for Background Fetch (Closed)
Patch Set: uma fix Created 3 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 unified diff | Download patch
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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_SERVICE_WORKER_CONTEXT_CLIENT_H_ 5 #ifndef CONTENT_RENDERER_SERVICE_WORKER_SERVICE_WORKER_CONTEXT_CLIENT_H_
6 #define CONTENT_RENDERER_SERVICE_WORKER_SERVICE_WORKER_CONTEXT_CLIENT_H_ 6 #define CONTENT_RENDERER_SERVICE_WORKER_SERVICE_WORKER_CONTEXT_CLIENT_H_
7 7
8 #include <stddef.h> 8 #include <stddef.h>
9 #include <stdint.h> 9 #include <stdint.h>
10 10
(...skipping 123 matching lines...) Expand 10 before | Expand all | Expand 10 after
134 const blink::WebString& source_url) override; 134 const blink::WebString& source_url) override;
135 void sendDevToolsMessage(int session_id, 135 void sendDevToolsMessage(int session_id,
136 int call_id, 136 int call_id,
137 const blink::WebString& message, 137 const blink::WebString& message,
138 const blink::WebString& state) override; 138 const blink::WebString& state) override;
139 blink::WebDevToolsAgentClient::WebKitClientMessageLoop* 139 blink::WebDevToolsAgentClient::WebKitClientMessageLoop*
140 createDevToolsMessageLoop() override; 140 createDevToolsMessageLoop() override;
141 void didHandleActivateEvent(int request_id, 141 void didHandleActivateEvent(int request_id,
142 blink::WebServiceWorkerEventResult, 142 blink::WebServiceWorkerEventResult,
143 double dispatch_event_time) override; 143 double dispatch_event_time) override;
144 void didHandleBackgroundFetchAbortEvent(int request_id,
145 blink::WebServiceWorkerEventResult,
146 double dispatch_event_time) override;
147 void didHandleBackgroundFetchClickEvent(int request_id,
148 blink::WebServiceWorkerEventResult,
149 double dispatch_event_time) override;
144 void didHandleExtendableMessageEvent( 150 void didHandleExtendableMessageEvent(
145 int request_id, 151 int request_id,
146 blink::WebServiceWorkerEventResult result, 152 blink::WebServiceWorkerEventResult result,
147 double dispatch_event_time) override; 153 double dispatch_event_time) override;
148 void didHandleInstallEvent(int request_id, 154 void didHandleInstallEvent(int request_id,
149 blink::WebServiceWorkerEventResult result, 155 blink::WebServiceWorkerEventResult result,
150 double event_dispatch_time) override; 156 double event_dispatch_time) override;
151 void respondToFetchEvent(int fetch_event_id, 157 void respondToFetchEvent(int fetch_event_id,
152 double event_dispatch_time) override; 158 double event_dispatch_time) override;
153 void respondToFetchEvent(int fetch_event_id, 159 void respondToFetchEvent(int fetch_event_id,
(...skipping 52 matching lines...) Expand 10 before | Expand all | Expand 10 after
206 212
207 void Send(IPC::Message* message); 213 void Send(IPC::Message* message);
208 void SendWorkerStarted(); 214 void SendWorkerStarted();
209 void SetRegistrationInServiceWorkerGlobalScope( 215 void SetRegistrationInServiceWorkerGlobalScope(
210 const ServiceWorkerRegistrationObjectInfo& info, 216 const ServiceWorkerRegistrationObjectInfo& info,
211 const ServiceWorkerVersionAttributes& attrs); 217 const ServiceWorkerVersionAttributes& attrs);
212 218
213 // mojom::ServiceWorkerEventDispatcher 219 // mojom::ServiceWorkerEventDispatcher
214 void DispatchActivateEvent( 220 void DispatchActivateEvent(
215 const DispatchActivateEventCallback& callback) override; 221 const DispatchActivateEventCallback& callback) override;
222 void DispatchBackgroundFetchAbortEvent(
223 const std::string& tag,
224 const DispatchBackgroundFetchAbortEventCallback& callback) override;
225 void DispatchBackgroundFetchClickEvent(
226 const std::string& tag,
227 mojom::BackgroundFetchState state,
228 const DispatchBackgroundFetchClickEventCallback& callback) override;
216 void DispatchExtendableMessageEvent( 229 void DispatchExtendableMessageEvent(
217 mojom::ExtendableMessageEventPtr event, 230 mojom::ExtendableMessageEventPtr event,
218 const DispatchExtendableMessageEventCallback& callback) override; 231 const DispatchExtendableMessageEventCallback& callback) override;
219 void DispatchFetchEvent(int fetch_event_id, 232 void DispatchFetchEvent(int fetch_event_id,
220 const ServiceWorkerFetchRequest& request, 233 const ServiceWorkerFetchRequest& request,
221 mojom::FetchEventPreloadHandlePtr preload_handle, 234 mojom::FetchEventPreloadHandlePtr preload_handle,
222 const DispatchFetchEventCallback& callback) override; 235 const DispatchFetchEventCallback& callback) override;
223 void DispatchNotificationClickEvent( 236 void DispatchNotificationClickEvent(
224 const std::string& notification_id, 237 const std::string& notification_id,
225 const PlatformNotificationData& notification_data, 238 const PlatformNotificationData& notification_data,
(...skipping 84 matching lines...) Expand 10 before | Expand all | Expand 10 after
310 // Initialized on the worker thread in workerContextStarted and 323 // Initialized on the worker thread in workerContextStarted and
311 // destructed on the worker thread in willDestroyWorkerContext. 324 // destructed on the worker thread in willDestroyWorkerContext.
312 std::unique_ptr<WorkerContextData> context_; 325 std::unique_ptr<WorkerContextData> context_;
313 326
314 DISALLOW_COPY_AND_ASSIGN(ServiceWorkerContextClient); 327 DISALLOW_COPY_AND_ASSIGN(ServiceWorkerContextClient);
315 }; 328 };
316 329
317 } // namespace content 330 } // namespace content
318 331
319 #endif // CONTENT_RENDERER_SERVICE_WORKER_SERVICE_WORKER_CONTEXT_CLIENT_H_ 332 #endif // CONTENT_RENDERER_SERVICE_WORKER_SERVICE_WORKER_CONTEXT_CLIENT_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698