Index: ash/wm/lock_state_controller.h |
diff --git a/ash/wm/lock_state_controller.h b/ash/wm/lock_state_controller.h |
index 13974a4e06cf68bc9b936f8266316fe4d83e033a..1330939258248625a5ee2ca541432b36ea9fac4e 100644 |
--- a/ash/wm/lock_state_controller.h |
+++ b/ash/wm/lock_state_controller.h |
@@ -40,8 +40,7 @@ class ASH_EXPORT LockStateControllerDelegate { |
virtual ~LockStateControllerDelegate() {} |
virtual void RequestLockScreen() = 0; |
- virtual void RequestRestart() = 0; |
- virtual void RequestShutdown() = 0; |
+ virtual void RequestShutdownOrRestart() = 0; |
Daniel Erat
2015/01/07 16:18:40
sorry for all the conflicting messages you're gett
stevenjb
2015/01/07 19:03:36
Agreed.
cschuet (SLOW)
2015/01/13 10:38:28
Done.
|
private: |
DISALLOW_COPY_AND_ASSIGN(LockStateControllerDelegate); |
@@ -73,10 +72,6 @@ class ASH_EXPORT LockStateControllerDelegate { |
class ASH_EXPORT LockStateController : public aura::WindowTreeHostObserver, |
public ShellObserver { |
public: |
- // ShutdownMode determines whether the device will power off or reboot when |
- // RequestShutdown is invoked. |
- enum ShutdownMode { POWER_OFF, RESTART }; |
- |
// Amount of time that the power button needs to be held before we lock the |
// screen. |
static const int kLockTimeoutMs; |
@@ -137,7 +132,7 @@ class ASH_EXPORT LockStateController : public aura::WindowTreeHostObserver, |
controller_->pre_shutdown_timer_.Stop(); |
} |
void trigger_real_shutdown_timeout() { |
- controller_->OnRealPowerTimeout(POWER_OFF); |
+ controller_->OnRealPowerTimeout(); |
controller_->real_shutdown_timer_.Stop(); |
} |
@@ -192,8 +187,9 @@ class ASH_EXPORT LockStateController : public aura::WindowTreeHostObserver, |
// Called when Chrome gets a request to display the lock screen. |
void OnStartingLock(); |
- // Displays the shutdown animation and requests shutdown when it's done. |
- void RequestShutdown(ShutdownMode mode); |
+ // Displays the shutdown animation and requests a system shutdown or system |
+ // restart depending on the the state of the |RebootOnShutdown| device policy. |
+ void RequestShutdownOrRestart(); |
Daniel Erat
2015/01/07 16:18:40
i think that this would be better as "RequestShutd
cschuet (SLOW)
2015/01/13 10:38:28
Done.
|
// Called when ScreenLocker is ready to close, but not yet destroyed. |
// Can be used to display "hiding" animations on unlock. |
@@ -242,13 +238,10 @@ class ASH_EXPORT LockStateController : public aura::WindowTreeHostObserver, |
// Starts timer for final shutdown animation. |
// If |with_animation_time| is true, it will also include time of "fade to |
// white" shutdown animation. |
- // If |shutdown_mode| is set to RESTART, the device will reboot. |
- void StartRealShutdownTimer(bool with_animation_time, |
- ShutdownMode shutdown_mode); |
+ void StartRealShutdownTimer(bool with_animation_time); |
- // Request that the machine be either restarted or shut down depending on |
- // |shutdown_mode|. |
- void OnRealPowerTimeout(ShutdownMode shutdown_mode); |
+ // Request that the machine is shut down. |
Daniel Erat
2015/01/07 16:18:40
nit: s/is/be/
cschuet (SLOW)
2015/01/13 10:38:28
Done.
|
+ void OnRealPowerTimeout(); |
// Starts shutdown animation that can be cancelled and starts pre-shutdown |
// timer. |