Index: components/translate/core/browser/translate_browser_metrics.cc |
diff --git a/chrome/browser/translate/translate_browser_metrics.cc b/components/translate/core/browser/translate_browser_metrics.cc |
similarity index 85% |
rename from chrome/browser/translate/translate_browser_metrics.cc |
rename to components/translate/core/browser/translate_browser_metrics.cc |
index a6605bd4e47e100ce44d853d58d84d6f1747e49d..68310551ca5120c25a2ec82e09fc6ca2b7016f77 100644 |
--- a/chrome/browser/translate/translate_browser_metrics.cc |
+++ b/components/translate/core/browser/translate_browser_metrics.cc |
@@ -2,14 +2,14 @@ |
// Use of this source code is governed by a BSD-style license that can be |
// found in the LICENSE file. |
-#include "chrome/browser/translate/translate_browser_metrics.h" |
+#include "components/translate/core/browser/translate_browser_metrics.h" |
#include <string> |
#include "base/basictypes.h" |
#include "base/metrics/histogram.h" |
#include "base/metrics/sparse_histogram.h" |
-#include "chrome/browser/language_usage_metrics.h" |
+#include "components/language_usage_metrics/language_usage_metrics.h" |
namespace { |
@@ -63,18 +63,21 @@ void ReportLanguageDetectionError() { |
} |
void ReportLocalesOnDisabledByPrefs(const std::string& locale) { |
- UMA_HISTOGRAM_SPARSE_SLOWLY(kTranslateLocalesOnDisabledByPrefs, |
- LanguageUsageMetrics::ToLanguageCode(locale)); |
+ UMA_HISTOGRAM_SPARSE_SLOWLY( |
+ kTranslateLocalesOnDisabledByPrefs, |
+ language_usage_metrics::LanguageUsageMetrics::ToLanguageCode(locale)); |
} |
void ReportUndisplayableLanguage(const std::string& language) { |
- int language_code = LanguageUsageMetrics::ToLanguageCode(language); |
+ int language_code = |
+ language_usage_metrics::LanguageUsageMetrics::ToLanguageCode(language); |
UMA_HISTOGRAM_SPARSE_SLOWLY(kTranslateUndisplayableLanguage, |
language_code); |
} |
void ReportUnsupportedLanguageAtInitiation(const std::string& language) { |
- int language_code = LanguageUsageMetrics::ToLanguageCode(language); |
+ int language_code = |
+ language_usage_metrics::LanguageUsageMetrics::ToLanguageCode(language); |
UMA_HISTOGRAM_SPARSE_SLOWLY(kTranslateUnsupportedLanguageAtInitiation, |
language_code); |
} |