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

Commit 0488ee20 authored by Selim Cinek's avatar Selim Cinek Committed by android-build-merger
Browse files

Fixed a bug that could lead to an empty notification am: aa3901a5 am: 0314b862

am: 67388cbb

Change-Id: Ic5df0408ad39f04714d23f9b55ed90fa8dafa2ef
parents 06510c50 67388cbb
Loading
Loading
Loading
Loading
+4 −0
Original line number Diff line number Diff line
@@ -744,6 +744,7 @@ public abstract class ActivatableNotificationView extends ExpandableOutlineView
                }
                if (!mWasCancelled) {
                    enableAppearDrawing(false);
                    onAppearAnimationFinished(isAppearing);
                }
            }

@@ -760,6 +761,9 @@ public abstract class ActivatableNotificationView extends ExpandableOutlineView
        mAppearAnimator.start();
    }

    protected void onAppearAnimationFinished(boolean wasAppearing) {
    }

    private void cancelAppearAnimation() {
        if (mAppearAnimator != null) {
            mAppearAnimator.cancel();
+19 −2
Original line number Diff line number Diff line
@@ -598,7 +598,7 @@ public class ExpandableNotificationRow extends ActivatableNotificationView {
    }

    private NotificationHeaderView getVisibleNotificationHeader() {
        if (mIsSummaryWithChildren) {
        if (mIsSummaryWithChildren && !mShowingPublic) {
            return mChildrenContainer.getHeaderView();
        }
        return getShowingLayout().getVisibleNotificationHeader();
@@ -1442,12 +1442,29 @@ public class ExpandableNotificationRow extends ActivatableNotificationView {

    @Override
    protected View getContentView() {
        if (mIsSummaryWithChildren) {
        if (mIsSummaryWithChildren && !mShowingPublic) {
            return mChildrenContainer;
        }
        return getShowingLayout();
    }

    @Override
    protected void onAppearAnimationFinished(boolean wasAppearing) {
        super.onAppearAnimationFinished(wasAppearing);
        if (wasAppearing) {
            // During the animation the visible view might have changed, so let's make sure all
            // alphas are reset
            if (mChildrenContainer != null) {
                mChildrenContainer.setAlpha(1.0f);
                mChildrenContainer.setLayerType(LAYER_TYPE_NONE, null);
            }
            mPrivateLayout.setAlpha(1.0f);
            mPrivateLayout.setLayerType(LAYER_TYPE_NONE, null);
            mPublicLayout.setAlpha(1.0f);
            mPublicLayout.setLayerType(LAYER_TYPE_NONE, null);
        }
    }

    @Override
    public int getExtraBottomPadding() {
        if (mIsSummaryWithChildren && isGroupExpanded()) {