Show indicator if guest creation is not allowed
When guest creation is not allowed by the admin, show a badge on the
icon. The guest icon will still appear in the list, but if clicked the
user will see a dialog that says: "Blocked by your IT admin", "If you
have questions, contact your IT admin"
Test: With config_guestUserAutoCreated=true, set the device owner during
SUW, then disable user creation in the admin app, then open QS
user switcher from the lock screen.
Bug: 195699593
Change-Id: I2cb404e8c3262b48efafcc73f341b5c45728ab76
This commit is contained in:
@@ -343,8 +343,7 @@ public class UserSwitcherController implements Dumpable {
|
||||
true /* isGuest */, false /* isCurrent */,
|
||||
false /* isAddUser */, false /* isRestricted */,
|
||||
isSwitchToGuestEnabled);
|
||||
// Don't call checkIfAddUserDisallowedByAdminOnly if
|
||||
// config_guestUserAutoCreated=true.
|
||||
checkIfAddUserDisallowedByAdminOnly(guestRecord);
|
||||
records.add(guestRecord);
|
||||
} else if (canCreateGuest) {
|
||||
guestRecord = new UserRecord(null /* info */, null /* picture */,
|
||||
|
||||
Reference in New Issue
Block a user