diff options
author | Eric Arseneau <earseneau@google.com> | 2022-04-07 14:35:44 -0700 |
---|---|---|
committer | Eric Arseneau <earseneau@google.com> | 2022-04-14 23:09:16 -0700 |
commit | 26017c68ee11d3f2d54ca731119c8dc4ddb842cf (patch) | |
tree | 618c91b7f65c846bb711714d5f4af6e3d1b9f8fa /packages/SystemUI/src | |
parent | 6dae96de34f3d951be8458b61441bfb762fb79b9 (diff) | |
parent | df1c9c98e12490d61dab288937bb84d2fa1cedb2 (diff) |
Merge s-mpr-2022-04
Change-Id: I2325ba5c76e7dba314bdcd5b53fdc36b5e90fb31
Diffstat (limited to 'packages/SystemUI/src')
3 files changed, 6 insertions, 4 deletions
diff --git a/packages/SystemUI/src/com/android/systemui/biometrics/UdfpsEnrollProgressBarDrawable.java b/packages/SystemUI/src/com/android/systemui/biometrics/UdfpsEnrollProgressBarDrawable.java index b31a36ee741c..631a461b0627 100644 --- a/packages/SystemUI/src/com/android/systemui/biometrics/UdfpsEnrollProgressBarDrawable.java +++ b/packages/SystemUI/src/com/android/systemui/biometrics/UdfpsEnrollProgressBarDrawable.java @@ -22,7 +22,6 @@ import android.graphics.Canvas; import android.graphics.ColorFilter; import android.graphics.Paint; import android.graphics.drawable.Drawable; -import android.util.Log; import android.view.animation.Interpolator; import android.view.animation.OvershootInterpolator; @@ -216,8 +215,6 @@ public class UdfpsEnrollProgressBarDrawable extends Drawable { @Override public void draw(@NonNull Canvas canvas) { - Log.d(TAG, "setEnrollmentProgress: draw"); - canvas.save(); // Progress starts from the top, instead of the right diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/notification/stack/NotificationStackScrollLayoutController.java b/packages/SystemUI/src/com/android/systemui/statusbar/notification/stack/NotificationStackScrollLayoutController.java index f14cc93c2046..9f440606a365 100644 --- a/packages/SystemUI/src/com/android/systemui/statusbar/notification/stack/NotificationStackScrollLayoutController.java +++ b/packages/SystemUI/src/com/android/systemui/statusbar/notification/stack/NotificationStackScrollLayoutController.java @@ -279,11 +279,11 @@ public class NotificationStackScrollLayoutController { @Override public void onThemeChanged() { - updateShowEmptyShadeView(); mView.updateCornerRadius(); mView.updateBgColor(); mView.updateDecorViews(); mView.reinflateViews(); + updateShowEmptyShadeView(); updateFooter(); } diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/notification/stack/StackScrollAlgorithm.java b/packages/SystemUI/src/com/android/systemui/statusbar/notification/stack/StackScrollAlgorithm.java index 2c70a5fd9ce7..c4567df914f0 100644 --- a/packages/SystemUI/src/com/android/systemui/statusbar/notification/stack/StackScrollAlgorithm.java +++ b/packages/SystemUI/src/com/android/systemui/statusbar/notification/stack/StackScrollAlgorithm.java @@ -376,6 +376,11 @@ public class StackScrollAlgorithm { final float stackHeight = ambientState.getStackHeight() - shelfHeight - scrimPadding; final float stackEndHeight = ambientState.getStackEndHeight() - shelfHeight - scrimPadding; + if (stackEndHeight == 0f) { + // This should not happen, since even when the shade is empty we show EmptyShadeView + // but check just in case, so we don't return infinity or NaN. + return 0f; + } return stackHeight / stackEndHeight; } |