Index: chrome/browser/performance_monitor/constants.cc |
diff --git a/chrome/browser/performance_monitor/constants.cc b/chrome/browser/performance_monitor/constants.cc |
index 8efa06add9279645d2a7b0dd5d90458850b41420..dd9a11541792ae88dcaa23d6a81ea0221fd33433 100644 |
--- a/chrome/browser/performance_monitor/constants.cc |
+++ b/chrome/browser/performance_monitor/constants.cc |
@@ -4,9 +4,9 @@ |
#include "chrome/browser/performance_monitor/constants.h" |
-namespace performance_monitor { |
+#include "base/time.h" |
-// TODO(chebert): i18n on all constants. |
+namespace performance_monitor { |
// The error message displayed when a metric's details are not found. |
const char kMetricNotFoundError[] = "Metric details not found."; |
@@ -28,4 +28,16 @@ const char kStateChromeVersion[] = "chrome_version"; |
// collisions in the database. |
const char kStateProfilePrefix[] = "profile"; |
+// Unit values |
+// Memory measurements |
+const int64 kBytesPerKilobyte = 1 << 10; |
+const int64 kBytesPerMegabyte = kBytesPerKilobyte * (1 << 10); |
+const int64 kBytesPerGigabyte = kBytesPerMegabyte * (1 << 10); |
+const int64 kBytesPerTerabyte = kBytesPerGigabyte * (1 << 10); |
+ |
+// Time measurements |
+const int64 kMicrosecondsPerMonth = base::Time::kMicrosecondsPerDay * 30; |
+const int64 kMicrosecondsPerYear = base::Time::kMicrosecondsPerDay * 365; |
+ |
+ |
} // namespace performance_monitor |