From 984dd77845aa56039b37d07adc36c8c4b2c04184 Mon Sep 17 00:00:00 2001 From: Beverly Date: Tue, 28 Apr 2020 09:26:44 -0400 Subject: [PATCH] Don't reset notif translation when menu is open If the user is viewing the notification menu (slide notification partially to the left or right and see the Settings/snooze buttons), then when the notification is updated, the notification's translation should not be updated or else the notification menu snaps back unexpectedly while the user is viewing the menu. Fixes: 14878871 Test: manually tested with constantly updating notification (ie: Maps in navigation) and also manually tested by posting a notification with a delayed update via the Notify.apk Change-Id: Ib7ebb6cd5b89590109ff7a7aa224ed537c6767de --- .../statusbar/notification/row/ExpandableNotificationRow.java | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/notification/row/ExpandableNotificationRow.java b/packages/SystemUI/src/com/android/systemui/statusbar/notification/row/ExpandableNotificationRow.java index ba72e2879f144..38120cb8d7bb4 100644 --- a/packages/SystemUI/src/com/android/systemui/statusbar/notification/row/ExpandableNotificationRow.java +++ b/packages/SystemUI/src/com/android/systemui/statusbar/notification/row/ExpandableNotificationRow.java @@ -1831,6 +1831,10 @@ public class ExpandableNotificationRow extends ActivatableNotificationView } public void resetTranslation() { + if (mMenuRow != null && mMenuRow.isMenuVisible()) { + return; + } + if (mTranslateAnim != null) { mTranslateAnim.cancel(); }