Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(421)

Side by Side Diff: content/browser/frame_host/render_frame_host_impl.cc

Issue 1108863002: Revert "Ensure we properly set PageTransition for iframes." (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: merge Created 5 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
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 1654 matching lines...) Expand 10 before | Expand all | Expand 10 after
1665 Navigate(common_params, StartNavigationParams(), RequestNavigationParams()); 1665 Navigate(common_params, StartNavigationParams(), RequestNavigationParams());
1666 } 1666 }
1667 1667
1668 void RenderFrameHostImpl::OpenURL(const FrameHostMsg_OpenURL_Params& params, 1668 void RenderFrameHostImpl::OpenURL(const FrameHostMsg_OpenURL_Params& params,
1669 SiteInstance* source_site_instance) { 1669 SiteInstance* source_site_instance) {
1670 GURL validated_url(params.url); 1670 GURL validated_url(params.url);
1671 GetProcess()->FilterURL(false, &validated_url); 1671 GetProcess()->FilterURL(false, &validated_url);
1672 1672
1673 TRACE_EVENT1("navigation", "RenderFrameHostImpl::OpenURL", "url", 1673 TRACE_EVENT1("navigation", "RenderFrameHostImpl::OpenURL", "url",
1674 validated_url.possibly_invalid_spec()); 1674 validated_url.possibly_invalid_spec());
1675 ui::PageTransition transition = ui::PAGE_TRANSITION_LINK;
1676 if (frame_tree_node_->parent()) {
1677 transition = params.should_replace_current_entry
1678 ? ui::PAGE_TRANSITION_AUTO_SUBFRAME
1679 : ui::PAGE_TRANSITION_MANUAL_SUBFRAME;
1680 }
1681 frame_tree_node_->navigator()->RequestOpenURL( 1675 frame_tree_node_->navigator()->RequestOpenURL(
1682 this, validated_url, source_site_instance, params.referrer, transition, 1676 this, validated_url, source_site_instance, params.referrer,
1683 params.disposition, params.should_replace_current_entry, 1677 params.disposition, params.should_replace_current_entry,
1684 params.user_gesture); 1678 params.user_gesture);
1685 } 1679 }
1686 1680
1687 void RenderFrameHostImpl::Stop() { 1681 void RenderFrameHostImpl::Stop() {
1688 Send(new FrameMsg_Stop(routing_id_)); 1682 Send(new FrameMsg_Stop(routing_id_));
1689 } 1683 }
1690 1684
1691 void RenderFrameHostImpl::DispatchBeforeUnload(bool for_navigation) { 1685 void RenderFrameHostImpl::DispatchBeforeUnload(bool for_navigation) {
1692 // TODO(creis): Support beforeunload on subframes. For now just pretend that 1686 // TODO(creis): Support beforeunload on subframes. For now just pretend that
(...skipping 373 matching lines...) Expand 10 before | Expand all | Expand 10 after
2066 return; 2060 return;
2067 2061
2068 permission_manager->RegisterPermissionUsage( 2062 permission_manager->RegisterPermissionUsage(
2069 PermissionType::GEOLOCATION, 2063 PermissionType::GEOLOCATION,
2070 GetLastCommittedURL().GetOrigin(), 2064 GetLastCommittedURL().GetOrigin(),
2071 frame_tree_node()->frame_tree()->GetMainFrame() 2065 frame_tree_node()->frame_tree()->GetMainFrame()
2072 ->GetLastCommittedURL().GetOrigin()); 2066 ->GetLastCommittedURL().GetOrigin());
2073 } 2067 }
2074 2068
2075 } // namespace content 2069 } // namespace content
OLDNEW
« no previous file with comments | « content/browser/frame_host/navigator_impl.cc ('k') | content/browser/security_exploit_browsertest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698