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

Unified Diff: powerd.cc

Issue 6854002: Merge monitor_reconfigure into powerd. (Closed) Base URL: ssh://gitrw.chromium.org:9222/power_manager.git@master
Patch Set: Address first round of reviews, fixing the tests still a TODO. 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: powerd.cc
diff --git a/powerd.cc b/powerd.cc
index 6136090c716041c2bb448898cd491938a3b87eb9..ebedcf2757571f5e83acaa0d5b6145882fcd7a86 100644
--- a/powerd.cc
+++ b/powerd.cc
@@ -50,11 +50,13 @@ Daemon::Daemon(BacklightController* backlight_controller,
PowerPrefs* prefs,
MetricsLibraryInterface* metrics_lib,
VideoDetectorInterface* video_detector,
+ MonitorReconfigureMain* monitor_reconfigure,
const FilePath& run_dir)
: backlight_controller_(backlight_controller),
prefs_(prefs),
metrics_lib_(metrics_lib),
video_detector_(video_detector),
+ monitor_reconfigure_(monitor_reconfigure),
low_battery_suspend_percent_(0),
clean_shutdown_initiated_(false),
low_battery_(false),
@@ -703,7 +705,8 @@ void Daemon::SendBrightnessChangedSignal(bool user_initiated) {
void Daemon::HandleResume() {
file_tagger_.HandleResumeEvent();
- backlight_controller_->SetPowerState(BACKLIGHT_ACTIVE_ON);
+ // Monitor reconfigure will set the backlight if needed.
+ monitor_reconfigure_->Run();
}
} // namespace power_manager

Powered by Google App Engine
This is Rietveld 408576698