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

Unified Diff: chrome/browser/android/data_usage/data_use_tab_model.h

Issue 1444133002: Add UMA histograms for data usage tab model (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebased Created 5 years, 1 month 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
« no previous file with comments | « no previous file | chrome/browser/android/data_usage/data_use_tab_model.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/android/data_usage/data_use_tab_model.h
diff --git a/chrome/browser/android/data_usage/data_use_tab_model.h b/chrome/browser/android/data_usage/data_use_tab_model.h
index d5635e1b9d41c759d0f331271ddc4b3c4d7af68c..2420de1a7a85465d58ade6bbbb54af066d2fd8a7 100644
--- a/chrome/browser/android/data_usage/data_use_tab_model.h
+++ b/chrome/browser/android/data_usage/data_use_tab_model.h
@@ -16,6 +16,7 @@
#include "base/memory/weak_ptr.h"
#include "base/observer_list_threadsafe.h"
#include "base/threading/thread_checker.h"
+#include "base/time/time.h"
#include "chrome/browser/android/data_usage/tab_data_use_entry.h"
#include "components/data_usage/core/data_use.h"
#include "url/gurl.h"
@@ -126,9 +127,18 @@ class DataUseTabModel {
FRIEND_TEST_ALL_PREFIXES(DataUseTabModelTest, OnTrackingLabelRemoved);
FRIEND_TEST_ALL_PREFIXES(DataUseTabModelTest,
CompactTabEntriesWithinMaxLimit);
+ FRIEND_TEST_ALL_PREFIXES(DataUseTabModelTest,
+ UnexpiredTabEntryRemovaltimeHistogram);
+ FRIEND_TEST_ALL_PREFIXES(DataUseTabModelTest,
+ ExpiredInactiveTabEntryRemovaltimeHistogram);
+ FRIEND_TEST_ALL_PREFIXES(DataUseTabModelTest,
+ ExpiredActiveTabEntryRemovaltimeHistogram);
typedef base::hash_map<int32_t, TabDataUseEntry> TabEntryMap;
+ // Virtualized for unit test support.
+ virtual base::TimeTicks Now() const;
+
// Notifies the observers that a data usage tracking session started for
// |tab_id|.
void NotifyObserversOfTrackingStarting(int32_t tab_id);
« no previous file with comments | « no previous file | chrome/browser/android/data_usage/data_use_tab_model.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698