diff options
| author | 2024-05-28 19:15:01 +0800 | |
|---|---|---|
| committer | 2024-05-29 14:55:13 +0800 | |
| commit | af692457ea9abbe0f159ea9aed4a261ff04909dc (patch) | |
| tree | 5f8144b6ec340209c45bb962a40705d11039bb91 | |
| parent | ec19f1f4b72d146f1d7dc08dfba43a2d55cace60 (diff) | |
[Back Navi] Fix a recursive call from clearBackAnimations to isTarget.
Modify the set mComposed order to preventing from recursive call.
Bug: 343030535
Test: atest BackNavigationControllerTests
Change-Id: Iaab6685a42c3416aa2f7a6d7d2db2669ba776cef
| -rw-r--r-- | services/core/java/com/android/server/wm/BackNavigationController.java | 10 |
1 files changed, 4 insertions, 6 deletions
diff --git a/services/core/java/com/android/server/wm/BackNavigationController.java b/services/core/java/com/android/server/wm/BackNavigationController.java index 0e4f0335118d..d71933414aa0 100644 --- a/services/core/java/com/android/server/wm/BackNavigationController.java +++ b/services/core/java/com/android/server/wm/BackNavigationController.java @@ -1099,10 +1099,6 @@ class BackNavigationController { } void finishPresentAnimations() { - if (!mComposed) { - return; - } - if (mCloseAdaptor != null) { mCloseAdaptor.mTarget.cancelAnimation(); mCloseAdaptor = null; @@ -1131,8 +1127,10 @@ class BackNavigationController { } void clearBackAnimateTarget() { - finishPresentAnimations(); - mComposed = false; + if (mComposed) { + mComposed = false; + finishPresentAnimations(); + } mWaitTransition = false; mStartingSurfaceTargetMatch = false; mSwitchType = UNKNOWN; |