Only show optimizing storage dialog if dex opt dialog was shown am: 2578beccbe
am: fd33b0194a
Change-Id: Ib9beeed392d134aa2a367e8758165ca05eef1b3e
This commit is contained in:
@@ -538,6 +538,9 @@ public class PackageManagerService extends IPackageManager.Stub {
|
||||
final boolean mIsPreNUpgrade;
|
||||
final boolean mIsPreNMR1Upgrade;
|
||||
|
||||
@GuardedBy("mPackages")
|
||||
private boolean mDexOptDialogShown;
|
||||
|
||||
/** The location for ASEC container files on internal storage. */
|
||||
final String mAsecInternalPath;
|
||||
|
||||
@@ -7150,7 +7153,11 @@ public class PackageManagerService extends IPackageManager.Stub {
|
||||
}
|
||||
}
|
||||
if (doTrim) {
|
||||
if (!isFirstBoot()) {
|
||||
final boolean dexOptDialogShown;
|
||||
synchronized (mPackages) {
|
||||
dexOptDialogShown = mDexOptDialogShown;
|
||||
}
|
||||
if (!isFirstBoot() && dexOptDialogShown) {
|
||||
try {
|
||||
ActivityManagerNative.getDefault().showBootMessage(
|
||||
mContext.getResources().getString(
|
||||
@@ -7244,6 +7251,9 @@ public class PackageManagerService extends IPackageManager.Stub {
|
||||
numberOfPackagesVisited, numberOfPackagesToDexopt), true);
|
||||
} catch (RemoteException e) {
|
||||
}
|
||||
synchronized (mPackages) {
|
||||
mDexOptDialogShown = true;
|
||||
}
|
||||
}
|
||||
|
||||
// If the OTA updates a system app which was previously preopted to a non-preopted state
|
||||
|
||||
Reference in New Issue
Block a user