Home
last modified time | relevance | path

Searched refs:mUserCaps (Results 1 – 7 of 7) sorted by relevance

/packages/apps/Settings/src/com/android/settings/users/
DAddUserWhenLockedPreferenceController.java29 private final UserCapabilities mUserCaps; field in AddUserWhenLockedPreferenceController
33 mUserCaps = UserCapabilities.create(context); in AddUserWhenLockedPreferenceController()
39 mUserCaps.updateAddUserCapabilities(mContext); in updateState()
46 mUserCaps.disallowAddUser() ? mUserCaps.getEnforcedAdmin() : null); in updateState()
47 restrictedSwitchPreference.setVisible(mUserCaps.mUserSwitcherEnabled); in updateState()
53 if (!mUserCaps.isAdmin()) { in getAvailabilityStatus()
55 } else if (mUserCaps.disallowAddUser() || mUserCaps.disallowAddUserSetByAdmin()) { in getAvailabilityStatus()
58 return mUserCaps.mUserSwitcherEnabled ? AVAILABLE : CONDITIONALLY_UNAVAILABLE; in getAvailabilityStatus()
DGuestTelephonyPreferenceController.java36 private final UserCapabilities mUserCaps; field in GuestTelephonyPreferenceController
41 mUserCaps = UserCapabilities.create(context); in GuestTelephonyPreferenceController()
46 if (!mUserCaps.isAdmin() || !mUserCaps.mCanAddGuest) { in getAvailabilityStatus()
49 return mUserCaps.mUserSwitcherEnabled ? AVAILABLE : CONDITIONALLY_UNAVAILABLE; in getAvailabilityStatus()
76 mUserCaps.updateAddUserCapabilities(mContext); in updateState()
77 preference.setVisible(isAvailable() && mUserCaps.mUserSwitcherEnabled in updateState()
DMultiUserTopIntroPreferenceController.java33 final UserCapabilities mUserCaps; field in MultiUserTopIntroPreferenceController
37 mUserCaps = UserCapabilities.create(context); in MultiUserTopIntroPreferenceController()
42 return (mUserCaps.mEnabled && !mUserCaps.mUserSwitcherEnabled) in getAvailabilityStatus()
49 mUserCaps.updateAddUserCapabilities(mContext); in updateState()
51 preference.setVisible(!mUserCaps.mIsGuest); in updateState()
DRemoveGuestOnExitPreferenceController.java50 private final UserCapabilities mUserCaps; field in RemoveGuestOnExitPreferenceController
58 mUserCaps = UserCapabilities.create(context); in RemoveGuestOnExitPreferenceController()
66 mUserCaps.updateAddUserCapabilities(mContext); in updateState()
74 mUserCaps.disallowAddUser() ? mUserCaps.getEnforcedAdmin() : null); in updateState()
75 restrictedSwitchPreference.setVisible(mUserCaps.mUserSwitcherEnabled); in updateState()
87 || !mUserCaps.isAdmin() in getAvailabilityStatus()
88 || mUserCaps.disallowAddUser() in getAvailabilityStatus()
89 || mUserCaps.disallowAddUserSetByAdmin()) { in getAvailabilityStatus()
92 return mUserCaps.mUserSwitcherEnabled ? AVAILABLE : CONDITIONALLY_UNAVAILABLE; in getAvailabilityStatus()
DUserSettings.java213 private UserCapabilities mUserCaps; field in UserSettings
290 if (!mUserCaps.mIsGuest) { in onActivityCreated()
360 mUserCaps = UserCapabilities.create(activity); in onCreate()
362 if (!mUserCaps.mEnabled) { in onCreate()
387 if (!mUserCaps.mCanAddRestrictedProfile) { in onCreate()
409 if (!mUserCaps.mEnabled) { in onResume()
437 if (mUserCaps == null || !mUserCaps.mEnabled) { in onDestroy()
498 mUserCaps.updateAddUserCapabilities(getActivity()); in updateUI()
1201 if (mUserCaps.mUserSwitcherEnabled) {
1224 isCurrentUserAdmin() || (canSwitchUserNow() && !mUserCaps.mDisallowSwitchUser);
[all …]
DUserDetailsSettings.java85 private UserCapabilities mUserCaps; field in UserDetailsSettings
117 mUserCaps = UserCapabilities.create(context); in onCreate()
157 } else if (mUserCaps.mIsGuest && mUserCaps.mIsEphemeral) { in onPreferenceClick()
357 if (mUserCaps.mDisallowSwitchUser) {
458 if (mUserCaps.mIsGuest && mUserCaps.mIsEphemeral) {
/packages/apps/Settings/tests/unit/src/com/android/settings/users/
DMultiUserTopIntroPreferenceControllerTest.java49 mController.mUserCaps.mEnabled = true; in getAvailabilityStatus_multiUserOff_shouldReturnEnabled()
50 mController.mUserCaps.mUserSwitcherEnabled = false; in getAvailabilityStatus_multiUserOff_shouldReturnEnabled()
58 mController.mUserCaps.mEnabled = true; in getAvailabilityStatus_multiUserOn_shouldReturnDisabled()
59 mController.mUserCaps.mUserSwitcherEnabled = true; in getAvailabilityStatus_multiUserOn_shouldReturnDisabled()