Loading core/java/android/content/pm/InstantAppRequest.java +5 −1 Original line number Diff line number Diff line Loading @@ -38,14 +38,18 @@ public final class InstantAppRequest { * Optional extra bundle provided by the source application to the installer for additional * verification. */ public final Bundle verificationBundle; /** Whether resolution occurs because an application is starting */ public final boolean resolveForStart; public InstantAppRequest(AuxiliaryResolveInfo responseObj, Intent origIntent, String resolvedType, String callingPackage, int userId, Bundle verificationBundle) { String resolvedType, String callingPackage, int userId, Bundle verificationBundle, boolean resolveForStart) { this.responseObj = responseObj; this.origIntent = origIntent; this.resolvedType = resolvedType; this.callingPackage = callingPackage; this.userId = userId; this.verificationBundle = verificationBundle; this.resolveForStart = resolveForStart; } } services/core/java/com/android/server/pm/InstantAppResolver.java +1 −1 Original line number Diff line number Diff line Loading @@ -122,7 +122,7 @@ public abstract class InstantAppResolver { } } // Only log successful instant application resolution if (resolutionStatus == RESOLUTION_SUCCESS) { if (requestObj.resolveForStart && resolutionStatus == RESOLUTION_SUCCESS) { logMetrics(ACTION_INSTANT_APP_RESOLUTION_PHASE_ONE, startTime, token, resolutionStatus); } Loading services/core/java/com/android/server/pm/PackageManagerService.java +6 −4 Original line number Diff line number Diff line Loading @@ -6778,7 +6778,7 @@ public class PackageManagerService extends IPackageManager.Stub Bundle verificationBundle, int userId) { final Message msg = mHandler.obtainMessage(INSTANT_APP_RESOLUTION_PHASE_TWO, new InstantAppRequest(responseObj, origIntent, resolvedType, callingPackage, userId, verificationBundle)); callingPackage, userId, verificationBundle, false /*resolveForStart*/)); mHandler.sendMessage(msg); } Loading Loading @@ -7362,7 +7362,8 @@ public class PackageManagerService extends IPackageManager.Stub } } if (addEphemeral) { result = maybeAddInstantAppInstaller(result, intent, resolvedType, flags, userId); result = maybeAddInstantAppInstaller( result, intent, resolvedType, flags, userId, resolveForStart); } if (sortResult) { Collections.sort(result, mResolvePrioritySorter); Loading @@ -7372,7 +7373,7 @@ public class PackageManagerService extends IPackageManager.Stub } private List<ResolveInfo> maybeAddInstantAppInstaller(List<ResolveInfo> result, Intent intent, String resolvedType, int flags, int userId) { String resolvedType, int flags, int userId, boolean resolveForStart) { // first, check to see if we've got an instant app already installed final boolean alreadyResolvedLocally = (flags & PackageManager.MATCH_INSTANT) != 0; ResolveInfo localInstantApp = null; Loading Loading @@ -7421,7 +7422,8 @@ public class PackageManagerService extends IPackageManager.Stub Trace.traceBegin(TRACE_TAG_PACKAGE_MANAGER, "resolveEphemeral"); final InstantAppRequest requestObject = new InstantAppRequest( null /*responseObj*/, intent /*origIntent*/, resolvedType, null /*callingPackage*/, userId, null /*verificationBundle*/); null /*callingPackage*/, userId, null /*verificationBundle*/, resolveForStart); auxiliaryResponse = InstantAppResolver.doInstantAppResolutionPhaseOne( mContext, mInstantAppResolverConnection, requestObject); Loading
core/java/android/content/pm/InstantAppRequest.java +5 −1 Original line number Diff line number Diff line Loading @@ -38,14 +38,18 @@ public final class InstantAppRequest { * Optional extra bundle provided by the source application to the installer for additional * verification. */ public final Bundle verificationBundle; /** Whether resolution occurs because an application is starting */ public final boolean resolveForStart; public InstantAppRequest(AuxiliaryResolveInfo responseObj, Intent origIntent, String resolvedType, String callingPackage, int userId, Bundle verificationBundle) { String resolvedType, String callingPackage, int userId, Bundle verificationBundle, boolean resolveForStart) { this.responseObj = responseObj; this.origIntent = origIntent; this.resolvedType = resolvedType; this.callingPackage = callingPackage; this.userId = userId; this.verificationBundle = verificationBundle; this.resolveForStart = resolveForStart; } }
services/core/java/com/android/server/pm/InstantAppResolver.java +1 −1 Original line number Diff line number Diff line Loading @@ -122,7 +122,7 @@ public abstract class InstantAppResolver { } } // Only log successful instant application resolution if (resolutionStatus == RESOLUTION_SUCCESS) { if (requestObj.resolveForStart && resolutionStatus == RESOLUTION_SUCCESS) { logMetrics(ACTION_INSTANT_APP_RESOLUTION_PHASE_ONE, startTime, token, resolutionStatus); } Loading
services/core/java/com/android/server/pm/PackageManagerService.java +6 −4 Original line number Diff line number Diff line Loading @@ -6778,7 +6778,7 @@ public class PackageManagerService extends IPackageManager.Stub Bundle verificationBundle, int userId) { final Message msg = mHandler.obtainMessage(INSTANT_APP_RESOLUTION_PHASE_TWO, new InstantAppRequest(responseObj, origIntent, resolvedType, callingPackage, userId, verificationBundle)); callingPackage, userId, verificationBundle, false /*resolveForStart*/)); mHandler.sendMessage(msg); } Loading Loading @@ -7362,7 +7362,8 @@ public class PackageManagerService extends IPackageManager.Stub } } if (addEphemeral) { result = maybeAddInstantAppInstaller(result, intent, resolvedType, flags, userId); result = maybeAddInstantAppInstaller( result, intent, resolvedType, flags, userId, resolveForStart); } if (sortResult) { Collections.sort(result, mResolvePrioritySorter); Loading @@ -7372,7 +7373,7 @@ public class PackageManagerService extends IPackageManager.Stub } private List<ResolveInfo> maybeAddInstantAppInstaller(List<ResolveInfo> result, Intent intent, String resolvedType, int flags, int userId) { String resolvedType, int flags, int userId, boolean resolveForStart) { // first, check to see if we've got an instant app already installed final boolean alreadyResolvedLocally = (flags & PackageManager.MATCH_INSTANT) != 0; ResolveInfo localInstantApp = null; Loading Loading @@ -7421,7 +7422,8 @@ public class PackageManagerService extends IPackageManager.Stub Trace.traceBegin(TRACE_TAG_PACKAGE_MANAGER, "resolveEphemeral"); final InstantAppRequest requestObject = new InstantAppRequest( null /*responseObj*/, intent /*origIntent*/, resolvedType, null /*callingPackage*/, userId, null /*verificationBundle*/); null /*callingPackage*/, userId, null /*verificationBundle*/, resolveForStart); auxiliaryResponse = InstantAppResolver.doInstantAppResolutionPhaseOne( mContext, mInstantAppResolverConnection, requestObject);