| 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 #include "content/browser/browser_child_process_host_impl.h" | 5 #include "content/browser/browser_child_process_host_impl.h" |
| 6 | 6 |
| 7 #include "base/base_switches.h" | 7 #include "base/base_switches.h" |
| 8 #include "base/bind.h" | 8 #include "base/bind.h" |
| 9 #include "base/command_line.h" | 9 #include "base/command_line.h" |
| 10 #include "base/debug/dump_without_crashing.h" | 10 #include "base/debug/dump_without_crashing.h" |
| (...skipping 11 matching lines...) Expand all Loading... |
| 22 #include "base/strings/stringprintf.h" | 22 #include "base/strings/stringprintf.h" |
| 23 #include "base/synchronization/waitable_event.h" | 23 #include "base/synchronization/waitable_event.h" |
| 24 #include "base/threading/thread_task_runner_handle.h" | 24 #include "base/threading/thread_task_runner_handle.h" |
| 25 #include "build/build_config.h" | 25 #include "build/build_config.h" |
| 26 #include "components/tracing/common/tracing_switches.h" | 26 #include "components/tracing/common/tracing_switches.h" |
| 27 #include "content/browser/histogram_message_filter.h" | 27 #include "content/browser/histogram_message_filter.h" |
| 28 #include "content/browser/loader/resource_message_filter.h" | 28 #include "content/browser/loader/resource_message_filter.h" |
| 29 #include "content/browser/memory/memory_message_filter.h" | 29 #include "content/browser/memory/memory_message_filter.h" |
| 30 #include "content/browser/power_monitor_message_broadcaster.h" | 30 #include "content/browser/power_monitor_message_broadcaster.h" |
| 31 #include "content/browser/profiler_message_filter.h" | 31 #include "content/browser/profiler_message_filter.h" |
| 32 #include "content/browser/renderer_host/shared_memory_allocator_impl.h" |
| 32 #include "content/browser/service_manager/service_manager_context.h" | 33 #include "content/browser/service_manager/service_manager_context.h" |
| 33 #include "content/browser/tracing/trace_message_filter.h" | 34 #include "content/browser/tracing/trace_message_filter.h" |
| 34 #include "content/common/child_process_host_impl.h" | 35 #include "content/common/child_process_host_impl.h" |
| 35 #include "content/common/child_process_messages.h" | 36 #include "content/common/child_process_messages.h" |
| 36 #include "content/common/service_manager/child_connection.h" | 37 #include "content/common/service_manager/child_connection.h" |
| 37 #include "content/public/browser/browser_child_process_host_delegate.h" | 38 #include "content/public/browser/browser_child_process_host_delegate.h" |
| 38 #include "content/public/browser/browser_child_process_observer.h" | 39 #include "content/public/browser/browser_child_process_observer.h" |
| 39 #include "content/public/browser/browser_thread.h" | 40 #include "content/public/browser/browser_thread.h" |
| 40 #include "content/public/browser/child_process_data.h" | 41 #include "content/public/browser/child_process_data.h" |
| 41 #include "content/public/browser/content_browser_client.h" | 42 #include "content/public/browser/content_browser_client.h" |
| (...skipping 48 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 90 class ConnectionFilterImpl : public ConnectionFilter { | 91 class ConnectionFilterImpl : public ConnectionFilter { |
| 91 public: | 92 public: |
| 92 ConnectionFilterImpl() {} | 93 ConnectionFilterImpl() {} |
| 93 | 94 |
| 94 private: | 95 private: |
| 95 // ConnectionFilter: | 96 // ConnectionFilter: |
| 96 bool OnConnect(const service_manager::Identity& remote_identity, | 97 bool OnConnect(const service_manager::Identity& remote_identity, |
| 97 service_manager::InterfaceRegistry* registry, | 98 service_manager::InterfaceRegistry* registry, |
| 98 service_manager::Connector* connector) override { | 99 service_manager::Connector* connector) override { |
| 99 registry->AddInterface(base::Bind(&PowerMonitorMessageBroadcaster::Create)); | 100 registry->AddInterface(base::Bind(&PowerMonitorMessageBroadcaster::Create)); |
| 101 registry->AddInterface(base::Bind(&SharedMemoryAllocatorImpl::Create)); |
| 100 return true; | 102 return true; |
| 101 } | 103 } |
| 102 | 104 |
| 103 DISALLOW_COPY_AND_ASSIGN(ConnectionFilterImpl); | 105 DISALLOW_COPY_AND_ASSIGN(ConnectionFilterImpl); |
| 104 }; | 106 }; |
| 105 | 107 |
| 106 } // namespace | 108 } // namespace |
| 107 | 109 |
| 108 BrowserChildProcessHost* BrowserChildProcessHost::Create( | 110 BrowserChildProcessHost* BrowserChildProcessHost::Create( |
| 109 content::ProcessType process_type, | 111 content::ProcessType process_type, |
| (...skipping 494 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 604 | 606 |
| 605 #if defined(OS_WIN) | 607 #if defined(OS_WIN) |
| 606 | 608 |
| 607 void BrowserChildProcessHostImpl::OnObjectSignaled(HANDLE object) { | 609 void BrowserChildProcessHostImpl::OnObjectSignaled(HANDLE object) { |
| 608 OnChildDisconnected(); | 610 OnChildDisconnected(); |
| 609 } | 611 } |
| 610 | 612 |
| 611 #endif | 613 #endif |
| 612 | 614 |
| 613 } // namespace content | 615 } // namespace content |
| OLD | NEW |