Home
last modified time | relevance | path

Searched refs:pm (Results 1 – 25 of 1802) sorted by relevance

12345678910>>...73

/packages/services/Car/tests/CarDeveloperOptions/src/com/android/car/developeroptions/
DSettingsInitialize.java19 import static android.content.pm.PackageManager.GET_ACTIVITIES;
20 import static android.content.pm.PackageManager.GET_META_DATA;
21 import static android.content.pm.PackageManager.GET_RESOLVED_FILTER;
22 import static android.content.pm.PackageManager.MATCH_DISABLED_COMPONENTS;
30 import android.content.pm.PackageManager;
31 import android.content.pm.ResolveInfo;
32 import android.content.pm.ShortcutInfo;
33 import android.content.pm.ShortcutManager;
34 import android.content.pm.UserInfo;
62 final PackageManager pm = context.getPackageManager(); in onReceive() local
[all …]
/packages/apps/Settings/src/com/android/settings/
DSettingsInitialize.java19 import static android.content.pm.PackageManager.GET_ACTIVITIES;
20 import static android.content.pm.PackageManager.GET_META_DATA;
21 import static android.content.pm.PackageManager.GET_RESOLVED_FILTER;
22 import static android.content.pm.PackageManager.MATCH_DISABLED_COMPONENTS;
30 import android.content.pm.PackageManager;
31 import android.content.pm.ResolveInfo;
32 import android.content.pm.ShortcutInfo;
33 import android.content.pm.ShortcutManager;
34 import android.content.pm.UserInfo;
62 final PackageManager pm = context.getPackageManager(); in onReceive() local
[all …]
/packages/apps/PermissionController/src/com/android/packageinstaller/permission/ui/handheld/
DAllAppPermissionsFragment.java23 import android.content.pm.ApplicationInfo;
24 import android.content.pm.PackageInfo;
25 import android.content.pm.PackageItemInfo;
26 import android.content.pm.PackageManager;
27 import android.content.pm.PackageManager.NameNotFoundException;
28 import android.content.pm.PermissionGroupInfo;
29 import android.content.pm.PermissionInfo;
129 PackageManager pm = getContext().getPackageManager(); in updateUi() local
137 final CharSequence label = appInfo.loadLabel(pm); in updateUi()
150 perm = pm.getPermissionInfo(info.requestedPermissions[i], 0); in updateUi()
[all …]
/packages/apps/Car/Settings/tests/robotests/src/com/android/car/settings/applications/managedomainurls/
DDomainUrlsUtilsTest.java27 import android.content.pm.IntentFilterVerificationInfo;
28 import android.content.pm.PackageManager;
102 PackageManager pm = mock(PackageManager.class); in getHandledDomains_includeIntentFilterVerificationInfoDomains() local
107 when(pm.getIntentFilterVerifications(TEST_PACKAGE)).thenReturn(Arrays.asList(info)); in getHandledDomains_includeIntentFilterVerificationInfoDomains()
109 assertThat(DomainUrlsUtils.getHandledDomains(pm, TEST_PACKAGE)).hasSize(1); in getHandledDomains_includeIntentFilterVerificationInfoDomains()
110 assertThat(DomainUrlsUtils.getHandledDomains(pm, TEST_PACKAGE)).contains(domain); in getHandledDomains_includeIntentFilterVerificationInfoDomains()
115 PackageManager pm = mock(PackageManager.class); in getHandledDomains_includeBrowsableIntentFiltersWithHttpDataScheme() local
122 when(pm.getAllIntentFilters(TEST_PACKAGE)).thenReturn(Arrays.asList(filter)); in getHandledDomains_includeBrowsableIntentFiltersWithHttpDataScheme()
124 assertThat(DomainUrlsUtils.getHandledDomains(pm, TEST_PACKAGE)).hasSize(1); in getHandledDomains_includeBrowsableIntentFiltersWithHttpDataScheme()
125 assertThat(DomainUrlsUtils.getHandledDomains(pm, TEST_PACKAGE)).contains(domain); in getHandledDomains_includeBrowsableIntentFiltersWithHttpDataScheme()
[all …]
/packages/services/Car/tests/CarDeveloperOptions/src/com/android/car/developeroptions/fuelgauge/
DBatteryEntry.java21 import android.content.pm.ApplicationInfo;
22 import android.content.pm.IPackageManager;
23 import android.content.pm.PackageInfo;
24 import android.content.pm.PackageManager;
25 import android.content.pm.PackageManager.NameNotFoundException;
26 import android.content.pm.UserInfo;
171 PackageManager pm = context.getPackageManager(); in BatteryEntry() local
172 sipper.mPackages = pm.getPackagesForUid(sipper.uidObj.getUid()); in BatteryEntry()
177 defaultPackageName = pm.getPackagesForUid(sipper.uidObj.getUid())[0]; in BatteryEntry()
180 pm.getApplicationInfo(defaultPackageName, 0 /* no flags */); in BatteryEntry()
[all …]
/packages/apps/Settings/src/com/android/settings/fuelgauge/
DBatteryEntry.java21 import android.content.pm.ApplicationInfo;
22 import android.content.pm.IPackageManager;
23 import android.content.pm.PackageInfo;
24 import android.content.pm.PackageManager;
25 import android.content.pm.PackageManager.NameNotFoundException;
26 import android.content.pm.UserInfo;
171 PackageManager pm = context.getPackageManager(); in BatteryEntry() local
172 sipper.mPackages = pm.getPackagesForUid(sipper.uidObj.getUid()); in BatteryEntry()
177 defaultPackageName = pm.getPackagesForUid(sipper.uidObj.getUid())[0]; in BatteryEntry()
180 pm.getApplicationInfo(defaultPackageName, 0 /* no flags */); in BatteryEntry()
[all …]
/packages/apps/PermissionController/src/com/android/packageinstaller/permission/ui/auto/
DAutoAllAppPermissionsFragment.java22 import android.content.pm.ApplicationInfo;
23 import android.content.pm.PackageInfo;
24 import android.content.pm.PackageItemInfo;
25 import android.content.pm.PackageManager;
26 import android.content.pm.PermissionGroupInfo;
27 import android.content.pm.PermissionInfo;
117 PackageManager pm = getContext().getPackageManager(); in updateUi() local
133 perm = pm.getPermissionInfo(info.requestedPermissions[i], /* flags= */ 0); in updateUi()
158 PackageItemInfo group = getGroup(Utils.getGroupOfPermission(perm), pm); in updateUi()
166 PreferenceGroup pref = findOrCreate(group, pm, prefs); in updateUi()
[all …]
/packages/apps/PermissionController/src/com/android/packageinstaller/permission/ui/television/
DAllAppPermissionsFragment.java24 import android.content.pm.ApplicationInfo;
25 import android.content.pm.PackageInfo;
26 import android.content.pm.PackageItemInfo;
27 import android.content.pm.PackageManager;
28 import android.content.pm.PackageManager.NameNotFoundException;
29 import android.content.pm.PermissionGroupInfo;
30 import android.content.pm.PermissionInfo;
132 PackageManager pm = getActivity().getPackageManager(); in updateUi() local
135 final Drawable icon = appInfo.loadIcon(pm); in updateUi()
136 final CharSequence label = appInfo.loadLabel(pm); in updateUi()
[all …]
/packages/apps/Settings/src/com/android/settings/accounts/
DAccountTypePreferenceLoader.java24 import android.content.pm.ActivityInfo;
25 import android.content.pm.ApplicationInfo;
26 import android.content.pm.PackageManager;
27 import android.content.pm.PackageManager.NameNotFoundException;
28 import android.content.pm.ResolveInfo;
119 final PackageManager pm = mFragment.getActivity().getPackageManager(); in updatePreferenceIntents() local
148 ResolveInfo ri = pm.resolveActivityAsUser(intent, in updatePreferenceIntents()
167 if (isSafeIntent(pm, prefIntent, acccountType)) { in updatePreferenceIntents()
190 private boolean isSafeIntent(PackageManager pm, Intent intent, String acccountType) { in isSafeIntent() argument
193 ResolveInfo resolveInfo = pm.resolveActivityAsUser(intent, 0, mUserHandle.getIdentifier()); in isSafeIntent()
[all …]
/packages/services/Car/tests/CarDeveloperOptions/src/com/android/car/developeroptions/accounts/
DAccountTypePreferenceLoader.java24 import android.content.pm.ActivityInfo;
25 import android.content.pm.ApplicationInfo;
26 import android.content.pm.PackageManager;
27 import android.content.pm.PackageManager.NameNotFoundException;
28 import android.content.pm.ResolveInfo;
119 final PackageManager pm = mFragment.getActivity().getPackageManager(); in updatePreferenceIntents() local
148 ResolveInfo ri = pm.resolveActivityAsUser(intent, in updatePreferenceIntents()
167 if (isSafeIntent(pm, prefIntent, acccountType)) { in updatePreferenceIntents()
190 private boolean isSafeIntent(PackageManager pm, Intent intent, String acccountType) { in isSafeIntent() argument
193 ResolveInfo resolveInfo = pm.resolveActivityAsUser(intent, 0, mUserHandle.getIdentifier()); in isSafeIntent()
[all …]
/packages/apps/DocumentsUI/src/com/android/documentsui/
DPreBootReceiver.java27 import android.content.pm.PackageManager;
49 final PackageManager pm = context.getPackageManager(); in onReceive() local
50 if (pm == null) { in onReceive()
62 context.getPackageName()).getValidOverlay(pm); in onReceive()
74 overlayRes = pm.getResourcesForApplication(overlayPkg); in onReceive()
83 setComponentEnabledByConfigResources(pm, packageName, LAUNCHER_TARGET_CLASS, in onReceive()
85 setComponentEnabledByConfigResources(pm, packageName, DOWNLOADS_TARGET_CLASS, in onReceive()
89 private static void setComponentEnabledByConfigResources(PackageManager pm, String packageName, in setComponentEnabledByConfigResources() argument
98 pm.setComponentEnabledSetting(component, value in setComponentEnabledByConfigResources()
/packages/apps/Tag/src/com/android/apps/tag/record/
DRecordUtils.java25 import android.content.pm.ActivityInfo;
26 import android.content.pm.PackageManager;
27 import android.content.pm.ResolveInfo;
66 PackageManager pm = activity.getPackageManager(); in getViewsForIntent() local
68 List<ResolveInfo> activities = pm.queryIntentActivities(intent, flags); in getViewsForIntent()
75 return buildActivityView(activity, activities.get(0), pm, inflater, parent, listener, in getViewsForIntent()
95 container.addView(buildActivityView(activity, resolveInfo, pm, inflater, container, in getViewsForIntent()
105 …rivate static View buildActivityView(Activity activity, ResolveInfo resolveInfo, PackageManager pm, in buildActivityView() argument
118 icon.setImageDrawable(resolveInfo.loadIcon(pm)); in buildActivityView()
121 text.setText(resolveInfo.loadLabel(pm)); in buildActivityView()
/packages/services/Car/tests/carservice_test/src/com/android/car/
DTestAppBlockingPolicyService.java18 import android.car.content.pm.AppBlockingPackageInfo;
19 import android.car.content.pm.CarAppBlockingPolicy;
20 import android.car.content.pm.CarAppBlockingPolicyService;
21 import android.content.pm.PackageManager;
22 import android.content.pm.PackageManager.NameNotFoundException;
23 import android.content.pm.Signature;
50 PackageManager pm = getPackageManager(); in getAppBlockingPolicy() local
54 signatures = pm.getPackageInfo(packageName, in getAppBlockingPolicy()
/packages/apps/Nfc/src/com/android/nfc/
DRegisteredComponentCache.java27 import android.content.pm.ActivityInfo;
28 import android.content.pm.PackageManager;
29 import android.content.pm.ResolveInfo;
30 import android.content.pm.PackageManager.NameNotFoundException;
147 PackageManager pm; in generateComponentsList() local
150 pm = mContext.createPackageContextAsUser("android", 0, in generateComponentsList()
157 List<ResolveInfo> resolveInfos = pm.queryIntentActivitiesAsUser(new Intent(mAction), in generateComponentsList()
161 parseComponentInfo(pm, resolveInfo, components); in generateComponentsList()
178 void parseComponentInfo(PackageManager pm, ResolveInfo info, in parseComponentInfo() argument
184 parser = ai.loadXmlMetaData(pm, mMetaDataName); in parseComponentInfo()
[all …]
/packages/apps/Settings/tests/robotests/src/com/android/settings/network/telephony/
DCarrierPreferenceControllerTest.java34 import android.content.pm.PackageManager;
35 import android.content.pm.ResolveInfo;
127 PackageManager pm = Mockito.mock(PackageManager.class); in handlePreferenceClick_activityFound_openCarrierSettingActivity() local
128 doReturn(pm).when(mContext).getPackageManager(); in handlePreferenceClick_activityFound_openCarrierSettingActivity()
129 doReturn(new ResolveInfo()).when(pm).resolveActivity(any(Intent.class), anyInt()); in handlePreferenceClick_activityFound_openCarrierSettingActivity()
147 PackageManager pm = Mockito.mock(PackageManager.class); in handlePreferenceClick_activityNotFound_DoNothing() local
148 doReturn(pm).when(mContext).getPackageManager(); in handlePreferenceClick_activityNotFound_DoNothing()
149 doReturn(null).when(pm).resolveActivity(any(Intent.class), anyInt()); in handlePreferenceClick_activityNotFound_DoNothing()
161 PackageManager pm = Mockito.mock(PackageManager.class); in handlePreferenceClick_activityNotConfigured_DoNothing() local
162 doReturn(pm).when(mContext).getPackageManager(); in handlePreferenceClick_activityNotConfigured_DoNothing()
[all …]
/packages/apps/Settings/src/com/android/settings/security/trustagent/
DTrustAgentManager.java25 import android.content.pm.PackageManager;
26 import android.content.pm.ResolveInfo;
82 public boolean shouldProvideTrust(ResolveInfo resolveInfo, PackageManager pm) { in shouldProvideTrust() argument
84 if (pm.checkPermission(PERMISSION_PROVIDE_AGENT, packageName) in shouldProvideTrust()
111 final PackageManager pm = context.getPackageManager(); in getActiveTrustAgents() local
114 final List<ResolveInfo> resolveInfos = pm.queryIntentServices(TRUST_AGENT_INTENT, in getActiveTrustAgents()
123 if (resolveInfo.serviceInfo == null || !shouldProvideTrust(resolveInfo, pm)) { in getActiveTrustAgents()
127 getSettingsComponent(pm, resolveInfo); in getActiveTrustAgents()
151 private TrustAgentComponentInfo getSettingsComponent(PackageManager pm, in getSettingsComponent() argument
162 parser = resolveInfo.serviceInfo.loadXmlMetaData(pm, TRUST_AGENT_META_DATA); in getSettingsComponent()
[all …]
/packages/services/Car/tests/CarDeveloperOptions/src/com/android/car/developeroptions/deviceinfo/storage/
DStorageAsyncLoader.java19 import static android.content.pm.ApplicationInfo.CATEGORY_AUDIO;
20 import static android.content.pm.ApplicationInfo.CATEGORY_GAME;
21 import static android.content.pm.ApplicationInfo.CATEGORY_IMAGE;
22 import static android.content.pm.ApplicationInfo.CATEGORY_VIDEO;
25 import android.content.pm.ApplicationInfo;
26 import android.content.pm.PackageManager;
27 import android.content.pm.PackageManager.NameNotFoundException;
28 import android.content.pm.UserInfo;
58 String uuid, StorageStatsSource source, PackageManager pm) { in StorageAsyncLoader() argument
63 mPackageManager = pm; in StorageAsyncLoader()
/packages/apps/Settings/src/com/android/settings/deviceinfo/storage/
DStorageAsyncLoader.java19 import static android.content.pm.ApplicationInfo.CATEGORY_AUDIO;
20 import static android.content.pm.ApplicationInfo.CATEGORY_GAME;
21 import static android.content.pm.ApplicationInfo.CATEGORY_IMAGE;
22 import static android.content.pm.ApplicationInfo.CATEGORY_VIDEO;
25 import android.content.pm.ApplicationInfo;
26 import android.content.pm.PackageManager;
27 import android.content.pm.PackageManager.NameNotFoundException;
28 import android.content.pm.UserInfo;
58 String uuid, StorageStatsSource source, PackageManager pm) { in StorageAsyncLoader() argument
63 mPackageManager = pm; in StorageAsyncLoader()
/packages/apps/Launcher3/src/com/android/launcher3/util/
DPackageManagerHelper.java25 import android.content.pm.ApplicationInfo;
26 import android.content.pm.LauncherActivityInfo;
27 import android.content.pm.PackageInfo;
28 import android.content.pm.PackageManager;
29 import android.content.pm.PackageManager.NameNotFoundException;
30 import android.content.pm.ResolveInfo;
228 PackageManager pm = context.getPackageManager(); in isSystemApp() local
232 ResolveInfo info = pm.resolveActivity(intent, PackageManager.MATCH_DEFAULT_ONLY); in isSystemApp()
244 PackageInfo info = pm.getPackageInfo(packageName, 0); in isSystemApp()
260 public static Pair<String, Resources> findSystemApk(String action, PackageManager pm) { in findSystemApk() argument
[all …]
/packages/apps/Settings/src/com/android/settings/vpn2/
DAppPreference.java20 import android.content.pm.PackageInfo;
21 import android.content.pm.PackageManager;
53 PackageManager pm = userContext.getPackageManager(); in AppPreference() local
57 PackageInfo pkgInfo = pm.getPackageInfo(mPackageName, 0 /* flags */); in AppPreference()
59 icon = pkgInfo.applicationInfo.loadIcon(pm); in AppPreference()
66 icon = pm.getDefaultActivityIcon(); in AppPreference()
79 PackageManager pm = getUserContext().getPackageManager(); in getPackageInfo() local
80 return pm.getPackageInfo(mPackageName, 0 /* flags */); in getPackageInfo()
/packages/services/Car/tests/CarDeveloperOptions/src/com/android/car/developeroptions/vpn2/
DAppPreference.java20 import android.content.pm.PackageInfo;
21 import android.content.pm.PackageManager;
53 PackageManager pm = userContext.getPackageManager(); in AppPreference() local
57 PackageInfo pkgInfo = pm.getPackageInfo(mPackageName, 0 /* flags */); in AppPreference()
59 icon = pkgInfo.applicationInfo.loadIcon(pm); in AppPreference()
66 icon = pm.getDefaultActivityIcon(); in AppPreference()
79 PackageManager pm = getUserContext().getPackageManager(); in getPackageInfo() local
80 return pm.getPackageInfo(mPackageName, 0 /* flags */); in getPackageInfo()
/packages/apps/DocumentsUI/tests/common/com/android/documentsui/testing/
DTestPackageManager.java20 import android.content.pm.ActivityInfo;
21 import android.content.pm.ApplicationInfo;
22 import android.content.pm.PackageManager;
23 import android.content.pm.ProviderInfo;
25 import android.content.pm.ResolveInfo;
57 TestPackageManager pm = Mockito.mock( in create() local
59 pm.contentProviders = new HashMap<>(); in create()
60 return pm; in create()
/packages/services/Car/tests/CarDeveloperOptions/src/com/android/car/developeroptions/utils/
DZenServiceListing.java23 import android.content.pm.ActivityInfo;
24 import android.content.pm.ComponentInfo;
25 import android.content.pm.PackageManager;
26 import android.content.pm.ResolveInfo;
27 import android.content.pm.ServiceInfo;
93 PackageManager pm) { in getServices() argument
96 List<ResolveInfo> installedServices = pm.queryIntentServicesAsUser( in getServices()
119 PackageManager pm) { in getActivities() argument
122 List<ResolveInfo> resolveInfos = pm.queryIntentActivitiesAsUser( in getActivities()
/packages/apps/Settings/src/com/android/settings/utils/
DZenServiceListing.java23 import android.content.pm.ActivityInfo;
24 import android.content.pm.ComponentInfo;
25 import android.content.pm.PackageManager;
26 import android.content.pm.ResolveInfo;
27 import android.content.pm.ServiceInfo;
93 PackageManager pm) { in getServices() argument
96 List<ResolveInfo> installedServices = pm.queryIntentServicesAsUser( in getServices()
119 PackageManager pm) { in getActivities() argument
122 List<ResolveInfo> resolveInfos = pm.queryIntentActivitiesAsUser( in getActivities()
/packages/services/Car/tests/CarDeveloperOptions/src/com/android/car/developeroptions/applications/specialaccess/pictureinpicture/
DPictureInPictureSettings.java18 import static android.content.pm.PackageManager.GET_ACTIVITIES;
23 import android.content.pm.ActivityInfo;
24 import android.content.pm.ApplicationInfo;
25 import android.content.pm.PackageInfo;
26 import android.content.pm.PackageManager;
27 import android.content.pm.UserInfo;
74 public AppComparator(PackageManager pm) { in AppComparator() argument
75 mPm = pm; in AppComparator()
126 public PictureInPictureSettings(PackageManager pm, UserManager um) { in PictureInPictureSettings() argument
127 mPackageManager = pm; in PictureInPictureSettings()

12345678910>>...73