Automated import from //branches/master/...@140830,140830

This commit is contained in:
Dianne Hackborn
2009-03-24 18:38:23 -07:00
committed by The Android Open Source Project
parent 678764730b
commit 04750b6b43
4 changed files with 38 additions and 10 deletions

View File

@@ -3248,12 +3248,18 @@ class PackageManagerService extends IPackageManager.Stub {
res.removedInfo.sendBroadcast(false, true);
Bundle extras = new Bundle(1);
extras.putInt(Intent.EXTRA_UID, res.uid);
if (res.removedInfo.removedPackage != null) {
final boolean update = res.removedInfo.removedPackage != null;
if (update) {
extras.putBoolean(Intent.EXTRA_REPLACING, true);
}
sendPackageBroadcast(Intent.ACTION_PACKAGE_ADDED,
res.pkg.applicationInfo.packageName,
extras);
if (update) {
sendPackageBroadcast(Intent.ACTION_PACKAGE_REPLACED,
res.pkg.applicationInfo.packageName,
extras);
}
}
Runtime.getRuntime().gc();
}