Loading packages/SystemUI/src/com/android/systemui/scrim/ScrimView.java +14 −0 Original line number Diff line number Diff line Loading @@ -30,8 +30,10 @@ import android.graphics.Rect; import android.graphics.RenderEffect; import android.graphics.Shader; import android.graphics.drawable.Drawable; import android.os.Build; import android.os.Looper; import android.util.AttributeSet; import android.util.Log; import android.view.MotionEvent; import android.view.View; Loading @@ -52,6 +54,9 @@ import java.util.concurrent.Executor; * need to be careful to synchronize when necessary. */ public class ScrimView extends View { private static final String TAG = "ScrimView"; private static final boolean isDebugLoggable = Build.isDebuggable() || Log.isLoggable(TAG, Log.DEBUG); private final Object mColorLock = new Object(); Loading Loading @@ -381,12 +386,21 @@ public class ScrimView extends View { */ public void setBlurRadius(float blurRadius) { if (blurRadius > 0) { debugLog("Apply blur RenderEffect to ScrimView " + mScrimName + " for radius " + blurRadius); setRenderEffect(RenderEffect.createBlurEffect( blurRadius, blurRadius, Shader.TileMode.CLAMP)); } else { debugLog("Resetting blur RenderEffect to ScrimView " + mScrimName); setRenderEffect(null); } } private void debugLog(String logMsg) { if (isDebugLoggable) { Log.d(TAG, logMsg); } } } packages/SystemUI/src/com/android/systemui/shade/NotificationPanelViewController.java +2 −0 Original line number Diff line number Diff line Loading @@ -989,8 +989,10 @@ public final class NotificationPanelViewController implements mBlurConfig.getMaxBlurRadiusPx(), Shader.TileMode.CLAMP); } debugLog("Applying blur RenderEffect to shade."); mView.setRenderEffect(mBlurRenderEffect); } else { debugLog("Resetting blur RenderEffect on shade."); mView.setRenderEffect(null); } } Loading packages/SystemUI/src/com/android/systemui/statusbar/notification/stack/NotificationStackScrollLayout.java +9 −0 Original line number Diff line number Diff line Loading @@ -6076,7 +6076,9 @@ public class NotificationStackScrollLayout if (mBlurRadius > 0) { mBlurEffect = RenderEffect.createBlurEffect(mBlurRadius, mBlurRadius, Shader.TileMode.CLAMP); spewLog("Setting up blur RenderEffect for NotificationStackScrollLayout"); } else { spewLog("Clearing the blur RenderEffect setup for NotificationStackScrollLayout"); mBlurEffect = null; } } Loading Loading @@ -6252,6 +6254,7 @@ public class NotificationStackScrollLayout @Override protected void dispatchDraw(@NonNull Canvas canvas) { if (mBlurEffect != null) { spewLog("Applying blur RenderEffect to NotificationStackScrollLayout"); // reuse the cached RenderNode to blur mBlurNode.setPosition(0, 0, canvas.getWidth(), canvas.getHeight()); mBlurNode.setRenderEffect(mBlurEffect); Loading Loading @@ -7025,4 +7028,10 @@ public class NotificationStackScrollLayout SceneContainerFlag.assertInLegacyMode(); mMaxTopPadding = maxTopPadding; } private void spewLog(String logMsg) { if (SPEW) { Log.v(TAG, logMsg); } } } packages/SystemUI/src/com/android/systemui/statusbar/notification/stack/NotificationStackScrollLayoutController.java +10 −0 Original line number Diff line number Diff line Loading @@ -1355,11 +1355,15 @@ public class NotificationStackScrollLayoutController implements Dumpable { */ public void setBlurRadius(float blurRadius) { if (blurRadius > 0.0f) { debugLog( "Setting blur RenderEffect for NotificationStackScrollLayoutController with " + "radius " + blurRadius); mView.setRenderEffect(RenderEffect.createBlurEffect( blurRadius, blurRadius, Shader.TileMode.CLAMP)); } else { debugLog("Resetting blur RenderEffect for NotificationStackScrollLayoutController"); mView.setRenderEffect(null); } } Loading Loading @@ -2175,4 +2179,10 @@ public class NotificationStackScrollLayoutController implements Dumpable { && !mSwipeHelper.isSwiping(); } } private void debugLog(String msg) { if (DEBUG) { Log.d(TAG, msg); } } } Loading
packages/SystemUI/src/com/android/systemui/scrim/ScrimView.java +14 −0 Original line number Diff line number Diff line Loading @@ -30,8 +30,10 @@ import android.graphics.Rect; import android.graphics.RenderEffect; import android.graphics.Shader; import android.graphics.drawable.Drawable; import android.os.Build; import android.os.Looper; import android.util.AttributeSet; import android.util.Log; import android.view.MotionEvent; import android.view.View; Loading @@ -52,6 +54,9 @@ import java.util.concurrent.Executor; * need to be careful to synchronize when necessary. */ public class ScrimView extends View { private static final String TAG = "ScrimView"; private static final boolean isDebugLoggable = Build.isDebuggable() || Log.isLoggable(TAG, Log.DEBUG); private final Object mColorLock = new Object(); Loading Loading @@ -381,12 +386,21 @@ public class ScrimView extends View { */ public void setBlurRadius(float blurRadius) { if (blurRadius > 0) { debugLog("Apply blur RenderEffect to ScrimView " + mScrimName + " for radius " + blurRadius); setRenderEffect(RenderEffect.createBlurEffect( blurRadius, blurRadius, Shader.TileMode.CLAMP)); } else { debugLog("Resetting blur RenderEffect to ScrimView " + mScrimName); setRenderEffect(null); } } private void debugLog(String logMsg) { if (isDebugLoggable) { Log.d(TAG, logMsg); } } }
packages/SystemUI/src/com/android/systemui/shade/NotificationPanelViewController.java +2 −0 Original line number Diff line number Diff line Loading @@ -989,8 +989,10 @@ public final class NotificationPanelViewController implements mBlurConfig.getMaxBlurRadiusPx(), Shader.TileMode.CLAMP); } debugLog("Applying blur RenderEffect to shade."); mView.setRenderEffect(mBlurRenderEffect); } else { debugLog("Resetting blur RenderEffect on shade."); mView.setRenderEffect(null); } } Loading
packages/SystemUI/src/com/android/systemui/statusbar/notification/stack/NotificationStackScrollLayout.java +9 −0 Original line number Diff line number Diff line Loading @@ -6076,7 +6076,9 @@ public class NotificationStackScrollLayout if (mBlurRadius > 0) { mBlurEffect = RenderEffect.createBlurEffect(mBlurRadius, mBlurRadius, Shader.TileMode.CLAMP); spewLog("Setting up blur RenderEffect for NotificationStackScrollLayout"); } else { spewLog("Clearing the blur RenderEffect setup for NotificationStackScrollLayout"); mBlurEffect = null; } } Loading Loading @@ -6252,6 +6254,7 @@ public class NotificationStackScrollLayout @Override protected void dispatchDraw(@NonNull Canvas canvas) { if (mBlurEffect != null) { spewLog("Applying blur RenderEffect to NotificationStackScrollLayout"); // reuse the cached RenderNode to blur mBlurNode.setPosition(0, 0, canvas.getWidth(), canvas.getHeight()); mBlurNode.setRenderEffect(mBlurEffect); Loading Loading @@ -7025,4 +7028,10 @@ public class NotificationStackScrollLayout SceneContainerFlag.assertInLegacyMode(); mMaxTopPadding = maxTopPadding; } private void spewLog(String logMsg) { if (SPEW) { Log.v(TAG, logMsg); } } }
packages/SystemUI/src/com/android/systemui/statusbar/notification/stack/NotificationStackScrollLayoutController.java +10 −0 Original line number Diff line number Diff line Loading @@ -1355,11 +1355,15 @@ public class NotificationStackScrollLayoutController implements Dumpable { */ public void setBlurRadius(float blurRadius) { if (blurRadius > 0.0f) { debugLog( "Setting blur RenderEffect for NotificationStackScrollLayoutController with " + "radius " + blurRadius); mView.setRenderEffect(RenderEffect.createBlurEffect( blurRadius, blurRadius, Shader.TileMode.CLAMP)); } else { debugLog("Resetting blur RenderEffect for NotificationStackScrollLayoutController"); mView.setRenderEffect(null); } } Loading Loading @@ -2175,4 +2179,10 @@ public class NotificationStackScrollLayoutController implements Dumpable { && !mSwipeHelper.isSwiping(); } } private void debugLog(String msg) { if (DEBUG) { Log.d(TAG, msg); } } }