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

Unified Diff: chrome/browser/chrome_browser_main.cc

Issue 472383002: Add ProcessPowerCollector to audit power information. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Use PowerManagerClient. Created 6 years, 4 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/chrome_browser_main.cc
diff --git a/chrome/browser/chrome_browser_main.cc b/chrome/browser/chrome_browser_main.cc
index a273d788b9b4e3aa992b9e9788725929f7f61189..b5aa5b0303ff6fa11b822edf6145a67476b4ec7a 100644
--- a/chrome/browser/chrome_browser_main.cc
+++ b/chrome/browser/chrome_browser_main.cc
@@ -70,6 +70,7 @@
#include "chrome/browser/performance_monitor/performance_monitor.h"
#include "chrome/browser/performance_monitor/startup_timer.h"
#include "chrome/browser/plugins/plugin_prefs.h"
+#include "chrome/browser/power/process_power_collector.h"
#include "chrome/browser/pref_service_flags_storage.h"
#include "chrome/browser/prefs/chrome_pref_service_factory.h"
#include "chrome/browser/prefs/command_line_pref_store.h"
@@ -1545,6 +1546,11 @@ int ChromeBrowserMainParts::PreMainMessageLoopRunImpl() {
performance_monitor::PerformanceMonitor::GetInstance()->Initialize();
+#if !defined(OS_ANDROID) && !defined(OS_IOS)
+ process_power_collector_.reset(new ProcessPowerCollector);
+ process_power_collector_->Initialize();
+#endif
+
PostBrowserStart();
if (parameters().ui_task) {

Powered by Google App Engine
This is Rietveld 408576698