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

Side by Side Diff: ash/wm/session_state_controller_impl.h

Issue 15974008: Rename SessionStateController -> LockStateController (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « ash/wm/session_state_controller.cc ('k') | ash/wm/session_state_controller_impl.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef ASH_WM_SESSION_STATE_CONTROLLER_IMPL_H_ 5 #ifndef ASH_WM_SESSION_STATE_CONTROLLER_IMPL_H_
6 #define ASH_WM_SESSION_STATE_CONTROLLER_IMPL_H_ 6 #define ASH_WM_SESSION_STATE_CONTROLLER_IMPL_H_
7 7
8 #include "ash/ash_export.h" 8 #include "ash/ash_export.h"
9 #include "ash/shell_observer.h" 9 #include "ash/shell_observer.h"
10 #include "ash/wm/lock_state_controller.h"
10 #include "ash/wm/session_state_animator.h" 11 #include "ash/wm/session_state_animator.h"
11 #include "ash/wm/session_state_controller.h"
12 #include "base/basictypes.h" 12 #include "base/basictypes.h"
13 #include "base/memory/scoped_ptr.h" 13 #include "base/memory/scoped_ptr.h"
14 #include "base/time.h" 14 #include "base/time.h"
15 #include "base/timer.h" 15 #include "base/timer.h"
16 #include "ui/aura/root_window_observer.h" 16 #include "ui/aura/root_window_observer.h"
17 17
18 namespace gfx { 18 namespace gfx {
19 class Rect; 19 class Rect;
20 class Size; 20 class Size;
21 } 21 }
22 22
23 namespace ui { 23 namespace ui {
24 class Layer; 24 class Layer;
25 } 25 }
26 26
27 namespace ash { 27 namespace ash {
28 28
29 namespace test { 29 namespace test {
30 class PowerButtonControllerTest; 30 class PowerButtonControllerTest;
31 } 31 }
32 32
33 // Displays onscreen animations and locks or suspends the system in response to 33 // Displays onscreen animations and locks or suspends the system in response to
34 // the power button being pressed or released. 34 // the power button being pressed or released.
35 class ASH_EXPORT SessionStateControllerImpl : public SessionStateController { 35 class ASH_EXPORT SessionStateControllerImpl :
36 public LockStateController {
36 public: 37 public:
37 38
38 // Helper class used by tests to access internal state. 39 // Helper class used by tests to access internal state.
39 class ASH_EXPORT TestApi { 40 class ASH_EXPORT TestApi {
40 public: 41 public:
41 explicit TestApi(SessionStateControllerImpl* controller); 42 explicit TestApi(SessionStateControllerImpl* controller);
42 43
43 virtual ~TestApi(); 44 virtual ~TestApi();
44 45
45 bool lock_timer_is_running() const { 46 bool lock_timer_is_running() const {
(...skipping 43 matching lines...) Expand 10 before | Expand all | Expand 10 after
89 90
90 // RootWindowObserver override: 91 // RootWindowObserver override:
91 virtual void OnRootWindowHostCloseRequested( 92 virtual void OnRootWindowHostCloseRequested(
92 const aura::RootWindow* root) OVERRIDE; 93 const aura::RootWindow* root) OVERRIDE;
93 94
94 // ShellObserver overrides: 95 // ShellObserver overrides:
95 virtual void OnLoginStateChanged(user::LoginStatus status) OVERRIDE; 96 virtual void OnLoginStateChanged(user::LoginStatus status) OVERRIDE;
96 virtual void OnAppTerminating() OVERRIDE; 97 virtual void OnAppTerminating() OVERRIDE;
97 virtual void OnLockStateChanged(bool locked) OVERRIDE; 98 virtual void OnLockStateChanged(bool locked) OVERRIDE;
98 99
99 // SessionStateController overrides: 100 // SessionLockStateController overrides:
100 virtual void StartLockAnimation(bool shutdown_after_lock) OVERRIDE; 101 virtual void StartLockAnimation(bool shutdown_after_lock) OVERRIDE;
101 102
102 virtual void StartShutdownAnimation() OVERRIDE; 103 virtual void StartShutdownAnimation() OVERRIDE;
103 virtual void StartLockAnimationAndLockImmediately() OVERRIDE; 104 virtual void StartLockAnimationAndLockImmediately() OVERRIDE;
104 105
105 virtual bool LockRequested() OVERRIDE; 106 virtual bool LockRequested() OVERRIDE;
106 virtual bool ShutdownRequested() OVERRIDE; 107 virtual bool ShutdownRequested() OVERRIDE;
107 108
108 virtual bool CanCancelLockAnimation() OVERRIDE; 109 virtual bool CanCancelLockAnimation() OVERRIDE;
109 virtual void CancelLockAnimation() OVERRIDE; 110 virtual void CancelLockAnimation() OVERRIDE;
(...skipping 75 matching lines...) Expand 10 before | Expand all | Expand 10 after
185 // request shutdown. Gives the animation time to complete before Chrome, X, 186 // request shutdown. Gives the animation time to complete before Chrome, X,
186 // etc. are shut down. 187 // etc. are shut down.
187 base::OneShotTimer<SessionStateControllerImpl> real_shutdown_timer_; 188 base::OneShotTimer<SessionStateControllerImpl> real_shutdown_timer_;
188 189
189 DISALLOW_COPY_AND_ASSIGN(SessionStateControllerImpl); 190 DISALLOW_COPY_AND_ASSIGN(SessionStateControllerImpl);
190 }; 191 };
191 192
192 } // namespace ash 193 } // namespace ash
193 194
194 #endif // ASH_WM_SESSION_STATE_CONTROLLER_IMPL_H_ 195 #endif // ASH_WM_SESSION_STATE_CONTROLLER_IMPL_H_
OLDNEW
« no previous file with comments | « ash/wm/session_state_controller.cc ('k') | ash/wm/session_state_controller_impl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698