From 2ccb70ec0356cb9257ce62958e37ec19c1b7c32c Mon Sep 17 00:00:00 2001 From: "nsylvain@chromium.org" Date: Tue, 7 Sep 2010 05:15:20 +0000 Subject: Revert 58663 - Revert 58641 - Add user metrics for nonsandboxed plugin infobar. BUG=52341 TEST=none Review URL: http://codereview.chromium.org/3303003 TBR=bauerb@chromium.org Review URL: http://codereview.chromium.org/3300015 TBR=mal@chromium.org Review URL: http://codereview.chromium.org/3303011 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@58666 0039d316-1c4b-4281-b951-d872f2087c98 --- chrome/browser/host_content_settings_map.cc | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) (limited to 'chrome/browser/host_content_settings_map.cc') diff --git a/chrome/browser/host_content_settings_map.cc b/chrome/browser/host_content_settings_map.cc index 8cb31f6..9c01798 100644 --- a/chrome/browser/host_content_settings_map.cc +++ b/chrome/browser/host_content_settings_map.cc @@ -8,6 +8,7 @@ #include "base/string_util.h" #include "base/utf_string_conversions.h" #include "chrome/browser/chrome_thread.h" +#include "chrome/browser/metrics/user_metrics.h" #include "chrome/browser/prefs/pref_service.h" #include "chrome/browser/profile.h" #include "chrome/browser/prefs/scoped_pref_update.h" @@ -701,11 +702,17 @@ void HostContentSettingsMap::SetBlockNonsandboxedPlugins(bool block) { block_nonsandboxed_plugins_ = block; } + PrefService* prefs = profile_->GetPrefs(); - if (block) + if (block) { + UserMetrics::RecordAction( + UserMetricsAction("BlockNonsandboxedPlugins_Enable")); prefs->SetBoolean(prefs::kBlockNonsandboxedPlugins, true); - else + } else { + UserMetrics::RecordAction( + UserMetricsAction("BlockNonsandboxedPlugins_Disable")); prefs->ClearPref(prefs::kBlockNonsandboxedPlugins); + } } void HostContentSettingsMap::ResetToDefaults() { -- cgit v1.1