From 83308c738bd6161222b692b8697fc8d092fcc659 Mon Sep 17 00:00:00 2001 From: Robin Lee Date: Tue, 4 Apr 2023 10:22:27 +0000 Subject: [PATCH] Unstomp TRANSIT_FLAG_APP_CRASHED Change-Id: Ia833db57b7d969cc307403824919d116a0f9e0bf Test: atest android.server.wm.KeyguardTests Test: microbench/systemui/main/systemui-lockscreen-1-jank-suite Test: atest PlatformScenarioTests:android.platform.test.scenario.sysui.notification.ExpandNotificationByDragging Bug: 276503488 Bug: 276572219 --- core/java/android/view/WindowManager.java | 36 +++++++++++------------ 1 file changed, 18 insertions(+), 18 deletions(-) diff --git a/core/java/android/view/WindowManager.java b/core/java/android/view/WindowManager.java index cda1f3adb9a4f..48686fc259165 100644 --- a/core/java/android/view/WindowManager.java +++ b/core/java/android/view/WindowManager.java @@ -495,64 +495,64 @@ public interface WindowManager extends ViewManager { * Transition flag: Keyguard is going away, but keeping the notification shade open * @hide */ - int TRANSIT_FLAG_KEYGUARD_GOING_AWAY_TO_SHADE = 0x1; + int TRANSIT_FLAG_KEYGUARD_GOING_AWAY_TO_SHADE = (1 << 0); // 0x1 /** * Transition flag: Keyguard is going away, but doesn't want an animation for it * @hide */ - int TRANSIT_FLAG_KEYGUARD_GOING_AWAY_NO_ANIMATION = 0x2; + int TRANSIT_FLAG_KEYGUARD_GOING_AWAY_NO_ANIMATION = (1 << 1); // 0x2 /** * Transition flag: Keyguard is going away while it was showing the system wallpaper. * @hide */ - int TRANSIT_FLAG_KEYGUARD_GOING_AWAY_WITH_WALLPAPER = 0x4; + int TRANSIT_FLAG_KEYGUARD_GOING_AWAY_WITH_WALLPAPER = (1 << 2); // 0x4 /** * Transition flag: Keyguard is going away with subtle animation. * @hide */ - int TRANSIT_FLAG_KEYGUARD_GOING_AWAY_SUBTLE_ANIMATION = 0x8; - - /** - * Transition flag: Keyguard is going away to the launcher, and it needs us to clear the task - * snapshot of the launcher because it has changed something in the Launcher window. - * @hide - */ - int TRANSIT_FLAG_KEYGUARD_GOING_AWAY_TO_LAUNCHER_CLEAR_SNAPSHOT = 0x16; + int TRANSIT_FLAG_KEYGUARD_GOING_AWAY_SUBTLE_ANIMATION = (1 << 3); // 0x8 /** * Transition flag: App is crashed. * @hide */ - int TRANSIT_FLAG_APP_CRASHED = 0x10; + int TRANSIT_FLAG_APP_CRASHED = (1 << 4); // 0x10 /** * Transition flag: A window in a new task is being opened behind an existing one in another * activity's task. * @hide */ - int TRANSIT_FLAG_OPEN_BEHIND = 0x20; + int TRANSIT_FLAG_OPEN_BEHIND = (1 << 5); // 0x20 /** * Transition flag: The keyguard is locked throughout the whole transition. * @hide */ - int TRANSIT_FLAG_KEYGUARD_LOCKED = 0x40; + int TRANSIT_FLAG_KEYGUARD_LOCKED = (1 << 6); // 0x40 /** * Transition flag: Indicates that this transition is for recents animation. * TODO(b/188669821): Remove once special-case logic moves to shell. * @hide */ - int TRANSIT_FLAG_IS_RECENTS = 0x80; + int TRANSIT_FLAG_IS_RECENTS = (1 << 7); // 0x80 /** * Transition flag: Indicates that keyguard should go away with this transition. * @hide */ - int TRANSIT_FLAG_KEYGUARD_GOING_AWAY = 0x100; + int TRANSIT_FLAG_KEYGUARD_GOING_AWAY = (1 << 8); // 0x100 + + /** + * Transition flag: Keyguard is going away to the launcher, and it needs us to clear the task + * snapshot of the launcher because it has changed something in the Launcher window. + * @hide + */ + int TRANSIT_FLAG_KEYGUARD_GOING_AWAY_TO_LAUNCHER_CLEAR_SNAPSHOT = (1 << 9); // 0x200 /** * @hide @@ -562,12 +562,12 @@ public interface WindowManager extends ViewManager { TRANSIT_FLAG_KEYGUARD_GOING_AWAY_NO_ANIMATION, TRANSIT_FLAG_KEYGUARD_GOING_AWAY_WITH_WALLPAPER, TRANSIT_FLAG_KEYGUARD_GOING_AWAY_SUBTLE_ANIMATION, - TRANSIT_FLAG_KEYGUARD_GOING_AWAY_TO_LAUNCHER_CLEAR_SNAPSHOT, TRANSIT_FLAG_APP_CRASHED, TRANSIT_FLAG_OPEN_BEHIND, TRANSIT_FLAG_KEYGUARD_LOCKED, TRANSIT_FLAG_IS_RECENTS, - TRANSIT_FLAG_KEYGUARD_GOING_AWAY + TRANSIT_FLAG_KEYGUARD_GOING_AWAY, + TRANSIT_FLAG_KEYGUARD_GOING_AWAY_TO_LAUNCHER_CLEAR_SNAPSHOT }) @Retention(RetentionPolicy.SOURCE) @interface TransitionFlags {}