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 // 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 828 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
839 cc::switches::kEnableImplSidePainting, | 839 cc::switches::kEnableImplSidePainting, |
840 cc::switches::kEnablePartialSwap, | 840 cc::switches::kEnablePartialSwap, |
841 cc::switches::kNumRasterThreads, | 841 cc::switches::kNumRasterThreads, |
842 cc::switches::kShowPropertyChangedRects, | 842 cc::switches::kShowPropertyChangedRects, |
843 cc::switches::kShowSurfaceDamageRects, | 843 cc::switches::kShowSurfaceDamageRects, |
844 cc::switches::kShowScreenSpaceRects, | 844 cc::switches::kShowScreenSpaceRects, |
845 cc::switches::kShowReplicaScreenSpaceRects, | 845 cc::switches::kShowReplicaScreenSpaceRects, |
846 cc::switches::kShowNonOccludingRects, | 846 cc::switches::kShowNonOccludingRects, |
847 cc::switches::kShowOccludingRects, | 847 cc::switches::kShowOccludingRects, |
848 cc::switches::kTraceOverdraw, | 848 cc::switches::kTraceOverdraw, |
849 cc::switches::kTopControlsHeight, | |
849 }; | 850 }; |
850 renderer_cmd->CopySwitchesFrom(browser_cmd, kSwitchNames, | 851 renderer_cmd->CopySwitchesFrom(browser_cmd, kSwitchNames, |
851 arraysize(kSwitchNames)); | 852 arraysize(kSwitchNames)); |
852 | 853 |
853 // Disable databases in incognito mode. | 854 // Disable databases in incognito mode. |
854 if (GetBrowserContext()->IsOffTheRecord() && | 855 if (GetBrowserContext()->IsOffTheRecord() && |
855 !browser_cmd.HasSwitch(switches::kDisableDatabases)) { | 856 !browser_cmd.HasSwitch(switches::kDisableDatabases)) { |
856 renderer_cmd->AppendSwitch(switches::kDisableDatabases); | 857 renderer_cmd->AppendSwitch(switches::kDisableDatabases); |
857 #if defined(OS_ANDROID) | 858 #if defined(OS_ANDROID) |
858 renderer_cmd->AppendSwitch(switches::kDisableMediaHistoryLogging); | 859 renderer_cmd->AppendSwitch(switches::kDisableMediaHistoryLogging); |
859 #endif | 860 #endif |
860 } | 861 } |
862 | |
863 #if defined(OS_ANDROID) | |
aelias_OOO_until_Jul13
2012/12/19 08:31:18
I don't think we should have this block here. Ple
Ted C
2012/12/19 21:34:17
I only want to enable this in the renderer. conte
aelias_OOO_until_Jul13
2012/12/19 23:08:36
You can set it explicitly to false in the browser
Ted C
2012/12/20 00:42:38
Done
| |
864 if (!browser_cmd.HasSwitch(switches::kDisableFullScreen)) { | |
865 renderer_cmd->AppendSwitch( | |
866 cc::switches::kEnableTopControlsPositionCalculation); | |
867 } | |
868 #endif | |
861 } | 869 } |
862 | 870 |
863 base::ProcessHandle RenderProcessHostImpl::GetHandle() { | 871 base::ProcessHandle RenderProcessHostImpl::GetHandle() { |
864 if (run_renderer_in_process()) | 872 if (run_renderer_in_process()) |
865 return base::Process::Current().handle(); | 873 return base::Process::Current().handle(); |
866 | 874 |
867 if (!child_process_launcher_.get() || child_process_launcher_->IsStarting()) | 875 if (!child_process_launcher_.get() || child_process_launcher_->IsStarting()) |
868 return base::kNullProcessHandle; | 876 return base::kNullProcessHandle; |
869 | 877 |
870 return child_process_launcher_->GetHandle(); | 878 return child_process_launcher_->GetHandle(); |
(...skipping 723 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
1594 "RenderWidgetHostImpl::OnCompositorSurfaceBuffersSwappedNoHost"); | 1602 "RenderWidgetHostImpl::OnCompositorSurfaceBuffersSwappedNoHost"); |
1595 AcceleratedSurfaceMsg_BufferPresented_Params ack_params; | 1603 AcceleratedSurfaceMsg_BufferPresented_Params ack_params; |
1596 ack_params.surface_handle = surface_handle; | 1604 ack_params.surface_handle = surface_handle; |
1597 ack_params.sync_point = 0; | 1605 ack_params.sync_point = 0; |
1598 RenderWidgetHostImpl::AcknowledgeBufferPresent(route_id, | 1606 RenderWidgetHostImpl::AcknowledgeBufferPresent(route_id, |
1599 gpu_process_host_id, | 1607 gpu_process_host_id, |
1600 ack_params); | 1608 ack_params); |
1601 } | 1609 } |
1602 | 1610 |
1603 } // namespace content | 1611 } // namespace content |
OLD | NEW |