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

Unified Diff: content/browser/frame_host/navigation_handle_impl.cc

Issue 1964863002: Persist prompt/block download limiter state on renderer-initiated loads. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Adding subframe limiter test Created 4 years, 7 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 side-by-side diff with in-line comments
Download patch
Index: content/browser/frame_host/navigation_handle_impl.cc
diff --git a/content/browser/frame_host/navigation_handle_impl.cc b/content/browser/frame_host/navigation_handle_impl.cc
index 894f6ea13c0bced481e0404917b7837f41a1c2d4..4c19c5c80f6bf2adf8363721122edb65456ae119 100644
--- a/content/browser/frame_host/navigation_handle_impl.cc
+++ b/content/browser/frame_host/navigation_handle_impl.cc
@@ -34,18 +34,21 @@ void UpdateThrottleCheckResult(
std::unique_ptr<NavigationHandleImpl> NavigationHandleImpl::Create(
const GURL& url,
FrameTreeNode* frame_tree_node,
+ bool is_renderer_initiated,
bool is_synchronous,
bool is_srcdoc,
const base::TimeTicks& navigation_start,
int pending_nav_entry_id) {
return std::unique_ptr<NavigationHandleImpl>(
- new NavigationHandleImpl(url, frame_tree_node, is_synchronous, is_srcdoc,
- navigation_start, pending_nav_entry_id));
+ new NavigationHandleImpl(url, frame_tree_node, is_renderer_initiated,
+ is_synchronous, is_srcdoc, navigation_start,
+ pending_nav_entry_id));
}
NavigationHandleImpl::NavigationHandleImpl(
const GURL& url,
FrameTreeNode* frame_tree_node,
+ bool is_renderer_initiated,
bool is_synchronous,
bool is_srcdoc,
const base::TimeTicks& navigation_start,
@@ -56,6 +59,7 @@ NavigationHandleImpl::NavigationHandleImpl(
is_external_protocol_(false),
net_error_code_(net::OK),
render_frame_host_(nullptr),
+ is_renderer_initiated_(is_renderer_initiated),
is_same_page_(false),
is_synchronous_(is_synchronous),
is_srcdoc_(is_srcdoc),
@@ -110,6 +114,10 @@ bool NavigationHandleImpl::IsParentMainFrame() {
return false;
}
+bool NavigationHandleImpl::IsRendererInitiated() {
+ return is_renderer_initiated_;
+}
+
bool NavigationHandleImpl::IsSynchronousNavigation() {
return is_synchronous_;
}
« no previous file with comments | « content/browser/frame_host/navigation_handle_impl.h ('k') | content/browser/frame_host/navigation_handle_impl_browsertest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698