Home
last modified time | relevance | path

Searched refs:userManager (Results 1 – 25 of 37) sorted by relevance

12

/frameworks/base/core/java/android/provider/
DCallLog.java738 final UserManager userManager = context.getSystemService(UserManager.class); in addCall() local
739 final int currentUserId = userManager.getUserHandle(); in addCall()
744 context, userManager, UserHandle.SYSTEM, values); in addCall()
758 final List<UserInfo> users = userManager.getUsers(true); in addCall()
771 if (!shouldHaveSharedCallLogEntries(context, userManager, userId)) { in addCall()
779 if (userManager.isUserRunning(userHandle) in addCall()
780 && userManager.isUserUnlocked(userHandle)) { in addCall()
781 final Uri uri = addEntryAndRemoveExpiredEntries(context, userManager, in addCall()
795 result = addEntryAndRemoveExpiredEntries(context, userManager, targetUserHandle, in addCall()
803 UserManager userManager, int userId) { in shouldHaveSharedCallLogEntries() argument
[all …]
/frameworks/base/packages/SystemUI/src/com/android/systemui/
DGuestResumeSessionReceiver.java96 UserManager userManager = (UserManager) context.getSystemService(Context.USER_SERVICE); in wipeGuestSession() local
115 boolean marked = userManager.markGuestForDeletion(currentUser.id); in wipeGuestSession()
120 UserInfo newGuest = userManager.createGuest(context, currentUser.name); in wipeGuestSession()
126 userManager.removeUser(currentUser.id); in wipeGuestSession()
131 userManager.removeUser(currentUser.id); in wipeGuestSession()
/frameworks/base/services/tests/servicestests/src/com/android/server/devicepolicy/
DDpmMockContext.java251 public final UserManager userManager; field in DpmMockContext
287 userManager = mock(UserManager.class); in DpmMockContext()
324 when(userManager.getUserInfo(eq(userId))).thenReturn(uh); in addUser()
327 when(userManager.getUsers()).thenReturn(mUserInfos); in addUser()
328 when(userManager.getUsers(anyBoolean())).thenReturn(mUserInfos); in addUser()
329 when(userManager.isUserRunning(eq(new UserHandle(userId)))).thenReturn(true); in addUser()
330 when(userManager.getUserInfo(anyInt())).thenAnswer( in addUser()
344 when(userManager.getProfiles(anyInt())).thenAnswer( in addUser()
353 when(userManager.getProfileIdsWithDisabled(anyInt())).thenAnswer( in addUser()
413 when(userManager.isUserRunning(MockUtils.checkUserHandle(userId))) in setUserRunning()
[all …]
DDevicePolicyManagerTest.java97 when(mContext.userManager.isUserUnlocked(anyInt())).thenReturn(true); in setUp()
142 }).when(mContext.userManager).setApplicationRestrictions( in setUpUserManager()
154 }).when(mContext.userManager).getApplicationRestrictions( in setUpUserManager()
437 when(mContext.userManager.isUserUnlocked(eq(DpmMockContext.CALLER_USER_HANDLE))) in testRemoveActiveAdmin_userNotRunningOrLocked()
450 when(mContext.userManager.isUserUnlocked(eq(DpmMockContext.CALLER_USER_HANDLE))) in testRemoveActiveAdmin_userNotRunningOrLocked()
811 when(mContext.userManager.getUserRestrictions()).thenReturn(new Bundle()); in testClearDeviceOwner()
819 when(mContext.userManager.isUserUnlocked(anyInt())).thenReturn(false); in testClearDeviceOwner()
828 when(mContext.userManager.isUserUnlocked(anyInt())).thenReturn(true); in testClearDeviceOwner()
915 when(mContext.userManager.isUserUnlocked(anyInt())) in testClearProfileOwner()
925 when(mContext.userManager.isUserUnlocked(anyInt())) in testClearProfileOwner()
[all …]
DDevicePolicyManagerServiceTestable.java58 super(context.userManager, context.userManagerInternal, context.packageManagerInternal); in OwnersTestable()
132 return context.userManager; in getUserManager()
/frameworks/base/packages/SettingsLib/src/com/android/settingslib/drawer/
DUserAdapter.java188 public static UserAdapter createUserSpinnerAdapter(UserManager userManager, in createUserSpinnerAdapter() argument
190 List<UserHandle> userProfiles = userManager.getUserProfiles(); in createUserSpinnerAdapter()
200 return createUserAdapter(userManager, context, userProfiles); in createUserSpinnerAdapter()
203 public static UserAdapter createUserAdapter(UserManager userManager, in createUserAdapter() argument
208 userDetails.add(new UserDetails(userProfiles.get(i), userManager, context)); in createUserAdapter()
DTileUtils.java122 UserManager userManager = UserManager.get(context); in getCategories() local
123 for (UserHandle user : userManager.getUserProfiles()) { in getCategories()
/frameworks/base/core/java/com/android/internal/app/
DIntentForwarderActivity.java177 UserManager userManager = (UserManager) getSystemService(Context.USER_SERVICE); in getManagedProfile() local
178 List<UserInfo> relatedUsers = userManager.getProfiles(UserHandle.myUserId()); in getManagedProfile()
192 UserManager userManager = (UserManager) getSystemService(Context.USER_SERVICE); in getProfileParent() local
193 UserInfo parent = userManager.getProfileParent(UserHandle.myUserId()); in getProfileParent()
DResolverActivity.java466 UserManager userManager = (UserManager) getSystemService(Context.USER_SERVICE); in setProfileSwitchMessageId() local
467 UserInfo originUserInfo = userManager.getUserInfo(contentUserHint); in setProfileSwitchMessageId()
470 boolean targetIsManaged = userManager.isManagedProfile(); in setProfileSwitchMessageId()
606 UserManager userManager = (UserManager) getSystemService(Context.USER_SERVICE); in hasManagedProfile() local
607 if (userManager == null) { in hasManagedProfile()
612 List<UserInfo> profiles = userManager.getProfiles(getUserId()); in hasManagedProfile()
1419 UserManager userManager = in rebuildList() local
1429 if (userManager.isManagedProfile()) { in rebuildList()
/frameworks/base/services/core/java/com/android/server/vr/
DEnabledComponentsObserver.java244 UserManager userManager = (UserManager) mContext.getSystemService(Context.USER_SERVICE); in getCurrentProfileIds() local
245 if (userManager == null) { in getCurrentProfileIds()
248 return userManager.getEnabledProfileIds(ActivityManager.getCurrentUser()); in getCurrentProfileIds()
/frameworks/base/media/java/android/mtp/
DMtpDevice.java71 UserManager userManager = (UserManager) context.getSystemService(Context.USER_SERVICE); in open() local
73 if (!userManager.hasUserRestriction(UserManager.DISALLOW_USB_FILE_TRANSFER)) { in open()
/frameworks/opt/net/wifi/service/java/com/android/server/wifi/
DFrameworkFacade.java164 FrameworkFacade frameworkFacade, Clock clock, UserManager userManager, in makeWifiConfigManager() argument
166 return new WifiConfigManager(context, wifiNative, frameworkFacade, clock, userManager, in makeWifiConfigManager()
DConfigurationMap.java33 ConfigurationMap(UserManager userManager) { in ConfigurationMap() argument
34 mUserManager = userManager; in ConfigurationMap()
/frameworks/base/packages/SettingsProvider/test/src/com/android/providers/settings/
DBaseSettingsProviderTest.java57 UserManager userManager = (UserManager) context.getSystemService(Context.USER_SERVICE); in setContext() local
58 List<UserInfo> users = userManager.getUsers(); in setContext()
/frameworks/opt/telephony/src/java/com/android/internal/telephony/
DSmsBroadcastUndelivered.java129 UserManager userManager = (UserManager) context.getSystemService(Context.USER_SERVICE); in SmsBroadcastUndelivered() local
131 if (userManager.isUserUnlocked()) { in SmsBroadcastUndelivered()
DWapPushOverSms.java137 UserManager userManager = (UserManager) mContext.getSystemService(Context.USER_SERVICE); in WapPushOverSms() local
139 if (userManager.isUserUnlocked()) { in WapPushOverSms()
/frameworks/opt/telephony/tests/telephonytests/src/com/android/internal/telephony/gsm/
DGsmInboundSmsHandlerTest.java127 UserManager userManager = (UserManager)mContext.getSystemService(Context.USER_SERVICE); in setUp() local
128 doReturn(true).when(userManager).isUserUnlocked(); in setUp()
561 UserManager userManager = (UserManager)mContext.getSystemService(Context.USER_SERVICE); in testBroadcastUndeliveredUserLocked() local
562 doReturn(false).when(userManager).isUserUnlocked(); in testBroadcastUndeliveredUserLocked()
577 doReturn(true).when(userManager).isUserUnlocked(); in testBroadcastUndeliveredUserLocked()
/frameworks/base/packages/SettingsLib/src/com/android/settingslib/deviceinfo/
DStorageMeasurement.java357 final UserManager userManager = mContext.getSystemService(UserManager.class); in measureExactStorage() local
360 final List<UserInfo> users = userManager.getUsers(); in measureExactStorage()
361 final List<UserInfo> currentProfiles = userManager.getEnabledProfiles( in measureExactStorage()
/frameworks/base/services/core/java/com/android/server/webkit/
DSystemImpl.java239 UserManager userManager = (UserManager)context.getSystemService(Context.USER_SERVICE); in enablePackageForAllUsers() local
240 for(UserInfo userInfo : userManager.getUsers()) { in enablePackageForAllUsers()
/frameworks/opt/telephony/tests/telephonytests/src/com/android/internal/telephony/cdma/
DCdmaInboundSmsHandlerTest.java109 UserManager userManager = (UserManager) mContextFixture.getTestDouble(). in setUp() local
111 doReturn(true).when(userManager).isUserUnlocked(); in setUp()
/frameworks/base/services/core/java/com/android/server/policy/
DEnableAccessibilityController.java231 final UserManager userManager = (UserManager) context.getSystemService( in enableAccessibility() local
239 final boolean hasMoreThanOneUser = userManager.getUsers().size() > 1; in enableAccessibility()
/frameworks/base/packages/SystemUI/src/com/android/systemui/recents/model/
DRecentsTaskLoadPlan.java90 UserManager userManager = (UserManager) mContext.getSystemService(Context.USER_SERVICE); in updateCurrentQuietProfilesCache() local
91 List<UserInfo> profiles = userManager.getProfiles(currentUserId); in updateCurrentQuietProfilesCache()
/frameworks/base/services/core/java/com/android/server/wm/
DDragState.java237 final IUserManager userManager = in broadcastDragStartedLw() local
240 mCrossProfileCopyAllowed = !userManager.getUserRestrictions(mSourceUserId).getBoolean( in broadcastDragStartedLw()
/frameworks/base/services/core/java/com/android/server/notification/
DManagedServices.java910 UserManager userManager = (UserManager) context.getSystemService(Context.USER_SERVICE); in updateCache() local
911 if (userManager != null) { in updateCache()
913 List<UserInfo> profiles = userManager.getProfiles(currentUserId); in updateCache()
/frameworks/base/services/devicepolicy/java/com/android/server/devicepolicy/
DOwners.java107 public Owners(UserManager userManager, in Owners() argument
110 mUserManager = userManager; in Owners()

12