Increating the scrim alpha for super-light wallpapers
Bug: 79111591
Change-Id: I645d5e536ea504a37f7cc0bb94a677f694bf4385
diff --git a/quickstep/src/com/android/quickstep/views/ShelfScrimView.java b/quickstep/src/com/android/quickstep/views/ShelfScrimView.java
index b47af2d..69b77b4 100644
--- a/quickstep/src/com/android/quickstep/views/ShelfScrimView.java
+++ b/quickstep/src/com/android/quickstep/views/ShelfScrimView.java
@@ -47,6 +47,7 @@
private static final int THRESHOLD_ALPHA_DARK = 102;
private static final int THRESHOLD_ALPHA_LIGHT = 46;
+ private static final int THRESHOLD_ALPHA_SUPER_LIGHT = 128;
// In transposed layout, we simply draw a flat color.
private boolean mDrawingFlatColor;
@@ -76,8 +77,13 @@
mMaxScrimAlpha = OVERVIEW.getWorkspaceScrimAlpha(mLauncher);
mEndAlpha = Color.alpha(mEndScrim);
- mThresholdAlpha = Themes.getAttrBoolean(mLauncher, R.attr.isMainColorDark)
- ? THRESHOLD_ALPHA_DARK : THRESHOLD_ALPHA_LIGHT;
+ if (Themes.getAttrBoolean(mLauncher, R.attr.isMainColorDark)) {
+ mThresholdAlpha = THRESHOLD_ALPHA_DARK;
+ } else if (Themes.getAttrBoolean(mLauncher, R.attr.isWorkspaceDarkText)) {
+ mThresholdAlpha = THRESHOLD_ALPHA_SUPER_LIGHT;
+ } else {
+ mThresholdAlpha = THRESHOLD_ALPHA_LIGHT;
+ }
mRadius = mLauncher.getResources().getDimension(R.dimen.shelf_surface_radius);
mPaint = new Paint(Paint.ANTI_ALIAS_FLAG);