| 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 <stdint.h> | 8 #include <stdint.h> |
| 9 | 9 |
| 10 #include <memory> | 10 #include <memory> |
| (...skipping 130 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 141 void OnDecrementServiceWorkerRefCount(int handle_id); | 141 void OnDecrementServiceWorkerRefCount(int handle_id); |
| 142 void OnIncrementRegistrationRefCount(int registration_handle_id); | 142 void OnIncrementRegistrationRefCount(int registration_handle_id); |
| 143 void OnDecrementRegistrationRefCount(int registration_handle_id); | 143 void OnDecrementRegistrationRefCount(int registration_handle_id); |
| 144 void OnPostMessageToWorker( | 144 void OnPostMessageToWorker( |
| 145 int handle_id, | 145 int handle_id, |
| 146 int provider_id, | 146 int provider_id, |
| 147 const base::string16& message, | 147 const base::string16& message, |
| 148 const url::Origin& source_origin, | 148 const url::Origin& source_origin, |
| 149 const std::vector<TransferredMessagePort>& sent_message_ports); | 149 const std::vector<TransferredMessagePort>& sent_message_ports); |
| 150 | 150 |
| 151 // TODO(nhiroki): Remove this after ExtendableMessageEvent is enabled by | |
| 152 // default (crbug.com/543198). | |
| 153 void OnDeprecatedPostMessageToWorker( | |
| 154 int handle_id, | |
| 155 const base::string16& message, | |
| 156 const std::vector<TransferredMessagePort>& sent_message_ports); | |
| 157 | |
| 158 void OnTerminateWorker(int handle_id); | 151 void OnTerminateWorker(int handle_id); |
| 159 | 152 |
| 160 void DispatchExtendableMessageEvent( | 153 void DispatchExtendableMessageEvent( |
| 161 scoped_refptr<ServiceWorkerVersion> worker, | 154 scoped_refptr<ServiceWorkerVersion> worker, |
| 162 const base::string16& message, | 155 const base::string16& message, |
| 163 const url::Origin& source_origin, | 156 const url::Origin& source_origin, |
| 164 const std::vector<TransferredMessagePort>& sent_message_ports, | 157 const std::vector<TransferredMessagePort>& sent_message_ports, |
| 165 ServiceWorkerProviderHost* sender_provider_host, | 158 ServiceWorkerProviderHost* sender_provider_host, |
| 166 const StatusCallback& callback); | 159 const StatusCallback& callback); |
| 167 template <typename SourceInfo> | 160 template <typename SourceInfo> |
| (...skipping 80 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 248 | 241 |
| 249 bool channel_ready_; // True after BrowserMessageFilter::sender_ != NULL. | 242 bool channel_ready_; // True after BrowserMessageFilter::sender_ != NULL. |
| 250 std::vector<std::unique_ptr<IPC::Message>> pending_messages_; | 243 std::vector<std::unique_ptr<IPC::Message>> pending_messages_; |
| 251 | 244 |
| 252 DISALLOW_COPY_AND_ASSIGN(ServiceWorkerDispatcherHost); | 245 DISALLOW_COPY_AND_ASSIGN(ServiceWorkerDispatcherHost); |
| 253 }; | 246 }; |
| 254 | 247 |
| 255 } // namespace content | 248 } // namespace content |
| 256 | 249 |
| 257 #endif // CONTENT_BROWSER_SERVICE_WORKER_SERVICE_WORKER_DISPATCHER_HOST_H_ | 250 #endif // CONTENT_BROWSER_SERVICE_WORKER_SERVICE_WORKER_DISPATCHER_HOST_H_ |
| OLD | NEW |