Index: base/timer/hi_res_timer_manager_win.cc |
diff --git a/base/timer/hi_res_timer_manager_win.cc b/base/timer/hi_res_timer_manager_win.cc |
index 98b41d700926c76cf6849c21d3add8adc299b1e8..692f72b4e594481897bf022e256d51bb65b1f1b9 100644 |
--- a/base/timer/hi_res_timer_manager_win.cc |
+++ b/base/timer/hi_res_timer_manager_win.cc |
@@ -11,12 +11,14 @@ |
HighResolutionTimerManager::HighResolutionTimerManager() |
: hi_res_clock_available_(false) { |
- base::PowerMonitor::AddObserver(this); |
- UseHiResClock(!base::PowerMonitor::IsOnBatteryPower()); |
+ base::PowerMonitor* power_monitor = base::PowerMonitor::Get(); |
+ DCHECK(power_monitor != NULL); |
+ power_monitor->AddObserver(this); |
+ UseHiResClock(!power_monitor->IsOnBatteryPower()); |
} |
HighResolutionTimerManager::~HighResolutionTimerManager() { |
- base::PowerMonitor::RemoveObserver(this); |
+ base::PowerMonitor::Get()->RemoveObserver(this); |
UseHiResClock(false); |
} |