summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorandroid-build-team Robot <android-build-team-robot@google.com>2021-04-09 21:10:55 +0000
committerandroid-build-team Robot <android-build-team-robot@google.com>2021-04-09 21:10:55 +0000
commit7cc412ace5354ae515df95662930d3693e6076c3 (patch)
treed555276eb179d60a70316a55392a4ee3fffa7885
parent18df48aa7034de06b1677f1f8f12414ce6ad5b28 (diff)
parent18217e7f94b221907a9454510d95ec2c0ca114d8 (diff)
downloadLauncher3-7cc412ace5354ae515df95662930d3693e6076c3.tar.gz
Snap for 7272189 from 18217e7f94b221907a9454510d95ec2c0ca114d8 to mainline-media-swcodec-releaseandroid-mainline-11.0.0_r40android11-mainline-media-swcodec-release
Change-Id: I4b7562cf8ec8f02ff2ca7bd73e47fdc9ab23b22f
-rw-r--r--quickstep/recents_ui_overrides/src/com/android/quickstep/TaskOverlayFactory.java2
-rw-r--r--quickstep/recents_ui_overrides/src/com/android/quickstep/views/TaskThumbnailView.java5
2 files changed, 4 insertions, 3 deletions
diff --git a/quickstep/recents_ui_overrides/src/com/android/quickstep/TaskOverlayFactory.java b/quickstep/recents_ui_overrides/src/com/android/quickstep/TaskOverlayFactory.java
index e9614d1351..1eaacd30bb 100644
--- a/quickstep/recents_ui_overrides/src/com/android/quickstep/TaskOverlayFactory.java
+++ b/quickstep/recents_ui_overrides/src/com/android/quickstep/TaskOverlayFactory.java
@@ -146,7 +146,7 @@ public class TaskOverlayFactory implements ResourceBasedOverride {
*/
public void initOverlay(Task task, ThumbnailData thumbnail, Matrix matrix,
boolean rotated) {
- final boolean isAllowedByPolicy = thumbnail.isRealSnapshot;
+ final boolean isAllowedByPolicy = mThumbnailView.isRealSnapshot();
getActionsView().updateDisabledFlags(DISABLED_ROTATED, rotated);
diff --git a/quickstep/recents_ui_overrides/src/com/android/quickstep/views/TaskThumbnailView.java b/quickstep/recents_ui_overrides/src/com/android/quickstep/views/TaskThumbnailView.java
index b2f937f8c2..dbea80adbc 100644
--- a/quickstep/recents_ui_overrides/src/com/android/quickstep/views/TaskThumbnailView.java
+++ b/quickstep/recents_ui_overrides/src/com/android/quickstep/views/TaskThumbnailView.java
@@ -447,13 +447,14 @@ public class TaskThumbnailView extends View implements PluginListener<OverviewSc
}
/**
- * Returns whether the snapshot is real.
+ * Returns whether the snapshot is real. If the device is locked for the user of the task,
+ * the snapshot used will be an app-theme generated snapshot instead of a real snapshot.
*/
public boolean isRealSnapshot() {
if (mThumbnailData == null) {
return false;
}
- return mThumbnailData.isRealSnapshot;
+ return mThumbnailData.isRealSnapshot && !mTask.isLocked;
}
/**