From 0c414c0740b78fde686fd35af7184e7232162998 Mon Sep 17 00:00:00 2001 From: Pablo Gamito Date: Tue, 29 Mar 2022 15:42:45 +0000 Subject: [PATCH] Revert "Revert "Use new T activity transitions in legacy"" This reverts commit 1250be73c8dd89fe5442df36f648d461606df4f0. Change-Id: Icb6902a2078feab30157ddaff8eb066133cb1384 --- .../internal/policy/TransitionAnimation.java | 25 ----------- .../res/anim/activity_close_enter_legacy.xml | 34 -------------- .../res/anim/activity_close_exit_legacy.xml | 44 ------------------ .../res/anim/activity_open_enter_legacy.xml | 42 ----------------- .../res/anim/activity_open_exit_legacy.xml | 45 ------------------- core/res/res/values/symbols.xml | 4 -- 6 files changed, 194 deletions(-) delete mode 100644 core/res/res/anim/activity_close_enter_legacy.xml delete mode 100644 core/res/res/anim/activity_close_exit_legacy.xml delete mode 100644 core/res/res/anim/activity_open_enter_legacy.xml delete mode 100644 core/res/res/anim/activity_open_exit_legacy.xml diff --git a/core/java/com/android/internal/policy/TransitionAnimation.java b/core/java/com/android/internal/policy/TransitionAnimation.java index e2d250589a8fb..fd8534d45b2b2 100644 --- a/core/java/com/android/internal/policy/TransitionAnimation.java +++ b/core/java/com/android/internal/policy/TransitionAnimation.java @@ -101,10 +101,6 @@ public class TransitionAnimation { private static final String DEFAULT_PACKAGE = "android"; - // TODO (b/215515255): remove once we full migrate to shell transitions - private static final boolean SHELL_TRANSITIONS_ENABLED = - SystemProperties.getBoolean("persist.wm.debug.shell_transit", false); - private final Context mContext; private final String mTag; @@ -259,9 +255,6 @@ public class TransitionAnimation { resId = ent.array.getResourceId(animAttr, 0); } } - if (!SHELL_TRANSITIONS_ENABLED) { - resId = updateToLegacyIfNeeded(resId); - } resId = updateToTranslucentAnimIfNeeded(resId, transit); if (ResourceId.isValid(resId)) { return loadAnimationSafely(context, resId, mTag); @@ -269,24 +262,6 @@ public class TransitionAnimation { return null; } - /** - * Replace animations that are not compatible with the legacy transition system with ones that - * are compatible with it. - * TODO (b/215515255): remove once we full migrate to shell transitions - */ - private int updateToLegacyIfNeeded(int anim) { - if (anim == R.anim.activity_open_enter) { - return R.anim.activity_open_enter_legacy; - } else if (anim == R.anim.activity_open_exit) { - return R.anim.activity_open_exit_legacy; - } else if (anim == R.anim.activity_close_enter) { - return R.anim.activity_close_enter_legacy; - } else if (anim == R.anim.activity_close_exit) { - return R.anim.activity_close_exit_legacy; - } - return anim; - } - /** Load animation by attribute Id from a specific AnimationStyle resource. */ @Nullable public Animation loadAnimationAttr(String packageName, int animStyleResId, int animAttr, diff --git a/core/res/res/anim/activity_close_enter_legacy.xml b/core/res/res/anim/activity_close_enter_legacy.xml deleted file mode 100644 index 9fa7c5498ea6c..0000000000000 --- a/core/res/res/anim/activity_close_enter_legacy.xml +++ /dev/null @@ -1,34 +0,0 @@ - - - - - - \ No newline at end of file diff --git a/core/res/res/anim/activity_close_exit_legacy.xml b/core/res/res/anim/activity_close_exit_legacy.xml deleted file mode 100644 index 1599ae8cb19fc..0000000000000 --- a/core/res/res/anim/activity_close_exit_legacy.xml +++ /dev/null @@ -1,44 +0,0 @@ - - - - - - - diff --git a/core/res/res/anim/activity_open_enter_legacy.xml b/core/res/res/anim/activity_open_enter_legacy.xml deleted file mode 100644 index 38d3e8ed06ce9..0000000000000 --- a/core/res/res/anim/activity_open_enter_legacy.xml +++ /dev/null @@ -1,42 +0,0 @@ - - - - - - diff --git a/core/res/res/anim/activity_open_exit_legacy.xml b/core/res/res/anim/activity_open_exit_legacy.xml deleted file mode 100644 index 3865d2149f42f..0000000000000 --- a/core/res/res/anim/activity_open_exit_legacy.xml +++ /dev/null @@ -1,45 +0,0 @@ - - - - - - - - - \ No newline at end of file diff --git a/core/res/res/values/symbols.xml b/core/res/res/values/symbols.xml index 94c9a122ee759..f946ba19b3c75 100644 --- a/core/res/res/values/symbols.xml +++ b/core/res/res/values/symbols.xml @@ -1715,10 +1715,6 @@ - - - -