summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--chrome/renderer/chrome_content_renderer_client.cc6
1 files changed, 4 insertions, 2 deletions
diff --git a/chrome/renderer/chrome_content_renderer_client.cc b/chrome/renderer/chrome_content_renderer_client.cc
index 1e97675..91841cf 100644
--- a/chrome/renderer/chrome_content_renderer_client.cc
+++ b/chrome/renderer/chrome_content_renderer_client.cc
@@ -327,6 +327,7 @@ WebPlugin* ChromeContentRendererClient::CreatePlugin(
scoped_ptr<webkit::npapi::PluginGroup> group(
webkit::npapi::PluginList::Singleton()->GetPluginGroup(info));
+ ContentSettingsType content_type = CONTENT_SETTINGS_TYPE_PLUGINS;
ContentSetting plugin_setting = CONTENT_SETTING_DEFAULT;
std::string resource;
if (cmd->HasSwitch(switches::kEnableResourceContentSettings))
@@ -391,8 +392,9 @@ WebPlugin* ChromeContentRendererClient::CreatePlugin(
bool is_nacl_plugin =
info.name == ASCIIToUTF16(ChromeContentClient::kNaClPluginName);
if (is_nacl_plugin) {
+ content_type = CONTENT_SETTINGS_TYPE_JAVASCRIPT;
plugin_setting =
- observer->GetContentSetting(CONTENT_SETTINGS_TYPE_JAVASCRIPT);
+ observer->GetContentSetting(content_type);
}
if (plugin_setting == CONTENT_SETTING_ALLOW ||
@@ -471,7 +473,7 @@ WebPlugin* ChromeContentRendererClient::CreatePlugin(
frame, params, info.path, actual_mime_type);
}
- observer->DidBlockContentType(CONTENT_SETTINGS_TYPE_PLUGINS, resource);
+ observer->DidBlockContentType(content_type, resource);
if (plugin_setting == CONTENT_SETTING_ASK) {
RenderThread::RecordUserMetrics("Plugin_ClickToPlay");
return CreatePluginPlaceholder(