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

Side by Side Diff: chrome/browser/ui/ash/session_controller_client.h

Issue 2830933002: cros: Use SessionController for lock starting code (Closed)
Patch Set: update comment Created 3 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 unified diff | Download patch
OLDNEW
1 // Copyright 2016 The Chromium Authors. All rights reserved. 1 // Copyright 2016 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 CHROME_BROWSER_UI_ASH_SESSION_CONTROLLER_CLIENT_H_ 5 #ifndef CHROME_BROWSER_UI_ASH_SESSION_CONTROLLER_CLIENT_H_
6 #define CHROME_BROWSER_UI_ASH_SESSION_CONTROLLER_CLIENT_H_ 6 #define CHROME_BROWSER_UI_ASH_SESSION_CONTROLLER_CLIENT_H_
7 7
8 #include "ash/public/interfaces/session_controller.mojom.h" 8 #include "ash/public/interfaces/session_controller.mojom.h"
9 #include "base/callback_forward.h" 9 #include "base/callback_forward.h"
10 #include "base/macros.h" 10 #include "base/macros.h"
(...skipping 19 matching lines...) Expand all
30 public user_manager::UserManager::UserSessionStateObserver, 30 public user_manager::UserManager::UserSessionStateObserver,
31 public user_manager::UserManager::Observer, 31 public user_manager::UserManager::Observer,
32 public session_manager::SessionManagerObserver, 32 public session_manager::SessionManagerObserver,
33 public content::NotificationObserver { 33 public content::NotificationObserver {
34 public: 34 public:
35 SessionControllerClient(); 35 SessionControllerClient();
36 ~SessionControllerClient() override; 36 ~SessionControllerClient() override;
37 37
38 static SessionControllerClient* Get(); 38 static SessionControllerClient* Get();
39 39
40 // Calls ash SessionController to run lock animation to start lock.
41 // |animation_finished_callback| will be invoked when the post lock animation
42 // finishes and the system is fully locked.
43 void RunLockAnimation(base::Closure animation_finished_callback);
44
40 // Calls ash SessionController to run unlock animation. 45 // Calls ash SessionController to run unlock animation.
41 // |animation_finished_callback| will be invoked when the animation finishes. 46 // |animation_finished_callback| will be invoked when the animation finishes.
42 void RunUnlockAnimation(base::Closure animation_finished_callback); 47 void RunUnlockAnimation(base::Closure animation_finished_callback);
43 48
44 // ash::mojom::SessionControllerClient: 49 // ash::mojom::SessionControllerClient:
45 void RequestLockScreen() override; 50 void RequestLockScreen() override;
46 void SwitchActiveUser(const AccountId& account_id) override; 51 void SwitchActiveUser(const AccountId& account_id) override;
47 void CycleActiveUser(ash::CycleUserDirection direction) override; 52 void CycleActiveUser(ash::CycleUserDirection direction) override;
48 53
49 // user_manager::UserManager::UserSessionStateObserver: 54 // user_manager::UserManager::UserSessionStateObserver:
(...skipping 48 matching lines...) Expand 10 before | Expand all | Expand 10 after
98 103
99 // For observing NOTIFICATION_APP_TERMINATING. 104 // For observing NOTIFICATION_APP_TERMINATING.
100 content::NotificationRegistrar registrar_; 105 content::NotificationRegistrar registrar_;
101 106
102 ash::mojom::SessionInfoPtr last_sent_session_info_; 107 ash::mojom::SessionInfoPtr last_sent_session_info_;
103 108
104 DISALLOW_COPY_AND_ASSIGN(SessionControllerClient); 109 DISALLOW_COPY_AND_ASSIGN(SessionControllerClient);
105 }; 110 };
106 111
107 #endif // CHROME_BROWSER_UI_ASH_SESSION_CONTROLLER_CLIENT_H_ 112 #endif // CHROME_BROWSER_UI_ASH_SESSION_CONTROLLER_CLIENT_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698