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

Unified Diff: chrome/browser/permissions/delegation_tracker.cc

Issue 2676203002: Convert DelegationTracker::DelegatedForChild to use the new navigation callbacks. (Closed)
Patch Set: Created 3 years, 10 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
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/permissions/delegation_tracker.cc
diff --git a/chrome/browser/permissions/delegation_tracker.cc b/chrome/browser/permissions/delegation_tracker.cc
index 491f16e1e2c13548102f7bc329dd41e88cad77dd..3a515fb35274e52e4c572aa120aa68bbf2dd1176 100644
--- a/chrome/browser/permissions/delegation_tracker.cc
+++ b/chrome/browser/permissions/delegation_tracker.cc
@@ -8,6 +8,7 @@
#include "base/memory/ptr_util.h"
#include "chrome/browser/permissions/permission_util.h"
+#include "content/public/browser/navigation_handle.h"
#include "content/public/browser/permission_type.h"
#include "content/public/browser/render_frame_host.h"
#include "content/public/browser/web_contents.h"
@@ -49,11 +50,10 @@ class DelegationTracker::DelegatedForChild : content::WebContentsObserver {
ClearPermissions(render_frame_host);
}
- void DidNavigateAnyFrame(
- content::RenderFrameHost* render_frame_host,
- const content::LoadCommittedDetails& details,
- const content::FrameNavigateParams& params) override {
- ClearPermissions(render_frame_host);
+ void DidFinishNavigation(
+ content::NavigationHandle* navigation_handle) override {
+ if (navigation_handle->HasCommitted())
+ ClearPermissions(navigation_handle->GetRenderFrameHost());
}
content::RenderFrameHost* child_rfh_;
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698