| OLD | NEW |
| 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 // Message definition file, included multiple times, hence no include guard. | 5 // Message definition file, included multiple times, hence no include guard. |
| 6 | 6 |
| 7 #include <string> | 7 #include <string> |
| 8 #include <vector> | 8 #include <vector> |
| 9 | 9 |
| 10 #include "base/strings/string16.h" | 10 #include "base/strings/string16.h" |
| (...skipping 84 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 95 int /* provider_id */) | 95 int /* provider_id */) |
| 96 | 96 |
| 97 // Informs the browser of a ServiceWorkerProvider being destroyed. | 97 // Informs the browser of a ServiceWorkerProvider being destroyed. |
| 98 IPC_MESSAGE_CONTROL1(ServiceWorkerHostMsg_ProviderDestroyed, | 98 IPC_MESSAGE_CONTROL1(ServiceWorkerHostMsg_ProviderDestroyed, |
| 99 int /* provider_id */) | 99 int /* provider_id */) |
| 100 | 100 |
| 101 // Increments and decrements the ServiceWorker object's reference | 101 // Increments and decrements the ServiceWorker object's reference |
| 102 // counting in the browser side. The ServiceWorker object is created | 102 // counting in the browser side. The ServiceWorker object is created |
| 103 // with ref-count==1 initially. | 103 // with ref-count==1 initially. |
| 104 IPC_MESSAGE_CONTROL1(ServiceWorkerHostMsg_IncrementServiceWorkerRefCount, | 104 IPC_MESSAGE_CONTROL1(ServiceWorkerHostMsg_IncrementServiceWorkerRefCount, |
| 105 int /* registration_handle_id */) |
| 106 IPC_MESSAGE_CONTROL1(ServiceWorkerHostMsg_DecrementServiceWorkerRefCount, |
| 107 int /* registration_handle_id */) |
| 108 |
| 109 // Increments and decrements the ServiceWorkerRegistration object's reference |
| 110 // counting in the browser side. The registration object is created with |
| 111 // ref-count==1 initially. |
| 112 IPC_MESSAGE_CONTROL1(ServiceWorkerHostMsg_IncrementRegistrationRefCount, |
| 105 int /* handle_id */) | 113 int /* handle_id */) |
| 106 IPC_MESSAGE_CONTROL1(ServiceWorkerHostMsg_DecrementServiceWorkerRefCount, | 114 IPC_MESSAGE_CONTROL1(ServiceWorkerHostMsg_DecrementRegistrationRefCount, |
| 107 int /* handle_id */) | 115 int /* handle_id */) |
| 108 | 116 |
| 109 // Informs the browser that |provider_id| is associated | 117 // Informs the browser that |provider_id| is associated |
| 110 // with a service worker script running context and | 118 // with a service worker script running context and |
| 111 // |version_id| identifies which ServcieWorkerVersion. | 119 // |version_id| identifies which ServcieWorkerVersion. |
| 112 IPC_MESSAGE_CONTROL2(ServiceWorkerHostMsg_SetVersionId, | 120 IPC_MESSAGE_CONTROL2(ServiceWorkerHostMsg_SetVersionId, |
| 113 int /* provider_id */, | 121 int /* provider_id */, |
| 114 int64 /* version_id */) | 122 int64 /* version_id */) |
| 115 | 123 |
| 116 // Informs the browser that event handling has finished. | 124 // Informs the browser that event handling has finished. |
| (...skipping 46 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 163 | 171 |
| 164 //--------------------------------------------------------------------------- | 172 //--------------------------------------------------------------------------- |
| 165 // Messages sent from the browser to the child process. | 173 // Messages sent from the browser to the child process. |
| 166 // | 174 // |
| 167 // NOTE: All ServiceWorkerMsg messages not sent via EmbeddedWorker must have | 175 // NOTE: All ServiceWorkerMsg messages not sent via EmbeddedWorker must have |
| 168 // a thread_id as their first field so that ServiceWorkerMessageFilter can | 176 // a thread_id as their first field so that ServiceWorkerMessageFilter can |
| 169 // extract it and dispatch the message to the correct ServiceWorkerDispatcher | 177 // extract it and dispatch the message to the correct ServiceWorkerDispatcher |
| 170 // on the correct thread. | 178 // on the correct thread. |
| 171 | 179 |
| 172 // Response to ServiceWorkerMsg_RegisterServiceWorker. | 180 // Response to ServiceWorkerMsg_RegisterServiceWorker. |
| 173 IPC_MESSAGE_CONTROL3(ServiceWorkerMsg_ServiceWorkerRegistered, | 181 IPC_MESSAGE_CONTROL4(ServiceWorkerMsg_ServiceWorkerRegistered, |
| 174 int /* thread_id */, | 182 int /* thread_id */, |
| 175 int /* request_id */, | 183 int /* request_id */, |
| 184 int /* registration_handle_id */, |
| 176 content::ServiceWorkerObjectInfo) | 185 content::ServiceWorkerObjectInfo) |
| 177 | 186 |
| 178 // Response to ServiceWorkerMsg_UnregisterServiceWorker. | 187 // Response to ServiceWorkerMsg_UnregisterServiceWorker. |
| 179 IPC_MESSAGE_CONTROL2(ServiceWorkerMsg_ServiceWorkerUnregistered, | 188 IPC_MESSAGE_CONTROL2(ServiceWorkerMsg_ServiceWorkerUnregistered, |
| 180 int /* thread_id */, | 189 int /* thread_id */, |
| 181 int /* request_id */) | 190 int /* request_id */) |
| 182 | 191 |
| 183 // Sent when any kind of registration error occurs during a | 192 // Sent when any kind of registration error occurs during a |
| 184 // RegisterServiceWorker / UnregisterServiceWorker handler above. | 193 // RegisterServiceWorker / UnregisterServiceWorker handler above. |
| 185 IPC_MESSAGE_CONTROL4(ServiceWorkerMsg_ServiceWorkerRegistrationError, | 194 IPC_MESSAGE_CONTROL4(ServiceWorkerMsg_ServiceWorkerRegistrationError, |
| 186 int /* thread_id */, | 195 int /* thread_id */, |
| 187 int /* request_id */, | 196 int /* request_id */, |
| 188 blink::WebServiceWorkerError::ErrorType /* code */, | 197 blink::WebServiceWorkerError::ErrorType /* code */, |
| 189 base::string16 /* message */) | 198 base::string16 /* message */) |
| 190 | 199 |
| 191 // Informs the child process that the ServiceWorker's state has changed. | 200 // Informs the child process that the ServiceWorker's state has changed. |
| 192 IPC_MESSAGE_CONTROL3(ServiceWorkerMsg_ServiceWorkerStateChanged, | 201 IPC_MESSAGE_CONTROL3(ServiceWorkerMsg_ServiceWorkerStateChanged, |
| 193 int /* thread_id */, | 202 int /* thread_id */, |
| 194 int /* handle_id */, | 203 int /* handle_id */, |
| 195 blink::WebServiceWorkerState) | 204 blink::WebServiceWorkerState) |
| 196 | 205 |
| 197 // Tells the child process to set service workers for the given provider. | 206 // Tells the child process to set service workers for the given provider. |
| 198 IPC_MESSAGE_CONTROL4(ServiceWorkerMsg_SetVersionAttributes, | 207 IPC_MESSAGE_CONTROL5(ServiceWorkerMsg_SetVersionAttributes, |
| 199 int /* thread_id */, | 208 int /* thread_id */, |
| 200 int /* provider_id */, | 209 int /* provider_id */, |
| 210 int /* registration_handle_id */, |
| 201 int /* changed_mask */, | 211 int /* changed_mask */, |
| 202 content::ServiceWorkerVersionAttributes) | 212 content::ServiceWorkerVersionAttributes) |
| 203 | 213 |
| 204 // Tells the child process to set the controller ServiceWorker for the given | 214 // Tells the child process to set the controller ServiceWorker for the given |
| 205 // provider. | 215 // provider. |
| 206 IPC_MESSAGE_CONTROL3(ServiceWorkerMsg_SetControllerServiceWorker, | 216 IPC_MESSAGE_CONTROL3(ServiceWorkerMsg_SetControllerServiceWorker, |
| 207 int /* thread_id */, | 217 int /* thread_id */, |
| 208 int /* provider_id */, | 218 int /* provider_id */, |
| 209 content::ServiceWorkerObjectInfo) | 219 content::ServiceWorkerObjectInfo) |
| 210 | 220 |
| (...skipping 53 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 264 blink::WebServiceWorkerCacheError /* reason */) | 274 blink::WebServiceWorkerCacheError /* reason */) |
| 265 IPC_MESSAGE_CONTROL2(ServiceWorkerMsg_CacheStorageCreateError, | 275 IPC_MESSAGE_CONTROL2(ServiceWorkerMsg_CacheStorageCreateError, |
| 266 int /* request_id */, | 276 int /* request_id */, |
| 267 blink::WebServiceWorkerCacheError /* reason */) | 277 blink::WebServiceWorkerCacheError /* reason */) |
| 268 IPC_MESSAGE_CONTROL2(ServiceWorkerMsg_CacheStorageDeleteError, | 278 IPC_MESSAGE_CONTROL2(ServiceWorkerMsg_CacheStorageDeleteError, |
| 269 int /* request_id */, | 279 int /* request_id */, |
| 270 blink::WebServiceWorkerCacheError /* reason */) | 280 blink::WebServiceWorkerCacheError /* reason */) |
| 271 IPC_MESSAGE_CONTROL2(ServiceWorkerMsg_CacheStorageKeysError, | 281 IPC_MESSAGE_CONTROL2(ServiceWorkerMsg_CacheStorageKeysError, |
| 272 int /* request_id */, | 282 int /* request_id */, |
| 273 blink::WebServiceWorkerCacheError /* reason */) | 283 blink::WebServiceWorkerCacheError /* reason */) |
| OLD | NEW |