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

Unified Diff: chrome/browser/ui/webui/options/content_settings_handler.cc

Issue 1412523003: Adding <keygen> Content Setting (UI) (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebase on core CL. Created 5 years, 1 month 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/ui/webui/options/content_settings_handler.cc
diff --git a/chrome/browser/ui/webui/options/content_settings_handler.cc b/chrome/browser/ui/webui/options/content_settings_handler.cc
index 7f0f3a64c0748e0bb5818b1e03a3830ed92c843b..b8b8b058540d41e547ad62ea8269c5b4afffcf7b 100644
--- a/chrome/browser/ui/webui/options/content_settings_handler.cc
+++ b/chrome/browser/ui/webui/options/content_settings_handler.cc
@@ -80,6 +80,7 @@ const ContentSettingWithExceptions kContentTypesWithExceptions[] = {
{CONTENT_SETTINGS_TYPE_COOKIES, true},
{CONTENT_SETTINGS_TYPE_IMAGES, true},
{CONTENT_SETTINGS_TYPE_JAVASCRIPT, true},
+ {CONTENT_SETTINGS_TYPE_KEYGEN, true},
{CONTENT_SETTINGS_TYPE_PLUGINS, true},
{CONTENT_SETTINGS_TYPE_POPUPS, true},
{CONTENT_SETTINGS_TYPE_FULLSCREEN, true},
@@ -135,6 +136,7 @@ const ContentSettingsTypeNameEntry kContentSettingsTypeGroupNames[] = {
{CONTENT_SETTINGS_TYPE_COOKIES, "cookies"},
{CONTENT_SETTINGS_TYPE_IMAGES, "images"},
{CONTENT_SETTINGS_TYPE_JAVASCRIPT, "javascript"},
+ {CONTENT_SETTINGS_TYPE_KEYGEN, "keygen"},
{CONTENT_SETTINGS_TYPE_PLUGINS, "plugins"},
{CONTENT_SETTINGS_TYPE_POPUPS, "popups"},
{CONTENT_SETTINGS_TYPE_GEOLOCATION, "location"},
@@ -391,6 +393,11 @@ void ContentSettingsHandler::GetLocalizedValues(
{"javascriptHeader", IDS_JAVASCRIPT_HEADER},
{"javascriptAllow", IDS_JS_ALLOW_RADIO},
{"javascriptBlock", IDS_JS_DONOTALLOW_RADIO},
+ // Keygen filter.
+ {"keygenTabLabel", IDS_KEYGEN_TAB_LABEL},
+ {"keygenHeader", IDS_KEYGEN_HEADER},
+ {"keygenAllow", IDS_KEYGEN_ALLOW_RADIO},
+ {"keygenBlock", IDS_KEYGEN_DONOTALLOW_RADIO},
// Plugins filter.
{"pluginsTabLabel", IDS_PLUGIN_TAB_LABEL},
{"pluginsHeader", IDS_PLUGIN_HEADER},
@@ -504,6 +511,7 @@ void ContentSettingsHandler::GetLocalizedValues(
IDS_IMAGES_TAB_LABEL);
RegisterTitle(localized_strings, "javascript",
IDS_JAVASCRIPT_TAB_LABEL);
+ RegisterTitle(localized_strings, "keygen", IDS_KEYGEN_TAB_LABEL);
RegisterTitle(localized_strings, "plugins",
IDS_PLUGIN_TAB_LABEL);
RegisterTitle(localized_strings, "popups",
@@ -1386,6 +1394,10 @@ void ContentSettingsHandler::SetContentFilter(const base::ListValue* args) {
content::RecordAction(
UserMetricsAction("Options_DefaultJavaScriptSettingChanged"));
break;
+ case CONTENT_SETTINGS_TYPE_KEYGEN:
+ content::RecordAction(
+ UserMetricsAction("Options_DefaultKeygenSettingChanged"));
+ break;
case CONTENT_SETTINGS_TYPE_PLUGINS:
content::RecordAction(
UserMetricsAction("Options_DefaultPluginsSettingChanged"));

Powered by Google App Engine
This is Rietveld 408576698