Launcher3: Ensure to update cached thumbnail if we take new one

This fixes a bug, which became obvious thanks to disabled live tile, but
has already existed before, where recents jumps to using last snapshot
instead of the correct/current one once you fling, because thumbnails
were cached but the cache had not been updated in this codepath.

Change-Id: Ie7afe56b6e0aecaae2510248c5887873800a0b51
This commit is contained in:
nift4 2023-08-24 14:16:43 +02:00 committed by fazilsheik96
parent a1acf94d2f
commit 61d397ac42
1 changed files with 1 additions and 0 deletions

View File

@ -5619,6 +5619,7 @@ public abstract class RecentsView<ACTIVITY_TYPE extends StatefulActivity<STATE_T
mRecentsAnimationController.screenshotTask(container.getTask().key.id);
TaskThumbnailView thumbnailView = container.getThumbnailView();
if (td != null) {
container.getTask().thumbnail = td;
thumbnailView.setThumbnail(container.getTask(), td);
} else {
thumbnailView.refresh();