| OLD | NEW |
| 1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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/frame_host/render_frame_host_impl.h" | 5 #include "content/browser/frame_host/render_frame_host_impl.h" |
| 6 | 6 |
| 7 #include <algorithm> | 7 #include <algorithm> |
| 8 #include <utility> | 8 #include <utility> |
| 9 | 9 |
| 10 #include "base/bind.h" | 10 #include "base/bind.h" |
| (...skipping 62 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 73 #include "content/public/browser/ax_event_notification_details.h" | 73 #include "content/public/browser/ax_event_notification_details.h" |
| 74 #include "content/public/browser/browser_accessibility_state.h" | 74 #include "content/public/browser/browser_accessibility_state.h" |
| 75 #include "content/public/browser/browser_context.h" | 75 #include "content/public/browser/browser_context.h" |
| 76 #include "content/public/browser/browser_plugin_guest_manager.h" | 76 #include "content/public/browser/browser_plugin_guest_manager.h" |
| 77 #include "content/public/browser/browser_thread.h" | 77 #include "content/public/browser/browser_thread.h" |
| 78 #include "content/public/browser/content_browser_client.h" | 78 #include "content/public/browser/content_browser_client.h" |
| 79 #include "content/public/browser/permission_manager.h" | 79 #include "content/public/browser/permission_manager.h" |
| 80 #include "content/public/browser/permission_type.h" | 80 #include "content/public/browser/permission_type.h" |
| 81 #include "content/public/browser/render_process_host.h" | 81 #include "content/public/browser/render_process_host.h" |
| 82 #include "content/public/browser/render_widget_host_view.h" | 82 #include "content/public/browser/render_widget_host_view.h" |
| 83 #include "content/public/browser/resource_context.h" | |
| 84 #include "content/public/browser/storage_partition.h" | 83 #include "content/public/browser/storage_partition.h" |
| 85 #include "content/public/browser/stream_handle.h" | 84 #include "content/public/browser/stream_handle.h" |
| 86 #include "content/public/common/bindings_policy.h" | 85 #include "content/public/common/bindings_policy.h" |
| 87 #include "content/public/common/browser_side_navigation_policy.h" | 86 #include "content/public/common/browser_side_navigation_policy.h" |
| 88 #include "content/public/common/content_constants.h" | 87 #include "content/public/common/content_constants.h" |
| 89 #include "content/public/common/content_features.h" | 88 #include "content/public/common/content_features.h" |
| 90 #include "content/public/common/content_switches.h" | 89 #include "content/public/common/content_switches.h" |
| 91 #include "content/public/common/file_chooser_file_info.h" | 90 #include "content/public/common/file_chooser_file_info.h" |
| 92 #include "content/public/common/file_chooser_params.h" | 91 #include "content/public/common/file_chooser_params.h" |
| 93 #include "content/public/common/isolated_world_ids.h" | 92 #include "content/public/common/isolated_world_ids.h" |
| (...skipping 2449 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2543 // BrowserMainLoop, which owns MediaStreamManager, is alive for the lifetime | 2542 // BrowserMainLoop, which owns MediaStreamManager, is alive for the lifetime |
| 2544 // of Mojo communication (see BrowserMainLoop::ShutdownThreadsAndCleanUp(), | 2543 // of Mojo communication (see BrowserMainLoop::ShutdownThreadsAndCleanUp(), |
| 2545 // which shuts down Mojo). Hence, passing that MediaStreamManager instance | 2544 // which shuts down Mojo). Hence, passing that MediaStreamManager instance |
| 2546 // as a raw pointer here is safe. | 2545 // as a raw pointer here is safe. |
| 2547 MediaStreamManager* media_stream_manager = | 2546 MediaStreamManager* media_stream_manager = |
| 2548 BrowserMainLoop::GetInstance()->media_stream_manager(); | 2547 BrowserMainLoop::GetInstance()->media_stream_manager(); |
| 2549 GetInterfaceRegistry()->AddInterface( | 2548 GetInterfaceRegistry()->AddInterface( |
| 2550 base::Bind(&MediaDevicesDispatcherHost::Create, GetProcess()->GetID(), | 2549 base::Bind(&MediaDevicesDispatcherHost::Create, GetProcess()->GetID(), |
| 2551 GetRoutingID(), GetProcess() | 2550 GetRoutingID(), GetProcess() |
| 2552 ->GetBrowserContext() | 2551 ->GetBrowserContext() |
| 2553 ->GetResourceContext() | |
| 2554 ->GetMediaDeviceIDSalt(), | 2552 ->GetMediaDeviceIDSalt(), |
| 2555 base::Unretained(media_stream_manager)), | 2553 base::Unretained(media_stream_manager)), |
| 2556 BrowserThread::GetTaskRunnerForThread(BrowserThread::IO)); | 2554 BrowserThread::GetTaskRunnerForThread(BrowserThread::IO)); |
| 2557 } | 2555 } |
| 2558 #endif | 2556 #endif |
| 2559 | 2557 |
| 2560 #if BUILDFLAG(ENABLE_MEDIA_REMOTING) | 2558 #if BUILDFLAG(ENABLE_MEDIA_REMOTING) |
| 2561 GetInterfaceRegistry()->AddInterface(base::Bind( | 2559 GetInterfaceRegistry()->AddInterface(base::Bind( |
| 2562 &RemoterFactoryImpl::Bind, GetProcess()->GetID(), GetRoutingID())); | 2560 &RemoterFactoryImpl::Bind, GetProcess()->GetID(), GetRoutingID())); |
| 2563 #endif // BUILDFLAG(ENABLE_MEDIA_REMOTING) | 2561 #endif // BUILDFLAG(ENABLE_MEDIA_REMOTING) |
| (...skipping 1117 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 3681 } | 3679 } |
| 3682 | 3680 |
| 3683 void RenderFrameHostImpl::ForwardGetInterfaceToRenderFrame( | 3681 void RenderFrameHostImpl::ForwardGetInterfaceToRenderFrame( |
| 3684 const std::string& interface_name, | 3682 const std::string& interface_name, |
| 3685 mojo::ScopedMessagePipeHandle pipe) { | 3683 mojo::ScopedMessagePipeHandle pipe) { |
| 3686 GetRemoteInterfaces()->GetInterface(interface_name, std::move(pipe)); | 3684 GetRemoteInterfaces()->GetInterface(interface_name, std::move(pipe)); |
| 3687 } | 3685 } |
| 3688 #endif | 3686 #endif |
| 3689 | 3687 |
| 3690 } // namespace content | 3688 } // namespace content |
| OLD | NEW |