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

Commit 3ba1937e authored by Asmita Poddar's avatar Asmita Poddar
Browse files

Remove check for frame size

Previously there was a check to ensure that all frames have the exact same size and share the same hotspot.
A crash occurred if this condition was not satisfied,
which was causing presubmit to fail due to test failures.
Removing this crash condition to fix presubmit and added a TODO for a
more permanent solution.

Bug: 361232935
Test: Presubmit
Flag: EXEMPT fix crash
Change-Id: I256b1f470442395876bd6fd273d87be72578d276
parent 40e7272d
Loading
Loading
Loading
Loading
+3 −6
Original line number Diff line number Diff line
@@ -556,12 +556,9 @@ public final class PointerIcon implements Parcelable {
                                + "is a different type from the others. All frames should be the "
                                + "same type.");
                    }
                    if (drawableFrame.getIntrinsicWidth() != width ||
                        drawableFrame.getIntrinsicHeight() != height) {
                        throw new IllegalArgumentException("The bitmap size of " + i + "-th frame "
                                + "is different. All frames should have the exact same size and "
                                + "share the same hotspot.");
                    }
                    // TODO(b/361232935): Check when bitmap size of the ith frame is different
                    // drawableFrame.getIntrinsicWidth() != width ||
                    // drawableFrame.getIntrinsicHeight() != height
                    if (isVectorAnimation) {
                        drawableFrame = getBitmapDrawableFromVectorDrawable(resources,
                                (VectorDrawable) drawableFrame, pointerScale);