Chromium Code Reviews| 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 89 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 100 #include "device/wake_lock/public/interfaces/wake_lock_context.mojom.h" | 100 #include "device/wake_lock/public/interfaces/wake_lock_context.mojom.h" |
| 101 #include "device/wake_lock/public/interfaces/wake_lock_service.mojom.h" | 101 #include "device/wake_lock/public/interfaces/wake_lock_service.mojom.h" |
| 102 #include "media/base/media_switches.h" | 102 #include "media/base/media_switches.h" |
| 103 #include "media/media_features.h" | 103 #include "media/media_features.h" |
| 104 #include "media/mojo/interfaces/media_service.mojom.h" | 104 #include "media/mojo/interfaces/media_service.mojom.h" |
| 105 #include "media/mojo/interfaces/remoting.mojom.h" | 105 #include "media/mojo/interfaces/remoting.mojom.h" |
| 106 #include "mojo/public/cpp/bindings/associated_interface_ptr.h" | 106 #include "mojo/public/cpp/bindings/associated_interface_ptr.h" |
| 107 #include "mojo/public/cpp/bindings/strong_binding.h" | 107 #include "mojo/public/cpp/bindings/strong_binding.h" |
| 108 #include "services/service_manager/public/cpp/connector.h" | 108 #include "services/service_manager/public/cpp/connector.h" |
| 109 #include "services/service_manager/public/cpp/interface_provider.h" | 109 #include "services/service_manager/public/cpp/interface_provider.h" |
| 110 #include "third_party/WebKit/public/platform/WebFeaturePolicy.h" | |
| 110 #include "ui/accessibility/ax_tree.h" | 111 #include "ui/accessibility/ax_tree.h" |
| 111 #include "ui/accessibility/ax_tree_id_registry.h" | 112 #include "ui/accessibility/ax_tree_id_registry.h" |
| 112 #include "ui/accessibility/ax_tree_update.h" | 113 #include "ui/accessibility/ax_tree_update.h" |
| 113 #include "ui/gfx/geometry/quad_f.h" | 114 #include "ui/gfx/geometry/quad_f.h" |
| 114 #include "url/gurl.h" | 115 #include "url/gurl.h" |
| 115 | 116 |
| 116 #if defined(OS_ANDROID) | 117 #if defined(OS_ANDROID) |
| 117 #include "content/browser/android/java_interfaces_impl.h" | 118 #include "content/browser/android/java_interfaces_impl.h" |
| 118 #include "content/browser/frame_host/render_frame_host_android.h" | 119 #include "content/browser/frame_host/render_frame_host_android.h" |
| 119 #include "content/browser/media/android/media_player_renderer.h" | 120 #include "content/browser/media/android/media_player_renderer.h" |
| (...skipping 1785 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 1905 } | 1906 } |
| 1906 | 1907 |
| 1907 void RenderFrameHostImpl::DisableBeforeUnloadHangMonitorForTesting() { | 1908 void RenderFrameHostImpl::DisableBeforeUnloadHangMonitorForTesting() { |
| 1908 beforeunload_timeout_.reset(); | 1909 beforeunload_timeout_.reset(); |
| 1909 } | 1910 } |
| 1910 | 1911 |
| 1911 bool RenderFrameHostImpl::IsBeforeUnloadHangMonitorDisabledForTesting() { | 1912 bool RenderFrameHostImpl::IsBeforeUnloadHangMonitorDisabledForTesting() { |
| 1912 return !beforeunload_timeout_; | 1913 return !beforeunload_timeout_; |
| 1913 } | 1914 } |
| 1914 | 1915 |
| 1916 bool RenderFrameHostImpl::IsFeatureEnabled( | |
| 1917 blink::WebFeaturePolicyFeature feature) { | |
| 1918 return feature_policy_->IsFeatureEnabledForOrigin(feature, | |
|
Reilly Grant (use Gerrit)
2017/04/13 20:21:45
I recommend making this feature_policy_ && feature
| |
| 1919 GetLastCommittedOrigin()); | |
| 1920 } | |
| 1921 | |
| 1915 void RenderFrameHostImpl::OnDidAccessInitialDocument() { | 1922 void RenderFrameHostImpl::OnDidAccessInitialDocument() { |
| 1916 delegate_->DidAccessInitialDocument(); | 1923 delegate_->DidAccessInitialDocument(); |
| 1917 } | 1924 } |
| 1918 | 1925 |
| 1919 void RenderFrameHostImpl::OnDidChangeOpener(int32_t opener_routing_id) { | 1926 void RenderFrameHostImpl::OnDidChangeOpener(int32_t opener_routing_id) { |
| 1920 frame_tree_node_->render_manager()->DidChangeOpener(opener_routing_id, | 1927 frame_tree_node_->render_manager()->DidChangeOpener(opener_routing_id, |
| 1921 GetSiteInstance()); | 1928 GetSiteInstance()); |
| 1922 } | 1929 } |
| 1923 | 1930 |
| 1924 void RenderFrameHostImpl::OnDidChangeName(const std::string& name, | 1931 void RenderFrameHostImpl::OnDidChangeName(const std::string& name, |
| (...skipping 1729 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 3654 } | 3661 } |
| 3655 | 3662 |
| 3656 void RenderFrameHostImpl::ForwardGetInterfaceToRenderFrame( | 3663 void RenderFrameHostImpl::ForwardGetInterfaceToRenderFrame( |
| 3657 const std::string& interface_name, | 3664 const std::string& interface_name, |
| 3658 mojo::ScopedMessagePipeHandle pipe) { | 3665 mojo::ScopedMessagePipeHandle pipe) { |
| 3659 GetRemoteInterfaces()->GetInterface(interface_name, std::move(pipe)); | 3666 GetRemoteInterfaces()->GetInterface(interface_name, std::move(pipe)); |
| 3660 } | 3667 } |
| 3661 #endif | 3668 #endif |
| 3662 | 3669 |
| 3663 } // namespace content | 3670 } // namespace content |
| OLD | NEW |