diff options
-rw-r--r-- | chrome/browser/metrics/metrics_log.cc | 12 | ||||
-rw-r--r-- | chrome/common/metrics/proto/system_profile.proto | 6 |
2 files changed, 10 insertions, 8 deletions
diff --git a/chrome/browser/metrics/metrics_log.cc b/chrome/browser/metrics/metrics_log.cc index ce22188..7ff5b5a 100644 --- a/chrome/browser/metrics/metrics_log.cc +++ b/chrome/browser/metrics/metrics_log.cc @@ -70,7 +70,7 @@ namespace { // Returns the date at which the current metrics client ID was created as // a string containing milliseconds since the epoch, or "0" if none was found. -std::string GetInstallDate(PrefService* pref) { +std::string GetMetricsEnabledDate(PrefService* pref) { if (!pref) { NOTREACHED(); return "0"; @@ -644,7 +644,7 @@ void MetricsLog::WriteInstallElement() { // Write the XML version. // We'll write the protobuf version in RecordEnvironmentProto(). OPEN_ELEMENT_FOR_SCOPE("install"); - WriteAttribute("installdate", GetInstallDate(GetPrefService())); + WriteAttribute("installdate", GetMetricsEnabledDate(GetPrefService())); WriteIntAttribute("buildid", 0); // We're using appversion instead. } @@ -757,11 +757,11 @@ void MetricsLog::RecordEnvironmentProto( const std::vector<webkit::WebPluginInfo>& plugin_list, const GoogleUpdateMetrics& google_update_metrics) { SystemProfileProto* system_profile = uma_proto()->mutable_system_profile(); - int install_date; - bool success = base::StringToInt(GetInstallDate(GetPrefService()), - &install_date); + int enabled_date; + bool success = base::StringToInt(GetMetricsEnabledDate(GetPrefService()), + &enabled_date); DCHECK(success); - system_profile->set_install_date(install_date); + system_profile->set_uma_enabled_date(enabled_date); system_profile->set_application_locale( content::GetContentClient()->browser()->GetApplicationLocale()); diff --git a/chrome/common/metrics/proto/system_profile.proto b/chrome/common/metrics/proto/system_profile.proto index 420ec02..bf25865 100644 --- a/chrome/common/metrics/proto/system_profile.proto +++ b/chrome/common/metrics/proto/system_profile.proto @@ -50,8 +50,10 @@ message SystemProfileProto { } optional Channel channel = 10; - // The date the user installed the browser, in seconds since the epoch. - optional int64 install_date = 3; + // The date the user enabled UMA, in seconds since the epoch. + // If the user has toggled the UMA enabled state multiple times, this will + // be the most recent date on which UMA was enabled. + optional int64 uma_enabled_date = 3; // The user's selected application locale, i.e. the user interface language. // The locale includes a language code and, possibly, also a country code, |