| Index: ash/system/chromeos/power/tablet_power_button_controller.cc
|
| diff --git a/ash/system/chromeos/power/tablet_power_button_controller.cc b/ash/system/chromeos/power/tablet_power_button_controller.cc
|
| index 672e54c199841b6ecf569733fd6ad71c0a2b1baa..5e0b54f6b6f832e1aadad9fde487db4aa2df1d14 100644
|
| --- a/ash/system/chromeos/power/tablet_power_button_controller.cc
|
| +++ b/ash/system/chromeos/power/tablet_power_button_controller.cc
|
| @@ -215,11 +215,7 @@ void TabletPowerButtonController::SetDisplayForcedOff(bool forced_off) {
|
| ->GetPowerManagerClient()
|
| ->SetBacklightsForcedOff(forced_off);
|
| backlights_forced_off_ = forced_off;
|
| -
|
| - ShellDelegate* delegate = WmShell::Get()->delegate();
|
| - delegate->SetTouchscreenEnabledInPrefs(!forced_off,
|
| - true /* use_local_state */);
|
| - delegate->UpdateTouchscreenStatusFromPrefs();
|
| + UpdateTouchscreenStatus();
|
|
|
| // Send an a11y alert.
|
| WmShell::Get()->accessibility_delegate()->TriggerAccessibilityAlert(
|
| @@ -237,6 +233,14 @@ void TabletPowerButtonController::GetInitialBacklightsForcedOff() {
|
| void TabletPowerButtonController::OnGotInitialBacklightsForcedOff(
|
| bool is_forced_off) {
|
| backlights_forced_off_ = is_forced_off;
|
| + UpdateTouchscreenStatus();
|
| +}
|
| +
|
| +void TabletPowerButtonController::UpdateTouchscreenStatus() {
|
| + ShellDelegate* delegate = WmShell::Get()->delegate();
|
| + delegate->SetTouchscreenEnabledInPrefs(!backlights_forced_off_,
|
| + true /* use_local_state */);
|
| + delegate->UpdateTouchscreenStatusFromPrefs();
|
| }
|
|
|
| void TabletPowerButtonController::StartShutdownTimer() {
|
|
|