| Index: chrome/browser/subresource_filter/chrome_subresource_filter_client.cc
|
| diff --git a/chrome/browser/subresource_filter/chrome_subresource_filter_client.cc b/chrome/browser/subresource_filter/chrome_subresource_filter_client.cc
|
| index ab7d64f00fb53bd545ef1bc201c8a60050f31683..2c69c29bfbaed6220faa3dd5956f8a984f19f584 100644
|
| --- a/chrome/browser/subresource_filter/chrome_subresource_filter_client.cc
|
| +++ b/chrome/browser/subresource_filter/chrome_subresource_filter_client.cc
|
| @@ -116,11 +116,14 @@ void ChromeSubresourceFilterClient::ToggleNotificationVisibility(
|
| }
|
| }
|
|
|
| -bool ChromeSubresourceFilterClient::ShouldSuppressActivation(
|
| - content::NavigationHandle* navigation_handle) {
|
| +bool ChromeSubresourceFilterClient::OnPageActivationComputed(
|
| + content::NavigationHandle* navigation_handle,
|
| + bool activated) {
|
| const GURL& url(navigation_handle->GetURL());
|
| - return navigation_handle->IsInMainFrame() &&
|
| - (whitelisted_hosts_.find(url.host()) != whitelisted_hosts_.end() ||
|
| + DCHECK(navigation_handle->IsInMainFrame());
|
| + // Return whether the activation should be whitelisted.
|
| + return activated &&
|
| + (whitelisted_hosts_.count(url.host()) ||
|
| settings_manager_->GetSitePermission(url) == CONTENT_SETTING_BLOCK);
|
| }
|
|
|
|
|