Merge "Reset the static preloaded icon result once launcher is hidden" into udc-dev am: 7cd608594b
Original change: https://googleplex-android-review.googlesource.com/c/platform/packages/apps/Launcher3/+/23697218
Change-Id: Ia9dc508fb9d9225e01d7bf627032a384e2d9324b
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
diff --git a/src/com/android/launcher3/Launcher.java b/src/com/android/launcher3/Launcher.java
index 37a20bf..25eb160 100644
--- a/src/com/android/launcher3/Launcher.java
+++ b/src/com/android/launcher3/Launcher.java
@@ -1074,6 +1074,7 @@
logStopAndResume(false /* isResume */);
mAppWidgetHolder.setActivityStarted(false);
NotificationListener.removeNotificationsChangedListener(getPopupDataProvider());
+ FloatingIconView.resetIconLoadResult();
}
@Override
diff --git a/src/com/android/launcher3/views/FloatingIconView.java b/src/com/android/launcher3/views/FloatingIconView.java
index 4d0e2af..6b5c8df 100644
--- a/src/com/android/launcher3/views/FloatingIconView.java
+++ b/src/com/android/launcher3/views/FloatingIconView.java
@@ -572,6 +572,13 @@
}
/**
+ * Resets the static icon load result used for preloading the icon for a launching app.
+ */
+ public static void resetIconLoadResult() {
+ sIconLoadResult = null;
+ }
+
+ /**
* Creates a floating icon view for {@param originalView}.
* @param originalView The view to copy
* @param visibilitySyncView A view whose visibility should update in sync with originalView.
@@ -608,7 +615,7 @@
}
view.setOriginalDrawableBackground(view.mIconLoadResult.btvDrawable);
}
- sIconLoadResult = null;
+ resetIconLoadResult();
// Match the position of the original view.
view.matchPositionOf(launcher, originalView, isOpening, positionOut);