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

Commit 173765b4 authored by TreeHugger Robot's avatar TreeHugger Robot Committed by Android (Google) Code Review
Browse files

Merge "Always draw the background color in the task views" into ub-launcher3-edmonton

parents b1c33a5d 174aae5d
Loading
Loading
Loading
Loading
+12 −14
Original line number Diff line number Diff line
@@ -148,20 +148,18 @@ public class TaskThumbnailView extends View {
        }
        int width = getMeasuredWidth();
        int height = getMeasuredHeight();
        if (mClipBottom > 0 && !mTask.isLocked) {

        // Always draw the background since the snapshots may be translucent
        canvas.drawRoundRect(0, 0, width, height, mCornerRadius, mCornerRadius, mBackgroundPaint);
        if (!mTask.isLocked) {
            if (mClipBottom > 0) {
                canvas.save();
                canvas.clipRect(0, 0, width, mClipBottom);

                canvas.drawRoundRect(0, 0, width, height, mCornerRadius, mCornerRadius, mPaint);
                canvas.restore();
            canvas.save();
            canvas.clipRect(0, mClipBottom, width, height);
            canvas.drawRoundRect(0, 0, width, height, mCornerRadius, mCornerRadius,
                    mBackgroundPaint);
            canvas.restore();
            } else {
            canvas.drawRoundRect(0, 0, width, height, mCornerRadius,
                    mCornerRadius, mTask.isLocked ? mBackgroundPaint : mPaint);
                canvas.drawRoundRect(0, 0, width, height, mCornerRadius, mCornerRadius, mPaint);
            }
        }
    }