OLD | NEW |
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_BROWSER_SERVICE_WORKER_SERVICE_WORKER_DISPATCHER_HOST_H_ | 5 #ifndef CONTENT_BROWSER_SERVICE_WORKER_SERVICE_WORKER_DISPATCHER_HOST_H_ |
6 #define CONTENT_BROWSER_SERVICE_WORKER_SERVICE_WORKER_DISPATCHER_HOST_H_ | 6 #define CONTENT_BROWSER_SERVICE_WORKER_SERVICE_WORKER_DISPATCHER_HOST_H_ |
7 | 7 |
8 #include <vector> | 8 #include <vector> |
9 | 9 |
10 #include "base/id_map.h" | 10 #include "base/id_map.h" |
11 #include "base/memory/weak_ptr.h" | 11 #include "base/memory/weak_ptr.h" |
12 #include "base/strings/string16.h" | 12 #include "base/strings/string16.h" |
| 13 #include "content/browser/service_worker/service_worker_mojo_event_dispatcher.h" |
13 #include "content/browser/service_worker/service_worker_registration_status.h" | 14 #include "content/browser/service_worker/service_worker_registration_status.h" |
14 #include "content/common/service_worker/service_worker_types.h" | 15 #include "content/common/service_worker/service_worker_types.h" |
15 #include "content/public/browser/browser_message_filter.h" | 16 #include "content/public/browser/browser_message_filter.h" |
16 | 17 |
17 class GURL; | 18 class GURL; |
18 struct EmbeddedWorkerHostMsg_ReportConsoleMessage_Params; | 19 struct EmbeddedWorkerHostMsg_ReportConsoleMessage_Params; |
19 | 20 |
20 namespace content { | 21 namespace content { |
21 | 22 |
22 class MessagePortMessageFilter; | 23 class MessagePortMessageFilter; |
(...skipping 167 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
190 ServiceWorkerStatusCode status); | 191 ServiceWorkerStatusCode status); |
191 | 192 |
192 void SendGetRegistrationsError(int thread_id, | 193 void SendGetRegistrationsError(int thread_id, |
193 int request_id, | 194 int request_id, |
194 ServiceWorkerStatusCode status); | 195 ServiceWorkerStatusCode status); |
195 | 196 |
196 ServiceWorkerContextCore* GetContext(); | 197 ServiceWorkerContextCore* GetContext(); |
197 | 198 |
198 int render_process_id_; | 199 int render_process_id_; |
199 MessagePortMessageFilter* const message_port_message_filter_; | 200 MessagePortMessageFilter* const message_port_message_filter_; |
| 201 scoped_ptr<ServiceWorkerMojoEventDispatcher> mojo_event_dispatcher_; |
200 ResourceContext* resource_context_; | 202 ResourceContext* resource_context_; |
201 scoped_refptr<ServiceWorkerContextWrapper> context_wrapper_; | 203 scoped_refptr<ServiceWorkerContextWrapper> context_wrapper_; |
202 | 204 |
203 IDMap<ServiceWorkerHandle, IDMapOwnPointer> handles_; | 205 IDMap<ServiceWorkerHandle, IDMapOwnPointer> handles_; |
204 IDMap<ServiceWorkerRegistrationHandle, IDMapOwnPointer> registration_handles_; | 206 IDMap<ServiceWorkerRegistrationHandle, IDMapOwnPointer> registration_handles_; |
205 | 207 |
206 bool channel_ready_; // True after BrowserMessageFilter::sender_ != NULL. | 208 bool channel_ready_; // True after BrowserMessageFilter::sender_ != NULL. |
207 ScopedVector<IPC::Message> pending_messages_; | 209 ScopedVector<IPC::Message> pending_messages_; |
208 | 210 |
209 DISALLOW_COPY_AND_ASSIGN(ServiceWorkerDispatcherHost); | 211 DISALLOW_COPY_AND_ASSIGN(ServiceWorkerDispatcherHost); |
210 }; | 212 }; |
211 | 213 |
212 } // namespace content | 214 } // namespace content |
213 | 215 |
214 #endif // CONTENT_BROWSER_SERVICE_WORKER_SERVICE_WORKER_DISPATCHER_HOST_H_ | 216 #endif // CONTENT_BROWSER_SERVICE_WORKER_SERVICE_WORKER_DISPATCHER_HOST_H_ |
OLD | NEW |