diff options
| author | 2024-06-14 19:02:48 +0000 | |
|---|---|---|
| committer | 2024-06-14 19:05:58 +0000 | |
| commit | 0b768a00b8a05458e663788784e2cda9699fc41d (patch) | |
| tree | b6604829b7694be15a6ca16cdaad395d2727e7ee | |
| parent | e47952d1e1cba9e711cf7dc9b23ec476b6cf1933 (diff) | |
Revert "Fix shade flicker when launching activity from glanceable hub"
This reverts commit 592f2370db95a1639cd4ba1736a85d3a8bd4434a.
Reason for revert: don't need this flag anymore
Change-Id: Ib572372b914748cc6afbbabeb8fcadddef7c8267
3 files changed, 1 insertions, 44 deletions
diff --git a/packages/SystemUI/aconfig/systemui.aconfig b/packages/SystemUI/aconfig/systemui.aconfig index 1cbf67ee0d0e..0fdcc7a5bba8 100644 --- a/packages/SystemUI/aconfig/systemui.aconfig +++ b/packages/SystemUI/aconfig/systemui.aconfig @@ -884,16 +884,6 @@ flag { } flag { - name: "shade_collapse_activity_launch_fix" - namespace: "systemui" - description: "Avoid collapsing the shade on activity launch if it is already collapsed, as this causes a flicker." - bug: "331591373" - metadata { - purpose: PURPOSE_BUGFIX - } -} - -flag { name: "slice_broadcast_relay_in_background" namespace: "systemui" description: "Move handling of slice broadcast relay broadcasts to background threads" diff --git a/packages/SystemUI/src/com/android/systemui/shade/NotificationPanelViewController.java b/packages/SystemUI/src/com/android/systemui/shade/NotificationPanelViewController.java index 262befc1e9ad..8b78f54309f3 100644 --- a/packages/SystemUI/src/com/android/systemui/shade/NotificationPanelViewController.java +++ b/packages/SystemUI/src/com/android/systemui/shade/NotificationPanelViewController.java @@ -25,7 +25,6 @@ import static com.android.app.animation.Interpolators.EMPHASIZED_DECELERATE; import static com.android.keyguard.KeyguardClockSwitch.LARGE; import static com.android.keyguard.KeyguardClockSwitch.SMALL; import static com.android.systemui.Flags.predictiveBackAnimateShade; -import static com.android.systemui.Flags.shadeCollapseActivityLaunchFix; import static com.android.systemui.Flags.smartspaceRelocateToBottom; import static com.android.systemui.classifier.Classifier.BOUNCER_UNLOCK; import static com.android.systemui.classifier.Classifier.GENERIC; @@ -4118,11 +4117,7 @@ public final class NotificationPanelViewController implements ShadeSurface, Dump @Override public boolean canBeCollapsed() { - return !isFullyCollapsed() && !isTracking() && !isClosing() - // Don't try to collapse if on keyguard, as the expansion fraction is 1 in this - // case. - && !(shadeCollapseActivityLaunchFix() && mExpandedFraction == 1f - && mBarState == KEYGUARD); + return !isFullyCollapsed() && !isTracking() && !isClosing(); } public void instantCollapse() { diff --git a/packages/SystemUI/tests/src/com/android/systemui/shade/NotificationPanelViewControllerTest.java b/packages/SystemUI/tests/src/com/android/systemui/shade/NotificationPanelViewControllerTest.java index 65364053f109..13d44de44ca1 100644 --- a/packages/SystemUI/tests/src/com/android/systemui/shade/NotificationPanelViewControllerTest.java +++ b/packages/SystemUI/tests/src/com/android/systemui/shade/NotificationPanelViewControllerTest.java @@ -18,7 +18,6 @@ package com.android.systemui.shade; import static com.android.keyguard.KeyguardClockSwitch.LARGE; import static com.android.keyguard.KeyguardClockSwitch.SMALL; -import static com.android.systemui.Flags.FLAG_SHADE_COLLAPSE_ACTIVITY_LAUNCH_FIX; import static com.android.systemui.shade.ShadeExpansionStateManagerKt.STATE_CLOSED; import static com.android.systemui.shade.ShadeExpansionStateManagerKt.STATE_OPEN; import static com.android.systemui.shade.ShadeExpansionStateManagerKt.STATE_OPENING; @@ -48,7 +47,6 @@ import android.animation.ValueAnimator; import android.graphics.Point; import android.os.PowerManager; import android.platform.test.annotations.DisableFlags; -import android.platform.test.annotations.EnableFlags; import android.testing.AndroidTestingRunner; import android.testing.TestableLooper; import android.view.MotionEvent; @@ -679,32 +677,6 @@ public class NotificationPanelViewControllerTest extends NotificationPanelViewCo } @Test - @EnableFlags(FLAG_SHADE_COLLAPSE_ACTIVITY_LAUNCH_FIX) - public void testCanBeCollapsed_expandedInKeyguard() { - mStatusBarStateController.setState(KEYGUARD); - mNotificationPanelViewController.setExpandedFraction(1f); - - assertThat(mNotificationPanelViewController.canBeCollapsed()).isFalse(); - } - - @Test - @EnableFlags(FLAG_SHADE_COLLAPSE_ACTIVITY_LAUNCH_FIX) - public void testCanBeCollapsed_expandedInShade() { - mStatusBarStateController.setState(SHADE); - mNotificationPanelViewController.setExpandedFraction(1f); - assertThat(mNotificationPanelViewController.canBeCollapsed()).isTrue(); - } - - @Test - @DisableFlags(FLAG_SHADE_COLLAPSE_ACTIVITY_LAUNCH_FIX) - public void testCanBeCollapsed_expandedInKeyguard_flagDisabled() { - mStatusBarStateController.setState(KEYGUARD); - mNotificationPanelViewController.setExpandedFraction(1f); - - assertThat(mNotificationPanelViewController.canBeCollapsed()).isTrue(); - } - - @Test @Ignore("b/341163515 - fails to clean up animators correctly") public void testSwipeWhileLocked_notifiesKeyguardState() { mStatusBarStateController.setState(KEYGUARD); |