Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 07f81af3 authored by Jerry Chang's avatar Jerry Chang Committed by Automerger Merge Worker
Browse files

Merge "Always draw background for task thumbnail" into sc-v2-dev am: 5b2bbe7e am: b7218408

Original change: https://googleplex-android-review.googlesource.com/c/platform/packages/apps/Launcher3/+/16422016

Change-Id: I15b0b99c4352839f5ae6d6b8bb101bab5b30f2a1
parents 7cc82937 b7218408
Loading
Loading
Loading
Loading
+7 −6
Original line number Diff line number Diff line
@@ -297,15 +297,16 @@ public class TaskThumbnailView extends View {
            }
        }

        // Draw the background in all cases, except when the thumbnail data is opaque
        // Always draw the background since the snapshots might be translucent or partially empty
        // (For example, tasks been reparented out of dismissing split root when drag-to-dismiss
        // split screen).
        canvas.drawRoundRect(x, y, width, height, cornerRadius, cornerRadius, mBackgroundPaint);

        final boolean drawBackgroundOnly = mTask == null || mTask.isLocked || mBitmapShader == null
                || mThumbnailData == null;
        if (drawBackgroundOnly || mThumbnailData.isTranslucent) {
            canvas.drawRoundRect(x, y, width, height, cornerRadius, cornerRadius, mBackgroundPaint);
        if (drawBackgroundOnly) {
            return;
        }
        }

        canvas.drawRoundRect(x, y, width, height, cornerRadius, cornerRadius, mPaint);
    }