OLD | NEW |
1 // Copyright (c) 2009 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2009 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 CHROME_BROWSER_WORKER_HOST_WORKER_PROCESS_HOST_H_ | 5 #ifndef CHROME_BROWSER_WORKER_HOST_WORKER_PROCESS_HOST_H_ |
6 #define CHROME_BROWSER_WORKER_HOST_WORKER_PROCESS_HOST_H_ | 6 #define CHROME_BROWSER_WORKER_HOST_WORKER_PROCESS_HOST_H_ |
7 #pragma once | 7 #pragma once |
8 | 8 |
9 #include <list> | 9 #include <list> |
10 #include <vector> | 10 #include <vector> |
(...skipping 167 matching lines...) Loading... |
178 static CallbackWithReturnValue<int>::Type* GetNextRouteIdCallback( | 178 static CallbackWithReturnValue<int>::Type* GetNextRouteIdCallback( |
179 IPC::Message::Sender* sender); | 179 IPC::Message::Sender* sender); |
180 | 180 |
181 // Relays a message to the given endpoint. Takes care of parsing the message | 181 // Relays a message to the given endpoint. Takes care of parsing the message |
182 // if it contains a message port and sending it a valid route id. | 182 // if it contains a message port and sending it a valid route id. |
183 static void RelayMessage(const IPC::Message& message, | 183 static void RelayMessage(const IPC::Message& message, |
184 IPC::Message::Sender* sender, | 184 IPC::Message::Sender* sender, |
185 int route_id, | 185 int route_id, |
186 CallbackWithReturnValue<int>::Type* next_route_id); | 186 CallbackWithReturnValue<int>::Type* next_route_id); |
187 | 187 |
188 virtual bool CanShutdown() { return instances_.empty(); } | 188 virtual bool CanShutdown(); |
189 | 189 |
190 // Updates the title shown in the task manager. | 190 // Updates the title shown in the task manager. |
191 void UpdateTitle(); | 191 void UpdateTitle(); |
192 | 192 |
193 void OnCreateWorker(const ViewHostMsg_CreateWorker_Params& params, | 193 void OnCreateWorker(const ViewHostMsg_CreateWorker_Params& params, |
194 int* route_id); | 194 int* route_id); |
195 void OnCancelCreateDedicatedWorker(int route_id); | 195 void OnCancelCreateDedicatedWorker(int route_id); |
196 void OnForwardToWorker(const IPC::Message& message); | 196 void OnForwardToWorker(const IPC::Message& message); |
197 | 197 |
198 // Checks the content settings whether access to web databases is enabled and | 198 // Checks the content settings whether access to web databases is enabled and |
(...skipping 14 matching lines...) Loading... |
213 // manually. | 213 // manually. |
214 std::vector<scoped_refptr<BrowserMessageFilter> > filters_; | 214 std::vector<scoped_refptr<BrowserMessageFilter> > filters_; |
215 | 215 |
216 // A callback to create a routing id for the associated worker process. | 216 // A callback to create a routing id for the associated worker process. |
217 scoped_ptr<CallbackWithReturnValue<int>::Type> next_route_id_callback_; | 217 scoped_ptr<CallbackWithReturnValue<int>::Type> next_route_id_callback_; |
218 | 218 |
219 DISALLOW_COPY_AND_ASSIGN(WorkerProcessHost); | 219 DISALLOW_COPY_AND_ASSIGN(WorkerProcessHost); |
220 }; | 220 }; |
221 | 221 |
222 #endif // CHROME_BROWSER_WORKER_HOST_WORKER_PROCESS_HOST_H_ | 222 #endif // CHROME_BROWSER_WORKER_HOST_WORKER_PROCESS_HOST_H_ |
OLD | NEW |