OLD | NEW |
1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #include "content/browser/power_usage_monitor_impl.h" | 5 #include "content/browser/power_usage_monitor_impl.h" |
6 | 6 |
7 #include <stddef.h> | 7 #include <stddef.h> |
8 #include <utility> | 8 #include <utility> |
9 | 9 |
10 #include "base/bind.h" | 10 #include "base/bind.h" |
11 #include "base/lazy_instance.h" | 11 #include "base/lazy_instance.h" |
12 #include "base/logging.h" | 12 #include "base/logging.h" |
13 #include "base/macros.h" | 13 #include "base/macros.h" |
14 #include "base/metrics/histogram.h" | 14 #include "base/metrics/histogram_macros.h" |
15 #include "base/strings/stringprintf.h" | 15 #include "base/strings/stringprintf.h" |
16 #include "base/sys_info.h" | 16 #include "base/sys_info.h" |
17 #include "content/public/browser/browser_thread.h" | 17 #include "content/public/browser/browser_thread.h" |
18 #include "content/public/browser/notification_service.h" | 18 #include "content/public/browser/notification_service.h" |
19 #include "content/public/browser/notification_source.h" | 19 #include "content/public/browser/notification_source.h" |
20 #include "content/public/browser/notification_types.h" | 20 #include "content/public/browser/notification_types.h" |
21 #include "content/public/browser/power_usage_monitor.h" | 21 #include "content/public/browser/power_usage_monitor.h" |
22 #include "content/public/browser/render_process_host.h" | 22 #include "content/public/browser/render_process_host.h" |
23 | 23 |
24 namespace content { | 24 namespace content { |
(...skipping 244 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
269 RenderProcessHost* rph = Source<RenderProcessHost>(source).ptr(); | 269 RenderProcessHost* rph = Source<RenderProcessHost>(source).ptr(); |
270 OnRenderProcessNotification(type, rph->GetID()); | 270 OnRenderProcessNotification(type, rph->GetID()); |
271 } | 271 } |
272 | 272 |
273 void PowerUsageMonitor::CancelPendingHistogramReporting() { | 273 void PowerUsageMonitor::CancelPendingHistogramReporting() { |
274 // Cancel any in-progress histogram reports and reporting of discharge UMA. | 274 // Cancel any in-progress histogram reports and reporting of discharge UMA. |
275 system_interface_->CancelPendingHistogramReports(); | 275 system_interface_->CancelPendingHistogramReports(); |
276 } | 276 } |
277 | 277 |
278 } // namespace content | 278 } // namespace content |
OLD | NEW |