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

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

Issue 2937553002: Create Mojo Struct for user information used in login/lock screen. (Closed)
Patch Set: rebase Created 3 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
« no previous file with comments | « ash/public/interfaces/BUILD.gn ('k') | ash/public/interfaces/login_user_info.mojom » ('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 2017 The Chromium Authors. All rights reserved. 1 // Copyright 2017 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 "ash/public/interfaces/login_user_info.mojom";
8 import "components/proximity_auth/public/interfaces/auth_type.mojom";
7 import "components/signin/public/interfaces/account_id.mojom"; 9 import "components/signin/public/interfaces/account_id.mojom";
8 import "mojo/common/string16.mojom"; 10 import "mojo/common/string16.mojom";
9 import "mojo/common/values.mojom";
10
11 // Supported authentication types. Keep in sync with enum in
12 // screenlock_bridge.h
13 enum AuthType {
14 OFFLINE_PASSWORD,
15 ONLINE_SIGN_IN,
16 NUMERIC_PIN,
17 USER_CLICK,
18 EXPAND_THEN_USER_CLICK,
19 FORCE_OFFLINE_PASSWORD,
20 };
21
22 // Information about the custom icon in the user pod.
23 struct UserPodCustomIconOptions {
24 string id;
25 mojo.common.mojom.String16 tooltip;
26 bool autoshow_tooltip;
27 mojo.common.mojom.String16 aria_label;
28 bool hardlock_on_click;
29 bool is_trial_run;
30 };
31 11
32 // Allows clients (e.g. Chrome browser) to control the ash lock screen. 12 // Allows clients (e.g. Chrome browser) to control the ash lock screen.
33 interface LockScreen { 13 interface LockScreen {
34 // Sets the client interface. 14 // Sets the client interface.
35 SetClient(LockScreenClient client); 15 SetClient(LockScreenClient client);
36 16
37 // Displays the lock screen. |did_show| is true iff the lock UI was 17 // Displays the lock screen. |did_show| is true iff the lock UI was
38 // successfully displayed. 18 // successfully displayed.
39 ShowLockScreen() => (bool did_show); 19 ShowLockScreen() => (bool did_show);
40 20
(...skipping 20 matching lines...) Expand all
61 41
62 // Requests to hide the custom icon in the user pod. 42 // Requests to hide the custom icon in the user pod.
63 // |account_id|: The account id of the user in the user pod. 43 // |account_id|: The account id of the user in the user pod.
64 HideUserPodCustomIcon(signin.mojom.AccountId account_id); 44 HideUserPodCustomIcon(signin.mojom.AccountId account_id);
65 45
66 // Requests to set the authentication type. 46 // Requests to set the authentication type.
67 // |account_id|: The account id of the user in the user pod. 47 // |account_id|: The account id of the user in the user pod.
68 // |auth_type|: Authentication type. 48 // |auth_type|: Authentication type.
69 // |initial_value|: A message shown in the password field of the user pod. 49 // |initial_value|: A message shown in the password field of the user pod.
70 SetAuthType(signin.mojom.AccountId account_id, 50 SetAuthType(signin.mojom.AccountId account_id,
71 AuthType auth_type, 51 proximity_auth.mojom.AuthType auth_type,
72 mojo.common.mojom.String16 initial_value); 52 mojo.common.mojom.String16 initial_value);
73 53
74 // Requests to load users in the lock screen. 54 // Requests to load users in the lock screen.
75 // TODO: create a mojo struct for |users|, this contains user information
76 // for login/lock screen, some of which might not be needed for the new
77 // view-based UI. See crbug.com/729687.
78 // |users|: A list of users who can unlock the device. 55 // |users|: A list of users who can unlock the device.
79 // |show_guest|: Whether to show guest session button. 56 // |show_guest|: Whether to show guest session button.
80 LoadUsers(mojo.common.mojom.ListValue users, bool show_guest); 57 LoadUsers(array<LoginUserInfo> users, bool show_guest);
81 58
82 // Notification if pin is enabled or disabled for the given user. 59 // Notification if pin is enabled or disabled for the given user.
83 // |account_id|: The account id of the user in the user pod. 60 // |account_id|: The account id of the user in the user pod.
84 // |is_enabled|: True if pin unlock is enabled. 61 // |is_enabled|: True if pin unlock is enabled.
85 SetPinEnabledForUser(signin.mojom.AccountId account_id, bool is_enabled); 62 SetPinEnabledForUser(signin.mojom.AccountId account_id, bool is_enabled);
86 }; 63 };
87 64
88 // Allows ash lock screen to control a client (e.g. Chrome browser). Requests 65 // Allows ash lock screen to control a client (e.g. Chrome browser). Requests
89 // often involve preferences or talk to cryptohome that is not available to ash. 66 // often involve preferences or talk to cryptohome that is not available to ash.
90 interface LockScreenClient { 67 interface LockScreenClient {
(...skipping 31 matching lines...) Expand 10 before | Expand all | Expand 10 after
122 99
123 // Load wallpaper of user with |account_id|. 100 // Load wallpaper of user with |account_id|.
124 LoadWallpaper(signin.mojom.AccountId account_id); 101 LoadWallpaper(signin.mojom.AccountId account_id);
125 102
126 // Sign out current user. 103 // Sign out current user.
127 SignOutUser(); 104 SignOutUser();
128 105
129 // User with |account_id| has reached maximum incorrect password attempts. 106 // User with |account_id| has reached maximum incorrect password attempts.
130 OnMaxIncorrectPasswordAttempted(signin.mojom.AccountId account_id); 107 OnMaxIncorrectPasswordAttempted(signin.mojom.AccountId account_id);
131 }; 108 };
OLDNEW
« no previous file with comments | « ash/public/interfaces/BUILD.gn ('k') | ash/public/interfaces/login_user_info.mojom » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698