summaryrefslogtreecommitdiffstats
path: root/src/com/android/launcher2/AllAppsView.java
diff options
context:
space:
mode:
authorJoe Onorato <joeo@android.com>2009-12-11 10:59:51 -0800
committerJoe Onorato <joeo@android.com>2009-12-11 10:59:51 -0800
commit8cf34293dc2f078bf023ac77d007f5182f9b9357 (patch)
tree83172abe28bfe2cb089c7f2e35a5068ce3480c12 /src/com/android/launcher2/AllAppsView.java
parent6799f0f9ced102e84475b5af3dbca16c0e6f2280 (diff)
downloadandroid_packages_apps_Trebuchet-8cf34293dc2f078bf023ac77d007f5182f9b9357.tar.gz
android_packages_apps_Trebuchet-8cf34293dc2f078bf023ac77d007f5182f9b9357.tar.bz2
android_packages_apps_Trebuchet-8cf34293dc2f078bf023ac77d007f5182f9b9357.zip
Launcher2 - This might fix the missing app problem and the crash in removeApp.
This marks the apps list as dirty by default. Usually, because of how long it takes the loader thread to run, the apps list comes in after the surface has been initialized. However, if the surface isn't around yet when setApps is called, then setApps won't set mRollo.mAppsDirty because mRollo is null. The extra null check is necessary for the normal case when mAllAppsList isn't ready yet when the surface comes in.
Diffstat (limited to 'src/com/android/launcher2/AllAppsView.java')
-rw-r--r--src/com/android/launcher2/AllAppsView.java4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/com/android/launcher2/AllAppsView.java b/src/com/android/launcher2/AllAppsView.java
index 88f074cdd..fa272b91f 100644
--- a/src/com/android/launcher2/AllAppsView.java
+++ b/src/com/android/launcher2/AllAppsView.java
@@ -804,7 +804,7 @@ public class AllAppsView extends RSSurfaceView
private Canvas mSelectionCanvas;
boolean mHasSurface = false;
- private boolean mAppsDirty = false;
+ private boolean mAppsDirty = true;
Params mParams;
State mState;
@@ -1051,7 +1051,7 @@ public class AllAppsView extends RSSurfaceView
void dirtyCheck() {
if (mHasSurface) {
- if (mAppsDirty) {
+ if (mAppsDirty && mAllAppsList != null) {
for (int i=0; i < mState.iconCount; i++) {
uploadAppIcon(i, mAllAppsList.get(i));
}