Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 233241f1 authored by Selim Cinek's avatar Selim Cinek
Browse files

Fixed a crash with HUNs

Bug: 21500600
Change-Id: Idf0a7be5d58bb5c666b930a0beada1e0ed2869aa
parent 60598075
Loading
Loading
Loading
Loading
+6 −5
Original line number Diff line number Diff line
@@ -1655,8 +1655,13 @@ public class NotificationStackScrollLayout extends ViewGroup
     * @return Whether an animation was generated.
     */
    private boolean generateRemoveAnimation(View child) {
        if (mAddedHeadsUpChildren.contains(child)) {
            removeChildFromHeadsUpChangeAnimations(child);
            mAddedHeadsUpChildren.remove(child);
            return false;
        }
        if (mIsExpanded && mAnimationsEnabled && !isChildInInvisibleGroup(child)) {
            if (!mChildrenToAddAnimated.contains(child) && !mAddedHeadsUpChildren.contains(child)) {
            if (!mChildrenToAddAnimated.contains(child)) {
                // Generate Animations
                mChildrenToRemoveAnimated.add(child);
                mNeedsAnimation = true;
@@ -1664,10 +1669,6 @@ public class NotificationStackScrollLayout extends ViewGroup
            } else {
                mChildrenToAddAnimated.remove(child);
                mFromMoreCardAdditions.remove(child);
                boolean remove = mAddedHeadsUpChildren.remove(child);
                if (remove) {
                    removeChildFromHeadsUpChangeAnimations(child);
                }
                return false;
            }
        }