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

Commit e7640411 authored by Garfield Tan's avatar Garfield Tan
Browse files

Fall back when failing to load size restricted icon

Bug: 226295380
Test: Notification still looks good.
Change-Id: Iff1b5ea18253bdc660731382da961f6b99ba33bd
parent 0f3393a4
Loading
Loading
Loading
Loading
+4 −1
Original line number Diff line number Diff line
@@ -122,8 +122,11 @@ public class CachingIconView extends ImageView {
    public Runnable setImageIconAsync(@Nullable final Icon icon) {
        resetCache();
        Drawable drawable = loadSizeRestrictedIcon(icon);
        if (drawable != null) {
            return () -> setImageDrawable(drawable);
        }
        return super.setImageIconAsync(icon);
    }

    @Override
    @RemotableViewMethod(asyncImpl="setImageResourceAsync")