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 1185 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1196 | 1196 |
1197 AddFilter(new GamepadBrowserMessageFilter()); | 1197 AddFilter(new GamepadBrowserMessageFilter()); |
1198 AddFilter(new ProfilerMessageFilter(PROCESS_TYPE_RENDERER)); | 1198 AddFilter(new ProfilerMessageFilter(PROCESS_TYPE_RENDERER)); |
1199 AddFilter(new HistogramMessageFilter()); | 1199 AddFilter(new HistogramMessageFilter()); |
1200 AddFilter(new MemoryMessageFilter(this)); | 1200 AddFilter(new MemoryMessageFilter(this)); |
1201 AddFilter(new PushMessagingMessageFilter( | 1201 AddFilter(new PushMessagingMessageFilter( |
1202 GetID(), storage_partition_impl_->GetServiceWorkerContext())); | 1202 GetID(), storage_partition_impl_->GetServiceWorkerContext())); |
1203 #if defined(OS_ANDROID) | 1203 #if defined(OS_ANDROID) |
1204 AddFilter(new ScreenOrientationMessageFilterAndroid()); | 1204 AddFilter(new ScreenOrientationMessageFilterAndroid()); |
1205 #endif | 1205 #endif |
| 1206 filter_ = new SynchronousCompositorObserver(GetID()); |
| 1207 AddFilter(filter_); |
| 1208 } |
| 1209 |
| 1210 SynchronousCompositorObserver* RenderProcessHostImpl::GetFilter() { |
| 1211 return filter_; |
1206 } | 1212 } |
1207 | 1213 |
1208 void RenderProcessHostImpl::RegisterMojoInterfaces() { | 1214 void RenderProcessHostImpl::RegisterMojoInterfaces() { |
1209 std::unique_ptr<shell::InterfaceRegistry> registry( | 1215 std::unique_ptr<shell::InterfaceRegistry> registry( |
1210 new shell::InterfaceRegistry); | 1216 new shell::InterfaceRegistry); |
1211 | 1217 |
1212 channel_->AddAssociatedInterface( | 1218 channel_->AddAssociatedInterface( |
1213 base::Bind(&RenderProcessHostImpl::OnRouteProviderRequest, | 1219 base::Bind(&RenderProcessHostImpl::OnRouteProviderRequest, |
1214 base::Unretained(this))); | 1220 base::Unretained(this))); |
1215 | 1221 |
(...skipping 1808 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
3024 LOG(ERROR) << "Terminating render process for bad Mojo message: " << error; | 3030 LOG(ERROR) << "Terminating render process for bad Mojo message: " << error; |
3025 | 3031 |
3026 // The ReceivedBadMessage call below will trigger a DumpWithoutCrashing. Alias | 3032 // The ReceivedBadMessage call below will trigger a DumpWithoutCrashing. Alias |
3027 // enough information here so that we can determine what the bad message was. | 3033 // enough information here so that we can determine what the bad message was. |
3028 base::debug::Alias(&error); | 3034 base::debug::Alias(&error); |
3029 bad_message::ReceivedBadMessage(process.get(), | 3035 bad_message::ReceivedBadMessage(process.get(), |
3030 bad_message::RPH_MOJO_PROCESS_ERROR); | 3036 bad_message::RPH_MOJO_PROCESS_ERROR); |
3031 } | 3037 } |
3032 | 3038 |
3033 } // namespace content | 3039 } // namespace content |
OLD | NEW |