| OLD | NEW |
| 1 // Copyright 2012 The Chromium Authors. All rights reserved. | 1 // Copyright 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 // Represents the browser side of the browser <--> renderer communication | 5 // Represents the browser side of the browser <--> renderer communication |
| 6 // channel. There will be one RenderProcessHost per renderer process. | 6 // channel. There will be one RenderProcessHost per renderer process. |
| 7 | 7 |
| 8 #include "content/browser/renderer_host/render_process_host_impl.h" | 8 #include "content/browser/renderer_host/render_process_host_impl.h" |
| 9 | 9 |
| 10 #include <algorithm> | 10 #include <algorithm> |
| (...skipping 1094 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1105 return storage_partition_impl_; | 1105 return storage_partition_impl_; |
| 1106 } | 1106 } |
| 1107 | 1107 |
| 1108 static void AppendCompositorCommandLineFlags(base::CommandLine* command_line) { | 1108 static void AppendCompositorCommandLineFlags(base::CommandLine* command_line) { |
| 1109 if (IsPropertyTreeVerificationEnabled()) | 1109 if (IsPropertyTreeVerificationEnabled()) |
| 1110 command_line->AppendSwitch(cc::switches::kEnablePropertyTreeVerification); | 1110 command_line->AppendSwitch(cc::switches::kEnablePropertyTreeVerification); |
| 1111 | 1111 |
| 1112 if (IsDelegatedRendererEnabled()) | 1112 if (IsDelegatedRendererEnabled()) |
| 1113 command_line->AppendSwitch(switches::kEnableDelegatedRenderer); | 1113 command_line->AppendSwitch(switches::kEnableDelegatedRenderer); |
| 1114 | 1114 |
| 1115 if (IsImplSidePaintingEnabled()) { | 1115 command_line->AppendSwitchASCII( |
| 1116 command_line->AppendSwitchASCII( | 1116 switches::kNumRasterThreads, |
| 1117 switches::kNumRasterThreads, | 1117 base::IntToString(NumberOfRendererRasterThreads())); |
| 1118 base::IntToString(NumberOfRendererRasterThreads())); | |
| 1119 } else { | |
| 1120 command_line->AppendSwitch(switches::kDisableImplSidePainting); | |
| 1121 } | |
| 1122 | 1118 |
| 1123 if (IsGpuRasterizationEnabled()) | 1119 if (IsGpuRasterizationEnabled()) |
| 1124 command_line->AppendSwitch(switches::kEnableGpuRasterization); | 1120 command_line->AppendSwitch(switches::kEnableGpuRasterization); |
| 1125 | 1121 |
| 1126 int msaa_sample_count = GpuRasterizationMSAASampleCount(); | 1122 int msaa_sample_count = GpuRasterizationMSAASampleCount(); |
| 1127 if (msaa_sample_count > 0) { | 1123 if (msaa_sample_count > 0) { |
| 1128 command_line->AppendSwitchASCII( | 1124 command_line->AppendSwitchASCII( |
| 1129 switches::kGpuRasterizationMSAASampleCount, | 1125 switches::kGpuRasterizationMSAASampleCount, |
| 1130 base::IntToString(msaa_sample_count)); | 1126 base::IntToString(msaa_sample_count)); |
| 1131 } | 1127 } |
| (...skipping 122 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1254 switches::kDisableTouchAdjustment, | 1250 switches::kDisableTouchAdjustment, |
| 1255 switches::kDisableTouchDragDrop, | 1251 switches::kDisableTouchDragDrop, |
| 1256 switches::kDisableTouchEditing, | 1252 switches::kDisableTouchEditing, |
| 1257 switches::kDisableV8IdleTasks, | 1253 switches::kDisableV8IdleTasks, |
| 1258 switches::kDomAutomationController, | 1254 switches::kDomAutomationController, |
| 1259 switches::kEnableBleedingEdgeRenderingFastPaths, | 1255 switches::kEnableBleedingEdgeRenderingFastPaths, |
| 1260 switches::kEnableBlinkFeatures, | 1256 switches::kEnableBlinkFeatures, |
| 1261 switches::kEnableBrowserSideNavigation, | 1257 switches::kEnableBrowserSideNavigation, |
| 1262 switches::kEnableCompositorAnimationTimelines, | 1258 switches::kEnableCompositorAnimationTimelines, |
| 1263 switches::kEnableCredentialManagerAPI, | 1259 switches::kEnableCredentialManagerAPI, |
| 1264 switches::kEnableDeferredImageDecoding, | |
| 1265 switches::kEnableDelayAgnosticAec, | 1260 switches::kEnableDelayAgnosticAec, |
| 1266 switches::kEnableDisplayList2dCanvas, | 1261 switches::kEnableDisplayList2dCanvas, |
| 1267 switches::kEnableDistanceFieldText, | 1262 switches::kEnableDistanceFieldText, |
| 1268 switches::kEnableExperimentalCanvasFeatures, | 1263 switches::kEnableExperimentalCanvasFeatures, |
| 1269 switches::kEnableExperimentalWebPlatformFeatures, | 1264 switches::kEnableExperimentalWebPlatformFeatures, |
| 1270 switches::kEnableGPUClientLogging, | 1265 switches::kEnableGPUClientLogging, |
| 1271 switches::kEnableGpuClientTracing, | 1266 switches::kEnableGpuClientTracing, |
| 1272 switches::kEnableGPUServiceLogging, | 1267 switches::kEnableGPUServiceLogging, |
| 1273 switches::kEnableIconNtp, | 1268 switches::kEnableIconNtp, |
| 1274 switches::kEnableLinkDisambiguationPopup, | 1269 switches::kEnableLinkDisambiguationPopup, |
| (...skipping 132 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1407 switches::kTraceStartup, | 1402 switches::kTraceStartup, |
| 1408 browser_cmd.GetSwitchValueASCII(switches::kTraceStartup)); | 1403 browser_cmd.GetSwitchValueASCII(switches::kTraceStartup)); |
| 1409 } | 1404 } |
| 1410 | 1405 |
| 1411 // Disable databases in incognito mode. | 1406 // Disable databases in incognito mode. |
| 1412 if (GetBrowserContext()->IsOffTheRecord() && | 1407 if (GetBrowserContext()->IsOffTheRecord() && |
| 1413 !browser_cmd.HasSwitch(switches::kDisableDatabases)) { | 1408 !browser_cmd.HasSwitch(switches::kDisableDatabases)) { |
| 1414 renderer_cmd->AppendSwitch(switches::kDisableDatabases); | 1409 renderer_cmd->AppendSwitch(switches::kDisableDatabases); |
| 1415 } | 1410 } |
| 1416 | 1411 |
| 1417 // Enforce the extra command line flags for impl-side painting. | |
| 1418 if (IsImplSidePaintingEnabled() && | |
| 1419 !browser_cmd.HasSwitch(switches::kEnableDeferredImageDecoding)) | |
| 1420 renderer_cmd->AppendSwitch(switches::kEnableDeferredImageDecoding); | |
| 1421 | |
| 1422 // Add kWaitForDebugger to let renderer process wait for a debugger. | 1412 // Add kWaitForDebugger to let renderer process wait for a debugger. |
| 1423 if (browser_cmd.HasSwitch(switches::kWaitForDebuggerChildren)) { | 1413 if (browser_cmd.HasSwitch(switches::kWaitForDebuggerChildren)) { |
| 1424 // Look to pass-on the kWaitForDebugger flag. | 1414 // Look to pass-on the kWaitForDebugger flag. |
| 1425 std::string value = | 1415 std::string value = |
| 1426 browser_cmd.GetSwitchValueASCII(switches::kWaitForDebuggerChildren); | 1416 browser_cmd.GetSwitchValueASCII(switches::kWaitForDebuggerChildren); |
| 1427 if (value.empty() || value == switches::kRendererProcess) { | 1417 if (value.empty() || value == switches::kRendererProcess) { |
| 1428 renderer_cmd->AppendSwitch(switches::kWaitForDebugger); | 1418 renderer_cmd->AppendSwitch(switches::kWaitForDebugger); |
| 1429 } | 1419 } |
| 1430 } | 1420 } |
| 1431 } | 1421 } |
| (...skipping 1069 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2501 void RenderProcessHostImpl::GetAudioOutputControllers( | 2491 void RenderProcessHostImpl::GetAudioOutputControllers( |
| 2502 const GetAudioOutputControllersCallback& callback) const { | 2492 const GetAudioOutputControllersCallback& callback) const { |
| 2503 audio_renderer_host()->GetOutputControllers(callback); | 2493 audio_renderer_host()->GetOutputControllers(callback); |
| 2504 } | 2494 } |
| 2505 | 2495 |
| 2506 BluetoothDispatcherHost* RenderProcessHostImpl::GetBluetoothDispatcherHost() { | 2496 BluetoothDispatcherHost* RenderProcessHostImpl::GetBluetoothDispatcherHost() { |
| 2507 return bluetooth_dispatcher_host_.get(); | 2497 return bluetooth_dispatcher_host_.get(); |
| 2508 } | 2498 } |
| 2509 | 2499 |
| 2510 } // namespace content | 2500 } // namespace content |
| OLD | NEW |