From 50647bf2013d2e73bf841c2fad89a5bcc4837bab Mon Sep 17 00:00:00 2001 From: Heemin Seog Date: Wed, 1 Apr 2020 18:06:24 -0700 Subject: [PATCH] Ensure views are inflated before trying to animate. Bug: 153000670 Test: manual (flash, spam touches to the nav bar - before opening notification shade) Change-Id: Iaa4f1515a238fbd6978d263dd22ea4d9438170a6 --- .../car/notification/NotificationPanelViewController.java | 3 +++ 1 file changed, 3 insertions(+) diff --git a/packages/CarSystemUI/src/com/android/systemui/car/notification/NotificationPanelViewController.java b/packages/CarSystemUI/src/com/android/systemui/car/notification/NotificationPanelViewController.java index f6679c0e681f4..9d98479dfeff5 100644 --- a/packages/CarSystemUI/src/com/android/systemui/car/notification/NotificationPanelViewController.java +++ b/packages/CarSystemUI/src/com/android/systemui/car/notification/NotificationPanelViewController.java @@ -219,6 +219,9 @@ public class NotificationPanelViewController extends OverlayViewController { mNavBarNotificationTouchListener = (v, event) -> { + if (!isInflated()) { + return true; + } boolean consumed = navBarCloseNotificationGestureDetector.onTouchEvent(event); if (consumed) { return true;