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

Unified Diff: chrome/browser/ui/webui/settings/md_settings_ui.cc

Issue 2853113004: chromeos: Add settings to control power management prefs. (Closed)
Patch Set: switch back from aria-labelledby to aria-label Created 3 years, 6 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/ui/webui/settings/md_settings_ui.cc
diff --git a/chrome/browser/ui/webui/settings/md_settings_ui.cc b/chrome/browser/ui/webui/settings/md_settings_ui.cc
index 83f48d8e4889b165b41d26c9afefa7a4e8a8cea8..3b7190ca317ba52a82c4e1e9e1fdc14ba331cdb4 100644
--- a/chrome/browser/ui/webui/settings/md_settings_ui.cc
+++ b/chrome/browser/ui/webui/settings/md_settings_ui.cc
@@ -210,15 +210,11 @@ MdSettingsUI::MdSettingsUI(content::WebUI* web_ui, const GURL& url)
arc::IsPlayStoreAvailable());
// TODO(mash): Support Chrome power settings in Mash. crbug.com/644348
- bool enable_power_settings =
- !ash_util::IsRunningInMash() &&
- (switches::PowerOverlayEnabled() ||
- (ash::PowerStatus::Get()->IsBatteryPresent() &&
- ash::PowerStatus::Get()->SupportsDualRoleDevices()));
+ bool enable_power_settings = !ash_util::IsRunningInMash();
html_source->AddBoolean("enablePowerSettings", enable_power_settings);
if (enable_power_settings) {
- AddSettingsPageUIHandler(
- base::MakeUnique<chromeos::settings::PowerHandler>());
+ AddSettingsPageUIHandler(base::MakeUnique<chromeos::settings::PowerHandler>(
+ profile->GetPrefs()));
}
#endif

Powered by Google App Engine
This is Rietveld 408576698