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

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

Issue 1269813002: Add a NavigationThrottle to the public content/ interface (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@navigation-api
Patch Set: Created 5 years, 3 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 883 matching lines...) Expand 10 before | Expand all | Expand 10 after
894 // navigation. 894 // navigation.
895 if (navigation_handle_ && 895 if (navigation_handle_ &&
896 navigation_handle_->GetURL() != validated_params.url) { 896 navigation_handle_->GetURL() != validated_params.url) {
897 navigation_handle_.reset(); 897 navigation_handle_.reset();
898 } 898 }
899 899
900 // Synchronous renderer-initiated navigations will send a 900 // Synchronous renderer-initiated navigations will send a
901 // DidCommitProvisionalLoad IPC without a prior DidStartProvisionalLoad 901 // DidCommitProvisionalLoad IPC without a prior DidStartProvisionalLoad
902 // message. 902 // message.
903 if (!navigation_handle_) { 903 if (!navigation_handle_) {
904 GURL filtered_url = validated_params.url;
905 GetProcess()->FilterURL(false, &filtered_url);
904 navigation_handle_ = NavigationHandleImpl::Create( 906 navigation_handle_ = NavigationHandleImpl::Create(
905 validated_params.url, frame_tree_node_->IsMainFrame(), 907 validated_params.url, filtered_url, frame_tree_node_->IsMainFrame(),
906 frame_tree_node_->navigator()->GetDelegate()); 908 frame_tree_node_->navigator()->GetDelegate());
907 } 909 }
908 910
909 accessibility_reset_count_ = 0; 911 accessibility_reset_count_ = 0;
910 frame_tree_node()->navigator()->DidNavigate(this, validated_params); 912 frame_tree_node()->navigator()->DidNavigate(this, validated_params);
911 913
912 // PlzNavigate 914 // PlzNavigate
913 if (base::CommandLine::ForCurrentProcess()->HasSwitch( 915 if (base::CommandLine::ForCurrentProcess()->HasSwitch(
914 switches::kEnableBrowserSideNavigation)) { 916 switches::kEnableBrowserSideNavigation)) {
915 pending_commit_ = false; 917 pending_commit_ = false;
(...skipping 1299 matching lines...) Expand 10 before | Expand all | Expand 10 after
2215 BrowserPluginInstanceIDToAXTreeID(value))); 2217 BrowserPluginInstanceIDToAXTreeID(value)));
2216 break; 2218 break;
2217 case AX_CONTENT_INT_ATTRIBUTE_LAST: 2219 case AX_CONTENT_INT_ATTRIBUTE_LAST:
2218 NOTREACHED(); 2220 NOTREACHED();
2219 break; 2221 break;
2220 } 2222 }
2221 } 2223 }
2222 } 2224 }
2223 2225
2224 } // namespace content 2226 } // namespace content
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698