From cda60ac3f9e95f7ba7afa8d2721d0428065b212c Mon Sep 17 00:00:00 2001 From: Winson Chung Date: Thu, 16 Jul 2020 19:08:35 +0000 Subject: [PATCH] Removing unnecessary code - The code was existing before we added onRecentsAnimationStateChanged earlier. But none of the other callers call this method with barWindow=NAV_BAR so this code was previously not even getting hit. In particular, touchAutoDim is already triggered in the nav bar layout touch handling, and the volume panel already listens for touch outside so all this does is trigger unnecessary animations (volume tries to animate even when not showing, and we don't dim the gesture bar since we have the sampling). Change-Id: I0bb309e1ddb593d01ce8f5fcc9622753324cdd09 --- .../src/com/android/systemui/statusbar/phone/StatusBar.java | 6 ------ 1 file changed, 6 deletions(-) diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/phone/StatusBar.java b/packages/SystemUI/src/com/android/systemui/statusbar/phone/StatusBar.java index 8ee0bdf2938ad..c5acd9bd0f06c 100644 --- a/packages/SystemUI/src/com/android/systemui/statusbar/phone/StatusBar.java +++ b/packages/SystemUI/src/com/android/systemui/statusbar/phone/StatusBar.java @@ -2477,7 +2477,6 @@ public class StatusBar extends SystemUI implements DemoMode, private final Runnable mCheckBarModes = this::checkBarModes; public void setInteracting(int barWindow, boolean interacting) { - final boolean changing = ((mInteractingWindows & barWindow) != 0) != interacting; mInteractingWindows = interacting ? (mInteractingWindows | barWindow) : (mInteractingWindows & ~barWindow); @@ -2486,11 +2485,6 @@ public class StatusBar extends SystemUI implements DemoMode, } else { mAutoHideController.resumeSuspendedAutoHide(); } - // manually dismiss the volume panel when interacting with the nav bar - if (changing && interacting && barWindow == StatusBarManager.WINDOW_NAVIGATION_BAR) { - mNavigationBarController.touchAutoDim(mDisplayId); - dismissVolumeDialog(); - } checkBarModes(); }