Index: components/data_reduction_proxy/core/browser/data_reduction_proxy_settings.cc |
diff --git a/components/data_reduction_proxy/core/browser/data_reduction_proxy_settings.cc b/components/data_reduction_proxy/core/browser/data_reduction_proxy_settings.cc |
index 19f3e25b4d888ffbdec22acebb538a68a0f5dd21..df934169add94f7572cc7396d973d0160da49649 100644 |
--- a/components/data_reduction_proxy/core/browser/data_reduction_proxy_settings.cc |
+++ b/components/data_reduction_proxy/core/browser/data_reduction_proxy_settings.cc |
@@ -254,6 +254,12 @@ void DataReductionProxySettings::MaybeActivateDataReductionProxy( |
prefs->SetBoolean(prefs::kDataReductionProxyWasEnabledBefore, true); |
ResetDataReductionStatistics(); |
} |
+ if (!at_startup) { |
+ if (IsDataReductionProxyEnabled()) |
+ RecordSettingsEnabledState(DATA_REDUCTION_SETTINGS_ACTION_OFF_TO_ON); |
+ else |
+ RecordSettingsEnabledState(DATA_REDUCTION_SETTINGS_ACTION_ON_TO_OFF); |
+ } |
// Configure use of the data reduction proxy if it is enabled. |
if (at_startup && !data_reduction_proxy_service_->Initialized()) |
deferred_initialization_ = true; |
@@ -289,6 +295,12 @@ void DataReductionProxySettings::RecordStartupState(ProxyStartupState state) { |
PROXY_STARTUP_STATE_COUNT); |
} |
+void DataReductionProxySettings::RecordSettingsEnabledState( |
sclittle
2015/10/09 20:52:48
It doesn't look like this function needs to be a m
Raj
2015/10/10 01:51:47
Done.
|
+ DataReductionSettingsEnabledAction action) { |
+ UMA_HISTOGRAM_ENUMERATION("DataReductionProxy.EnabledState", action, |
+ DATA_REDUCTION_SETTINGS_ACTION_BOUNDARY); |
+} |
+ |
void DataReductionProxySettings::RecordLoFiImplicitOptOutAction( |
LoFiImplicitOptOutAction action) const { |
net::NetworkChangeNotifier::ConnectionType connection_type = |