| 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 "base/bind.h" | 7 #include "base/bind.h" |
| 8 #include "base/command_line.h" | 8 #include "base/command_line.h" |
| 9 #include "base/containers/hash_tables.h" | 9 #include "base/containers/hash_tables.h" |
| 10 #include "base/lazy_instance.h" | 10 #include "base/lazy_instance.h" |
| (...skipping 989 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1000 | 1000 |
| 1001 void RenderFrameHostImpl::OnUpdateEncoding(const std::string& encoding_name) { | 1001 void RenderFrameHostImpl::OnUpdateEncoding(const std::string& encoding_name) { |
| 1002 // This message is only sent for top-level frames. TODO(avi): when frame tree | 1002 // This message is only sent for top-level frames. TODO(avi): when frame tree |
| 1003 // mirroring works correctly, add a check here to enforce it. | 1003 // mirroring works correctly, add a check here to enforce it. |
| 1004 delegate_->UpdateEncoding(this, encoding_name); | 1004 delegate_->UpdateEncoding(this, encoding_name); |
| 1005 } | 1005 } |
| 1006 | 1006 |
| 1007 void RenderFrameHostImpl::OnBeginNavigation( | 1007 void RenderFrameHostImpl::OnBeginNavigation( |
| 1008 const FrameHostMsg_BeginNavigation_Params& params, | 1008 const FrameHostMsg_BeginNavigation_Params& params, |
| 1009 const CommonNavigationParams& common_params) { | 1009 const CommonNavigationParams& common_params) { |
| 1010 CHECK(CommandLine::ForCurrentProcess()->HasSwitch( | 1010 CHECK(base::CommandLine::ForCurrentProcess()->HasSwitch( |
| 1011 switches::kEnableBrowserSideNavigation)); | 1011 switches::kEnableBrowserSideNavigation)); |
| 1012 frame_tree_node()->navigator()->OnBeginNavigation( | 1012 frame_tree_node()->navigator()->OnBeginNavigation( |
| 1013 frame_tree_node(), params, common_params); | 1013 frame_tree_node(), params, common_params); |
| 1014 } | 1014 } |
| 1015 | 1015 |
| 1016 void RenderFrameHostImpl::OnAccessibilityEvents( | 1016 void RenderFrameHostImpl::OnAccessibilityEvents( |
| 1017 const std::vector<AccessibilityHostMsg_EventParams>& params, | 1017 const std::vector<AccessibilityHostMsg_EventParams>& params, |
| 1018 int reset_token) { | 1018 int reset_token) { |
| 1019 // Don't process this IPC if either we're waiting on a reset and this | 1019 // Don't process this IPC if either we're waiting on a reset and this |
| 1020 // IPC doesn't have the matching token ID, or if we're not waiting on a | 1020 // IPC doesn't have the matching token ID, or if we're not waiting on a |
| (...skipping 587 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1608 void RenderFrameHostImpl::DidUseGeolocationPermission() { | 1608 void RenderFrameHostImpl::DidUseGeolocationPermission() { |
| 1609 RenderFrameHost* top_frame = frame_tree_node()->frame_tree()->GetMainFrame(); | 1609 RenderFrameHost* top_frame = frame_tree_node()->frame_tree()->GetMainFrame(); |
| 1610 GetContentClient()->browser()->RegisterPermissionUsage( | 1610 GetContentClient()->browser()->RegisterPermissionUsage( |
| 1611 PERMISSION_GEOLOCATION, | 1611 PERMISSION_GEOLOCATION, |
| 1612 delegate_->GetAsWebContents(), | 1612 delegate_->GetAsWebContents(), |
| 1613 GetLastCommittedURL().GetOrigin(), | 1613 GetLastCommittedURL().GetOrigin(), |
| 1614 top_frame->GetLastCommittedURL().GetOrigin()); | 1614 top_frame->GetLastCommittedURL().GetOrigin()); |
| 1615 } | 1615 } |
| 1616 | 1616 |
| 1617 } // namespace content | 1617 } // namespace content |
| OLD | NEW |