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

Unified Diff: content/common/hi_res_timer_manager_win.cc

Issue 6904117: Reland old fix that was reverted without my knowledge. (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: '' Created 9 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: content/common/hi_res_timer_manager_win.cc
===================================================================
--- content/common/hi_res_timer_manager_win.cc (revision 82646)
+++ content/common/hi_res_timer_manager_win.cc (working copy)
@@ -7,7 +7,7 @@
#include "base/time.h"
HighResolutionTimerManager::HighResolutionTimerManager()
- : hi_res_clock_used_(false) {
+ : hi_res_clock_available_(false) {
ui::SystemMonitor* system_monitor = ui::SystemMonitor::Get();
system_monitor->AddObserver(this);
UseHiResClock(!system_monitor->BatteryPower());
@@ -23,7 +23,8 @@
}
void HighResolutionTimerManager::UseHiResClock(bool use) {
- if (use == hi_res_clock_used_)
+ if (use == hi_res_clock_available_)
return;
+ hi_res_clock_available_ = use;
base::Time::EnableHighResolutionTimer(use);
}

Powered by Google App Engine
This is Rietveld 408576698