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 #ifndef CONTENT_BROWSER_RENDERER_HOST_BROWSER_RENDER_PROCESS_HOST_IMPL_H_ | 5 #ifndef CONTENT_BROWSER_RENDERER_HOST_BROWSER_RENDER_PROCESS_HOST_IMPL_H_ |
6 #define CONTENT_BROWSER_RENDERER_HOST_BROWSER_RENDER_PROCESS_HOST_IMPL_H_ | 6 #define CONTENT_BROWSER_RENDERER_HOST_BROWSER_RENDER_PROCESS_HOST_IMPL_H_ |
7 | 7 |
8 #include <map> | 8 #include <map> |
9 #include <queue> | 9 #include <queue> |
10 #include <string> | 10 #include <string> |
11 | 11 |
12 #include "base/memory/scoped_ptr.h" | 12 #include "base/memory/scoped_ptr.h" |
13 #include "base/observer_list.h" | 13 #include "base/observer_list.h" |
14 #include "base/process/process.h" | 14 #include "base/process/process.h" |
15 #include "base/timer/timer.h" | 15 #include "base/timer/timer.h" |
16 #include "content/browser/child_process_launcher.h" | 16 #include "content/browser/child_process_launcher.h" |
17 #include "content/browser/geolocation/geolocation_dispatcher_host.h" | 17 #include "content/browser/geolocation/geolocation_dispatcher_host.h" |
18 #include "content/browser/power_monitor_message_broadcaster.h" | 18 #include "content/browser/power_monitor_message_broadcaster.h" |
19 #include "content/common/content_export.h" | 19 #include "content/common/content_export.h" |
20 #include "content/public/browser/gpu_data_manager_observer.h" | 20 #include "content/public/browser/gpu_data_manager_observer.h" |
21 #include "content/public/browser/render_process_host.h" | 21 #include "content/public/browser/render_process_host.h" |
22 #include "ipc/ipc_channel_proxy.h" | 22 #include "ipc/ipc_channel_proxy.h" |
23 #include "ipc/ipc_platform_file.h" | 23 #include "ipc/ipc_platform_file.h" |
24 #include "ui/surface/transport_dib.h" | 24 #include "ui/surface/transport_dib.h" |
25 | 25 |
26 class CommandLine; | |
27 struct ViewHostMsg_CompositorSurfaceBuffersSwapped_Params; | 26 struct ViewHostMsg_CompositorSurfaceBuffersSwapped_Params; |
28 | 27 |
29 namespace base { | 28 namespace base { |
| 29 class CommandLine; |
30 class MessageLoop; | 30 class MessageLoop; |
31 } | 31 } |
32 | 32 |
33 namespace gfx { | 33 namespace gfx { |
34 class Size; | 34 class Size; |
35 } | 35 } |
36 | 36 |
37 namespace content { | 37 namespace content { |
38 class AudioRendererHost; | 38 class AudioRendererHost; |
39 class BrowserDemuxerAndroid; | 39 class BrowserDemuxerAndroid; |
(...skipping 226 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
266 void SuddenTerminationChanged(bool enabled); | 266 void SuddenTerminationChanged(bool enabled); |
267 void OnUserMetricsRecordAction(const std::string& action); | 267 void OnUserMetricsRecordAction(const std::string& action); |
268 void OnSavedPageAsMHTML(int job_id, int64 mhtml_file_size); | 268 void OnSavedPageAsMHTML(int job_id, int64 mhtml_file_size); |
269 | 269 |
270 // CompositorSurfaceBuffersSwapped handler when there's no RWH. | 270 // CompositorSurfaceBuffersSwapped handler when there's no RWH. |
271 void OnCompositorSurfaceBuffersSwappedNoHost( | 271 void OnCompositorSurfaceBuffersSwappedNoHost( |
272 const ViewHostMsg_CompositorSurfaceBuffersSwapped_Params& params); | 272 const ViewHostMsg_CompositorSurfaceBuffersSwapped_Params& params); |
273 | 273 |
274 // Generates a command line to be used to spawn a renderer and appends the | 274 // Generates a command line to be used to spawn a renderer and appends the |
275 // results to |*command_line|. | 275 // results to |*command_line|. |
276 void AppendRendererCommandLine(CommandLine* command_line) const; | 276 void AppendRendererCommandLine(base::CommandLine* command_line) const; |
277 | 277 |
278 // Copies applicable command line switches from the given |browser_cmd| line | 278 // Copies applicable command line switches from the given |browser_cmd| line |
279 // flags to the output |renderer_cmd| line flags. Not all switches will be | 279 // flags to the output |renderer_cmd| line flags. Not all switches will be |
280 // copied over. | 280 // copied over. |
281 void PropagateBrowserCommandLineToRenderer(const CommandLine& browser_cmd, | 281 void PropagateBrowserCommandLineToRenderer( |
282 CommandLine* renderer_cmd) const; | 282 const base::CommandLine& browser_cmd, |
| 283 base::CommandLine* renderer_cmd) const; |
283 | 284 |
284 // Callers can reduce the RenderProcess' priority. | 285 // Callers can reduce the RenderProcess' priority. |
285 void SetBackgrounded(bool backgrounded); | 286 void SetBackgrounded(bool backgrounded); |
286 | 287 |
287 // Handle termination of our process. | 288 // Handle termination of our process. |
288 void ProcessDied(bool already_dead); | 289 void ProcessDied(bool already_dead); |
289 | 290 |
290 virtual void OnGpuSwitching() OVERRIDE; | 291 virtual void OnGpuSwitching() OVERRIDE; |
291 | 292 |
292 #if defined(ENABLE_WEBRTC) | 293 #if defined(ENABLE_WEBRTC) |
(...skipping 130 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
423 ScreenOrientationDispatcherHost* screen_orientation_dispatcher_host_; | 424 ScreenOrientationDispatcherHost* screen_orientation_dispatcher_host_; |
424 | 425 |
425 int worker_ref_count_; | 426 int worker_ref_count_; |
426 | 427 |
427 DISALLOW_COPY_AND_ASSIGN(RenderProcessHostImpl); | 428 DISALLOW_COPY_AND_ASSIGN(RenderProcessHostImpl); |
428 }; | 429 }; |
429 | 430 |
430 } // namespace content | 431 } // namespace content |
431 | 432 |
432 #endif // CONTENT_BROWSER_RENDERER_HOST_BROWSER_RENDER_PROCESS_HOST_IMPL_H_ | 433 #endif // CONTENT_BROWSER_RENDERER_HOST_BROWSER_RENDER_PROCESS_HOST_IMPL_H_ |
OLD | NEW |