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

Unified Diff: chrome/browser/renderer_host/async_resource_handler.cc

Issue 1744003: Send content settings based on the URL to the renderer instead of just the host. (Closed)
Patch Set: nits Created 10 years, 8 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 | « chrome/browser/host_zoom_map_unittest.cc ('k') | chrome/browser/renderer_host/resource_message_filter.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/renderer_host/async_resource_handler.cc
diff --git a/chrome/browser/renderer_host/async_resource_handler.cc b/chrome/browser/renderer_host/async_resource_handler.cc
index 4cc35bb7b07c07741e8956711837889551a9683a..a4a3494547ba67cce4dc7f0a29bdb2db381be751 100644
--- a/chrome/browser/renderer_host/async_resource_handler.cc
+++ b/chrome/browser/renderer_host/async_resource_handler.cc
@@ -110,16 +110,15 @@ bool AsyncResourceHandler::OnResponseStarted(int request_id,
ResourceDispatcherHostRequestInfo* info = rdh_->InfoForRequest(request);
if (info->resource_type() == ResourceType::MAIN_FRAME) {
GURL request_url(request->url());
- std::string host(request_url.host());
ChromeURLRequestContext* context =
static_cast<ChromeURLRequestContext*>(request->context());
- if (!host.empty() && context) {
- receiver_->Send(new ViewMsg_SetContentSettingsForLoadingHost(
- info->route_id(), host,
+ if (context) {
+ receiver_->Send(new ViewMsg_SetContentSettingsForLoadingURL(
+ info->route_id(), request_url,
context->host_content_settings_map()->GetContentSettings(
request_url)));
- receiver_->Send(new ViewMsg_SetZoomLevelForLoadingHost(info->route_id(),
- host, context->host_zoom_map()->GetZoomLevel(host)));
+ receiver_->Send(new ViewMsg_SetZoomLevelForLoadingURL(info->route_id(),
+ request_url, context->host_zoom_map()->GetZoomLevel(request_url)));
}
}
« no previous file with comments | « chrome/browser/host_zoom_map_unittest.cc ('k') | chrome/browser/renderer_host/resource_message_filter.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698