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

Commit db4e713c authored by TreeHugger Robot's avatar TreeHugger Robot Committed by Android (Google) Code Review
Browse files

Merge "Don't layout empty tasks in layout anim if we have the actual content."...

Merge "Don't layout empty tasks in layout anim if we have the actual content." into ub-launcher3-qt-dev
parents a5ed906d 1335c36c
Loading
Loading
Loading
Loading
+7 −0
Original line number Diff line number Diff line
@@ -161,6 +161,13 @@ public final class ContentFillItemAnimator extends SimpleItemAnimator {

    private void animateChangeImpl(ViewHolder viewHolder, long startDelay) {
        TaskItemView itemView = (TaskItemView) viewHolder.itemView;
        if (itemView.getAlpha() == 0) {
            // View is still not visible, so we can finish the change immediately.
            CONTENT_TRANSITION_PROGRESS.set(itemView, 1.0f);
            dispatchChangeFinished(viewHolder, true /* oldItem */);
            dispatchFinishedWhenDone();
            return;
        }
        final ObjectAnimator anim =
                ObjectAnimator.ofFloat(itemView, CONTENT_TRANSITION_PROGRESS, 0.0f, 1.0f);
        anim.setDuration(ITEM_CHANGE_DURATION).setStartDelay(startDelay);