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

Commit 3b894e1f authored by fbaron's avatar fbaron
Browse files

Fix IllegalArguemntException for ClipIconView#update

The scale was infinity sometimes which means that the view minSize is probably getting set to 0 due to lp height and width being 0, so we do not update the views as they are no longer laid out

Flag: NONE
Test: Opening apps should work fine, but i wasn't able to repro this exception before or after this fix
Fix: 318099222
Change-Id: I1c08346c7ee1d4e89d9c3ba23ee2aa51a451cb31
parent ff03dd19
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -112,7 +112,7 @@ public class ClipIconView extends View implements ClipPathView {
        float scaleY = rect.height() / minSize;
        float scale = Math.max(1f, Math.min(scaleX, scaleY));

        if (Float.isNaN(scale)) {
        if (Float.isNaN(scale) || Float.isInfinite(scale)) {
            // Views are no longer laid out, do not update.
            return;
        }