Merge "Reorder bubbles without animations on collapse" into sc-dev am: 26e6b76d99
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/13665681 MUST ONLY BE SUBMITTED BY AUTOMERGER Change-Id: I754e00b34a283251d8a500429d1b672560af3f09
This commit is contained in:
@@ -1539,19 +1539,16 @@ public class BubbleStackView extends FrameLayout
|
||||
* Update bubble order and pointer position.
|
||||
*/
|
||||
public void updateBubbleOrder(List<Bubble> bubbles) {
|
||||
if (isExpansionAnimating()) {
|
||||
return;
|
||||
}
|
||||
final Runnable reorder = () -> {
|
||||
for (int i = 0; i < bubbles.size(); i++) {
|
||||
Bubble bubble = bubbles.get(i);
|
||||
mBubbleContainer.reorderView(bubble.getIconView(), i);
|
||||
}
|
||||
};
|
||||
if (mIsExpanded) {
|
||||
if (mIsExpanded || isExpansionAnimating()) {
|
||||
reorder.run();
|
||||
updateBadgesAndZOrder(false /* setBadgeForCollapsedStack */);
|
||||
} else {
|
||||
} else if (!isExpansionAnimating()) {
|
||||
List<View> bubbleViews = bubbles.stream()
|
||||
.map(b -> b.getIconView()).collect(Collectors.toList());
|
||||
mStackAnimationController.animateReorder(bubbleViews, reorder);
|
||||
|
||||
Reference in New Issue
Block a user