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

Unified Diff: components/subresource_filter/content/browser/subresource_filter_client.h

Issue 2874663002: [subresource_filter] s/ShouldSuppressActivation/OnPageActivationComputed (Closed)
Patch Set: Created 3 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: components/subresource_filter/content/browser/subresource_filter_client.h
diff --git a/components/subresource_filter/content/browser/subresource_filter_client.h b/components/subresource_filter/content/browser/subresource_filter_client.h
index 6792ad691eb6f779a45d17804b28a41406f50d80..3719591e2b8537b305fa0304ac94df3ed2d05340 100644
--- a/components/subresource_filter/content/browser/subresource_filter_client.h
+++ b/components/subresource_filter/content/browser/subresource_filter_client.h
@@ -28,11 +28,15 @@ class SubresourceFilterClient {
// off.
virtual void ToggleNotificationVisibility(bool visibility) = 0;
- // Returns true if the navigation is in a main frame and the URL is
- // whitelisted from activation via content settings or by the per-tab
- // whitelist.
- virtual bool ShouldSuppressActivation(
- content::NavigationHandle* navigation_handle) = 0;
+ // Called when the activation decision is otherwise completely computed by the
+ // subresource filter. At this point, the embedder still has a chance to
+ // return false to suppress the activation. Returns whether the activation
+ // should be whitelisted for this navigation.
+ //
+ // Precondition: The navigation must be a main frame navigation.
+ virtual bool OnPageActivationComputed(
+ content::NavigationHandle* navigation_handle,
+ bool activated) = 0;
// Adds |top_level_url| to the BLOCKED state via content settings for the
// current profile.

Powered by Google App Engine
This is Rietveld 408576698