Merge "Always add the instant app installer" into oc-dev
am: e943a3cbe7
Change-Id: I2f057e4d0367fd47050c30340490987ef6d2128a
This commit is contained in:
@@ -6491,18 +6491,22 @@ public class PackageManagerService extends IPackageManager.Stub
|
|||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
final PackageParser.Package pkg = mPackages.get(pkgName);
|
final PackageParser.Package pkg = mPackages.get(pkgName);
|
||||||
|
result = null;
|
||||||
if (pkg != null) {
|
if (pkg != null) {
|
||||||
return applyPostResolutionFilter(filterIfNotSystemUser(
|
result = filterIfNotSystemUser(
|
||||||
mActivities.queryIntentForPackage(
|
mActivities.queryIntentForPackage(
|
||||||
intent, resolvedType, flags, pkg.activities, userId),
|
intent, resolvedType, flags, pkg.activities, userId),
|
||||||
userId), instantAppPkgName);
|
userId);
|
||||||
} else {
|
}
|
||||||
|
if (result == null || result.size() == 0) {
|
||||||
// the caller wants to resolve for a particular package; however, there
|
// the caller wants to resolve for a particular package; however, there
|
||||||
// were no installed results, so, try to find an ephemeral result
|
// were no installed results, so, try to find an ephemeral result
|
||||||
addEphemeral = !ephemeralDisabled
|
addEphemeral = !ephemeralDisabled
|
||||||
&& isInstantAppAllowed(
|
&& isInstantAppAllowed(
|
||||||
intent, null /*result*/, userId, true /*skipPackageCheck*/);
|
intent, null /*result*/, userId, true /*skipPackageCheck*/);
|
||||||
result = new ArrayList<ResolveInfo>();
|
if (result == null) {
|
||||||
|
result = new ArrayList<>();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user