Home
last modified time | relevance | path

Searched refs:hasUserRestriction (Results 1 – 25 of 57) sorted by relevance

123

/frameworks/base/services/core/java/com/android/server/policy/
DRestartAction.java39 if (!um.hasUserRestriction(UserManager.DISALLOW_SAFE_BOOT)) { in onLongPress()
DPowerAction.java39 if (!um.hasUserRestriction(UserManager.DISALLOW_SAFE_BOOT)) { in onLongPress()
/frameworks/base/packages/SettingsLib/src/com/android/settingslib/development/
DDevelopmentSettingsEnabler.java47 final boolean hasRestriction = um.hasUserRestriction( in isDevelopmentSettingsEnabled()
/frameworks/base/packages/SystemUI/src/com/android/systemui/statusbar/phone/
DMultiUserSwitch.java107 || mUserManager.hasUserRestriction(UserManager.DISALLOW_USER_SWITCH) in isMultiUserEnabled()
117 || (guestEnabled && !mUserManager.hasUserRestriction(UserManager.DISALLOW_ADD_USER)) in isMultiUserEnabled()
/frameworks/base/services/tests/servicestests/src/com/android/server/pm/
DUserManagerTest.java213 assertTrue(mUserManager.hasUserRestriction(UserManager.DISALLOW_SMS, in testSetUserAdmin()
215 assertTrue(mUserManager.hasUserRestriction(UserManager.DISALLOW_OUTGOING_CALLS, in testSetUserAdmin()
226 assertFalse(mUserManager.hasUserRestriction(UserManager.DISALLOW_SMS, in testSetUserAdmin()
228 assertFalse(mUserManager.hasUserRestriction(UserManager.DISALLOW_OUTGOING_CALLS, in testSetUserAdmin()
528 assertTrue(mUserManager.hasUserRestriction(UserManager.DISALLOW_FUN, in testSetDefaultGuestRestrictions()
/frameworks/base/services/core/java/com/android/server/oemlock/
DPersistentDataBlockLock.java67 .hasUserRestriction(UserManager.DISALLOW_OEM_UNLOCK, UserHandle.SYSTEM); in isOemUnlockAllowedByCarrier()
DOemLockService.java244 .hasUserRestriction(UserManager.DISALLOW_FACTORY_RESET, UserHandle.SYSTEM); in isOemUnlockAllowedByAdmin()
/frameworks/base/core/java/android/os/
DUserManager.java1300 boolean isUserSwitchDisallowed = hasUserRestriction(DISALLOW_USER_SWITCH); in canSwitchUsers()
1332 if (hasUserRestriction(DISALLOW_USER_SWITCH)) { in getUserSwitchability()
1944 public boolean hasUserRestriction(String restrictionKey) { in hasUserRestriction() method in UserManager
1945 return hasUserRestriction(restrictionKey, Process.myUserHandle()); in hasUserRestriction()
1956 public boolean hasUserRestriction(String restrictionKey, UserHandle userHandle) { in hasUserRestriction() method in UserManager
1958 return mService.hasUserRestriction(restrictionKey, in hasUserRestriction()
2954 if (hasUserRestriction(DISALLOW_USER_SWITCH)) { in isUserSwitcherEnabled()
DIUserManager.aidl75 boolean hasUserRestriction(in String restrictionKey, int userHandle); in hasUserRestriction() method
/frameworks/opt/net/wifi/tests/wifitests/src/com/android/server/wifi/p2p/
DWifiP2pServiceImplTest.java1738 when(mUserManager.hasUserRestriction(eq(UserManager.DISALLOW_NETWORK_RESET))) in testPersistentGroupMetricWhenSendFactoryReset()
1740 when(mUserManager.hasUserRestriction(eq(UserManager.DISALLOW_CONFIG_WIFI))) in testPersistentGroupMetricWhenSendFactoryReset()
1906 when(mUserManager.hasUserRestriction(eq(UserManager.DISALLOW_NETWORK_RESET))) in testStartLocalConnectionWhenCreateGroup()
1908 when(mUserManager.hasUserRestriction(eq(UserManager.DISALLOW_CONFIG_WIFI))) in testStartLocalConnectionWhenCreateGroup()
3106 when(mUserManager.hasUserRestriction(UserManager.DISALLOW_NETWORK_RESET)).thenReturn(false); in testFactoryResetSuccessWhenP2pEnabled()
3107 when(mUserManager.hasUserRestriction(UserManager.DISALLOW_CONFIG_WIFI)).thenReturn(false); in testFactoryResetSuccessWhenP2pEnabled()
3114 verify(mUserManager).hasUserRestriction(eq(UserManager.DISALLOW_NETWORK_RESET)); in testFactoryResetSuccessWhenP2pEnabled()
3115 verify(mUserManager).hasUserRestriction(eq(UserManager.DISALLOW_CONFIG_WIFI)); in testFactoryResetSuccessWhenP2pEnabled()
3133 when(mUserManager.hasUserRestriction(UserManager.DISALLOW_NETWORK_RESET)).thenReturn(false); in testFactoryResetSuccessWhenP2pFromDisabledToEnabled()
3134 when(mUserManager.hasUserRestriction(UserManager.DISALLOW_CONFIG_WIFI)).thenReturn(false); in testFactoryResetSuccessWhenP2pFromDisabledToEnabled()
[all …]
/frameworks/base/services/core/java/com/android/server/pm/
DUserRestrictionsUtils.java674 if (mUserManager.hasUserRestriction( in isSettingRestrictedForUser()
685 if (mUserManager.hasUserRestriction( in isSettingRestrictedForUser()
821 return mUserManager.hasUserRestriction(restriction, UserHandle.of(userId)); in isSettingRestrictedForUser()
895 return (newValue || UserManager.get(context).hasUserRestriction(userRestriction, in getNewUserRestrictionSetting()
/frameworks/base/core/java/com/android/internal/app/
DConfirmUserCreationActivity.java99 boolean cantCreateUser = mUserManager.hasUserRestriction(UserManager.DISALLOW_ADD_USER) in checkUserCreationRequirements()
/frameworks/base/packages/SystemUI/src/com/android/systemui/statusbar/policy/
DBluetoothControllerImpl.java92 return !mUserManager.hasUserRestriction(UserManager.DISALLOW_CONFIG_BLUETOOTH, in canConfigBluetooth()
94 && !mUserManager.hasUserRestriction(UserManager.DISALLOW_BLUETOOTH, in canConfigBluetooth()
DAccessPointControllerImpl.java68 return !mUserManager.hasUserRestriction(UserManager.DISALLOW_CONFIG_WIFI, in canConfigWifi()
DLocationControllerImpl.java145 return um.hasUserRestriction(UserManager.DISALLOW_SHARE_LOCATION, in isUserLocationRestricted()
DZenModeControllerImpl.java113 return mUserManager.hasUserRestriction(UserManager.DISALLOW_ADJUST_VOLUME, in isVolumeRestricted()
DSecurityControllerImpl.java243 || mUserManager.hasUserRestriction(UserManager.DISALLOW_CONFIG_VPN, currentUser); in isVpnRestricted()
/frameworks/base/packages/VpnDialogs/src/com/android/vpndialogs/
DConfirmDialog.java62 if (UserManager.get(this).hasUserRestriction(UserManager.DISALLOW_CONFIG_VPN)) { in onCreate()
/frameworks/base/packages/SettingsProvider/test/src/com/android/providers/settings/
DInstallNonMarketAppsDeprecationTest.java90 mHasUserRestriction = mUm.hasUserRestriction(UserManager.DISALLOW_INSTALL_UNKNOWN_SOURCES); in setUp()
/frameworks/base/media/java/android/mtp/
DMtpDevice.java89 if (!userManager.hasUserRestriction(UserManager.DISALLOW_USB_FILE_TRANSFER)) { in open()
/frameworks/base/services/core/java/com/android/server/am/
DUserController.java856 && !hasUserRestriction(UserManager.DISALLOW_RUN_IN_BACKGROUND, userId)) {
1409 boolean disallowRunInBg = hasUserRestriction(UserManager.DISALLOW_RUN_IN_BACKGROUND,
1656 if (hasUserRestriction(UserManager.DISALLOW_DEBUGGING_FEATURES, targetUserId)) {
1935 if (userHandle < 0 || hasUserRestriction(restriction, userHandle)) {
1942 boolean hasUserRestriction(String restriction, int userId) {
1943 return mInjector.getUserManager().hasUserRestriction(restriction, userId);
/frameworks/opt/net/wifi/tests/wifitests/src/com/android/server/wifi/
DOpenNetworkNotifierTest.java458 when(mUserManager.hasUserRestriction(UserManager.DISALLOW_CONFIG_WIFI, UserHandle.CURRENT)) in userHasDisallowConfigWifiRestriction_notificationNotDisplayed()
477 when(mUserManager.hasUserRestriction(UserManager.DISALLOW_CONFIG_WIFI, UserHandle.CURRENT)) in userHasDisallowConfigWifiRestriction_showingNotificationIsCleared()
DCarrierNetworkNotifierTest.java462 when(mUserManager.hasUserRestriction(UserManager.DISALLOW_CONFIG_WIFI, UserHandle.CURRENT)) in userHasDisallowConfigWifiRestriction_notificationNotDisplayed()
481 when(mUserManager.hasUserRestriction(UserManager.DISALLOW_CONFIG_WIFI, UserHandle.CURRENT)) in userHasDisallowConfigWifiRestriction_showingNotificationIsCleared()
/frameworks/opt/net/wifi/service/java/com/android/server/wifi/
DAvailableNetworkNotifier.java268 .hasUserRestriction(UserManager.DISALLOW_CONFIG_WIFI, UserHandle.CURRENT); in isControllerEnabled()
/frameworks/base/core/java/android/provider/
DCallLog.java915 if (userManager.hasUserRestriction(UserManager.DISALLOW_OUTGOING_CALLS, in shouldHaveSharedCallLogEntries()

123