/frameworks/base/tests/permission/src/com/android/framework/permission/tests/ |
D | PmPermissionsTests.java | 28 private PackageManager mPm; field in PmPermissionsTests 34 mPm = getContext().getPackageManager(); in setUp() 44 mPm.getPackageSizeInfo(mPkgName, null); in testGetPackageSize() 59 mPm.deleteApplicationCacheFiles(mPkgName, null); in testDeleteApplicationCacheFiles() 81 mPm.freeStorage(100000, null); in testFreeStorage1() 96 mPm.freeStorageAndNotify(100000, null); in testFreeStorage2() 111 mPm.clearApplicationUserData(mPkgName, null); in testClearApplicationUserData() 126 mPm.deletePackage(mPkgName, null, 0); in testDeletePackage()
|
/frameworks/base/core/java/android/content/pm/ |
D | LauncherActivityInfo.java | 36 private final PackageManager mPm; field in LauncherActivityInfo 47 mPm = context.getPackageManager(); in LauncherActivityInfo() 83 return getActivityInfo().loadLabel(mPm); in getLabel() 108 final Resources resources = mPm.getResourcesForApplication( in getIcon() 116 icon = getActivityInfo().loadIcon(mPm); in getIcon() 157 return mPm.getPackageInfo(getActivityInfo().packageName, in getFirstInstallTime() 183 return mPm.getUserBadgedIcon(originalIcon, mUser); in getBadgedIcon()
|
/frameworks/base/core/tests/coretests/src/android/os/ |
D | PowerManagerTest.java | 44 private PowerManager mPm; field in PowerManagerTest 78 mPm = (PowerManager) mContext.getSystemService(Context.POWER_SERVICE); in setUp() 97 assertNotNull(mPm); in testPreconditions() 107 PowerManager.WakeLock wl = mPm.newWakeLock(PowerManager.FULL_WAKE_LOCK, "FULL_WAKE_LOCK"); in testNewWakeLock() 110 wl = mPm.newWakeLock(PowerManager.SCREEN_BRIGHT_WAKE_LOCK, "SCREEN_BRIGHT_WAKE_LOCK"); in testNewWakeLock() 113 wl = mPm.newWakeLock(PowerManager.SCREEN_DIM_WAKE_LOCK, "SCREEN_DIM_WAKE_LOCK"); in testNewWakeLock() 116 wl = mPm.newWakeLock(PowerManager.PARTIAL_WAKE_LOCK, "PARTIAL_WAKE_LOCK"); in testNewWakeLock() 134 PowerManager.WakeLock wl = mPm.newWakeLock(badFlags, "foo"); in testBadNewWakeLock() 149 PowerManager.WakeLock wakeLock = mPm.newWakeLock( in testWakeLockWithWorkChains() 203 assertEquals(status, mPm.getCurrentThermalStatus()); in testGetThermalStatus() [all …]
|
D | PowerManagerVrTest.java | 35 private PowerManager mPm; field in PowerManagerVrTest 50 mPm = (PowerManager) getInstrumentation().getTargetContext().getSystemService( in setUp() 75 assertNotNull(mPm); in testPreconditions() 129 PowerManager.WakeLock wl = mPm.newWakeLock( in wakeUpDevice()
|
/frameworks/base/packages/SettingsLib/src/com/android/settingslib/applications/ |
D | DefaultAppInfo.java | 41 protected final PackageManager mPm; field in DefaultAppInfo 56 mPm = pm; in DefaultAppInfo() 67 mPm = pm; in DefaultAppInfo() 80 return componentInfo.loadLabel(mPm); in loadLabel() 82 final ApplicationInfo appInfo = mPm.getApplicationInfoAsUser( in loadLabel() 84 return appInfo.loadLabel(mPm); in loadLabel() 90 return packageItemInfo.loadLabel(mPm); in loadLabel() 103 final ApplicationInfo appInfo = mPm.getApplicationInfoAsUser( in loadIcon() 116 final ApplicationInfo appInfo = mPm.getApplicationInfoAsUser( in loadIcon()
|
/frameworks/base/packages/SystemUI/src/com/android/systemui/plugins/ |
D | PluginEnablerImpl.java | 28 private PackageManager mPm; field in PluginEnablerImpl 38 mPm = pm; in PluginEnablerImpl() 51 mPm.setComponentEnabledSetting(component, desiredState, PackageManager.DONT_KILL_APP); in setDisabled() 61 return mPm.getComponentEnabledSetting(component) in isEnabled()
|
/frameworks/base/services/tests/uiservicestests/src/com/android/server/notification/ |
D | RoleObserverTest.java | 99 private IPackageManager mPm; field in RoleObserverTest 146 mRoleObserver = mService.new RoleObserver(mContext, mRoleManager, mPm, mMainLooper); in setUp() 189 when(mPm.getPackageUid("dialer", MATCH_ALL, 0)).thenReturn(30); in testInit_forNonBlockableDefaultApps() 193 when(mPm.getPackageUid("emergency", MATCH_ALL, 0)).thenReturn(40); in testInit_forNonBlockableDefaultApps() 229 when(mPm.getPackageUid("com.browser", MATCH_ALL, 0)).thenReturn(30); in testInit_forTrampolines() 261 when(mPm.getPackageUid("phone", MATCH_ALL, 0)).thenReturn(30); in testSwapDefault_forNonBlockableDefaultApps() 277 when(mPm.getPackageUid("com.browser", MATCH_ALL, 0)).thenReturn(30); in testSwapDefault_forTrampolines() 278 when(mPm.getPackageUid("com.browser2", MATCH_ALL, 0)).thenReturn(31); in testSwapDefault_forTrampolines() 329 when(mPm.getPackageUid("emerPhone", MATCH_ALL, 0)).thenReturn(30); in testSwapDefault_multipleOverlappingApps_forNonBlockableDefaultApps() 363 when(mPm.getPackageUid("phone", MATCH_ALL, 10)).thenReturn(30); in testSwapDefault_newUser_forNonBlockableDefaultApps() [all …]
|
D | RankingHelperTest.java | 83 @Mock PackageManager mPm; field in RankingHelperTest 113 when(mPm.getApplicationInfoAsUser(eq(PKG), anyInt(), anyInt())).thenReturn(legacy); in setUp() 114 when(mPm.getApplicationInfoAsUser(eq(UPDATED_PKG), anyInt(), anyInt())).thenReturn(upgrade); in setUp() 115 when(mPm.getApplicationInfoAsUser(eq(SYSTEM_PKG), anyInt(), anyInt())).thenReturn(upgrade); in setUp() 116 when(mPm.getPackageUidAsUser(eq(PKG), anyInt())).thenReturn(UID); in setUp() 117 when(mPm.getPackageUidAsUser(eq(UPDATED_PKG), anyInt())).thenReturn(UID2); in setUp() 118 when(mPm.getPackageUidAsUser(eq(SYSTEM_PKG), anyInt())).thenReturn(SYSTEM_UID); in setUp() 121 when(mPm.getPackageInfoAsUser(eq(SYSTEM_PKG), anyInt(), anyInt())).thenReturn(info); in setUp() 122 when(mPm.getPackageInfoAsUser(eq(PKG), anyInt(), anyInt())) in setUp() 128 when(mContext.getPackageManager()).thenReturn(mPm); in setUp()
|
/frameworks/libs/net/common/tests/unit/src/com/android/net/module/util/ |
D | DeviceConfigUtilsTest.java | 74 @Mock private PackageManager mPm; field in DeviceConfigUtilsTest 87 doReturn(mPm).when(mContext).getPackageManager(); in setUp() 89 doReturn(mMi).when(mPm).getModuleInfo(eq(TEST_APEX_NAME), anyInt()); in setUp() 91 doReturn(pi).when(mPm).getPackageInfo(anyString(), anyInt()); in setUp() 221 doThrow(NameNotFoundException.class).when(mPm).getPackageInfo(anyString(), anyInt()); in testFeatureIsEnabledWithException() 226 doThrow(NameNotFoundException.class).when(mPm).getModuleInfo(anyString(), anyInt()); in testFeatureIsEnabledWithException() 235 doThrow(NameNotFoundException.class).when(mPm).getModuleInfo(anyString(), anyInt()); in testFeatureIsEnabledUsingFixedVersion() 265 verify(mPm, times(1)).getPackageInfo(anyString(), anyInt()); in testFeatureIsEnabledCaching() 273 verify(mPm, times(1)).getModuleInfo(anyString(), anyInt()); in testFeatureIsEnabledCaching()
|
/frameworks/base/tests/NullHomeTest/src/com/android/test/nullhome/ |
D | NullHomeTest.java | 51 private PackageManager mPm; field in NullHomeTest 57 mPm = mContext.getPackageManager(); in before() 64 mPm.getHomeActivities(homeActivities); in checkNullHome()
|
/frameworks/base/tests/StatusBar/src/com/android/statusbartest/ |
D | PowerTest.java | 35 PowerManager mPm; field in PowerTest 46 mPm = (PowerManager)getSystemService("power"); in tests() 47 mProx = mPm.newWakeLock(PowerManager.PROXIMITY_SCREEN_OFF_WAKE_LOCK, "PowerTest-prox"); in tests()
|
/frameworks/base/packages/SystemUI/src/com/android/systemui/ |
D | ForegroundServicesDialog.java | 165 final PackageManager mPm; field in ForegroundServicesDialog.PackageItemAdapter 171 mPm = context.getPackageManager(); in PackageItemAdapter() 182 apps.add(mPm.getApplicationInfo(packages[i], in setPackages() 188 apps.sort(new ApplicationInfo.DisplayNameComparator(mPm)); in setPackages() 206 label.setText(getItem(position).loadLabel(mPm)); in getView()
|
/frameworks/base/packages/SystemUI/src/com/android/systemui/statusbar/notification/row/ |
D | FeedbackInfo.java | 59 private PackageManager mPm; field in FeedbackInfo 82 mPm = pm; in bindGuts() 101 info = mPm.getApplicationInfo(mPkg, in bindHeader() 107 mAppName = String.valueOf(mPm.getApplicationLabel(info)); in bindHeader() 108 pkgicon = mPm.getApplicationIcon(info); in bindHeader() 112 pkgicon = mPm.getDefaultActivityIcon(); in bindHeader()
|
D | PartialConversationInfo.java | 62 private PackageManager mPm; field in PartialConversationInfo 114 mPm = pm; in bindNotification() 185 info = mPm.getApplicationInfo( 192 mAppName = String.valueOf(mPm.getApplicationLabel(info)); 193 mPkgIcon = mPm.getApplicationIcon(info); 196 mPkgIcon = mPm.getDefaultActivityIcon();
|
/frameworks/base/core/java/com/android/internal/app/ |
D | ResolverListAdapter.java | 68 private final PackageManager mPm; field in ResolverListAdapter 101 mPm = context.getPackageManager(); in ResolverListAdapter() 235 resolveInfo.loadLabel(mPm), in rebuildList() 236 resolveInfo.loadLabel(mPm), in rebuildList() 318 mPm, 0); 341 ri.loadLabel(mPm), null, ii, makePresentationGetter(ri))); 819 mPm.getResourcesForApplication(mRi.resolvePackageName), mRi.icon); 836 return mRi.loadLabel(mPm).toString(); 860 mPm.getResourcesForApplication(mActivityInfo.applicationInfo), 875 return (String) mActivityInfo.loadLabel(mPm); [all …]
|
/frameworks/base/services/devicepolicy/java/com/android/server/devicepolicy/ |
D | NetworkLogger.java | 48 private final PackageManagerInternal mPm; field in NetworkLogger 72 mPm.getNameForUid(uid), timestamp); 86 ConnectEvent connectEvent = new ConnectEvent(ipAddr, port, mPm.getNameForUid(uid), 108 mPm = pm; in NetworkLogger()
|
/frameworks/base/packages/SettingsLib/tests/integ/src/com/android/settingslib/users/ |
D | AppRestrictionsHelperTest.java | 58 private @Mock PackageManager mPm; field in AppRestrictionsHelperTest 92 when(mPm.getInstalledApplications(anyInt())).thenReturn(mInstalledAppInfos); in testFetchAndMergeApps() 153 verify(mPm, times(1)).deletePackageAsUser(eq("app3"), in testApplyUserAppsStates() 185 when(mPm.queryIntentActivities(argThat(new IntentMatcher(intent)), anyInt())) in addSystemAppsForIntent() 198 when(mPm.getPackageInfo(eq(pkg), anyInt())).thenReturn(packageInfo); in addSystemAppsWithRequiredAccounts() 218 when(mPm.getPackageInfo(eq(pkgName), anyInt())).thenReturn(packageInfo); in addInstalledApp() 282 return mPm; in getPackageManager()
|
/frameworks/base/core/java/android/util/ |
D | IconDrawableFactory.java | 38 protected final PackageManager mPm; field in IconDrawableFactory 45 mPm = context.getPackageManager(); in IconDrawableFactory() 67 Drawable icon = mPm.loadUnbadgedItemIcon(itemInfo, appInfo); in getBadgedIcon()
|
/frameworks/base/services/core/java/com/android/server/pm/ |
D | PackageInstallerService.java | 147 private final PackageManagerService mPm; field in PackageInstallerService 241 mPm = pm; in PackageInstallerService() 332 mStagingManager.restoreSessions(stagedSessionsToRestore, mPm.isDeviceUpgrading()); in restoreAndApplyStagedSessionIfNeeded() 354 synchronized (mPm.mInstallLock) { in reconcileStagesLocked() 355 mPm.removeCodePathLI(stage); in reconcileStagesLocked() 416 mContext, mPm, mInstallThread.getLooper(), mStagingManager, in readSessionsLocked() 530 mPm.enforceCrossUserPermission( in createSessionInternal() 533 if (mPm.isUserRestricted(userId, UserManager.DISALLOW_INSTALL_APPS)) { in createSessionInternal() 596 && !mPm.isCallerVerifier(callingUid)) { in createSessionInternal() 609 String[] packages = mPm.getPackagesForUid(params.originatingUid); in createSessionInternal() [all …]
|
/frameworks/base/cmds/am/src/com/android/commands/am/ |
D | Am.java | 42 private IPackageManager mPm; field in Am 71 mPm = IPackageManager.Stub.asInterface(ServiceManager.getService("package")); in onRun() 72 if (mPm == null) { in onRun() 152 Instrument instrument = new Instrument(mAm, mPm); in runInstrument()
|
/frameworks/base/packages/SystemUI/src/com/android/systemui/media/systemsounds/ |
D | HomeSoundEffectController.java | 49 private final PackageManager mPm; field in HomeSoundEffectController 72 mPm = packageManager; in HomeSoundEffectController() 100 if (mPm.checkPermission(Manifest.permission.DISABLE_SYSTEM_SOUND_EFFECTS, in hasFlagNoSound()
|
/frameworks/base/core/java/com/android/internal/app/chooser/ |
D | SelectableTargetInfo.java | 60 private final PackageManager mPm; field in SelectableTargetInfo 78 mPm = mContext.getPackageManager(); in SelectableTargetInfo() 112 mPm = other.mPm; in SelectableTargetInfo() 159 info = mPm.getActivityInfo(target.getComponentName(), 0); in getChooserTargetIconDrawable()
|
/frameworks/base/packages/PackageInstaller/src/com/android/packageinstaller/ |
D | PackageInstallerActivity.java | 90 PackageManager mPm; field in PackageInstallerActivity 184 mPm.getApplicationLabel(mPkgInfo.applicationInfo)); in createDialog() 187 mPm.getApplicationLabel(mPkgInfo.applicationInfo)); in createDialog() 232 String[] packagesForUid = mPm.getPackagesForUid(sourceUid); in getPackageNameForUid() 267 String[] oldName = mPm.canonicalToCurrentPackageNames(new String[] { pkgName }); in initiateInstall() 278 mAppInfo = mPm.getApplicationInfo(pkgName, in initiateInstall() 308 mPm = getPackageManager(); in onCreate() 311 mInstaller = mPm.getPackageInstaller(); in onCreate() 556 mPkgInfo = mPm.getPackageInfo(packageUri.getSchemeSpecificPart(), in processPackageUri() 568 CharSequence label = mPm.getApplicationLabel(mPkgInfo.applicationInfo); in processPackageUri() [all …]
|
/frameworks/base/services/core/java/com/android/server/net/watchlist/ |
D | WatchlistLoggingHandler.java | 76 private final PackageManager mPm; field in WatchlistLoggingHandler 97 mPm = mContext.getPackageManager(); in WatchlistLoggingHandler() 156 final String[] packageNames = mPm.getPackagesForUid(uid); in isPackageTestOnly() 161 ai = mPm.getApplicationInfo(packageNames[0], 0); in isPackageTestOnly() 330 final String[] packageNames = mPm.getPackagesForUid(key); in getDigestFromUid() 335 final String apkPath = mPm.getPackageInfoAsUser(packageName, in getDigestFromUid()
|
/frameworks/base/services/core/java/com/android/server/storage/ |
D | AppCollector.java | 100 private final PackageManager mPm; field in AppCollector.BackgroundHandler 108 mPm = pm; in BackgroundHandler() 122 final List<ApplicationInfo> apps = mPm.getInstalledApplicationsAsUser( in handleMessage()
|