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 // Defines messages between the browser and worker process, as well as between | 5 // Defines messages between the browser and worker process, as well as between |
6 // the renderer and worker process. | 6 // the renderer and worker process. |
7 | 7 |
8 // Multiply-included message file, hence no include guard. | 8 // Multiply-included message file, hence no include guard. |
9 | 9 |
10 #include <string> | 10 #include <string> |
(...skipping 33 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
44 IPC_STRUCT_MEMBER(string16, source_url) | 44 IPC_STRUCT_MEMBER(string16, source_url) |
45 IPC_STRUCT_END() | 45 IPC_STRUCT_END() |
46 | 46 |
47 // Parameter structure for WorkerProcessMsg_CreateWorker. | 47 // Parameter structure for WorkerProcessMsg_CreateWorker. |
48 IPC_STRUCT_BEGIN(WorkerProcessMsg_CreateWorker_Params) | 48 IPC_STRUCT_BEGIN(WorkerProcessMsg_CreateWorker_Params) |
49 IPC_STRUCT_MEMBER(GURL, url) | 49 IPC_STRUCT_MEMBER(GURL, url) |
50 IPC_STRUCT_MEMBER(string16, name) | 50 IPC_STRUCT_MEMBER(string16, name) |
51 IPC_STRUCT_MEMBER(int, route_id) | 51 IPC_STRUCT_MEMBER(int, route_id) |
52 IPC_STRUCT_MEMBER(int, creator_process_id) | 52 IPC_STRUCT_MEMBER(int, creator_process_id) |
53 IPC_STRUCT_MEMBER(int64, shared_worker_appcache_id) | 53 IPC_STRUCT_MEMBER(int64, shared_worker_appcache_id) |
| 54 IPC_STRUCT_MEMBER(bool, is_controller) |
54 IPC_STRUCT_END() | 55 IPC_STRUCT_END() |
55 | 56 |
56 IPC_ENUM_TRAITS(WebKit::WebContentSecurityPolicyType) | 57 IPC_ENUM_TRAITS(WebKit::WebContentSecurityPolicyType) |
57 | 58 |
58 //----------------------------------------------------------------------------- | 59 //----------------------------------------------------------------------------- |
59 // WorkerProcess messages | 60 // WorkerProcess messages |
60 // These are messages sent from the browser to the worker process. | 61 // These are messages sent from the browser to the worker process. |
61 IPC_MESSAGE_CONTROL1(WorkerProcessMsg_CreateWorker, | 62 IPC_MESSAGE_CONTROL1(WorkerProcessMsg_CreateWorker, |
62 WorkerProcessMsg_CreateWorker_Params) | 63 WorkerProcessMsg_CreateWorker_Params) |
63 | 64 |
| 65 IPC_MESSAGE_ROUTED2(WorkerMsg_StartEmbeddedWorkerContext, |
| 66 GURL /* url */, |
| 67 std::string /* raw_source_code */) |
| 68 |
64 // Note: these Message Port related messages can also be sent to the | 69 // Note: these Message Port related messages can also be sent to the |
65 // renderer process. Putting them here since we don't have a shared place | 70 // renderer process. Putting them here since we don't have a shared place |
66 // like common_messages_internal.h | 71 // like common_messages_internal.h |
67 IPC_MESSAGE_ROUTED3(WorkerProcessMsg_Message, | 72 IPC_MESSAGE_ROUTED3(WorkerProcessMsg_Message, |
68 string16 /* message */, | 73 string16 /* message */, |
69 std::vector<int> /* sent_message_port_ids */, | 74 std::vector<int> /* sent_message_port_ids */, |
70 std::vector<int> /* new_routing_ids */) | 75 std::vector<int> /* new_routing_ids */) |
71 | 76 |
72 // Tells the Message Port Channel object that there are no more in-flight | 77 // Tells the Message Port Channel object that there are no more in-flight |
73 // messages arriving. | 78 // messages arriving. |
(...skipping 84 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
158 string16 /* message */, | 163 string16 /* message */, |
159 std::vector<int> /* sent_message_port_ids */, | 164 std::vector<int> /* sent_message_port_ids */, |
160 std::vector<int> /* new_routing_ids */) | 165 std::vector<int> /* new_routing_ids */) |
161 | 166 |
162 IPC_MESSAGE_ROUTED2(WorkerMsg_Connect, | 167 IPC_MESSAGE_ROUTED2(WorkerMsg_Connect, |
163 int /* sent_message_port_id */, | 168 int /* sent_message_port_id */, |
164 int /* routing_id */) | 169 int /* routing_id */) |
165 | 170 |
166 IPC_MESSAGE_ROUTED0(WorkerMsg_WorkerObjectDestroyed) | 171 IPC_MESSAGE_ROUTED0(WorkerMsg_WorkerObjectDestroyed) |
167 | 172 |
168 | |
169 //----------------------------------------------------------------------------- | 173 //----------------------------------------------------------------------------- |
170 // WorkerHost messages | 174 // WorkerHost messages |
171 // These are messages sent from the worker process to the renderer process. | 175 // These are messages sent from the worker process to the renderer process. |
172 // WorkerMsg_PostMessage is also sent here. | 176 // WorkerMsg_PostMessage is also sent here. |
173 IPC_MESSAGE_ROUTED3(WorkerHostMsg_PostExceptionToWorkerObject, | 177 IPC_MESSAGE_ROUTED3(WorkerHostMsg_PostExceptionToWorkerObject, |
174 string16 /* error_message */, | 178 string16 /* error_message */, |
175 int /* line_number */, | 179 int /* line_number */, |
176 string16 /* source_url*/) | 180 string16 /* source_url*/) |
177 | 181 |
178 IPC_MESSAGE_ROUTED1(WorkerHostMsg_PostConsoleMessageToWorkerObject, | 182 IPC_MESSAGE_ROUTED1(WorkerHostMsg_PostConsoleMessageToWorkerObject, |
179 WorkerHostMsg_PostConsoleMessageToWorkerObject_Params) | 183 WorkerHostMsg_PostConsoleMessageToWorkerObject_Params) |
180 | 184 |
181 IPC_MESSAGE_ROUTED1(WorkerHostMsg_ConfirmMessageFromWorkerObject, | 185 IPC_MESSAGE_ROUTED1(WorkerHostMsg_ConfirmMessageFromWorkerObject, |
182 bool /* bool has_pending_activity */) | 186 bool /* bool has_pending_activity */) |
183 | 187 |
184 IPC_MESSAGE_ROUTED1(WorkerHostMsg_ReportPendingActivity, | 188 IPC_MESSAGE_ROUTED1(WorkerHostMsg_ReportPendingActivity, |
185 bool /* bool has_pending_activity */) | 189 bool /* bool has_pending_activity */) |
186 | 190 |
187 IPC_MESSAGE_CONTROL1(WorkerHostMsg_WorkerContextClosed, | 191 IPC_MESSAGE_CONTROL1(WorkerHostMsg_WorkerContextClosed, |
188 int /* worker_route_id */) | 192 int /* worker_route_id */) |
189 IPC_MESSAGE_ROUTED0(WorkerHostMsg_WorkerContextDestroyed) | 193 IPC_MESSAGE_ROUTED0(WorkerHostMsg_WorkerContextDestroyed) |
OLD | NEW |