OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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 // IPC messages for resource loading. | 5 // IPC messages for resource loading. |
6 // | 6 // |
7 // NOTE: All messages must send an |int request_id| as their first parameter. | 7 // NOTE: All messages must send an |int request_id| as their first parameter. |
8 | 8 |
9 // Multiply-included message file, hence no include guard. | 9 // Multiply-included message file, hence no include guard. |
10 #include "base/memory/shared_memory.h" | 10 #include "base/memory/shared_memory.h" |
(...skipping 195 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
206 // created before this navigation has been transferred to a new render view. | 206 // created before this navigation has been transferred to a new render view. |
207 // This serves the purpose of recycling the old request. | 207 // This serves the purpose of recycling the old request. |
208 // Unless this refers to a transferred navigation, these values are -1 and -1. | 208 // Unless this refers to a transferred navigation, these values are -1 and -1. |
209 IPC_STRUCT_MEMBER(int, transferred_request_child_id) | 209 IPC_STRUCT_MEMBER(int, transferred_request_child_id) |
210 IPC_STRUCT_MEMBER(int, transferred_request_request_id) | 210 IPC_STRUCT_MEMBER(int, transferred_request_request_id) |
211 | 211 |
212 // Whether or not we should allow the URL to download. | 212 // Whether or not we should allow the URL to download. |
213 IPC_STRUCT_MEMBER(bool, allow_download) | 213 IPC_STRUCT_MEMBER(bool, allow_download) |
214 IPC_STRUCT_END() | 214 IPC_STRUCT_END() |
215 | 215 |
| 216 // Parameters for a ResourceMsg_RequestComplete |
| 217 IPC_STRUCT_BEGIN(ResourceMsg_RequestCompleteData) |
| 218 // The error code. |
| 219 IPC_STRUCT_MEMBER(int, error_code) |
| 220 |
| 221 // Was ignored by the request handler. |
| 222 IPC_STRUCT_MEMBER(bool, was_ignored_by_handler) |
| 223 |
| 224 // A copy of the data requested exists in the cache |
| 225 IPC_STRUCT_MEMBER(bool, exists_in_cache) |
| 226 |
| 227 // Serialized security info; see content/common/ssl_status_serialization.h. |
| 228 IPC_STRUCT_MEMBER(std::string, security_info) |
| 229 |
| 230 // Time the request completed. |
| 231 IPC_STRUCT_MEMBER(base::TimeTicks, completion_time) |
| 232 IPC_STRUCT_END() |
| 233 |
216 // Resource messages sent from the browser to the renderer. | 234 // Resource messages sent from the browser to the renderer. |
217 | 235 |
218 // Sent when the headers are available for a resource request. | 236 // Sent when the headers are available for a resource request. |
219 IPC_MESSAGE_CONTROL2(ResourceMsg_ReceivedResponse, | 237 IPC_MESSAGE_CONTROL2(ResourceMsg_ReceivedResponse, |
220 int /* request_id */, | 238 int /* request_id */, |
221 content::ResourceResponseHead) | 239 content::ResourceResponseHead) |
222 | 240 |
223 // Sent when cached metadata from a resource request is ready. | 241 // Sent when cached metadata from a resource request is ready. |
224 IPC_MESSAGE_CONTROL2(ResourceMsg_ReceivedCachedMetadata, | 242 IPC_MESSAGE_CONTROL2(ResourceMsg_ReceivedCachedMetadata, |
225 int /* request_id */, | 243 int /* request_id */, |
(...skipping 41 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
267 | 285 |
268 // Sent when some data from a resource request has been downloaded to | 286 // Sent when some data from a resource request has been downloaded to |
269 // file. This is only called in the 'download_to_file' case and replaces | 287 // file. This is only called in the 'download_to_file' case and replaces |
270 // ResourceMsg_DataReceived in the call sequence in that case. | 288 // ResourceMsg_DataReceived in the call sequence in that case. |
271 IPC_MESSAGE_CONTROL3(ResourceMsg_DataDownloaded, | 289 IPC_MESSAGE_CONTROL3(ResourceMsg_DataDownloaded, |
272 int /* request_id */, | 290 int /* request_id */, |
273 int /* data_len */, | 291 int /* data_len */, |
274 int /* encoded_data_length */) | 292 int /* encoded_data_length */) |
275 | 293 |
276 // Sent when the request has been completed. | 294 // Sent when the request has been completed. |
277 IPC_MESSAGE_CONTROL5(ResourceMsg_RequestComplete, | 295 IPC_MESSAGE_CONTROL2(ResourceMsg_RequestComplete, |
278 int /* request_id */, | 296 int /* request_id */, |
279 int /* error_code */, | 297 ResourceMsg_RequestCompleteData) |
280 bool /* was_ignored_by_handler */, | |
281 std::string /* security info */, | |
282 base::TimeTicks /* completion_time */) | |
283 | 298 |
284 // Resource messages sent from the renderer to the browser. | 299 // Resource messages sent from the renderer to the browser. |
285 | 300 |
286 // Makes a resource request via the browser. | 301 // Makes a resource request via the browser. |
287 IPC_MESSAGE_ROUTED2(ResourceHostMsg_RequestResource, | 302 IPC_MESSAGE_ROUTED2(ResourceHostMsg_RequestResource, |
288 int /* request_id */, | 303 int /* request_id */, |
289 ResourceHostMsg_Request) | 304 ResourceHostMsg_Request) |
290 | 305 |
291 // Cancels a resource request with the ID given as the parameter. | 306 // Cancels a resource request with the ID given as the parameter. |
292 IPC_MESSAGE_CONTROL1(ResourceHostMsg_CancelRequest, | 307 IPC_MESSAGE_CONTROL1(ResourceHostMsg_CancelRequest, |
(...skipping 27 matching lines...) Expand all Loading... |
320 int /* request_id */) | 335 int /* request_id */) |
321 | 336 |
322 // Sent when the renderer process deletes a resource loader. | 337 // Sent when the renderer process deletes a resource loader. |
323 IPC_MESSAGE_CONTROL1(ResourceHostMsg_ReleaseDownloadedFile, | 338 IPC_MESSAGE_CONTROL1(ResourceHostMsg_ReleaseDownloadedFile, |
324 int /* request_id */) | 339 int /* request_id */) |
325 | 340 |
326 // Sent by the renderer when a resource request changes priority. | 341 // Sent by the renderer when a resource request changes priority. |
327 IPC_MESSAGE_CONTROL2(ResourceHostMsg_DidChangePriority, | 342 IPC_MESSAGE_CONTROL2(ResourceHostMsg_DidChangePriority, |
328 int /* request_id */, | 343 int /* request_id */, |
329 net::RequestPriority) | 344 net::RequestPriority) |
OLD | NEW |