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

Unified Diff: chrome/browser/chrome_content_browser_client.cc

Issue 7831075: Delegating the "are images allowed" decision to renderer. (Closed) Base URL: http://git.chromium.org/git/chromium.git@trunk
Patch Set: Rebased. Created 9 years, 2 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: chrome/browser/chrome_content_browser_client.cc
diff --git a/chrome/browser/chrome_content_browser_client.cc b/chrome/browser/chrome_content_browser_client.cc
index 27df9071ae3bbe02233e5cbee84896bb59a5a99c..7865dc04d79a9428b0a7dfc5a40520431d966992 100644
--- a/chrome/browser/chrome_content_browser_client.cc
+++ b/chrome/browser/chrome_content_browser_client.cc
@@ -258,6 +258,17 @@ void ChromeContentBrowserClient::BrowserRenderProcessHostCreated(
host->Send(new ChromeViewMsg_SetIsIncognitoProcess(
profile->IsOffTheRecord()));
+
+ ContentSettingsForOneType settings;
+ HostContentSettingsMap* map =
+ profile->GetHostContentSettingsMap();
+ map->GetSettingsForOneType(
+ CONTENT_SETTINGS_TYPE_IMAGES, "",
+ &settings);
+ settings.push_back(ContentSettingPatternSourceTuple(
+ ContentSettingsPattern::Wildcard(), ContentSettingsPattern::Wildcard(),
+ map->GetDefaultContentSetting(CONTENT_SETTINGS_TYPE_IMAGES), "", false));
+ host->Send(new ChromeViewMsg_SetImageSettingRules(settings));
}
void ChromeContentBrowserClient::PluginProcessHostCreated(

Powered by Google App Engine
This is Rietveld 408576698