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

Unified Diff: ash/test/user_metrics_recorder_test_api.cc

Issue 1093483002: Changed when the UMA metric Ash.NumberOfVisibleWindowsInPrimaryDisplay is recorded. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Addressed pkotwicz@ comments from patch set 3. Created 5 years, 8 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: ash/test/user_metrics_recorder_test_api.cc
diff --git a/ash/test/user_metrics_recorder_test_api.cc b/ash/test/user_metrics_recorder_test_api.cc
new file mode 100644
index 0000000000000000000000000000000000000000..d563240fa09d745f36eec65613fd1984c978349e
--- /dev/null
+++ b/ash/test/user_metrics_recorder_test_api.cc
@@ -0,0 +1,37 @@
+// Copyright 2015 The Chromium Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+#include "ash/test/user_metrics_recorder_test_api.h"
+
+#include "ash/metrics/user_metrics_recorder.h"
+
+namespace ash {
+namespace test {
+
+UserMetricsRecorderTestAPI::UserMetricsRecorderTestAPI(
+ UserMetricsRecorder* user_metrics_recorder)
+ : user_metrics_recorder_(user_metrics_recorder) {
+}
+
+UserMetricsRecorderTestAPI::~UserMetricsRecorderTestAPI() {
+}
+
+// static
+scoped_ptr<UserMetricsRecorder>
+UserMetricsRecorderTestAPI::CreateUserMetricsRecorder(
+ bool record_periodic_metrics) {
+ return scoped_ptr<UserMetricsRecorder>(
+ new UserMetricsRecorder(record_periodic_metrics));
+}
+
+void UserMetricsRecorderTestAPI::RecordPeriodicMetrics() {
+ user_metrics_recorder_->RecordPeriodicMetrics();
+}
+
+bool UserMetricsRecorderTestAPI::IsUserActiveInMultiWindowEnvironment() const {
+ return user_metrics_recorder_->IsUserActiveInMultiWindowEnvironment();
+}
+
+} // namespace test
+} // namespace ash
« ash/metrics/user_metrics_recorder_unittest.cc ('K') | « ash/test/user_metrics_recorder_test_api.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698