Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(7)

Unified Diff: chrome/browser/ui/webui/performance_monitor/performance_monitor_ui_constants.cc

Issue 10907121: Add guards to metric values; erase bad events/metrics from db (Closed) Base URL: http://git.chromium.org/chromium/src.git@dc_use_units
Patch Set: Estade's requests Created 8 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: chrome/browser/ui/webui/performance_monitor/performance_monitor_ui_constants.cc
diff --git a/chrome/browser/ui/webui/performance_monitor/performance_monitor_ui_constants.cc b/chrome/browser/ui/webui/performance_monitor/performance_monitor_ui_constants.cc
index 1fd6c3cfc31244f791c3dff19cbdb86016f33a98..37c463c545d59de4fad11597faca59e317dd4aad 100644
--- a/chrome/browser/ui/webui/performance_monitor/performance_monitor_ui_constants.cc
+++ b/chrome/browser/ui/webui/performance_monitor/performance_monitor_ui_constants.cc
@@ -5,25 +5,13 @@
#include "chrome/browser/ui/webui/performance_monitor/performance_monitor_ui_constants.h"
#include "base/logging.h"
+#include "chrome/browser/performance_monitor/constants.h"
#include "base/time.h"
namespace performance_monitor {
namespace {
-// 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 - Most of these are imported from base/time.h
-// These units are used for display (and it's related calculations), not for
-// any mathematical analysis. Thus we can estimate for values without an exact
-// conversion.
-const int64 kMicrosecondsPerMonth = base::Time::kMicrosecondsPerDay * 30;
-const int64 kMicrosecondsPerYear = base::Time::kMicrosecondsPerDay * 365;
-
// Keep this list synced with the enum declared in the .h file.
const UnitDetails kUnitDetailsList[] = {
{ UNIT_BYTES, MEASUREMENT_TYPE_MEMORY, 1 },

Powered by Google App Engine
This is Rietveld 408576698