summaryrefslogtreecommitdiffstats
path: root/src/com/android/settings/ManageApplications.java
diff options
context:
space:
mode:
authorMichael Chan <mchan@android.com>2009-05-14 17:47:02 -0700
committerMichael Chan <mchan@android.com>2009-05-14 17:47:02 -0700
commit8762093e0094e09493fa6cbac8e8fbf265f18165 (patch)
tree3711951fb324975a29045c9fbdb9b2abdef1995d /src/com/android/settings/ManageApplications.java
parent4815a667cd8ce64b623523a5e1a42d900b2a0a05 (diff)
downloadpackages_apps_Settings-8762093e0094e09493fa6cbac8e8fbf265f18165.tar.gz
packages_apps_Settings-8762093e0094e09493fa6cbac8e8fbf265f18165.tar.bz2
packages_apps_Settings-8762093e0094e09493fa6cbac8e8fbf265f18165.zip
Findbug fixes in Settings app
modified: src/com/android/settings/ApnPreference.java modified: src/com/android/settings/ApnSettings.java modified: src/com/android/settings/BandMode.java modified: src/com/android/settings/BatteryInfo.java modified: src/com/android/settings/LanguageSettings.java modified: src/com/android/settings/ManageApplications.java modified: src/com/android/settings/RadioInfo.java modified: src/com/android/settings/SdCardSettings.java modified: src/com/android/settings/UsageStats.java modified: src/com/android/settings/ZoneList.java modified: src/com/android/settings/bluetooth/LocalBluetoothDevice.java modified: src/com/android/settings/deviceinfo/Status.java modified: src/com/android/settings/quicklaunch/QuickLaunchSettings.java modified: src/com/android/settings/wifi/AccessPointDialog.java modified: src/com/android/settings/wifi/AccessPointPreference.java modified: src/com/android/settings/wifi/WifiLayer.java modified: src/com/android/settings/wifi/WifiSettings.java
Diffstat (limited to 'src/com/android/settings/ManageApplications.java')
-rw-r--r--src/com/android/settings/ManageApplications.java21
1 files changed, 13 insertions, 8 deletions
diff --git a/src/com/android/settings/ManageApplications.java b/src/com/android/settings/ManageApplications.java
index 1595de148..e5b2134c0 100644
--- a/src/com/android/settings/ManageApplications.java
+++ b/src/com/android/settings/ManageApplications.java
@@ -426,15 +426,20 @@ public class ManageApplications extends ListActivity implements
public void onGetStatsCompleted(PackageStats pStats, boolean pSucceeded) {
AppInfo appInfo = null;
Bundle data = new Bundle();
- data.putString(ATTR_PKG_NAME, pStats.packageName);
- if(pSucceeded && pStats != null) {
- if (localLOGV) Log.i(TAG, "onGetStatsCompleted::"+pStats.packageName+", ("+
- pStats.cacheSize+","+
- pStats.codeSize+", "+pStats.dataSize);
- data.putParcelable(ATTR_APP_PKG_STATS, pStats);
- } else {
+ if (pStats != null) {
+ data.putString(ATTR_PKG_NAME, pStats.packageName);
+ if(pSucceeded) {
+ if (localLOGV) Log.i(TAG, "onGetStatsCompleted::"+pStats.packageName+", ("+
+ pStats.cacheSize+","+
+ pStats.codeSize+", "+pStats.dataSize);
+ data.putParcelable(ATTR_APP_PKG_STATS, pStats);
+ }
+ }
+
+ if(!pSucceeded || pStats == null) {
Log.w(TAG, "Invalid package stats from PackageManager");
}
+
//post message to Handler
Message msg = mHandler.obtainMessage(mMsgId, data);
msg.setData(data);
@@ -705,7 +710,7 @@ public class ManageApplications extends ListActivity implements
// internal structure used to track added and deleted packages when
// the activity has focus
- class AddRemoveInfo {
+ static class AddRemoveInfo {
String pkgName;
boolean add;
public AddRemoveInfo(String pPkgName, boolean pAdd) {