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

Side by Side Diff: ash/public/interfaces/session_controller.mojom

Issue 2830933002: cros: Use SessionController for lock starting code (Closed)
Patch Set: RunLockAnimation -> StartLock and add a bool |locked| to return, fix tests, fix nits 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
« no previous file with comments | « no previous file | ash/session/session_controller.h » ('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 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 module ash.mojom; 5 module ash.mojom;
6 6
7 import "components/signin/public/interfaces/account_id.mojom"; 7 import "components/signin/public/interfaces/account_id.mojom";
8 import "ui/gfx/image/mojo/image.mojom"; 8 import "ui/gfx/image/mojo/image.mojom";
9 9
10 // Matches session_manager::SessionState. 10 // Matches session_manager::SessionState.
(...skipping 125 matching lines...) Expand 10 before | Expand all | Expand 10 after
136 // its meta data (e.g. name, avatar) is changed. There is no method to remove 136 // its meta data (e.g. name, avatar) is changed. There is no method to remove
137 // a user session because ash/chrome does not support that. All users are 137 // a user session because ash/chrome does not support that. All users are
138 // logged out at the same time. 138 // logged out at the same time.
139 UpdateUserSession(UserSession user_session); 139 UpdateUserSession(UserSession user_session);
140 140
141 // Sets the order of user sessions. The order is keyed by the session id. 141 // Sets the order of user sessions. The order is keyed by the session id.
142 // Currently, session manager set a LRU order with the first one being the 142 // Currently, session manager set a LRU order with the first one being the
143 // active user session. 143 // active user session.
144 SetUserSessionOrder(array<uint32> user_session_ids); 144 SetUserSessionOrder(array<uint32> user_session_ids);
145 145
146 // Runs the pre-lock animation to start locking ash. When the call returns,
147 // |locked| == true means that the post-lock animation finishes and ash is
James Cook 2017/04/20 19:25:21 super nit: finishes -> finished
xiyuan 2017/04/20 21:00:26 Done.
148 // fully locked. Otherwise |locked| is false, which means something is wrong
149 // for the lock and ash is not locked. When the call returns with a true
150 // |locked|, screen locker runs the post lock jobs such as a11y announcement
151 // etc. Invoked by the screen locker during initialization.
152 StartLock() => (bool locked);
153
146 // Runs the pre-unlock animation. Invoked by the screen locker before 154 // Runs the pre-unlock animation. Invoked by the screen locker before
147 // dismissing. When the mojo call returns, screen locker takes that as a 155 // dismissing. When the mojo call returns, screen locker takes that as a
148 // signal of finished unlock animation and dismisses itself. 156 // signal of finished unlock animation and dismisses itself.
149 RunUnlockAnimation() => (); 157 RunUnlockAnimation() => ();
150 158
151 // Notifies that chrome is terminating. 159 // Notifies that chrome is terminating.
152 NotifyChromeTerminating(); 160 NotifyChromeTerminating();
153 }; 161 };
154 162
155 // Interface for ash to request session service from its client (e.g. Chrome). 163 // Interface for ash to request session service from its client (e.g. Chrome).
156 interface SessionControllerClient { 164 interface SessionControllerClient {
157 // Requests to lock screen. 165 // Requests to lock screen.
158 RequestLockScreen(); 166 RequestLockScreen();
159 167
160 // Switch to the active user with |account_id| (if the user has already signed 168 // Switch to the active user with |account_id| (if the user has already signed
161 // in). 169 // in).
162 SwitchActiveUser(signin.mojom.AccountId account_id); 170 SwitchActiveUser(signin.mojom.AccountId account_id);
163 171
164 // Switch the active user to the next or previous user. 172 // Switch the active user to the next or previous user.
165 CycleActiveUser(CycleUserDirection direction); 173 CycleActiveUser(CycleUserDirection direction);
166 }; 174 };
OLDNEW
« no previous file with comments | « no previous file | ash/session/session_controller.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698