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

Commit 6f953c4d authored by Jeff DeCew's avatar Jeff DeCew
Browse files

Fix pinched short notification at bottom of lockscreen.

This change disables the feature on the lockscreen which smoothly transitions the roundness of notifications when they get closer to the shelf.  For short notifications (a common occurrence when notifications are redacted) this would cause the TOP corners of the bottommost notification (and the bottom corners of the one above it) to be rounded on the lockscreen.  This was because the 'shelf' start was considered to be a shelf height ABOVE the bottom of the stack.  This CL just tweaks the shelf position down to where it intuitively is.

Fixes: 235234674
Test: manual
Merged-In: I2da67022a62f0b3adcd00df1c9b372754ee643fc
Change-Id: I2da67022a62f0b3adcd00df1c9b372754ee643fc
(cherry picked from commit d37fbdaa)
parent 0251a892
Loading
Loading
Loading
Loading
+8 −1
Original line number Diff line number Diff line
@@ -398,7 +398,14 @@ public class NotificationShelf extends ActivatableNotificationView implements
            if (child instanceof ActivatableNotificationView) {
                ActivatableNotificationView anv =
                        (ActivatableNotificationView) child;
                updateCornerRoundnessOnScroll(anv, viewStart, shelfStart);
                // Because we show whole notifications on the lockscreen, the bottom notification is
                // always "just about to enter the shelf" by normal scrolling rules.  This is fine
                // if the shelf is visible, but if the shelf is hidden, it causes incorrect curling.
                // notificationClipEnd handles the discrepancy between a visible and hidden shelf,
                // so we use that when on the keyguard (and while animating away) to reduce curling.
                final float keyguardSafeShelfStart =
                        mAmbientState.isOnKeyguard() ? notificationClipEnd : shelfStart;
                updateCornerRoundnessOnScroll(anv, viewStart, keyguardSafeShelfStart);
            }
        }