diff options
| author | 2024-03-05 21:24:56 +0000 | |
|---|---|---|
| committer | 2024-03-05 21:24:56 +0000 | |
| commit | 80e74ab79c4f904a19d18ef938aab90f9244e86d (patch) | |
| tree | 761099105863be1a91174c8ca6de3ca70c42cc44 | |
| parent | 67154dd72a3bac1029a322b3a8568396eb05affe (diff) | |
| parent | 1487b7cb2c86271ff2d190ab69e7907232981284 (diff) | |
Merge "Fix bubble reordering issue" into main
| -rw-r--r-- | libs/WindowManager/Shell/src/com/android/wm/shell/bubbles/BubbleStackView.java | 11 |
1 files changed, 6 insertions, 5 deletions
diff --git a/libs/WindowManager/Shell/src/com/android/wm/shell/bubbles/BubbleStackView.java b/libs/WindowManager/Shell/src/com/android/wm/shell/bubbles/BubbleStackView.java index 8fd6ffe15cfe..474430eb44ab 100644 --- a/libs/WindowManager/Shell/src/com/android/wm/shell/bubbles/BubbleStackView.java +++ b/libs/WindowManager/Shell/src/com/android/wm/shell/bubbles/BubbleStackView.java @@ -717,11 +717,6 @@ public class BubbleStackView extends FrameLayout // Hide the stack after a delay, if needed. updateTemporarilyInvisibleAnimation(false /* hideImmediately */); - - if (mShouldReorderBubblesAfterGestureCompletes) { - mShouldReorderBubblesAfterGestureCompletes = false; - updateBubbleOrderInternal(mBubbleData.getBubbles(), true); - } } }; @@ -2732,6 +2727,12 @@ public class BubbleStackView extends FrameLayout ev.getAction() != MotionEvent.ACTION_UP && ev.getAction() != MotionEvent.ACTION_CANCEL; + // If there is a deferred reorder action, and the gesture is over, run it now. + if (mShouldReorderBubblesAfterGestureCompletes && !mIsGestureInProgress) { + mShouldReorderBubblesAfterGestureCompletes = false; + updateBubbleOrderInternal(mBubbleData.getBubbles(), false); + } + return dispatched; } |